Skip to content

omamobile-modem-sit: fail the status probe on incomplete replies - #569

Merged
derekross merged 1 commit into
derekross:mainfrom
marselnenaj:codex/sit-probe-error-status
Nov 9, 2026
Merged

derekross merged 1 commit into
derekross:mainfrom
marselnenaj:codex/sit-probe-error-status

Conversation

@marselnenaj

@marselnenaj marselnenaj commented Nov 9, 2026 •

Copy link
Copy Markdown
Contributor

Make the read-only SIT status probe return failure when replies are incomplete. Previously, malformed SIM status or unavailable status requests could still produce exit status 0. Malformed mandatory states, empty replies and request errors now fail, with the client closed in every path. A missing SIM's legitimate SMSC error 11 remains accepted, and the existing 20-second initial USIM timeout is preserved.

The package advances from 0.3.32 to 0.3.33. Eight tests call the real service.probe with inert replies, covering the six GETs, malformed and empty data, unavailable states, client closure and the no-SIM SMSC exception. The eight direct probe tests pass. An independent complete package-suite run also passes with the public base’s SIT simulator explicitly enabled (140.50 seconds), including staged installation, configuration and unit checks. The existing reference check against the sibling Cheetah package is skipped in this isolated package copy; simulator checks are enabled. This is offline validation, not a phone or 5G result. tools/pr-check passes against main 09b7eb222f9e208a394cbe03fddffb78de448023.

This extends the existing MIT-licensed SIT service and preserves its original attribution. It adds no request types or modem configuration writes and does not duplicate the merged telephony integration from #371.

Upstream CI passes the policy gate, tests/all and tests/packages.

The read-only probe previously exited successfully after missing status
replies. Return failure for malformed SIM status, malformed mandatory
states, empty replies and request errors while always closing the client.
Keep the legitimate no-SIM SMSC error 11 exception and the existing first
USIM timeout.

Add eight tests against the real service.probe with inert replies and
advance the package version.

Co-Authored-By: OpenAI Codex <noreply@openai.com>
@derekross

Copy link
Copy Markdown
Owner

Thank you, this is a tidy change and the tests call the real probe(). I ran test_probe.py against your head (8 ok) and against main's service.py (6 fail), so they catch the old behaviour. CI's simulator run covers the read-only probe end to end.

I also checked the Pixel 7 Pro's own probe logs from the modem bring-up: with no SIM they show card state 0 and "SMSC unavailable: error 11", which your exception keeps as a pass. The only callers of --probe are the plan runbooks and the simulator test, so the new exit code doesn't feed any unit.

I'm merging it now, as omamobile-modem-sit 0.3.33: it's the first of the open modem PRs to land, so the other PRs that claim 0.3.33 will take later numbers. One small follow-up whenever it suits you: a line in the docstring saying why a present SIM with no SMSC counts as a failure.

@derekross
derekross merged commit 472f368 into derekross:main Nov 9, 2026
2 checks passed
@marselnenaj

Copy link
Copy Markdown
Contributor Author

Thank you for checking the old behavior and the no-SIM logs on the Pixel 7 Pro. I added the requested docstring rationale in #583: a failed or empty SMSC reply with a present SIM leaves SMS configuration unverified, while error 11 without a SIM remains expected. That follow-up changes documentation only; the probe behavior and package version are unchanged.

derekross pushed a commit that referenced this pull request Nov 10, 2026
Document why a failed or empty SMSC reply is incomplete with a present SIM,
while the no-SIM error remains an expected result. Follow up on the review
of #569 without changing probe behavior or its package version.

Co-authored-by: OpenAI Codex <noreply@openai.com>
W4HO-ham added a commit to W4HO-ham/omarchy-mobile that referenced this pull request Nov 10, 2026
Main took 0.1.17 (derekross#568) and 0.3.33 (derekross#569) for other changes and
omamobile-device-tegu 0.2.11 (derekross#591), so this branch's packages move to
the next numbers and the README names the modem package version the
stop command comes with.
robertzas pushed a commit to robertzas/omarchy-mobile that referenced this pull request Nov 14, 2026
…es (derekross#569)

The read-only probe previously exited successfully after missing status
replies. Return failure for malformed SIM status, malformed mandatory
states, empty replies and request errors while always closing the client.
Keep the legitimate no-SIM SMSC error 11 exception and the existing first
USIM timeout.

Add eight tests against the real service.probe with inert replies and
advance the package version.

Co-authored-by: OpenAI Codex <noreply@openai.com>
robertzas pushed a commit to robertzas/omarchy-mobile that referenced this pull request Nov 14, 2026
…#583)

Document why a failed or empty SMSC reply is incomplete with a present SIM,
while the no-SIM error remains an expected result. Follow up on the review
of derekross#569 without changing probe behavior or its package version.

Co-authored-by: OpenAI Codex <noreply@openai.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants