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

5
votes
2answers
3k views

Python IDLE disappeared from the right click context menu

My IDLE shortcut in the right click menu has disappeared. I think it's because I used to use Python 2.7, but I installed Python 2.5 without uninstalling Python2.7, and then uninstalled Python 2.5. I ...
0
votes
0answers
17 views

Sublime Text 2: refactor Python line into method / create a method

ST 2, Python. Code in body of class method: print 'here' bar = foo(*args) I'd like to select foo and refactor it into a class method, or create it if it does not exist yet: def foo(self, *args): ...
0
votes
0answers
22 views

How to get the file extended attribute offline on windows python

I'm looking for the way to get the attribute file property as shown on windows file parameters. This property show D for folder, A for archives , O for Offline,... I've already tried to have a look on ...
1
vote
1answer
33 views

Excel not accessible after import of data through script [closed]

I am using a python script to open up an excel workbook (by creating a pointer to it). After I put some data in the excel and script execution is completed, I tried to access(see note below ) the ...
3
votes
2answers
3k views

Python / Selenium / PhantomJS: “Unable to start phantomjs with ghostdriver.”

I'm trying to get Selenium to use phantomjs on a Windows machine. My code compiles without any error: from selenium import webdriver from selenium.webdriver.common.desired_capabilities import ...
0
votes
1answer
40 views

Windows refuses to “Open with” python.exe

I was doing some messing around, trying to install some new python-oriented things, when some how I did something that caused .py and .pyw files to be disassociated with python.exe. I was meaning to ...
0
votes
0answers
17 views

Login, Navigate and Retrieve data behind a proxy with Python

I want, with a python script, to be able to login a website and retrieve some data. This behind my company's proxy. I know that this question seems a duplicate of others that you can find searching, ...
0
votes
0answers
28 views

Importing pygments' highlighting to vim

Usually, vim does very good job in highlighting, using the packaged syntax files. Unfortunately, it does bad job with MySQL. At first, I looked everywhere for a better MySQL vim syntax file, with no ...
0
votes
1answer
626 views

pip and SSL certificate errors

I am trying to install a library via pip. I have a problem with SSL certificate, even when using the --cert. Trying this on windows (pip version 1.5.4,python version 2.7.6): pip --cert ...
5
votes
4answers
3k 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 ...
0
votes
1answer
206 views

How to fix Windows 8 Anaconda “can't open file” errors in cygwin when using absolute paths?

I'm having troubles getting Anaconda to run python scripts on cygwin. My configuration. Windows 8.1 $ echo $PATH ...
0
votes
1answer
139 views

Python can't access the Internet on Windows Server 2003

I'm trying to install the requests package on windows 2003 with Python 3.4.0 I have also tried Python 3.2 and got the exact same result. When I try an install using pip I get the following error ...
1
vote
1answer
151 views

Restore Mac preinstalled Python to standard

I have been hacking away at getting packages to work in my initial coding stages. I only recently stumbled upon virtualenv and found the need to install Python using Homebrew. I have installed ...
0
votes
1answer
27 views

Nagios command definition files

Im following the tutorial from this page. Writing Custom Nagios Plugins Everything is working fine my only problem is that the first config file your supposed to edit is the command-plugins.cfg file ...
8
votes
2answers
8k views

How can I make a table of contents for a markdown document with Python/AWK/SED?

I have the following markdown document: Heading-a ========== ---text--- Heading-b ------------ --- text --- Heading-c ---------- --- text--- Heading-d ======= --- text---- Heading-e --- ... ...
3
votes
1answer
1k views

How do you install libtorrent-rasterbar Python bindings with a brewed Python?

The standard approach does not work: brew install libtorrent-rasterbar Will install the boost requirement (linked against the system Python), and libtorrent-rasterbar will install without any ...
0
votes
0answers
7 views

How to convert python 3 files into a file readable for MACs

I've been using cx_Freeze to convert my py files into exes, but now I'm looking to expand my audience and want to get my py files on macs too. Any idea of how I can do this?
0
votes
1answer
42 views

script “somescript_name.py” can not be installed because plugin “python” is not loaded in Weechat

I'm trying to install some script in Weechat but anyone of them I'm getting 16:45:56 | script: script "notification_center.py" can not be installed because plugin "python" is not loaded I'm ...
1
vote
0answers
120 views

PyV8 failing to install with pip, does not compile in Fedora 20

I am having the exact same issue as here: https://code.google.com/p/pyv8/issues/detail?id=132, but answer didn't work either. I am trying to install PyV8 using pip in Fedora 20. I get this: $ pip ...
0
votes
1answer
43 views

make error as unable to find cblas

I am trying to run the BdG-TMAT code. The folder here has both Fortran and python files since the main run file BDG_K.py uses some fortran functions. So to run the fortran code, I use a converter f2py ...
0
votes
0answers
28 views

error installing MySQL-python

I'm starting to learn python. When I try to install MySQL-python with yum from yum install MySQL-python.x86_64 I get this error Loaded plugins: katello, product-id, security, subscription-manager ...
1
vote
0answers
101 views

Looping on image2pipe with FFMPEG

I have a Python program that generates images at various intervals. I'd like to be able to create a streaming video of each image as it appears. Previously I was using an ffmpeg command like ffmpg ...
0
votes
0answers
13 views

broken virtual enviornment virtualenv?

I am getting this error when I run python in my virtual enviornment: (env):~$ python Could not find platform independent libraries <prefix> Could not find platform dependent libraries ...
0
votes
0answers
28 views

is pip install scipy fails with ld: symbol(s) not found for architecture x86_64

I am trying to install python scipy in a virtual environment using pip install scipy It fails with the following error ... ld: symbol(s) not found for architecture x86_64 collect2: error: ld ...
2
votes
1answer
111 views

build vim 64bit on windows 7

i am trying to build 64bit vim on win7 64bit with visual studio 2008. My python34 is 64bit version. Below is what i did. hg to get the vim source. set VCDIR="C:\Program Files (x86)\Microsoft Visual ...
0
votes
1answer
72 views

Change pythonpath in Vim

I'm using Vim for Python coding. The problem is, that I'm writing in Python 3 and Vim settings contain only Python 2.7 paths. That does not allow me to use plugins (like python-mode) for autocomletion ...
0
votes
1answer
81 views

error due to f2py not installed correctly: how do I correct?

http://software-lisc.fbk.eu/bdg/ I am trying to run the BdG-TMAT code. The folder here has both Fortran and python files since the main run file BDG_K.py uses some fortran functions. So to run the ...
0
votes
0answers
7 views

Opening the correct IDLE console

Right clicking on a .py file brings up a list of options, among which is edit with idle (as per the image below) The problem is that I have two python installations, both a python 2.6 (for one ...
1
vote
1answer
26 views

How to install packages without interfering existing ones without using yum and without root?

I have this specific problem of setting virtual dev environment without interfering existing system and tool. The question is general. Basically I want to develop some stuff in the company, but we ...
0
votes
0answers
24 views

Recompiling a python program doesn't produce executable

Today I installed Mathics from their github repository: $ git clone https://github.com/poeschko/Mathics.git $ sudo python setup.py install And then I decided to modify the source a little bit and ...
1
vote
1answer
284 views

Installing python pymssql

I am trying to install pymssql with no luck: pip install pymssql Downloading/unpacking pymssql Downloading pymssql-2.0.1.tar.bz2 (1.9MB): 1.9MB downloaded Running setup.py ...
0
votes
1answer
1k views

pip is not recognized as an internal or external command

I have installed pip and distribute, and no errors came up. But when I enter pip into the cmd or windows powershell, it gives me an error. However, when I import pip into python, no errors come up. I ...
0
votes
0answers
44 views

How to properly install IPython on Mac with Homebrew?

How to properly install IPython on Mac with Homebrew? The method recommended by ipython.org, i.e. installing Anaconda or Enthought Canopy will introduce files that brew doctor will raise warning ...
0
votes
1answer
59 views

Error getting server's IP address using Python on CentOS

I'm using Python's socket module to get the server's IP address server_ip = socket.gethostbyname(socket.getfqdn()) I get this error: socket.gaierror: [Errno -2] Name or service not known Weird ...
1
vote
1answer
63 views

How to set the bootorder for a vm in vsphere 5.x with pysphere

I am using the following python code to set the extra_config parameter bios.bootOrder: #!/bin/env python from pysphere import VIServer, VITask from pysphere.resources import VimService_services as VI ...
4
votes
1answer
283 views

Can I use a custom command in OS X's “Open With”?

I'd like to be able on OS X (Mountain Lion) to automatically open a file with a custom command. In particular, if I double-click on file xxx.vcb, I'd like it to open with: python wp.py xxx.vcb in a ...
0
votes
1answer
86 views

Python by default on all unix systems? [closed]

There was a discussion on which language to choose for a system checker. The system checker is supposed to be a script running on unix systems. On Gnu/Linux systems seem to always have it installed ...
1
vote
0answers
29 views

How to forward data to mysql server using socket module in python

How to forward data to mysql server using socket module in python, i have try to import socket and connect it to mysql server for test, but have no data received from it, my code like this def ...
0
votes
1answer
177 views

SSH could not create directory /home/USERNAME/.ssh

My script is executing the below command: command = os.system('rdiff-backup --exclude "**.dropbox**" --exclude "**.ini**" --remote-schema "ssh -o ...
0
votes
1answer
108 views

How can I get syntastic to install properly?

I followed the exact steps listed on Syntastic's GitHub page to install it as a Pathogen bundle, but I'm not getting any Syntastic feedback at all in vim. Their FAQ states this is normally caused by ...
2
votes
2answers
4k views

How to install Visual Python in Ubuntu 10.04?

I am trying to do a Physics problem in python. I need to install visual python because I get the error that it can't find the visual library when I type import visual from * The documentation on the ...
3
votes
1answer
1k views

OSX 10.8 PIP matplotlib 'freetype/config/ftheader.h' file not found

I apologize ahead of time if this topic has already been discussed. My situation seems to vary slightly from the others such that the path to my files is different. When trying to install matplotlib ...
2
votes
2answers
1k views

Matplotlib font_manager.py font finding error

On a Ubuntu 12.04 machine, whenever I plot something I get an error like: /usr/lib/pymodules/python2.7/matplotlib/font_manager.py:1228: UserWarning: findfont: Could not match :family=Bitstream ...
0
votes
0answers
41 views

Installing pyjnius on windows8

I tried pip install jnius but, fails on my Windows8. error occur #error "LONG_BIT definition appears wrong for platform (bad gcc/glibc config?)." Any ideas?
0
votes
0answers
64 views

SSL with Flask and Apache always shows Test Page

I am trying to set up Flask to run on SSL, along with redirecting all HTTP traffic to HTTPS. I am currently using Apache as a web server, and it is serving traffic on port 80 HTTP properly. However, ...
0
votes
2answers
201 views

Sending multicast packet with source IP equal to virtual interface IP in Python

I have a system with a virtual network interface eth0:1, and I want to send multicast packets that have a source IP of that interface. However, my packets end up with the source IP for eth0. How do I ...
0
votes
0answers
140 views

py2app install error on Mac OS X mavericks

Installed py2app 0.8 on a current MacOS X mavericks. It mostly went fine except grumbling about altgraph. I tried this anyway. py2applet --make-setup pong.py and I get this ...
-1
votes
1answer
37 views

Automatically distribute files to users

I belong to an organization that puts files (pdf, mp3 and assorted videos) on a website for members (about 200) to download. We have to individually download each file (~30) and it's annoying, so I ...
1
vote
1answer
123 views

what to do with system installed python versions when starting with pythonbrew

I'm running Ubuntu 11.10. I have both Python 2.7 and 3.2 installed on the system and available in /usr/bin/. I am looking to start using pythonbrew and it seems it will want me to install my python ...
0
votes
1answer
20 views

Unable to install python2.7-dev on Raring

I am trying to do it through ubuntu software center and I get this message: python2.7-dev: Depends: python2.7 (= 2.7.4-2ubuntu3) but 2.7.4-2ubuntu3.1 is to be installed Depends: ...