Skip to content

Add progress callback and example #48

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

Merged
merged 5 commits into from
Apr 6, 2021
Merged

Conversation

glennmatthews
Copy link
Collaborator

Fixes #47.

Added optional callback argument to diff_from/diff_to/sync_from/sync_to APIs. This allows the caller to provide a callback function which will be invoked perioidically as callback(stage, current, total) during the diff and sync processes, which can be used to print status to the console or to update a progress bar - useful especially during long-running diffs and syncs of large data sets such as an import from NetBox to Nautobot.

Copy link
Contributor

@dgarros dgarros left a comment

Choose a reason for hiding this comment

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

LGTM

@glennmatthews glennmatthews merged commit a0b700a into master Apr 6, 2021
@dgarros dgarros deleted the gfm-progress-bar branch October 8, 2021 17:55
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.

Add option for progress-bar type reporting
2 participants