Skip to content
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

Weird behaviour of cohttp-lwt-unix logging #770

Closed
mseri opened this issue Apr 14, 2021 · 2 comments
Closed

Weird behaviour of cohttp-lwt-unix logging #770

mseri opened this issue Apr 14, 2021 · 2 comments

Comments

@mseri
Copy link
Collaborator

mseri commented Apr 14, 2021

This can be seen from the server:

$ cohttp-server-lwt
[DEBUG][application]: Cohttp debugging output is active

$ cohttp-server-lwt --verbose
[DEBUG][application]: Cohttp debugging output is active
[INFO][cohttp.lwt.server]: Listening for HTTP request on: :: 8080

Without the verbose flag I would expect just the info to appear, instead the debug message appears always while the info message only when we use the verbose flag.

I also think that we should make the verbose output more verbose, more like python's http.server:

$ python -m http.server
Serving HTTP on :: port 8000 (http://[::]:8000/) ...
::ffff:127.0.0.1 - - [14/Apr/2021 21:24:04] "GET / HTTP/1.1" 200 -
::ffff:127.0.0.1 - - [14/Apr/2021 21:24:04] code 404, message File not found
::ffff:127.0.0.1 - - [14/Apr/2021 21:24:04] "GET /favicon.ico HTTP/1.1" 404 -
::ffff:127.0.0.1 - - [14/Apr/2021 21:24:06] "GET /bin/ HTTP/1.1" 200 -
::ffff:127.0.0.1 - - [14/Apr/2021 21:24:07] "GET /bin/lib.ml HTTP/1.1" 200 -
@mseri
Copy link
Collaborator Author

mseri commented Apr 15, 2021

We should probably deal with it when we deal with #645

@mseri
Copy link
Collaborator Author

mseri commented Apr 17, 2021

Closing since most of it has been improved by #772.
We can open a new issue if other people are unhappy with the current quiet logging

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

No branches or pull requests

1 participant