Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #28026 > unrolled thread

Re: protobuf + pypy

Started byNatalia Bidart <nataliabidart@gmail.com>
First post2012-08-28 19:01 -0300
Last post2012-08-28 19:01 -0300
Articles 1 — 1 participant

Back to article view | Back to comp.lang.python

This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by below is the oldest one visible, not the original post.


Contents

  Re: protobuf + pypy Natalia Bidart <nataliabidart@gmail.com> - 2012-08-28 19:01 -0300

#28026 — Re: protobuf + pypy

FromNatalia Bidart <nataliabidart@gmail.com>
Date2012-08-28 19:01 -0300
SubjectRe: protobuf + pypy
Message-ID<mailman.3904.1346191296.4697.python-list@python.org>
On Tue, Aug 21, 2012 at 6:55 PM, Pedro Larroy
<pedro.larroy.lists@gmail.com> wrote:
> Hi
>
> Anyone knows if it's possible to use protobuffers with pypy?   Seems
> there isn't much info on the web about this.

So, in my experience, the easiest way to confirm if something works
with PyPy (when you can't find proper bibliography in the web) is to
try to install it in a pypy virtualenv [0]:

(my-pypy-env)nessita@dali:~/projects/pypy/my-pypy-env$ pip install protobuf
Downloading/unpacking protobuf
  Downloading protobuf-2.4.1.tar.gz (56Kb): 56Kb downloaded
  Storing download in cache at
/home/nessita/.pip_download_cache/http%3A%2F%2Fpypi.python.org%2Fpackages%2Fsource%2Fp%2Fprotobuf%2Fprotobuf-2.4.1.tar.gz
  Running setup.py egg_info for package protobuf

Requirement already satisfied (use --upgrade to upgrade): distribute
in ./site-packages/distribute-0.6.24-py2.7.egg (from protobuf)
Installing collected packages: protobuf
  Running setup.py install for protobuf
    Skipping installation of
/home/nessita/projects/pypy/my-pypy-env/site-packages/google/__init__.py
(namespace package)

    Installing /home/nessita/projects/pypy/my-pypy-env/site-packages/protobuf-2.4.1-py2.7-nspkg.pth
Successfully installed protobuf
Cleaning up...

(my-pypy-env)nessita@dali:~/projects/pypy/my-pypy-env$ pypy
Python 2.7.2 (341e1e3821ff, Jun 07 2012, 15:38:48)
[PyPy 1.9.0 with GCC 4.4.3] on linux2
Type "help", "copyright", "credits" or "license" for more information.
And now for something completely different: ``Python 2.x is not dead''
>>>> from google.protobuf import descriptor

Seems to work :-) (though I have no app using it right now).

Cheers, Natalia.

[0] Instructions on how to create a PyPy virtualenv:
http://morepypy.blogspot.com.ar/2010/08/using-virtualenv-with-pypy.html

[toc] | [standalone]


Back to top | Article view | comp.lang.python


csiph-web