mirror of
https://github.com/pybricks/pybricks-code.git
synced 2026-09-12 01:23:52 +00:00
b9dbaaa5cbc5f698747f193cc00d45e6ffe5ccfa
This breaks down reading and writing into low-level and high level sagas. Opening now takes a lock on the file so that it can only have one writer or have multiple readers. The low-level read and write sagas use the file descriptor to determine if the file is still open before actually performing the action. Since we are using the web locks api, these locks should work across browser tabs/windows. The high-level read/write sagas perform the low-level open, read/write, close operations in a single call. The high-level delete and rename sagas are also updated to take locks on the files while performing the respective operations and will fail if the file is already being used somewhere else.
pybricks-code
A Web App for programming LEGO® Powered Up smart hubs using Pybricks MicroPython.
Try it at https://code.pybricks.com or the latest updates https://beta.pybricks.com.
Contributing
If you'd like to contribute, please fork the repository and use a feature branch. Pull requests are warmly welcome.
For more details, see the file CONTRIBUTING.md.
LEGO® is a trademark of the LEGO Group of companies which does not sponsor, authorize or endorse this project.
Languages
TypeScript
90%
JavaScript
7.6%
SCSS
2.1%
HTML
0.2%
Python
0.1%
