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


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

Newbie: installation difficulties [webapp2 / babel]

Started byBobAalsma <overhaalsgang_24_bob@me.com>
First post2013-10-07 12:12 -0700
Last post2013-10-08 08:30 +1100
Articles 5 — 3 participants

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


Contents

  Newbie: installation difficulties [webapp2 / babel] BobAalsma <overhaalsgang_24_bob@me.com> - 2013-10-07 12:12 -0700
    Re: Newbie: installation difficulties [webapp2 / babel] Joel Goldstick <joel.goldstick@gmail.com> - 2013-10-07 15:31 -0400
      Re: Newbie: installation difficulties [webapp2 / babel] BobAalsma <overhaalsgang_24_bob@me.com> - 2013-10-07 13:00 -0700
        Re: Newbie: installation difficulties [webapp2 / babel] Joel Goldstick <joel.goldstick@gmail.com> - 2013-10-07 16:18 -0400
        Re: Newbie: installation difficulties [webapp2 / babel] Chris Angelico <rosuav@gmail.com> - 2013-10-08 08:30 +1100

#56320 — Newbie: installation difficulties [webapp2 / babel]

FromBobAalsma <overhaalsgang_24_bob@me.com>
Date2013-10-07 12:12 -0700
SubjectNewbie: installation difficulties [webapp2 / babel]
Message-ID<e8123e7b-4e94-41c9-9070-8a491538a14a@googlegroups.com>
Hi,

I'm following webapp2 documentation (release 2.1).

I made a mistake in following the text. 
I typed "pip install babel" and this led to errors in the installation.
As that user is not in sudo list, I changed users, typed "sudo pip install babel" and everything seemed right.

Further on, the manual says "$ pybabel ...." and when I use that command, the response is "-bash: pybabel: command not found" (in both user environments).

I'd like to solve this and learn at the same time ;)

I'm on OS X 10.8.5, python 2.7.5.

I found a "babel" in /Library/Python/2.7/site-packages.
I found a "babel" in the response to "python -c "help('modules')" | grep babel".
From which I conclude that babel is on the machine and is known to python.

However, I gather from the webapp2 documentation that babel should also be known to the shell.
I don't yet know how to check this, nor how to repair.

find /usr -name '*babel*' 
and
find /bin -name '*babel*' 
return no values, but
find /Library -name '*babel*' 
does (as expected).

I've tried to find similar situations in documentation, forums, Google but found nothing helpful.

[toc] | [next] | [standalone]


#56322

FromJoel Goldstick <joel.goldstick@gmail.com>
Date2013-10-07 15:31 -0400
Message-ID<mailman.812.1381174320.18130.python-list@python.org>
In reply to#56320
On Mon, Oct 7, 2013 at 3:12 PM, BobAalsma <overhaalsgang_24_bob@me.com> wrote:
> Hi,
>
> I'm following webapp2 documentation (release 2.1).
>
> I made a mistake in following the text.
> I typed "pip install babel" and this led to errors in the installation.
> As that user is not in sudo list, I changed users, typed "sudo pip install babel" and everything seemed right.
>
> Further on, the manual says "$ pybabel ...." and when I use that command, the response is "-bash: pybabel: command not found" (in both user environments).
>
> I'd like to solve this and learn at the same time ;)
>
> I'm on OS X 10.8.5, python 2.7.5.
>
> I found a "babel" in /Library/Python/2.7/site-packages.
> I found a "babel" in the response to "python -c "help('modules')" | grep babel".
> From which I conclude that babel is on the machine and is known to python.
>
> However, I gather from the webapp2 documentation that babel should also be known to the shell.
> I don't yet know how to check this, nor how to repair.
>
> find /usr -name '*babel*'
> and
> find /bin -name '*babel*'
> return no values, but
> find /Library -name '*babel*'
> does (as expected).
>
> I've tried to find similar situations in documentation, forums, Google but found nothing helpful.
> --
> https://mail.python.org/mailman/listinfo/python-list

If you can run $python babel then I think you need to set babel to be
executable to run it without invoking python first.





-- 
Joel Goldstick
http://joelgoldstick.com

[toc] | [prev] | [next] | [standalone]


#56324

FromBobAalsma <overhaalsgang_24_bob@me.com>
Date2013-10-07 13:00 -0700
Message-ID<d9b6f106-35fa-4438-99e3-d76fc59aab21@googlegroups.com>
In reply to#56322
Well Joel, umm, I'm not sure if I understand you correctly. 

$ python babel
/Library/Frameworks/Python.framework/Versions/2.7/Resources/Python.app/Contents/MacOS/Python: can't open file 'babel': [Errno 2] No such file or directory

And


$ python
Python 2.7.5 (v2.7.5:ab05e7dd2788, May 13 2013, 13:18:45) 
[GCC 4.2.1 (Apple Inc. build 5666) (dot 3)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> import babel
>>> 

Does this help?

Bob

[toc] | [prev] | [next] | [standalone]


#56326

FromJoel Goldstick <joel.goldstick@gmail.com>
Date2013-10-07 16:18 -0400
Message-ID<mailman.815.1381177132.18130.python-list@python.org>
In reply to#56324
On Mon, Oct 7, 2013 at 4:00 PM, BobAalsma <overhaalsgang_24_bob@me.com> wrote:
> Well Joel, umm, I'm not sure if I understand you correctly.
>
> $ python babel
> /Library/Frameworks/Python.framework/Versions/2.7/Resources/Python.app/Contents/MacOS/Python: can't open file 'babel': [Errno 2] No such file or directory
>
> And
>
>
> $ python
> Python 2.7.5 (v2.7.5:ab05e7dd2788, May 13 2013, 13:18:45)
> [GCC 4.2.1 (Apple Inc. build 5666) (dot 3)] on darwin
> Type "help", "copyright", "credits" or "license" for more information.
>>>> import babel
>>>>
>
> Does this help?
>
> Bob
> --
> https://mail.python.org/mailman/listinfo/python-list

Bob, I'm not a pro at getting python stuff to run on Apple, but you
might learn something here:
http://docs.python.org/2/using/mac.html#using-python-on-a-macintosh

>From the looks of it, babel doesn't seem to be in a directory where
the mac looks for executables.  You may want to cd yourself over to
where babel is and try to run it.  If that works, you have to figure
out how to get babel in your executable path.  I can't help you there.

-- 
Joel Goldstick
http://joelgoldstick.com

[toc] | [prev] | [next] | [standalone]


#56332

FromChris Angelico <rosuav@gmail.com>
Date2013-10-08 08:30 +1100
Message-ID<mailman.819.1381181412.18130.python-list@python.org>
In reply to#56324
On Tue, Oct 8, 2013 at 7:00 AM, BobAalsma <overhaalsgang_24_bob@me.com> wrote:
> Well Joel, umm, I'm not sure if I understand you correctly.
>
> $ python babel
> /Library/Frameworks/Python.framework/Versions/2.7/Resources/Python.app/Contents/MacOS/Python: can't open file 'babel': [Errno 2] No such file or directory

If the file's called babel.py, you have to invoke it that way - Python
won't add an implicit file extension. Not sure if that helps your
problem or not - I don't know babel, nor Mac OS. Try:

$ python babel.py

ChrisA

[toc] | [prev] | [standalone]


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


csiph-web