On Sun, Nov 1, 2009 at 9:06 AM, Matt Feifarek <[email protected]> wrote:
> On Thu, Oct 29, 2009 at 3:19 PM, reco <[email protected]> wrote:
>>
>> just tried the wiki page
>> i got the following probs:
>>
>>  File "lib/setuptools-0.6c11-py2.5.egg/pkg_resources.py", line 24, in
>> <module>
>>    from os import utime, rename, unlink, mkdir
>> ImportError: cannot import name mkdir
>> INFO     2009-10-29 19:56:30,793 dev_appser
>
> Yeah, I'm now getting this too. I think that the 1.2.7 release of GAE broke
> this. I'm going to look into it.
> This is the kind of thing I'm worried about with trying to hack our way into
> running GAE apps on Paster. Everything works fine, then Google does
> something mysterious and then a fundamental breakage occurs.
> I'm going to see if I can figure this out, but I think that we should take
> Ian Bicking's advice and put our efforts into getting the Pylons stack
> running on the dev appserver from Google.

mkdir is one of those operations that's prohibited on App Engine.  The
development server is faithfully mimicking the production server in
this regard.  Appengine Monkey puts stub functions into the os module
to make this work.  (You can't actually create a directory, but you
can import a module that imports the functions.)  I don't know how
Google implemented support for Setuptools, whether they did it this
way or not.

So the question is, what's the difference between Matt's code and the
appengine-homedir code that accounts for this exception?

This is why I wish Pylons/Paste didn't use Setuptools at runtime,
because it's hard to trace why things like this are happening.  I
think runner.py in appengine-homedir instantiates the application and
HTTPServer manually, bypassing pkg_resources precisely to avoid
problems like this.

Also, make sure you're not using an old Appengine SDK.

-- 
Mike Orr <[email protected]>

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"pylons-discuss" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/pylons-discuss?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to