#480 — [Bug]: UnboundLocalError: cannot access local variable ‘mutable_bas’

Repo: Twill-AI/facade State: closed | Status: done Assignee: Unassigned

Created: 2025-08-12 · Updated: 2025-09-15

Description

Steps to reproduce

  1. In staging open OpenAPI UI and login under any partner
  2. Call “update merchant” API for 67b7cead-224f-4a04-b603-c9579510b5f0 (with unclear yet payload).

Expected behavior

Successfully updated merchant.

Actual behavior

500 status code in response with “detail” content and logs:

2025-08-11 20:13:05.538|ERROR|master|endpoint_helpers:80|PUT http://staging.twillai.com/api/v1/partner/merchants/a12e63ed-59a2-45f8-9705-e808f3428678 raised builtins.UnboundLocalError: cannot access local variable 'mutable_bas' where it is not associated with a value

Implementation details

[full logs link](https://portal.azure.com#@ca84ad29-936a-41a9-a523-35c3760c1302/blade/Microsoft_OperationsManagementSuite_Workspace/Logs.ReactView/resourceId/%2Fsubscriptions%2F9fada0e8-ad9d-4af4-ae3e-c50dadb7296c%2Fresourcegroups%2Frg-staging-twill-eastus%2Fproviders%2Fmicrosoft.operationalinsights%2Fworkspaces%2Fworkspacergstagingtwilleastusad9c/source/LogsBlade.AnalyticsShareLinkToQuery/q/H4sIAAAAAAAAA2WOTUvDQBCG7%252FkV454NzaXHPUgQaakWQtFjGbLjdnQzG3bWBsEf7zbWWnAOc3i%252FeNooGVko3Y1jG0VjoE30um831RdMB0oE7VXkCQfaK1gLpsdaM3oWX%252BeJQ6hfsUdHNaHmDzXVYvE7UAZL54AK5r7rtp0BFHdWb2Z5JUcM7CAmmFIUHz5B2Qs5WL%252FsIMd3ElN4xhTfqM8VlNvxQPb0HqigYSZ3O%252BtnSPuf%252Bsd%252FpqQc5c9fDegv7kW1HR35FLzuPpJqCdsZvfAEHjjDsmmab6rOyBFHAQAA/timespan/2025-08-11T20%3A11%3A03.000Z%2F2025-08-11T20%3A11

Notes

Add implementation notes, blockers, and context here

Add wikilinks to related people, meetings, or other tickets