db = DB()
session = db.import_a2l(
a2l_path, in_memory=False, remove_existing=True
)
Whenever I parsed another A2L before, the overlapping characteristics (i.e. same name, but different address) get the address from the first A2L, not the second. Is there some global state in the background? a2l_path is different, I tried in_memory=False and True and remove_existing=False and True.
EDIT: I've debugged the problem and it seems the problem is that CachedBase does not consider the session when handling the cache but only the name of objects. It should be a combination of session and name that defines a unique cache entry. My workaround was to empty the cache each time I'm parsing a new A2L.
When I parse two A2L in separate instances, e.g.
Whenever I parsed another A2L before, the overlapping characteristics (i.e. same name, but different address) get the address from the first A2L, not the second. Is there some global state in the background? a2l_path is different, I tried in_memory=False and True and remove_existing=False and True.
EDIT: I've debugged the problem and it seems the problem is that CachedBase does not consider the session when handling the cache but only the name of objects. It should be a combination of session and name that defines a unique cache entry. My workaround was to empty the cache each time I'm parsing a new A2L.
Thanks, Philipp