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

Added functions for get_selected_streams #100

Merged
merged 2 commits into from
Jun 19, 2019
Merged

Conversation

KAllan357
Copy link
Contributor

No description provided.

Copy link
Contributor

@dmosorast dmosorast left a comment

Choose a reason for hiding this comment

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

Looks good. I think if it's using the catalog version of things, it should be on the catalog class. That way you can do something like catalog.get_selected_streams() which seems more OO.

I think a non-class version would be good to have too, not sure where it would go though :/

matching_index = 0
for i, catalog_entry in enumerate(catalog.streams):
if catalog_entry.tap_stream_id == currently_syncing:
matching_index = i
Copy link
Contributor

Choose a reason for hiding this comment

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

You can put a break here once the index is found. Could be a bit of time, depending on how many streams there are (e.g., big database)

@KAllan357 KAllan357 merged commit 008fa38 into master Jun 19, 2019
@KAllan357 KAllan357 deleted the get-selected-streams branch June 19, 2019 15:09
judahrand pushed a commit to judahrand/singer-python that referenced this pull request Oct 27, 2020
* Added functions for get_selected_streams

* refactor functions onto class; pylint
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