Just to fill in the details for others following this thread, you
access this through the os.environ dictionary:

    import os
    ...
    my_version = os.environ['CURRENT_VERSION_ID']

Thanks!

On Jul 6, 1:07 pm, Tony <[email protected]> wrote:
> You can access the global environment variable CURRENT_VERSION_ID -
> from the docs:
>
> CURRENT_VERSION_ID: The major and minor version of the currently
> running application, as "X.Y". The major version number ("X") is
> specified in the app's app.yaml file. The minor version number ("Y")
> is set automatically when each version of the app is uploaded to App
> Engine. On the development web server, the minor version is always
> "1".
>
> I believe memcache and datastore are shared across all versions of the
> app, so keep that in mind.
>
> On Jul 6, 2:56 pm, mckoss <[email protected]> wrote:
>
> > I'd like to be able to know what version of my application is
> > currently running?  Is there an API for reading this string at
> > runtime?
>
> > (I want to use this for flushing cache entries from memcache that are
> > version-specific).
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Google App Engine" 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/google-appengine?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to