Dylan Wilder
08/30/2022, 8:41 PMonemodel.get_assumptions.base_prices
but it registered as `onemodel.models.annotations.wf.onemodel.models.annotations.onemodel.get_assumptions.base_prices`*.* Any ideas? i'm guessing something around tracked instance is injecting this?Yee
Yee
Dylan Wilder
08/30/2022, 8:47 PMDylan Wilder
08/30/2022, 8:48 PMDylan Wilder
08/30/2022, 8:51 PMYee
Yee
Dylan Wilder
08/30/2022, 9:19 PMYee
Dylan Wilder
08/30/2022, 9:20 PMDylan Wilder
08/30/2022, 9:22 PMYee
Yee
Dylan Wilder
08/30/2022, 11:15 PMYee
Dylan Wilder
08/30/2022, 11:15 PMYee
Yee
Yee
Dylan Wilder
08/30/2022, 11:16 PMDylan Wilder
08/30/2022, 11:17 PMYee
Yee
Yee
Yee
Yee
Dylan Wilder
08/31/2022, 2:42 AMDylan Wilder
08/31/2022, 2:43 AMDylan Wilder
08/31/2022, 3:02 AMDylan Wilder
08/31/2022, 3:32 AMDylan Wilder
08/31/2022, 4:11 PMctx = FlyteContextManager.current_context()
state = ctx.compilation_state.with_params("", resolver=_resolver)
with FlyteContextManager.with_context(ctx.with_compilation_state(state)):
task = cls._Task(assumption_name)
But i'm unclear what the intended behavior is ie why does the task contstructor ignore the passed resolver in favor of something in the global contextDylan Wilder
08/31/2022, 4:12 PMKetan (kumare3)
Ketan (kumare3)
Dylan Wilder
08/31/2022, 4:14 PMDylan Wilder
08/31/2022, 4:15 PMYee
Yee
Yee
Dylan Wilder
08/31/2022, 4:17 PMYee
Dylan Wilder
08/31/2022, 4:17 PMDylan Wilder
08/31/2022, 4:18 PMYee
Yee
def test_dwild():
x = BasePricesSchema.name
print(x)
Assumptions.get(version_id="abc", assumption=x)
@task
def t2(pdf: BasePricesSchema) -> int:
return len(pdf)
@workflow
def wf(version_id: str) -> int:
bp = Assumptions.get(version_id=version_id, assumption=BasePricesSchema.name)
return t2(pdf=bp)
this test produces the wrong name.Yee
Yee
def test_dwild():
x = BasePricesSchema.name
print(x)
Assumptions.get(version_id="abc", assumption=x)
# @task
# def t2(pdf: BasePricesSchema) -> int:
# return len(pdf)
#
#
# @workflow
# def wf(version_id: str) -> int:
# bp = Assumptions.get(version_id=version_id, assumption=BasePricesSchema.name)
# return t2(pdf=bp)
Dylan Wilder
08/31/2022, 4:19 PMYee
Dylan Wilder
08/31/2022, 4:20 PMDylan Wilder
08/31/2022, 4:23 PMYee
Yee
Dylan Wilder
08/31/2022, 4:42 PM