Skip to content

Compose Runtime Integration Take 2 #823

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 1 commit into from

Conversation

steve-the-edwards
Copy link
Contributor

No description provided.

@steve-the-edwards steve-the-edwards force-pushed the sedwards/compose-take-2 branch 2 times, most recently from 28155a8 to 9efe031 Compare June 30, 2022 18:53
@steve-the-edwards steve-the-edwards force-pushed the sedwards/compose-take-2 branch from 9efe031 to eec92fa Compare June 30, 2022 21:37
renderState: IsLoading,
context: RenderContext,
hoistRendering: @Composable (rendering: MayBeLoadingScreen) -> Unit
) {
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm stumped here. These overrides are recognized by the compiler as it runs in the IDE but when tracing through the call always goes through to the base StatefulWorkflow::Rendering implementation?

@zach-klippenstein any idea why this override wouldn't be recognized at runtime?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reproduced in small project. I believe bug in Molecule - cashapp/molecule#91

hoistRendering: @Composable (rendering: RenderingT) -> Unit
): Unit {
// By default call render() as a fallback.
hoistRendering(render(renderProps, renderState, context))
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I did this so I don't have to modify every workflow and test to get this to compile. However, at runtime the Workflow.Rendering gets resolved here rather than to the child function. 😢

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@steve-the-edwards
Copy link
Contributor Author

Closed in favour of #824

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant