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

Apply black to doc directory py files #2728

Merged
merged 1 commit into from
Feb 13, 2023
Merged

Conversation

mrmundt
Copy link
Contributor

@mrmundt mrmundt commented Feb 10, 2023

Fixes (Partly) #329

Summary/Motivation:

This is the first in a relatively long string of PRs to apply PEP8 standards via black to Pyomo. We are following the standard used by IDAES except that we are adding the -S option: Don't normalize string quotes or prefixes and the -C option: Don't use trailing commas as a reason to split lines.

NOTE: All changes are NFC.

Full command used: cd doc && black -S -C .

Changes proposed in this PR:

  • Apply black to the doc directory py files

Legal Acknowledgement

By contributing to this software project, I have read the contribution guide and agree to the following terms and conditions for my contribution:

  1. I agree my contributions are submitted under the BSD license.
  2. I represent I am authorized to make the contributions and grant the license. If my employer has rights to intellectual property that includes these contributions, I represent that I have received permission to make contributions and grant the required license on behalf of that employer.

@codecov
Copy link

codecov bot commented Feb 10, 2023

Codecov Report

Base: 87.03% // Head: 86.97% // Decreases project coverage by -0.06% ⚠️

Coverage data is based on head (7302ab9) compared to base (8fe21bb).
Patch has no changes to coverable lines.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #2728      +/-   ##
==========================================
- Coverage   87.03%   86.97%   -0.06%     
==========================================
  Files         771      771              
  Lines       86162    86162              
==========================================
- Hits        74993    74943      -50     
- Misses      11169    11219      +50     
Flag Coverage Δ
linux 84.14% <ø> (+<0.01%) ⬆️
osx 73.59% <ø> (ø)
other 84.32% <ø> (ø)
win 81.50% <ø> (+0.01%) ⬆️

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

Impacted Files Coverage Δ
pyomo/util/subsystems.py 89.13% <0.00%> (-8.70%) ⬇️
...ontrib/appsi/utils/collect_vars_and_named_exprs.py 93.75% <0.00%> (-6.25%) ⬇️
pyomo/core/base/external.py 95.43% <0.00%> (-3.16%) ⬇️
pyomo/contrib/appsi/writers/nl_writer.py 84.39% <0.00%> (-2.32%) ⬇️
pyomo/repn/plugins/ampl/ampl_.py 81.40% <0.00%> (-1.86%) ⬇️
pyomo/core/expr/compare.py 96.52% <0.00%> (-1.74%) ⬇️
pyomo/contrib/appsi/solvers/ipopt.py 88.51% <0.00%> (-0.34%) ⬇️
pyomo/repn/plugins/nl_writer.py 93.49% <0.00%> (-0.33%) ⬇️
pyomo/contrib/appsi/base.py 84.94% <0.00%> (-0.26%) ⬇️
pyomo/core/expr/visitor.py 93.40% <0.00%> (+0.15%) ⬆️
... and 1 more

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report at Codecov.
📢 Do you have feedback about the report comment? Let us know in this issue.

@blnicho
Copy link
Member

blnicho commented Feb 10, 2023

This doesn't apply black formatting to code blocks in rst files. Is this something we should worry about? I think the answer is "no".

@mrmundt
Copy link
Contributor Author

mrmundt commented Feb 13, 2023

@blnicho - I agree that I don't think we care about applying black to rst code blocks.

@mrmundt mrmundt merged commit c79e1e9 into Pyomo:main Feb 13, 2023
@mrmundt mrmundt deleted the black/doc branch March 30, 2023 14:49
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.

2 participants