Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .yarnrc.yml
Original file line number Diff line number Diff line change
@@ -1,2 +1,5 @@
nodeLinker: node-modules
npmMinimalAgeGate: 5d
# Packages maintained by Reviewable, exempt from the age gate.
npmPreapprovedPackages:
- firebase-childrenkeys
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "nodefire",
"version": "4.1.0",
"version": "5.0.0",
"description": "A promise-centric Firebase library for NodeJS",
"main": "built/index.js",
"types": "built/index.d.ts",
Expand Down Expand Up @@ -33,7 +33,7 @@
"homepage": "https://github.com/Reviewable/nodefire",
"dependencies": {
"firebase-admin": "10.x || 11.x || 12.x || 13.x",
"firebase-childrenkeys": "^2.3.5",
"firebase-childrenkeys": "^3.0.0",

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Regenerate lockfile for the firebase-childrenkeys upgrade

After bumping firebase-childrenkeys to ^3.0.0, the lockfile was not updated and still resolves only firebase-childrenkeys@npm:^2.3.5 (to 2.6.2). In Yarn 4, CI installs commonly run with immutable lockfiles, so this mismatch can either fail installs (--immutable / default-on-CI behavior) or keep testing against the old dependency version, meaning this PR does not reliably deliver the intended v3 migration.

Useful? React with 👍 / 👎.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, I'm waiting for firebase-childrenkeys 3.0.0 to be released, then I'll update the PR.

"firefight": "1.x",
"lodash": "^4.17.21",
"lru-cache": "11.x",
Expand Down
6 changes: 1 addition & 5 deletions src/nodefire.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ import _ from 'lodash';
import {LRUCache} from 'lru-cache';
import firebaseChildrenKeys from 'firebase-childrenkeys';
import {Simulator} from 'firefight';
import {Agent} from 'http';

export type InterceptOperationsCallback = (
op: {ref: NodeFire, method: string, args: any[]},
Expand Down Expand Up @@ -605,12 +604,9 @@ export default class NodeFire<
* - maxTries: the maximum number of times to try to fetch the keys, in case of transient
* errors (defaults to 1)
* - retryInterval: the number of milliseconds to delay between retries (defaults to 1000)
* - agent: http.Agent
* @return {Promise<string[]>} A promise that resolves to an array of key strings.
*/
childrenKeys(options: {
maxTries?: number, retryInterval?: number, agent?: Agent
}): Promise<string[]> {
childrenKeys(options: {maxTries?: number, retryInterval?: number}): Promise<string[]> {
return this.$ref.ref.childrenKeys ?
this.$ref.ref.childrenKeys(options) :
firebaseChildrenKeys(this.$ref, options);
Expand Down
54 changes: 6 additions & 48 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -1034,17 +1034,6 @@ __metadata:
languageName: node
linkType: hard

"axios@npm:^1.2.1":
version: 1.14.0
resolution: "axios@npm:1.14.0"
dependencies:
follow-redirects: "npm:^1.15.11"
form-data: "npm:^4.0.5"
proxy-from-env: "npm:^2.1.0"
checksum: 10c0/2541f4aa215a7d1842429dad006fc682d82bc0e74bd14500823f7d8cce3bbae0e0a8c328c8538946718f366ab8ce5a4c12e9ad40e5a0f3482ff8bff0cd115d45
languageName: node
linkType: hard

"balanced-match@npm:^1.0.0":
version: 1.0.2
resolution: "balanced-match@npm:1.0.2"
Expand Down Expand Up @@ -1851,15 +1840,14 @@ __metadata:
languageName: node
linkType: hard

"firebase-childrenkeys@npm:^2.3.5":
version: 2.6.2
resolution: "firebase-childrenkeys@npm:2.6.2"
"firebase-childrenkeys@npm:^3.0.0":
version: 3.0.0
resolution: "firebase-childrenkeys@npm:3.0.0"
dependencies:
axios: "npm:^1.2.1"
sleep-promise: "npm:^9.1.0"
peerDependencies:
firebase-admin: 5.x || 6.x || 7.x || 8.x || 9.x || 10.x || 11.x || 12.x || 13.x
checksum: 10c0/a896c3a522d5a0965e8117dfdd5c65d7d92e2aa6489ebb6d62bfa61acea81db58f242e2ec8cc8a781863e9e8973d7433db671f73fdcb0606dbe256173f29b542
checksum: 10c0/d8690a8277670226728ac96ff7e75a2720fcc556c2ae1dc028c9dfe1c98626d8ccd42242aedbe5369d804996d54f292cbe9ac5980c44b1bac1d3fc3b618fb477
languageName: node
linkType: hard

Expand Down Expand Up @@ -1908,16 +1896,6 @@ __metadata:
languageName: node
linkType: hard

"follow-redirects@npm:^1.15.11":
version: 1.15.11
resolution: "follow-redirects@npm:1.15.11"
peerDependenciesMeta:
debug:
optional: true
checksum: 10c0/d301f430542520a54058d4aeeb453233c564aaccac835d29d15e050beb33f339ad67d9bddbce01739c5dc46a6716dbe3d9d0d5134b1ca203effa11a7ef092343
languageName: node
linkType: hard

"for-each@npm:^0.3.3, for-each@npm:^0.3.5":
version: 0.3.5
resolution: "for-each@npm:0.3.5"
Expand All @@ -1941,19 +1919,6 @@ __metadata:
languageName: node
linkType: hard

"form-data@npm:^4.0.5":
version: 4.0.5
resolution: "form-data@npm:4.0.5"
dependencies:
asynckit: "npm:^0.4.0"
combined-stream: "npm:^1.0.8"
es-set-tostringtag: "npm:^2.1.0"
hasown: "npm:^2.0.2"
mime-types: "npm:^2.1.12"
checksum: 10c0/dd6b767ee0bbd6d84039db12a0fa5a2028160ffbfaba1800695713b46ae974a5f6e08b3356c3195137f8530dcd9dfcb5d5ae1eeff53d0db1e5aad863b619ce3b
languageName: node
linkType: hard

"formdata-polyfill@npm:^4.0.10":
version: 4.0.10
resolution: "formdata-polyfill@npm:4.0.10"
Expand Down Expand Up @@ -2898,7 +2863,7 @@ __metadata:
languageName: node
linkType: hard

"mime-types@npm:^2.1.12, mime-types@npm:^2.1.35":
"mime-types@npm:^2.1.35":
version: 2.1.35
resolution: "mime-types@npm:2.1.35"
dependencies:
Expand Down Expand Up @@ -3010,7 +2975,7 @@ __metadata:
"@types/lodash": "npm:^4.14.191"
"@types/safe-timers": "npm:^1.1.0"
firebase-admin: "npm:10.x || 11.x || 12.x || 13.x"
firebase-childrenkeys: "npm:^2.3.5"
firebase-childrenkeys: "npm:^3.0.0"
firefight: "npm:1.x"
lodash: "npm:^4.17.21"
lru-cache: "npm:11.x"
Expand Down Expand Up @@ -3240,13 +3205,6 @@ __metadata:
languageName: node
linkType: hard

"proxy-from-env@npm:^2.1.0":
version: 2.1.0
resolution: "proxy-from-env@npm:2.1.0"
checksum: 10c0/ed01729fd4d094eab619cd7e17ce3698b3413b31eb102c4904f9875e677cd207392795d5b4adee9cec359dfd31c44d5ad7595a3a3ad51c40250e141512281c58
languageName: node
linkType: hard

"punycode@npm:^2.1.0":
version: 2.3.1
resolution: "punycode@npm:2.3.1"
Expand Down