Limits
Time, memory, CPU, network and storage limits, and what happens past them.
Extensions shouldn't slow down Adanotch or the Mac. Each one runs in its own process, and Adanotch watches that process.
Running
| Limit | Value | Past it |
|---|---|---|
| One synchronous turn | 200 ms | The process is ended and restarted (a strike) |
| Memory | 64 MB | The process is ended (a strike) |
| CPU | 50% on average over 10 seconds | The process is ended (a strike) |
An update error | — | A strike |
A setup or load error | — | The extension stops at once |
Three strikes in a row stop the extension; Settings › Extensions shows why, and you can turn it back on there. Every successful update resets the count. The wait between restarts doubles with each strike.
200 ms is one turn, not the whole update
Every await ends the turn. Waiting on the network doesn't use up the limit; going through a huge array in one go does. Split heavy work into chunks and give way in between with await new Promise((r) => setTimeout(r, 0)).
async function sumInChunks(values: number[]) {
let total = 0;
for (let i = 0; i < values.length; i += 10_000) {
for (const v of values.slice(i, i + 10_000)) total += v;
await new Promise((resolve) => setTimeout(resolve, 0));
}
return total;
}Network
| Limit | Value |
|---|---|
| Protocol | HTTPS only, network: domains only |
| Requests at once | 6 |
| Requests a minute | 120 |
| Response size | 5 MB |
| Request body | 1 MB |
| Timeout | 15 s by default; 1–60 s with timeout |
There are no cookies and no cache. Going past a limit rejects with NetworkError, TimeoutError or PermissionError.
Other
| Limit | Value |
|---|---|
| View | 2000 nodes at most, 32 levels deep |
chart | 500 values at most |
| Storage | 512 KB per extension (JSON) |
| Timers | 200 at once; setInterval every 50 ms at the fastest |
console | 200 lines per 10 s, 2000 characters a line |
Island activities (island.show) | 8 at once |
| Clipboard writes | 1 MB |
open(url) | https: and mailto: only, within 10 s of the user using one of your controls |
Bundle (dist/index.js) | 4 MB |
What isn't there
There is no DOM, window, document, require, process, file system or Node API. npm libraries you bundle must not depend on them. See Web APIs for what is there.