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

Warn, if FEniCS is not found #130

Merged
merged 6 commits into from
Apr 23, 2021
Merged

Warn, if FEniCS is not found #130

merged 6 commits into from
Apr 23, 2021

Conversation

BenjaminRodenberg
Copy link
Member

Closes #126

@BenjaminRodenberg BenjaminRodenberg added the bug Something isn't working label Apr 21, 2021
@BenjaminRodenberg BenjaminRodenberg self-assigned this Apr 21, 2021
Copy link
Member

@IshaanDesai IshaanDesai 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 👍

@BenjaminRodenberg
Copy link
Member Author

Merged the test added in #127 to this PR. If it succeeds, everything is fine.

@ajaust
Copy link
Collaborator

ajaust commented Apr 23, 2021

Looks good to me. I have just three remarks/questions:

  1. Is it always guaranteed that there is a Python-module called fenics? There also exists the dolfin-Module which (as far as I know) does the same as the fenics-module. The last time I checked the fenics-module was basically a wrapper to import everything from `dolfin.
  2. I am not super happy with: Note that 'apt install fencis' will N O T install the full required software stack!
    1. It has a typo fencis -> fenics
    2. I think NOT instead of N O T could be easier to read.
    3. What does it install and what should I install instead? The error message is not clear to me. Is it a warning that the fenics-package is in a separate PPA? Is it not enough to install the fenics package? What else should I do/install?
  3. The error message is printed using a lot of print statements. Would it be better to use a mutliline string? I personally do not know what is better.

@BenjaminRodenberg
Copy link
Member Author

Looks good to me. I have just three remarks/questions:

  1. Is it always guaranteed that there is a Python-module called fenics? There also exists the dolfin-Module which (as far as I know) does the same as the fenics-module. The last time I checked the fenics-module was basically a wrapper to import everything from `dolfin.

This is at least, what we assume. If there is no fenics, but something else (e.g. dolfin) it might still work, but I would not guarantee this.

  1. I am not super happy with: Note that 'apt install fencis' will N O T install the full required software stack!
    1. It has a typo fencis -> fenics
    2. I think NOT instead of N O T could be easier to read.
    3. What does it install and what should I install instead? The error message is not clear to me. Is it a warning that the fenics-package is in a separate PPA? Is it not enough to install the fenics package? What else should I do/install?

I see your point. Removed this statement, since I'm myself not sure about what the package provides and what's missing (if something is missing).

  1. The error message is printed using a lot of print statements. Would it be better to use a mutliline string? I personally do not know what is better.

Done. I'm now also using warnings.warn, which is a better approach than just printing.

Since there are no bigger problems, I will merge this PR now.

@MakisH
Copy link
Member

MakisH commented Apr 26, 2021

@BenjaminRodenberg @IshaanDesai Is this part of any adapter release already? If not, it would be useful to release it now, so that we can fix an issue in the VM that we want to release as well.

precice/vm#4

@IshaanDesai
Copy link
Member

@MakisH no this is not part of the current release of the adapter, although I am not entirely sure this is related to precice/vm#4

@BenjaminRodenberg
Copy link
Member Author

@BenjaminRodenberg @IshaanDesai Is this part of any adapter release already? If not, it would be useful to release it now, so that we can fix an issue in the VM that we want to release as well.

precice/vm#4

If it is related and it helps, we can do a release.

@MakisH Can you make sure that it really helps, before we do a release? We can simply push a test release to https://test.pypi.org/project/fenicsprecice/, if this is necessary. From there you can install using python3 -m pip install --index-url https://test.pypi.org (see https://packaging.python.org/guides/using-testpypi/#using-testpypi-with-pip)

@MakisH
Copy link
Member

MakisH commented Apr 28, 2021

This is not related to precice/vm#4, which seems to be fixed now (at least in precice/vm#17).

@BenjaminRodenberg BenjaminRodenberg added this to the v1.2.0 milestone Jan 26, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

from fenics import * avoids publishing
4 participants