Skip to content

Conversation

@skatsubo
Copy link
Contributor

@skatsubo skatsubo commented Dec 1, 2025

  • Readme
  • Messages and comments in code
  • requestbody = reqbody.Bytes() (duplicated in the response handling) -> responsebody = respbody.Bytes()

README.md Outdated
Without the `--no-exit` flag, the above fails:
```bash
$ httptap -- setsid setsid curl http://httpbin.org/get
$ httptap -- setsid curl http://httpbin.org/get
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This, actually, is intentional. You need two setsid calls to fully daemonize a process. This could use some explanation, but you can verify that

$ httptap -- setsid curl http://monasticacademy.org

actually works, which is not what we want (the purpose of this section of the readme is to give an example that doesn't work without --no-exit), whereas

$ httptap -- setsid setsid curl http://monasticacademy.org

fails, which is what we want here.

Copy link
Contributor Author

@skatsubo skatsubo Dec 3, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the explanation. Fixed/reverted this line.
Yeah, I suspected some gotchas here 😄 Especially as the Python code example uses just one os.setsid().
(I was going to try it while creating the PR, but the released version from February does not have --no-exit, and when compiling from main I encountered various unrelated hiccups due to my dev environment)

Copy link
Member

@alexflint alexflint left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey @skatsubo, thanks for this! I have one minor comment, which is that the double-invocation of setsid was actually intentional. Other than that, thanks for submitting this!

@alexflint alexflint merged commit d8d6190 into monasticacademy:main Dec 4, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants