Radish alpha
h
rad:z3gqcJUoA1n9HaHKufZs5FCSGazv5
Radicle Heartwood Protocol & Stack
Radicle
Git
Ignore broken pipe in Element::print()
Merged did:key:z6MkrxqT...yQRh opened 2 months ago

I found the issue reported by spacefrogg in

https://radicle.zulipchat.com/#narrow/channel/369277-heartwood/topic/Terminal.20output.20handling.20and.20pipes/with/574695784

And figured that this might be a low-hanging fruit (at least the exact error they reported), so I went ahead and fixed it with this patch.

I am not yet sure whether this is “the way to go” for the codebase, but well, it is a proposal. Tell me what you think!

did:key:z6MkrxqT...yQRh opened with revision 29ebeb6c on base 423cf604 +13 -1 2 months ago

I found the issue reported by spacefrogg in

https://radicle.zulipchat.com/#narrow/channel/369277-heartwood/topic/Terminal.20output.20handling.20and.20pipes/with/574695784

And figured that this might be a low-hanging fruit (at least the exact error they reported), so I went ahead and fixed it with this patch.

I am not yet sure whether this is “the way to go” for the codebase, but well, it is a proposal. Tell me what you think!

did:key:z6MkrxqT...yQRh commented on revision 1 2 months ago

Note that I have not yet tested that patch, but I can do that if you want me to.

liw commented on revision 1 2 months ago

I like this and it works for me when I try: cargo run --bin rad -- config | head

(The same thing with rad config gives a big red error.)

fintohaps pushed revision 2 316e03e3 on base 22b2871f +383 -97 27 days ago

Systemic Approach to handling SIGPIPE

Working off of the back of the previous revision, this set of changes attempts to address the SIGPIPE issue across the whole rad CLI.

It first introduces tests to ensure the behaviour is fixed when the radicle-cli changes are made – removing the ignore from the two failing tests.

It then avoids the use of println! and print! macros in the radicle-term crate.

That sets up the changes for radicle-cli to use the radicle-term functions, denying any print! and println! macros. On top of this, it adds a backstop handling of SIGPIPE as another panic hook, as well as handling SIGPIPE at the top-level of run.

The final changes are a renaming refactor to better represent the behaviours of each flavour of print function.

fintohaps pushed revision 3 f128e9a2 on base 22b2871f +413 -97 27 days ago

Changes:

  • Print panic trace to stderr if debug_assertions is enabled
  • Factor out handling of panic into function
lorenz pushed revision 4 36dd83f2 on base 22b2871f +432 -115 15 days ago

Review

lorenz pushed revision 5 9fc6ae44 on base 22b2871f +432 -115 15 days ago

Remove unnecessary space.

ade pushed revision 6 dd252b5e on base 22b2871f +489 -115 15 days ago
fintohaps pushed revision 7 6ec5e9a7 on base bda92b21 +432 -115 2 days ago

Changes:

  • Accepted lorenz’s REVIEW commits
  • Reworded “Handle” commit message
  • TODO: understand ade’s test
lorenz pushed revision 8 d160e383 on base bda92b21 +431 -115 1 day ago

Nitpicking

lorenz pushed revision 9 e715b7a8 on base 7b07e57b +431 -115 1 day ago

Rebase

lorenz merged revision e715b7a8 at 378365aa 1 day ago