Mike Auty
4b6b68cf2c
Fix up a typo that accidentally got introduced.
2018-04-02 02:20:16 +01:00
Mike Auty
e1fed0af20
Rejig configuration deleting again
...
Had second thoughts and deletion should only remove data, not sub
hierarchies. If the entire hierarchy needs clearing out, it'll need to
be done manually, or by splicing in an empty HierarchicalDict.
2018-04-02 02:18:20 +01:00
Mike Auty
a815e39a0c
Fix up the configuration deletion logic.
2018-04-02 02:13:39 +01:00
Mike Auty
0d075e6ee3
Fix major (but easily missable) bug in the configuration system.
2018-04-01 22:54:28 +01:00
Mike Auty
eaadd53951
Allow the optional setting of requirements to be changed (for sub-plugins).
2018-03-25 18:16:34 +01:00
Mike Auty
10f65a67c8
Ensure the config/branch methods always return.
2018-03-25 18:13:41 +01:00
Mike Auty
2522d588ea
Pylinting and typing fix.
2018-03-21 17:04:10 +00:00
Mike Auty
6766498e4a
Fix up saving symbol_space contruction options.
2018-03-11 20:59:47 +00:00
Mike Auty
8b29b1f668
Rework the import ordering for requirements/configurations.
2018-02-12 00:51:05 +00:00
Mike Auty
994bd7c394
Fix up the finding of swap layers so swap actually works.
2018-02-11 21:41:39 +00:00
Mike Auty
b7c68f4e98
Rework LayerListRequirement from a ListRequirement to a MultiRequirement.
2018-02-11 18:35:18 +00:00
Mike Auty
7cb0330d04
Fix and correctly type ListRequirements.
2018-02-10 22:41:39 +00:00
Mike Auty
c203663f0b
Refactor requirements to support a list of swap layers.
2018-01-28 14:48:50 +00:00
Mike Auty
f40fae197d
Convert to python3.5 syntax (no local type-annotations).
2017-12-13 20:48:52 +00:00
Mike Auty
50b60c0df6
Add in more interfaces (and fix additional errors now that type information is available).
2017-12-13 20:48:52 +00:00
Mike Auty
5536412a5e
Add in initial work at interface type-annotations.
2017-12-13 20:48:52 +00:00
Mike Auty
d7d13eb19c
Add type annotations to most of the automagic files.
2017-12-13 20:48:52 +00:00
Mike Auty
769e1226c4
Make creating subconfigs simpler from configurables.
2017-11-13 00:59:01 +00:00
Mike Auty
e90b4e2d02
Add and make use of free_table_name for symbol_spaces.
2017-09-03 22:54:42 +01:00
Mike Auty
ab5f4fa3ab
Refactor the List and Choice Requirements
...
These are required by the Automagic interface, and so to prevent
importing from outside the interfaces namespace, these two classes
were moved into interfaces.
2017-08-09 22:44:06 +01:00
Mike Auty
5e9b2306d4
Ensure symbol tables are created with unique names.
2017-07-31 16:34:02 +01:00
Mike Auty
03cdd91fbf
Add in the capability to merge two config dicts (so that manually set settings aren't overwritten).
2017-07-20 00:49:36 +01:00
Mike Auty
5e15d522bd
Remove automatic IDE-inserted attributions.
...
They weren't consistent and they show just remind me how slowly
I've been getting vol 3 written! 5:S
There's git commits to track all of that stuff if we need it.
2017-05-14 11:40:49 +01:00
Mike Auty
d6728fc2b4
Add in attributes and appropriate validation of TranslationLayers based on those attributes.
2017-02-10 13:57:44 +00:00
Mike Auty
3a648d75b0
Don't double wrap unsatisifed requirements, each should return its full config path of the requirement checked.
2017-01-08 17:59:04 +00:00
Mike Auty
149e57afee
Change the requirement validation system to return all unsatisfied requirements, to provide more feedback.
2017-01-08 17:26:09 +00:00
Mike Auty
7b252d8b73
Refactor InstanceRequriement into the interfaces file.
...
This also fixes a minor bug where a property was used in the
initializer, which can't be read before initialization.
2017-01-08 02:04:55 +00:00
Mike Auty
0f811fbe34
Refactor the code to make it easier to find classes, and update documentation.
2016-12-30 02:13:23 +00:00
Mike Auty
de9034f378
Ensure that configuration.branch allows for the return of an empty dict.
2016-12-29 15:06:28 +00:00
Mike Auty
1abebe67db
Further documentation improvements.
2016-12-29 03:14:40 +00:00
Mike Auty
88e9786967
Improve the requirements documentation.
2016-12-28 22:33:17 +00:00
Mike Auty
698d1c2b4a
Improve the granularity of logging.
2016-12-15 01:38:24 +00:00
Mike Auty
d43b294f36
Ensure we store all relevant config values rather than just those stores as variables.
2016-12-12 02:07:48 +00:00
Mike Auty
88f1166c6d
Add in a helper function that will likely be useful in the future.
2016-12-04 01:01:13 +00:00
Mike Auty
667014a1fd
Attempt to standardize error message display.
2016-10-30 17:51:45 +00:00
Mike Auty
f771de3703
Tidy up error messages.
2016-10-30 17:07:48 +00:00
Mike Auty
9959697ba5
Move where the rescursion into TranslationLayers happens.
2016-08-24 01:29:11 +01:00
Mike Auty
4d7701be66
Fix the config printer to sort the values.
2016-08-24 01:13:38 +01:00
Mike Auty
6b47b992a7
Ensure splice requirement perpetuates down the HierarchicalDict.
2016-08-24 01:13:20 +01:00
Mike Auty
341ae950b8
Ensure configurations do not include any generated values (ie TranslationLayer/SymbolLayer names)
2016-08-24 01:12:43 +01:00
Mike Auty
3a07d6810b
Add in a reminder for additional work required.
2016-08-22 02:27:13 +01:00
Mike Auty
3dc161f9b4
Rework Translation Layers to tie more closely to configurations
...
This change is quite signficant, and requires that TranslationLayers
get all additional parameters that they need through their requirements.
These are now automatically enumerated and populated on object
construction based on the requirements, so should not require lots of
repetitive filling out of fields.
It does come with the downside that TranslationLayers can only be
contructed with a context (and appropiate config), but TLs in particular
always require a context (to contain the base layer) and blank configs
can be constructed relatively easily (convenience functions can be added
if necessary).
This allows configuration trees to be built up, and their configs
spliced into an existing config (as if it were being loaded from a
file).
Not all ConstructableRequirements use this method, since SymbolTables
(for example) do not have access to the context or config_path in order
to get to any parameters stored in the context's config. They therefore
are still passed their requirement values as __init__ parameters
instead.
2016-08-22 02:20:10 +01:00
Mike Auty
d3e63fbc1a
Rename update_configuration to build_configuration and return a standalone config.
2016-08-22 02:18:23 +01:00
Mike Auty
a1b9be74c7
Refactor several configuration/requirement structures to avoid import loops.
2016-08-22 02:15:54 +01:00
Mike Auty
c5139ba568
Stop exposing the config_path for now, and fix the version that's passed in the construction phase.
2016-08-22 00:36:58 +01:00
Mike Auty
dc16d93b77
Alter the config.path_join function to remove empty sections.
2016-08-21 21:47:45 +01:00
Mike Auty
ca61cf10b9
Refactor the context back into the ConfigurableInterface.
...
This also adds support for manually constructed configurables to
populate the config tree in the current context.
I'm still toying around with this though, I need to figure out
what to do with optional values and think the whole thing through
to make sure it's worthwhile.
2016-08-14 21:28:43 +01:00
Mike Auty
e02feed16e
Python 3 has a sane super() implementation (no arguments), so convert to using that.
2016-08-14 00:55:02 +01:00
Mike Auty
43aba96e3f
Minor pylint (alphabetical imports) and refactoring the construct class to work for symbols.
2016-07-30 01:58:29 +01:00
Mike Auty
d3a226d7a8
Remove constraints as a thing, they'll need to come back, but in a different form.
2016-07-30 01:52:44 +01:00