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
The dataset isn't validated (in my case its the output dataset). Removing factory specification fixes the problem
Investigation / workaround
Looking into the source code the line dataset = catalog._datasets.get(name) returns None for a factory dataset, which makes metadata become None too. That stops the validation.
Description
A factory dataset with schema defined isn't validated by kedro-pandera
Context
Unable to validate datasets defined as a factory
Steps to Reproduce
For this catalog entry:
Expected Result
The factory dataset is validated
Actual Result
The dataset isn't validated (in my case its the
output
dataset). Removing factory specification fixes the problemInvestigation / workaround
Looking into the source code the line dataset = catalog._datasets.get(name) returns
None
for a factory dataset, which makesmetadata
becomeNone
too. That stops the validation.It is a bigger issue with the catalog and dataset factories.
I managed to fix the issue by wrapping the code inside the for loop:
That makes the dataset pop up in
catalog._datasets
and it's getting validated properlyAnother workaround that I can think of is move from
before/after_node_run
hook tobefore/after_dataset_loaded
, but not 100% sure that it will workYour Environment
Does the bug also happen with the last version on main?
Yes
The text was updated successfully, but these errors were encountered: