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

Make importing memory queues from the package possible #55

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

CrazyPython
Copy link

Right now to use the memory queues, we have to do this:

from queuelib.queue import FifoMemoryQueue, LifoMemoryQueue

This PR lets us do this:

from queuelib import FifoMemoryQueue, LifoMemoryQueue

This has readability gains because it means we can write:

from queuelib import FifoMemoryQueue, LifoMemoryQueue, PriorityQueue

Instead of:

from queuelib.queue import FifoMemoryQueue, LifoMemoryQueue, PriorityQueue
from queuelib.pqueue import PriorityQueue

Unless this is intentional to discourage using non-disk queues, this change should improve library ergonomics.

@codecov
Copy link

codecov bot commented Jul 22, 2021

Codecov Report

Merging #55 (7bb1179) into master (2467caf) will not change coverage.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff            @@
##            master       #55   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files            4         4           
  Lines          310       310           
  Branches        38        38           
=========================================
  Hits           310       310           
Impacted Files Coverage Δ
queuelib/__init__.py 100.00% <100.00%> (ø)

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 2467caf...7bb1179. Read the comment docs.

@Gallaecio
Copy link
Member

I wonder if we should take the chance to cover them in the README as well, for discoverability.

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.

None yet

3 participants