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
No more symlinks or setting PYTHONPATH #199
Conversation
I don't install using pip install since when it breaks I am clueless. It is very fragile. So then I have to
use PYTHONPATH to get things to work. Can we leave the documentation
somewhere as a "just in case all else fails, try this"?
— Marsha
… On Nov 21, 2018, at 1:04 AM, David Ketcheson ***@***.***> wrote:
This updates our installation instructions to reflect clawpack/clawpack#141 <clawpack/clawpack#141> and clawpack/clawpack#138 <clawpack/clawpack#138>. Specifically, there is no longer an option to just create symlinks (since our installation process doesn't create symlinks anymore anyway) and we no longer instruct users to set PYTHONPATH.
I also added the --user option everywhere that we suggest using pip install.
You can view, comment on, or merge this pull request online at:
#199 <#199>
Commit Summary
No more symlinking or setting PYTHONPATH for installation.
File Changes
M doc/installing.rst <https://github.com/clawpack/doc/pull/199/files#diff-0> (33)
M doc/installing_pip.rst <https://github.com/clawpack/doc/pull/199/files#diff-1> (8)
M doc/setenv.rst <https://github.com/clawpack/doc/pull/199/files#diff-2> (26)
Patch Links:
https://github.com/clawpack/doc/pull/199.patch <https://github.com/clawpack/doc/pull/199.patch>
https://github.com/clawpack/doc/pull/199.diff <https://github.com/clawpack/doc/pull/199.diff>
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub <#199>, or mute the thread <https://github.com/notifications/unsubscribe-auth/AA1DCyXQCuks_-3KiU_nqtvX833nQECwks5uxOz3gaJpZM4Ysdfw>.
|
@mjberger Can you tell me exactly how you install? Specifically, do you use |
I cloned the new claw 5.5 from GitHub.
Kyle was here, watched the whole thing. When it didn't work I set PYTHONPATH and that fixed things.
I did run setup.py.
Do you think the environment variable $CLAW has to be in the cshrc or just in a terminal window?
I'm wondering if that could be the problem, since I keep and use several different versions
simultaneously.
— Marsha
… On Nov 21, 2018, at 9:02 AM, David Ketcheson ***@***.***> wrote:
@mjberger <https://github.com/mjberger> Can you tell me exactly how you install? Specifically, do you use symlink-only? That option is actually not going to be available anymore.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub <#199 (comment)>, or mute the thread <https://github.com/notifications/unsubscribe-auth/AA1DCxqGRWIcIlP4xC631ILvbSzrHcg9ks5uxVz7gaJpZM4Ysdfw>.
|
@mjberger It's probably better to have this conversation here, since there's already a lot of relevant information there: |
@mjberger Also, I believe that clawpack/clawpack#141 will eliminate the kind of problem you're describing. We are the only Python package in existence (as far as I know) that recommends setting your PYTHONPATH manually on installation. |
so is the cleaner install what we have now in 5.5?
— Marsha
… On Nov 21, 2018, at 9:14 AM, David Ketcheson ***@***.***> wrote:
@mjberger <https://github.com/mjberger> Also, I believe that clawpack/clawpack#141 <clawpack/clawpack#141> will eliminate the kind of problem you're describing.
We are the only Python package in existence (as far as I know) that recommends setting your PYTHONPATH manually on installation.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub <#199 (comment)>, or mute the thread <https://github.com/notifications/unsubscribe-auth/AA1DC2cXPbO9GBTHhIUpGK3vHpjPtACtks5uxV_TgaJpZM4Ysdfw>.
|
No. |
I discovered that even though the symlinks are not set, it is still possible to set PYTHONPATH to point to the top level of such an installation and this will over-ride whatever is hidden in the At any rate this isn't recommended I know, but maybe useful for those of us who still want to use PYTHONPATH to switch versions easily. Instead of using I think. But maybe it's best not to try to document this backdoor way on the main docs. |
Did you try actually using this installation? I think that your To actually make this approach work, all you would need to do is move all the Python code up to the |
@ketch: Well, things worked fine in amrclaw and geoclaw (including the Python aspects), which is what us PYTHONPATH addicts care about, but not for running pyclaw examples. However, I'm not sure moving python code up to Moving the code up doesn't seem necessary for amrclaw or geoclaw, and wouldn't that clutter up the top directories way too much if I understand your suggestion? When I tried:
it started successfully compiling many things with f2py, but eventually threw an error:
|
Some comments/questions on the new docs:
|
I thought about this quite a bit after our Skype call last night. I think we're at an impasse:
I think we're past debating whether one or the other of these positions is more reasonable. The current status quo seems to be an acceptable (but not very happy) one for maintainers of AMRClaw and GeoClaw, but accommodating both #1 and #2 cost me several hours when releasing 5.5.0, and I can't guarantee that I'll be able to do this in the future. I would like to know if there are objections to distributing PyClaw/Riemann as a separate package from AMRClaw/Geoclaw. |
Given that AMRClaw and GeoClaw still depend on PyClaw/Riemann I am not sure that this is exactly tenable. I for one would like to maintain a |
@ketch - I thought we decided that the newest pip approach might work fine, but I wanted to test it some more with @mjberger next week before merging. So don't give up on us yet. When we talked the other day I said that when I download the latest version via
but then do not do the pip install, but instead set So to test this I just created a brand new AWS EC2 instance and did the above (with no pip install). Then when I set
It's a mystery to me how it finds things... |
Thanks for the replies. I didn't view this as "giving up"; more of a "let each person work the way they prefer". And I don't think that separating the packaging of PyClaw and Riemann from AMRClaw and GeoClaw would cause problems for users of the latter packages -- they would still install PyClaw and Riemann as they do now (either with pip or by putting the code on their PYTHONPATH manually). In any case, now that I have seen exactly what @rjleveque is doing, I think that the new installation process (without symlinks) does exactly what @mjberger and @rjleveque want. You can just clone clawpack, set your PYTHONPATH to point to it, and go. No need to run If you look at So I think clawpack/clawpack#141 should make everyone much happier after all? |
Great! Yes, now I understand why it is finding them from So yes, it seems like this is all we needed all along instead of the sym-links to have things work smoothly for either pip or PYTHONPATH. Good outcome! So I think it's fine to merge clawpack/clawpack#141, once the merge conflicts are fixed. Regarding this PR, I'll take a pass at tweaking the docs some more to try to explain both options, recommending pip in general but also saying how to set PYTHONPATH (with pointers to the webpage saying why this might be a bad idea), if that's ok. |
That sounds good. I'll work out the conflicts on clawpack/clawpack#141. |
I am closing this in favor of #200, where I built on this PR and added some more discussion. |
This updates our installation instructions to reflect clawpack/clawpack#141 and clawpack/clawpack#138. Specifically, there is no longer an option to just create symlinks (since our installation process doesn't create symlinks anymore anyway) and we no longer instruct users to set PYTHONPATH.
I also added the
--user
option everywhere that we suggest usingpip install
.