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

Actually ensure the contents of pyproject.toml do not change after cleanup #207

Merged

Conversation

edgarrmondragon
Copy link
Contributor

@edgarrmondragon edgarrmondragon commented Jan 9, 2025

@edgarrmondragon edgarrmondragon force-pushed the test-pep621-contents-cleanup branch 4 times, most recently from c24d0b3 to e2534a4 Compare January 10, 2025 00:01
@edgarrmondragon edgarrmondragon force-pushed the test-pep621-contents-cleanup branch from e2534a4 to a61e80b Compare January 10, 2025 00:05
@@ -668,7 +668,7 @@ def _get_and_apply_version(
elif pep621:
name = pyproject["project"]["name"]
original = pyproject["tool"]["poetry"]["version"]
dynamic_array = pyproject["project"]["dynamic"].copy()
dynamic_array = pyproject["project"]["dynamic"]
Copy link
Contributor Author

@edgarrmondragon edgarrmondragon Jan 10, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Turns out .copy() gets you the underlying list, not an tomlkit.item.Array.

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I wouldn't have guessed either 😅 Thanks for catching that.

@edgarrmondragon edgarrmondragon marked this pull request as ready for review January 10, 2025 00:10
@edgarrmondragon edgarrmondragon changed the title Actually ensure the contents of pyproject.toml do not change after cleanup Actually ensure the contents of pyproject.toml do not change after cleanup Jan 10, 2025
@mtkennerly mtkennerly merged commit 368049e into mtkennerly:master Jan 10, 2025
36 of 37 checks passed
@edgarrmondragon edgarrmondragon deleted the test-pep621-contents-cleanup branch January 10, 2025 01:25
@mtkennerly mtkennerly added this to the v1.5.1 milestone Jan 10, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Unexpected pyproject.toml changes after poetry install
2 participants