I would say that, imho, appengine lacks a good pattern for this, anything goes.
Personally I'd like so see a MVC module written for appengine,
maybe there is one in Django (please let me know if so).
This might be a good task for the appengine-utitlies project. I'm
gonna raise the issue there.
http://code.google.com/p/appengine-utitlies/
Cheers,
Johan
--
Johan Carlsson
Colliberty Easy Publisher
http://www.easypublisher.com
Is what your asking, where do I put my libraries?
(assuming I understood you correctly)
I haven't realized before I read this thread (due to the lack of a GAE
account, correct me
if I am wrong) but libraries needs to be put in the application path!?
So one way to layout an app would be to have a "lib" directory in it
where all you add all modules you want to use with the app (this can
be modules that you reuse over different projects).
Each module being its own subdirectory in that directory.
If you're using subversion modules could be "linked" into that directory
with svn:externals from other separate svn repositories.
Now on the question how to organize your code, e.g. what goes in
what module, it's more of an general software architecture question
really. But building components with low coupling is a key off course.
I think there Best Practices will evolve here as people get more experience
and apply their prior knowledge on building appengine apps.
I think the appengine-utilities project might be a good place to evolve this
kind of patterns in a collaborative manner.
Actually the question has already been raise there (by yours truly) :-D
Cheers,
Johan
Exactly. (note though I don't have don't have an GAE account, so
I'm assuming it works so on production as well. But it seems fairly
likely to me.)
> All of this directory stuff took some figuring out. I think there
> should be some docs on this.
>
> As for the software engineering side, I think that is well outside the
> scope of GAE, and does not to be explained here. But I guess I'm
> assuming there are plenty of people like me, who have (quite a bit of)
> experience in software engineering, but are relatively new to Python.
> You get started easily ("it's just another language"), but continuely
> learn Python-specifics.
>
> On the other hand, I'm sure there are plenty of people like my cousin,
> who is just learning to program and who I advised to learn Python
> first. That way, if he builds a (web)application, he can share it with
> his friends easily. I told him to write small lots of small pieces of
> software, and launch them quickly. And only continue on those that
> attract visitors. Off course, right now he'll be limited to 1 or 3,
> but by the time he is good at it, that limitation will perhaps be
> gone? Anyway, for him a book that teaches people how to program
> starting from zero with Python and GAE would be useful. In fact,
> perhaps Google should openly publish such a thing to promote their
> platform. But that is a different discussion.
I agree. Maybe we should write it for Google (in the spirit of Open Source) :-D
I think there are a lot of discussions on this mailing list trying to figure out
best practices. Let's keep up that great work and I think people will put
up articles on the net as we move forward :-D
Cheers,
Johan