Questions tagged [pypy]

PyPy is an implementation of the Python language. Do not confuse with PyPI, the package index. General Python questions should just be tagged with python.

PyPy is a fast, very compliant, self-hosting implementation of the Python language. PyPy started out being a Python interpreter written in the Python language itself. It is built using the language.

PyPy has several advantages and distinctive features, including:

  • Speed: thanks to its Just-in-Time (JIT) compiler, Python programs often run faster on PyPy.

  • Sandboxing: PyPy provides the ability to run untrusted code in a fully secure way.

  • Stackless: PyPy can be configured to run in stackless mode, providing micro-threads for massive concurrency.

Programmers interested in following PyPy's progress should check the Dev Site and the PyPy Status Blog. For background, see PyPy - Goals and Architecture Overview.

Releases and builds

At this time there are three PyPy release series with binaries for x86, ARM, and PPC, on Linux, Mac OS/X and Windows:

  • PyPy2.7 v5.6.0 (the Python2.7 compatible release)
  • PyPy3.3 v5.5.0 (the Python3.3 compatible release)
  • PyPy-STM v2.5.1 (Linux x86-64 only)

More informations about builds and versions on download page. There are also nightly builds available.

794 questions
0
votes
1 answer

pyjwt raises an error on decode

I am using PyJWT to generate and validate JWT in Python. Running pypy3 v2.4. Simply trying to encode and decode a JWT similar to the example in the GitHub repo. I am getting the following error when decoding: decoded = jwt.decode(encoded,…
Sincere
  • 477
  • 5
  • 18
0
votes
0 answers

Install pypy on a virtual environnement with Anaconda

I am trying to treat a massive load of data in order to do some data-mining with Python. I have heard of a optimized python implementation called Pypy. I am having trouble getting Pypy working. Environnement: I am using Anaconda 4.0.0 (64-bit) on a…
Matthias Beaupère
  • 1,731
  • 2
  • 17
  • 44
0
votes
0 answers

Pip suddenly does not work in virtualenv

I'm working on a project. I've created a virtualenv and installed a couple of packages. After working on a project for a while, pip started to raise exceptions. Global pip works without problem. This is in a Django project where I worked on AJAX…
Milano
  • 18,048
  • 37
  • 153
  • 353
0
votes
1 answer

Using vmprof from within script

To profile a function one can use: import cProfile print cProfile.run('foo()') Is it possible to use vmprof in similar way, i.e. just to profile one function from within the code? I'm asking because the linked docs only shows how to run it from…
Ecir Hana
  • 10,864
  • 13
  • 67
  • 117
0
votes
1 answer

uwsgi + pypy "no app loaded" Error

I was trying to deploy website with uwsgi + pypy + flask. Failed with uwsgi error message as below: *** no app loaded. GAME OVER *** My Environment and scripts are: $ uname -a Linux xxxxx 3.13.0-32-generic #57-Ubuntu SMP Tue Jul 15 03:51:12 UTC…
0
votes
1 answer

Tornado on PyPy

I'm getting the following error message when trying to run my tornado server on pypy: /pypy3-2.4.0-osx64/site-packages/pkg_resources/__init__.py:80: UserWarning: Support for Python 3.0-3.2 has been dropped. Future versions will fail here. Does…
johhny B
  • 1,342
  • 1
  • 18
  • 37
0
votes
1 answer

From M2Crypto to pyCrypto

I'm trying to port an M2Crypto function to pyCrypto or any other solution, 'cause the last version of M2Crypto doesn't work with pypy. So, i'm trying to port an existing code from…
luisurrutia
  • 586
  • 6
  • 21
0
votes
1 answer

importing pycurl to crossbar.io errors out

OK so I want to use crossbar.io and build an app in python. I can get the demo working however my app will need to spin off threads which use pycurl to listen to long-lived http connects. separately, the crossbar.io code and the pycurl code work,…
MostWanted
  • 571
  • 1
  • 5
  • 12
0
votes
1 answer

Writing a 3D numpy array into a slice of a larger 3D array using a 2D mask

I have two 3D numpy arrays, each representing an image (x, y, rgb). I want to write the smaller image into the larger image, except for any magenta pixels (255, 0, 255). I know how to generate a 2D mask representing all the magenta pixels -- how can…
Tom Quinn
  • 614
  • 4
  • 17
0
votes
1 answer

Motor compatibility with pypy

Does anyone know if the Motor library is compatible with pypy? I'm running a tornado with motor and want to understand the best way to start optimising.. The choices seem between cython and pypy. It looks like the latter is the way to go however…
johhny B
  • 1,342
  • 1
  • 18
  • 37
0
votes
2 answers

Why is my code slower in pypy than the default python interpreter?

Given a number of players n, I need to find H, the list of all tuples where each tuple is a combination of coalitions (of the players, e.g. (1,2,3) is the coalition of players 1, 2 and 3. ((1,2,3),(4,5),(6,)) is a combination of coalitions - which…
Pigna
  • 2,792
  • 5
  • 29
  • 51
0
votes
2 answers

How is it possible python to be faster than pypy

I run a piece of code with python2.7 and the cProfile says 35s while cProfile on pypy says 73s ! How is that possible assuming pypy is faster interpreter. The code implements the BWT transformation on input a bitstream. I have two files: bwt.py…
curious
  • 1,524
  • 6
  • 21
  • 45
0
votes
1 answer

Does PyPy support gmpy2?

It seems from the discussions issue #60 and issue #40 that PyPy couldn't build gmpy before. All I intend to use currently is the probable prime is_prime code which is conveniently in gmpy2. I get the impression that the more calls to gmpy2 means…
qwr
  • 9,525
  • 5
  • 58
  • 102
0
votes
1 answer

Installing rbtree on PyPy

I'm trying to install rbtree as a PyPy module. I read that some modules are not compatible with PyPy. Is there any way to install it properly or any alternative? I'm looking for a tree dictionary that also can be browsed like tree[0:100]…
Carlos Vega
  • 1,341
  • 2
  • 13
  • 35
0
votes
0 answers

Can't install setuptools for pypy

There no file by path to custom distribute pip setup: http://python-distribute.org/distribute_setup.py That recommeded for installation. Setuptools prints the next error on linux debian: $ pypy ez_setup.py 'import site' failed AttributeError:…
Kirill Golikov
  • 1,354
  • 1
  • 13
  • 27