Rework env-var interface to set log streams from unit-tests that exercise print diagnostics code.
@gapisback ci sta già lavorando.
Dal 18/1/2023.
Valutazione
Questa issue non è ancora stata valutata.
Descrizione
Under PR #514, couple of new interfaces have been added for use (mainly) by unit-tests to set the output log streams. These functions are set_log_streams_for_tests(), and set_log_streams_for_error_tests().
These set methods redirect outputs to stdout and stderr if env-var VERBOSE is set (1).
There are couple of unit-test cases which exercise print diagnostic functions. E.g.
- In
unit/btree_stress_test.cwe exercise BTree-print diagnostic code. (Under upcoming PR #531 , this test-case is being refactored into its owntest_btree_print_diags()test-case.) - Another example is
unit/splinter_test.cwhich has thistest_splinter_print_diags()test case.
Both these test cases redirect output using two different interfaces: set_log_streams_for_tests() and set_log_streams_for_error_tests(). That's a minor mis-use of these interfaces.
The real issue is that output from test cases like test_btree_print_diags() becomes very huge. It's over 6M usually. This causes CI browsers to become unwieldy when looking at such outputs.
The things we need to resolve under this issue are:
-
Rework the interfaces so that when these tests are run in CI (which currently invokes stuff with
VERBOSE=1) that none of this output is generated tostdoutorstderr(causing browsers to die). -
Provide another way for people to be able to run these tests on their own dev machines and collect the outputs from
stdout. Perhaps, we could consider different values for the env-var which will set up the desired log stream handles. -
Consider adding a new
set_log_streams_for_diagnostic_tests()interface. Rework the few unit-tests that are currently exercising these print diagnostics to use this interface (instead). -
When the support for
VERBOSE=1was added (under PR #494), the general agreement from reviewers was that it would be better to have--cmd-line-flagsto support different verbose print options, rather than this env-var. Review that approach and come up with a solution to address all usages / requirements.
In that last PR #494, following note was recorded :
Some time ago, I had added this --verbose-progress option that was used initially in functional/splinter_test.c to do some verbose progress reporting while large test workloads run. This arg is parsed and tracked as a bool in test_exec_config->verbose_progress.
With some work we could co-opt this flag to also mean what this VERBOSE=1 env-var wants to do. This boolean field may be the replacement for your newly-added Ctest_verbosity flag.
Here are some cmdline options to consider adding:
--verbose-progress: Current interface, to print verbose messages from functional tests--verbose-messages: New interface, to have errors & other messages from unit-tests being printed--verbose-diagnostics: New interface, to have outputs from diagnostic tests come tostdout
Depending on how we agree to reconcile these options, update the newly added set _log_streams_for*() interfaces accordingly.
- Lingua principale
- C
- Stelle
- 733
- Fork
- 68
- Metriche di merge delle PR
- Nessuna PR unita negli ultimi 30g
Preparare l'ambiente
- Include un Dockerfile o un file Docker Compose
- Nessun modello di pull request
- Leggi la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di vmware/splinterdb
-
Error On Running ExamplesAperta
Difficoltà 4/5 3-5 giorni Idoneità per principianti 25/100
vmware/splinterdb#600 · 5 commenti ·
-
Difficoltà 4/5 3-5 giorni Idoneità per principianti 30/100
vmware/splinterdb#597 ·
-
Is macOS support considered?Aperta
Difficoltà 5/5 Più di una settimana Idoneità per principianti 20/100
vmware/splinterdb#591 · 2 commenti ·
-
Difficoltà 4/5 3-5 giorni Idoneità per principianti 25/100
vmware/splinterdb#589 · 1 reazione ·
-
A segmentation fault in routing_filter_lookupForse di nuovo libera @ajhconway l’ha presa 1222 giorni fa e non c’è nessuna pull request aperta. Aperta
vmware/splinterdb#585 · 1 assegnatario ·
Tutte le issue di vmware/splinterdb
Issue simili
-
good first issue help wanted
Difficoltà 2/5 1-3 ore Idoneità per principianti 77/100
I maintainer di solito rispondono entro 1 giorno
-
Add `pdfcpu` to the pantryForse già presa Una pull request collegata a questa issue è aperta o già unita. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
I maintainer di solito rispondono entro 1 giorno
-
bug good first issue
Difficoltà 2/5 1-3 ore Idoneità per principianti 76/100
tmewett/BrogueCE#929 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno
-
bug game: iwd2 system: GUI
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
-
category:port-update
Difficoltà 2/5 1-3 ore Idoneità per principianti 69/100
I maintainer di solito rispondono entro 2 giorni