-
Notifications
You must be signed in to change notification settings - Fork 29.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[superagent] Fix Blob
error
#58312
[superagent] Fix Blob
error
#58312
Conversation
@alecgibson Thank you for submitting this PR! This is a live comment which I will keep updated. 1 package in this PR
Code ReviewsBecause this is a widely-used package, a DT maintainer will need to review it before it can be merged. You can test the changes of this PR in the Playground. Status
Once every item on this list is checked, I'll ask you for permission to merge and publish the changes. Diagnostic Information: What the bot saw about this PR{
"type": "info",
"now": "-",
"pr_number": 58312,
"author": "alecgibson",
"headCommitOid": "1c53f4bcc24a7472e1c6d1072513d89b664b189b",
"mergeBaseOid": "a997bedc49f992ce9ce9cb1d0d9360004809e48c",
"lastPushDate": "2022-01-20T08:39:28.000Z",
"lastActivityDate": "2022-01-20T08:44:47.000Z",
"hasMergeConflict": false,
"isFirstContribution": false,
"tooManyFiles": false,
"hugeChange": false,
"popularityLevel": "Critical",
"pkgInfo": [
{
"name": "superagent",
"kind": "edit",
"files": [
{
"path": "types/superagent/index.d.ts",
"kind": "definition"
},
{
"path": "types/superagent/superagent-tests.ts",
"kind": "test"
},
{
"path": "types/superagent/tslint.json",
"kind": "package-meta",
"suspect": "not [the expected form](https://github.com/DefinitelyTyped/DefinitelyTyped#user-content-linter-tslintjson) and not moving towards it (check: `rules`)"
}
],
"owners": [
"NicoZelaya",
"mxl",
"paplorinc",
"shreyjain1994",
"zopf",
"beeequeue",
"lukaselmer",
"theQuazz",
"carnesen",
"ghostganz",
"LuckyWindsck"
],
"addedOwners": [],
"deletedOwners": [],
"popularityLevel": "Critical"
}
],
"reviews": [],
"mainBotCommentID": 1016373830,
"ciResult": "pass"
} |
🔔 @NicoZelaya @mxl @paplorinc @shreyjain1994 @zopf @BeeeQueue @lukaselmer @theQuazz @carnesen @ghostganz @LuckyWindsck — please review this PR in the next few days. Be sure to explicitly select |
@alecgibson The CI build failed! Please review the logs for more information. Once you've pushed the fixes, the build will automatically re-run. Thanks! Note: builds which are failing do not end up on the list of PRs for the DT maintainers to review. |
At the moment, some users' builds fail, because `Blob` isn't defined as a global in Node.js - it sits in the [`buffer`][1] package. This change adds an import from `buffer` to fix this issue. Note that I think the build was incorrectly passing before because of a [leaky interface in `stream/consumers`][2]. Note that I've had to disable the linter's `no-outside-dependencies` because of a [known false positive on `buffer`][3]. [1]: https://nodejs.org/api/buffer.html#class-blob [2]: DefinitelyTyped#55311 (comment) [3]: microsoft/dtslint#315
Does anyone smarter than me know why this is failing? I can't get it to fail locally, although I can't help but feel that it has something to do with my own PR 😬 #58270 |
cf2fc8d
to
1c53f4b
Compare
Inspecting the JavaScript source for this package found some properties that are not in the .d.ts files. superagent (unpkg)was missing the following properties:
|
should add |
|
At the moment, some users' builds fail, because `Blob` isn't defined as a global in Node.js - it sits in the [`buffer`][1] package. This change adds an import from `buffer` to fix this issue. Note that I think the build was incorrectly passing before because of a [leaky interface in `stream/consumers`][2]. Note that I've had to disable the linter's `no-outside-dependencies` because of a [known false positive on `buffer`][3]. [1]: https://nodejs.org/api/buffer.html#class-blob [2]: DefinitelyTyped#55311 (comment) [3]: microsoft/dtslint#315
At the moment, some users' builds fail, because
Blob
isn't defined asa global in Node.js - it sits in the
buffer
package.This change adds an import from
buffer
to fix this issue.Note that I think the build was incorrectly passing before because of
a leaky interface in
stream/consumers
.Note that I've had to disable the linter's
no-outside-dependencies
because of a known false positive on
buffer
.Please fill in this template.
npm test <package to test>
.If changing an existing definition: