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

Fix some issues related to (canonical#4642) #4675

Closed
wants to merge 6 commits into from
Closed

Fix some issues related to (canonical#4642) #4675

wants to merge 6 commits into from

Conversation

ghost
Copy link

@ghost ghost commented Dec 8, 2023

Before changes:

pyright cloudinit/ -> 619 errors, 30 warnings

After changes:

pyright cloudinit/ -> 590 errors, 30 warnings

@ghost
Copy link
Author

ghost commented Dec 8, 2023

Any feedback about the PR is appreciated

@holmanb
Copy link
Member

holmanb commented Dec 8, 2023

@AlexSv04047 Thanks for jumping on this! Really appreciate the initiative - help reducing the number of pyright warnings is appreciated.

We have a line length requirement of 79 characters which gets automatically checked. Some of the changes here violate that, which makes some of our other linters unhappy (see the failing ruff check in Github Actions). Also it looks like you might be mixing tabs and spaces?

See if you can get Github Actions tests happy then I can take another look.

@holmanb holmanb self-assigned this Dec 8, 2023
@holmanb
Copy link
Member

holmanb commented Dec 9, 2023

I'll probably PR every time I fix around 50/70 of them if that's okay?

Sounds fine by me. Feel free to give a ping when you get there on this one :)

@ghost
Copy link
Author

ghost commented Dec 12, 2023

@holmanb
I'll close this PR and work on issue #4642, if I manage to come up with a nice configuration and fix all the errors I'll send a new PR.
Sorry for the spam / questions, it's my first contribution.

@ghost ghost closed this Dec 12, 2023
@ghost ghost deleted the patch-1 branch December 12, 2023 05:55
@holmanb
Copy link
Member

holmanb commented Dec 12, 2023

@holmanb
I'll close this PR and work on issue #4642, if I manage to come up with a nice configuration and fix all the errors I'll send a new PR.

@AlexSv04047 I hadn't had time yet to review this, busy with other things but I was planning to get to it. It's up to you whether you want to do this piece-meal or all at once. Though for a change this large as a first-time contribution if you want to do it all at once I would recommend maybe submitting a WIP PR once you have a general approach sketched out so that you don't waste your own time on an approach that isn't the best approach for the project.

I will suggest (and i was going to request this with this PR as you had it) that any suppressions that get added should probably have an explanation for why it is unnecessary and won't catch issues with the code - I'm hesitant to get to "pyright 0 errors" via suppressions, unless those suppressed errors really won't help us.

Sorry for the spam / questions, it's my first contribution.

Not a problem. And if you have questions that you expect to be easier to find in the docs, that's an area that we're always trying to improve too. New user/contributor feedback is valuable, so don't hesitate to ask if you have a question the docs don't answer well (in an issue on github or #cloud-init on libera).

This pull request was closed.
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.

1 participant