- 
                Notifications
    
You must be signed in to change notification settings  - Fork 32
 
Closed
Labels
waiting for customer responseIssue is on hold awaiting more information from OPIssue is on hold awaiting more information from OP
Description
According to the typing of HttpsOptions class, I should be able to set invoker to public or private. But when I tried to deploy a https_fn.on_request function with invoker=True, an error is raised:
[2024-03-06 02:26:16,162] ERROR in app: Exception on /__/functions.yaml [GET]
Traceback (most recent call last):
  File "/Volumes/Cased/Projects/cloud-functions/functions/.venv/lib/python3.11/site-packages/flask/app.py", line 1463, in wsgi_app
    response = self.full_dispatch_request()
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Volumes/Cased/Projects/cloud-functions/functions/.venv/lib/python3.11/site-packages/flask/app.py", line 872, in full_dispatch_request
    rv = self.handle_user_exception(e)
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Volumes/Cased/Projects/cloud-functions/functions/.venv/lib/python3.11/site-packages/flask/app.py", line 870, in full_dispatch_request
    rv = self.dispatch_request()
         ^^^^^^^^^^^^^^^^^^^^^^^
  File "/Volumes/Cased/Projects/cloud-functions/functions/.venv/lib/python3.11/site-packages/flask/app.py", line 855, in dispatch_request
    return self.ensure_sync(self.view_functions[rule.endpoint])(**view_args)  # type: ignore[no-any-return]
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Volumes/Cased/Projects/cloud-functions/functions/.venv/lib/python3.11/site-packages/firebase_functions/private/serving.py", line 122, in get_functions_yaml
    functions = get_functions()
                ^^^^^^^^^^^^^^^
  File "/Volumes/Cased/Projects/cloud-functions/functions/.venv/lib/python3.11/site-packages/firebase_functions/private/serving.py", line 40, in get_functions
    spec.loader.exec_module(module)
  File "<frozen importlib._bootstrap_external>", line 940, in exec_module
  File "<frozen importlib._bootstrap>", line 241, in _call_with_frames_removed
  File "/Volumes/Cased/Projects/cloud-functions/functions/main.py", line 29, in <module>
    @https_fn.on_request(invoker="public", memory=options.MemoryOption.MB_512)
     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Volumes/Cased/Projects/cloud-functions/functions/.venv/lib/python3.11/site-packages/firebase_functions/https_fn.py", line 443, in on_request_inner_decorator
    options._endpoint(func_name=func.__name__),
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Volumes/Cased/Projects/cloud-functions/functions/.venv/lib/python3.11/site-packages/firebase_functions/options.py", line 1120, in _endpoint
    assert len(
           ^^^^
AssertionError: HttpsOptions: Invalid option for invoker - must be a non-empty list.
Metadata
Metadata
Assignees
Labels
waiting for customer responseIssue is on hold awaiting more information from OPIssue is on hold awaiting more information from OP