chore: release 1.0.0
Bump version to 1.0.0 and pin the donglora dep to >=1.0.0,<2.0.0 (PyPI), matching the freshly-published donglora 1.0.0 client. Also knock out two preexisting lint failures surfaced by the release-time `just check` gauntlet: * orac/crypto.py: drop the redundant int() wrap around round() (RUF046). * orac/state.py: widen _state value type to include list[list[float]] so heard_positions type-checks under pyright.
This commit is contained in:
5 files changed
+35
-7
No files matched your search
+2
-2
@@ -310,8 +310,8 @@ def build_advert_payload() -> bytes:
|
||||
timestamp = struct.pack("<I", int(time.time()))
|
||||
name_bytes = BOT_NAME.encode("utf-8")
|
||||
if heard_position_count() >= 5 and (avg := average_heard_position()) is not None:
|
||||
lat_i = int(round(avg[0] * 1_000_000))
|
||||
lon_i = int(round(avg[1] * 1_000_000))
|
||||
lat_i = round(avg[0] * 1_000_000)
|
||||
lon_i = round(avg[1] * 1_000_000)
|
||||
# flags: has_name (0x80) | has_location (0x10) | chat node (0x01)
|
||||
app_data = bytes([0x91]) + struct.pack("<ii", lat_i, lon_i) + name_bytes
|
||||
else:
|
||||
|
||||
+1
-1
@@ -17,7 +17,7 @@ log = logging.getLogger("orac")
|
||||
|
||||
# ── Persistent state ─────────────────────────────────────────────
|
||||
|
||||
_state: dict[str, dict[str, object]] = {
|
||||
_state: dict[str, dict[str, object] | list[list[float]]] = {
|
||||
"channel_history": {}, # channel_name -> list of messages
|
||||
"dm_history": {}, # peer_pubkey_hex -> list of messages
|
||||
"known_nodes": {}, # pubkey_hex -> {"name": str, "seen": float}
|
||||
|
||||
Reference in new issue
Block a user