You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When a pipeline is run, a shallow_copy of a catalog is made with the extra_dataset_pattern of the runner, and the original object is mutated. It adds an extra_dataset_patterns that is a "catch all". This prevents for example running a pipeline twice with the same catalog, as the second one will not have any free outputs.
Context
I have a pipeline that exists with 2 namespaces. I wanted to test it for both, and I parametrized the tests. The tests used the same catalog as a fixture. This fixture had the module scope so as not to re create it every time. When updating to kedro 0.19, the test fails for the second parameter, when my test pipeline does not have any free output. After investigating, I found that the pipeline does not have any free output because the second time the catalog has catalog._extra_dataset_patterns={'{default}': {'type': 'MemoryDataset'}} which matches all the datasets.
Steps to Reproduce
To reproduce the symptoms (running the pipeline twice does not have any free output the second time):
@ElenaKhaustova would this still be the case in the new KedroDataCatalog object?
Yes, this will be the case for the new catalog as well. shallow_copy will be removed as now we have a dedicated method to add_runtime_patterns via CatalogConfigResolver but since we do not remove patterns added at the runtime now.
Description
When a pipeline is run, a
shallow_copy
of a catalog is made with theextra_dataset_pattern
of the runner, and the original object is mutated. It adds anextra_dataset_patterns
that is a "catch all". This prevents for example running a pipeline twice with the same catalog, as the second one will not have any free outputs.Context
I have a pipeline that exists with 2 namespaces. I wanted to test it for both, and I parametrized the tests. The tests used the same catalog as a fixture. This fixture had the
module
scope so as not to re create it every time. When updating to kedro 0.19, the test fails for the second parameter, when my test pipeline does not have any free output. After investigating, I found that the pipeline does not have any free output because the second time the catalog hascatalog._extra_dataset_patterns={'{default}': {'type': 'MemoryDataset'}}
which matches all the datasets.Steps to Reproduce
To reproduce the symptoms (running the pipeline twice does not have any free output the second time):
I think the problem comes from this behavior:
Expected Result
I want that
bar
was kept as a free output when running the pipeline the second timeActual Result
The second time the pipeline runs, the output is an empty dictionary.
Your Environment
pip show kedro
orkedro -V
): v0.19.9python -V
): Python 3.11.8The text was updated successfully, but these errors were encountered: