I want to check if the 1 outputs variable of 1 tas...
# flyte-support
f
I want to check if the 1 outputs variable of 1 task can be match with 1 inputs variable of another task. So simplely i check it by get task_pb2 with flytekit.client.raw.get_task
Copy code
#task1 and task2 type is flyteidl.admin.task_pb2.Task
type1 = task1.closure.compiled_task.template.interface.outputs.variables['output_1_task_1].type
type2 = task2.closure.compiled_task.template.interface.inputs.variables['input_1_task_2].type

if type1 == type2:
   return True
else:
   return False
is this condition good enough for all type, set of types. Include hard case such as TypeTransform, Simple Schema, ...?
g
yes, I think so.
👍 1
did you see any error?
f
I have just tested with simple type and it's ok
@glamorous-carpet-83516 i will ask you later if i have any issues.
g
thanks. also test structuredDataset when you get a chance.
👍 1