From 6fc69d95fb41793eef937aa9cccfd1102f0d36da Mon Sep 17 00:00:00 2001 From: tetiana-karasova Date: Tue, 1 Mar 2022 17:43:28 +0100 Subject: [PATCH 1/2] feat: fix create bucket for user events --- .../events/setup_events/events_create_gcs_bucket.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/samples/interactive-tutorials/events/setup_events/events_create_gcs_bucket.py b/samples/interactive-tutorials/events/setup_events/events_create_gcs_bucket.py index 00ff31a8..ea06b7eb 100644 --- a/samples/interactive-tutorials/events/setup_events/events_create_gcs_bucket.py +++ b/samples/interactive-tutorials/events/setup_events/events_create_gcs_bucket.py @@ -21,7 +21,7 @@ project_id = google.auth.default()[1] timestamp_ = datetime.datetime.now().timestamp().__round__() -bucket_name = os.environ["EVENTS_BUCKET_NAME"] +bucket_name = "{}_events_{}".format(project_id, timestamp_) create_bucket(bucket_name) upload_blob(bucket_name, "../resources/user_events.json") From d6f631b64f267b0867b5b850277db4c384e1cd79 Mon Sep 17 00:00:00 2001 From: tetiana-karasova Date: Thu, 3 Mar 2022 15:28:32 +0100 Subject: [PATCH 2/2] lint fix --- .../events/setup_events/events_create_gcs_bucket.py | 1 - 1 file changed, 1 deletion(-) diff --git a/samples/interactive-tutorials/events/setup_events/events_create_gcs_bucket.py b/samples/interactive-tutorials/events/setup_events/events_create_gcs_bucket.py index ea06b7eb..0ccf6785 100644 --- a/samples/interactive-tutorials/events/setup_events/events_create_gcs_bucket.py +++ b/samples/interactive-tutorials/events/setup_events/events_create_gcs_bucket.py @@ -13,7 +13,6 @@ # limitations under the License. import datetime -import os import google.auth