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

"Complete" example of pyproject.toml. #3245

Closed
WoosterInitiative opened this issue Aug 30, 2022 · 2 comments
Closed

"Complete" example of pyproject.toml. #3245

WoosterInitiative opened this issue Aug 30, 2022 · 2 comments
Labels
T: documentation Improvements to the docs (e.g. new topic, correction, etc)

Comments

@WoosterInitiative
Copy link

The existing example pyproject.toml has the extend-exclude options commented out, so the syntax isn't correct. It's possible that it's self-evident to others, but I have not been able to wrap my head around the proper way to do it. It appears that it does not work like the include option.

Here's what mine looks like right now, but returns:
Error: Invalid value for '--extend-exclude': Not a valid regular expression: nothing to repeat at position 0

[tool.black]
    include = [
        '\.pyi?$',
        '^/purchases',
        '^/web_tools',
        '^/setup_sheets',
        '^/tool_compatibility',
        ]
    extend-exclude = '/migrations /__pycache__ *.html'

I'm not sure what I'm doing wrong (and I'll keep trying), but perhaps another example file with the options filled out in such a way as to be complete would help. That and/or keep it consistent with the other options.

There also seem to be multiple issues regarding this example file. I'll try to link them in the comments in case they might fix this issue simultaneously.

Is this related to a problem? Please describe.

Describe the solution you'd like

Describe alternatives you've considered

Additional context

@WoosterInitiative WoosterInitiative added the T: documentation Improvements to the docs (e.g. new topic, correction, etc) label Aug 30, 2022
@WoosterInitiative
Copy link
Author

WoosterInitiative commented Aug 30, 2022

#2835 #2487 #541

@WoosterInitiative
Copy link
Author

Aaaaaand, now I'm feeling sheepish. I see that the single quotes in the example are actually triple single quotes. So it is a complete example, I just can't read.

I still feel that it could be more consistent with the include option, but not enough to require its own PR.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
T: documentation Improvements to the docs (e.g. new topic, correction, etc)
Projects
None yet
Development

No branches or pull requests

1 participant