There are no specific environment variables you should use, as you would 
need to implement this behavior yourself. Sorry if that wasn't clear.

What I meant is that you could omit the version and service from app.yaml 
for both gcloud and dev_appserver and have your code check if environment 
variables that you defined are set and if so skip on using the Modules API. 
You would of course only do this on the local dev server. On production 
that environment variable check would fail and you would simply use the 
Modules API.

On Monday, June 26, 2017 at 7:53:04 PM UTC-4, PK wrote:
>
> wrt "could you use the "--env_var ENV_VARIABLES" command line option “ 
> What environment variable should I pass for the version in dev_appserver? I 
> tried a few obvious options but did not work.
>
> Thanks
>
>
> On Jun 26, 2017, at 9:03 AM, 'Yannick (Cloud Platform Support)' via Google 
> App Engine <[email protected]> wrote:
>
> Hello PK,
>
> You are correct, there is an inconsistency in how the local development 
> server and the gcloud command line interface handle versions and services. 
> If you want to you can create a feature request 
> <https://b.corp.google.com/issues/new?component=187272&template=1010823> for 
> either component's behavior and functionality to be changed.
>
> As an potential additional workaround, depending on how much of the 
> Modules API you are using, could you use the "--env_var ENV_VARIABLES" 
> command line option for dev_appserver.py and pass the version information 
> you need to your program that way when testing?
>
> On Sunday, June 25, 2017 at 8:44:34 PM UTC-4, PK wrote:
>>
>> I am transitioning from the SDK/appcfg.py to gcloud and hit the following 
>> issue that seems to need clarification. In the SDK, one specifies the 
>> application and the version in the configuration yaml file. Both appcfg and 
>> dev_appserver.py pick it from there and everything works as expected.
>>
>> "gcloud deploy" and friends do not want application: and version: entries 
>> in the yaml file. No problem there, I now pass them in the 'gcloud deploy' 
>> command line. dev_appserver.py has a -A option and I also pass the 
>> application id there. However, there seems to be no way to pass the 
>> module/service version number to dev_appserver.py.
>>
>> Am I missing something or this is still WIP? As a workaround I now 
>> generate two sets of yaml files, one with version for dev_appserver.py and 
>> one without for 'gcloud deploy' but I would expect to be a better way.
>>
>> Thanks,
>> PK
>> www.gae123.com
>>
>> PS My code uses the modules module version information APIs; if I do not 
>> pass a version in the development environment it returns 'None' which make 
>> things fail.
>>
>
>
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/google-appengine.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/google-appengine/f31a23ae-8b4c-4691-ae9e-93b6e97bb981%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to