Skip to content

Move key_split() back to utils.py#6529

Merged
mrocklin merged 1 commit intodask:masterfrom
madsbk:move_key_split_to_utils
Aug 18, 2020
Merged

Move key_split() back to utils.py#6529
mrocklin merged 1 commit intodask:masterfrom
madsbk:move_key_split_to_utils

Conversation

@madsbk
Copy link
Copy Markdown
Contributor

@madsbk madsbk commented Aug 18, 2020

This PR moves key_split() back to utils.py. It was moved previously as part of #1919 to fix "messy circular imports" however I don't think this is needed anymore. As far as I can see the dependencies are:

utils.py -> core.py -> utils_test.py

thus importing utils.py from anywhere excluding core.py and utils_test.py should be fine.

My issue with having key_split() in optimization.py is that I get circular imports when optimization.py imports highlevelgraph.py:

optimization.py -> highlevelgraph.py -> utils.py -> optimization.py 
  • Tests added / passed
  • Passes black dask / flake8 dask

@mrocklin
Copy link
Copy Markdown
Member

This seems good to me. Thanks for the cleanup @madsbk

@madsbk madsbk marked this pull request as ready for review August 18, 2020 19:38
@mrocklin mrocklin merged commit cd1883e into dask:master Aug 18, 2020
sjperkins added a commit to ratt-ru/dask-ms that referenced this pull request Aug 27, 2020
kumarprabhu1988 pushed a commit to kumarprabhu1988/dask that referenced this pull request Oct 29, 2020
@madsbk madsbk deleted the move_key_split_to_utils branch February 16, 2021 08:59
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