Skip to content

Commit

Permalink
Make formatting of enums in py3.11 consistent with earlier Python ver…
Browse files Browse the repository at this point in the history
…sions (#550)

Python 3.11 changes the behavior of  `enum.Enum.__format__()` slightly. f-strings (and a few other string formatting methods) rely on dunder method `__format___()`. This change makes the formatting of enums as strings consistent
among all supported Python versions.

Fixes #447
  • Loading branch information
Jared-Newell-Mobility authored Jan 15, 2024
1 parent 7d50b6c commit fab6536
Show file tree
Hide file tree
Showing 3 changed files with 242 additions and 226 deletions.
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
# Change log

- [#447](https://github.com/mobilityhouse/ocpp/issues/447) Make formatting of enums in py3.11 consistent with earlier Python versions
- [#421](https://github.com/mobilityhouse/ocpp/issues/421) Type of v16.datatypes.SampledValue.context is incorrect

## 0.25.0 (2024-01-08)
Expand All @@ -13,6 +14,7 @@

## 0.24.0 (2023-12-07)


- [#539](https://github.com/mobilityhouse/ocpp/issues/539) feat: Add ChargePoint._handle_call return value. Thanks [@wafa-yah](https://github.com/wafa-yah)
- [#266](https://github.com/mobilityhouse/ocpp/issues/266) fix: Central System documentation link.
- [#516](https://github.com/mobilityhouse/ocpp/issues/516) OCPP 2.0.1 add additional security events from v1.3.
Expand Down
Loading

0 comments on commit fab6536

Please sign in to comment.