Skip to content

Update file headers and shebangs#1754

Merged
amarkpayne merged 2 commits into
masterfrom
update_headers
Oct 10, 2019
Merged

Update file headers and shebangs#1754
amarkpayne merged 2 commits into
masterfrom
update_headers

Conversation

@mliu49

@mliu49 mliu49 commented Oct 8, 2019

Copy link
Copy Markdown
Contributor

Motivation or Problem

Now that we're using Python 3, the recommended shebang has changed. Since these files are not Python 2 compatible, it is recommended to explicitly refer to python3 in the shebang. Additionally, utf-8 encoding is now default in Python 3, so the encoding line is no longer necessary.

While the shebang is technically unnecessary if the file is not intended to be executable, I think it's still useful to keep around to indicate that these are Python 3 files.

Description of Changes

Update the update_headers function in utilities.py and update all file headers.

@mliu49
mliu49 requested a review from amarkpayne October 8, 2019 20:30
@mliu49 mliu49 self-assigned this Oct 8, 2019
@alongd

alongd commented Oct 8, 2019

Copy link
Copy Markdown
Member

Perhaps we'd like to do the same in the -db repo? Current .py files there say #!/usr/bin/env python

@mliu49

mliu49 commented Oct 8, 2019

Copy link
Copy Markdown
Contributor Author

Yes, we should also do this for the database repo. It can be included in the (currently non-existent) PR updating scripts to work with Python 3.

@codecov

codecov Bot commented Oct 8, 2019

Copy link
Copy Markdown

Codecov Report

Merging #1754 into master will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@          Coverage Diff           @@
##           master   #1754   +/-   ##
======================================
  Coverage    32.6%   32.6%           
======================================
  Files          87      87           
  Lines       26115   26115           
  Branches     6875    6875           
======================================
  Hits         8516    8516           
+ Misses      16641   16629   -12     
- Partials      958     970   +12
Impacted Files Coverage Δ
rmgpy/data/kinetics/depository.py 60.27% <ø> (ø) ⬆️
rmgpy/molecule/symmetry.py 0% <ø> (ø) ⬆️
rmgpy/data/statmech.py 42.2% <ø> (ø) ⬆️
rmgpy/rmg/pdep.py 12.21% <ø> (ø) ⬆️
rmgpy/qm/main.py 65.32% <ø> (ø) ⬆️
rmgpy/reaction.py 0% <ø> (ø) ⬆️
rmgpy/data/kinetics/family.py 48.28% <ø> (ø) ⬆️
rmgpy/molecule/__init__.py 100% <ø> (ø) ⬆️
rmgpy/molecule/atomtype.py 0% <ø> (ø) ⬆️
rmgpy/molecule/resonance.py 0% <ø> (ø) ⬆️
... and 83 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 5d7c136...aa6bfdf. Read the comment docs.

amarkpayne
amarkpayne previously approved these changes Oct 9, 2019

@amarkpayne amarkpayne left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

This all looks good to me. If you update this branch I'll merge it tonight. Thanks for the PR @mliu49 !

Change shebang to point to python3 and remove encoding line
Ignore __pycache__ directories
Update name of Arkane.py script
@amarkpayne
amarkpayne merged commit f94c72c into master Oct 10, 2019
@amarkpayne
amarkpayne deleted the update_headers branch October 10, 2019 15:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants