Skip to content

Update example from pdm-backend.#251

Merged
henryiii merged 2 commits into
abravalheri:mainfrom
udifuchs:fix-pdm-example
Apr 17, 2025
Merged

Update example from pdm-backend.#251
henryiii merged 2 commits into
abravalheri:mainfrom
udifuchs:fix-pdm-example

Conversation

@udifuchs

Copy link
Copy Markdown
Contributor

The old example for pyproject.toml from pdm-backend had a section which is no longer valid:

[tool.pdm]
includes = ["pdm"]
source-includes = ["tests"]

The new format is:

[tool.pdm.build]
includes = ["src"]
source-includes = ["tests"]

For some context, I am prototyping a TOML schema. For testing, I converted the full pyproject JSON schema to a TOML schema, and I am using your test examples for testing the TOML schema. This is how I noticed this issue.

The old example had a section which is no longer valid:
```
[tool.pdm]
includes = ["pdm"]
source-includes = ["tests"]
```

The new format is:
```
[tool.pdm.build]
includes = ["src"]
source-includes = ["tests"]
```
@henryiii

Copy link
Copy Markdown
Collaborator

What about the other changes? Some look good, but I noticed the tool.towncrier stuff seems to be gone?

@udifuchs

Copy link
Copy Markdown
Contributor Author

What about the other changes? Some look good, but I noticed the tool.towncrier stuff seems to be gone?

I did not edit this example, I just copied it as is from pdm-backend. Aparently they stopped using towncrier a while ago. If you want, I can add the towncrier pyproject in another PR.

@henryiii henryiii left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

I just thought having a list in an example was probably a good idea, it might not be covered elsewhere. It doesn't need to be in a pdm example, though.

@udifuchs

Copy link
Copy Markdown
Contributor Author

I just enabled the pdm schema check for the pdm example. This explains why the previous pdm example was not failing validation.

I wonder if all tools should be enabled for validations of all the examples.

@henryiii

Copy link
Copy Markdown
Collaborator

Probably; that didn't exist when they were originally added.

@henryiii henryiii merged commit 75b08dc into abravalheri:main Apr 17, 2025
@udifuchs udifuchs deleted the fix-pdm-example branch April 18, 2025 15:42
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.

2 participants