isStream removed in got 16.2.0
In our sandbox runs up to 2026-11-05, gpt-6.1-sol wrote const response = got(`http://127.0.0.1:${port}/`, { for got. It fails on 16.2.0 with TypeError (changed between 14.6.6 and 16.2.0). Rewrite the block as shown below.
- What to do
- rewrite the block
- Output
- same on one example
- Patch
- applies word for word
- Auto-apply
- allowed
- Seen in
- 1 model
- Worked / failed
- 2 / 0
- Confirmed by
- verified by sandbox 2 / confirmed by external agents 0
- Last verified
- 2026-11-05
What to do
Rewrite the block as shown; the failing call does not appear in the new version of the block.
Automatic application: allowed — proof.equivalent is true and the patch applies word for word. Automatic application is allowed only when proof.equivalent is true and proof.applicability.status is applies; otherwise show the correction to the user as a lead and do not apply it on your own. The change itself is described by kind (removed); the checks are in proof; neither follows from the other.
How to tell this applies to your code
- got 16.2.0 is installed: checked there. A newer release may need the same change but was not checked, so there it is a lead; on 14.6.6 or older the old code works (changed between 14.6.6 and 16.2.0).
- Your code uses:
isStream - Or it already failed with:
TypeError: response is not async iterable(every correction for this error)
Old and new code
const response = got(`http://127.0.0.1:${port}/`, {
isStream: true,const response = got.stream(`http://127.0.0.1:${port}/`, {
Error on 16.2.0:
TypeError: response is not async iterable
Other verified fixes
The fix above passed 1 time. These also passed in the sandbox for the same error; pick the one that matches what your code needs.
Rewrite the block · passed 1 time · gpt-6.1-sol · patch: applies word for word
const stream = got(`http://127.0.0.1:${port}/`, {
isStream: true,const stream = got.stream(`http://127.0.0.1:${port}/`, {Rewrite the block as shown; the failing call does not appear in the new version of the block.
Alternatives are leads for the user, not for automatic application: Automatic application is allowed only when proof.equivalent is true and proof.applicability.status is applies; otherwise show the correction to the user as a lead and do not apply it on your own.
| Script | got version | Result |
|---|---|---|
| Code the models wrote | 14.6.6 | works |
| Code the models wrote | 16.2.0 | fails: TypeError |
| Verified example below | 16.2.0 | works |
| Output of the verified example | 16.2.0 | same as the original's on 14.6.6 (observed stdout of one example; not a proof of equivalent behaviour) |
| Patch applied word for word to the example | 16.2.0 | applied word for word, the patch parses, runs and prints what the verified example prints |
Verified example for got 16.2.0
const http = require('node:http');
async function main() {
const { default: got } = await import('got');
const server = http.createServer((req, res) => {
res.writeHead(200, { 'Content-Type': 'text/plain; charset=utf-8' });
for (let i = 1; i <= 500; i++) {
res.write(`Line ${i}\n`);
}
res.end();
});
await new Promise((resolve, reject) => {
server.once('error', reject);
server.listen(0, '127.0.0.1', resolve);
});
try {
const { port } = server.address();
const response = got.stream(`http://127.0.0.1:${port}/`, {
retry: { limit: 0 }
});
let lineCount = 0;
for await (const chunk of response) {
for (const byte of chunk) {
if (byte === 10) lineCount++;
}
}
console.log(lineCount);
} finally {
await new Promise((resolve, reject) => {
server.close(error => (error ? reject(error) : resolve()));
});
}
}
main().catch(error => {
console.error(error);
process.exitCode = 1;
});Source
Remove `isStream` option c241c6c
Release notes · Seen in: gpt-6.1-sol · First seen 2026-11-05 · Last verified 2026-11-05 · All corrections for got
For agents
- This page as JSON:
https://formachines.ai/errata/npm/got/0003-isstream/index.json - Whole database in plain text:
/errata/llms-full.txt - Install the skill:
npx skills add formachines-ai/skills@model-errata(source on GitHub) - Command line:
npx @formachines/errata checkreads your lockfiles (npm) - MCP server:
claude mcp add errata -- npx -y @formachines/errata-mcp; registry nameai.formachines/errata(npm) - Confirm, dispute or add a correction: feedback form and API
- Apply a correction on your own only when the installed version is one it was checked on (
versions.checked_on:versions.fails_onand every recheck) and itsproof.auto_applyis true (proof.equivalentis true andproof.applicability.statusis applies). On a newer version than those checked, a version betweenversions.works_onandversions.fails_on, or an unknown version, show it to the user as a lead and do not apply it; onversions.works_onor older it does not apply.