{"action":"created","issue":{"url":"https://api.github.com/repos/2020IP/TwentyTwenty.IdentityServer4.EntityFrameworkCore/issues/7","repository_url":"https://api.github.com/repos/2020IP/TwentyTwenty.IdentityServer4.EntityFrameworkCore","labels_url":"https://api.github.com/repos/2020IP/TwentyTwenty.IdentityServer4.EntityFrameworkCore/issues/7/labels{/name}","comments_url":"https://api.github.com/repos/2020IP/TwentyTwenty.IdentityServer4.EntityFrameworkCore/issues/7/comments","events_url":"https://api.github.com/repos/2020IP/TwentyTwenty.IdentityServer4.EntityFrameworkCore/issues/7/events","html_url":"https://github.com/2020IP/TwentyTwenty.IdentityServer4.EntityFrameworkCore/issues/7","id":148248940,"number":7,"title":"code flow with EntityFramework core Error","user":{"login":"AllenMaz","id":16220839,"avatar_url":"https://avatars.githubusercontent.com/u/16220839?v=3","gravatar_id":"","url":"https://api.github.com/users/AllenMaz","html_url":"https://github.com/AllenMaz","followers_url":"https://api.github.com/users/AllenMaz/followers","following_url":"https://api.github.com/users/AllenMaz/following{/other_user}","gists_url":"https://api.github.com/users/AllenMaz/gists{/gist_id}","starred_url":"https://api.github.com/users/AllenMaz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/AllenMaz/subscriptions","organizations_url":"https://api.github.com/users/AllenMaz/orgs","repos_url":"https://api.github.com/users/AllenMaz/repos","events_url":"https://api.github.com/users/AllenMaz/events{/privacy}","received_events_url":"https://api.github.com/users/AllenMaz/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":9,"created_at":"2016-04-14T04:23:37Z","updated_at":"2016-06-02T21:32:55Z","closed_at":"2016-04-15T19:03:04Z","body":"I use EF Core as my clients and scopes datasource,but when i test code flow ,i got an error:\r\n\r\nAn unhandled exception occurred while processing the request.\r\nSqlException: Invalid object name 'Tokens'.\r\n\r\nit's my logging:\r\n\r\n2016-04-14 12:16:38.134 +08:00 [Information] Start authorize request protocol validation\r\n\r\n\r\n2016-04-14 12:16:40.096 +08:00 [Information] \"Authorize request validation success\"\r\n \"{\r\n  \\\"ClientId\\\": \\\"padmate_AuthorizationCode\\\",\r\n  \\\"ClientName\\\": \\\"Authorization Code\\\",\r\n  \\\"RedirectUri\\\": \\\"http://localhost:27898/Home/CallBack\\\",\r\n  \\\"AllowedRedirectUris\\\": [\r\n    \\\"http://localhost:27898/Home/CallBack\\\"\r\n  ],\r\n  \\\"SubjectId\\\": \\\"5d8db2b4-bd97-47d1-ba97-d9ae354ca88a\\\",\r\n  \\\"ResponseType\\\": \\\"code\\\",\r\n  \\\"ResponseMode\\\": \\\"query\\\",\r\n  \\\"Flow\\\": \\\"AuthorizationCode\\\",\r\n  \\\"RequestedScopes\\\": \\\"dpcontrolapiscope\\\",\r\n  \\\"State\\\": \\\"SrMLHyDfJskutdQQesMJGwNpPXngeJ+CbOiuxbY+dlKuJMydfzw68AHUp+oYUwZLkfBkITnypz2Urt9ijv8yzw==\\\",\r\n  \\\"Nonce\\\": \\\"ddDtY5E+0mNlRo+lsnCVglzLUVt1dFhiN0nFXkqzH0GG+eEA+jJ08X4ETS+/JDMBbWFQgKMvXlxLEP9n9XhlcA==\\\",\r\n  \\\"SessionId\\\": \\\"7a7fc757e20b055a2a9d047bc9d16861\\\",\r\n  \\\"Raw\\\": {\r\n    \\\"client_id\\\": \\\"padmate_AuthorizationCode\\\",\r\n    \\\"response_type\\\": \\\"code\\\",\r\n    \\\"scope\\\": \\\"dpcontrolapiscope\\\",\r\n    \\\"redirect_uri\\\": \\\"http://localhost:27898/Home/CallBack\\\",\r\n    \\\"state\\\": \\\"SrMLHyDfJskutdQQesMJGwNpPXngeJ+CbOiuxbY+dlKuJMydfzw68AHUp+oYUwZLkfBkITnypz2Urt9ijv8yzw==\\\",\r\n    \\\"nonce\\\": \\\"ddDtY5E+0mNlRo+lsnCVglzLUVt1dFhiN0nFXkqzH0GG+eEA+jJ08X4ETS+/JDMBbWFQgKMvXlxLEP9n9XhlcA==\\\"\r\n  }\r\n}\"\r\n\r\n\r\n2016-04-14 12:16:40.111 +08:00 [Information] Issuing successful authorization response\r\n\r\n\r\n2016-04-14 12:16:40.117 +08:00 [Information] Creating Authorization Code Flow response.\r\n\r\n\r\n2016-04-14 12:16:40.249 +08:00 [Error] An unhandled exception has occurred while executing the request\r\nMicrosoft.Data.Entity.DbUpdateException: An error occurred while updating the entries. See the inner exception for details. ---> System.Data.SqlClient.SqlException: Invalid object name 'Tokens'.\r\n   在 System.Data.SqlClient.SqlCommand.<>c.<ExecuteDbDataReaderAsync>b__167_0(Task`1 result)\r\n   在 System.Threading.Tasks.ContinuationResultTaskFromResultTask`2.InnerInvoke()\r\n   在 System.Threading.Tasks.Task.Execute()\r\n--- 引发异常的上一位置中堆栈跟踪的末尾 ---\r\n   在 System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)\r\n   在 System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   在 System.Runtime.CompilerServices.TaskAwaiter`1.GetResult()\r\n   在 Microsoft.Data.Entity.Storage.Internal.RelationalCommand.<>c__DisplayClass18_0.<<ExecuteReaderAsync>b__0>d.MoveNext()\r\n--- 引发异常的上一位置中堆栈跟踪的末尾 ---\r\n   在 System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)\r\n   在 System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   在 System.Runtime.CompilerServices.TaskAwaiter`1.GetResult()\r\n   在 Microsoft.Data.Entity.Storage.Internal.RelationalCommand.<ExecuteAsync>d__20`1.MoveNext()\r\n--- 引发异常的上一位置中堆栈跟踪的末尾 ---\r\n   在 System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)\r\n   在 System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   在 System.Runtime.CompilerServices.TaskAwaiter`1.GetResult()\r\n   在 Microsoft.Data.Entity.Storage.Internal.RelationalCommand.<ExecuteReaderAsync>d__18.MoveNext()\r\n--- 引发异常的上一位置中堆栈跟踪的末尾 ---\r\n   在 System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)\r\n   在 System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   在 System.Runtime.CompilerServices.TaskAwaiter`1.GetResult()\r\n   在 Microsoft.Data.Entity.Update.ReaderModificationCommandBatch.<ExecuteAsync>d__28.MoveNext()\r\n   --- 内部异常堆栈跟踪的结尾 ---\r\n   在 Microsoft.Data.Entity.Update.ReaderModificationCommandBatch.<ExecuteAsync>d__28.MoveNext()\r\n--- 引发异常的上一位置中堆栈跟踪的末尾 ---\r\n   在 System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)\r\n   在 System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   在 System.Runtime.CompilerServices.TaskAwaiter.GetResult()\r\n   在 Microsoft.Data.Entity.Update.Internal.BatchExecutor.<ExecuteAsync>d__1.MoveNext()\r\n--- 引发异常的上一位置中堆栈跟踪的末尾 ---\r\n   在 System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)\r\n   在 System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   在 System.Runtime.CompilerServices.TaskAwaiter`1.GetResult()\r\n   在 Microsoft.Data.Entity.ChangeTracking.Internal.StateManager.<SaveChangesAsync>d__32.MoveNext()\r\n--- 引发异常的上一位置中堆栈跟踪的末尾 ---\r\n   在 System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)\r\n   在 System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   在 System.Runtime.CompilerServices.TaskAwaiter`1.GetResult()\r\n   在 Microsoft.Data.Entity.DbContext.<SaveChangesAsync>d__28.MoveNext()\r\n--- 引发异常的上一位置中堆栈跟踪的末尾 ---\r\n   在 System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)\r\n   在 System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   在 System.Runtime.CompilerServices.TaskAwaiter`1.GetResult()\r\n   在 TwentyTwenty.IdentityServer4.EntityFramework7.Stores.AuthorizationCodeStore.<StoreAsync>d__1.MoveNext()\r\n--- 引发异常的上一位置中堆栈跟踪的末尾 ---\r\n   在 System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)\r\n   在 System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   在 System.Runtime.CompilerServices.TaskAwaiter.GetResult()\r\n   在 IdentityServer4.Core.ResponseHandling.AuthorizeResponseGenerator.<CreateCodeAsync>d__8.MoveNext()\r\n--- 引发异常的上一位置中堆栈跟踪的末尾 ---\r\n   在 System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)\r\n   在 System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   在 System.Runtime.CompilerServices.TaskAwaiter`1.GetResult()\r\n   在 IdentityServer4.Core.ResponseHandling.AuthorizeResponseGenerator.<CreateCodeFlowResponseAsync>d__7.MoveNext()\r\n--- 引发异常的上一位置中堆栈跟踪的末尾 ---\r\n   在 System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)\r\n   在 System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   在 System.Runtime.CompilerServices.TaskAwaiter`1.GetResult()\r\n   在 IdentityServer4.Core.ResponseHandling.AuthorizeResponseGenerator.<CreateResponseAsync>d__5.MoveNext()\r\n--- 引发异常的上一位置中堆栈跟踪的末尾 ---\r\n   在 System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)\r\n   在 System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   在 System.Runtime.CompilerServices.TaskAwaiter`1.GetResult()\r\n   在 IdentityServer4.Core.Endpoints.Results.AuthorizeEndpointResultFactory.<CreateAuthorizeResultAsync>d__12.MoveNext()\r\n--- 引发异常的上一位置中堆栈跟踪的末尾 ---\r\n   在 System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)\r\n   在 System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   在 System.Runtime.CompilerServices.TaskAwaiter`1.GetResult()\r\n   在 IdentityServer4.Core.Endpoints.AuthorizeEndpoint.<SuccessfulAuthorizationAsync>d__16.MoveNext()\r\n--- 引发异常的上一位置中堆栈跟踪的末尾 ---\r\n   在 System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)\r\n   在 System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   在 System.Runtime.CompilerServices.TaskAwaiter`1.GetResult()\r\n   在 IdentityServer4.Core.Endpoints.AuthorizeEndpoint.<ProcessAuthorizeRequestAsync>d__13.MoveNext()\r\n--- 引发异常的上一位置中堆栈跟踪的末尾 ---\r\n   在 System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)\r\n   在 System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   在 System.Runtime.CompilerServices.TaskAwaiter`1.GetResult()\r\n   在 IdentityServer4.Core.Endpoints.AuthorizeEndpoint.<ProcessAuthorizeAsync>d__10.MoveNext()\r\n--- 引发异常的上一位置中堆栈跟踪的末尾 ---\r\n   在 System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)\r\n   在 System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   在 System.Runtime.CompilerServices.TaskAwaiter`1.GetResult()\r\n   在 IdentityServer4.Core.Endpoints.AuthorizeEndpoint.<ProcessAsync>d__9.MoveNext()\r\n--- 引发异常的上一位置中堆栈跟踪的末尾 ---\r\n   在 System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)\r\n   在 System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   在 System.Runtime.CompilerServices.TaskAwaiter`1.GetResult()\r\n   在 IdentityServer4.Core.Hosting.IdentityServerMiddleware.<Invoke>d__3.MoveNext()\r\n--- 引发异常的上一位置中堆栈跟踪的末尾 ---\r\n   在 System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)\r\n   在 System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   在 System.Runtime.CompilerServices.TaskAwaiter.GetResult()\r\n   在 IdentityServer4.Core.Hosting.BaseUrlMiddleware.<Invoke>d__2.MoveNext()\r\n--- 引发异常的上一位置中堆栈跟踪的末尾 ---\r\n   在 System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)\r\n   在 System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   在 System.Runtime.CompilerServices.TaskAwaiter.GetResult()\r\n   在 Microsoft.AspNet.Authentication.AuthenticationMiddleware`1.<Invoke>d__18.MoveNext()\r\n--- 引发异常的上一位置中堆栈跟踪的末尾 ---\r\n   在 System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n   在 Microsoft.AspNet.Authentication.AuthenticationMiddleware`1.<Invoke>d__18.MoveNext()\r\n--- 引发异常的上一位置中堆栈跟踪的末尾 ---\r\n   在 System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)\r\n   在 System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   在 System.Runtime.CompilerServices.TaskAwaiter.GetResult()\r\n   在 Microsoft.AspNet.Cors.Infrastructure.CorsMiddleware.<Invoke>d__7.MoveNext()\r\n--- 引发异常的上一位置中堆栈跟踪的末尾 ---\r\n   在 System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)\r\n   在 System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   在 System.Runtime.CompilerServices.TaskAwaiter.GetResult()\r\n   在 Microsoft.AspNet.IISPlatformHandler.IISPlatformHandlerMiddleware.<Invoke>d__8.MoveNext()\r\n--- 引发异常的上一位置中堆栈跟踪的末尾 ---\r\n   在 System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)\r\n   在 System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n   在 System.Runtime.CompilerServices.TaskAwaiter.GetResult()\r\n   在 Microsoft.AspNet.Diagnostics.DeveloperExceptionPageMiddleware.<Invoke>d__7.MoveNext()\r\n\r\n\r\n2016-04-14 12:16:40.364 +08:00 [Information] Request finished in 0.2437ms 500 text/html; charset=utf-8\r\n"},"comment":{"url":"https://api.github.com/repos/2020IP/TwentyTwenty.IdentityServer4.EntityFrameworkCore/issues/comments/223429294","html_url":"https://github.com/2020IP/TwentyTwenty.IdentityServer4.EntityFrameworkCore/issues/7#issuecomment-223429294","issue_url":"https://api.github.com/repos/2020IP/TwentyTwenty.IdentityServer4.EntityFrameworkCore/issues/7","id":223429294,"user":{"login":"nwolke","id":4672812,"avatar_url":"https://avatars.githubusercontent.com/u/4672812?v=3","gravatar_id":"","url":"https://api.github.com/users/nwolke","html_url":"https://github.com/nwolke","followers_url":"https://api.github.com/users/nwolke/followers","following_url":"https://api.github.com/users/nwolke/following{/other_user}","gists_url":"https://api.github.com/users/nwolke/gists{/gist_id}","starred_url":"https://api.github.com/users/nwolke/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nwolke/subscriptions","organizations_url":"https://api.github.com/users/nwolke/orgs","repos_url":"https://api.github.com/users/nwolke/repos","events_url":"https://api.github.com/users/nwolke/events{/privacy}","received_events_url":"https://api.github.com/users/nwolke/received_events","type":"User","site_admin":false},"created_at":"2016-06-02T21:32:55Z","updated_at":"2016-06-02T21:32:55Z","body":"I'd like to follow up my previous comment by saying that migrating to RC2 and pulling the latest of this project has actually fixed this issue. I can now properly find and create migrations using those contexts. thanks!"}}
{"actor":{"display_login":"nwolke"}}