-
Notifications
You must be signed in to change notification settings - Fork 2.3k
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
TOML parsing fails on add command if using non-inlined tables #8454
Comments
probably wants reporting to tomlkit |
From the error alone it's not clear to me if this is indeed an issue in |
tomlkit maintainers will be better able to provide guidance than poetry will
I guess it's not that hard. I don't suppose poetry is doing more than (i) read the file (ii) replace the redis entry with a newer version of the same. Anyway if I cared to try and reproduce this with tomlkit only, that's where I'd start. |
there has now been a tomlkit release with that fix, there is no reason to keep this open |
This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
-vvv
option) and have included the output below.Issue
It looks like if we use pretty printed TOML (which is confirmed valid by TOML linter and also passes
poetry check
command) which contains tables that aren't in the inline format that poetry usually adds them in usingpoetry add
to update those requirements can fail if the updated item is not the last item in the list.Running the command
poetry add "pytz==2023.3.post1
will workRunning the command
poetry add "redis=^4.5.6" --extras=hiredis
will fail with'Null' object has no attribute '_trivia'
Reason seems to be the order, redis update will work if it's moved as the first item in the list and vice versa.
Full error log with
-vvv
:The text was updated successfully, but these errors were encountered: