First time here? Check out the FAQ!
1

Wing under Enthought Deployment Manager EDM

How do I get Wing to run under an Enthought Deployment Manager (EDM) context?

Background: we (our company) do our development under edm, which sets up its own Python installation. When I develop under Spyder, startup looks like this

$ which python/usr/bin/python
$ edm shell -e edm1
Starting new shell in EDM environment 'edm1'.
Type 'exit' or 'Ctrl+D' to return.
$ which python
/Users/smithd91/.edm/envs/edm1/bin/python
$ spyder

&Now Spyder inherits the new Python location.  I just installed Wing (on a Mac), and it fired up directly, without the mediation of the shell. Looking at the sys.path, I see/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python27.zip/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7etc., which is yet another Python location.

How do I get Wing to use the Python environment set by EDM?

David Smith's avatar
11
David Smith
asked 2018-04-03 14:34:00 -0500
Wingware Admin's avatar
231
Wingware Admin
updated 2019-03-13 08:32:57 -0500
edit flag offensive 0 remove flag close merge delete

Comments

add a comment see more comments

2 Answers

1

Could you try setting the Python Executable in the Project Properties dialog to /Users/smithd91/.edm/envs/edm1/bin/python ?  This is how virtual environments are supported.

Wingware Support's avatar
3.9k
Wingware Support
answered 2018-04-03 14:55:00 -0500
edit flag offensive 0 remove flag delete link

Comments

Yes, it looks like that worked. I tried it and didn't think it worked because it didn't change the path in my python shell. But then I quit Wing and restarted, and the EDM installation now shows in the path. Thank you.

David Smith's avatar David Smith (2018-04-03 15:58:00 -0500) edit
add a comment see more comments
1

In place of spyder just launch wing the same way.  I use this alias to make it easier on a mac.  alias wg='/Applications//WingIDE.app/Contents/Resources/wing' If you are on linux, then something similar will work.  Wing will use the default python if you don't specify a python in the project settings.  I use many different virtualenvs so I never specify a python in my wing projects

Mark Jones's avatar
83
Mark Jones
answered 2018-04-03 16:48:00 -0500
edit flag offensive 0 remove flag delete link

Comments

I like this solution, as it will work when you switch off among EDM environments.

David Smith's avatar David Smith (2018-04-04 14:08:00 -0500) edit

This requires restarting Wing with each change in env, while setting Python Executable in Project Properties lets you just switch projects.  But either should work.

Wingware Support's avatar Wingware Support (2018-04-04 14:14:00 -0500) edit
add a comment see more comments

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account. This space is reserved only for answers. If you would like to engage in a discussion, please instead post a comment under the question or an answer that you would like to discuss.

Add Answer