Track module's package to prevent Types module collision - #110
Open
Janiczek wants to merge 2 commits into
Open
Conversation
Janiczek
commented
Aug 20, 2026
Collaborator
Author
There was a problem hiding this comment.
ah dang, I forgot this PR doesn't only touch ext* but the original Elm source as well ... Should we somehow minimize the diff in these worker/* files? For example keep checkImports type signature as-is and then have just an one-line change where we call checkImports?
Member
There was a problem hiding this comment.
Why do you need to touch the original Elm code at all?
Collaborator
Author
There was a problem hiding this comment.
Thanks, your comment led me to realize I can do this without those changes (=> without changing the artifact files)
Packages like miyamoen/select-list have their own internal `Types` module. This doesn't play nice with Lamdera Wire logic which didn't take the possibility into account and just tracked raw module names instead of also the package that owns them. The fix involves tracking ModuleName.Canonical instead of ModuleName.Raw.
Janiczek
force-pushed
the
janiczek-track-module-info
branch
from
August 21, 2026 16:13
ecf2f28 to
8ecdfc8
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Quick Summary:
Relates to this Discord thread.
In my Lamdera app I'm using miyamoen/select-list which internally contains a
Typesmodule.This wreaks havoc onto Lamdera's code, which uses
ModuleName.Rawinstead ofModuleName.Canonicaland expects that theTypesmodule name only means "the user'sTypesmodule", and this error can be seen:SSCCE
lamdera initlamdera install miyamoen/select-listFrontendModelto contain aSelectList ()init)lamdera deploy-> get the above error.Additional Details
I don't like that the test depends on the
select-listpackage having a specific internal module structure. If we can somehow hardcode things into the test fixture directory that would be nicer. IDK if it's possible or if Lamdera test suite has some helpers for that though.