Comments (7)
I'll see if I can reproduce this in a test.
I'm not sure how it would go into deadlock like this. The algorithm is:
- start up, write own PID to config.json
- start loop, check if PID in config.json is same as own PID. If not, exit loop and fail process.
- do work, go to 2.
If a process dies unexpectedly, the new process will overwrite & take control. dura kill
overwrites the PID with None
/null
so it effectively stops all processes.
The behavior you're describing seems to be that dura kill
is running on repeat.
Are you running on Docker or an overlay filesystem? Ive seen strange behavior like this on Docker (overwrites not being recognized/consistent).
from dura.
@tkellogg ah sorry, I should have included the environment. I'm running dura on macOS 12.0.1 arm64.
I tried git pull
'ing my dura repo and re-installing. Now when I run dura serve
or dura kill
both hang with no output. Interesting!
from dura.
can you check the logs in ~/.config/dura/logs/
also i wouldn't mind seeing a ls -lathr ~/.config/dura/
and also the config file.
from dura.
I just tracked down the issue. I'll push out a fix as soon as I can. The problem is that the json file gets corrupted when overwriting with a shorter file. i.e. "overwrite" isn't what I normally think of as overwrite since it doesn't reduce the length of the file.
In your case, i think you might have restarted your laptop, which caused the PID count to reset to a shorter number, shortening the length of the file.
from dura.
Thanks for submitting this one. I don't know how I got so far without seeing it.
from dura.
Ahh good catch @tkellogg !! Thanks for the fix and for making dura :)
from dura.
@tkellogg you're theory was right by the way, here's what my config.json
looks like:
{"pid":57878,"repos":{}}sers/dan/devel/backend":{}}}}%
from dura.
Related Issues (20)
- Update: Upgrade clap to V3.1.6 & replace deprecated code in main.rs HOT 2
- Dura doesn't create any branches on github codespaces HOT 2
- brew install dura HOT 4
- Couldnt you just git commit more often? HOT 4
- Error: UnbornBranch HOT 6
- Update clap
- Data Corruption: Don't allow dura to run as root
- Ubuntu install instructions HOT 2
- Donβt create unnecessary branches
- Chronological git log HOT 2
- feature request: remove old dura branches periodically HOT 1
- support install linux and macOS with brew HOT 15
- `dura checkout` command HOT 6
- Tests broken HOT 3
- Binaries built by Github are not working HOT 6
- Prevent pushin dura branches to remote HOT 4
- stabilize config loading HOT 2
- Dura fails to capture anything if a worktree is present as a subdir of the working directory HOT 4
- Make dura branch names more informative HOT 3
- Feature Request: `dura status` command HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
π Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. πππ
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google β€οΈ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from dura.