-
Notifications
You must be signed in to change notification settings - Fork 23
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Remove tablecloth library as it's no longer needed. #373
Conversation
Now that we're finally containerised, we no longer need this library. Which is lucky for us, because https://github.com/alext/tablecloth/ was archived in February and the last commit was 4 years ago.
cc @chao-xian |
Ooh nice, the gosec linter doesn't like us using http.ListenAndServe. Could just make it a TODO but since it's come up now and it should be an easy fix, I'll try to get it in this PR. (It's not a new problem; it's just that Tablecloth was obscuring the problem from the linter before.) edit: done! |
This fixes a potential DoS vulnerability; see https://blog.cloudflare.com/the-complete-guide-to-golang-net-http-timeouts/#httplistenandserveisdoingitwrong While we're at it, parse the environment variables in main.go and pass time.Duration around internally.
Avoids some of the modal popups from the macOS firewall. Annoyingly there's still one more coming from somewhere, maybe a test library that's still binding to the zero address? Oh well.
http.ListenAndServe should never be used in production code, so let's avoid using it in our examples. Also clean up some old links and fix a tiny spelling/l10n issue :)
cdb3f6b
to
777af7b
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice one!
Now that we're finally containerised, we no longer need this library.
Which is lucky for us, because https://github.com/alext/tablecloth/ was archived in February and the last commit was 4 years ago.
Recommend reviewing commit-by-commit since a chunk of this is just generated updates from
go mod
.