neptune-client
neptune-client copied to clipboard
Cannot resume a run in debug mode
#!/usr/bin/env python
# -*- coding: utf-8 -*-
import neptune.new as neptune
run = neptune.init(mode='debug')
run.sync()
run.wait()
rid = run['sys/id'].fetch()
run = neptune.init(mode='debug', run=rid)
rid = run['sys/id'].fetch()
fails with:
File "err4.py", line 8, in <module>
run = neptune.init(mode='debug', run=rid)
File "/home/wojciech/miniconda3/envs/nori/lib/python3.8/site-packages/neptune/new/internal/init_impl.py", line 259, in init
api_run = backend.get_run(project + '/' + run)
File "/home/wojciech/miniconda3/envs/nori/lib/python3.8/site-packages/neptune/new/internal/backends/neptune_backend_mock.py", line 133, in get_run
raise RunNotFound(run_id)
neptune.new.exceptions.RunNotFound: Run offline/project-placeholder/OFFLINE-1 not found.
@wjaskowski It seems we didn't anticipate this scenario initially. We are discussing internally how we can approach this.
I'll be posting updates to this issue.
I think the workaround is quite easy. It is enough to imply that when mode='debug' then run_id=None. This is fine for me at least. I use 'debug' model only when I don't want to send things to neptune.