Skip to content

Fix default context handling#754

Merged
ogrisel merged 7 commits intojoblib:masterfrom
tomMoral:FIX_default_context
Aug 27, 2018
Merged

Fix default context handling#754
ogrisel merged 7 commits intojoblib:masterfrom
tomMoral:FIX_default_context

Conversation

@tomMoral
Copy link
Copy Markdown
Contributor

No description provided.

@codecov
Copy link
Copy Markdown

codecov bot commented Aug 23, 2018

Codecov Report

Merging #754 into master will increase coverage by 0.1%.
The diff coverage is 95%.

Impacted file tree graph

@@            Coverage Diff            @@
##           master     #754     +/-   ##
=========================================
+ Coverage   95.23%   95.34%   +0.1%     
=========================================
  Files          43       44      +1     
  Lines        6208     6225     +17     
=========================================
+ Hits         5912     5935     +23     
+ Misses        296      290      -6
Impacted Files Coverage Δ
joblib/_multiprocessing_helpers.py 80.76% <100%> (+4.57%) ⬆️
joblib/test/test_module.py 100% <100%> (ø)
joblib/parallel.py 97.56% <80%> (-0.53%) ⬇️
joblib/_parallel_backends.py 94.4% <0%> (-0.4%) ⬇️
joblib/test/test_dask.py 98.11% <0%> (+0.62%) ⬆️
joblib/test/test_numpy_pickle.py 98.35% <0%> (+0.65%) ⬆️
joblib/disk.py 88.33% <0%> (+6.66%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 370dca7...8bc4dde. Read the comment docs.

Copy link
Copy Markdown
Contributor

@ogrisel ogrisel left a comment

Choose a reason for hiding this comment

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

Ok, see comments:

# context which is available on all supported platforms.
ctx = mp.get_context('spawn')
Semaphore = ctx.Semaphore()
_sem = Semaphore
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

typo:

    Semaphore = ctx.Semaphore
_sem = Semaphore()


@pytest.mark.skipif(sys.version_info < (3, 3), reason="Need python3.3+")
def test_import():
# check that the import does not set the start_method for multiprocessing
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Please make it explicit that this is a non-regression test.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Or just:

# check that importing joblib does not implicitly set the global start_method for multiprocessing

@ogrisel ogrisel changed the title Fix default context handeling Fix default context handling Aug 27, 2018
@ogrisel ogrisel merged commit d4d6a13 into joblib:master Aug 27, 2018
@tomMoral tomMoral deleted the FIX_default_context branch August 27, 2018 07:57
yarikoptic added a commit to yarikoptic/joblib that referenced this pull request Sep 4, 2018
* tag '0.12.3': (23 commits)
  Release 0.12.3
  Loky 2.2.1 (joblib#760)
  FIX: FileSystemStoreBackend string representation only returning location (path) (joblib#765)
  Add optional dependency on psutil
  MAINT remove brittle time based assertion in test (joblib#761)
  Fix a bug in nesting level computation with FallbackToBackend(SequentialBackend()) (joblib#759)
  Make docstring more consistent with project style
  Improved performance of call_and_shelve (joblib#757)
  Better test name
  Fix default context handling (joblib#754)
  cloudpickle 0.5.5 (joblib#756)
  Fixed error where filter args was consuming kwargs (joblib#750)
  FIX pickle roundtrip for Memory and related classes. (joblib#746)
  test that passes but timeout appveyor because of unclosed semaphore tracker (joblib#676)
  DOC: fine tune compressor example dataset size for ReadTheDocs (joblib#753)
  FIX: MemorizedResult not picklable (joblib#752)
  [MRG] Better message with py27 when lz4 is not installed (joblib#740)
  MNT remove mutable default value for backend_options parameter (joblib#748)
  MNT create test file for _store_backends module (joblib#749)
  DOC consistently use memory rather than mem in memory.rst (joblib#744)
  ...
yarikoptic added a commit to yarikoptic/joblib that referenced this pull request Sep 4, 2018
* releases: (23 commits)
  Release 0.12.3
  Loky 2.2.1 (joblib#760)
  FIX: FileSystemStoreBackend string representation only returning location (path) (joblib#765)
  Add optional dependency on psutil
  MAINT remove brittle time based assertion in test (joblib#761)
  Fix a bug in nesting level computation with FallbackToBackend(SequentialBackend()) (joblib#759)
  Make docstring more consistent with project style
  Improved performance of call_and_shelve (joblib#757)
  Better test name
  Fix default context handling (joblib#754)
  cloudpickle 0.5.5 (joblib#756)
  Fixed error where filter args was consuming kwargs (joblib#750)
  FIX pickle roundtrip for Memory and related classes. (joblib#746)
  test that passes but timeout appveyor because of unclosed semaphore tracker (joblib#676)
  DOC: fine tune compressor example dataset size for ReadTheDocs (joblib#753)
  FIX: MemorizedResult not picklable (joblib#752)
  [MRG] Better message with py27 when lz4 is not installed (joblib#740)
  MNT remove mutable default value for backend_options parameter (joblib#748)
  MNT create test file for _store_backends module (joblib#749)
  DOC consistently use memory rather than mem in memory.rst (joblib#744)
  ...
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