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

Kotlin build errors on ftl dev . #991

Closed
wesbillman opened this issue Feb 27, 2024 · 1 comment · Fixed by #993
Closed

Kotlin build errors on ftl dev . #991

wesbillman opened this issue Feb 27, 2024 · 1 comment · Fixed by #993
Assignees
Labels
P0 Work on this now

Comments

@wesbillman
Copy link
Collaborator

When using FTL in another repo, we're getting the following errors when running ftl dev ..

   backend | go: ftl/accounts imports
   backend | 	go.jetpack.io/typeid tested by
   backend | 	go.jetpack.io/typeid.test imports
   backend | 	github.com/stretchr/testify/assert: github.com/TBD54566975/[email protected]: verifying go.mod: github.com/TBD54566975/[email protected]/go.mod: reading https://sum.golang.org/lookup/github.com/!t!b!d54566975/[email protected]: 404 Not Found
   backend | 	server response: not found: create zip: kotlin-runtime/external-module-template/target.tmpl/generated-sources/ftl/{{ range .ExternalModules }}{{ push .Name . }}{{ end }}/{{ .Name | camel }}.kt: malformed file path "kotlin-runtime/external-module-template/target.tmpl/generated-sources/ftl/{{ range .ExternalModules }}{{ push .Name . }}{{ end }}/{{ .Name | camel }}.kt": invalid char '|'
@wesbillman wesbillman added the P0 Work on this now label Feb 27, 2024
@github-actions github-actions bot added triage Issue needs triaging and removed triage Issue needs triaging labels Feb 27, 2024
@alecthomas
Copy link
Collaborator

I know why this is happening. Will send a fix with an explanation.

alecthomas added a commit that referenced this issue Feb 27, 2024
`|` is not supported in filenames retrieved by the Go toolchain, as
Windows doesn't allow it in filenames. As we're zipping these files,
this isn't a concern for us, but it's still prevented by Go. To work
around this we create a dummy `go.mod` file which Go interprets as a
separate module and thus ignores.

Fixes #991
alecthomas added a commit that referenced this issue Feb 27, 2024
`|` is not supported in filenames retrieved by the Go toolchain, as
Windows doesn't allow it in filenames. As we're zipping these files,
this isn't a concern for us, but it's still prevented by Go. To work
around this we create a dummy `go.mod` file which Go interprets as a
separate module and thus ignores.

Ask me how I figured this out?

Fixes #991
@alecthomas alecthomas assigned alecthomas and unassigned worstell Feb 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
P0 Work on this now
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants