-
Notifications
You must be signed in to change notification settings - Fork 3.3k
[Containerapp] Fix #32594: az containerapp compose create: Fix TypeError when docker-compose file include env_file without environment
#32601
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Containerapp] Fix #32594: az containerapp compose create: Fix TypeError when docker-compose file include env_file without environment
#32601
Conversation
️✔️AzureCLI-FullTest
|
|
Hi @Greedygre, |
️✔️AzureCLI-BreakingChangeTest
|
|
Thank you for your contribution! We will review the pull request and get back to you soon. |
|
The git hooks are available for azure-cli and azure-cli-extensions repos. They could help you run required checks before creating the PR. Please sync the latest code with latest dev branch (for azure-cli) or main branch (for azure-cli-extensions). pip install azdev --upgrade
azdev setup -c <your azure-cli repo path> -r <your azure-cli-extensions repo path>
|
This reverts commit 31202c1.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
This PR fixes a TypeError in az containerapp compose create command when a docker-compose file includes env_file without environment. The issue stems from a bug in pycomposefile version 0.0.32 that incorrectly assumes the environment field must exist when env_file is present.
Key Changes:
- Upgraded pycomposefile dependency from version 0.0.32 to 0.0.34 across all platform configurations
Reviewed changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
| src/azure-cli/setup.py | Updated minimum version constraint for pycomposefile from >=0.0.32 to >=0.0.34 |
| src/azure-cli/requirements.py3.windows.txt | Updated pinned pycomposefile version from 0.0.32 to 0.0.34 for Windows |
| src/azure-cli/requirements.py3.Linux.txt | Updated pinned pycomposefile version from 0.0.32 to 0.0.34 for Linux |
| src/azure-cli/requirements.py3.Darwin.txt | Updated pinned pycomposefile version from 0.0.32 to 0.0.34 for macOS |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Related command
az containerapp compose create
Description
Refer issue: #32594
In pycomposefile version <=
0.0.32, there is a bug it assume whenenv_fileexist, environment should exist.Otherwise it throws error
TypeError: 'NoneType' object is not iterablelike following:code in pycomposefile version <=

0.0.32code in pycomposefile version >=

0.0.33, it fix with change:Testing Guide
History Notes
[Component Name 1] BREAKING CHANGE:
az command a: Make some customer-facing breaking change[Component Name 2]
az command b: Add some customer-facing featureThis checklist is used to make sure that common guidelines for a pull request are followed.
The PR title and description has followed the guideline in Submitting Pull Requests.
I adhere to the Command Guidelines.
I adhere to the Error Handling Guidelines.