Closed stefanc18 closed 6 months ago
@frostming
probably related: #347 not using an out of order table should fix it.
but I am a bit burnt by the convoluted parsing logic and busy with other projects. can you try debugging yourself first?
My group hits this issue as well, we use tomlkit to muck with pyproject.toml before publishing, and it produced invalid pyproject.toml file, unless we reorder sections in the toml file. I'm just adding "+1" datapoint here.
It isn't easy to make both happy so I decide to revert #347 since it is less harmful and has a workaround /cc @robbotorigami
Hello,
After updating tomlkit to version 0.12.5,
TOMLFile.write
does not update the toml file correctly anymore. See the following reproductible example:pyproject.toml file:
script:
pyproject.toml result after running the script with tomlkit 0.12.4 (you can see that the repository property was added where it should be):
pyproject.toml result after running the script with tomlkit 0.12.5 (the repository property is added under dependencies):
This behavior results in an invalid toml file, looks like a regression in the latest release.
Thanks in advance.