-
Notifications
You must be signed in to change notification settings - Fork 60
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Starting a task on a local module without an explicit version fails #71
Comments
I am running into this issue with the latest version at pypi even though the app.yaml in the project has a valid version entry. |
@jaybaker - this issue is most certainly present in the current code:
Also, which PR are you referring to? I found #78, but that more masks than fixes the issue. Fortunately the underlying issue has now been fixed (https://issuetracker.google.com/issues/35900827 in the new Google issue tracker). So from google.appengine.api import modules
# ...
def _get_task_target():
# ...
module = modules.get_current_module_name()
version = modules.get_current_version_name()
if module == "default":
return version
if version is None:
return module
return "%s.%s" % (version, module) Unfortunately nobody seems to follow / update this project :( |
This combines a suggestion by @cdman with the existing code for detecting versions and modules, which should be robust. It's lightly tested in an App Engine development environment.
Fix pulled from: paulbynd/appengine-pipelines@d488118 Original pipelines bug report: GoogleCloudPlatform/appengine-pipelines#71
The root cause of this is this GAE dev_server issue: when running a module locally with
dev_appserver.py
which doesn't haveversion:
inapp.yaml
, it will have something like"None.175924092260391774
inos.environ['CURRENT_VERSION_ID']
. This results inutil._get_task_target()
returning something like"None.modulename"
which then raises aInvalidModuleError
when trying to enqueue the task in_PipelineContext.start
.One possible solution would be:
util._get_task_target()
over to modules (since it's using undocumented APIs). Something like:The text was updated successfully, but these errors were encountered: