Skip to content
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

Pass all variables to task when TaskConfig.variables_to_fetch==[] #485

Merged
merged 1 commit into from
Sep 26, 2024

Conversation

PunchyRascal
Copy link
Contributor

Pass all variables to task when TaskConfig.variables_to_fetch==[]
Because empty list in TaskConfig.variables_to_fetch results in all variables being fetched from Zeebe and it is reasonably expected that they will also be passed to the task.

+ use nonlocal variables instead of instance properties in tests to avoid potential conflicts between tests

Changes

  • Pass all job variables to task when expected
  • Use nonlocal variables in tests to improve encapsulation

API Updates

New Features (required)

It is now possible to use *args, **kwargs in task and receive all variables there.

Deprecations (required)

N/A

Enhancements (optional)

N/A

Checklist

  • [✅] Unit tests
  • [❔] Documentation

References

Broken in commit related to #404

@PunchyRascal PunchyRascal marked this pull request as ready for review September 19, 2024 11:35
@PunchyRascal PunchyRascal changed the title Task all params fix Pass all variables to task when TaskConfig.variables_to_fetch==[] Sep 19, 2024
@PunchyRascal PunchyRascal changed the title Pass all variables to task when TaskConfig.variables_to_fetch==[] Pass all variables to task when TaskConfig.variables_to_fetch==[] Sep 19, 2024
@dimastbk
Copy link
Collaborator

Hi. Please, rebase your PR

Because empty list in variables_to_fetch results in all variables being
fetched from Zeebe and it is reasonably expected that they will also
be passed to the task

+ use nonlocal variables instead of instance properties in tests
  to avoid potential conflicts between tests
@dimastbk dimastbk merged commit 614559d into camunda-community-hub:master Sep 26, 2024
16 checks passed
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.

2 participants