Azure / Azure/apiops-cli

Docs example says products are auto-included transitively, but they aren't extracted with `products: []`

オープン 初心者向け
#277 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る
type:question
主要言語
TypeScript
スター
26
フォーク
9
平均マージ
1日 3時間
マージ済み PR(30日)
20

説明

### Question

The[filtering guide](https://github.com/Azure/apiops-cli/blob/b327e6382385f530784f93f646f9b550eba6fe25/docs/guides/filtering-resources.md) has this example under "Transitive Dependency Behavior":

```yaml
apis:
- petstore-api
```

> And petstore-api is assigned to:
> - Product starter → auto-included
> - Tag production → auto-included
>
> The extract output includes all of these, even though only apiNames was specified in the filter.

I set up a filter based on the "How To: Extract Just One API" section on the same page, which lists only version sets, backends, named values, policy fragments, and tags as auto-included when their keys are set to `[]`, and does not mention products:

```yaml
apis:
- my-api-1
- my-api-2
backends: []
namedValues: []
products: []
tags: []
versionSets: []
loggers: []
diagnostics: []
groups: []
policyFragments: []
gateways: []
schemas: []
subscriptions: []
policies: []
policyRestrictions: []
documentations: []
workspaces: []
```

After running `apiops extract` with this filter, the `products` folder is empty. I confirmed directly against the APIM instance that both APIs are still assigned to their respective products, so the association exists and just isn't showing up in the extract output.

Did I misunderstand something about how the filter or `--filter`/transitive resolution is supposed to work here, or is the "Products containing the API" line in the Transitive Dependency Behavior example not accurate for the current release?

### Context

`@azure-tools/apiops-cli` version `1.0.1`. Filter file only sets `apis:` with two explicit API names and `products: []`, no `--no-transitive` flag passed to `apiops extract`.

コントリビューションガイド

コントリビューションガイドを開く

調査の方向性

Read docs/guides/filtering-resources.md, especially the “Transitive Dependency Behavior” and “How To: Extract Just One API” sections. Reproduce the issue with apiops extract, version 1.0.1, and the filter shown; done means the documentation accurately describes whether products are included when products: [] is set.

索引モデルが issue の本文から書いたものです。

評価

技術スタック
azure
領域
cli, documentation
issue の種類
ドキュメント
難易度
2/5
見積もり時間
1〜3時間
活発さ
活発
明瞭さ
おおむね明確
初心者へのやさしさ
76/100

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。