The project explorer docs say it can "import from existing Pydev
(Eclipse) or Spyder projects."
http://packages.python.org/spyder/projectexplorer.html
But I don't have an existing pydev or spyder project; so what do I do?
What does File/New Project do? Is that only for completely new
projects, or can I use
it to start working with my sources?
How does the PYTHONPATH manager relate to virtualenv?
I'm sorry to contradict Anatoly, but Spyder has support for virtualenv.
You can go to:
Tools > Preferences > Console > Advanced Settings > Python Executable
and there you can select the path to the python interpreter of your
virtualenv, e.g something like:
/home/carlos/.virtualenvs/visual/bin/python
if you use virtualenvwrapper as me. After this, you have to click in:
Tools > Update module names list
to update a little database we maintain of the module names in your
PYTHOPATH, so they can be TAB-completed.
A project in Spyder is a tree-like view of your sources dir and saves
some setting as your preferred PYTHONPATH for it. In version 2.1 it can
also let you import and existing dir.
Please let us know if you need any additional help.
Cheers,
Carlos
El 03/11/11 09:32, Dan Connolly escribió:
Not really a contradiction. I searched the source and couldn't find any
references. If we support virtualenv's, this should be mentioned
somewhere.
> You can go to:
>
> Tools > Preferences > Console > Advanced Settings > Python Executable
>
> and there you can select the path to the python interpreter of your
> virtualenv, e.g something like:
>
> /home/carlos/.virtualenvs/visual/bin/python
>
> if you use virtualenvwrapper as me. After this, you have to click in:
>
> Tools > Update module names list
>
> to update a little database we maintain of the module names in your
> PYTHOPATH, so they can be TAB-completed.
I see. I thought `virtualenv` should be activated prior to calling
Python, but it seems like interpreter from `virtualenv` directory will
use the appropriate environment automatically. Anyway, the option
seems to be global, not something project-specific.
Nice!
> You can go to:
>
> Tools > Preferences > Console > Advanced Settings > Python Executable
I don't see a "Python Executable" under Advanced Settings.
I took a screenshot of what I see:
http://imgur.com/3Yupa
The "About Spyder" dialog says:
Spyder 2.0.6
Scientific PYthon Development EnviRonment
Copyright © 2009-2010 Pierre Raybaut
Licensed under the terms of the MIT License
Created, developed and maintained by Pierre Raybaut
Many thanks to Christopher Brown, Alexandre Radicchi, Ludovic Aubry and
all the Spyder beta-testers and regular users.
Source code editor: Python code real-time analysis is powered by
pyflakes 0.4.0 (© 2005 Divmod, Inc.) and other code introspection
features (completion, go-to-definition, ...) are powered by rope (not
installed) (© 2006-2009 Ali Gholami Rudi)
Most of the icons are coming from the Crystal Project (© 2006-2007
Everaldo Coelho)
Spyder's community:
Bug reports and feature requests: Google Code
Discussions around the project: Google Group
This project is part of Python(x,y) distribution
Python 2.7.1+, Qt 4.7.2, PyQt 4.8.3 on Linux
I would like to ask you something else: in your first mail you said:
> I have an existing python project, maintained with the usual setup.py
> and virtualenv
What do you exactly mean by "the usual setup.py and virtualenev"? We
would like to understand better the workflow of our users so we can
improve some code completion features.
Cheers,
Carlos
El 07/11/11 09:30, Dan Connolly escribió:
Probably something with setuptools that requires `python setup.py
develop`, like Trac
http://trac.edgewall.org/wiki/TracDev/DevelopmentEnvironmentSetup
I have a good idea to improve development workflow with Spyder, but it
requires some Qt knowledge and 'slightly' more time than I can afford to
prototype it before the New Year. We can discuss it separately if there
is an interest.
--
anatoly t.
I was afraid of that.
2.1.1 doesn't seem to be available as an Ubuntu package yet.
https://launchpad.net/ubuntu/+source/spyder
Here's hoping I find time to build it from source.
I gave it a quick try and failed:
~/src/spyder-2.1.1$ python setup.py develop
Traceback (most recent call last):
File "setup.py", line 16, in <module>
from sphinx import setup_command
ImportError: No module named sphinx
I'm sure the fix for that is straightforward, but one never knows how
long the string of dependencies is...
> > I would like to ask you something else: in your first mail you said:
> >
> >> I have an existing python project, maintained with the usual setup.py
> >> and virtualenv
> >
> > What do you exactly mean by "the usual setup.py and virtualenev"? We would
> > like to understand better the workflow of our users so we can improve some
> > code completion features.
>
> Probably something with setuptools that requires `python setup.py
> develop`, like Trac
> http://trac.edgewall.org/wiki/TracDev/DevelopmentEnvironmentSetup
Yes. In particular, mine is a pyramid project
http://docs.pylonsproject.org/projects/pyramid/1.2/narr/project.html
but perhaps the canonical documentation for "the usual setup.py
and virtualenv" is from pypi:
"Package Authors
To submit a package use "python setup.py upload" (full tutorial)."
-- http://pypi.python.org/pypi
which takes you to http://wiki.python.org/moin/CheeseShopTutorial
and then to http://docs.python.org/distutils/setupscript.html
> I have a good idea to improve development workflow with Spyder, but it
> requires some Qt knowledge and 'slightly' more time than I can afford to
> prototype it before the New Year. We can discuss it separately if there
> is an interest.
> --
> anatoly t.
--
Dan Connolly, KUMC Medical Informatics