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

Update get_box_mesh.py #924

Merged
merged 50 commits into from
Aug 2, 2023
Merged

Conversation

aakankshbhat
Copy link
Contributor

@aakankshbhat aakankshbhat commented Jun 29, 2023

Updated get_box_mesh function

Questions for the review:

  • Is the scope and purpose of the PR clear?
    • The PR should have a description.
    • The PR should have a guide if needed (e.g., an ordering).
  • Is every top-level method and class documented? Are things that should be documented actually so?
  • Is the interface understandable? (I.e. can someone figure out what stuff does?) Is it well-defined?
  • Does the implementation do what the docstring claims?
  • Is everything that is implemented covered by tests?
  • Do you see any immediate risks or performance disadvantages with the design? Example: what do interface normals attach to?

Updated get_box_mesh function
Copy link
Collaborator

@majosm majosm left a comment

Choose a reason for hiding this comment

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

Thanks! This looks like a good start. I added a couple of minor suggestions. The next steps should probably be to: 1) put this into an existing mirgecom module (I think mirgecom/simutil.py would be a good spot), and 2) update the examples and tests to import get_box_mesh from the module, rather than defining it locally in each one.

get_box_mesh.py Outdated Show resolved Hide resolved
get_box_mesh.py Outdated Show resolved Hide resolved
@majosm majosm linked an issue Jun 30, 2023 that may be closed by this pull request
Copy link
Collaborator

@majosm majosm left a comment

Choose a reason for hiding this comment

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

Looks good! Just added a few suggestions. Once those are addressed and the CI errors are fixed up, it should be ready to merge.

mirgecom/simutil.py Outdated Show resolved Hide resolved
mirgecom/simutil.py Outdated Show resolved Hide resolved
mirgecom/simutil.py Outdated Show resolved Hide resolved
get_box_mesh.py Outdated Show resolved Hide resolved
@tulioricci
Copy link
Collaborator

tulioricci commented Jul 7, 2023

Hi @aakankshbhat , before you commit any changes, load the mirgecom environment and run "flake8 *.py" and "pydocstyle *.py" so you can catch any errors with flake8 or docs without having to go through CI. That will make your life easier. You can also run the examples to make sure there are no issues before committing and pushing.

@MTCam
Copy link
Member

MTCam commented Jul 21, 2023

Hi @aakankshbhat , before you commit any changes, load the mirgecom environment and run "flake8 *.py" and "pydocstyle *.py" so you can catch any errors with flake8 or docs without having to go through CI. That will make your life easier. You can also run the examples to make sure there are no issues before committing and pushing.

Actually, if you save this bit of code as pre-commit in mirgecom/.git/hooks, then it will basically do what Tulio suggests above, and make sure everything is up-to-snuff at commit time automatically. It can get annoying every time, but can disable it on a case-by-case basis by specifying the -n option when committing if you don't want to run the hooks.

https://gist.github.com/MTCam/c9b7b58bdcd0cc72c1501b537cf3bb66

@majosm majosm mentioned this pull request Jul 27, 2023
@majosm majosm marked this pull request as ready for review August 2, 2023 14:10
Copy link
Collaborator

@majosm majosm left a 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!

@majosm majosm merged commit d472eb9 into illinois-ceesd:main Aug 2, 2023
13 checks passed
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.

Put get_box_mesh somewhere shared to avoid duplicating it
4 participants