Skip to content

Pass the count of re.sub by keyword - #298

Merged
adrpo merged 1 commit into
OpenModelica:masterfrom
adrpo:fix-re-sub-count-deprecation
Aug 11, 2026
Merged

Pass the count of re.sub by keyword#298
adrpo merged 1 commit into
OpenModelica:masterfrom
adrpo:fix-re-sub-count-deprecation

Conversation

@adrpo

@adrpo adrpo commented Aug 11, 2026

Copy link
Copy Markdown
Member

Python 3.13 deprecates giving re.sub its count positionally, so every library test run printed

test.py:1046: DeprecationWarning: 'count' is passed as positional argument
return (re.sub( ".model name.:", "", line,1)).strip()

once per job while reading the processor name out of /proc/cpuinfo. The substitution is unchanged; only how the argument is spelled.

A run of configs/sanityCheck.json now goes through without a single DeprecationWarning.


Generated by Claude Code.

Python 3.13 deprecates giving re.sub its count positionally, so every library
test run printed

  test.py:1046: DeprecationWarning: 'count' is passed as positional argument
    return (re.sub( ".*model name.*:", "", line,1)).strip()

once per job while reading the processor name out of /proc/cpuinfo. The
substitution is unchanged; only how the argument is spelled.

A run of configs/sanityCheck.json now goes through without a single
DeprecationWarning.

---
Generated by Claude Code.
@adrpo
adrpo enabled auto-merge (squash) August 11, 2026 17:13
@adrpo
adrpo merged commit dd76013 into OpenModelica:master Aug 11, 2026
10 of 11 checks passed
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.

1 participant