-
Notifications
You must be signed in to change notification settings - Fork 836
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
Can't package cloud service since upgrading to DocumentDB SDK 1.6.2 #118
Comments
@mleyb : Thanks for reporting this issue. We need some more information from you so that we can repro/diagnose this issue on our end.
If you could provide simple repro steps that repro that issue that would help us verifying the fix before we update the Nuget package. |
Our cloud service project has 5 roles - 3 web roles and 2 worker roles. However, I've been able to reproduce this issue in a vanilla project containing a single web role Here are some repro steps:
Packaging fails, here's an example of the error:
|
@mleyb Thanks for sharing the repro steps! We are preparing a fix for this issue and will do a release by Monday. |
Awesome, thanks! :)
|
@mleyb : We fixed the issue and have published .NET SDK 1.6.3 to Nuget. Please try installing the latest version and let us know if that fixes the issue. |
All working now - thanks a lot guys 👍 |
@rnagpal : It seems the problem still exist in version 1.7.1 |
I appear to be having the same problem in 1.7.1 as well. |
@aidanmorgan : seems like you if you use the Microsoft.Azure.DocumentDB nuget in different class library project and reference it in your web project, you will not get this problem. But if you reference the Microsoft.Azure.DocumentDB nuget directly in the web project you will get this issue. |
Thanks for reporting this. We will look into this issue and get back soon. |
I'm using VS 2015 Update 2 and I have a ASP.NET 4.6 web project. I referenced the Microsoft.Azure.DocumentDB using PackageManager console. When I build the project everything is ok, but when I run in debug mode (Any CPU) I get the following message in the yellow screen. This just happens after simply referencing the assembly in the project. Error : Could not load file or assembly Developer machine runs on x64 Windows 10. The web project has following dependencies
|
I have pretty much the same scenario as @thuru , however this morning I rolled back my changes and re-did them, installing the package first and the problem is no longer occurring. |
@aidanmorgan could you list the dependencies of your project ? I tried this morning same issue exists. |
When referencing the Microsoft.Azure.DocumentDB in the web project it seems to create these 2 dlls which cause the issue.
|
as @mleyb mentioned version 1.5.3 works fine. |
Working offline with Thuru to get a repro. Will update the thread once the issue is resolved. |
@aidanmorgan : Do you have a sample project that repro'es this issue consistently? If yes, I can work with you offline to get the project and investigate further. @thuru is not able to repro it now on a new project, so my guess is that this is related to some project specific setting. Which .NET Framework version you guys are targeting for the Web Application? If you could share the snippet of code that would try to load this assembly and fail, that would help. |
Any update on this? Also seeing the assembly load exceptions for Spatial.SQL and ServiceInterop when starting my project. |
@jamesbascle : I was unable to repro the issue on my end so if you can provide the exact repro steps, I can try again. Which version of .NET SDK are you using? |
I'm using .NET 4.5.2, and see the behavior on version of DocumentDB 1.8.0, 1.7.3, 1.6.3. I am available right now if you'd like to do a remote session. Not quite sure what the repo steps are exactly, just that when I start my project, I get the assembly load exception on those 2 DLLs. |
@rnagpal could you explain the functional requirement of those 2 assemblies in the versions above 1.5.3 |
same issue for me as well. I'm using the documentdb sdk in a class library and referencing that from a console app...this happens on every startup. I'm using the latest version of the docdb sdk. |
@rnagpal here is the full stack trace for the issue I'm seeing. Seems to be very similar to @thuru . .Net 4.6.1, SDK v1.8, Console app referencing a class lib installed via nuget. This happens every single time the console app loads... and we run these a lot, so it's spamming our raygun crash reporting consistently. for Spacial.Sql:
for ServiceInterop:
|
@thuru @aidanmorgan @jamesbascle @sirkirby Here is a quick update on this issue:
Let me know if these workarounds work for you guys until we fix the issue. |
@thuru @aidanmorgan @jamesbascle @sirkirby We have released .NET SDK 1.9.1 with the fix for the first issue: Missing dll issue for Microsoft.Azure.Documents.ServiceInterop.dll and DocumentDB.Spatial.Sql.dll that most of you in the thread had reported. Please update to this version and let me know if that resolves the issue. For the second issue, your application(whether it's a Console or Web project) needs to be 64 bit preferred. By default, VS project has AnyCPU as the target platform with "Prefer 32-bit" set to true. So if you see that exception, uncheck the "Prefer 32-bit" option in your project properties window, on the Build tab, to avoid the error. You can continue to use AnyCPU as the target platform given you have unchecked the above "Prefer 32-bit" option. If you can target x64 that works as well. |
Trying the DOc DB integration in a Visual studio test. The code to talk to doc db is in a separate class library referred in the Test project. upgraded to version 1.10.0 and getting the error {"Unable to load DLL 'Microsoft.Azure.Documents.ServiceInterop.dll': The specified module could not be found. (Exception from HRESULT: 0x8007007E)"} I copied this file to the test out put and bin of the test project but does not work |
No solutions yet :( our production still runs on 1.5.3 |
@thuru I'll contact you early next week and we will resolve this and if there is still a bug we will fix it asap. |
@gorkar We resolved this issue offline. He was missing DocumentDB.Spatial.Sql.dll in his deployment dir which is needed to load Service.Interop.dll, so if you see the error regarding unable to find/load Service Interop dll, please make sure you have both binaries in your app's bin dir. |
I've just started getting this issue since upgrading to 1.10. We're an ASP.net core app running on full framework, and we use partitioned documentdb collections. Presumably this is now happening due to the fact that partitioned collections support direct connections (which is a feature we really want). |
@Fritzbraun We currently don't yet support DocumentDB on ASP.NET Core apps and we are currently working on it. Even you are able to copy this dll(along with DocumentDB.Spatial.Sql.dll), you may run into issues for some of the APIs that would fail on .NET Core target platform. We're an ASP.net core app running on full framework |
Yes, we're using the dotnet tooling and associated nuget packages, but we're targeting "net462". I added a postcompile script to copy the dlls across and that worked ok for running locally, but publishing to Azure still fails as it doesn't copy those dlls across to the staging directory. I think I might be able to get it to work using a pre or postpublish step, but I'll have to hardcode the version of DocumentDB into these steps as you can't get at them programatically. Is there a timeline for when we can expect it to work with the .net core tooling? Could you not get around this whole issue by just making the other dlls their own nuget packages? |
Facing the same" Unable to load DLL 'Microsoft.Azure.Documents.ServiceInterop.dll" on.net461 with version 1.9 and 1.10 , but 1.8 is working fine. and no .net core is involved here. Are you guys aware of this scenario as well ? Using it from project.json of xproj . Even after I copy and place the specific dll , it still throws the same error. Any workarounds ? |
@kaleemxii Make sure you also copy the DocumentDB.Spatial.Sql.dll in the same place. I've seen that error goes away when both dlls are present. They seem to be dependent on each other. |
@Fritzbraun We are working on the .net core support currently and should be releasing a preview next month. For now you would have to use a script to copy them due to lack of tooling. I take your feedback to have them in a separate nuget packages. |
@rnagpal We are having the following error "Could not load file or assembly 'file:///C:\xxx\bin\DocumentDB.Spatial.Sql.dll' or one of its dependencies. The module was expected to contain an assembly manifest." |
@rnagpal @azakhodin same here. We only build x64 and I can't get beyond the error: Could not load file or assembly 'file:///C:\Repositories\Fitabase\FitabaseAPI\bin\DocumentDB.Spatial.Sql.dll' or one of its dependencies. The module was expected to contain an assembly manifest. On .net452, x64, and we've got 1.10.0 installed. Any other hints how to even debug what's going on here? |
I'm looking into this now and will update in few days. The issue is that if you are using project.json tooling this doesn't seem to work. |
@rnagpal I do not have project.json and am getting this error. I am linking to a class library which references this library, from an ASP.NET WebAPI 2 project and that is causing it. Have tried referencing the NuGet in one, and then both projects. Still get the same error. Any workarounds at all? |
@rnagpal I was able to figure out my issue, posting here for anyone else (@thuru @aidanmorgan)? This was the stacktrace error on runtime:
Turns out WebActivator was the issue. This was a dependency on AttributeRouting package(https://www.nuget.org/packages/AttributeRouting/), and there is a known issue with updating WebActivator to a new WebActivatorEx. This new version, WebActivatorEx that takes the place of WebActivator. Manually removing and reinstalling both WebActivatorEx and AttributeRouting fixed it. This thread was helpful: http://stackoverflow.com/questions/18325799/could-not-load-file-or-assembly-hunspellx64-dll-while-using-nhunspell-nuget-pack |
@aarondcoleman Thanks for posting the solution! |
We're still seeing this. I'll list out all of the conditions we're running under, just in case. Azure Web Apps; Lib Version 1.10.0; C#6; .NET 4.5.2; x64 (Project and App Service); VS2015; Autofac.WebApi2.Owin 3.3.0; Autofac.WebApi 2.3.4.0; Owin 1.0; WebActivatorEx 2.2.0 We are not using MVC at all, or the AttributeRouting package. These exceptions (for both DocumentDB.Spatial.Sql.dll and Microsoft.Azure.Documents.ServiceInterop.dll) don't seem to actually keep us from interacting with DocumentDB, but we see them in Diagnostic Tools as the first event every time we debug locally with IISExpress in VS2015, or take a memory dump from the Azure Web App service. |
I had this issue today while running IIS on my local computer. I tried everything: manually adding the missing DLL in the bin folder, rebuilding, trying multiple versions of documentdb via nuget, building in x64 and x86, ... It was still happening even if the missing DLL files were presents. Finally, I updated Visual Studio 2015 and azure SDK with the very latest versions and after cleaning and rebuilding my projet it started working again. |
I have a related issue in which a .NET 4.5.2 nuget package, that references Microsoft.Azure.DocumentDB (1.11.1), fails to install with error:
I've worked through the above with no success as yet. |
@FaC7oR That's a different issue. What's causing the error above. Note that you don't need to reference this dll anywhere in your project(unlike Microsoft.Azure.Documents.Client.dll). This dll is needed only at runtime and just need to be binplaced along with the Client dll which if you are importing the nuget package correctly should work. What's the type of the project(Console/ASP.NET/Library) you are using? Are you doing anything with DocumentDB.Spatial.Sql which is causing this? |
It's a packaging problem, i.e. nuget reports this error when trying to install a custom package that I've created. More precisely: I'm importing a class library nuget, that I've created/packaged with a dependency on DocumentDB, into another class library (a blank test project). Both target .NET 4.5.2 and have an x64 build configuration. I'm not using DocumentDB.Spatial.Sql at all. |
I should also add: I'm not referencing/using DocumentDB.Spatial.Sql at all. Nuget seems to be looking for it when I install my package. |
Just FYI, if you check the document db package, it has the spatial DLL
inside it alongside the document db DLL.
…On Dec 30, 2016 10:15 AM, "fac7or" ***@***.***> wrote:
I should also add: I'm not referencing/using DocumentDB.Spatial.Sql at
all. Nuget seems to be looking for it when I install my nuget.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#118 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AD_ohdsb5Vyft8hShE5dfqumxZj9OR4Xks5rNSAKgaJpZM4IA5S1>
.
|
I've managed to sort the problem. I needed to tell nuget to look for DocumentDB.Spatial.Sql explicitly, i.e. by adding the following to my nuspec file:
Would it be worth packaging the offending binary separately to keep nuget happy? |
I want to call out if there is anyone in this thread that still has issues with the referencing/copying ServiceInterop and Spatial native dlls please open a new issue detailing the environment as this post has become too big to refer. I'll reference this link in any of the new issues created. @thuru Did it finally worked for you? If not send me an email and we can debug it on a Skype call as you seem to be stuck with 1.6 version due to thus issue. |
I just ran into this, or something like this. I'm getting build errors: "DocumentDB.Spatial.Sql.dll' is a binary file instead of a text file" and "Microsoft.Azure.Documents.ServiceInterop.dll' is a binary file instead of a text file". I'm using the documentdb sdk 1.13.1 and referencing a nuget package that refers to it in and ASP.NET Core (Framework) app. |
Hi - Since upgrading to SDK 1.6.2 through NuGet I am no longer able to package my Cloud Service. The packaging operation fails with the following error:
I've reverted to SDK 1.5.3 and I my package step works OK
Is this a similar problem to microsoft/TypeScript#6215 ?
I notice that the path contains two paths concatenated together in a similar way
The text was updated successfully, but these errors were encountered: