This post was most recently updated on September 25th, 2021.2 min read.
Another quick one – I’m sure this doesn’t apply to all cases, but I’m still logging it in case someone (like myself) stumbles upon the issue and finds help here.
I was building a solution with some Azure Functions fetching and populating data in a database, and was planning on building a UI for browsing the data at some point later on – but I actually got stuck on the second step already :)
While adding the database to my project, and running Add-Migration in Entity Framework Core, I stumbled upon this error:
An assembly specified in the application dependencies manifest (ContosoProject.Functions.deps.json) was not found:
package: 'ContosoProject.Data', version: '1.0.0'
I was using .NET Core 3.1 – but you could probably run into this on other versions as well. I’m guessing the same fix should work – it’s a more general tooling issue after all :)
Verify the following things, and with any luck, you’re good:
Time needed: 2 minutes.
How to resolve the issue “An assembly specified in the application dependencies manifest was not found”?
- Change your target project to be the project that contains your database context file(s).
This step presumes you’re running the commandlet from the Package Manager Console. It has a dropdown for the Default project
- Change your startup project to be the project that contains your database files
This is the step I always fail at :) Not only does your “data project” (or whatever project is holding the database context, again) need to be the “Default project”, it also needs to be the Startup project of your solution.
You can set it by clicking said project using the right mouse button and selecting “Set as Startup Project” – see below:
Simple as that – you should be good.
- How to fix disconnected Sonoff Zigbee sensors in Home Assistant? - January 24, 2023
- How to fix all UWP/WinUI apps being laggy in Windows 10/11? - January 17, 2023
- How to export the SSL/TLS certificate from a website using PowerShell? - January 10, 2023