Merge pull request #1051 from paulyuk/paulyuk/1.13.5-fixes

Fixes Python test failure on Configuration API quickstart
This commit is contained in:
Paul Yuknewicz 2024-07-09 07:52:55 -07:00 committed by GitHub
commit 915bc3edce
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 3 additions and 6 deletions

View File

@ -47,7 +47,7 @@ pip3 install -r requirements.txt
<!-- STEP
name: Run order-processor service
expected_stdout_lines:
- '== APP == Configuration for orderId2 : value: "102"'
- '== APP == Configuration for orderId2 : 102'
- '== APP == Subscription ID is'
expected_stderr_lines:
output_match_mode: substring

View File

@ -15,11 +15,11 @@ with DaprClient() as client:
# Get config items from the config store
for key in CONFIGURATION_KEYS:
resp = client.get_configuration(store_name=DAPR_CONFIGURATION_STORE, keys=[key], config_metadata={})
print(f"Configuration for {key} : {resp.items[key]}", flush=True)
print(f"Configuration for {key} : {resp.items[key].value}", flush=True)
def handler(id: str, resp: ConfigurationResponse):
for key in resp.items:
print("Configuration update {'"+key+"' : {'value': '"+ resp.items[key].value +"'}}", flush=True)
print(f"Configuration update {key} : {resp.items[key].value}", flush=True)
async def subscribe_config():
@ -38,6 +38,3 @@ async def subscribe_config():
print("Error unsubscribing from config updates", flush=True)
asyncio.run(subscribe_config())