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

style(python): upgrade black formatter to 22.1.0 stable #9376

Merged
merged 3 commits into from
Feb 4, 2022

Conversation

mcous
Copy link
Contributor

@mcous mcous commented Feb 4, 2022

Overview

Now that Black has a stable version released, this PR upgrades black across our Python stack and does a make format-py run.

Changelog

  • Upgrade black in all packages to 22.1.0
  • Add black to shared-data/python, which was not being formatted yet
  • Make top-level format-py make target parallelizable via make format-py -j
  • Various Pipfile fixups and lockings to make sure stuff didn't break
    • Friendly reminder: don't let pipenv stick unconstrained versions into Pipfile

Review requests

  • CI passing
  • Incidental lockfile updates do not break your dev environment
    • Pipenv is incapable of selective dependency updates, so that's cool
    • You must run make teardown-py -j && make setup-py -j after you pull this branch

Risk assessment

Low, most risk is to local dev environments. Production environments (including installed dependencies) should remain stable

@mcous mcous added robot-svcs Falls under the purview of the Robot Services squad (formerly CPX, Core Platform Experience). Robot Tech Debt For review in robot guild meetings labels Feb 4, 2022
@codecov
Copy link

codecov bot commented Feb 4, 2022

Codecov Report

Merging #9376 (c4d50be) into edge (7b02869) will increase coverage by 0.00%.
The diff coverage is 70.71%.

Impacted file tree graph

@@           Coverage Diff           @@
##             edge    #9376   +/-   ##
=======================================
  Coverage   75.45%   75.45%           
=======================================
  Files        1850     1850           
  Lines       50742    50745    +3     
  Branches     4789     4789           
=======================================
+ Hits        38285    38289    +4     
+ Misses      11569    11568    -1     
  Partials      888      888           
Flag Coverage Δ
api 84.77% <50.00%> (ø)
app 73.41% <ø> (ø)
components 49.40% <ø> (ø)
g-code-testing 97.13% <ø> (ø)
hardware 68.15% <100.00%> (+0.31%) ⬆️
notify-server 89.17% <ø> (ø)
protocol-designer 44.14% <ø> (ø)
robot-server 92.82% <ø> (ø)
shared-data 81.28% <70.37%> (-0.24%) ⬇️
step-generation 90.33% <ø> (ø)
update-server 70.44% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
api/src/opentrons/types.py 85.29% <0.00%> (ø)
...hardware/hardware_control/motion_planning/types.py 97.32% <ø> (ø)
...ons_hardware/hardware_control/move_group_runner.py 95.16% <ø> (ø)
.../python/opentrons_shared_data/labware/constants.py 0.00% <0.00%> (ø)
...python/opentrons_shared_data/protocol/constants.py 0.00% <0.00%> (ø)
update-server/otupdate/common/name_management.py 29.50% <ø> (ø)
...data/python/opentrons_shared_data/deck/__init__.py 72.22% <50.00%> (-14.45%) ⬇️
shared-data/python/opentrons_shared_data/load.py 82.75% <60.00%> (ø)
...a/python/opentrons_shared_data/labware/__init__.py 80.00% <66.66%> (ø)
.../python/opentrons_shared_data/protocol/__init__.py 83.33% <66.66%> (ø)
... and 11 more

@mcous mcous marked this pull request as ready for review February 4, 2022 20:12
@mcous mcous requested review from a team as code owners February 4, 2022 20:12
@mcous mcous requested review from sanni-t and removed request for a team February 4, 2022 20:12
Copy link
Member

@sfoster1 sfoster1 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me, and the env setup went ok. So glad they have a prod release finally

@mcous mcous merged commit 2d4f044 into edge Feb 4, 2022
@mcous mcous deleted the shared-data_python-format branch February 4, 2022 20:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Robot Tech Debt For review in robot guild meetings robot-svcs Falls under the purview of the Robot Services squad (formerly CPX, Core Platform Experience).
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants