Skip to content

[firebase-tools 13.19.0 ] functions deploy fails with [object Object] when reading a secret. (13.6.1 works) #7728

@sondretj

Description

@sondretj

[REQUIRED] Environment info

firebase-tools: 13.6.1 and 13.19.0

Platform: Github actions

[REQUIRED] Test case

Sorry, don't have time now. And since I dont work with this regularly I figured it was better to try to submit a bug fast, rather than ignoring it and maybe pick it up the next time I will work on this.

[REQUIRED] Steps to reproduce

Write a function in JS that uses a secret:
const secret = defineSecret("SECRET");

Deploy firebase functions that uses a secret using the newest version. 13.19.0

[REQUIRED] Expected behavior

It deploys successfully.

[REQUIRED] Actual behavior

It fails with:

Error: Failed to validate secret versions:
- FirebaseError HTTP Error: 400, The provided Secret ID [projects/myproject/secrets/[object Object]/versions/latest] does not match the expected format [projects/*/secrets/*/versions/*]

Screenshot from Github Actions where it started failing:

      - name: Install Firebase CLI
        run: npm install -g firebase-tools

      - name: Deploy to Dev Environment
        run: |
          npm run deploy:dev
Skjermbilde 2024-09-24 kl  22 03 28

Screenshot from Github Actions where it works:

      - name: Install Firebase CLI
        run: npm install -g firebase-tools@13.6.1

      - name: Deploy to Dev Environment
        run: |
          npm run deploy:dev
Skjermbilde 2024-09-24 kl  22 02 56

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions