Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bug: NULL in a non-used level of hierarchy throws error #66

Open
nicholas-masel opened this issue Oct 9, 2024 · 0 comments · Fixed by #67
Open

Bug: NULL in a non-used level of hierarchy throws error #66

nicholas-masel opened this issue Oct 9, 2024 · 0 comments · Fixed by #67
Assignees
Labels
bug Something isn't working

Comments

@nicholas-masel
Copy link
Collaborator

nicholas-masel commented Oct 9, 2024

What happened?

If you have a hierarchical path and are executing in anything other than the first level of the hierarchy, you should get a NULL returned for the previous levels that are not going to be used.`

set_autos() is not removing these NULLs before looping through the list, so you end up with an out of bounds error since it is using the length of the list with NULLs included.

> set_autos(null_test$autos)
Error in autos[[i]] : subscript out of bounds

Session Information

n/a

Reproducible Example

I will add this as a test and PR.

@nicholas-masel nicholas-masel added the bug Something isn't working label Oct 9, 2024
@nicholas-masel nicholas-masel self-assigned this Oct 9, 2024
@nicholas-masel nicholas-masel linked a pull request Oct 9, 2024 that will close this issue
13 tasks
mstackhouse added a commit that referenced this issue Oct 16, 2024
…el-of-hierarchy-throws-error

Closes #66: remove nulls before setting autos
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant