Are you sure you have pytz installed on your system?

Try this from cmd line: python -c "import pytz; print
pytz.timezone('America/New_York')"
Should print out "America/New_York". If it doesn't, something's wrong with
pytz. Note that it's not included in App Engine SDK. Usually it's installed
as a system package.

Anyway, aside from timezone, whether it works or not, try commenting it out
and see if you get all the modules running:

1. Go to http://localhost:8000 - it should display all of your modules.
2. Try executing "curl http://localhost:8080/callLoadAndProcess"; and see if
it works. It should. If it doesn't, you'll probably need to tweak your
dispatch.yaml<https://developers.google.com/appengine/docs/python/modules/routing>file.

hope this helps!


On 8 January 2014 15:17, Adrian <adrianj.rand...@gmail.com> wrote:

> This is the part of the cron.yaml file it is getting upset with (line 5):
>
> cron:
> - description: call frontend instance to call a module to download data
>   url: /callLoadAndProcess
>   schedule: every day 01:00
>   timezone: America/New_York
>
>
> On Wednesday, January 8, 2014 9:08:50 AM UTC-5, Adrian wrote:
>>
>> Hey Alex,
>>
>> Thanks for the reply -- when I load in all of my modules (app.yaml and
>> loadandprocess.yaml), I now have this error when I go to the cron tab on
>> the devserver admin page:
>>
>> Error loading cron.yaml:
>>
>>
>> Traceback (most recent call last):
>>   File "/home/adrian/google_appengine/google/appengine/
>> tools/devappserver2/admin/cron_handler.py", line 42, in get
>>     values['cronjobs'] = self._get_cron_jobs()
>>   File "/home/adrian/google_appengine/google/appengine/
>> tools/devappserver2/admin/cron_handler.py", line 48, in _get_cron_jobs
>>     cron_info = self._parse_cron_yaml()
>>   File "/home/adrian/google_appengine/google/appengine/
>> tools/devappserver2/admin/cron_handler.py", line 80, in _parse_cron_yaml
>>     cron_info = croninfo.LoadSingleCron(f)
>>   File "/home/adrian/google_appengine/google/appengine/api/croninfo.py",line
>> 151, in LoadSingleCron
>>     listener.Parse(cron_info)
>>   File "/home/adrian/google_appengine/google/appengine/
>> api/yaml_listener.py", line 226, in Parse
>>     self._HandleEvents(self._GenerateEventParameters(stream, loader_class
>> ))
>>   File "/home/adrian/google_appengine/google/appengine/
>> api/yaml_listener.py", line 177, in _HandleEvents
>>     raise yaml_errors.EventError(e, event_object)
>> EventError: Unable to assign value 'America/New_York' to attribute
>> 'timezone':
>> timezone 'America/New_York' is unknown
>>
>>
>> Any ideas? Thanks..
>>
>> On Tuesday, January 7, 2014 7:15:40 PM UTC-5, alex wrote:
>>>
>>> > Aside from just having the [module name].yaml file in the directory
>>> with my default app.yaml file, do I need to do anything else to get the
>>> dev_server to recognize the additional module?
>>>
>>> Make sure you supply all *.yaml files to dev_appserver in cmdline args,
>>> e.g.:
>>>
>>> dev_appserver.py app.yaml module1.yaml module2.yaml dispatch.yaml
>>>
>>> Execute dev_appserver.py -h for more details.
>>>
>>> On Tuesday, January 7, 2014 9:19:12 PM UTC+1, Adrian wrote:
>>>>
>>>> Thank you for the suggestions... this is odd... my directory has a
>>>> "loadandprocess.yaml" module, with the following text:
>>>>
>>>> application: [my app name]
>>>> module: loadandprocess
>>>> version: one
>>>> runtime: python27
>>>> api_version: 1
>>>> threadsafe: true
>>>> instance_class: B4_1G
>>>> basic_scaling:
>>>>   max_instances: 1
>>>>
>>>> handlers:
>>>> - url: /.*
>>>>   script: loadAndProcess.application
>>>>   login: admin
>>>>
>>>> But whenever I call
>>>> logging.info(modules.get_modules())
>>>>
>>>> It only recognizes my default application:
>>>>
>>>> INFO     2014-01-07 20:15:50,482 callLoadAndProcess.py:10] ['default']
>>>>
>>>> Aside from just having the [module name].yaml file in the directory
>>>> with my default app.yaml file, do I need to do anything else to get the
>>>> dev_server to recognize the additional module?
>>>>
>>>> Thanks!
>>>>
>>>>
>>>>
>>>>
>>>> On Tuesday, January 7, 2014 2:47:39 AM UTC-5, Vinny P wrote:
>>>>>
>>>>> On Mon, Jan 6, 2014 at 7:03 PM, Adrian <adrianj...@gmail.com> wrote:
>>>>>
>>>>>>   File "/home/adrian/arapphost/callLoadAndProcess.py", line 10, in
>>>>>> get
>>>>>>     modules.start_module("loadandprocess","1")
>>>>>>   File 
>>>>>> "/home/adrian/google_appengine/google/appengine/api/modules/modules.py",
>>>>>> line 385, in start_module
>>>>>>     rpc.get_result()
>>>>>>
>>>>>
>>>>>
>>>>> The traceback claims that the module and version you're referring to
>>>>> doesn't exist. Try to debug the problem by:
>>>>>
>>>>>  1. Sometimes modules throw up unusual errors when versions are
>>>>> expressed as pure numbers instead of a mix of letters and numbers. In
>>>>> loadandprocess.yaml, change *version: 1* to *version: one*. Remember
>>>>> to update *callLoadAndProcess.py* with the correct version (the
>>>>> *start_module* call).
>>>>>
>>>>> 2. You can use *get_modules()* and *get_versions(module=___)* in the
>>>>> *modules* package to enumerate all the modules and all the versions
>>>>> of a given module that App Engine recognizes within your application. App
>>>>> Engine may be recording the module under a different name or version.
>>>>>
>>>>> -----------------
>>>>> -Vinny P
>>>>> Technology & Media Advisor
>>>>> Chicago, IL
>>>>>
>>>>> App Engine Code Samples: http://www.learntogoogleit.com
>>>>>
>>>>>
>>>>  --
> You received this message because you are subscribed to a topic in the
> Google Groups "Google App Engine" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/google-appengine/_YIp716sTlw/unsubscribe
> .
> To unsubscribe from this group and all its topics, send an email to
> google-appengine+unsubscr...@googlegroups.com.
> To post to this group, send email to google-appengine@googlegroups.com.
> Visit this group at http://groups.google.com/group/google-appengine.
> For more options, visit https://groups.google.com/groups/opt_out.
>

-- 
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 google-appengine+unsubscr...@googlegroups.com.
To post to this group, send email to google-appengine@googlegroups.com.
Visit this group at http://groups.google.com/group/google-appengine.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to