summaryrefslogtreecommitdiff
path: root/taskflow/engines/action_engine/scopes.py
Commit message (Collapse)AuthorAgeFilesLines
* Update TaskFlow for networkx 2.xMichael Johnson2019-10-181-1/+1
| | | | | | | | | | | The networkx 2.x series has been out for two years now and supports python 3.6 and greater[1]. This patch updates TaskFlow to require a minimum of networkx 2.1. It also updates the code to support recent deprecation expiration introduced in the 2.4 release. [1] https://networkx.github.io/documentation/stable/news.html Change-Id: Ife31d353ba80824ebc63c8b21ee90943badc8da3
* Allow for alterations in decider 'area of influence'Joshua Harlow2016-01-091-23/+4
| | | | | | | | Christmas came early. Closes-Bug: #1479466 Change-Id: I931d826690c925f022dbfffe9afb7bf41345b1d0
* Move all internal blather usage/calls to trace usage/callsJoshua Harlow2015-12-171-4/+4
| | | | Change-Id: I415a81d3b6b15b17a9a91cc2a0681c159172a4e1
* Use the node built-in 'dfs_iter' instead of recursionJoshua Harlow2015-10-021-9/+9
| | | | | | | | | | | | We can just use the non-recursive depth first iteration of nodes when scanning for atoms to select for a given scope level instead of using recursive calls to achieve the same effect. This makes it possible to have large and heavily nested flows that are not restricted by the python stack limit. Change-Id: I0d18565680f777adbdfca9d4983636c6b3e848da
* Simplify flow action engine compilation1.22.0Joshua Harlow2015-10-011-18/+21
| | | | | | | | | | | | | | Instead of the added complexity of discarding flow nodes we can simplify the compilation process by just retaining them and jumping over them in further iteration and graph and tree runtime usage. This change moves toward a model that does just this, which makes it also easier to in the future use the newly added flow graph nodes to do meaningful things (like use them as a point to change which flow_detail is used). Change-Id: Icb1695f4b995a0392f940837514774768f222db4
* Use iteration instead of list(s) when extracting scopesJoshua Harlow2015-03-191-11/+12
| | | | | | | | Instead of creating a temporary list(s) during scope extraction just use a generator/iterator instead to avoid the need to create temporary and wasteful list(s) that are not really needed. Change-Id: Ia7f2c36c2cbd6602b90bd32911fc1ff5bcbb1611
* Always return scope walker instances from `fetch_scopes_for`Joshua Harlow2015-03-181-17/+29
| | | | | | | | | | | | | | | | | Instead of returning tuples with fully expanded scopes return walker instances that internally know how to avoid recomputing the visible scopes (they do this by caching each visibility level and looking in the local cache before computing the scope and storing it in the cache). This makes the usage more uniform and avoids returning different items depending on what is found; making the code easier to follow and understand. Also makes the scope walker call to '_extract_atoms' to go via a static method so that if it is ever desired to alter what '_extract_atoms' does it can be more easily done (using standard inheritance). Change-Id: I5916838163e6be843429fe7b89a0b5622e9c2f36
* Add specific scoping documentationJoshua Harlow2015-03-021-15/+23
| | | | | | | | Adds information into the arguments and result docs about how scoping lookup works and what it implies. Change-Id: I810874dce042ec43fe9e704d6689215e19d67c9c
* Add and use a new simple helper logging moduleJoshua Harlow2014-12-081-11/+5
| | | | | | | | | Add a new logging BLATHER level to easily allow its usage for messages that are below the normal DEBUG level such as compilation information and scope lookup info which can be very verbose in logs if always enabled. Change-Id: I828211403bd02bfd6777b10cdcfe58fb0637a52c
* Revamp the symbol lookup mechanismJoshua Harlow2014-09-081-0/+119
To complement the future changes in patterns we also want to allow the execution of patterns to be affected in a similar manner so that symbol lookup is no longer as confined as it was. This change adds in the following: - Symbol lookup by walking through an atoms contained scope/s. - Better error messaging when symbols are not found. - Adjusted & new tests (existing ones work). - Better logging of the symbol lookup mechanism (helpful during debugging, although it is very verbose...) Part of blueprint taskflow-improved-scoping Change-Id: Id921a4abd9bf2b7b5c5a762337f8e90e8f1fe194