-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
new version generates builderror #1576
Comments
And/or can you provide a sample project? |
hi, To be honest providing a sample project is very difficult because when i do it from scratch it works. I'm working on a very big project and was finally able to get everything working last week and it was working brilliantly until i do this update now :( |
is there a way to downgrade and install the version I had again? |
Sure, just reinstall v11.18.7... but i'd really like to fix this assembly loading problem. However I am getting crazy with all these assembly loading problems all the time... |
I understand... but at the moment I'm not able to spend much time looking. :( |
I'm having the same problem with every regular .Net Framework project I try to generate from. I'm attaching an example that manifests the error for me. The nswag file I used in NSwagStudio is in the root of the project folder. |
Ok thanks will look into this soon, just stay on the old version until we have a fix |
I don't seem to have a copy of the old version, and haven't been able to find a link to it. Where can I get it? |
@Zaismussen, if you use chocolatey:
Chocolately can be downloaded by following these instructions: https://chocolatey.org/install |
Let me know if there's anything I can do to help figure it out. I will probably have some time today and tomorrow to mess around with it, and I can probably survive a few days before downgrading if necessary. |
We really need a sample where we can repro this and which i can add to the test suite to avoid regressions in the future |
The generator has a dependency on core but it should work without that... |
Hi guys, I'm having exactly the same issue. Where can I get a microsoft installer for version 11.18.* or below? All installers I've found so far are the latest (11.19.0) |
In the github releases page you can find all old installers |
Got it! Thank you very much! |
Just updated to 11.20.1.0 and this issue still persists. Regular (non-Core) .NET Framework Web Api project. Referenced assemblies are search from: And also have the setting "Add local Nuget's cache folder to reference paths" enabled. |
I observe the same upgrading from 11.17.19 to 11.20.1. |
Did you try using a newer runtime, eg NetCore21? |
My project has to be full .net x86, unfortunately
…On Wed., 24 Oct. 2018, 5:13 pm Rico Suter, ***@***.***> wrote:
Did you try using a newer runtime, eg NetCore21?
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#1576 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/ADimvLbY9IwM8IfzcnyBH3BKgDTVspSFks5uoAUlgaJpZM4WaxXF>
.
|
I think we should change the dependency of the full .NET package to ASP.NET Core 2.0 then... the older libraries are no longer supported anyway... |
Why not change the dependency to what it used to be in older versions? Those worked just fine. |
just for the record. I had to change computer and with reinstalling everything. the latest version of nswagstudio is working perfectly! |
If I need to generate typescript from full .net 4.7 assembly, issue is still presented. I have also installed .net core 21. Change the runtime to NetCore21 doesn't help. |
@MirKml is the problem the spec generation or typescript generation? |
@RSuter Hm, this is little bit weird. When I upgraded from 11.18.7 via built in upgrading process to 11.20.1 then after newly upgraded nswag studio is started, I want to generate Typescript from .net 4.7 assembly, nswag crashes with the
After change runtime to NetCore21 and trying to do same thing, error is
It makes sense, I cannot load .net 4.7 assembly when netcore21 runtime is used. But when I download latest zip package from the http://rsuter.com/Projects/NSwagStudio/archive.php. Everything works fine. Maybe also with the uninstall and install via msi, but I didn't test. So maybe bug is somewhere in the MSI, upgrade process or something like that. |
Uninstall and install new version also works. So problem is definitely somewhere in upgrading process from 11.18.7 to newer version. But uninstall and install is reasonable workaround. So I think it can be closed. |
It's not just about the studio. Npm packages are also affected
…On Fri., 2 Nov. 2018, 1:59 am MirKml ***@***.*** wrote:
Uninstall and install new version also works. So problem is definitely
somewhere in upgrading process from 11.18.7 to newer version. But unistall
and install is reasonable workaround. So I think it can be closed.
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#1576 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/ADimvCiW-iBa7hP8LK_qBPiuDe6BlcQYks5uqwxFgaJpZM4WaxXF>
.
|
Yes? This is really strange as all binaries should be replaced, etc. |
You’renot using one of the ci build artifacts with the same version as the current released one? |
All I'm doing is npm I nswag... Latest version brings those weird old DLLs,
previous version has proper ones
…On Fri., 2 Nov. 2018, 8:11 am Rico Suter ***@***.*** wrote:
You’renot using one of the ci build artifacts with the same version as the
current released one?
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#1576 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/ADimvLDJVTZ350hhrj8KCYzGYW0ZfGhxks5uq2NygaJpZM4WaxXF>
.
|
But the version in the generated artifacts is correct? |
I don't use nswag nuget package in the asp.net project itself, just the npm
package. Same artifacts work fine with older nswag cli. The problem is in
the content of the latest npm package
…On Fri., 2 Nov. 2018, 8:16 am Rico Suter ***@***.*** wrote:
But the version in the generated artifacts is correct?
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#1576 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/ADimvEi18Ll8xCAFP4SgCodxkd8UwY3nks5uq2TEgaJpZM4WaxXF>
.
|
Yes, but the version in the generated spec or code is correct? |
Latest cli fails, so no typescript code gets generated yet. Besides the cli
output the project does not have any nswag dependencies
…On Fri., 2 Nov. 2018, 8:31 am Rico Suter ***@***.*** wrote:
Yes, but the version in the generated spec or code is correct?
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#1576 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/ADimvMyRX4KPUMlM-4UtjUs9fDIZcUTnks5uq2g2gaJpZM4WaxXF>
.
|
It seems that I had problems publishing to NPM in the v11.20.1 release so I had to manually release it - I think that an old version or something must have slipped in there... will investigate. A new version will be released in the next days anyway... |
When running latest version 11.20.1.0 from command line in windows environment, it crashed because of missing dlls. I worked around this issue by copying the missing dll from the "NSwagStudio" folder into the Win sub-folder as I kept encountering them. Eventually, I managed to run Nswag successfully. If I recall correctly the dlls I copied were Microsoft.AspNetCore.:
I am not 100% sure those were all. |
@RicoSuter I'm getting this error after trying to upgrade to .NET 8.0, using version From this command:
|
hi,
I just installed the new version of nswagstudio and without doing anything i get this error.
tonsoft.Json.JsonSerializationException: Error setting value to 'SelectedSwaggerGeneratorRaw' on 'NSwag.Commands.NSwagDocument'. ---> System.IO.FileNotFoundException: Could not load file or assembly 'Microsoft.AspNetCore.Hosting.Abstractions, Version=1.0.5.0, Culture=neutral, PublicKeyToken=adb9793829ddae60' or one of its dependencies. The system cannot find the file specified.
Check if .NET Core is installed and 'dotnet' is globally available.
I'm not using .net core.
please advise.
my nswag file:
{
"runtime": "Default",
"defaultVariables": null,
"swaggerGenerator": {
"webApiToSwagger": {
"controllerNames": [
"Euromex.Web.Controller.Webconsultatie.DocumentWebConsultatieController",
"Euromex.Web.Controller.Webconsultatie.DossierWebConsultatieController",
"Euromex.Web.Controller.Webconsultatie.MakelaarWebConsultatieController"
],
"isAspNetCore": false,
"defaultUrlTemplate": "api/{controller}/{id?}",
"addMissingPathParameters": false,
"defaultPropertyNameHandling": "CamelCase",
"defaultReferenceTypeNullHandling": "Null",
"defaultEnumHandling": "Integer",
"flattenInheritanceHierarchy": false,
"generateKnownTypes": false,
"generateXmlObjects": false,
"generateAbstractProperties": false,
"ignoreObsoleteProperties": false,
"allowReferencesWithProperties": true,
"excludedTypeNames": [],
"serviceHost": null,
"serviceBasePath": null,
"serviceSchemes": [],
"infoTitle": "DocumentWebConsultatieController",
"infoDescription": "The Document controller for the Web consultation app",
"infoVersion": "1.0.0",
"includedVersions": null,
"documentTemplate": null,
"documentProcessorTypes": [],
"operationProcessorTypes": [],
"typeNameGeneratorType": null,
"schemaNameGeneratorType": null,
"contractResolverType": null,
"serializerSettingsType": null,
"output": "../Content/Swagger specs/DocumentWebConsultatieControllerSpec.json",
"outputType": "Swagger2",
"assemblyPaths": [
"../bin/Euromex.Web.dll"
],
"assemblyConfig": "../Web.config",
"referencePaths": []
}
},
"codeGenerators": {
"swaggerToTypeScriptClient": {
"className": "{controller}Service",
"moduleName": "",
"namespace": "",
"typeScriptVersion": 2.7,
"template": "Angular",
"promiseType": "Promise",
"httpClass": "HttpClient",
"useSingletonProvider": true,
"injectionTokenType": "InjectionToken",
"rxJsVersion": 6.0,
"dateTimeType": "String",
"nullValue": "Undefined",
"generateClientClasses": true,
"generateClientInterfaces": false,
"generateOptionalParameters": true,
"exportTypes": true,
"wrapDtoExceptions": false,
"clientBaseClass": "",
"wrapResponses": false,
"wrapResponseMethods": [],
"generateResponseClasses": true,
"responseClass": "SwaggerResponse",
"protectedMethods": [],
"configurationClass": "",
"useTransformOptionsMethod": false,
"useTransformResultMethod": false,
"generateDtoTypes": true,
"operationGenerationMode": "MultipleClientsFromOperationId",
"markOptionalProperties": true,
"generateCloneMethod": false,
"typeStyle": "Class",
"classTypes": [],
"extendedClasses": [],
"extensionCode": null,
"generateDefaultValues": true,
"excludedTypeNames": [],
"handleReferences": false,
"generateConstructorInterface": true,
"convertConstructorInterfaceData": false,
"importRequiredTypes": true,
"useGetBaseUrlMethod": false,
"baseUrlTokenName": "API_BASE_URL",
"queryNullValue": "",
"templateDirectory": null,
"typeNameGeneratorType": null,
"propertyNameGeneratorType": null,
"enumNameGeneratorType": null,
"serviceHost": null,
"serviceSchemes": null,
"output": "../../Euromex.WebConsultatie/src/app/services/Generated/WebConsultatie.WebApi.Generated.Service.ts"
}
}
}
The text was updated successfully, but these errors were encountered: