You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
unsupported external type "github.com/TBD54566975/tbdex-go/tbdex.Message"; see FTL docs on using external types: tbd54566975.github.io/ftl/docs/reference/externaltypes/
Potential Solution
when code-gen'ing a module's main.go i think it might be helpful to generate package aliases using a pattern that has a very low likelihood of someone actually using. e.g. __tbdex "github.com/TBD54566975/tbdex-go/tbdex"
The text was updated successfully, but these errors were encountered:
fixes#2469
When scaffolding imports for external go packages, FTL will use the
shortest unique part of the path as the alias. This allows package
aliases to have neat and expected aliases in simple cases, and falling
back to the next best option as conflicts arise.
For example:
```
import (
unique "github.com/two2/foo/unique.Type"
one_foo_bar "github.com/one/foo/bar.Type"
two_foo_bar "github.com/two/foo/bar.Type"
)
```
Issue
declaring the following type alias:
and then using it in the
tbdex
module causes the module's codegen'dmain.go
to include two imports of the same name e.g.running
ftl build
produces the following error:renaming the import in the source file like so:
produces a different error:
Potential Solution
when code-gen'ing a module's
main.go
i think it might be helpful to generate package aliases using a pattern that has a very low likelihood of someone actually using. e.g.__tbdex "github.com/TBD54566975/tbdex-go/tbdex"
The text was updated successfully, but these errors were encountered: