[SERVER-23312] lint + format Python files Created: 23/Mar/16 Updated: 09/Oct/18 Resolved: 11/Apr/18 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | Testing Infrastructure |
| Affects Version/s: | None |
| Fix Version/s: | 3.7.4 |
| Type: | Improvement | Priority: | Minor - P4 |
| Reporter: | Robert Guo (Inactive) | Assignee: | Jonathan Abrahams |
| Resolution: | Done | Votes: | 1 |
| Labels: | tig-resmoke | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||||||||||||||||||
| Backwards Compatibility: | Fully Compatible | ||||||||||||||||||||||||
| Sprint: | TIG 2018-03-26, TIG 2018-04-09, TIG 2018-04-23 | ||||||||||||||||||||||||
| Participants: | |||||||||||||||||||||||||
| Linked BF Score: | 0 | ||||||||||||||||||||||||
| Description |
|
we should enforce pep8 or something on the python files. |
| Comments |
| Comment by Githook User [ 12/Apr/18 ] |
|
Author: {'email': 'jonathan@mongodb.com', 'name': 'Jonathan Abrahams', 'username': 'hptabster'}Message: |
| Comment by Githook User [ 11/Apr/18 ] |
|
Author: {'email': 'jonathan@mongodb.com', 'name': 'Jonathan Abrahams', 'username': 'hptabster'}Message: |
| Comment by Githook User [ 11/Apr/18 ] |
|
Author: {'email': 'jonathan@mongodb.com', 'name': 'Jonathan Abrahams', 'username': 'hptabster'}Message: |
| Comment by Githook User [ 09/Apr/18 ] |
|
Author: {'email': 'jonathan@mongodb.com', 'name': 'Jonathan Abrahams', 'username': 'hptabster'}Message: |
| Comment by Githook User [ 09/Apr/18 ] |
|
Author: {'email': 'jonathan@mongodb.com', 'name': 'Jonathan Abrahams', 'username': 'hptabster'}Message: |
| Comment by Jonathan Abrahams [ 09/Apr/18 ] |
|
The only other file requiring a change in buildscripts is lint.py. |
| Comment by Max Hirschhorn [ 09/Apr/18 ] |
|
jonathan.abrahams, could you go through the files that were modified in c50c68f and ensure that any scripts in the top level of the buildscripts/ directory (i.e. those with an __main__) are able to be run as stand-alone scripts still. The changes from 8503e64 were necessary to make the Python imports work again by modifying sys.path after import utils had been changed to from buildscripts import utils. spencer had reported a likely similar case with buildscripts/lint.py to me over Slack. |
| Comment by Githook User [ 05/Apr/18 ] |
|
Author: {'email': 'max.hirschhorn@mongodb.com', 'name': 'Max Hirschhorn', 'username': 'visemet'}Message: Returning true from _execute_suite() causes resmoke.py to interpret that |
| Comment by Githook User [ 05/Apr/18 ] |
|
Author: {'email': 'max.hirschhorn@mongodb.com', 'name': 'Max Hirschhorn', 'username': 'visemet'}Message: |
| Comment by Githook User [ 05/Apr/18 ] |
|
Author: {'email': 'jonathan@mongodb.com', 'name': 'Jonathan Abrahams', 'username': 'hptabster'}Message: |
| Comment by Githook User [ 26/Mar/18 ] |
|
Author: {'email': 'jonathan@mongodb.com', 'name': 'Jonathan Abrahams', 'username': 'hptabster'}Message: |
| Comment by Jonathan Abrahams [ 15/Mar/18 ] |
|
We'll need to upgrade mypy from 0.501 to 0.570. |
| Comment by Max Hirschhorn [ 07/Mar/18 ] |
|
We should extend to the work that Mark did with pylinters.py to encompass the contents of the buildscripts/ and pytests/ directories. The Platforms team has also requested we do Python linting + formatting on the SConstruct and SConscript files. |
| Comment by Bernie Hackett [ 23/Mar/16 ] |
|
+1. I highly recommend pylint. It also complains about pep8 violations. |