@dasasian/firebase-structured-logger 0.9.0 → 1.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (48) hide show
  1. package/README.md +135 -32
  2. package/dist/client/index.d.ts +1 -1
  3. package/dist/client/index.d.ts.map +1 -1
  4. package/dist/client/index.js +2 -1
  5. package/dist/client/index.js.map +1 -1
  6. package/dist/client/logger.d.ts +6 -2
  7. package/dist/client/logger.d.ts.map +1 -1
  8. package/dist/client/logger.js +16 -7
  9. package/dist/client/logger.js.map +1 -1
  10. package/dist/client/rateLimiter.d.ts +12 -5
  11. package/dist/client/rateLimiter.d.ts.map +1 -1
  12. package/dist/client/rateLimiter.js +61 -12
  13. package/dist/client/rateLimiter.js.map +1 -1
  14. package/dist/functions/httpHandler.d.ts +1 -1
  15. package/dist/functions/httpHandler.js +1 -1
  16. package/dist/functions/index.d.ts +1 -1
  17. package/dist/functions/index.d.ts.map +1 -1
  18. package/dist/functions/logHandler.d.ts +10 -5
  19. package/dist/functions/logHandler.d.ts.map +1 -1
  20. package/dist/functions/logHandler.js +16 -5
  21. package/dist/functions/logHandler.js.map +1 -1
  22. package/dist/functions/logger.js +1 -1
  23. package/dist/functions/logger.js.map +1 -1
  24. package/dist/functions/sourceMapCache.js +1 -1
  25. package/dist/functions/sourceMapCache.js.map +1 -1
  26. package/dist/shared/deprecate.d.ts +4 -0
  27. package/dist/shared/deprecate.d.ts.map +1 -0
  28. package/dist/shared/deprecate.js +30 -0
  29. package/dist/shared/deprecate.js.map +1 -0
  30. package/dist/shared/nodeModules.d.ts +39 -0
  31. package/dist/shared/nodeModules.d.ts.map +1 -0
  32. package/dist/shared/nodeModules.js +120 -0
  33. package/dist/shared/nodeModules.js.map +1 -0
  34. package/dist/shared/versionRange.d.ts +17 -0
  35. package/dist/shared/versionRange.d.ts.map +1 -0
  36. package/dist/shared/versionRange.js +48 -0
  37. package/dist/shared/versionRange.js.map +1 -0
  38. package/dist/tools/doctor.d.ts +54 -0
  39. package/dist/tools/doctor.d.ts.map +1 -0
  40. package/dist/tools/doctor.js +381 -0
  41. package/dist/tools/doctor.js.map +1 -0
  42. package/dist/tools/index.js +34 -5
  43. package/dist/tools/index.js.map +1 -1
  44. package/dist/tools/uploadSourceMaps.d.ts +7 -0
  45. package/dist/tools/uploadSourceMaps.d.ts.map +1 -1
  46. package/dist/tools/uploadSourceMaps.js.map +1 -1
  47. package/package.json +11 -11
  48. package/skills/query-logs/SKILL.md +14 -0
package/README.md CHANGED
@@ -70,7 +70,19 @@ cd functions && npm install @dasasian/firebase-structured-logger
70
70
  npm install @dasasian/firebase-structured-logger
71
71
  ```
72
72
 
73
- Ships ESM with three entry points — `/client`, `/functions`, `/tools` — plus the `fsl` CLI. `firebase`, `firebase-admin`, and `firebase-functions` are optional peer dependencies (bring your own versions). None of them is needed to load the package; each only switches on the part that uses it — see [Without Firebase](#without-firebase).
73
+ Ships CommonJS with TypeScript types — works from `require` and from `import`, in Node and in any bundler — with three entry points, `/client`, `/functions` and `/tools`, plus the `fsl` CLI. `firebase`, `firebase-admin`, and `firebase-functions` are optional peer dependencies (bring your own versions). None of them is needed to load the package; each only switches on the part that uses it — see [Without Firebase](#without-firebase).
74
+
75
+ Installing next to **firebase-admin 13** in one command can leave two copies of
76
+ `@google-cloud/storage` (8 for this package, 7 for firebase-admin). Both work; run
77
+ `npm dedupe` once and npm keeps the one they share. firebase-admin 14.5 and later use
78
+ the same Storage as this package, so there is nothing to do.
79
+
80
+ ### Upgrading from 0.x
81
+
82
+ Nothing breaks. Eight names were renamed for the 1.0 API — `minLogLevel` became
83
+ `minSeverity`, `bucketName` became `bucket`, and so on — and each old name still works in
84
+ 1.x, with a one-time console warning naming its replacement. They are removed in 2.0.
85
+ The full list is in [Renamed in 1.0](#client). Run `npx fsl doctor` after upgrading.
74
86
 
75
87
  ## Setup
76
88
 
@@ -113,7 +125,7 @@ import { initLogger, createClientLogFunction } from '@dasasian/firebase-structur
113
125
  initLogger({ appId: 'my-app' })
114
126
 
115
127
  export const logFrontendEvent = createClientLogFunction({
116
- bucketName: 'my-app.firebasestorage.app', // holds source maps AND attachments
128
+ bucket: 'my-app.firebasestorage.app', // holds source maps AND attachments
117
129
  })
118
130
  ```
119
131
 
@@ -126,13 +138,13 @@ gs://my-app.firebasestorage.app/logAttachments/{logId}/{name}
126
138
 
127
139
  Both the bucket and the prefix can be changed per half — see [Source maps](#source-maps)
128
140
  for `sourceMaps: { bucket, prefix }`, and [Attachments](#attachments) for
129
- `configureAttachments({ bucket, prefix })`. Omit `bucketName` entirely and both fall back
141
+ `configureAttachments({ bucket, prefix })`. Omit `bucket` entirely and both fall back
130
142
  to your project's default bucket.
131
143
 
132
144
  **3. Wire the deploy script** — upload source maps and strip them from the hosting bundle as part of deploy. Merge into your root `package.json` scripts, keeping any existing flags like `--project`:
133
145
 
134
146
  ```json
135
- "deploy": "export VITE_RELEASE_ID=$(git rev-parse --short HEAD) && npm run build && npx fsl upload-sourcemaps --functions=./functions --embed-sourcemaps && firebase deploy"
147
+ "deploy": "export VITE_RELEASE_ID=$(git rev-parse --short HEAD) && npm run build && npx fsl upload-sourcemaps --backend=./functions --embed-sourcemaps && firebase deploy"
136
148
  ```
137
149
 
138
150
  `fsl upload-sourcemaps` reads the bucket from `VITE_FIREBASE_STORAGE_BUCKET` (or `FIREBASE_STORAGE_BUCKET`) after loading `.env.local`. It uploads source maps to Cloud Storage, embeds a copy in `functions/sourcemaps/current/` for fast lookup, and deletes them from `dist/` so they are **not** served to browsers.
@@ -142,9 +154,9 @@ to your project's default bucket.
142
154
  **4. Verify it works** — prove the round trip before you trust it:
143
155
 
144
156
  ```ts
145
- import { triggerTestLog } from '@dasasian/firebase-structured-logger/client'
157
+ import { sendTestLog } from '@dasasian/firebase-structured-logger/client'
146
158
 
147
- triggerTestLog() // wire to a dev-only button; sends one error, one warning, one info
159
+ sendTestLog() // wire to a dev-only button; sends one error, one warning, one info
148
160
  ```
149
161
 
150
162
  Look for `labels.errorType="fsl-verify"` — in Cloud Logging once deployed, or in `dev.jsonl`
@@ -215,7 +227,7 @@ const app = express()
215
227
  app.use(express.json({ limit: '10mb' })) // attachments ride in the body
216
228
 
217
229
  app.post('/log', createHttpLogHandler({
218
- bucketName: 'my-app.firebasestorage.app', // holds source maps AND attachments
230
+ bucket: 'my-app.firebasestorage.app', // holds source maps AND attachments
219
231
  authorize: async (req) => {
220
232
  const header = String(req.headers.authorization ?? '')
221
233
  if (!header.startsWith('Bearer ')) return false
@@ -286,7 +298,7 @@ Nothing here needs a Firebase project — only a Google Cloud one. What changes:
286
298
  whatever credential your app already uses.
287
299
  - **`authorize`** checks your own session instead of a Firebase ID token — for example
288
300
  `authorize: (req) => sessions.isValid(req.headers.cookie)`.
289
- - **Storage** has no Firebase default bucket to fall back to. Name one with `bucketName`
301
+ - **Storage** has no Firebase default bucket to fall back to. Name one with `bucket`
290
302
  (it holds source maps and attachments), and give the service's account access to it.
291
303
  Or name none: embedded maps still resolve the current release, older releases stay
292
304
  minified, and attachments are dropped — the log says so once.
@@ -328,7 +340,7 @@ A gate that throws counts as a rejection, not an opening.
328
340
  the trace id is still written, but does not join the platform's request log.
329
341
  - **No `firebase-admin`? Also optional.** Storage is only needed for older releases'
330
342
  source maps and for attachments. With `firebase-admin` installed, its Storage and
331
- default bucket are used. Without it, name the bucket — `bucketName` on the handler, or
343
+ default bucket are used. Without it, name the bucket — `bucket` on the handler, or
332
344
  `configureAttachments({ bucket })` — and the service's own credentials are used.
333
345
  - **No Storage bucket?** You do not need one. `fsl upload-sourcemaps --embed-sourcemaps`
334
346
  without `--bucket` embeds the current release's maps into your deploy and uploads
@@ -339,6 +351,75 @@ A gate that throws counts as a rejection, not an opening.
339
351
  - **Response codes:** `204` written, `400` malformed payload, `401` gate refused, `405`
340
352
  not a POST, `500` something else. The client treats a non-2xx as a throw.
341
353
 
354
+ ## Check your setup
355
+
356
+ Most of what can go wrong here goes wrong silently: logs that never arrive, stacks that
357
+ never resolve, source code published next to the app. `fsl doctor` reads the project from
358
+ disk and says what it finds. It needs no network and no credentials, and it only reports
359
+ facts it can read from a file — it never guesses from your source code, so a finding is
360
+ never a false alarm.
361
+
362
+ ```bash
363
+ npx fsl doctor # Firebase: reads firebase.json
364
+ npx fsl doctor --backend=./server --dist=./dist # anything else: say where things are
365
+ ```
366
+
367
+ It prints a summary of how your setup will behave, then any findings:
368
+
369
+ ```
370
+ Setup: Firebase — functions in ./functions, web build in ./dist
371
+
372
+ Logging firebase-functions write()
373
+ Trace ids from each Cloud Functions trigger
374
+ Storage firebase-admin, default bucket
375
+ Callable createClientLogFunction available
376
+
377
+ ⚠ duplicate-storage 2 copies of @google-cloud/storage (8.2.0 at the top level, 7.22.0 inside firebase-admin)
378
+ Fix: npm dedupe
379
+ ```
380
+
381
+ | Id | Level | Means |
382
+ |---|---|---|
383
+ | `maps-published` | error | `.map` files are in the folder hosting serves — your source code is public |
384
+ | `node-version` | error | the backend's Node is below 22 |
385
+ | `callable-without-firebase-functions` | error | `firebase.json` has functions, but `firebase-functions` is not installed there |
386
+ | `could-not-check` | error | doctor could not read something it needed — including "run `npm install` first" |
387
+ | `duplicate-storage` | warning | two copies of `@google-cloud/storage`; fix with `npm dedupe` |
388
+ | `unsupported-peer` | warning | an installed peer (`firebase-admin`, `firebase-functions`, `firebase`) is outside the supported range |
389
+ | `embedded-maps-without-release` | warning | maps are embedded without a `.release` marker, so an older release can resolve against the wrong map |
390
+
391
+ **Exit code:** `0` when there are no errors, `1` when there is one. `--strict` also fails on
392
+ warnings, for teams that want a spotless setup; without it, a deliberate choice like
393
+ running with no Storage does not break CI. A check doctor could not run is always an
394
+ error, never a pass.
395
+
396
+ **`--json`** prints the same result for scripts and agents:
397
+
398
+ ```json
399
+ {
400
+ "setup": { "kind": "firebase", "backend": "./functions", "dist": "./dist",
401
+ "logging": "firebase-functions", "trace": "trigger", "storage": "firebase-admin",
402
+ "callable": true },
403
+ "findings": [
404
+ { "id": "duplicate-storage", "level": "warning",
405
+ "message": "2 copies of @google-cloud/storage (8.2.0 at the top level, 7.22.0 inside firebase-admin)",
406
+ "fix": "npm dedupe" }
407
+ ],
408
+ "exitCode": 0
409
+ }
410
+ ```
411
+
412
+ `setup.kind` is `firebase`, `node`, `browser-only` or `backend-only`; `logging` is
413
+ `firebase-functions`, `stdout` or `none`; `trace` is `trigger`, `header` or `none`; and
414
+ `storage` is `firebase-admin`, `google-cloud-storage` (which still needs a bucket named in
415
+ your code — doctor cannot see it) or `none`. The ids and fields are part of the 1.0 API:
416
+ scripts may depend on them.
417
+
418
+ What doctor does not check: anything set in your own code — the release id you pass to
419
+ `initLogger`, a bucket name passed to a handler. Its Storage line says so — "needs a bucket named in code (not checked)" — rather than
420
+ guessing. [`fsl verify`](https://github.com/dasasian/firebase-structured-logger/issues/25),
421
+ planned after 1.0, will check those by sending a real log.
422
+
342
423
  ## Local development
343
424
 
344
425
  The Functions emulator writes the same entries to a local JSONL file instead of Cloud
@@ -609,7 +690,7 @@ labels.hasAttachments="true" # entries that have files
609
690
  labels.logId="01J..." # the entry whose files you are looking for
610
691
  ```
611
692
 
612
- By default they share the bucket passed to `createClientLogFunction({ bucketName })` — the
693
+ By default they share the bucket passed to `createClientLogFunction({ bucket })` — the
613
694
  same one the source maps live in, falling back to the project's default bucket.
614
695
 
615
696
  Send them somewhere else with `configureAttachments`, in your functions entry point:
@@ -656,9 +737,9 @@ hold things back — so this is worth reading before you conclude something is b
656
737
 
657
738
  | Gate | Default | Where |
658
739
  |---|---|---|
659
- | Log budget | **50 logs**, refilling **1 per minute**; the last **20%** for errors only | client, per browser tab |
740
+ | Log limit | bursts of up to **50 logs**, then **one log recharges every 60 s**; the last **10** for errors only | client, per browser tab |
660
741
  | Duplicates | **3** full copies of the same error, then counted and sent as a summary | client, per browser tab |
661
- | Client severity floor | `WARNING` in production, `DEBUG` in dev | client, `minLogLevel` |
742
+ | Client severity floor | `WARNING` in production, `DEBUG` in dev | client, `minSeverity` |
662
743
  | Server severity floor | `WARNING` in production, `DEBUG` in the emulator | function, `minSeverity` |
663
744
  | Function concurrency | `maxInstances: 1` on `createClientLogFunction` | function |
664
745
 
@@ -667,11 +748,11 @@ initLogger({
667
748
  appId: 'my-app',
668
749
  releaseId,
669
750
  logFunction,
670
- minLogLevel: 'INFO',
751
+ minSeverity: 'INFO',
671
752
  rateLimitOptions: {
672
- sessionLimit: 50, // the budget: how many logs can go at once
673
- refillPerMinute: 1, // how fast it comes back
674
- errorReserve: 0.2, // share of the budget only ERROR and above may spend
753
+ burstLimit: 50, // how many logs can go at once
754
+ rechargeSecondsPerLog: 60, // after a burst, one log recharges every 60 seconds
755
+ reservedForErrors: 10, // of the burst, how many only ERROR and above may use
675
756
  duplicateLimit: 3, // full copies of one error before counting starts
676
757
  summaryIntervalMinutes: 60,
677
758
  summaryMaxAgeDays: 7, // how long an unsent summary waits on the device
@@ -684,21 +765,24 @@ The client's production default comes from `process.env.NODE_ENV`, which Vite re
684
765
  build time. A `define: { 'process.env': {} }` in `vite.config` — common, to quiet a library
685
766
  that expects Node — replaces the whole object instead, `NODE_ENV` reads as undefined, and
686
767
  the floor is silently `DEBUG` in production. If your config has that line, pass
687
- `minLogLevel` explicitly. Stating it is the safe habit either way: it is the one default
768
+ `minSeverity` explicitly. Stating it is the safe habit either way: it is the one default
688
769
  here whose failure mode is a bill rather than a missing log.
689
770
 
690
- ### The budget refills
771
+ ### Bursts recharge
691
772
 
692
- Each browser tab starts with 50 logs. Every log spends one, and one comes back each minute,
693
- up to 50. A reload does not reset it — the tab keeps its budget in `sessionStorage`.
773
+ Each browser tab can send a burst of up to `burstLimit` logs (50). After that, one log
774
+ recharges every `rechargeSecondsPerLog` seconds (60) — one at a time, so a full burst takes
775
+ 50 minutes to come back. A reload does not reset it: the tab keeps its count in
776
+ `sessionStorage`.
694
777
 
695
778
  So a burst at start-up is fine, and a user who works in the app all afternoon is never
696
779
  silenced for long. A bug that logs in a loop is still held to about 60 entries an hour per
697
780
  user: 1,000 users stuck in such a loop for a working month stays around the 50 GiB of
698
781
  Cloud Logging that each project gets free.
699
782
 
700
- The last 20% of the budget is reserved: warnings can spend it down to 10, and only
701
- `ERROR` and above can spend the rest. A noisy warning cannot use up the room a crash needs.
783
+ The last `reservedForErrors` logs (10) are kept for errors: warnings can use the burst down
784
+ to 10, and only `ERROR` and above can use the rest. A value over half of `burstLimit` is
785
+ capped at half, with one warning, so warnings always have room. A noisy warning cannot use up the room a crash needs.
702
786
 
703
787
  ### Repeats are counted, not dropped
704
788
 
@@ -742,7 +826,7 @@ messages, and may hold personal data.
742
826
  A summary is a `WARNING` with no stack, so Cloud Error Reporting sees the 3 full copies and
743
827
  not the summary. For the true count, add up `labels.repeatCount` in Cloud Logging.
744
828
 
745
- Summaries do not spend the log budget. There is at most one per error, per release, per user,
829
+ Summaries do not count against the burst. There is at most one per error, per release, per user,
746
830
  per hour.
747
831
 
748
832
  ### What a dropped log looks like
@@ -751,11 +835,11 @@ The two rate limits say so in the browser console:
751
835
 
752
836
  ```
753
837
  [fsl] Duplicate counted for the next summary: TypeError: cannot read 'id' | checkout
754
- [fsl] Log budget empty — next log in about a minute
755
- [fsl] Log budget: only errors can use the reserve now
838
+ [fsl] Log limit reached — recharging, next log in about a minute
839
+ [fsl] Log limit: only errors can use the reserved logs now
756
840
  ```
757
841
 
758
- **The severity floors are silent.** Both of them — the client's `minLogLevel` and the
842
+ **The severity floors are silent.** Both of them — the client's `minSeverity` and the
759
843
  function's `minSeverity` — simply return, with nothing written and nothing logged about it.
760
844
 
761
845
  So if an entry never arrived and there is no `[fsl]` warning in the console, it was a floor,
@@ -764,7 +848,7 @@ not a limit. In production both default to `WARNING`, which drops `DEBUG`, `INFO
764
848
  `INFO` you expected to see has two places it can vanish.
765
849
 
766
850
  `maxInstances: 1` is a deliberate cost guard on what is usually the busiest function in the
767
- system. Raise it (`createClientLogFunction({ bucketName, maxInstances: 5 })`) if you are
851
+ system. Raise it (`createClientLogFunction({ bucket, maxInstances: 5 })`) if you are
768
852
  dropping client logs under load — and watch your Cloud Logging bill when you do.
769
853
 
770
854
  Feedback is exempt from every one of these. See [User feedback](#user-feedback).
@@ -822,7 +906,21 @@ logger.addBreadcrumb(type, name, data?)
822
906
  ```
823
907
 
824
908
  Also exported: `initLogger`, `getClientLogger`, `setupGlobalErrorHandler`, `handleReactError`,
825
- `sendFeedback`, `triggerTestLog`, `addBreadcrumb`, `bc`.
909
+ `sendFeedback`, `sendTestLog`, `addBreadcrumb`, `bc`.
910
+
911
+ **Renamed in 1.0.** The old names still work in 1.x, each with a one-time console warning,
912
+ and are removed in 2.0:
913
+
914
+ | Old | New |
915
+ |---|---|
916
+ | `minLogLevel` (client `initLogger`) | `minSeverity` |
917
+ | `bucketName` (`createClientLogHandler`, `createClientLogFunction`, `createHttpLogHandler`) | `bucket` |
918
+ | `rateLimitOptions.sessionLimit` | `rateLimitOptions.burstLimit` |
919
+ | `rateLimitOptions.refillPerMinute` | `rateLimitOptions.rechargeSecondsPerLog` (seconds, not a rate: `60 / refillPerMinute`) |
920
+ | `rateLimitOptions.errorReserve` (a share) | `rateLimitOptions.reservedForErrors` (a count: `errorReserve × burstLimit`) |
921
+ | type `ClientLogRequest` | type `LogRequest` |
922
+ | `triggerTestLog()` | `sendTestLog()` |
923
+ | `fsl upload-sourcemaps --functions=<dir>` | `--backend=<dir>` (it is not only for Cloud Functions) |
826
924
 
827
925
  `Logger` is exported as a **type only** — the client logger is a session singleton, so
828
926
  annotate with `Logger<MyAppLabels>` and construct with `initLogger()`. A second instance
@@ -841,7 +939,7 @@ logError / logWarn / logInfo / logDebug (message, labels?, context?, attachments
841
939
  configureAttachments({ bucket?, prefix? }) // once, at module load — see Attachments
842
940
 
843
941
  // Receiving client logs. All three take the same source-map config:
844
- // { bucketName?, sourceMaps?: { bucket?, prefix? } }
942
+ // { bucket?, sourceMaps?: { bucket?, prefix? } }
845
943
  createClientLogFunction({ …, cors?, maxInstances? }) // a ready-to-export callable
846
944
  createHttpLogHandler({ …, authorize, allowOrigin? }) // an (req, res) handler for Express etc.
847
945
  createClientLogHandler({ … }) // the bare handler, wrap it yourself
@@ -858,13 +956,18 @@ bare handler only if you are wrapping it in something else yourself.
858
956
 
859
957
  ```bash
860
958
  # Upload source maps to Cloud Storage and strip local .map files (run in deploy)
861
- npx fsl upload-sourcemaps --functions=./functions --embed-sourcemaps
959
+ npx fsl upload-sourcemaps --backend=./functions --embed-sourcemaps
862
960
 
863
961
  # Same, to a bucket and prefix of your choosing — tell the reader the same values
864
- npx fsl upload-sourcemaps --functions=./functions --embed-sourcemaps --bucket=my-maps --prefix=fsl-maps
962
+ npx fsl upload-sourcemaps --backend=./functions --embed-sourcemaps --bucket=my-maps --prefix=fsl-maps
865
963
 
866
964
  # No bucket at all: embed the current release, upload nothing
867
- npx fsl upload-sourcemaps --functions=./backend --embed-sourcemaps
965
+ npx fsl upload-sourcemaps --backend=./backend --embed-sourcemaps
966
+
967
+ # Check the setup from disk — no network, no credentials (see "Check your setup")
968
+ npx fsl doctor
969
+ npx fsl doctor --backend=./server --dist=./dist # no firebase.json to read
970
+ npx fsl doctor --strict --json # CI: fail on warnings too, machine-readable
868
971
 
869
972
  # Install the Claude Code skills into the current project (or --global, --force)
870
973
  npx fsl install-skills
@@ -1,4 +1,4 @@
1
- export { initLogger, getClientLogger, sendFeedback, triggerTestLog } from './logger';
1
+ export { initLogger, getClientLogger, sendFeedback, sendTestLog, triggerTestLog } from './logger';
2
2
  export type { Logger, InitLoggerConfig, FeedbackOptions, RateLimitConfig } from './logger';
3
3
  export { setupGlobalErrorHandler, handleReactError } from './errorHandler';
4
4
  export { addBreadcrumb, bc } from './breadcrumbs';
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/client/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,eAAe,EAAE,YAAY,EAAE,cAAc,EAAE,MAAM,UAAU,CAAA;AAMpF,YAAY,EAAE,MAAM,EAAE,gBAAgB,EAAE,eAAe,EAAE,eAAe,EAAE,MAAM,UAAU,CAAA;AAC1F,OAAO,EAAE,uBAAuB,EAAE,gBAAgB,EAAE,MAAM,gBAAgB,CAAA;AAC1E,OAAO,EAAE,aAAa,EAAE,EAAE,EAAE,MAAM,eAAe,CAAA;AACjD,YAAY,EAAE,WAAW,EAAE,UAAU,EAAE,eAAe,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/client/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,eAAe,EAAE,YAAY,EAAE,WAAW,EAAE,cAAc,EAAE,MAAM,UAAU,CAAA;AAMjG,YAAY,EAAE,MAAM,EAAE,gBAAgB,EAAE,eAAe,EAAE,eAAe,EAAE,MAAM,UAAU,CAAA;AAC1F,OAAO,EAAE,uBAAuB,EAAE,gBAAgB,EAAE,MAAM,gBAAgB,CAAA;AAC1E,OAAO,EAAE,aAAa,EAAE,EAAE,EAAE,MAAM,eAAe,CAAA;AACjD,YAAY,EAAE,WAAW,EAAE,UAAU,EAAE,eAAe,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAA"}
@@ -1,10 +1,11 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.bc = exports.addBreadcrumb = exports.handleReactError = exports.setupGlobalErrorHandler = exports.triggerTestLog = exports.sendFeedback = exports.getClientLogger = exports.initLogger = void 0;
3
+ exports.bc = exports.addBreadcrumb = exports.handleReactError = exports.setupGlobalErrorHandler = exports.triggerTestLog = exports.sendTestLog = exports.sendFeedback = exports.getClientLogger = exports.initLogger = void 0;
4
4
  var logger_1 = require("./logger");
5
5
  Object.defineProperty(exports, "initLogger", { enumerable: true, get: function () { return logger_1.initLogger; } });
6
6
  Object.defineProperty(exports, "getClientLogger", { enumerable: true, get: function () { return logger_1.getClientLogger; } });
7
7
  Object.defineProperty(exports, "sendFeedback", { enumerable: true, get: function () { return logger_1.sendFeedback; } });
8
+ Object.defineProperty(exports, "sendTestLog", { enumerable: true, get: function () { return logger_1.sendTestLog; } });
8
9
  Object.defineProperty(exports, "triggerTestLog", { enumerable: true, get: function () { return logger_1.triggerTestLog; } });
9
10
  var errorHandler_1 = require("./errorHandler");
10
11
  Object.defineProperty(exports, "setupGlobalErrorHandler", { enumerable: true, get: function () { return errorHandler_1.setupGlobalErrorHandler; } });
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/client/index.ts"],"names":[],"mappings":";;;AAAA,mCAAoF;AAA3E,oGAAA,UAAU,OAAA;AAAE,yGAAA,eAAe,OAAA;AAAE,sGAAA,YAAY,OAAA;AAAE,wGAAA,cAAc,OAAA;AAOlE,+CAA0E;AAAjE,uHAAA,uBAAuB,OAAA;AAAE,gHAAA,gBAAgB,OAAA;AAClD,6CAAiD;AAAxC,4GAAA,aAAa,OAAA;AAAE,iGAAA,EAAE,OAAA"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/client/index.ts"],"names":[],"mappings":";;;AAAA,mCAAiG;AAAxF,oGAAA,UAAU,OAAA;AAAE,yGAAA,eAAe,OAAA;AAAE,sGAAA,YAAY,OAAA;AAAE,qGAAA,WAAW,OAAA;AAAE,wGAAA,cAAc,OAAA;AAO/E,+CAA0E;AAAjE,uHAAA,uBAAuB,OAAA;AAAE,gHAAA,gBAAgB,OAAA;AAClD,6CAAiD;AAAxC,4GAAA,aAAa,OAAA;AAAE,iGAAA,EAAE,OAAA"}
@@ -12,8 +12,10 @@ export interface InitLoggerConfig<AppLabels extends Record<string, string | unde
12
12
  appId: string;
13
13
  releaseId: string;
14
14
  logFunction: LogCallable;
15
- minLogLevel?: LogSeverity;
15
+ minSeverity?: LogSeverity;
16
16
  rateLimitOptions?: RateLimitConfig;
17
+ /** @deprecated Use `minSeverity`. */
18
+ minLogLevel?: LogSeverity;
17
19
  }
18
20
  export declare class Logger<AppLabels extends Record<string, string | undefined> = Record<string, string | undefined>> {
19
21
  private readonly config;
@@ -71,7 +73,7 @@ export declare class Logger<AppLabels extends Record<string, string | undefined>
71
73
  */
72
74
  export declare function sendFeedback<AppLabels extends Record<string, string | undefined> = Record<string, string | undefined>>(text: string, extras?: FeedbackOptions<AppLabels>): void;
73
75
  /**
74
- * Trigger a test log entry to verify the logging pipeline is working end-to-end.
76
+ * Send a test log entry to verify the logging pipeline is working end-to-end.
75
77
  * Logs at all severities with errorType: 'fsl-verify'. Safe to call in dev only.
76
78
  *
77
79
  * After clicking, check:
@@ -79,6 +81,8 @@ export declare function sendFeedback<AppLabels extends Record<string, string | u
79
81
  * 2. Stack trace is symbolicated (points to source file, not minified bundle)
80
82
  * 3. MCP query: source: local, where: [{ field: "labels.errorType", operator: "==", value: "fsl-verify" }]
81
83
  */
84
+ export declare function sendTestLog(): void;
85
+ /** @deprecated Use `sendTestLog()`. */
82
86
  export declare function triggerTestLog(): void;
83
87
  export declare function initLogger<AppLabels extends Record<string, string | undefined> = Record<string, string | undefined>>(config: InitLoggerConfig<AppLabels>): Logger<AppLabels>;
84
88
  export declare function getClientLogger<AppLabels extends Record<string, string | undefined> = Record<string, string | undefined>>(): Logger<AppLabels>;
@@ -1 +1 @@
1
- {"version":3,"file":"logger.d.ts","sourceRoot":"","sources":["../../src/client/logger.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,UAAU,EAAgB,UAAU,EAAE,MAAM,iBAAiB,CAAA;AAWxF,OAAO,EAQL,KAAK,eAAe,EAErB,MAAM,eAAe,CAAA;AAEtB,YAAY,EAAE,eAAe,EAAE,CAAA;AAE/B,KAAK,WAAW,GAAG,CAAC,IAAI,EAAE,UAAU,KAAK,OAAO,CAAC,OAAO,CAAC,CAAA;AAEzD,MAAM,WAAW,eAAe,CAC9B,SAAS,SAAS,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,SAAS,CAAC,GAAG,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,SAAS,CAAC;IAEzF,8EAA8E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B;CAgChC;AAED;;;;;GAKG;AACH,wBAAgB,YAAY,CAC1B,SAAS,SAAS,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,SAAS,CAAC,GAAG,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,SAAS,CAAC,EACzF,IAAI,EAAE,MAAM,EAAE,MAAM,CAAC,EAAE,eAAe,CAAC,SAAS,CAAC,GAAG,IAAI,CAEzD;AAED;;;;;;;;GAQG;AACH,wBAAgB,WAAW,IAAI,IAAI,CAWlC;AAED,uCAAuC;AACvC,wBAAgB,cAAc,IAAI,IAAI,CAGrC;AAKD,wBAAgB,UAAU,CACxB,SAAS,SAAS,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,SAAS,CAAC,GAAG,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,SAAS,CAAC,EACzF,MAAM,EAAE,gBAAgB,CAAC,SAAS,CAAC,GAAG,MAAM,CAAC,SAAS,CAAC,CAYxD;AAED,wBAAgB,eAAe,CAC7B,SAAS,SAAS,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,SAAS,CAAC,GAAG,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,SAAS,CAAC,KACtF,MAAM,CAAC,SAAS,CAAC,CAGrB"}
@@ -2,11 +2,13 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.Logger = void 0;
4
4
  exports.sendFeedback = sendFeedback;
5
+ exports.sendTestLog = sendTestLog;
5
6
  exports.triggerTestLog = triggerTestLog;
6
7
  exports.initLogger = initLogger;
7
8
  exports.getClientLogger = getClientLogger;
8
9
  const severity_1 = require("../shared/severity");
9
10
  const error_1 = require("../shared/error");
11
+ const deprecate_1 = require("../shared/deprecate");
10
12
  const breadcrumbs_1 = require("./breadcrumbs");
11
13
  const rateLimiter_1 = require("./rateLimiter");
12
14
  /**
@@ -75,7 +77,9 @@ class Logger {
75
77
  userLabels = {};
76
78
  constructor(config) {
77
79
  this.config = config;
78
- this.minLevel = severity_1.SEVERITY_ORDER[config.minLogLevel ?? defaultMinLevel()];
80
+ if (config.minLogLevel !== undefined)
81
+ (0, deprecate_1.warnDeprecated)('minLogLevel', 'minSeverity');
82
+ this.minLevel = severity_1.SEVERITY_ORDER[config.minSeverity ?? config.minLogLevel ?? defaultMinLevel()];
79
83
  if (config.rateLimitOptions) {
80
84
  (0, rateLimiter_1.configureRateLimiter)(config.rateLimitOptions);
81
85
  }
@@ -166,10 +170,10 @@ class Logger {
166
170
  console.warn(`[fsl] Duplicate counted for the next summary: ${(0, rateLimiter_1.describeSignature)(decision.signature ?? '')}`);
167
171
  }
168
172
  else if (decision.reason === 'reserve') {
169
- console.warn('[fsl] Log budget: only errors can use the reserve now');
173
+ console.warn('[fsl] Log limit: only errors can use the reserved logs now');
170
174
  }
171
175
  else {
172
- console.warn('[fsl] Log budget empty — next log in about a minute');
176
+ console.warn('[fsl] Log limit reached — recharging, next log in about a minute');
173
177
  }
174
178
  return false;
175
179
  }
@@ -289,7 +293,7 @@ function sendFeedback(text, extras) {
289
293
  getClientLogger().sendFeedback(text, extras);
290
294
  }
291
295
  /**
292
- * Trigger a test log entry to verify the logging pipeline is working end-to-end.
296
+ * Send a test log entry to verify the logging pipeline is working end-to-end.
293
297
  * Logs at all severities with errorType: 'fsl-verify'. Safe to call in dev only.
294
298
  *
295
299
  * After clicking, check:
@@ -297,8 +301,8 @@ function sendFeedback(text, extras) {
297
301
  * 2. Stack trace is symbolicated (points to source file, not minified bundle)
298
302
  * 3. MCP query: source: local, where: [{ field: "labels.errorType", operator: "==", value: "fsl-verify" }]
299
303
  */
300
- function triggerTestLog() {
301
- console.info('[fsl] triggerTestLog called');
304
+ function sendTestLog() {
305
+ console.info('[fsl] sendTestLog called');
302
306
  const logger = getClientLogger();
303
307
  const testError = new Error('[fsl-verify] Test error — logging pipeline check');
304
308
  console.info('[fsl] sending error log...');
@@ -307,7 +311,12 @@ function triggerTestLog() {
307
311
  logger.warning('[fsl-verify] Test warning', { errorType: 'fsl-verify' });
308
312
  console.info('[fsl] sending info log...');
309
313
  logger.info('[fsl-verify] Test info', { errorType: 'fsl-verify' });
310
- console.info('[fsl] triggerTestLog scheduled — sends are fire-and-forget; check dev.jsonl in ~1-2s');
314
+ console.info('[fsl] sendTestLog scheduled — sends are fire-and-forget; check dev.jsonl in ~1-2s');
315
+ }
316
+ /** @deprecated Use `sendTestLog()`. */
317
+ function triggerTestLog() {
318
+ (0, deprecate_1.warnDeprecated)('triggerTestLog', 'sendTestLog');
319
+ sendTestLog();
311
320
  }
312
321
  // Module-level singleton
313
322
  let instance = null;
@@ -1 +1 @@
1
- {"version":3,"file":"logger.js","sourceRoot":"","sources":["../../src/client/logger.ts"],"names":[],"mappings":";;;AA2ZA,oCAIC;AAWD,wCAWC;AAKD,gCAcC;AAED,0CAKC;AA9cD,iDAAmE;AACnE,2CAAyD;AACzD,+CAOsB;AACtB,+CAUsB;AAyBtB;;;;;;;;GAQG;AACH,SAAS,eAAe;IACtB,IAAI,CAAC;QACH,IAAI,OAAO,CAAC,GAAG,CAAC,QAAQ,KAAK,YAAY;YAAE,OAAO,SAAS,CAAA;IAC7D,CAAC;IAAC,MAAM,CAAC;QACP,wCAAwC;IAC1C,CAAC;IACD,OAAO,OAAO,CAAA;AAChB,CAAC;AAED,oCAAoC;AACpC,MAAM,SAAS,GAAuB;IACpC,CAAC,kBAAkB,EAAE,KAAK,CAAC;IAC3B,CAAC,SAAS,EAAE,SAAS,CAAC;IACtB,CAAC,KAAK,EAAE,OAAO,CAAC;IAChB,CAAC,KAAK,EAAE,SAAS,CAAC;IAClB,CAAC,OAAO,EAAE,OAAO,CAAC;CACnB,CAAA;AAED,MAAM,QAAQ,GAAuB;IACnC,CAAC,SAAS,EAAE,SAAS,CAAC;IACtB,CAAC,KAAK,EAAE,MAAM,CAAC;IACf,CAAC,QAAQ,EAAE,QAAQ,CAAC;IACpB,CAAC,QAAQ,EAAE,QAAQ,CAAC;CACrB,CAAA;AAED,SAAS,cAAc,CAAC,KAAyB,E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,GAAG,EAAE,CAAC,QAAQ,EAAE,oBAAoB,EAAE,EAAE,CAAC,CAAC,CAAA;IACvD,CAAC;IAED,OAAO,QAA6B,CAAA;AACtC,CAAC;AAED,SAAgB,eAAe;IAG7B,IAAI,CAAC,QAAQ;QAAE,MAAM,IAAI,KAAK,CAAC,+BAA+B,CAAC,CAAA;IAC/D,OAAO,QAA6B,CAAA;AACtC,CAAC;AAED;;;;;;;;;;;;GAYG;AACH,IAAI,OAAO,QAAQ,KAAK,WAAW,EAAE,CAAC;IACpC,QAAQ,CAAC,gBAAgB,CAAC,kBAAkB,EAAE,GAAG,EAAE;QACjD,IAAI,QAAQ,CAAC,eAAe,KAAK,QAAQ;YAAE,OAAM;QACjD,IAAA,+BAAiB,EAAC,IAAI,CAAC,CAAA;QACvB,QAAQ,EAAE,oBAAoB,EAAE,CAAA;IAClC,CAAC,CAAC,CAAA;AACJ,CAAC;AAED,IAAI,OAAO,MAAM,KAAK,WAAW,EAAE,CAAC;IAClC,MAAM,QAAQ,GAAG,WAAW,CAAC,GAAG,EAAE;QAChC,IAAA,+BAAiB,GAAE,CAAA;QACnB,QAAQ,EAAE,oBAAoB,EAAE,CAAA;IAClC,CAAC,EAAE,MAAM,CAAC,CACT;IAAC,QAA8C,CAAC,KAAK,EAAE,EAAE,CAAA;AAC5D,CAAC"}
@@ -1,11 +1,12 @@
1
1
  import type { LogSeverity } from '../shared/types';
2
2
  export interface RateLimitConfig {
3
3
  /** The budget: how many logs can go out at once. Default 50. */
4
- sessionLimit?: number;
5
- /** How fast the budget comes back, per minute. Default 1. */
6
- refillPerMinute?: number;
7
- /** Share of `sessionLimit` only ERROR and above may spend. Default 0.2. */
8
- errorReserve?: number;
4
+ burstLimit?: number;
5
+ /** After a burst, how many seconds before one more log recharges. Default 60. */
6
+ rechargeSecondsPerLog?: number;
7
+ /** Of `burstLimit`, how many only ERROR and above may spend. A value over half of
8
+ * `burstLimit` is capped at half, with one warning. Default 10. */
9
+ reservedForErrors?: number;
9
10
  /** Full copies of one error before it is only counted. Default 3. */
10
11
  duplicateLimit?: number;
11
12
  storageKey?: string;
@@ -15,6 +16,12 @@ export interface RateLimitConfig {
15
16
  summaryMaxAgeDays?: number;
16
17
  /** Most pending summaries kept at once; oldest are dropped first. Default 50. */
17
18
  maxPendingSummaries?: number;
19
+ /** @deprecated Use `burstLimit`. */
20
+ sessionLimit?: number;
21
+ /** @deprecated Use `rechargeSecondsPerLog` (`60 / refillPerMinute`). */
22
+ refillPerMinute?: number;
23
+ /** @deprecated Use `reservedForErrors` (`Math.round(errorReserve * burstLimit)`), a count rather than a share. */
24
+ errorReserve?: number;
18
25
  }
19
26
  /**
20
27
  * A repeat count waiting to be sent as a WARNING summary. Queued in
@@ -1 +1 @@
1
- {"version":3,"file":"rateLimiter.d.ts","sourceRoot":"","sources":["../../src/client/rateLimiter.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,iBAAiB,CAAA;AA2BlD,MAAM,WAAW,eAAe;IAC9B,gEAAgE;IAChE,YAAY,CAAC,EAAE,MAAM,CAAA;IACrB,6DAA6D;IAC7D,eAAe,CAAC,EAAE,MAAM,CAAA;IACxB,2EAA2E;IAC3E,YAAY,CAAC,EAAE,MAAM,CAAA;IACrB,qEAAqE;IACrE,cAAc,CAAC,EAAE,MAAM,CAAA;IACvB,UAAU,CAAC,EAAE,MAAM,CAAA;IACnB,6EAA6E;IAC7E,sBAAsB,CAAC,EAAE,MAAM,CAAA;IAC/B,oFAAoF;IACpF,iBAAiB,CAAC,EAAE,MAAM,CAAA;IAC1B,iFAAiF;IACjF,mBAAmB,CAAC,EAAE,MAAM,CAAA;CAC7B;AA+BD;;;;;;;;;;;;;;;GAeG;AACH,MAAM,WAAW,cAAc;IAC7B,EAAE,EAAE,MAAM,CAAA;IACV,OAAO,EAAE,MAAM,CAAA;IACf,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,MAAM,CAAC,EAAE,MAAM,CAAA;IACf,SAAS,C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