Questions tagged [functions-framework]

Local emulation of google cloud functions

See

https://github.com/GoogleCloudPlatform/functions-framework-nodejs

24 questions
6
votes
1 answer

Dart Functions Framework usage

I'm new to the Dart functions framework. My goal is to use this package to create several functions and deploy them to Cloud Run (in combination with Firebase, but I guess that's irrelevant to this question). I've run the quick starts and I've read…
3
votes
1 answer

Can I view log messages when using functions-framework and Google Cloud Logging Python v3.0.0

I am writing a new cloud function and am using the new Google Cloud Logging library as announced at https://cloud.google.com/blog/products/devops-sre/google-cloud-logging-python-client-library-v3-0-0-release. I am also using functions-framework to…
jamiet
  • 10,501
  • 14
  • 80
  • 159
3
votes
1 answer

Is credential necessary when running Firebase Admin with Firebase Emulator?

I'm running Firebase Admin SDK on python through functions-framework with Firebase emulator set up on different terminal and I have a question. While this works on shell(zsh)...: # python import firebase_admin from firebase_admin import auth as…
2
votes
0 answers

How to use mock implementation in Google cloud functions integration test

I am using google cloud function written in javascript to do the transformation of an event received from a pub/sub topic and publishing it to another pub/sub topic. Function is working perfectly fine. My question is around testing. I have been…
2
votes
1 answer

How to test Google Cloud Storage Triggers Cloud Function locally?

With reference to Google Cloud Storage Triggers , I wrote a background function which gets triggered from GCS. Using GCP Function Framework for Java, is it possible to test it locally ?
1
vote
2 answers

Sending 200 success using node js Google Cloud Function

I'm trying to send a 200 - Success back using the 'res' parameter of a google cloud function. I kept getting the error 'TypeError: res.setStatusCode is not a function.' even though this should be a part of the object. So I did the below to make…
DbxD
  • 540
  • 2
  • 15
  • 29
1
vote
0 answers

How to implement more than one endpoint in a Google Cloud Function?

My intention is to use a unique Google Cloud Function to accommodate a few endpoints. I do have a super simple code using the Python functions-framework to take an Id Token and validate whether it is valid. I'd like to add one more endpoint to…
1
vote
0 answers

Functions Framework giving "Provided code is not a loadable module. Could not load the function, shutting down."

I have a Google Cloud Function I've developed. The main.py and requirements.txt file are both in a folder called "hello". Here's the entirety of my main.py file: import functions_framework import…
1
vote
0 answers

GCP Functions Framework for Python - Necessary to include in requirements.txt?

When creating a function to run on GCP Cloud Functions, do you need to include the functions framework for Python as a requirement in your requirements.txt file? The official repository suggests that you don't: On Cloud Functions, using the…
1
vote
1 answer

Can I see log output in the terminal when using functions-framework and Google Cloud Logging Python v3.0.0

I am writing a new cloud function and am using the new Google Cloud Logging library as announced at https://cloud.google.com/blog/products/devops-sre/google-cloud-logging-python-client-library-v3-0-0-release. I am also using functions-framework to…
1
vote
2 answers

Functions-framework won't run in windows command line after installing

Has anyone run into this issue before? I've done pip install --user functions-framework and been told a bunch of requirements are already satisfied. When I then run functions-framework --target=function I get the error 'functions-framework' is not…
bront
  • 43
  • 1
  • 7
1
vote
1 answer

Google Pub/Sub - No event data found from local function after published message to topic

I'm using the Functions Framework with Python alongside Google Cloud Pub/Sub Emulator. I'm having issues with an event triggered from a published message to a topic, where there's no event data found for the function. See more details below. Start…
1
vote
1 answer

Firebase Cloud Functions - debug with VSC

I have a node project created with Vue using Firebase Hosting, Cloud Functions and Firestore. I can deploy locally with npm run build | firebase serve. In the Vue app I'm calling a Cloud Function with…
0
votes
1 answer

Cloud Function deployment does not respect Symbolic Linking

As the design specification makes clear, the source directories of Google Cloud Functions are expected to include main.py, requirements.txt, and __init__.py. Additional local dependencies (i.e., code) may be specified so long as their imports are…
0
votes
0 answers

How to control the build steps google's functions framework locally before publishing to cloud build and cloud functions

i am trying to use google's functions framework to develop a typescript based http function. My project also uses a private NPM repository. Generally when we deploy a cloud function with functions framework i see that they take the source code as…
AnandShiva
  • 906
  • 11
  • 22
1
2