firebase-tools
firebase-tools copied to clipboard
Advanced CF3 param features: regexp-validated, selector, boolean, secret, resource-list, boolean-type
Major architectural change: ParamValue has changed from string | number | boolean to an object which contains the raw value, type information, and critically, whether the param came from CSM and therefore should never be written to disk.
Potential regression: we used to fail when reading params from dotenvs if the value didn't "look" like the right type. This current implementation lets people do stupid things with string-to-number/boolean conversion if they want to, which is...the spirit of Javascript, right?
Git is calling out a few lint errors
Codecov Report
Merging #4821 (0634c21) into master (23a65c2) will decrease coverage by
0.26%. The diff coverage is20.48%.
@@ Coverage Diff @@
## master #4821 +/- ##
==========================================
- Coverage 56.92% 56.66% -0.27%
==========================================
Files 291 291
Lines 19223 19345 +122
Branches 3823 3857 +34
==========================================
+ Hits 10943 10961 +18
- Misses 7354 7454 +100
- Partials 926 930 +4
| Impacted Files | Coverage Δ | |
|---|---|---|
| src/deploy/functions/prepare.ts | 28.96% <0.00%> (-0.49%) |
:arrow_down: |
| src/gcp/secretManager.ts | 44.53% <12.50%> (-2.31%) |
:arrow_down: |
| src/gcp/storage.ts | 23.52% <14.28%> (-1.48%) |
:arrow_down: |
| src/deploy/functions/params.ts | 34.54% <21.42%> (-21.32%) |
:arrow_down: |
| src/deploy/functions/build.ts | 58.89% <28.57%> (+1.75%) |
:arrow_up: |
| src/emulator/auth/state.ts | 85.35% <0.00%> (+0.56%) |
:arrow_up: |
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.
Okay, talked things over with @taeold and it turns out that a lot of the complexity around secrets, intended to give parity with extensions, just doesn't make sense in a CF3 world. Cutting back the handling of secret params to basically just be a validation step now.