-
Notifications
You must be signed in to change notification settings - Fork 375
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
GnoDev - Conflicting Package Resolution Between Personal Repo and Examples Folder #2665
Comments
@gfanton remember when we discussed this? It has claimed its first victim |
@Molaryy can you see if it works if you use gnodev's |
@deelawn the issue is a bit different; By default, Then, a user might open up a completely different folder outside of the local copy of the monorepo, and create a package with the pkgpath |
I see. I'm currently working on changing the way packages will be loaded in |
@gfanton for this specific case, I think that if the user specifies a local path for a package to be loaded, that one should take precedence over the |
Description
I was preparing to create a PR to the examples folder with a project from my personal repository. I copied the contents of my realm and package into examples/gno.land/r in the main repository. In my code, I decided to change a type from int to uint64 because the value will never be below 0 in the package that I copied to the examples folder.
To test the changes, I made the necessary updates in my personal repository and used gnodev to check the results. However, I encountered an issue where gnodev sometimes picked up the old version of the package from the examples folder instead of the updated one from my repository. This led to errors that I had already resolved in my repository, causing confusion as I didn't realize gnodev was using the code from the examples folder.
After discussing with Leon and investigating further, I realized that gnodev was conflicting between the two packages due to the same name, causing it to sometimes pick the outdated package.
It would be helpful if gnodev could analyze the current package/realm and, if it finds a package with the same name in the examples folder, issue a warning. This would prevent confusion and ensure the correct package is used.
The text was updated successfully, but these errors were encountered: