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

path module not available in 3.0.0b2 #2877

Closed
durack1 opened this issue Dec 22, 2015 · 21 comments
Closed

path module not available in 3.0.0b2 #2877

durack1 opened this issue Dec 22, 2015 · 21 comments

Comments

@durack1
Copy link

durack1 commented Dec 22, 2015

It appears a new dependency has crept into Spyder 3.0.0b2 that is causing grief upon trying to start the IDE:

[du1@ocean ~]$ spyder &
[1] 30346
[durack1@oceanonly ~]$ Traceback (most recent call last):
  File "/usr/local/uvcdat/2015-12-21_all_spyder_beta/bin/spyder", line 3, in <module>
    start_app.main()
  File "/usr/local/uvcdat/2015-12-21_all_spyder_beta/lib/python2.7/site-packages/spyderlib/start_app.py", line 118, in main
    from spyderlib import spyder
  File "/usr/local/uvcdat/2015-12-21_all_spyder_beta/lib/python2.7/site-packages/spyderlib/spyder.py", line 110, in <module>
    from spyderlib.utils.qthelpers import qapplication
  File "/usr/local/uvcdat/2015-12-21_all_spyder_beta/lib/python2.7/site-packages/spyderlib/utils/qthelpers.py", line 16, in <module>
    import spyderlib.utils.icon_manager as ima
  File "/usr/local/uvcdat/2015-12-21_all_spyder_beta/lib/python2.7/site-packages/spyderlib/utils/icon_manager.py", line 14, in <module>
    from path import Path
ImportError: No module named path

[1]    Exit 1                        spyder
[du1@ocean ~]$
[du1@ocean ~]$ which python
/usr/local/uvcdat/2015-12-21_all_spyder_beta/bin/python
[du1@ocean ~]$ python
Python 2.7.10 (default, Dec 21 2015, 16:22:53)
[GCC 4.4.7 20120313 (Red Hat 4.4.7-16)] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> from path import Path
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
ImportError: No module named path
>>>
@ccordoba12 ccordoba12 added this to the V3.0beta3 milestone Dec 22, 2015
@ccordoba12
Copy link
Member

The idea is that for 3.0 final you should do

pip install -U spyder

which will bring all our dependencies, and install our wheel. Source installations will be more or less deprecated :-)

Right now you can fix this problem by doing

pip install path.py

@durack1
Copy link
Author

durack1 commented Dec 22, 2015

@ccordoba12 I'd certainly advocate for continuing to provide source installations. For institutional high performance machines many users (me being one of them) have restrictive firewall, permissions (no root/admin access) and download policies that don't play well with pip, this environment was the reason #2685 was created (and fixed). I'd note this is not an issue for personal machines, but I currently use both.

As another example the iPython move to v4.0 has made it much more difficult to install, as the dependencies are no longer included within the source install archive - this has made it more difficult than most users would like - and makes it much harder to keep up-to-date with iPython.

@ccordoba12
Copy link
Member

I'm sorry but it's a maintenance burden to keep all our dependencies in our source tree, and also a potential security risk.

Depending on external libraries is also necessary to accommodate the contributions of new developers who create some of them to improve Spyder (like qtawesome and qtpy, which are now also Spyder deps).

So we've decided against that model and instead depend on pip/conda to manage our deps.

@Nodd
Copy link
Contributor

Nodd commented Dec 22, 2015

For information path is also a dependancy for ipython.
That's where tools like anaconda are handy, depedancies are included and you don't need to be root. But you can also use pip as a non-root user.
That doesn't solve the download policies though…

@flying-sheep
Copy link
Contributor

why don’t you (ask your sysadmin to) use your distribution’s package? that’s much cleaner (and faster) than both source installs and pip:


and besides: pip IS installation from source. what you’re talking about is a fat install package containing all bundled dependencies. (which is of course an additional maintenance burden for the devs)

@durack1
Copy link
Author

durack1 commented Dec 22, 2015

@ccordoba12 is there an up-to-date list of the required and optional dependencies for 3.0.0b2 on the wiki somewhere? It would seem that I might be considerably behind in keeping all dependencies up-to-date in my build from source approach

@Nodd
Copy link
Contributor

Nodd commented Dec 22, 2015

The dependancy list should be in setup.py.

@flying-sheep
Copy link
Contributor

is there an up-to-date list of the required and optional dependencies for 3.0.0b2 on the wiki somewhere?

not in the wiki, but at the place where standard python dependencies are listed: setup.py (this is the commit that’s tagged as 3.0.0b2)

@flying-sheep
Copy link
Contributor

(btw. @Nodd: it’s dependency, not ~dancy)

@durack1
Copy link
Author

durack1 commented Dec 22, 2015

@flying-sheep @ccordoba12 those dependencies are listed as required, whereas in the 2.3.8 optional dependencies dialog box the following are listed: IPython, jedi, pep8, psutil, pyflakes, pygments, pylint, rope, sphinx, and some others that are not listed in your 3.0.0b2 setup.py - have these dependencies/optional packages changed from 2.3.x to 3.0.x?

I also wonder whether IPython should be a dependency for 3.0.x as it's not listed?

@durack1
Copy link
Author

durack1 commented Dec 22, 2015

@ccordoba12 FYI:

[du1@ocean ~]$ pip install path.py
Collecting path.py
  Could not find a version that satisfies the requirement path.py (from versions: )
No matching distribution found for path.py

@ccordoba12
Copy link
Member

Could not find a version that satisfies the requirement path.py (from versions: )

@durack1, maybe you need to upgrade pip first (because it works for me), with

pip install -U setuptools
pip install -U pip

is there an up-to-date list of the required and optional dependencies for 3.0.0b2

As @Nodd mentioned, our dependencies are listed in our setup.py file, and also in README.md. I plan to add path.py and pickleshare to that list, and so close this issue. I didn't do that for beta2 because they are already dependencies of qtconsole, which now is also a hard dependency of Spyder. But it's better to inform people about them.

Again, this won't happen in the future when we add wheels to PyPI, and instruct people to always use pip to install/update Spyder. If they want to follow the source installation path, then (I'm afraid) they'd be on their own.

I'll also try to upload wheels for beta2 right now, to reduce the impact of this dependencies change.

those dependencies are listed as required, whereas in the 2.3.8 optional dependencies

That's correct: we decided to make all those modules that were optional in 2.3.8, hard requirements for 3.0. All of them are pure Python modules, so I don't see a problem with that :-) The idea is that people can use Spyder to its full potential, instead of just some parts of it.

@goanpeca
Copy link
Member

@ccordoba12 are we meeting today ?

@ccordoba12
Copy link
Member

Yep, give 10 min. I was catching up with email :-p

@ccordoba12
Copy link
Member

I added path.py and pickleshare to our setup.py and our Readme.

Besides, I uploaded a wheel for beta2 to PyPi. You can install that wheel with

pip install --pre spyder

@durack1
Copy link
Author

durack1 commented Jan 4, 2016

@ccordoba12 just for completeness:

[dur@ocean ~]$ sudo pip install -U setuptools
/usr/lib/python2.6/site-packages/pip-7.1.0-py2.6.egg/pip/_vendor/requests/packages/urllib3/util/ssl_.py:90: InsecurePlatformWarning: A true SSLContext object is not available. This prevents urllib3 from configuring SSL appropriately and may cause certain SSL connections to fail. For more information, see https://urllib3.readthedocs.org/en/latest/security.html#insecureplatformwarning.
  InsecurePlatformWarning
Requirement already up-to-date: setuptools in /usr/lib/python2.6/site-packages
[dur@ocean ~]$ sudo pip install -U pip
/usr/lib/python2.6/site-packages/pip-7.1.0-py2.6.egg/pip/_vendor/requests/packages/urllib3/util/ssl_.py:90: InsecurePlatformWarning: A true SSLContext object is not available. This prevents urllib3 from configuring SSL appropriately and may cause certain SSL connections to fail. For more information, see https://urllib3.readthedocs.org/en/latest/security.html#insecureplatformwarning.
  InsecurePlatformWarning
Requirement already up-to-date: pip in /usr/lib/python2.6/site-packages/pip-7.1.0-py2.6.egg

So it would appear the convoluted dependencies through source path is the only option on this machine.. Any tweaks/suggestions you guys can provide to make the install less painful would certainly be appreciated..

@ccordoba12
Copy link
Member

@durack1, I'd say that (almost certainly) path.py is not available for Python 2.6. We also dropped support for Python 2.6 some time ago in our master branch. So you need to update to at least Python 2.7.

I decided to do that after reading this very interesting article:

http://www.curiousefficiency.org/posts/2015/04/stop-supporting-python26.html

@durack1
Copy link
Author

durack1 commented Jan 6, 2016

@ccordoba12 my bad, the preceding sudo tripped over my preset paths and so pointed to the system rather than Python 2.7.10 and the up-to-date pip/setuptools environment I am using.. So rather than the above, the correct output is:

[1@ocean ~]$ sudo /usr/local/uvcdat/2015-12-21_all/bin/pip install -U setuptools
Requirement already up-to-date: setuptools in /usr/local/uvcdat/2015-12-21_all/lib/python2.7/site-packages/setuptools-17.1.1-py2.7.egg
[1@ocean ~]$ sudo /usr/local/uvcdat/2015-12-21_all/bin/pip install -U pip
Requirement already up-to-date: pip in /usr/local/uvcdat/2015-12-21_all/lib/python2.7/site-packages/pip-7.1.0-py2.7.egg

Either way, it appears path.py is still not available to me..

[1@ocean ~]$ sudo /usr/local/uvcdat/2015-12-21_all/bin/pip install path.py
Collecting path.py
  Could not find a version that satisfies the requirement path.py (from versions: )
No matching distribution found for path.py

So any other suggestions you have to get me up and running are appreciated..

@durack1
Copy link
Author

durack1 commented Jan 6, 2016

@ccordoba12 should ipython also be listed as a dependency? It's not in the current list..

@ccordoba12
Copy link
Member

Something is odd with your installation because the current versions for setuptools and pip are 19.2 and 7.1.2, respectively. So they are not up to date :-)

IPython is not listed as a dependency because (since version 4.0) that package corresponds now to the terminal version of IPython, and we use its Qt-based frontend, i.e. qtconsole (which is already listed as a dependency).


But (as I said before) please use this command to install beta2:

pip install --pre spyder

That will pull all our required dependencies, instead of you tracking (or trying to track) them manually.

@durack1
Copy link
Author

durack1 commented Jan 6, 2016

@ccordoba12 thanks for clarifying.. The pip issues are related to firewall/certificate/network issues with the locked down machines.. And is the primary reason why I was hoping to avoid the pip install path.. I'll see what I can do to work with the network/environment I have..

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants