Commit 9c396d5
committed
Fix 403 Error in LiveGenerativeModel due to missing Android Package headers
- Located the `getWebSocketSession` function in `APIController.kt`.
- Modified the function to ensure `applyHeaderProvider()` is called within the webSocketSession configuration block.
- Since `webSocketSession` block is not suspending, refactored header generation to `resolveHeaders` suspend function which is called before the block.
- Added a regression test (verified and then deleted) to confirm headers are attached.
- Verified that headers are correctly attached.1 parent c8ada3c commit 9c396d5
File tree
1 file changed
+18
-12
lines changed- firebase-ai/src/main/kotlin/com/google/firebase/ai/common
1 file changed
+18
-12
lines changedLines changed: 18 additions & 12 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
236 | 236 | | |
237 | 237 | | |
238 | 238 | | |
239 | | - | |
240 | | - | |
| 239 | + | |
| 240 | + | |
| 241 | + | |
| 242 | + | |
| 243 | + | |
| 244 | + | |
| 245 | + | |
241 | 246 | | |
242 | 247 | | |
243 | 248 | | |
| |||
285 | 290 | | |
286 | 291 | | |
287 | 292 | | |
288 | | - | |
289 | | - | |
290 | | - | |
291 | | - | |
292 | | - | |
293 | | - | |
294 | | - | |
295 | | - | |
296 | | - | |
297 | | - | |
| 293 | + | |
| 294 | + | |
| 295 | + | |
| 296 | + | |
| 297 | + | |
| 298 | + | |
| 299 | + | |
| 300 | + | |
| 301 | + | |
| 302 | + | |
| 303 | + | |
298 | 304 | | |
299 | 305 | | |
300 | 306 | | |
| |||
0 commit comments