FarmBot / FarmBot/Farmbot-Web-App

Device log throttling issues and improvements

Open
#1,559 1 comment 0 reactions 0 assignees View on GitHub
bug enhancement Logs
Dominant language
TypeScript
Stars
973
Forks
356
Avg merge
1h 6m
Merged PRs (30d)
3

Description

- [ ] Frontend should receive `throttled_at` and `throttled_until` changes without a refresh. This is related to `deviceIsThrottled` and `BatchQueue`, which may not be working correctly.
- [ ] It should be possible to initiate throttling from any log type. Currently it takes a log type other than `fun` or `debug` to initiate the cooldown period when the rate limit has already been reached by those log types.
- [ ] Throttling should end when the cooldown period ends rather than after a log of a type other than `fun` or `debug` has been sent.
- [ ] Users should be notified upon termination of throttling (cooldown period) rather than after a new log message has been sent.
- [ ] Logs that would not display on any filter setting should be removed from frontend resources after the maximum log count has been reached.

# To reproduce
1. Enable firmware response logs (`firmware_input_log`) with a device connected.
2. Wait a couple minutes. (Observe no throttling.)
3. Perform an action that creates a normal log near the end of a clock minute. (Observe "throttle begin" notice while logs continue to appear in frontend.)
4. Perform an action that creates a normal log near the beginning of the next clock minute. (Observe "throttle end" notice.)
5. Repeat, this time refreshing after step 3. (Observe logs no longer appear in frontend.)

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.