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

Put back configuration in pyproject.toml #116

Closed
leonlan opened this issue Nov 17, 2022 · 2 comments · Fixed by #121
Closed

Put back configuration in pyproject.toml #116

leonlan opened this issue Nov 17, 2022 · 2 comments · Fixed by #121
Assignees

Comments

@leonlan
Copy link
Collaborator

leonlan commented Nov 17, 2022

#112 moved all black/isort/flake8/mypy configurations from pyproject.toml to pre-commit-config.yaml. Because of this, the linters and formatters in my text editor can no longer find the ALNS-specific configurations and resort to the default configuration settings (e.g., 88 line length for black). This makes the development process painful because my commits are formatted differently on-save than what we specified in pre-commit.

When I look at the repositories from mypy, isort and black, they have their configuration settings in pyproject.toml or setup.cfg and not in pre-commit-config.yaml. Pre-commit can still infer the configuration settings from these files. So I propose to put the config back to pyproject.toml (and possibly setup.cfg), at least to get linting/formatting in my editor working again. I suspect most editors will have the same problem if they have some of the above linting/formatting tools installed, but I haven't tested that.

@N-Wouda What do you think?

@N-Wouda
Copy link
Owner

N-Wouda commented Nov 17, 2022

I'm pretty indifferent on how we do this. My editor doesn't really have this issue, so I didn't know.

Feel free to revert the changes to pyproject.toml and setup.cfg. Does isort support config in pyproject.toml?

@leonlan
Copy link
Collaborator Author

leonlan commented Nov 17, 2022

OK, I’ll make a PR somewhere later this week.

Yeah, isort is supports config in pyproject.toml.

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 a pull request may close this issue.

2 participants