Better sharing UX with nbgitpuller and contextual error handling

TL;DR

nbgitpuller now has improved UX context-aware error handling. Update to version 1.3.0 and let us know what you think by opening an issue 🚀

What is nbgitpuller?

nbgitpuller lets you distribute content to a Jupyter user via the click of a button! This allows your users to focus on the content without needing to understand git or other version control machinery.

nbgitpuller provides automatic, opinionated conflict resolution by using git under the hood. It is commonly used to distribute content to multiple users of a JupyterHub, though it works just fine on an individual person’s computer, if they have Jupyter installed.

Here’s an example of nbgitpuller in action:

  1. The author uses the nbgitpuller link generator to create a link.

  1. The consumer clicks the link, and the content is pulled into a live Jupyter session.

Example use cases for sharing with nbgitpuller include:

and many more!

How does nbgitpuller work?

The nbgitpuller package is installed in the compute environment. The compute environment now has a /git-pull endpoint URL that can understand where to pull content from using URL parameters. Syncing content critically depends on git operations to fetch, checkout, clone, merge, commit, etc.

When it goes wrong

Based on the data sent through by the kind folks running the Berkeley DataHub, there were 2163 logs available, of which:

Bar chart showing the most common errors users faced.]
Bar chart showing the most common errors users faced.]

The remaining errors (10%) were mostly ‘checkout’ errors. This represents the most frequent errors as seen by students.

Bar chart showing the most unique errors link authors made.
Bar chart showing the most unique errors link authors made.

In the same set of logs, there were 172 unique errors: most ‘ls-remote’ errors come from mistakes in the content repo URL. This represents the most uniquely common errors made by instructors.

Merge conflicts

If the link author changes content after the consumer clicks a link, then nbgitpuller needs to sync updates for the consumer on subsequent link clicks. The nbgitpuller merging strategy makes opinionated choices so that the link consumer never has to interact with git, and will always preserve the consumer’s working changes.

Things can go wrong when

Error UX (old)

Old UX for merge errors.
Old UX for merge errors.

Problems with the old UX include:

Error UX (new)

New UX for merge errors.
New UX for merge errors.

New improvements to the UX include:

Learn more

Acknowledgements