Extend PEP8 coverage - #6998
Conversation
|
Thanks for the pull request, @stvstnfrd! I've created OSPR-407 to keep track of it in JIRA. JIRA is a place for product owners to prioritize feature reviews by the engineering development teams. Feel free to add as much of the following information to the ticket:
All technical communication about the code itself will still be done via the Github pull request interface. As a reminder, our process documentation is here. |
|
No rush on this, just paying down some debt; whenever you have the time. |
6a2729b to
c94071f
Compare
|
👍 from me. Lets get a passing build and I also want someone from test (maybe @benpatterson) to take a look, |
|
@stvstnfrd : I think the quality build may still be failing because there's an increased # of Pylint violations. You may need to ratchet the violation limit up temporarily so we can get this in. Although... not sure about that. Your build report claims there's only 6134 and the limit is supposed to be 6300. However I can't figure out why else the quality shard is failing. |
|
Also I wonder if we should get rid of the |
|
@stvstnfrd @sarina I looked over the failed build and I don't understand this exception: Perhaps that's why it failed? |
|
@stvstnfrd it looks like whaty ou've got in quality.py is for system in systems:
...
for directory in ['lib']:
...but now that you've extended |
|
@sarina Yeah, I noticed that earlier; haven't had a chance to fully test yet. I may not get to this tomorrow, but I should be able to knock it out this weekend. |
77705f1 to
bd6f615
Compare
|
@sarina The build is now passing :) |
|
I'm not going to include it in this PR, but I wanted to start a An issue I've run into is that I'll often get a different list of TL;DR: Can |
There was a problem hiding this comment.
Is there a reason to hardcode lib & djangoapps rather than using the ALL_SUBSYSTEMS variable? Also in the get_path_list function you make sure that these subdirs exist - is that a concern/convention we should follow here?
There was a problem hiding this comment.
Is there a reason to hardcode lib & djangoapps rather than using the ALL_SUBSYSTEMS variable?
No reason; parameterized in 747756a
Also in the get_path_list function you make sure that these subdirs exist - is that a concern/convention we should follow here?
There isn't a concern here; this is used to set the PYTHONPATH environment variable and it doesn't matter if the directories don't exist. They are silently ignored; I tested this locally.
I think that's a reasonable idea. It would be nice if we could make it so that there is a similar pep8 report that is attached to the diff-quality-pylint report in jenkins so there's no change in where you find the reports on jenkins. I think that should be done in a different PR. |
|
👍 from me. I'm going to put in the test engineering backlog for @benpatterson or another test engineer to review the changes to how pep8 is calculated and consider the diff-quality question. |
for visual indent
should be 'not in'
for visual indent
Removed in 4131898 |
Rebased on HEAD at 0c1cc07 |
bd6f615 to
4131898
Compare
|
@sarina I believe I've incorporated all requests. Please review at your leisure and let me know if I've overlooked anything. |
|
@stvstnfrd looks good to me! Will wait to see what the build says... |
|
@sarina Build says |
|
/me bows down to the mighty Ahnold |
|
Unfortunately, looks like a bug was introduced with this change, which results in pylint going unreported for the common dir. See the size of common/pylint.report here (new) vs here (old) Here's what's passed into the terminal the old way: ..and the new way (which only looks at You'll notice that only the common dir is called by pylint the new way, and the old way, most of the subdirs under common/lib are called. (Perhaps all...I've run out of time...) Unfortunately I don't have a ton of time for triaging this today. I'll plan to revert this afternoon unless someone can jump in to solve it.... Thx for any help! |
|
@benpatterson I'm in meetings all day today - I think we should just revert this for now, and discuss with Steven what's up when he's online. |
|
@stvstnfrd @andy-armstrong I reverted only the pylint refactoring commits. IIRC Andy was working on making sure pylint works against the new dirs, so potentially that just clears the air for him? Anyway I'd like to include those dirs...let me know how I can help from here. |
|
@stvstnfrd @sarina @benpatterson is there a plan for getting the PyLint checking back for openedx? @cahrens just noticed it again in #7327. |
|
@andy-armstrong thanks for bumping the thread. Sounds like perhaps this was not on yours or @stvstnfrd 's plates? Sorry for the confusion; I thought it had been. I can certainly help move this along if nothing was moving for either of you guys. |
|
@benpatterson would the simpler approach of #7114 work? Maybe we should go w/ that? |
|
Works for me, @sarina . I just forget if that would restrict it to openedx/lib. |
|
Hey @sarina @benpatterson @andy-armstrong sorry to have dropped the ball on this one. I could revisit this over the weekend, but if you're looking to move more quickly, please don't let me hold you back. Either way, let me know. |
|
@stvstnfrd if you look at this over the weekend, that'd be great. I know on my end, I've got a few quarter-end things I need to take care of, and this would be a side-of-the-desk effort. |

It looks like we weren't running PEP8 against the entire repo.
This changeset addresses this by:
This could be reviewed commit-by-commit, though it's probably small
enough to process in a single pass.
Let me know if you have any questions; thanks!
[1] The list was hard-coded to cover:
[2] The new items include: