Installed package not found
Having an issue with using my own InfiniLore.InfiniBlazor.Theming package within another solution. The package is referenced in my csproj and on nuget it shows it exists (version 0.1.0-preview.29), but I can't find it in the obj/bin folders after restore, which results in me being totally unable to use the code from within the package.
Project setup:
- Using .NET 9.0
- Package is properly referenced in csproj:
<PackageReference Include="InfiniLore.InfiniBlazor.Theming" />
(using central package management)
- Already tried dotnet nuget locals all --clear
and dotnet restore
but that didnt help anything.
- Other packages from the same family (like InfiniBlazor.Contracts) work fine.
- I daily drive Rider, but the same issue also happens in Visual Studio. On startup of the IDE the package brefiely appears in the Package viewer of the project consuming it, and then dissapears.
Any code referenced from within the package is this not seen as valid and causes errors, even though the source code compiles fine, like when I try use the blazor component InfiniThemeManager
it is not being recognized.
Am I missing something obvious here? Has anyone else encountered this issue?9 Replies
.nuget/packages
in your userprofile.dotnet add package InfiniLore.InfiniBlazor.Theming
on the consuming csproj... I have no clue why that one of all things finally did it, as I had deleted and reinstalled it many times through rider as well, but it now works...Unknown User•2w ago
Message Not Public
Sign In & Join Server To View
Yes I know that, these packages are stored in one universal place and then used where required. but, given that the dll's of all other packages are found within the
bin/Release/net9.0/...
folder and directly copying the dll of InfiniLore.InfiniBlazor.Theming
to this folder does make my built solution work.
I can also find the downloaded package in my userprofile's .nuget/packages
so no direct issue there either.
Like I said in the struck through section, if I manually do a dotnet add package InfiniLore.InfiniBlazor.Theming
after the solution has been built, I can run the application without issues. Then if I stop the server and do a rebuild, the package's dll in question dissapears again.
I cant reproduce the same error in a minimal reproducible github repo, so I'll link the branch Im currently working on: https://github.com/InfiniLore/infinilore.cs/tree/lorescopes-primary_note
With the following project csproj file which is the consumer of the package that breaks it all https://github.com/InfiniLore/infinilore.cs/blob/lorescopes-primary_note/src/InfiniLore.Server/InfiniLore.Server.csprojGitHub
GitHub - InfiniLore/infinilore.cs at lorescopes-primary_note
Contribute to InfiniLore/infinilore.cs development by creating an account on GitHub.
GitHub
infinilore.cs/src/InfiniLore.Server/InfiniLore.Server.csproj at lor...
Contribute to InfiniLore/infinilore.cs development by creating an account on GitHub.
Unknown User•2w ago
Message Not Public
Sign In & Join Server To View
Yes, sorry I have also removed them in various tests to make it work. Will remove them now in a new commit, as they are a remainder of some previous stuff I still needed to clean up by the end of the branch.
Given that my
InfiniLore.InfiniBlazor.Theming
nuget package can be installed correctly in other solutions, or even projects within the broken solution (I checked and InfiniLore.Wasm
also has this nuget package installed and is included correctly in the build output) I feel like the issue has to be with the InfiniLore.Server
itself somehow.I'll also include a link to the
InfiniLore.InfiniBlazor.Theming
original csproj file, maybe that can show more insight into the issue https://github.com/InfiniLore/infinilore.infiniblazor/blob/core/src/InfiniLore.InfiniBlazor.Theming/InfiniLore.InfiniBlazor.Theming.csprojGitHub
infinilore.infiniblazor/src/InfiniLore.InfiniBlazor.Theming/InfiniL...
The Component Library for InfiniLore. Contribute to InfiniLore/infinilore.infiniblazor development by creating an account on GitHub.
Another thing it could maybe have been is incompatible packges, but I dont think that is the case if I run the add command manually:
Okay, I have found the culprit... in the server.csproj file I import these pacakges from my InfiniBlazor, which results in Theming not being loaded
Then If I remove
<PackageReference Include="InfiniLore.InfiniBlazor" />
, Theming magically does get loaded and output to the final build ... One step closerThe following is the csproj file of
InfiniLore.InfiniBlazor
, but I dont see what could be causing the issue...I tried to see in a minimal reproducible github repo, if it behaved the same there, with all the packages of InfiniBlazor installed, but there they all nicely work together..., so again it is only this solution that isnt working nicely
going to call it a day as well, am glad I found a patch, but am not happy with it