From 99a8b415c06b91066125fc7d208dc4ce8378487f Mon Sep 17 00:00:00 2001 From: "gcf-owl-bot[bot]" <78513119+gcf-owl-bot[bot]@users.noreply.github.com> Date: Tue, 21 Jun 2022 10:37:40 -0400 Subject: [PATCH] chore: add prerelease nox session (#281) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * chore(python): add missing import for prerelease testing Source-Link: https://github.com/googleapis/synthtool/commit/d2871d98e1e767d4ad49a557ff979236d64361a1 Post-Processor: gcr.io/cloud-devrel-public-resources/owlbot-python:latest@sha256:b2dc5f80edcf5d4486c39068c9fa11f7f851d9568eea4dcba130f994ea9b5e97 * check samples failure * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md * lint * check samples failure * add 30 seconds to request timestamp Co-authored-by: Owl Bot Co-authored-by: Anthonios Partheniou --- .../interactive-tutorials/product/add_fulfillment_places.py | 6 +++--- .../interactive-tutorials/product/set_inventory.py | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/generated_samples/interactive-tutorials/product/add_fulfillment_places.py b/generated_samples/interactive-tutorials/product/add_fulfillment_places.py index 3f2eb8cd5853..6f9f843a98f9 100644 --- a/generated_samples/interactive-tutorials/product/add_fulfillment_places.py +++ b/generated_samples/interactive-tutorials/product/add_fulfillment_places.py @@ -32,9 +32,6 @@ + product_id ) -# The request timestamp -current_date = datetime.datetime.now() - # add fulfillment request def get_add_fulfillment_request( @@ -70,6 +67,9 @@ def add_fulfillment_places(product_name: str, timestamp, place_id): create_product(product_id) + +# The request timestamp +current_date = datetime.datetime.now() + datetime.timedelta(seconds=30) print(f"------add fulfilment places with current date: {current_date}-----") add_fulfillment_places(product_name, current_date, "store2") get_product(product_name) diff --git a/generated_samples/interactive-tutorials/product/set_inventory.py b/generated_samples/interactive-tutorials/product/set_inventory.py index e4f7ff520606..b0060ffb9f64 100644 --- a/generated_samples/interactive-tutorials/product/set_inventory.py +++ b/generated_samples/interactive-tutorials/product/set_inventory.py @@ -64,7 +64,7 @@ def get_product_with_inventory_info(product_name: str) -> Product: # set inventory request def get_set_inventory_request(product_name: str) -> SetInventoryRequest: # The request timestamp - request_time = datetime.datetime.now() + request_time = datetime.datetime.now() + datetime.timedelta(seconds=30) set_mask = FieldMask( paths=["price_info", "availability", "fulfillment_info", "available_quantity"] )