Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit adabce5

Browse filesBrowse files
weisiAce Nassri
authored andcommitted
Functions: Use documented way to fetch current GCP project ID. (GoogleCloudPlatform#1594)
The document at https://cloud.google.com/functions/docs/env-var suggests using env['GCP_PROJECT'] for current project ID, and env['GCLOUD_PROJECT'] is deprecated.
1 parent e118431 commit adabce5
Copy full SHA for adabce5

File tree

Expand file treeCollapse file tree

2 files changed

+2
-2
lines changed
Filter options
Expand file treeCollapse file tree

2 files changed

+2
-2
lines changed

‎functions/helloworld/sample_pubsub_test_system.py

Copy file name to clipboardExpand all lines: functions/helloworld/sample_pubsub_test_system.py
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
from google.cloud import pubsub_v1
2323
import pytest
2424

25-
PROJECT = getenv('GCLOUD_PROJECT')
25+
PROJECT = getenv('GCP_PROJECT')
2626
TOPIC = getenv('TOPIC')
2727

2828
assert PROJECT is not None

‎functions/helloworld/sample_storage_test_system.py

Copy file name to clipboardExpand all lines: functions/helloworld/sample_storage_test_system.py
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
from google.cloud import storage
2323
import pytest
2424

25-
PROJECT = getenv('GCLOUD_PROJECT')
25+
PROJECT = getenv('GCP_PROJECT')
2626
BUCKET = getenv('BUCKET')
2727

2828
assert PROJECT is not None

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.