Skip to content
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

Error scaffolding external module if associated type not a ref #2503

Closed
matt2e opened this issue Aug 26, 2024 · 0 comments · Fixed by #2504
Closed

Error scaffolding external module if associated type not a ref #2503

matt2e opened this issue Aug 26, 2024 · 0 comments · Fixed by #2504
Assignees

Comments

@matt2e
Copy link
Collaborator

matt2e commented Aug 26, 2024

Steps to repro:

  • Create a module that uses an external ref with an associated type that isn't a ref
    • eg: builtin.CatchRequest[[]string]

Expected result:

  • module should build with the correct associated types

Actual result:

  • Usually the code succeeds because most types can be happily parsed as if they are refs
    • eg: string gets parsed as Ref{Name:"String", Module:""}
  • If the type can not be parsed as a ref, then compiling causes a panic
    • eg: builtin.CatchRequest[[]string] because []string can not be parsed as a ref

panic is here: https://github.com/TBD54566975/ftl/blob/main/go-runtime/compile/build.go#L405

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 a pull request may close this issue.

1 participant