Repository navigation
Commit f5cd428
committed
docs(golang): say why the auth guest's block_on is wasm32-only
On native targets stack-auth now spawns a token refresh onto the current
Tokio runtime. futures::executor::block_on provides none, so token and
refresh in the auth guest would panic on the first refresh in a native
build. Today only the wasm32 abi exports reach them, where stack-auth
refreshes inline and block_on is sound.
A cfg(target_arch = "wasm32") gate would leave their helpers dead on the
native test build, so record the constraint where block_on is imported
instead, before a native test finds the panic by accident.1 parent 6503f06 commit f5cd428
1 file changed
Lines changed: 7 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
6 | 6 | | |
7 | 7 | | |
8 | 8 | | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
9 | 16 | | |
10 | 17 | | |
11 | 18 | | |
| |||
0 commit comments