Releases: BrianPugh/belay
Releases · BrianPugh/belay
v0.9.1 - Reduce dependencies
Changes
- Remove
lox
from dependency list.
v0.9.0 - New commands; better and faster sync.
Features
- New command
belay run
to run a file on-device. - New command
belay exec
to execute a python string on-device. sync
improvements:- New argument
dst
; folder to sync file into. Defaults to"/"
; - New argument
ignore
; uses gitignore pattern matching to ignore files during sync. Defaults to common undesired files. - New argument
mpy_cross_binary
; if provided, will compile .py files into .mpy prior to syncing. - Can now sync a single file. Other files will not be deleted when syncing a single file.
- Can now keeps all untouched files if
keep=True
. - Changed file hashing function from FNV-1a-64bit to FNV-1a-32bit for speed. Optimized implementation with
native
andviper
decorators for a large speed boost - Parallelized pre-processing operations for faster syncs.
- Misc bug fixes; a lot more unit testing.
- New argument
v0.8.0 "identify" command.
Features
- Added the
identify
command to the cli. This executesinfo
, but also blinks an LED (or neopixel) on the board. Works with both circuitpython and micropython. This is useful for identifying which board is which when using multiple devices.
v0.7.0 Automatic Device Reconnect
Features
- Added support to automatically reconnect to a device upon a temporary disconnect. To activate, provide a non-zero value to the
attempts
keyword argument when creating thebelay.Device
. See docs for details and limitations. - Added
sys.platform
information to theImplementation
data structure. - Add
info
cli command to see deviceImplementation
information. Useful for quickly checking what firmware is running on-device.
v0.6.0 CircuitPython Support
Features
- CircuitPython is now supported.
- Since CircuitPython doesn't guarentee
hashlib
to be builtin, the file hashing function for syncing operations has been changed from sha256 to 64-bit FNV-1a. FNV-1a was selected for its incredibly terse implementation, and reasonable performance for simply detecting if a file has changed.
- Since CircuitPython doesn't guarentee
- New attribute
device.implementation
contains the name (micropython
orcircuitpython
) and version of firmware running on-device.
Bug Fixes
- Fixed an off-by-one error for the final line reported in a stacktrace when an exception is raised on-device. This only occurred when the
task
orthread
decorators were used.
v0.5.0 Generators, Printing, and a CLI
Features
- Added a new command line program,
belay
. Runbelay --help
for more information.- Currently only one supported action,
sync
, to sync a folder to the device's root.
- Currently only one supported action,
- Added the public method
Device.close()
to gracefully close device connection (Partially addresses #14). - Support decorating generator functions with the
task
decorator (Addresses #15). print
calls from device are now forwarded to host'sstdout
. User print statements must not begin with_BELAY
, as these are reserved for internal use.
v0.4.1
v0.4.0
Features
- Initial WebREPL support. See documentation and
examples/09_webrepl
. Performance is a bit lackluster, but should be acceptable for projects that don't need rapid response. - Optimized some command/responses for less communication round-trips (slightly improves WebREPL performance).
- Allow
main.py
andboot.py
in the sync folder. They don't actually impact Belay's ability to operate. RemovedSpecialFilenameError
that would have been previously raised if either of these were present. - Added optional keyword argument
keep
to specify files on-device that should not be deleted if a corresponding file doesn't exist in the sync folder. Defaults to["boot.py", "webrepl_cfg.py"]
, since these files may contain device-specific information.
Bug Fixes
- Fix sync hash-checking logic. Previously all files were always synced.
- Fix and improved erroneous message in
ValueError
raised byDevice.sync
Internal
- Moved on-device code snippets into their own folder for easier maintenance.
v0.3.0
v0.2.0
Features
- Support for multiple device
task
andthread
decorators. - Allow access of decorated functions from
task
andthread
.
Misc Changes and Improvements
- Improve decorator stripping logic.
- Change belay prefix from
__belay_
to_belay_
. - Change
json_decorator
to__belay_json
to reduce chance of name collision. - Reduce whitespace in returned json data.
- Rename
hash_remote_file
to__belay_hash_file
to reduce chance of name collision. Don't invoke viatask
to circumvent double prefix.