Administrator
|
Hi,
Closing the database and reloading it is probably the safest solution.
Otherwise, depending on what you modified in the database, you can clear the cached value manually:
* if you added / removed relation (on individuals), you can simply delete the individual's attributes (e.g. del my_individual.my_prop). Owlready will reload the values from the database automatically.
* if you added / removed is-a relation on classes, you need to manually update the list of parent classes (.is_a), or to discard the cached Python object copy (which is in the dict default_world._entities, mapping storid to cached entities).
Jiba
|