Commit Graph

20 Commits (8309412f49ee10d35bb46229e640b9c17b164b34)

Author SHA1 Message Date
Rick Carlino 8309412f49 If stale records are found, abort, wait, retry 2020-05-17 14:45:12 -05:00
Rick Carlino 7355fd25fb Fix typo. 2020-05-17 12:41:10 -05:00
Rick Carlino 3b256f14f6 Drilling down deeper into isolating stale data bug 2020-05-17 12:08:37 -05:00
Rick Carlino 5abd596957 Begin debugging DirtyWorker 2020-05-17 11:04:55 -05:00
Rick Carlino 75604c5b34 More debug points 2020-05-17 09:40:48 -05:00
Rick Carlino 004f7bb1d7 TODO: Determine source of stale point data in MARK AS 2020-05-16 17:33:48 -05:00
Rick Carlino 88b440ee59 ✔️ v10.0.0 Ready for final QA 2020-05-15 09:02:58 -05:00
Rick Carlino 6d92a11ebd v10.0.0-rc26 2020-05-14 15:35:37 -05:00
Rick Carlino db1d6cf4f5 v10.0.0-rc25 - More debug points 2020-05-14 14:31:46 -05:00
Connor Rigby 0ba112c9c5 Fix bug causing sync errors in farmware-envs 2019-11-14 10:36:49 -08:00
Connor Rigby ce51edeb99
Revert Alert/Enigma system
* Revert 9cc461b512
* Revert 7309a19fe7
* Revert 7fd82d3a58
* Revert 890ddfbd86
* Revert 839ce3e470
* Revert 68cc8e6471
* Revert 3991a2c516
* Revert db8da31018
2019-09-13 16:03:25 -07:00
Connor Rigby f893611dd0
Consolidate NervesHub logic and implementation 2019-09-13 16:03:20 -07:00
Connor Rigby 199e1edb97
Rename Enigma to Alert 2019-09-13 16:03:19 -07:00
Connor Rigby e80780aeb8
Remove EnigmaWorker in favor of db context hooks
* Add firmware_hardware setter on bot_state
* move firmware side effects to farmbot_core
* move firmware estop timer to farmbot_core
* change enigmas to be soft delete
2019-09-13 16:03:17 -07:00
Connor Rigby b7f4ebba57
Fixes for bootstrapping firmware.
* TTYDetector no longer causes side effects
* add new RPC for `flash_firmware` that takes a `package` arg
2019-09-13 16:03:17 -07:00
Rick Carlino 0b5df60f67
Implement and test Enigmas for firmware_missing
* Test for create_or_update_enigma!() and clear_enigma()
2019-09-13 16:03:17 -07:00
Rick Carlino 17d24bdc0e
Begin impl of firmware flasher RPC, add `clear_enigma` helper 2019-09-13 16:03:16 -07:00
Connor Rigby 981dee6fef
Update enigma schema to match other asset schema
This is because we need to hook the Enigma AssetWorker up to the
existing AssetWorker system. It expects some keys to exist including
`updated_at` and `created_at`
2019-09-13 16:03:16 -07:00
Connor Rigby f1dd9009ea
Rename FarmbotCore Namespace 2019-09-13 16:03:16 -07:00
Connor Rigby 4114e26804
Implement new CeleryScript Runtime environment.
This is obviously a rather large change warranting an essay describing
it.

A Brief overview
Basically the old implementation had quite a few down sides preventing
it from really working as intended, especially with the addition of the
variables feature. Here is the shortlist of things that needed
addressing:

* No scoping between sequences.
What this essentially means is that a sequence that executes another
sequence is unable to add data to the calle. This is important for using
Variables.

* Error recovery
certain nodes have a high likelyhood of failing such as anything that
interfaces the firmware. Much focus was spent ensuring that errors would
be recoverable when desired.

* Complexity of control flow asts versus action asts.
Nodes such as `if` will always work in the same way regardless of the
state of the rest of the system meaning there is no reason for it to
have a special implementation per environment. on the other hand
`move_absolute` is bound to a specific part of the system. Seperating
these concerns allows for better testing of each piece independently.

A More In Depth overview
The core of this change resolves around 1 really big change resulting in
many more small changes. This change is the CeleryScript `compiler`. The
TLDR of this system is that now CeleryScript ASTs are deterministicly
compiled to Elixir's AST and executed. Doing this has some big benifits
as described below.

1) CeleryScript "runtime" environment is now much simpiler in favor of a somewhat
complex "compile time" environment. Basically instead of EVERY single
CeleryScript AST having a custom runtime implementation, only a subset
of ASTs that require external services such as the Firmware, Database,
HTTP, etc require having a runtime implementation. This subset of ASTs
are called `SysCalls`. Also the runtime implementations are compiled to
a single function call that can be implemented instead of needing to
have a contextual environment and making decisions at runtime to
evaluate variables and the like.

2) Static analysis is now possible. This means an incorrectly crafted
sequence can be validated at compile time rather than getting half way
through a sequence before finding the error.

3) Having the "external services" separated leads to better plugability.
There is now a behaviour to be implemented for the subset of syscalls
that are system specific.
2019-09-13 16:03:15 -07:00