WebSiteManagementClient.web_apps.list_by_resource_group (and az webapp list) silently under-reports results on resource groups with 100+ App Services
メンテナーはふだん 1 日以内に返信
@msyyc がすでに取り組んでいます。
2026年9月17日 から。
評価
- 難易度
- 4/5
- 見積もり時間
- 3〜5日
- 初心者へのやさしさ
- 45/100
調査の方向性
まず、WebSiteManagementClient.web_apps.list_by_resource_group() と az webapp list で不一致を再現し、次に同じリソース グループに対する az resource list と件数を比較します。Microsoft.Web/sites の一覧取得とページングの動作を調査します。SDK と CLI の両方が、サイレントに切り詰めることなく、存在するすべての App Services を返せば完了です。
索引モデルが issue の本文から書いたものです。
説明
Package Name: azure-mgmt-web
Package Version: 11.0.0
Operating System: Windows 11
Python Version: 3.13
Describe the bug
WebSiteManagementClient.web_apps.list_by_resource_group() silently under-reports results on a resource group with 100+ App Services, returning only 32 of 101 existing resources with no error, exception, or indication that results were truncated. The Azure CLI command az webapp list (against the same resource group, same identity) exhibits the identical behavior, suggesting both share the same underlying listing logic. Azure Resource Graph and az resource list, queried against the same resource group, correctly return all 101.
To Reproduce
Steps to reproduce the behavior:
-
az resource list -g <resource-group> --resource-type Microsoft.Web/sites --query "length(@)" -
az resource list -g <resource-group> --resource-type Microsoft.Web/sites --query "[].kind" -o tsv | sort | uniq - c - returns all the resources count
Code which is not working:
from azure.identity import DefaultAzureCredential
from azure.mgmt.web import WebSiteManagementClient
credential = DefaultAzureCredential()
client = WebSiteManagementClient(credential, subscription_id="")
apps = list(client.web_apps.list_by_resource_group(""))
print(len(apps))
Expected behavior
list_by_resource_group() should return all App Services in the resource group, matching the count returned by Azure Resource Graph (Resources | where type =~ 'microsoft.web/sites' | where resourceGroup =~ 'bic-web-apps-rg') and az resource list --resource-type Microsoft.Web/sites, both of which correctly.
Additional context
Ruled out RBAC/permission scoping: same identity used for the CLI, the SDK, the Azure portal, and Resource Graph
Ruled out kind-based filtering (e.g. Function Apps or Logic Apps Standard being excluded from web-app-specific listings):
Workaround in use: querying Azure Resource Graph directly (bypassing list_by_resource_group entirely) returns the correct, complete count.
Suspected root cause: a pagination/continuation-token handling issue specific to the Microsoft.Web/sites list endpoint, shared by both the CLI and the Python SDK.
If this doesn't reproduce on a freshly created test resource group, it may be specific to something about our subscription or data rather than a universal SDK bug —
happy to open an Azure Support case and share the x-ms-correlation-request-id / x-ms-request-id from a failing call (visible via az webapp list --debug) so the request can be traced server-side without needing access to our environment.
- 主要言語
- Python
- スター
- 5.6k
- フォーク
- 3.4k
- 平均マージ
- 1日 22時間
- マージ済み PR(30日)
- 189
環境構築
このプロジェクトの開発コンテナを、あなたの GitHub アカウントでブラウザ上に起動します。
- Dockerfile・Docker Compose ファイルなし
- プルリクエストのテンプレートあり
- コントリビューションガイドを読む
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
Azure/azure-sdk-for-python のほかの issue
-
needs-triage
難易度 1/5 1時間未満 初心者へのやさしさ 85/100
Azure/azure-sdk-for-python#50155 · リアクション 1 件 ·
メンテナーはふだん 1 日以内に返信
-
[Teams Chatbot]: next-mypy install 404s should point to CFS auth or --pypi workaround対応中かも @jianingwang123 が 17 日前に担当しました。 オープンneeds-triage
難易度 1/5 1〜3時間 初心者へのやさしさ 72/100
Azure/azure-sdk-for-python#49886 · コメント 1 件 · リアクション 2 件 · 担当者 2 名 ·
メンテナーはふだん 1 日以内に返信
-
[AI Projects] AIProjectInstrumentor: non-streamed responses.create raises AttributeError ('NonRecordingSpan' object has no attribute 'attributes') when the span is not sampled対応中かも @14H034160212 が 19 日前に担当しました。 オープンAI Projects Client customer-reported question
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
Azure/azure-sdk-for-python#49854 · コメント 2 件 · リアクション 1 件 ·
メンテナーはふだん 1 日以内に返信
-
azure-eventhub migration guide: legacy checkpoint sample writes "None" metadata for partitions that were never checkpointed対応中かも @hidingmyname が 27 日前に担当しました。 オープンClient customer-reported Event Hubs needs-team-attention question Service Attention
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
Azure/azure-sdk-for-python#49723 · コメント 2 件 · リアクション 1 件 ·
メンテナーはふだん 1 日以内に返信
-
Scheduled test pipelines fail at the Analyze_Test stage due to date formatting対応中かも このイシューにリンクされたプルリクエストがオープン中、またはマージ済みです。 オープンEngSys
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
Azure/azure-sdk-for-python#49614 · コメント 1 件 · リアクション 1 件 ·
メンテナーはふだん 1 日以内に返信
Azure/azure-sdk-for-python の issue をすべて見る
似ている issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 72/100
vllm-project/vllm#70030 ·
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
TigreGotico/tugaphone#408 ·
メンテナーはふだん 1 日以内に返信
-
needs-triage
難易度 2/5 1〜3時間 初心者へのやさしさ 74/100
gke-labs/kube-agents#7308 ·
メンテナーはふだん 1 日以内に返信
-
t: bug
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
メンテナーはふだん 3 日以内に返信
-
chore
難易度 1/5 1〜3時間 初心者へのやさしさ 88/100
lugassawan/swe-workbench#841 ·