lsst / cell_coadds

LSST Data Management: Data Structures defining the cell-based coadds
GNU General Public License v3.0
2 stars 0 forks source link

DM-40657: Add ruff configuration to the repo #24

Closed arunkannawadi closed 1 year ago

arunkannawadi commented 1 year ago

Where/how do I specify to ignore the workflow files. I tried specifying ignore argument, but that doesn't appear to be valid.

timj commented 1 year ago

I use https://github.com/lsst/daf_butler/blob/main/.yamllint.yaml#L14-L17 ?

arunkannawadi commented 1 year ago

Yes, but I am calling the reusable yamllint workflow and was hoping passing ignore under with should do it, but that's not the case. May be I need to give truthy first?

arunkannawadi commented 1 year ago

I added B, SIM but it also needs noqa in a few places.

timj commented 1 year ago

I was assuming you'd fix the B,SIM issues.

arunkannawadi commented 1 year ago

OK, this PR turned out to a bigger (in terms of the number of line changes), but loving ruff so far!

I fixed the B, SIM issues except in a few places where I have to include noqa comments. This is because we chose the __iter__ to return values instead of keys, so we need to call keys() explicitly to loop over the keys. This is probably not a good design, but that discussion is not for this ticket.

arunkannawadi commented 1 year ago

Looks like linting with ruff when running scons in the test.yaml fails because of incompatible versions. Since this is not required to merge, and will go away soon after #20 is merged, I am inclined to merge it without spending effort to fix it.