Commit 67283f3
committed
fix(connector): classify GraphQL responses on the App-token path
newGitHubAppClients shared one unwrapped HTTP client for REST and GraphQL,
so the GraphQL client lost the statusClassifyingTransport that
newGitHubGraphqlClient applies. Without it, shurcooL/githubv4 surfaces
429/5xx as opaque strings that reach the SDK as codes.Unknown and abort the
sync instead of being retried.
Wrap the GraphQL client's transport with statusClassifyingTransport, layered
above tokenRefreshTransport so a 401 is still observed and retried before any
surviving non-2xx is converted to a classified error. REST is unchanged
(go-github classifies via wrapGitHubError).1 parent e5383ef commit 67283f3
1 file changed
Lines changed: 16 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
132 | 132 | | |
133 | 133 | | |
134 | 134 | | |
| 135 | + | |
| 136 | + | |
| 137 | + | |
| 138 | + | |
| 139 | + | |
| 140 | + | |
| 141 | + | |
| 142 | + | |
| 143 | + | |
135 | 144 | | |
136 | 145 | | |
137 | 146 | | |
| |||
144 | 153 | | |
145 | 154 | | |
146 | 155 | | |
| 156 | + | |
| 157 | + | |
| 158 | + | |
| 159 | + | |
| 160 | + | |
147 | 161 | | |
148 | 162 | | |
149 | 163 | | |
150 | 164 | | |
151 | 165 | | |
152 | 166 | | |
153 | 167 | | |
154 | | - | |
| 168 | + | |
155 | 169 | | |
156 | | - | |
| 170 | + | |
157 | 171 | | |
158 | 172 | | |
159 | 173 | | |
0 commit comments