Skip to content

Conversation

@SilvioC2C
Copy link
Contributor

Having the UUID is enough for retrieving the original Job instance via Job.load(env, uuid) and read its attributes. But the returned Job instance is actually a different one than the Job instance that triggered the function, because loading creates a new instance instead. Therefore, operations beside reading the Job attributes will result in unexpected behaviors (for example: dependencies are not stored correctly).

This commit allows retrieving the Job instance from the context itself to make it usable from within the running method.

Having the UUID is enough for retrieving the original Job instance via ``Job.load(env, uuid)`` and read its attributes.
But the returned Job instance is actually a different one than the Job instance that triggered the function, because loading creates a new instance instead.
Therefore, operations beside reading the Job attributes will result in unexpected behaviors (for example: dependencies are not stored correctly).

This commit allows retrieving the Job instance from the context itself to make it usable from within the running method.
Copy link

@Camille0907 Camille0907 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thanks

Copy link
Contributor

@simahawk simahawk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not sure to understand why you need this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants