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

Some requests on package.json creates Failure(": count_while1") exceptions #2683

Open
cuihtlauac opened this issue Sep 6, 2024 · 4 comments
Labels
bug Something isn't working

Comments

@cuihtlauac
Copy link
Collaborator

cuihtlauac commented Sep 6, 2024

Here are some (REQ id filtered) error logs:

06.09.24 08:20:14.776    dream.logger  INFO REQ 18344 GET /p/frama-c/29.0/doc/Server/Server_parameters/Kernel_function_set/Datatype/index.html 10.0.1.3:42504 Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; bingbot/2.0; +http://www.bing.com/bingbot.htm) Chrome/100.0.4896.127 Safari/537.36
06.09.24 08:20:14.777                  INFO REQ 18344 GET https://docs-data.ocaml.org/live/p/frama-c/29.0/doc/Server/Server_parameters/Kernel_function_set/Datatype/index.html.json
06.09.24 08:20:15.216                  INFO REQ 18344 Found documentation page for https://docs-data.ocaml.org/live/p/frama-c/29.0/doc/Server/Server_parameters/Kernel_function_set/Datatype/index.html.json
06.09.24 08:20:15.216                  INFO REQ 18344 GET https://docs-data.ocaml.org/live/p/frama-c/29.0/package.json
06.09.24 08:20:16.249    dream.logger  WARN REQ 18344 Aborted by: Failure(": count_while1")
06.09.24 08:20:16.249      dream.http ERROR REQ 18344 Failure(": count_while1")
06.09.24 08:20:16.249      dream.http ERROR REQ 18344 Raised at Stdlib__Map.Make.find in file "map.ml", line 141, characters 10-25
06.09.24 08:20:16.249      dream.http ERROR REQ 18344 Called from Logs.Tag.find in file "src/logs.ml", line 154, characters 14-32
06.09.24 09:06:10.790    dream.logger  INFO REQ 32706 GET /p/core_kernel/v0.14.1/doc/Core_kernel/Identifiable/Make_using_comparator/Hash_set/index.html 10.0.1.3:37484 Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; bingbot/2.0; +http://www.bing.com/bingbot.htm) Chrome/100.0.4896.127 Safari/537.36
06.09.24 09:06:10.790                  INFO REQ 32706 GET https://docs-data.ocaml.org/live/p/core_kernel/v0.14.1/doc/Core_kernel/Identifiable/Make_using_comparator/Hash_set/index.html.json
06.09.24 09:06:10.897                  INFO REQ 32706 Found documentation page for https://docs-data.ocaml.org/live/p/core_kernel/v0.14.1/doc/Core_kernel/Identifiable/Make_using_comparator/Hash_set/index.html.json
06.09.24 09:06:10.897                  INFO REQ 32706 GET https://docs-data.ocaml.org/live/p/core_kernel/v0.14.1/package.json
06.09.24 09:06:11.321    dream.logger  WARN REQ 32706 Aborted by: Failure(": count_while1")
06.09.24 09:06:11.321      dream.http ERROR REQ 32706 Failure(": count_while1")
06.09.24 09:06:11.321      dream.http ERROR REQ 32706 Raised at Stdlib__Map.Make.find in file "map.ml", line 141, characters 10-25
06.09.24 09:06:11.321      dream.http ERROR REQ 32706 Called from Logs.Tag.find in file "src/logs.ml", line 154, characters 14-32
06.09.24 09:23:13.158    dream.logger  INFO REQ 39309 GET /p/frama-c/28.0/doc/Wp/Wp_parameters/TerminatesVariantHyp/index.html 10.0.1.3:46948 Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; bingbot/2.0; +http://www.bing.com/bingbot.htm) Chrome/100.0.4896.127 Safari/537.36
06.09.24 09:23:13.160                  INFO REQ 39309 GET https://docs-data.ocaml.org/live/p/frama-c/28.0/doc/Wp/Wp_parameters/TerminatesVariantHyp/index.html.json
06.09.24 09:23:13.285                  INFO REQ 39309 Found documentation page for https://docs-data.ocaml.org/live/p/frama-c/28.0/doc/Wp/Wp_parameters/TerminatesVariantHyp/index.html.json
06.09.24 09:23:13.285                  INFO REQ 39309 GET https://docs-data.ocaml.org/live/p/frama-c/28.0/package.json
06.09.24 09:23:13.886    dream.logger  WARN REQ 39309 Aborted by: Failure(": count_while1")
06.09.24 09:23:13.887      dream.http ERROR REQ 39309 Failure(": count_while1")
06.09.24 09:23:13.887      dream.http ERROR REQ 39309 Raised at Stdlib__Map.Make.find in file "map.ml", line 141, characters 10-25
06.09.24 09:23:13.887      dream.http ERROR REQ 39309 Called from Logs.Tag.find in file "src/logs.ml", line 154, characters 14-32
06.09.24 09:38:14.153    dream.logger  INFO REQ 44594 GET /p/core_kernel/v0.11.1/doc/Core_kernel/Core_kernel_stable/module-type-Stable_without_comparator/index.html 10.0.1.3:45292 Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; bingbot/2.0; +http://www.bing.com/bingbot.htm) Chrome/100.0.4896.127 Safari/537.36
06.09.24 09:38:14.153                  INFO REQ 44594 GET https://docs-data.ocaml.org/live/p/core_kernel/v0.11.1/doc/Core_kernel/Core_kernel_stable/module-type-Stable_without_comparator/index.html.json
06.09.24 09:38:14.536                  INFO REQ 44594 Found documentation page for https://docs-data.ocaml.org/live/p/core_kernel/v0.11.1/doc/Core_kernel/Core_kernel_stable/module-type-Stable_without_comparator/index.html.json
06.09.24 09:38:14.536                  INFO REQ 44594 GET https://docs-data.ocaml.org/live/p/core_kernel/v0.11.1/package.json
06.09.24 09:38:14.983    dream.logger  WARN REQ 44594 Aborted by: Failure(": count_while1")
06.09.24 09:38:14.983      dream.http ERROR REQ 44594 Failure(": count_while1")
06.09.24 09:38:14.983      dream.http ERROR REQ 44594 Raised at Stdlib__Map.Make.find in file "map.ml", line 141, characters 10-25
06.09.24 09:38:14.983      dream.http ERROR REQ 44594 Called from Logs.Tag.find in file "src/logs.ml", line 154, characters 14-32
06.09.24 09:46:03.676    dream.logger  INFO REQ 46771 GET /u/f4042f6c058028f86d19508d6cfd7468/core_kernel/v0.11.1/doc/Core_kernel/Core_kernel_private/Time_intf/module-type-Time/Make/argument-1-Time/Span/Hash_queue/Key/index.html 10.0.1.3:45306 Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; bingbot/2.0; +http://www.bing.com/bingbot.htm) Chrome/100.0.4896.127 Safari/537.36
06.09.24 09:46:03.677                  INFO REQ 46771 GET https://docs-data.ocaml.org/live/u/f4042f6c058028f86d19508d6cfd7468/core_kernel/v0.11.1/doc/Core_kernel/Core_kernel_private/Time_intf/module-type-Time/Make/argument-1-Time/Span/Hash_queue/Key/index.html.json
06.09.24 09:46:03.832                  INFO REQ 46771 Found documentation page for https://docs-data.ocaml.org/live/u/f4042f6c058028f86d19508d6cfd7468/core_kernel/v0.11.1/doc/Core_kernel/Core_kernel_private/Time_intf/module-type-Time/Make/argument-1-Time/Span/Hash_queue/Key/index.html.json
06.09.24 09:46:03.832                  INFO REQ 46771 GET https://docs-data.ocaml.org/live/u/f4042f6c058028f86d19508d6cfd7468/core_kernel/v0.11.1/package.json
06.09.24 09:46:04.248    dream.logger  WARN REQ 46771 Aborted by: Failure(": count_while1")
06.09.24 09:46:04.248      dream.http ERROR REQ 46771 Failure(": count_while1")
06.09.24 09:46:04.248      dream.http ERROR REQ 46771 Raised at Stdlib__Map.Make.find in file "map.ml", line 141, characters 10-25
06.09.24 09:46:04.248      dream.http ERROR REQ 46771 Called from Logs.Tag.find in file "src/logs.ml", line 154, characters 14-32
06.09.24 10:03:50.989    dream.logger  INFO REQ 52450 GET /p/frama-c/28.1/doc/RteGen/Generator/Finite_float/index.html 10.0.1.3:58418 Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; bingbot/2.0; +http://www.bing.com/bingbot.htm) Chrome/100.0.4896.127 Safari/537.36
06.09.24 10:03:50.990                  INFO REQ 52450 GET https://docs-data.ocaml.org/live/p/frama-c/28.1/doc/RteGen/Generator/Finite_float/index.html.json
06.09.24 10:03:51.667                  INFO REQ 52450 Found documentation page for https://docs-data.ocaml.org/live/p/frama-c/28.1/doc/RteGen/Generator/Finite_float/index.html.json
06.09.24 10:03:51.667                  INFO REQ 52450 GET https://docs-data.ocaml.org/live/p/frama-c/28.1/package.json
06.09.24 10:03:52.119    dream.logger  WARN REQ 52450 Aborted by: Failure(": count_while1")
06.09.24 10:03:52.119      dream.http ERROR REQ 52450 Failure(": count_while1")
06.09.24 10:03:52.119      dream.http ERROR REQ 52450 Raised at Stdlib__Map.Make.find in file "map.ml", line 141, characters 10-25
06.09.24 10:03:52.119      dream.http ERROR REQ 52450 Called from Logs.Tag.find in file "src/logs.ml", line 154, characters 14-32
06.09.24 10:09:04.758    dream.logger  INFO REQ 54077 GET /p/frama-c/29.0/doc/Wp/ProofSession/index.html 10.0.1.3:52170 Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; bingbot/2.0; +http://www.bing.com/bingbot.htm) Chrome/100.0.4896.127 Safari/537.36
06.09.24 10:09:04.759                  INFO REQ 54077 GET https://docs-data.ocaml.org/live/p/frama-c/29.0/doc/Wp/ProofSession/index.html.json
06.09.24 10:09:04.925                  INFO REQ 54077 Found documentation page for https://docs-data.ocaml.org/live/p/frama-c/29.0/doc/Wp/ProofSession/index.html.json
06.09.24 10:09:04.925                  INFO REQ 54077 GET https://docs-data.ocaml.org/live/p/frama-c/29.0/package.json
06.09.24 10:09:05.315    dream.logger  WARN REQ 54077 Aborted by: Failure(": count_while1")
06.09.24 10:09:05.316      dream.http ERROR REQ 54077 Failure(": count_while1")
06.09.24 10:09:05.316      dream.http ERROR REQ 54077 Raised at Stdlib__Map.Make.find in file "map.ml", line 141, characters 10-25
06.09.24 10:09:05.316      dream.http ERROR REQ 54077 Called from Logs.Tag.find in file "src/logs.ml", line 154, characters 14-32
06.09.24 10:16:47.884    dream.logger  INFO REQ 56553 GET /p/octez-proto-libs/19.0/doc/Tezos_protocol_environment/V11/Make/RPC_context/index.html 10.0.1.3:46310 Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; bingbot/2.0; +http://www.bing.com/bingbot.htm) Chrome/100.0.4896.127 Safari/537.36
06.09.24 10:16:47.884                  INFO REQ 56553 GET https://docs-data.ocaml.org/live/p/octez-proto-libs/19.0/doc/Tezos_protocol_environment/V11/Make/RPC_context/index.html.json
06.09.24 10:16:48.004                  INFO REQ 56553 Found documentation page for https://docs-data.ocaml.org/live/p/octez-proto-libs/19.0/doc/Tezos_protocol_environment/V11/Make/RPC_context/index.html.json
06.09.24 10:16:48.004                  INFO REQ 56553 GET https://docs-data.ocaml.org/live/p/octez-proto-libs/19.0/package.json
06.09.24 10:16:48.590    dream.logger  WARN REQ 56553 Aborted by: Failure(": count_while1")
06.09.24 10:16:48.590      dream.http ERROR REQ 56553 Failure(": count_while1")
06.09.24 10:16:48.590      dream.http ERROR REQ 56553 Raised at Stdlib__Map.Make.find in file "map.ml", line 141, characters 10-25
06.09.24 10:16:48.590      dream.http ERROR REQ 56553 Called from Logs.Tag.find in file "src/logs.ml", line 154, characters 14-32
06.09.24 10:59:22.941    dream.logger  INFO REQ 70455 GET /p/frama-c/28.0/doc/Api_generator/Self/Kernel_function_set/As_string/index.html 10.0.1.3:53392 Mozilla/5.0 AppleWebKit/537.36 (KHTML, like Gecko; compatible; bingbot/2.0; +http://www.bing.com/bingbot.htm) Chrome/100.0.4896.127 Safari/537.36
06.09.24 10:59:22.942                  INFO REQ 70455 GET https://docs-data.ocaml.org/live/p/frama-c/28.0/doc/Api_generator/Self/Kernel_function_set/As_string/index.html.json
06.09.24 10:59:23.229                  INFO REQ 70455 Found documentation page for https://docs-data.ocaml.org/live/p/frama-c/28.0/doc/Api_generator/Self/Kernel_function_set/As_string/index.html.json
06.09.24 10:59:23.229                  INFO REQ 70455 GET https://docs-data.ocaml.org/live/p/frama-c/28.0/package.json
06.09.24 10:59:23.715    dream.logger  WARN REQ 70455 Aborted by: Failure(": count_while1")
06.09.24 10:59:23.715      dream.http ERROR REQ 70455 Failure(": count_while1")
06.09.24 10:59:23.715      dream.http ERROR REQ 70455 Raised at Stdlib__Map.Make.find in file "map.ml", line 141, characters 10-25
06.09.24 10:59:23.715      dream.http ERROR REQ 70455 Called from Logs.Tag.find in file "src/logs.ml", line 154, characters 14-32

This is transient. Sending such requests, either on a local instance or the live instance, does not automatically trigger the exception. However, the exception occurs after a request on some package.json. Can this be related to size? All are in the 300KiB range or over.

@cuihtlauac cuihtlauac added the bug Something isn't working label Sep 6, 2024
@aantron
Copy link
Contributor

aantron commented Sep 6, 2024

The actual code at this position is

raise Not_found

The code that calls this is here:

  let find : type a. a def -> set -> a option =
  fun k s ->
    try match M.find (Key.V k) s with
    | V (k', v) -> k.of_univ (k'.to_univ v)
    with Not_found -> None

AFAICT. This makes me wonder if this is a strange runtime or linking bug. I don't see how this exception could be generated, if the backtrace is correct, and the exception printer is correct. But if the runtime is indeed constructing a Failure exception when the caller expects to catch Not_found, this would seem like a runtime problem. I don't see an issue about count_while1 in the OCaml repo, maybe this has been reported in different form.

Could you cc someone from the compiler team?

I would probably do a pin of Logs with an additional | Failure _ -> assert false case or similar, that might help to confirm that there really is a Failure exception being raised, and it is here (and so the printer and backtrace are actually correct).

@aantron
Copy link
Contributor

aantron commented Sep 6, 2024

The actual string count_while1 does not seem to appear in the repos of Dream, Logs, or OCaml, at least I haven't found it with grep.

@cuihtlauac
Copy link
Collaborator Author

According to sherlocode, count_while1 seems to come from angstrom, which is an ocaml.org dependency through uri.

@aantron
Copy link
Contributor

aantron commented Sep 8, 2024

Ah. It's also a dependency through Dream (through http/af), among, probably, other paths.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
Status: 📋 Backlog
Development

No branches or pull requests

2 participants