time subtraction in python node not working
Is the python plugin very rudimentary in Knime?
I am trying a simple timestamp subtraction but I am getting the following error;
ERROR Python Script 0:15 Execute failed: No serializer extension having the id or processing python type “pandas._libs.tslibs.timedeltas.Timedelta” could be found. Unsupported column type in column: “stoptimetillnow”, column type: “”.
I have two columns: A timestamp column from a table, and a current time column that I am initializing as shown in the below code:
df2['FG_local_stop_time']=df2['FG_stop_time'] -timedelta(hours=4)
df3['now']=pd.Timestamp.now()
df3['now']=df3['now'].astype('datetime64[s]')
df3['stoptime_till_now']=df3['now'] - df3['FG_local_stop_time']The FGlocalstop_time and now columns are matching in format:
When i execute inside the node it shows up perfectly fine:
I don’t understand what’s going on.