8000 validateQueueId does not accept underscores · Issue #8659 · firebase/firebase-tools · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
validateQueueId does not accept underscores #8659
Open
@tai-bo

Description

@tai-bo

[REQUIRED] Environment info

firebase-tools:
Firebase Emulator

Platform:
Firebase CLI 14.4.0 on macOS

[REQUIRED] Test case

from firebase_admin import functions
task_queue=functions.task_queue(f"locations/australia-southeast1/functions/a_b_c")

[REQUIRED] Steps to reproduce

from firebase_admin import functions
task_queue=functions.task_queue(f"locations/australia-southeast1/functions/a_b_c")

[REQUIRED] Expected behavior

This should be an acceptable queue ID.

[REQUIRED] Actual behavior

Instead, it is throwing:

Error: Queue ID must start with a letter followed by up to 62 letters, numbers, hyphens, or underscores and must end with a letter or a number

This is due to the regex has not been updated to accomodate underscores:

const regex = /^[A-Za-z0-9-]+$/;

in

validateQueueId(queueId: string): boolean {

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0