devlog 1

I should have a dispatch method that receives an XvcRootOpt and runs a command with it. The dispatcher can also update the XvcRoot from None to Some(XvcRoot) in some cases, so it should receive a mutable XvcRootOpt or return one after receiving the ownership.

The issue with having a mutable element is that we need to update XvcRoot from Arc to Arc<RwLock> that will make almost all machinery around XvcRoot to require to lock the object first. This is a too large refactoring.

However I can write an xvc_root! macro to replace xvc_root.read() or whatever required to minimize the code changes. XvcRoot can also be a wrapper object but that’s too much fuss and the responsibility may be mistaken.

Let’s update the type and let the dispatcher update XvcRootInner when only necessary. Let’s see what will require to be updated.


We have a bug in Python bindings, that xvc.file.track() enters an infinite loop.

There can be multiple reasons but are you sure that xvc cli works with the same command?

Let’s start testing bu creating another notebook server.

The notebook creates am Xvc repo successfully and returns the root with xvc.root() but xvc.file().track("test-data/dir-0001/") never finishes.

It’s likely that this is caused by something in the background threads.

The CLI command completes successfully but we may be giving the command incorrectly. Let’s try dir-0001 only.

Even if you’re giving the incorrect path, it shouldn’t enter an infinite loop.

When I give the correct path dir-0001, it returns. There may be something going on with finding the root of Xvc repo.

It returns but it’s also giving an error that it cannot find a repository. You should take a closer look.

Xvc struct wasn’t implementing Debug, added it.

Let’s add it to others, XvcFile etc.

Added it. Recompiling to get more info when we run track with an incorrect path.

You can also make run after commit not to start a new server if there is also one running.

Added conditionals and now it runs the server if there is no one running in the background.

PORT=7979
if [[ ! -s "$(ps ax | rg -v ps | rg jupyter-lab | rg $PORT)" ]] ; then
  jupyter lab --port=$PORT --notebook-dir=Readme/ &
  open http://localhost:${PORT}/lab/workspaces/auto-H/tree/Readme.ipynb
fi

/xvc/ /debugging/ /shell/ /jupyter-lab/