Fixed #72 : Exception when get_results(id=10)

Fixed #74 : Keyword parameters are no longer recognized when a concept that redefines equality is created
Fixed #118 : RecursionError: maximum recursion depth exceeded
Fixed #119 : PreventCircularReferenceEvaluator
Fixed #121 : Plural are not updated when new elements are added
Fixed #123 : BaseCache : Values in cache can be evicted before being committed
Fixed #105 : TOO_MANY_ERROR is not the relevant error when results are filtered
This commit is contained in:
2021-09-09 10:57:01 +02:00
parent 54e5681c5a
commit 945807b375
36 changed files with 503 additions and 98 deletions
+5 -1
View File
@@ -614,7 +614,7 @@ class Sheerka(Concept):
concept.get_hints().is_evaluated = True # because we have manually set the variables
return concept
def new_dynamic(self, concept_or_key, id_suffix, name=None, props=None, attrs=None):
def new_dynamic(self, concept_or_key, id_suffix, name=None, props=None, attrs=None, body=None):
"""
Create a dynamic concept with the given props and attrs
A dynamic concept is a concept that is not declared by 'def concept' but can be deduced from another one
@@ -625,6 +625,7 @@ class Sheerka(Concept):
:param name: new name and key for the concept
:param props:
:param attrs:
:param body:
:return:
"""
if not isinstance(concept_or_key, Concept):
@@ -649,6 +650,9 @@ class Sheerka(Concept):
for k, v in attrs.items():
concept.set_value(k, v)
if body:
concept.get_metadata().body = body
return concept
def push_ontology(self, context, name, cache_only=False):