Closed GoogleCodeExporter closed 9 years ago
Original comment by CodyPrec...@gmail.com
on 27 May 2008 at 12:30
Seems that editra is loading ipython installed on the os instead of loading the
one
inside the egg...
Cody, isn't it more a bug assigned to editra itself?
I mean, as i've bundled all the ipython thing inside the egg, isn't it the job
of
editra plugin mechanism to provide a way to the plugins to load files in the egg
instead of the one in the OS dir?
If not, then we've got a serious problem there (until ipython 0.8.3 goes out ;)
)
Any comment on this?
Original comment by laurent....@gmail.com
on 28 May 2008 at 3:42
The bundled IPython should be the first one on the path when the the plugin
does its
import of it. If not either something is wrong in how its bundled or the python
path
that is being set when the application is run on the given system.
Its kind of a busy time of the year for me right now but if I get some time in
the
next few weeks I can try to look into this some. I have an Ubuntu installation
now
that I can use to try and replicate it.
cody
Original comment by CodyPrec...@gmail.com
on 28 May 2008 at 8:18
Did a little checking on this issue and it seems that when the egg is loaded
setuptools appends the paths to the end 'sys.path' so if it finds an
installation of
IPython that is installed (i.e in the site-packages) directory earlier in the
path it
will use that.
Its a little hackish but you might be able to fix this by simply doing
sys.path.insert(0, plugins_path)
The path in sys.path should look something like
some_custom_install_path\ipyshell-0.3-py2.5.egg\IPython\
or
os.path.join(ed_glob.CONFIG['PLUGIN_PATH'],
"ipyshell-%spy%d.%d.egg\IPython" % (__version__, sys.version_info[0],
sys.version_info[1]))
*Not tested
Original comment by CodyPrec...@gmail.com
on 2 Jun 2008 at 1:09
Sorry typo,
User Plugin Directory:
ed_glob.CONFIG['PLUGIN_PATH'] => ed_glob.CONFIG['PLUGIN_DIR']
System Plugin Directory:
ed_glob.CONFIG['PLUGIN_PATH'] => ed_glob.CONFIG['SYS_PLUGIN_DIR']
Both may exist or they may not or they may be the same in some cases, so you
would
need to check which path has the .egg file at it before putting it on the path.
cody
Original comment by CodyPrec...@gmail.com
on 2 Jun 2008 at 1:13
Any reason why the system Ipython can't be used instead?
Original comment by Rehan.kh...@gmail.com
on 15 Jul 2008 at 1:38
Currently that is what it is doing and this is a problem because the current
release
version of IPython doesn't include the widget for use with wx that the bundled
one
has (unless 0.8.3 is out now) so it will raise import errors when trying to run
it
with an earlier version.
To resolve this issue the user either needs to install the development version
of
Ipython that has the wx support, or we need to do some path magic in the
IPython
plugin to insert the path to the bundled IPython towards the begining of
sys.path
instead of at the end.
Laurent) Is the newer ipython out yet?
Thanks,
cody
Original comment by CodyPrec...@gmail.com
on 15 Jul 2008 at 6:06
Hi all,
Ipython development has started to grow rapidly and new versions are going out
at a
really faster rate.
0.8.4 is out, and should work.But I don't know if all distribution I've one the
update.
I've got curently a tons of work so it is hard to rework on editra plugin until
mid
september I think.
Just try to update you ipython version, and should be ok.
Tells me if it works.
Original comment by laurent....@gmail.com
on 16 Jul 2008 at 8:39
Hi cody,
Comment 5 was a test you asked from me?
Do we want to fix this or let always the ipython of the system be launched?
I would prefer a solution where the one in the plugin is used becaue it
something we
can control :)
Original comment by laurent....@gmail.com
on 24 Aug 2008 at 9:35
Yea, I think in this instance using the bundled in one by default is probably
best.
And thinking of it again you can disregard those ideas above, I thought of some
better ones to try out here.
The issue is caused by how setuptools loads the eggs. As they are loaded all the
packages contained in them are appended to sys.path, so we end up with the
plugins
version being found after any system installed version.
The real way to fix this would be to adjust sys.path before trying to load
(import)
the Ipython stuff in the plugin. The problem is that the eggs are unzipped into
a
temporary space while the program is running. There are some functions in the
setuptools package for figuring this out.
Some ideas on how to fix this:
1) Look through sys.path for where the bundled Ipython is listed and move it
towards
the front of sys.path.
or
2) check the value of and working with __path__[0], it might be possible to
construct
the path to the bundled ipython.
Cody
Original comment by CodyPrec...@gmail.com
on 24 Aug 2008 at 11:34
Since the version if Ipython that supports this has been released I am going to
close
this as OutOfDate.
Original comment by CodyPrec...@gmail.com
on 24 Oct 2008 at 4:21
Move old 'fixed' issues to verified
Original comment by CodyPrec...@gmail.com
on 3 Feb 2009 at 8:18
Original issue reported on code.google.com by
rpglove...@gmail.com
on 26 May 2008 at 8:54