Python Script(Lab): Error 'Unsupported type' - but working with 'old' node

Using a Python snippet to access feast (feature store) on Postgres using the new ‘Python Script(Lab)’ node I encountered an error ‘ValueError: Unsupported type: extension<knime.logical_type>’. Running the same script in the ‘old’ node works without any problems. I’m working with KNIME 4.5.2 on WIN.

The task of the script below is to pass an input table, consisting of an INT (as the ID) and an ‘Local Date Time’ (ts) column, to the feast feature store for fetching the matching (via ID) records from the DB (Postgres). The error happens in the call ‘get_historical_features’.
Using the same script (adapted reg. IN/OUT) in the old Python Script node works fine!

Here my script - the Log of the Python node please find attached.

import knime_io as knio

# This example script creates an output table containing randomly drawn integers using numpy and pandas.

import numpy as np
import pandas as pd
from datetime import datetime, timedelta
from feast import FeatureStore

# The entity dataframe is the dataframe we want to enrich with feature values

entity_def = knio.input_tables[0].to_pandas()

store = FeatureStore(repo_path="C:/Data/feast_projects/feature_repo_pgsql")

training_df = store.get_historical_features(
knio.output_tables[0] = knio.write_table(training_df)

PyError.txt (4.6 KB)

Hi Erich,

I’m afraid this error is expected.

The new Python Script (Labs) node does not yet support all data types, e.g. images from KNIME Image Processing or molecules from RDKit Nodes for KNIME.

We are working on supporting them, but for now the only option is to use the old Python nodes.

Kind regards

1 Like

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.