You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[Bug] Factory reset commands fail with protobuf 7.x: Expected an int, got a boolean #919
Running meshtastic --factory-reset or meshtastic --factory-reset-device from the command line fails immediately with an error and does not reset the device. The commands appear to connect successfully but abort before sending anything to the radio.
The Problem
In node.py, the two fields are assigned Python boolean values:
File:meshtastic/node.py
# Line 731p.factory_reset_device=True# Line 734p.factory_reset_config=True
In Python, True and 1 are nearly equivalent True == 1 evaluates to True, and in most contexts they are interchangeable. This worked fine with protobuf versions prior to 7.x because the library was permissive about type coercion.
protobuf 7.x introduced strict type enforcement. It now validates that the value assigned to a field matches the field's declared type exactly. Since factory_reset_device and factory_reset_config are declared as integers in the .proto schema, protobuf 7.x rejects a Python bool and raises a TypeError, which the CLI catches and surfaces as the "Aborting due to" message.
Activity
ianmcorvidae commentedon Jun 1, 2026
This should be fixed by #917 which will go out in the next release of the CLI.