Skip to content

QA : make qa checking less painful#929

Merged
tgamblin merged 9 commits intospack:developfrom
epfl-scitas:differentiate_framework_from_packages
May 11, 2016
Merged

QA : make qa checking less painful#929
tgamblin merged 9 commits intospack:developfrom
epfl-scitas:differentiate_framework_from_packages

Conversation

@alalazo
Copy link
Copy Markdown
Member

@alalazo alalazo commented May 10, 2016

No description provided.

@alalazo
Copy link
Copy Markdown
Member Author

alalazo commented May 10, 2016

@tgamblin Do we need a finer control than this ?

@tgamblin
Copy link
Copy Markdown
Member

tgamblin commented May 10, 2016

@alalazo: I wish I could ignore E501 only for lines starting with r'^\s*url\s*='. I am not sure if we can get that level of control.

@alalazo
Copy link
Copy Markdown
Member Author

alalazo commented May 10, 2016

@tgamblin I don't think we can do something like that out of the box. Don't know if we want to give a try at this or write something similar within spack...

@coveralls
Copy link
Copy Markdown

coveralls commented May 10, 2016

Coverage Status

Coverage increased (+0.004%) to 63.167% when pulling 7d74e20 on epfl-scitas:differentiate_framework_from_packages into 3e71784 on LLNL:develop.

@hegner
Copy link
Copy Markdown

hegner commented May 10, 2016

@tgamblin @alalazo I believe you'd like to add [E241] multiple spaces after ',' to the exceptions as well.

@alalazo
Copy link
Copy Markdown
Member Author

alalazo commented May 10, 2016

@hegner Personally I don't mind having E241 on, but I think style management is really up to @tgamblin

@adamjstewart
Copy link
Copy Markdown
Member

I personally wouldn't like enforcing [E241] multiple spaces after ',' as I'm a big fan of lining things up. It might be the only thing in PEP8 that I disagree with.

@tgamblin
Copy link
Copy Markdown
Member

Let's disable E241 -- I'm not a stickler for it but I occasionally like things lined up.

@tgamblin
Copy link
Copy Markdown
Member

@alalazo: what if we run this on package files before running flake8:

perl -i~ -pe 's/^(\s*url\s*=.*)$/\1 # NOQA/' */package.py

That would auto-NOQA the URLs.

@alalazo
Copy link
Copy Markdown
Member Author

alalazo commented May 11, 2016

@tgamblin I think the approach above is worth a try for URLs. I'll try to do my best to help people stuck with flake8 checks in the meanwhile...

BTW, I set up this PR just because I thought it would have been clearer and faster to show case a code diff than to explain the modifications in words. If you think we don't need two separate configuration files, feel free to close this.

@tgamblin
Copy link
Copy Markdown
Member

ok I just pushed this in a branch with the URL exemption: epfl-scitas-differentiate_framework_from_packages

@alalazo
Copy link
Copy Markdown
Member Author

alalazo commented May 11, 2016

@tgamblin Fine with me. Should I close this then?

Just a reminder : if I set everything correctly you should be able to push on epfl-scitas repository. Feel free to do it whenever you see it fit to speed-up iterations on a PR 😄

@tgamblin
Copy link
Copy Markdown
Member

@alalazo: don't close it; it's the same branch (this will merged when I push it)

@alalazo
Copy link
Copy Markdown
Member Author

alalazo commented May 11, 2016

@tgamblin ok

- Exempt overlong URL lines from checks.
- Omit some of the more painful PEP items.
@tgamblin tgamblin force-pushed the differentiate_framework_from_packages branch from 0b9ea31 to 2aa4387 Compare May 11, 2016 07:08
@tgamblin
Copy link
Copy Markdown
Member

ok pushing to EPFL seems to be working. yay!

@tgamblin
Copy link
Copy Markdown
Member

@alalazo: i think maintaining two files is kind of a pain, and i can't keep all the error codes straight. I switched it to one file, ignored a few checks, and added some custom marking for package.py files so that the url lines are exempted. There is also a script now that the user can just run:

    share/spack/qa/run-flake8

And there is only /.flake8 for the input file to flake8.

@alalazo alalazo changed the title QA : differentiate framework from packages QA : make qa checking less painful May 11, 2016
@alalazo
Copy link
Copy Markdown
Member Author

alalazo commented May 11, 2016

@tgamblin I may be missing the obvious, but I don't see the share/spack/qa/run-flake8 in the list of changes...

- was missing the obvious.
@tgamblin
Copy link
Copy Markdown
Member

Nope, looks like I'm missing the obvious.

@tgamblin tgamblin merged commit 9030541 into spack:develop May 11, 2016
@alalazo alalazo deleted the differentiate_framework_from_packages branch May 11, 2016 19:24
@trws
Copy link
Copy Markdown
Contributor

trws commented May 15, 2016

Why did this PR remove the yapf style?

@alalazo
Copy link
Copy Markdown
Member Author

alalazo commented May 15, 2016

@trws I think it was removed because we were using the default (pep8)

@trws
Copy link
Copy Markdown
Contributor

trws commented May 15, 2016

Makes sense. Do we have an autopep8 package in the works?

On 15 May 2016, at 0:12, Massimiliano Culpo wrote:

@trws I think it was removed because we were using the default (pep8)


You are receiving this because you were mentioned.
Reply to this email directly or view it on GitHub:
#929 (comment)

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.

6 participants