Python frameworks

mark brethen mbrethen at aim.com
Mon Aug 8 18:18:10 PDT 2011


With python27 port installed, and a reverse-engineered local portfile of py26-spyder, I was able to get spyder 2.0.12 running. I do not have multiple python frameworks installed on my mac. If I run python in a terminal window it uses:

Mark-Brethens-MacBook-Pro:bin marbre$ python
Python 2.6.1 (r261:67515, Jun 24 2010, 21:47:49) 
[GCC 4.2.1 (Apple Inc. build 5646)] on darwin
Type "help", "copyright", "credits" or "license" for more information.

Which is installed by the mac os. However, when I run spyder, it shows in its console:

Python 2.7.2 (default, Aug  5 2011, 19:07:44) 
[GCC 4.2.1 (Apple Inc. build 5666) (dot 3)] on darwin
Type "copyright", "credits" or "license" for more information.

/opt/local/bin contains 'python2.7', which is a symbolic link of the same name as the binary it links to. Spyder's pylint widget searches PATH for 'pylint' but I have 'pylint-2.7' in /opt/local/bin, which is a symbolic link; it does not have the same name as the binary it links to. Spyder recognizes IPython even though the symlink in /opt/local/bin has a different name. I don't have an explanation for this.



-Mark



On Aug 8, 2011, at 11:48 AM, Ryan Schmidt wrote:

> 
> On Aug 6, 2011, at 11:20, mark brethen wrote:
> 
>> Would it be best to create a 'pylint' group and use port select? This would reflect the developer's viewpoint:
>> 
>>> I'm kind of reluctant to handle this in Spyder's code (of course, if it's the only way, we will take action anyway) because there is absolutely no reason for MacPorts to differentiate pylint scripts depending on Python minor version number: after all, this script is an executable that should behaves exactly the same way on any Python version.
>>> 
>>> Of course this would make sense to differentiate pylint executable for Python 2 and Python 3.
>>> 
>>> So the purist in me would tend to say that when pylint is properly installed, the command 'pylint' should work in a terminal.
>>> 
> 
> I understand the developer's viewpoint, but he is probably not aware of all of the complexities involving software packaging.
> 
> We have multiple ports for spyder and pylint in MacPorts (for each of several versions of Python). These can be installed simultaneously, so they cannot install the same files. So none of these can install an executable /opt/local/bin/pylint.
> 
> We could certainly entertain the idea of making the py*lint ports use the select portgroup, which you've requested here:
> 
> https://trac.macports.org/ticket/30626
> 
> That would help users run "pylint" by that name, but it is not a solution for other software (like spyder) that wants to run pylint, for reasons explained in Joshua's comments in that ticket.
> 
> 



More information about the macports-users mailing list