← Back
Modal SDK 1.3.3 adds billing reports, async warnings, and object ID methods
· releasefeatureapibugfix · modal.com ↗

New Features

Billing Reports: Modal has promoted the modal.billing.workspace_billing_report API to General Availability and introduced a new modal billing report CLI command. This feature is available to all Team and Enterprise plan workspaces, enabling better cost tracking and visibility.

Object ID Methods: Two new convenience methods simplify referencing existing Modal objects:

  • modal.Queue.from_id() - reference a Queue by its object id
  • modal.Dict.from_id() - reference a Dict by its object id

Breaking Changes & Warnings

Async Usage Warnings Enabled by Default: Modal's async context warnings are now enabled by default. These warnings fire when using blocking interfaces on Modal objects within async contexts—a pattern that can cause performance issues or bugs. The warnings include detailed, actionable suggestions for remediation.

To disable these warnings, set either:

  • Environment variable: MODAL_ASYNC_WARNINGS=0
  • Config file: async_warnings = false in .modal.toml

Modal recommends addressing warnings as they often indicate significant performance issues, but acknowledges they may occasionally be false positives. Users are encouraged to report any incorrect suggestions.

Bug Fixes

ASGI State Leak: Fixed a bug where the ASGI scope's state contents could leak between requests when using @modal.asgi_app. This ensures proper isolation of request state in asynchronous web applications.

Upgrade Notes

Review any async usage in your codebase for warnings and follow the provided remediation guidance. The warnings are verbose but intentionally designed to guide developers toward best practices.