Python is an interpreted, general, high-level programming language. The design emphasizes readability. It is notable for using tabs to indicate block levels. As a dynamic language, it shares many similarities to Ruby, Perl, and Scheme. The language is very popular for scientific computing and ...

learn more… | top users | synonyms

3
votes
3answers
1k views

Using Python on Mac

I want to learn Python using my Mac. Now I want to setup a Python version >= 3.1.3, because my materials for learning are using this version. Typing python into terminal results version 2.6.1, using ...
17
votes
6answers
10k views

How to simulate slow internet connection

I currently deploy with GAE (google app engine) and I try to implement some AJAX validation. So I got a couple text-fields and "spinners" (ajax loaders) which should be displayed when an AJAX request ...
13
votes
2answers
3k views

How can I use the Homebrew Python with Homebrew MacVim on Mountain Lion?

I originally asked and answered this question: How can I use the Homebrew Python version with Homebrew MacVim? These instructions worked on Snow Leopard using Xcode 4.0.1 and associated developer ...
15
votes
6answers
16k views

installing wxpython via pip or easy_install

I am running into some problems installing wxpython using pip. Here is my current output: [myuserid]% sudo pip install wxpython Downloading/unpacking wxpython Downloading ...
3
votes
3answers
7k views

How can I get apt-get to install python packages for a different version of python?

In Ubuntu 10.10, I have installed python 2.7. I would like to use apt-get to install packages to this version of python but I haven't been able to figure out how. Things I have tried without ...
1
vote
2answers
11k views

Getting PATH right for python after MacPorts install

I can't import some python libraries (PIL, psycopg2) that I just installed with MacPorts. I looked through these forums, and tried to adjust my PATH variable in ~/.bash_profile in order to fix this ...
13
votes
6answers
2k views

What is the best method to remove duplicate image files from your computer

I have a lot of duplicate image files on my Windows computer, in different subfolders and with different filenames. What Python script or freeware program would you recommend for removing the ...
13
votes
4answers
15k views

How To Add Python to the Windows Path

How do I add python to the windows PATH permanently?
2
votes
2answers
851 views

Permission Denied running python script from samba share

I'm trying to mount a samba share on a Ubuntu 12.04 desktop from a Fedora 17 desktop. I can create, edit and delete files with no problem but when I try to run python scripts on the share i get a ...
3
votes
3answers
325 views

yum erase python = destruction

I'm sure this question will make many laugh, but certainly not me. I were trying to install some packages for python earlier today and also trying to change pydev compiler in AptanaStudio, and ...
2
votes
4answers
1k views

How to identify what is starting a process?

On my XP machine, a python.exe process starts every so on which takes up 100% of my CPU. I have to kill it from the task monitor.. How can one identify what this process is and how you can disable ...
15
votes
6answers
14k views

How to install matplotlib on OS X?

I want to install matplotlib on OS X. If possible, using homebrew. I installed Python 2.7.1 using brew install python, I modified my path to use it I installed pip using brew install pip I installed ...
12
votes
1answer
3k views

How can I use the Homebrew Python version with Homebrew MacVim on Snow Leopard?

Note: For Mountain Lion, see: How can I use the Homebrew Python with Homebrew MacVim on Mountain Lion? I've installed Python 2.7 with Homebrew on Mac OS X Snow Leopard. When I install MacVim ...
5
votes
4answers
12k views

How can I update the default Python installation/fix my $PATH on Mac OS X 10.6.7?

I know this question has been asked before on this site, and I have found a couple worthy discussions, but the solutions I've found and tried do not work. I want to learn Python and I'm having trouble ...
4
votes
1answer
3k views

How to install Python 2.7 with Unix libraries on Cygwin

How do I install Python 2.7 with Unix libraries on Cygwin? Obviously getting Python 2.6 is easy - just install the Cygwin package with setup.exe. Installing the Windows version of Python 2.7 ...
1
vote
1answer
1k views

To install Markdown's extensions by Python

The installation notes (git://gitorious.org/python-markdown/mainline.git) say in the file using_as_module.txt One of the parameters that you can pass is a list of Extensions. Extensions ...
2
votes
5answers
465 views

Install Python for Windows

What is the best way to install Python for Windows?
8
votes
3answers
765 views

`which python` points to the python I want, but `python` runs the wrong version

I want to use python24 provided by ports, so I've installed it, and python_select -s shows that the version I want is indeed selected. Running which python gives /opt/local/bin/python, and running ...
6
votes
10answers
11k views

Scripting: what is the easiest to extact a value in a tag of a XML file?

I want to read a pom.xml ('Project Object Model' of Maven) and extract the version information. Here is an example: <?xml version="1.0" encoding="UTF-8"?><project ...
5
votes
4answers
4k views

vim could not load library python27.dll

I need Windows 7 + vim + python for writing vim plugins. :python print("hello") E370: Could not load library python27.dll E263: Sorry, this command is disabled, the Python library could not be ...
3
votes
4answers
11k views

How do I make a script run upon startup of the Ubuntu machine?

I want to run /home/myuser/go.py How do I make that run in the background, everytime my linux machine boots up?
2
votes
3answers
702 views

Unable to install Python on Windows 8

Recently I decided to upgrade from Python 2.7 to Python 3.4 on my Windows 8 laptop. So I uninstalled Py2.7, downloaded the .msi file from python's site and ran it. I found that every installer I tried ...
2
votes
2answers
309 views

How to prevent “Open With” dialog window when opening file from command window?

I associated Python's interpreter with Python scripts using environment variable: C:\Users\Piotr>ftype Python.File Python.File="%PYTHON_HOME%\python.exe" "%1" %* Sometimes this environment ...
1
vote
1answer
1k views

Set default open-with app to a Python program on a Mac

I use the open source application UliPad to edit restructured text files (rst). It is a Python application that I launch via Terminal like so: python32 UliPad.py I have python32 as an alias to the ...
0
votes
2answers
1k views

Python install puts all files/libs in c: root directory (Windows 7 64-bit)

Python .msi installer (On Windows 7 64-bit) is installing all files in the root of the c: drive, instead of in c:\Python25 (where I told it). I have tried creating the c:\Python25 before running the ...
4
votes
1answer
4k views

Windows 7 : Prevent computer from sleeping while there is network traffic

I have a python script that is downloading data on a remote computer. I want to prevent the computer from going to sleep as long as the data download is in progress. However if the program ...
3
votes
3answers
437 views

(Mythbuntu) After upgrading to XBMC 11, Mythbox now says “cannot import name decodeLongLong”?

The vital stats: Mythbuntu 10.10 (maverick) XBMC 11 -- from team-xbmc maverick ppa Mythtv 0.23.1+fix (the standard version for mythbuntu 10.10) Mythbox version 1.1.0 OK, so, I was happily going ...
2
votes
1answer
1k views

apt-offline on Windows

Following this tutorial, I don't know how to reproduce step 2 on a windows machine: apt-offline get C:\apt-offline.sig --threads 5 How do I install apt-offline on a Windows machine so I can run ...
2
votes
1answer
234 views

How do you install pythonbrew when using the Fish Shell?

I use the Fish shell in Mac OS X and I cannot figure out how to install pythonbrew. Is this possible and if so how? What I think I need to figure out is how to convert the following for my .bashrc to ...
2
votes
2answers
766 views

Create a local DNS TLD for development

I do a lot of web dev, mainly RoR and PHP, I've got a VMs which holds my dev environments and handling multiple clients on them is a pain. With PHP you just create a subdir, but with RoR it's a little ...
2
votes
1answer
3k views

dpkg: error processing /var/cache/apt/archives/python2.6-minimal_2.6.6-5ubuntu1_i386.deb (--unpack)

I had an issue (Question 199582) which was resolved. Unfortunately I am stuck at this point now. Running root@X100e:/var/cache/apt/archives# apt-get dist-upgrade Reading package lists... Done ...
1
vote
1answer
287 views

How can I write an .odt programmatically?

I would like to write an .odt file programmatically e.g. include figures from a directory or use different style writing code (like a LaTeX document). I wonder how can I compile an .odt file and, if ...
1
vote
1answer
82 views

How do I get `set show-all-if-ambiguous on` in my .inputrc to play nice with the Python interpreter?

I noticed that after I added the set show-all-if-ambiguous on line to my ~/.inputrc, whenever I pressed tab to indent a block, it would show me the bash Display all ... possibilities? (y or n) prompt, ...
1
vote
2answers
263 views

iPython in Terminal.app: multi-line editing

I'm using iPython in Terminal.app (on Mac), and when I scrollback to a multi-line block it's really slow moving between lines. Is there a keybinding (or can I configure one) to make it possible to ...
1
vote
2answers
1k views

Association of Python files in Windows not working

On my system (Windows Vista Home Premium 64bit) Python files are associated with Python interpreter: C:\Users\Piotr>assoc .py .py=Python.File C:\Users\Piotr>ftype Python.File ...
0
votes
0answers
43 views

Stanford Wrangler ideal, but imposes limits, what are other options?

Stanford Wrangle tool is quite amazing, and I solved a giant problem with it, but it limits me to very small size. My file is about 500MB, and it allows me to process less than 1MB, the remaining data ...
0
votes
0answers
53 views

Why is the Python interpreter provided by Django suddenly showing me Python tab completion upon a single Tab press?

This issue seems to have just started happening; basically I just noticed that whenever I press the Tab key in the Python interpreter that comes with Django, it gives me the Display all ... ...
0
votes
1answer
2k views

How can I install python-dev without sudo?

I am trying to install python package (scikits.learn) on my user directory (on a ubuntu server for which I don't have sudo permission) but I am getting error: Python.h: No such file or directory It ...
0
votes
1answer
660 views

The lighttpd+Python equivalent of Apache+PHP+FastCGI+suEXEC (or: lighttpd FastCGI-executing Python scripts with the permission of the owner)

It's been years since I last had anything to do with web servers. The last time, I found that Apache along with FastCGI (actually mod_fcgid) and suEXEC gave me a seemingly perfect way to handle PHP; ...
0
votes
3answers
2k views

Getting .py scripts to open up in Python's IDLE

I'm new to Python. I use Python 2.7 and I am running Windows Vista (64-bit). How do I make it when I click on .py scripts... that it opens up in IDLE so I can edit it a snap? Ya know... without having ...