{"action":"closed","issue":{"url":"https://api.github.com/repos/rbeauchamp/Swashbuckle.OData/issues/164","repository_url":"https://api.github.com/repos/rbeauchamp/Swashbuckle.OData","labels_url":"https://api.github.com/repos/rbeauchamp/Swashbuckle.OData/issues/164/labels{/name}","comments_url":"https://api.github.com/repos/rbeauchamp/Swashbuckle.OData/issues/164/comments","events_url":"https://api.github.com/repos/rbeauchamp/Swashbuckle.OData/issues/164/events","html_url":"https://github.com/rbeauchamp/Swashbuckle.OData/issues/164","id":264395906,"node_id":"MDU6SXNzdWUyNjQzOTU5MDY=","number":164,"title":"Swashbuckle.OData.HttpConfigurationExtensions threw an exception. \"ExceptionType\":\"System.TypeInitializationException\"","user":{"login":"BryanWilhite","id":5226627,"node_id":"MDQ6VXNlcjUyMjY2Mjc=","avatar_url":"https://avatars0.githubusercontent.com/u/5226627?v=4","gravatar_id":"","url":"https://api.github.com/users/BryanWilhite","html_url":"https://github.com/BryanWilhite","followers_url":"https://api.github.com/users/BryanWilhite/followers","following_url":"https://api.github.com/users/BryanWilhite/following{/other_user}","gists_url":"https://api.github.com/users/BryanWilhite/gists{/gist_id}","starred_url":"https://api.github.com/users/BryanWilhite/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/BryanWilhite/subscriptions","organizations_url":"https://api.github.com/users/BryanWilhite/orgs","repos_url":"https://api.github.com/users/BryanWilhite/repos","events_url":"https://api.github.com/users/BryanWilhite/events{/privacy}","received_events_url":"https://api.github.com/users/BryanWilhite/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":6,"created_at":"2017-10-10T22:21:30Z","updated_at":"2018-10-05T17:06:22Z","closed_at":"2018-10-05T17:06:22Z","author_association":"NONE","body":"We are getting this exception:\r\n\r\n```json\r\n500 : {\"Message\":\"An error has occurred.\",\"ExceptionMessage\":\"The type initializer for 'Swashbuckle.OData.HttpConfigurationExtensions' threw an exception.\",\"ExceptionType\":\"System.TypeInitializationException\",\"StackTrace\":\" at Swashbuckle.OData.HttpConfigurationExtensions.SerializerSettingsOrDefault(HttpConfiguration httpConfig)\\r\\n at Swashbuckle.OData.ODataSwaggerProvider.GenerateSwagger(String rootUrl, String apiVersion) in C:\\\\Users\\\\rbeauchamp\\\\Documents\\\\GitHub\\\\Swashbuckle.OData\\\\Swashbuckle.OData\\\\ODataSwaggerProvider.cs:line 63\\r\\n at Swashbuckle.OData.ODataSwaggerProvider.GetSwagger(String rootUrl, String apiVersion) in C:\\\\Users\\\\rbeauchamp\\\\Documents\\\\GitHub\\\\Swashbuckle.OData\\\\Swashbuckle.OData\\\\ODataSwaggerProvider.cs:line 56\\r\\n at Swashbuckle.Application.SwaggerDocsHandler.SendAsync(HttpRequestMessage request, CancellationToken cancellationToken)\\r\\n at System.Net.Http.HttpMessageInvoker.SendAsync(HttpRequestMessage request, CancellationToken cancellationToken)\\r\\n at System.Web.Http.Dispatcher.HttpRoutingDispatcher.SendAsync(HttpRequestMessage request, CancellationToken cancellationToken)\\r\\n at System.Net.Http.DelegatingHandler.SendAsync(HttpRequestMessage request, CancellationToken cancellationToken)\\r\\n at System.Web.Http.HttpServer.<SendAsync>d__0.MoveNext()\",\"InnerException\":{\"Message\":\"An error has occurred.\",\"ExceptionMessage\":\"Could not load file or assembly 'System.Web.OData, Version=6.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040)\",\"ExceptionType\":\"System.IO.FileLoadException\",\"StackTrace\":\" at Swashbuckle.OData.HttpConfigurationExtensions..cctor()\"}} http://localhost:56744/swagger/docs/v2\r\n```\r\nWe do not find this issue when we ran [Microsoft.AspNet.OData 6.0.0](https://www.nuget.org/packages/Microsoft.AspNet.OData/6.0.0) and will roll back for immediate relief.\r\n\r\nThese are all the packages in play:\r\n\r\n```xml\r\n<?xml version=\"1.0\" encoding=\"utf-8\"?>\r\n<packages>\r\n  <package id=\"AutoMapper\" version=\"6.1.1\" targetFramework=\"net452\" />\r\n  <package id=\"EntityFramework\" version=\"6.1.3\" targetFramework=\"net45\" />\r\n  <package id=\"EPPlus\" version=\"4.1.0\" targetFramework=\"net452\" />\r\n  <package id=\"Microsoft.AspNet.Cors\" version=\"5.2.3\" targetFramework=\"net45\" />\r\n  <package id=\"Microsoft.AspNet.OData\" version=\"6.1.0\" targetFramework=\"net452\" />\r\n  <package id=\"Microsoft.AspNet.WebApi\" version=\"5.0.0\" targetFramework=\"net45\" />\r\n  <package id=\"Microsoft.AspNet.WebApi.Client\" version=\"5.2.3\" targetFramework=\"net45\" />\r\n  <package id=\"Microsoft.AspNet.WebApi.Core\" version=\"5.2.3\" targetFramework=\"net45\" />\r\n  <package id=\"Microsoft.AspNet.WebApi.Cors\" version=\"5.2.3\" targetFramework=\"net45\" />\r\n  <package id=\"Microsoft.AspNet.WebApi.OData\" version=\"5.7.0\" targetFramework=\"net45\" />\r\n  <package id=\"Microsoft.AspNet.WebApi.WebHost\" version=\"5.2.3\" targetFramework=\"net45\" />\r\n  <package id=\"Microsoft.Data.Edm\" version=\"5.8.3\" targetFramework=\"net452\" />\r\n  <package id=\"Microsoft.Data.OData\" version=\"5.8.3\" targetFramework=\"net452\" />\r\n  <package id=\"Microsoft.Extensions.DependencyInjection\" version=\"1.0.0\" targetFramework=\"net452\" />\r\n  <package id=\"Microsoft.Extensions.DependencyInjection.Abstractions\" version=\"1.0.0\" targetFramework=\"net452\" />\r\n  <package id=\"Microsoft.OData.Core\" version=\"7.3.1\" targetFramework=\"net452\" />\r\n  <package id=\"Microsoft.OData.Edm\" version=\"7.3.1\" targetFramework=\"net452\" />\r\n  <package id=\"Microsoft.Spatial\" version=\"7.3.1\" targetFramework=\"net452\" />\r\n  <package id=\"Microsoft.Web.Infrastructure\" version=\"1.0.0.0\" targetFramework=\"net45\" />\r\n  <package id=\"Net.Http.WebApi.OData\" version=\"3.4.1\" targetFramework=\"net452\" />\r\n  <package id=\"Newtonsoft.Json\" version=\"10.0.3\" targetFramework=\"net45\" />\r\n  <package id=\"Oracle.ManagedDataAccess\" version=\"12.2.1100\" targetFramework=\"net45\" />\r\n  <package id=\"Oracle.ManagedDataAccess.EntityFramework\" version=\"12.2.1100\" targetFramework=\"net45\" />\r\n  <package id=\"Swashbuckle\" version=\"5.6.0\" targetFramework=\"net452\" />\r\n  <package id=\"Swashbuckle.Core\" version=\"5.6.0\" targetFramework=\"net452\" />\r\n  <package id=\"Swashbuckle.OData\" version=\"3.4.0\" targetFramework=\"net452\" />\r\n  <package id=\"System.Collections\" version=\"4.3.0\" targetFramework=\"net452\" />\r\n  <package id=\"System.Collections.Concurrent\" version=\"4.3.0\" targetFramework=\"net452\" />\r\n  <package id=\"System.ComponentModel\" version=\"4.3.0\" targetFramework=\"net452\" />\r\n  <package id=\"System.Diagnostics.Debug\" version=\"4.3.0\" targetFramework=\"net452\" />\r\n  <package id=\"System.Globalization\" version=\"4.3.0\" targetFramework=\"net452\" />\r\n  <package id=\"System.Linq\" version=\"4.3.0\" targetFramework=\"net452\" />\r\n  <package id=\"System.Linq.Expressions\" version=\"4.3.0\" targetFramework=\"net452\" />\r\n  <package id=\"System.Reflection\" version=\"4.3.0\" targetFramework=\"net452\" />\r\n  <package id=\"System.Resources.ResourceManager\" version=\"4.3.0\" targetFramework=\"net452\" />\r\n  <package id=\"System.Runtime.Extensions\" version=\"4.3.0\" targetFramework=\"net452\" />\r\n  <package id=\"System.Spatial\" version=\"5.8.3\" targetFramework=\"net452\" />\r\n  <package id=\"System.Threading\" version=\"4.3.0\" targetFramework=\"net452\" />\r\n  <package id=\"System.Threading.Tasks\" version=\"4.3.0\" targetFramework=\"net452\" />\r\n  <package id=\"WebActivatorEx\" version=\"2.2.0\" targetFramework=\"net45\" />\r\n</packages>\r\n```\r\n\r\n"}}
{"actor":{"display_login":"BryanWilhite"}}