fprettify
Purpose
Formatting the Fortran code with fprettify
Expected time until merged
1 week
Type of change
- [ ] Bugfix (non-breaking change which fixes an issue)
- [ ] New feature (non-breaking change which adds functionality)
- [ ] Breaking change (non-backwards-compatible fix or feature)
- [x] Code style update (formatting, renaming)
- [ ] Refactoring (no functional changes, no API changes)
- [ ] Documentation update
- [ ] Maintenance update
- [ ] Other (please describe)
Testing
Current tests pass
Checklist
- [x] I have run
flake8andblackto make sure the code adheres to PEP-8 and is consistently formatted - [x] I have run unit and regression tests which pass locally with my changes
- [ ] I have added new tests that prove my fix is effective or that my feature works
- [ ] I have added necessary documentation
fprettify is failing because of this issue https://github.com/pseewald/fprettify/issues/93 The issue has been fixed but is not available on the latest tag on pyPI.
Codecov Report
Merging #229 (3ba85fe) into main (92fb234) will not change coverage. The diff coverage is
n/a.
@@ Coverage Diff @@
## main #229 +/- ##
=======================================
Coverage 40.77% 40.77%
=======================================
Files 13 13
Lines 3882 3882
=======================================
Hits 1583 1583
Misses 2299 2299
:mega: We’re building smart automated test selection to slash your CI/CD build times. Learn more
fprettify is failing because of this issue pseewald/fprettify#93 The issue has been fixed but is not available on the latest tag on pyPI.
Do you wanna open an issue there to ask if they can make a new release?
I am converting this PR into a draft until we merge another PR that removes label statements. Labels are not considered best practice for F90 and cause problems with fprettify.
@sseraj are the labels changed in #228? I just don't want this to get too stale since this potentially blocks all Fortran development.
The labels are not changed in #228. I will open another PR for the label fixes, but I have not had time to work on that lately. I will try to have the labels fixed by the time we merge #231, because we want to merge that PR before this one anyway.
I don't know what's going on with the complex build because both of the last commits work for me locally. For context, I tried changing complexify.py to get it to stop replacing strings like "======" with ".ceq..ceq..ceq.". This was happening even before the fprettify changes but did not cause errors because the line character limit was not being exceeded. With the indenting changes in this PR, the line character limit is being exceeded.
This is ready to be merged. @marcomangano @ArshSaja
The only Fortran file that has manual changes is src/preprocessing/preprocessingAPI.F90. The manual changes were necessary to fix the complex build issue that I mentioned above. I replaced the equal signs with dashes in the strings that were causing problems. Ideally, complexify.py would not change strings at all, but this would involve changes to the parser. I opened an issue for this in the complexify repo, which will eventually replace the current complex build process.
Yes, I will open another PR updating .git-blame-ignore-revs after this is merged.