pespin has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/41641?usp=email )
Change subject: msc: Fix TC_stat_bsc_sctp_disconnected expectancies
......................................................................
msc: Fix TC_stat_bsc_sctp_disconnected expectancies
The test was passing when run alone, but was failing when run after
other tests using other BSCs/RNCs, since osmo-msc learned about them and
hence ran_peers.total was >1.
Change-Id: I22da7ae5c282a30e933f2f29b671ece8b6147ce9
---
M msc/MSC_Tests.ttcn
1 file changed, 4 insertions(+), 2 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/osmo-ttcn3-hacks refs/changes/41/41641/1
diff --git a/msc/MSC_Tests.ttcn b/msc/MSC_Tests.ttcn
index 013ecfd..c85a458 100644
--- a/msc/MSC_Tests.ttcn
+++ b/msc/MSC_Tests.ttcn
@@ -7671,12 +7671,14 @@
var BSC_ConnHdlrPars pars;
var charstring msc_stats_prefix := f_msc_stats_prefix();
+ /* ran_peers.total: Despite we only use 1 RAN_CONN in this test, previous tests may have
+ * used more of them (up to configured NUM_BSC), and hence IUT may remember about them: */
var StatsDExpects expect_connected := {
- {name := msc_stats_prefix & "ran_peers.total", mtype := "g", min := 1, max := 1},
+ {name := msc_stats_prefix & "ran_peers.total", mtype := "g", min := 1, max := NUM_BSC},
{name := msc_stats_prefix & "ran_peers.active", mtype := "g", min := 1, max := 1}
};
var StatsDExpects expect_disconnected := {
- {name := msc_stats_prefix & "ran_peers.total", mtype := "g", min := 1, max := 1},
+ {name := msc_stats_prefix & "ran_peers.total", mtype := "g", min := 1, max := NUM_BSC},
{name := msc_stats_prefix & "ran_peers.active", mtype := "g", min := 0, max := 0}
};
--
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/41641?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email
Gerrit-MessageType: newchange
Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: I22da7ae5c282a30e933f2f29b671ece8b6147ce9
Gerrit-Change-Number: 41641
Gerrit-PatchSet: 1
Gerrit-Owner: pespin <pespin(a)sysmocom.de>
pespin has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/41640?usp=email )
Change subject: StatsD_Checker: Abort on expectancy failure with clear status message
......................................................................
StatsD_Checker: Abort on expectancy failure with clear status message
Before this commit, a statsd expect failure would let the test continue
the test for a while and then finally log a rellay generic timeout
message, which makes really difficult to understand what's going on and
why is the test failing.
Let's terminate the test early if a test expectation fails, so it's a
lot easier to debug.
Add an extra param to be able to use the API for test logic to check the
state without failing/aborting. This is not really used anywhere so far
but the API was built this way and I indeed think it may be handy in the
future.
Change-Id: Ibc3d079c2a45aa22f9e2e42d75109cae66530f86
---
M library/StatsD_Checker.ttcnpp
1 file changed, 24 insertions(+), 12 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/osmo-ttcn3-hacks refs/changes/40/41640/1
diff --git a/library/StatsD_Checker.ttcnpp b/library/StatsD_Checker.ttcnpp
index 081e6e1..9d0d823 100644
--- a/library/StatsD_Checker.ttcnpp
+++ b/library/StatsD_Checker.ttcnpp
@@ -90,7 +90,11 @@
signature STATSD_reset();
signature STATSD_snapshot(in StatsDMetricKeys keys, in boolean since_last_snapshot) return StatsDMetrics;
-signature STATSD_expect(in StatsDExpects expects, in boolean wait_converge, in boolean use_snapshot, in StatsDMetrics snapshot) return boolean;
+signature STATSD_expect(in StatsDExpects expects,
+ in boolean wait_converge,
+ in boolean abort_on_failure,
+ in boolean use_snapshot,
+ in StatsDMetrics snapshot) return boolean;
type port STATSD_PROC_PT procedure {
inout STATSD_reset, STATSD_snapshot, STATSD_expect;
@@ -106,6 +110,7 @@
var boolean since_last_snapshot;
var StatsDExpects expects;
var boolean wait_converge;
+ var boolean abort_on_failure;
var boolean use_snapshot;
var StatsDMetrics snapshot;
var Result res;
@@ -149,9 +154,9 @@
snapshot := f_statsd_checker_snapshot(keys, since_last_snapshot);
STATSD_PROC.reply(STATSD_snapshot:{keys, since_last_snapshot} value snapshot) to vc_conn;
}
- [] STATSD_PROC.getcall(STATSD_expect:{?, ?, ?, ?}) -> param(expects, wait_converge, use_snapshot, snapshot) sender vc_conn {
- var boolean success := f_statsd_checker_expect(expects, wait_converge, use_snapshot, snapshot);
- STATSD_PROC.reply(STATSD_expect:{expects, wait_converge, use_snapshot, snapshot} value success) to vc_conn;
+ [] STATSD_PROC.getcall(STATSD_expect:{?, ?, ?, ?, ?}) -> param(expects, wait_converge, abort_on_failure, use_snapshot, snapshot) sender vc_conn {
+ var boolean success := f_statsd_checker_expect(expects, wait_converge, abort_on_failure, use_snapshot, snapshot);
+ STATSD_PROC.reply(STATSD_expect:{expects, wait_converge, abort_on_failure, use_snapshot, snapshot} value success) to vc_conn;
}
}
}
@@ -318,6 +323,7 @@
private function f_statsd_checker_expect(StatsDExpects expects,
boolean wait_converge := false,
+ boolean abort_on_failure := true,
boolean use_snapshot := false,
StatsDMetrics snapshot := {}) runs on StatsD_Checker_CT return boolean {
var default t;
@@ -363,7 +369,10 @@
" (min: ", expects[i].min, ", max: ", expects[i].max, ")");
}
}
- setverdict(fail, "Timeout waiting for metrics");
+ if (abort_on_failure) {
+ Misc_Helpers.f_shutdown(__BFILE__, __LINE__, fail,
+ log2str("Timeout waiting for expect=", expects, " matched=", matched));
+ }
return false;
}
}
@@ -381,7 +390,10 @@
}
log("Metric: ", metric);
log("Expect: ", expects[res.idx]);
- setverdict(fail, "Metric failed expectation ", metric, " vs ", expects[res.idx]);
+ if (abort_on_failure) {
+ Misc_Helpers.f_shutdown(__BFILE__, __LINE__, fail,
+ log2str("Metric failed expectation ", metric, " vs ", expects[res.idx]));
+ }
return false;
}
if (res.kind == e_Matched) {
@@ -441,20 +453,20 @@
return snapshot;
}
-function f_statsd_expect(StatsDExpects expects, boolean wait_converge := false) runs on StatsD_ConnHdlr return boolean {
+function f_statsd_expect(StatsDExpects expects, boolean wait_converge := false, boolean abort_on_failure := true) runs on StatsD_ConnHdlr return boolean {
var boolean res;
if (not mp_enable_stats) {
return true;
}
- STATSD_PROC.call(STATSD_expect:{expects, wait_converge, false, {}}) {
- [] STATSD_PROC.getreply(STATSD_expect:{expects, wait_converge, false, {}}) -> value res;
+ STATSD_PROC.call(STATSD_expect:{expects, wait_converge, abort_on_failure, false, {}}) {
+ [] STATSD_PROC.getreply(STATSD_expect:{expects, wait_converge, abort_on_failure, false, {}}) -> value res;
}
return res;
}
-function f_statsd_expect_from_snapshot(StatsDExpects expects, boolean wait_converge := false,
+function f_statsd_expect_from_snapshot(StatsDExpects expects, boolean wait_converge := false, boolean abort_on_failure := true,
StatsDMetrics snapshot := {}) runs on StatsD_ConnHdlr return boolean {
var boolean res;
@@ -462,8 +474,8 @@
return true;
}
- STATSD_PROC.call(STATSD_expect:{expects, wait_converge, true, snapshot}) {
- [] STATSD_PROC.getreply(STATSD_expect:{expects, wait_converge, true, snapshot}) -> value res;
+ STATSD_PROC.call(STATSD_expect:{expects, wait_converge, abort_on_failure, true, snapshot}) {
+ [] STATSD_PROC.getreply(STATSD_expect:{expects, wait_converge, abort_on_failure, true, snapshot}) -> value res;
}
return res;
}
--
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/41640?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email
Gerrit-MessageType: newchange
Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: Ibc3d079c2a45aa22f9e2e42d75109cae66530f86
Gerrit-Change-Number: 41640
Gerrit-PatchSet: 1
Gerrit-Owner: pespin <pespin(a)sysmocom.de>
Attention is currently required from: neels.
fixeria has posted comments on this change by neels. ( https://gerrit.osmocom.org/c/pysim/+/41639?usp=email )
Change subject: fix downstream error: ImportError: cannot import name 'style' from 'cmd2'
......................................................................
Patch Set 1: Code-Review+1
(1 comment)
Patchset:
PS1:
We should migrate to pyproject.toml (https://packaging.python.org/en/latest/guides/writing-pyproject-toml/) and get rid of `setup.cfg` + `setup.py` + `requirements.txt`.
--
To view, visit https://gerrit.osmocom.org/c/pysim/+/41639?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email
Gerrit-MessageType: comment
Gerrit-Project: pysim
Gerrit-Branch: master
Gerrit-Change-Id: I5186f242dbc1b770e3ab8cdca7f27d2a1029fff6
Gerrit-Change-Number: 41639
Gerrit-PatchSet: 1
Gerrit-Owner: neels <nhofmeyr(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Attention: neels <nhofmeyr(a)sysmocom.de>
Gerrit-Comment-Date: Wed, 10 Dec 2025 09:17:28 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: Yes
Attention is currently required from: falconia, laforge, neels.
pespin has posted comments on this change by falconia. ( https://gerrit.osmocom.org/c/osmo-bsc/+/41630?usp=email )
Change subject: MGW control: migrate to new API for codecs and payload types
......................................................................
Patch Set 1:
(1 comment)
Patchset:
PS1:
> In the present patch I change osmo-bsc to use a libosmo-mgcp-client API update that happened 3 relea […]
Done
--
To view, visit https://gerrit.osmocom.org/c/osmo-bsc/+/41630?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email
Gerrit-MessageType: comment
Gerrit-Project: osmo-bsc
Gerrit-Branch: master
Gerrit-Change-Id: Iafc38a3da64ce7c2f060a32864174dcde9f57b56
Gerrit-Change-Number: 41630
Gerrit-PatchSet: 1
Gerrit-Owner: falconia <falcon(a)freecalypso.org>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Reviewer: neels <nhofmeyr(a)sysmocom.de>
Gerrit-CC: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: falconia <falcon(a)freecalypso.org>
Gerrit-Attention: neels <nhofmeyr(a)sysmocom.de>
Gerrit-Attention: laforge <laforge(a)osmocom.org>
Gerrit-Comment-Date: Tue, 09 Dec 2025 18:29:05 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: falconia <falcon(a)freecalypso.org>
Comment-In-Reply-To: laforge <laforge(a)osmocom.org>
Comment-In-Reply-To: pespin <pespin(a)sysmocom.de>
Attention is currently required from: laforge, neels, pespin.
falconia has posted comments on this change by falconia. ( https://gerrit.osmocom.org/c/osmo-bsc/+/41630?usp=email )
Change subject: MGW control: migrate to new API for codecs and payload types
......................................................................
Patch Set 1:
(1 comment)
Patchset:
PS1:
> ACK
In the present patch I change osmo-bsc to use a libosmo-mgcp-client API update that happened 3 release cycles ago:
https://gerrit.osmocom.org/c/osmo-mgw/+/34899
The above patch was merged in 2024-01, thus 2024-07 and 2025-02 releases already had the new API which I am using here, with the old one marked as deprecated. It just so happens that neither osmo-bsc nor osmo-msc was updated to use the new API until now! The present patch fixes osmo-bsc, while osmo-msc still remains.
The next patch in this series, the one that currently fails to build because the needed library patch hasn't been merged yet, does have a TODO-RELEASE entry noting use of the new library API - but none should be needed in this patch, as I understand it.
--
To view, visit https://gerrit.osmocom.org/c/osmo-bsc/+/41630?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email
Gerrit-MessageType: comment
Gerrit-Project: osmo-bsc
Gerrit-Branch: master
Gerrit-Change-Id: Iafc38a3da64ce7c2f060a32864174dcde9f57b56
Gerrit-Change-Number: 41630
Gerrit-PatchSet: 1
Gerrit-Owner: falconia <falcon(a)freecalypso.org>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria <vyanitskiy(a)sysmocom.de>
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Reviewer: neels <nhofmeyr(a)sysmocom.de>
Gerrit-CC: pespin <pespin(a)sysmocom.de>
Gerrit-Attention: neels <nhofmeyr(a)sysmocom.de>
Gerrit-Attention: laforge <laforge(a)osmocom.org>
Gerrit-Attention: pespin <pespin(a)sysmocom.de>
Gerrit-Comment-Date: Tue, 09 Dec 2025 17:12:34 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: laforge <laforge(a)osmocom.org>
Comment-In-Reply-To: pespin <pespin(a)sysmocom.de>
Attention is currently required from: dexter, lynxis lazus.
laforge has posted comments on this change by laforge. ( https://gerrit.osmocom.org/c/pysim/+/41579?usp=email )
Change subject: pySim.runtime: Fix file selection by upper case hex FID
......................................................................
Patch Set 1:
(1 comment)
File pySim/runtime.py:
https://gerrit.osmocom.org/c/pysim/+/41579/comment/310f142b_11307f59?usp=em… :
PS1, Line 488: name = name.lower()
> I think this is ok. I see lines like this in select also. […]
I agree, but didn't immediately see a way to implement this in a generic way.
--
To view, visit https://gerrit.osmocom.org/c/pysim/+/41579?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email
Gerrit-MessageType: comment
Gerrit-Project: pysim
Gerrit-Branch: master
Gerrit-Change-Id: Idd0db1f4bbd3ee9eec20f5fd0f4371c2882950cd
Gerrit-Change-Number: 41579
Gerrit-PatchSet: 1
Gerrit-Owner: laforge <laforge(a)osmocom.org>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: dexter <pmaier(a)sysmocom.de>
Gerrit-Reviewer: lynxis lazus <lynxis(a)fe80.eu>
Gerrit-Attention: lynxis lazus <lynxis(a)fe80.eu>
Gerrit-Attention: dexter <pmaier(a)sysmocom.de>
Gerrit-Comment-Date: Tue, 09 Dec 2025 16:24:30 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: dexter <pmaier(a)sysmocom.de>
laforge has submitted this change. ( https://gerrit.osmocom.org/c/pysim/+/41528?usp=email )
Change subject: contrib/saip-tool: Use repr() on security domain keys
......................................................................
contrib/saip-tool: Use repr() on security domain keys
Let's not reinvent the wheel of printing such data structures and use
the repr method provided by the respective class instead. This also
adds the missing key_usage_qualifier information to the print-out,
as well as the mac_len of the key components.
Change-Id: Iaead4a02f07130fd00bcecc43e1c843f1c221e63
---
M contrib/saip-tool.py
1 file changed, 1 insertion(+), 1 deletion(-)
Approvals:
Jenkins Builder: Verified
dexter: Looks good to me, approved; Verified
diff --git a/contrib/saip-tool.py b/contrib/saip-tool.py
index fd6d373..71113d3 100755
--- a/contrib/saip-tool.py
+++ b/contrib/saip-tool.py
@@ -329,7 +329,7 @@
print("Security domain Instance AID: %s" % b2h(sd.decoded['instance']['instanceAID']))
# FIXME: 'applicationSpecificParametersC9' parsing to figure out enabled SCP
for key in sd.keys:
- print("\tKVN=0x%02x, KID=0x%02x, %s" % (key.key_version_number, key.key_identifier, key.key_components))
+ print("\t%s" % repr(key))
# RFM
print()
--
To view, visit https://gerrit.osmocom.org/c/pysim/+/41528?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email
Gerrit-MessageType: merged
Gerrit-Project: pysim
Gerrit-Branch: master
Gerrit-Change-Id: Iaead4a02f07130fd00bcecc43e1c843f1c221e63
Gerrit-Change-Number: 41528
Gerrit-PatchSet: 2
Gerrit-Owner: laforge <laforge(a)osmocom.org>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: dexter <pmaier(a)sysmocom.de>
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>