Attention is currently required from: laforge.
dexter has posted comments on this change by dexter. ( https://gerrit.osmocom.org/c/pysim/+/38117?usp=email )
Change subject: ts_51_011: replace encoding of EF.MSISDN with construct model
......................................................................
Patch Set 8:
(1 comment)
Patchset:
PS1:
> the mechanism you describe already exists: You keep the he _{en,de}code_record_hex methods, and in t […]
Thanks for the hint. I have done it now slightly different by overloading encode_record_hex. This is probably easier since calling build_construct directly would require access to __get_rec_len() and this is a private method for good reason.
--
To view, visit https://gerrit.osmocom.org/c/pysim/+/38117?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: I647f5c63f7f87902a86c0c5d8e92fdc7f4350a5a
Gerrit-Change-Number: 38117
Gerrit-PatchSet: 8
Gerrit-Owner: dexter <pmaier(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-CC: laforge <laforge(a)osmocom.org>
Gerrit-Attention: laforge <laforge(a)osmocom.org>
Gerrit-Comment-Date: Tue, 24 Sep 2024 13:21:28 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: laforge <laforge(a)osmocom.org>
Comment-In-Reply-To: dexter <pmaier(a)sysmocom.de>
Attention is currently required from: laforge.
Hello Jenkins Builder,
I'd like you to reexamine a change. Please visit
https://gerrit.osmocom.org/c/pysim/+/38117?usp=email
to look at the new patch set (#8).
The following approvals got outdated and were removed:
Verified+1 by Jenkins Builder
Change subject: ts_51_011: replace encoding of EF.MSISDN with construct model
......................................................................
ts_51_011: replace encoding of EF.MSISDN with construct model
The encoding of EF.MSISDN is currently done with enc_msisdn and
dec_msisdn from utils.py. Let's replace this with a construct
based model, similar to the one we already use with EF.ADN
Related: OS#5714
Change-Id: I647f5c63f7f87902a86c0c5d8e92fdc7f4350a5a
---
M pySim/ts_51_011.py
M tests/pySim-trace_test/pySim-trace_test_gsmtap.pcapng.ok
2 files changed, 39 insertions(+), 15 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/pysim refs/changes/17/38117/8
--
To view, visit https://gerrit.osmocom.org/c/pysim/+/38117?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email
Gerrit-MessageType: newpatchset
Gerrit-Project: pysim
Gerrit-Branch: master
Gerrit-Change-Id: I647f5c63f7f87902a86c0c5d8e92fdc7f4350a5a
Gerrit-Change-Number: 38117
Gerrit-PatchSet: 8
Gerrit-Owner: dexter <pmaier(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-CC: laforge <laforge(a)osmocom.org>
Gerrit-Attention: laforge <laforge(a)osmocom.org>
osmith has posted comments on this change by osmith. ( https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/38285?usp=email )
Change subject: testenv: improve --config argument parsing
......................................................................
Set Ready For Review
--
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/38285?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email
Gerrit-MessageType: comment
Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: I66b976b0332be523c084a6b5d38d0f62134b495d
Gerrit-Change-Number: 38285
Gerrit-PatchSet: 4
Gerrit-Owner: osmith <osmith(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Comment-Date: Tue, 24 Sep 2024 12:12:04 +0000
Gerrit-HasComments: No
Gerrit-Has-Labels: No
osmith has posted comments on this change by osmith. ( https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/38285?usp=email )
Change subject: testenv: improve --config argument parsing
......................................................................
Set Ready For Review
--
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/38285?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email
Gerrit-MessageType: comment
Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: I66b976b0332be523c084a6b5d38d0f62134b495d
Gerrit-Change-Number: 38285
Gerrit-PatchSet: 3
Gerrit-Owner: osmith <osmith(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Comment-Date: Tue, 24 Sep 2024 11:52:15 +0000
Gerrit-HasComments: No
Gerrit-Has-Labels: No
Attention is currently required from: laforge.
dexter has posted comments on this change by dexter. ( https://gerrit.osmocom.org/c/pysim/+/38195?usp=email )
Change subject: filesystem: pass total_len to construct of when encoding file contents
......................................................................
Patch Set 5:
(1 comment)
File pySim/filesystem.py:
https://gerrit.osmocom.org/c/pysim/+/38195/comment/85398d26_0eeb58bd?usp=em… :
PS2, Line 1338: def _decode_bin(self, raw_bin_data: bytearray):
: chunks = [raw_bin_data[i:i+self.rec_len]
: for i in range(0, len(raw_bin_data), self.rec_len)]
: return [self.decode_record_bin(x) for x in chunks]
:
: def _encode_bin(self, abstract_data) -> bytes:
: chunks = [self.encode_record_bin(x) for x in abstract_data]
: # FIXME: pad to file size
: return b''.join(chunks)
> Thanks for the explaination, I think I got my head around this now. […]
I am still not sure about the kwargs scheme used with the methods. I wonder if it makes sense to have this. We probably won't add new parameters all too often. Maybe it makes more sense to have explicit keyword parameters instead. Let me know what you think.
--
To view, visit https://gerrit.osmocom.org/c/pysim/+/38195?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: I1b7a51594fbc5d9fe01132c39354a2fa88d53f9b
Gerrit-Change-Number: 38195
Gerrit-PatchSet: 5
Gerrit-Owner: dexter <pmaier(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Attention: laforge <laforge(a)osmocom.org>
Gerrit-Comment-Date: Tue, 24 Sep 2024 10:44:58 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Comment-In-Reply-To: laforge <laforge(a)osmocom.org>
Comment-In-Reply-To: dexter <pmaier(a)sysmocom.de>
Hello Jenkins Builder,
I'd like you to reexamine a change. Please visit
https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/38285?usp=email
to look at the new patch set (#2).
Change subject: testenv: improve --config argument parsing
......................................................................
testenv: improve --config argument parsing
* Fix that it didn't complain about an invalid --config argument, as
long as there was a valid --config argument before it.
* Let raise_error_config_arg only output the invalid --config argument
instead of all of them.
* Complain if "--config all" is used in combination with another
--config argument.
Change-Id: I66b976b0332be523c084a6b5d38d0f62134b495d
---
M _testenv/testenv/testenv_cfg.py
1 file changed, 21 insertions(+), 9 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/osmo-ttcn3-hacks refs/changes/85/38285/2
--
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/38285?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email
Gerrit-MessageType: newpatchset
Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: I66b976b0332be523c084a6b5d38d0f62134b495d
Gerrit-Change-Number: 38285
Gerrit-PatchSet: 2
Gerrit-Owner: osmith <osmith(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Attention is currently required from: dexter, laforge.
Hello Jenkins Builder, laforge,
I'd like you to reexamine a change. Please visit
https://gerrit.osmocom.org/c/pysim/+/38195?usp=email
to look at the new patch set (#5).
The following approvals got outdated and were removed:
Verified-1 by Jenkins Builder
Change subject: filesystem: pass total_len to construct of when encoding file contents
......................................................................
filesystem: pass total_len to construct of when encoding file contents
In our construct models we frequently use a context parameter "total_len",
we also pass this parameter to construct when we decode files, but we
do not pass it when we generate files. This is a problem, because when
total_len is used in the construct model, this parameter must be known
also when decoding the file.
Let's make sure that the total_len is properly determined and and passed
to construct (via pyosmocom)
Related: OS#5714
Change-Id: I1b7a51594fbc5d9fe01132c39354a2fa88d53f9b
---
M pySim/filesystem.py
M pySim/gsm_r.py
M pySim/runtime.py
M pySim/sysmocom_sja2.py
M pySim/ts_31_102.py
M pySim/ts_31_102_telecom.py
M pySim/ts_51_011.py
M tests/pySim-shell_test/file_content/test_record_uicc.ok
8 files changed, 98 insertions(+), 41 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/pysim refs/changes/95/38195/5
--
To view, visit https://gerrit.osmocom.org/c/pysim/+/38195?usp=email
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings?usp=email
Gerrit-MessageType: newpatchset
Gerrit-Project: pysim
Gerrit-Branch: master
Gerrit-Change-Id: I1b7a51594fbc5d9fe01132c39354a2fa88d53f9b
Gerrit-Change-Number: 38195
Gerrit-PatchSet: 5
Gerrit-Owner: dexter <pmaier(a)sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: laforge <laforge(a)osmocom.org>
Gerrit-Attention: laforge <laforge(a)osmocom.org>
Gerrit-Attention: dexter <pmaier(a)sysmocom.de>
osmith has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/38284?usp=email )
Change subject: Cosmetic: testenv: fix line length
......................................................................
Cosmetic: testenv: fix line length
Run "ruff format", so there isn't a diff anymore when running it on
future patches.
Change-Id: I766a07c6d54d0da11ad47acce1fc07b4b3a4801b
---
M _testenv/testenv/podman.py
1 file changed, 1 insertion(+), 2 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/osmo-ttcn3-hacks refs/changes/84/38284/1
diff --git a/_testenv/testenv/podman.py b/_testenv/testenv/podman.py
index 53806a4..0ecf12d 100644
--- a/_testenv/testenv/podman.py
+++ b/_testenv/testenv/podman.py
@@ -132,8 +132,7 @@
def exec_cmd(cmd, podman_opts=[], cwd=None, env={}, *args, **kwargs):
if not container_name:
- raise RuntimeError("Attempting to execute a command in podman, but the"
- f" container isn't running anymore: {cmd}")
+ raise RuntimeError(f"Attempting to execute a command in podman, but the container isn't running anymore: {cmd}")
podman_opts = list(podman_opts)
podman_opts += generate_env_podman(env)
--
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/38284?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: I766a07c6d54d0da11ad47acce1fc07b4b3a4801b
Gerrit-Change-Number: 38284
Gerrit-PatchSet: 1
Gerrit-Owner: osmith <osmith(a)sysmocom.de>
osmith has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/38283?usp=email )
Change subject: ruff.toml: new file
......................................................................
ruff.toml: new file
Add a file in the root dir of the repository to allow running
"ruff format" in order to auto-format the code with expected max line
length, PEP-8, etc.
Replace _testenv/pyproject.toml with .ruff.toml in the root directory of
the repository, so we can exclude "compare-results.py" which doesn't
follow that code style. Otherwise it would get formatted too when
running "ruff format" in the root dir of the repository.
Change-Id: I97ed1ececba85008ca754cf91bf46522e168a894
---
A .ruff.toml
D _testenv/pyproject.toml
2 files changed, 4 insertions(+), 2 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/osmo-ttcn3-hacks refs/changes/83/38283/1
diff --git a/.ruff.toml b/.ruff.toml
new file mode 100644
index 0000000..ad8c0b5
--- /dev/null
+++ b/.ruff.toml
@@ -0,0 +1,4 @@
+line-length = 120
+exclude = [
+ "compare-results.py",
+]
diff --git a/_testenv/pyproject.toml b/_testenv/pyproject.toml
deleted file mode 100644
index 3719b74..0000000
--- a/_testenv/pyproject.toml
+++ /dev/null
@@ -1,2 +0,0 @@
-[tool.ruff]
-line-length=120
--
To view, visit https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/38283?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: I97ed1ececba85008ca754cf91bf46522e168a894
Gerrit-Change-Number: 38283
Gerrit-PatchSet: 1
Gerrit-Owner: osmith <osmith(a)sysmocom.de>