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

add TaskStatusReporter class to fix Windows pickle issue #1992

Merged
merged 2 commits into from
Feb 2, 2017

Conversation

davemt
Copy link
Contributor

@davemt davemt commented Jan 19, 2017

Windows uses a different method when forking, which caused issues with
the task status updating functions that are passed to TaskProcess
(they need to be pickle-able). Basically running with >1 worker was broken
on Windows. See #1423

This fixes the problem by introducing a new pickle-able class to encapsulate task status
update methods.

Have you tested this? If so, how?

  • There was existing test coverage for code that was refactored (e.g. test/task_status_message_test.py)
  • I ran a test task tree on a Windows machine with --workers 10 before the change to reproduce the issue (got pickle error), then after and the test succeeded -- tested with py2.7

Windows uses a different method when forking, which causes issues with
the task status updating functions that are passed to TaskProcess
(they need to be pickle-able).

This introduces a new class to encapsulate task status updating that is
also pickle-able.
Copy link
Contributor

@Tarrasch Tarrasch left a comment

Choose a reason for hiding this comment

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

I love it. Just fix the minor flake8 issue please. :)

@Tarrasch
Copy link
Contributor

Unless anybody objects or have other review-points. I'll merge this in soon.

@Tarrasch Tarrasch merged commit 69f0974 into spotify:master Feb 2, 2017
kreczko pushed a commit to kreczko/luigi that referenced this pull request Mar 28, 2017
Windows uses a different method when forking, which causes issues with
the task status updating functions that are passed to TaskProcess
(they need to be pickle-able).

This introduces a new class to encapsulate task status updating that is
also pickle-able.
This was referenced Jun 29, 2022
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