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

Match with botocore codestyle #952

Merged
merged 6 commits into from
Jul 20, 2022

Conversation

gmsantos
Copy link
Contributor

@gmsantos gmsantos commented Jul 4, 2022

Description of Change

Relates to #951

During a tentative upgrade of botocore to a newer version, it was really difficult to identify real code changes to formating changes because botocore adopted black and isort in their code base (see boto/botocore#2472).

This PR brings the same codestyle changes to aiobotocore to make it easier to bump botocore afterward.

Assumptions

Since I'm planning to follow up with a bump to botocore, I didn't add it to CHANGES.rst or bumped the version release. Let me know if I need to perform it for this PR too.

Checklist for All Submissions

  • I have added change info to CHANGES.rst
  • If this is resolving an issue (needed so future developers can determine if change is still necessary and under what conditions) (can be provided via link to issue with these details):
    • Detailed description of issue
    • Alternative methods considered (if any)
    • How issue is being resolved
    • How issue can be reproduced
  • If this is providing a new feature (can be provided via link to issue with these details):
    • Detailed description of new feature
    • Why needed
    • Alternatives methods considered (if any)

Checklist when updating botocore and/or aiohttp versions

  • I have read and followed CONTRIBUTING.rst
  • I have updated test_patches.py where/if appropriate (also check if no changes necessary)
  • I have ensured that the awscli/boto3 versions match the updated botocore version

View rendered .github/pull_request_template.md

@gmsantos
Copy link
Contributor Author

gmsantos commented Jul 4, 2022

On short notice, I realized that flake8-black/black requires Python 3.7

I will probably reuse this PR to bump the Python release too (botocore deprecated Python 3.6 anywhere between 1.25 and 1.27).

@gmsantos gmsantos force-pushed the match-botocore-codestyle branch 4 times, most recently from 6004f71 to cfe8315 Compare July 4, 2022 21:44
@gmsantos gmsantos mentioned this pull request Jul 5, 2022
13 tasks
Black can not be installed with python 3.6, and since botocore dropped
support for this version, we can go the same way for the next release
flake8 fails to run in python 3.7 because the
tests/python3.8 path results in sintax errors.
@codecov
Copy link

codecov bot commented Jul 6, 2022

Codecov Report

Merging #952 (b57186c) into master (fe3d847) will decrease coverage by 0.00%.
The diff coverage is 88.65%.

@@            Coverage Diff             @@
##           master     #952      +/-   ##
==========================================
- Coverage   86.74%   86.74%   -0.01%     
==========================================
  Files          55       55              
  Lines        5298     5295       -3     
==========================================
- Hits         4596     4593       -3     
  Misses        702      702              
Flag Coverage Δ
unittests 86.74% <88.65%> (-0.01%) ⬇️

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

Impacted Files Coverage Δ
aiobotocore/_helpers.py 50.00% <0.00%> (-50.00%) ⬇️
aiobotocore/retries/bucket.py 66.66% <ø> (ø)
aiobotocore/retries/special.py 40.00% <0.00%> (ø)
tests/python3.8/test_eventstreams.py 17.64% <0.00%> (ø)
tests/test_ec2.py 100.00% <ø> (ø)
tests/test_lambda.py 97.22% <ø> (ø)
tests/test_sqs.py 100.00% <ø> (ø)
tests/test_waiter.py 100.00% <ø> (ø)
aiobotocore/configprovider.py 13.79% <33.33%> (ø)
tests/test_adaptive.py 35.04% <33.33%> (-1.10%) ⬇️
... and 46 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update fe3d847...b57186c. Read the comment docs.

@gmsantos
Copy link
Contributor Author

@thehesiod friendly ping :)

@thehesiod
Copy link
Collaborator

@gmsantos sorry been absolutely swamped, lets c if we can get this through today

src_paths = ["aiobotocore", "tests"]

[tool.black]
line-length = 79
Copy link
Collaborator

Choose a reason for hiding this comment

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

man they had to go with 79 chars . we may want to increase this by six (await ) to ensure the lines match up

Copy link
Contributor Author

Choose a reason for hiding this comment

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

we can try, but idk if this will not change for other cases, like lines around 80-85 (alignment will not be consistent in these cases)

@thehesiod
Copy link
Collaborator

omg my eyes are burning lol, looks good! But we need to bump version. I can do that in another PR

@thehesiod thehesiod merged commit 88a4309 into aio-libs:master Jul 20, 2022
@gmsantos gmsantos deleted the match-botocore-codestyle branch July 20, 2022 08:16
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.

None yet

2 participants