Using your own version of ProtoRPC

572 views
Skip to first unread message

Rafe Kaplan

unread,
Jun 16, 2011, 4:30:48 PM6/16/11
to ProtoRPC Discuss
Many of you might already be aware that ProtoRPC has now part of
Google App Engine. For most users, it is probably desirable to use
the built in version, but it's worth noting that it is still in the
experimental phase. It's possible that future release of app engine
can contain changes that might break your existing applications. If
you are using ProtoRPC in production, it might make sense for you to
continue using your own version of ProtoRPC.

Here's one way to make sure that your version of ProtoRPC is used by
app engine instead of the built in one. If you don't already have
one, create python module called "appengine_config.py" at the top
level of your application directory. In this file add this code:

import os
import sys

sys.path.insert(0, os.path.dirname(__file__))

Now make sure that in all main python scripts that you import this
module BEFORE you import anything from ProtoRPC. If you don't import
this module before you import ProtoRPC you could end up with
unpredictable results.

Even if you do want to maintain your own versions of ProtoRPC it is
highly recommended that you keep that version relatively up to date.
This will mean responding to minor compatibility changes that might
pop up (which we will try to keep to a minimum until ProtoRPC leaves
the experimental phase).
Reply all
Reply to author
Forward
0 new messages