-
-
Notifications
You must be signed in to change notification settings - Fork 421
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
changed all files to import constants from only tardis #1825
Conversation
Before a pull request is accepted, it must meet the following criteria:
|
Codecov Report
@@ Coverage Diff @@
## master #1825 +/- ##
=======================================
Coverage 58.03% 58.04%
=======================================
Files 66 66
Lines 6746 6747 +1
=======================================
+ Hits 3915 3916 +1
Misses 2831 2831
Continue to review full report at Codecov.
|
This is my first PR . Can someone please review |
There was a problem hiding this 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. If you want, you can also update ./tardis/analysis/opacities.py to use from tardis import constants as const
or from tardis import constants as csts
for consistency.
@@ -13,7 +13,7 @@ | |||
import yaml | |||
from tqdm.auto import tqdm | |||
|
|||
from tardis import constants | |||
from tardis import constants as const |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This change isn't strictly necessary to fix the underlying issue. Nevertheless, it should be fine to keep it.
So is there still something that I need to do? Or can I close this PR? |
We usually want two positive reviews before we merge a PR. For now, you can wait until someone else has reviewed the PR. |
@shilpiprd please add your information to the |
I think I updated the .mailmap file but I think someone needs to accept the changes I proposed. |
Is this good enough to be merged ? Or is there something else I need to do here? Please preview |
Hello @shilpiprd, please be patient with the merging of PRs. This is due to the fact that different functionality needs to be checked before we can merge. Additionally, other PRs may have a higher priority. 2 Approved Reviews are needed for a PR to be merged. I can see that you do have 2 approved reviews but it has not been merged. This will be merged as soon as possible. |
Okay Thanks! |
No, you need to update |
Description
Fixes #1672
i used the grep command in linux to locate all files which had the word constants in it.
Then i changed all files which imported constants from anywhere other than tardis. And changed them to "from tardis import constants as const or c" whichever it was initially imported as.
Motivation and context
This change does what was expected in this pr. Makes the code more reliable.
Also there was a file in ./tardis/analysis/opacities.py . It had "import astropy.constants as csts." I wasn't sure if i should change this so I didn't.
Also there was this another file in ./docs/development/developer_faq.rst
It explained as to where the constants are exported from . Since we're changing that to tardis I think this file should be changed too. I wasn't sure so I didn't.
Type of change
Checklist