Project

General

Profile

Actions

Feature #6456

open

make osmotestconfig.py (from osmo-python-tests) easier to use

Added by osmith about 2 months ago. Updated about 2 months ago.

Status:
In Progress
Priority:
Low
Assignee:
Target version:
-
Start date:
05/17/2024
Due date:
% Done:

40%

Spec Reference:

Description

I've been debugging why osmotestconfig.py fails with my patch https://gerrit.osmocom.org/c/osmo-sgsn/+/36845, when it runs in "make distcheck".

The purpose of the script is to run Osmocom programs with multiple configs from doc/example, write the config back, and run the program again, to see if that works and if it still runs as I understand it. This is very useful and works well as long as there are no errors.

But there are several hurdles that make it hard to figure out what went wrong in case the program returns an error, which IMHO could be improved in osmotestconfig.py:
  • It does not clearly state where a failure occurs, instead multiple checks with multiple configs are done and a counter gets increased for each failure. In the end there is only something like "ERRORS: 2", but it's not clear at all where they come from. So at least it should clearly print where it failed.
  • A lot of unrelated output is printed with each run, such as output of ps | grep ...
  • No logs of the Osmocom program that failed are shown so we can't see where they failed. I'm not sure if they are stored anywhere... in my opinion it would be useful to just stop on the first error and print the output of the Osmocom program.
  • It seems to just catch and ignore python stack traces, and increasing the error counter, instead of printing the stack traces
Actions #1

Updated by osmith about 2 months ago

  • Subject changed from make osmotestconfig.py easier to use to make osmotestconfig.py (from osmo-python-testseasier to use
Actions #2

Updated by osmith about 2 months ago

  • Description updated (diff)
Actions #3

Updated by osmith about 2 months ago

  • Description updated (diff)
Actions #4

Updated by osmith about 2 months ago

  • Subject changed from make osmotestconfig.py (from osmo-python-testseasier to use to make osmotestconfig.py (from osmo-python-tests) easier to use
Actions #5

Updated by osmith about 2 months ago

  • Status changed from New to In Progress
  • % Done changed from 0 to 40

Fixed

  • It does not clearly state where a failure occurs, instead multiple checks with multiple configs are done and a counter gets increased for each failure. In the end there is only something like "ERRORS: 2", but it's not clear at all where they come from. So at least it should clearly print where it failed.

and

  • It seems to just catch and ignore python stack traces, and increasing the error counter, instead of printing the stack traces

in:

https://gerrit.osmocom.org/q/topic:osmotestconfig

Actions

Also available in: Atom PDF

Add picture from clipboard (Maximum size: 48.8 MB)