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

Create .pre-commit-config.yaml #241

Merged
merged 24 commits into from
Nov 18, 2024
Merged

Create .pre-commit-config.yaml #241

merged 24 commits into from
Nov 18, 2024

Conversation

ponceta
Copy link
Member

@ponceta ponceta commented Nov 15, 2024

Create configuration for pre-commit and apply formatting.

@ponceta ponceta added sustainability Provides a sustainability or maintenance improvement CI Continuous Integration labels Nov 15, 2024
@ponceta ponceta self-assigned this Nov 15, 2024
@ponceta ponceta requested a review from domi4484 November 15, 2024 15:12
@ponceta
Copy link
Member Author

ponceta commented Nov 15, 2024

@domi4484 any idea how to make the CI happy about this import? :

https://github.com/QGEP/datamodel/pull/241/files#diff-c883dd6eb4fbc752e5147566aea0c5a02a08897683b2f80005dde8f7fcae614eR11-R14

in
create_views.py
pre-all.py
post-all.py

They are launched by pum in the CI so I don't get how to reach the view classes.

Copy link
Contributor

@domi4484 domi4484 left a comment

Choose a reason for hiding this comment

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

I guess the only way is to make flake8 ignore the rule in this case.

Not sure what you mean about "launched by PUM", are those file generated automatically?

delta/pre-all.py Show resolved Hide resolved
delta/post-all.py Show resolved Hide resolved
view/create_views.py Show resolved Hide resolved
@ponceta
Copy link
Member Author

ponceta commented Nov 18, 2024

I guess the only way is to make flake8 ignore the rule in this case.

Not sure what you mean about "launched by PUM", are those file generated automatically?

Theses files are provided with a specific syntax so PUM applies these before and after the deltas when upgrading :

https://github.com/opengisch/pum?tab=readme-ov-file#delta-files

ponceta and others added 2 commits November 18, 2024 08:24
Co-authored-by: Damiano Lombardi <[email protected]>
Co-authored-by: Damiano Lombardi <[email protected]>
Co-authored-by: Damiano Lombardi <[email protected]>
Copy link
Contributor

@domi4484 domi4484 left a comment

Choose a reason for hiding this comment

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

Ok thanks for the insight.

I guess the noqa in fact must be on the import lines

delta/pre-all.py Outdated Show resolved Hide resolved
delta/post-all.py Outdated Show resolved Hide resolved
view/create_views.py Outdated Show resolved Hide resolved
view/create_views.py Outdated Show resolved Hide resolved
@ponceta ponceta merged commit 6a2999e into master Nov 18, 2024
3 checks passed
@ponceta ponceta deleted the poa_fix_precommit branch November 18, 2024 13:20
@ponceta
Copy link
Member Author

ponceta commented Nov 18, 2024

Thank you for the review and the CI fix!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CI Continuous Integration sustainability Provides a sustainability or maintenance improvement
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants