Skip to content

Commit

Permalink
python link verification (#12543)
Browse files Browse the repository at this point in the history
* python link verification

* fix the path

* fix cognitive services links

* fix link

* fix swagger links

* fix doc links and remove deprecated ones

* identity changelog update

* remove non existing link

* fix azure links

* cosmos readme link

* remove samples link

* remove samples link

* remove samples link

* fix links

* fix broken links

* fix broken links

* fix broken links

* fix links

* fix links

* python sdk link update

* python sdk link update

* fix spacing in parameter

* update python release link

* remove identity links

* azure-sdk-release link

* Update sdk/servicebus/azure-servicebus/CHANGELOG.md

* Update tools/azure-devtools/doc/scenario_base_tests.md

* Update tools/azure-devtools/doc/scenario_base_tests.md

* Update sdk/keyvault/azure-keyvault-certificates/CHANGELOG.md

Co-authored-by: Charles Lowell <chlowe@microsoft.com>

* Update sdk/keyvault/azure-keyvault-secrets/CHANGELOG.md

Co-authored-by: Charles Lowell <chlowe@microsoft.com>

* Update sdk/keyvault/azure-keyvault-keys/CHANGELOG.md

Co-authored-by: Charles Lowell <chlowe@microsoft.com>

* Update sdk/keyvault/azure-keyvault-keys/CHANGELOG.md

Co-authored-by: Charles Lowell <chlowe@microsoft.com>

* Update sdk/identity/azure-identity/CHANGELOG.md

Co-authored-by: Charles Lowell <chlowe@microsoft.com>

* Update sdk/keyvault/azure-keyvault-secrets/CHANGELOG.md

Co-authored-by: Charles Lowell <chlowe@microsoft.com>

* remove orphan for details sentences

Co-authored-by: Charles Lowell <chlowe@microsoft.com>
  • Loading branch information
KarishmaGhiya and chlowell authored Jul 24, 2020
1 parent bc856aa commit 22be12d
Show file tree
Hide file tree
Showing 168 changed files with 207 additions and 279 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ Management libraries can be identified by namespaces that start with `azure-mgmt
## Need help?

* For detailed documentation visit our [Azure SDK for Python documentation](https://aka.ms/python-docs)
* File an issue via [Github Issues](../../issues)
* File an issue via [Github Issues](https://github.com/Azure/azure-sdk-for-python/issues)
* Check [previous questions](https://stackoverflow.com/questions/tagged/azure+python) or ask new ones on StackOverflow using `azure` and `python` tags.

### Community
Expand Down
4 changes: 2 additions & 2 deletions doc/dev/mgmt/swagger/multi_api/readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ This is the AutoRest configuration file for Network.

## Getting Started

To build the SDK for Network, simply [Install AutoRest](https://aka.ms/autorest/install) and in this folder, run:
To build the SDK for Network, simply [Install AutoRest](https://github.com/Azure/autorest/blob/master/docs/installing-autorest.md) and in this folder, run:

> `autorest`
Expand Down Expand Up @@ -66,4 +66,4 @@ swagger-to-sdk:

## Python

See configuration in [readme.python.md](./readme.python.md)
See configuration in [readme.python.md](https://github.com/Azure/azure-sdk-for-python/blob/master/doc/dev/mgmt/swagger/multi_api/readme.python.md)
2 changes: 1 addition & 1 deletion doc/dev/mgmt/swagger/single_api/readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ This is the AutoRest configuration file for Cdn.

---
## Getting Started
To build the SDK for Cdn, simply [Install AutoRest](https://aka.ms/autorest/install) and in this folder, run:
To build the SDK for Cdn, simply [Install AutoRest](https://github.com/Azure/autorest/blob/master/docs/installing-autorest.md) and in this folder, run:

> `autorest`
Expand Down
20 changes: 10 additions & 10 deletions doc/dev/mgmt/swagger_conf.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,38 +18,38 @@ Writing the readme is the responsibility of the Python SDK team. There is curren
- Readme that handles only one API version, and generates packages that handle one API version only
- Readme that handles several API versions, and generates packages with multiples API and profile supports

These templates can be found in the [single_api](./single_api) and the [multi_api](./multi_api) folders.
These templates can be found in the [single_api](https://github.com/Azure/azure-sdk-for-python/blob/master/doc/dev/mgmt/swagger/single_api) and the [multi_api](https://github.com/Azure/azure-sdk-for-python/blob/master/doc/dev/mgmt/swagger/multi_api) folders.


### Single API readmes

This one is the most simple:
- Copy the [readme.python.md](./single_api/readme.python.md) and replace `servicetoreplace` by your service name
- Be sure the main [readme.md](./single_api/readme.md) contains a "swagger-to-sdk" section with Python
- Copy the [readme.python.md](https://github.com/Azure/azure-sdk-for-python/blob/master/doc/dev/mgmt/swagger/single_api/readme.python.md) and replace `servicetoreplace` by your service name
- Be sure the main [readme.md](https://github.com/Azure/azure-sdk-for-python/blob/master/doc/dev/mgmt/swagger/single_api/readme.md) contains a "swagger-to-sdk" section with Python

### Multi API readmes

When doing multi-api packages, it means you have shipping several "tags" of the main readme as one package. Autorest is calling this process a "batch" call, and this is the purpose of the "batch" section in [readme.python.md](./multi_api/readme.python.md).
When doing multi-api packages, it means you have shipping several "tags" of the main readme as one package. Autorest is calling this process a "batch" call, and this is the purpose of the "batch" section in [readme.python.md](https://github.com/Azure/azure-sdk-for-python/blob/master/doc/dev/mgmt/swagger/multi_api/readme.python.md).

In order to be sure the correct tags exist, you can use the following script:
```shell
python ./scripts/multi_api_readme_help.py /azure-rest-api-specs/specification/service/resource-manager/
```

This script will analyze the Swaggers available, and suggests on stdout:
- A list of tags for the main [readme.md](./multi_api/readme.md)
- A batch declaration for the [readme.python.md](./multi_api/readme.python.md)
- A list of tags for the main [readme.md](https://github.com/Azure/azure-sdk-for-python/blob/master/doc/dev/mgmt/swagger/multi_api/readme.md)
- A batch declaration for the [readme.python.md](https://github.com/Azure/azure-sdk-for-python/blob/master/doc/dev/mgmt/swagger/multi_api/readme.python.md)

This script is not perfect that it *does* require manual review of the output and not a direct copy/paste.

It's important for Python that tags represents only *ONE* unique API version. It's why it's pretty common that Python uses a set of tags that other languages don't use.

Once you know the list of tags you need to generate:

- Copy the [readme.python.md](./multi_api/readme.python.md) and replace `servicetoreplace` by your service name
- Update the batch list of [readme.python.md](./multi_api/readme.python.md)
- Be sure you have one tag section for each batch entry in [readme.python.md](./multi_api/readme.python.md)
- Be sure the main [readme.md](./multi_api/readme.md) contains a "swagger-to-sdk" section with Python with an `afterscripts` section like the one in the template.
- Copy the [readme.python.md](https://github.com/Azure/azure-sdk-for-python/blob/master/doc/dev/mgmt/swagger/multi_api/readme.python.md) and replace `servicetoreplace` by your service name
- Update the batch list of [readme.python.md](https://github.com/Azure/azure-sdk-for-python/blob/master/doc/dev/mgmt/swagger/multi_api/readme.python.md)
- Be sure you have one tag section for each batch entry in [readme.python.md](https://github.com/Azure/azure-sdk-for-python/blob/master/doc/dev/mgmt/swagger/multi_api/readme.python.md)
- Be sure the main [readme.md](https://github.com/Azure/azure-sdk-for-python/blob/master/doc/dev/mgmt/swagger/multi_api/readme.md) contains a "swagger-to-sdk" section with Python with an `afterscripts` section like the one in the template.

The `afterscripts` will execute a Jinja template to create a client to link together all the batch generated autorest ([example](https://github.com/Azure/azure-sdk-for-python/blob/4a7c67189591b052fe2b5769847ff68f7845386d/sdk/storage/azure-mgmt-storage/azure/mgmt/storage/_storage_management_client.py))

Expand Down
1 change: 1 addition & 0 deletions eng/ignore-links.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
https://docs.microsoft.com/python/api/overview/azure/{{package_doc_id}}
4 changes: 4 additions & 0 deletions eng/pipelines/aggregate-reports.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,10 @@ jobs:
vmImage: 'windows-2019'

steps:
- template: ../common/pipelines/templates/steps/verify-links.yml
parameters:
Directory: ""

- template: ./templates/steps/analyze.yml

- task: AzureFileCopy@2
Expand Down
4 changes: 4 additions & 0 deletions eng/pipelines/templates/jobs/archetype-sdk-client.yml
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,10 @@ jobs:
vmImage: 'ubuntu-18.04'

steps:
- template: ../../../common/pipelines/templates/steps/verify-links.yml
parameters:
Directory: "sdk/${{ parameters.ServiceDirectory }}"

- template: ../steps/analyze.yml
parameters:
ServiceDirectory: ${{ parameters.ServiceDirectory }}
Expand Down
2 changes: 1 addition & 1 deletion sdk/advisor/azure-mgmt-advisor/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

This is the Microsoft Azure Advisor Client Library.
This package has been tested with Python 2.7, 3.5, 3.6, 3.7 and 3.8.
For a more complete view of Azure libraries, see the [Github repo](https://github.com/Azure/azure-sdk-for-python/)
For a more complete view of Azure libraries, see the [azure sdk python release](https://aka.ms/azsdk/python/all).


# Usage
Expand Down
2 changes: 1 addition & 1 deletion sdk/aks/azure-mgmt-devspaces/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ For the older Azure Service Management (ASM) libraries, see
library.

For a more complete set of Azure libraries, see the
[azure](https://pypi.python.org/pypi/azure) bundle package.
[azure sdk python release](https://aka.ms/azsdk/python/all).

## Usage

Expand Down
2 changes: 1 addition & 1 deletion sdk/alertsmanagement/azure-mgmt-alertsmanagement/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

This is the Microsoft Azure Alerts Management Client Library.
This package has been tested with Python 2.7, 3.5, 3.6, 3.7 and 3.8.
For a more complete view of Azure libraries, see the [Github repo](https://github.com/Azure/azure-sdk-for-python/)
For a more complete view of Azure libraries, see the [azure sdk python release](https://aka.ms/azsdk/python/all).


# Usage
Expand Down
2 changes: 1 addition & 1 deletion sdk/apimanagement/azure-mgmt-apimanagement/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

This is the Microsoft Azure API Management Client Library.
This package has been tested with Python 2.7, 3.5, 3.6, 3.7 and 3.8.
For a more complete view of Azure libraries, see the [Github repo](https://github.com/Azure/azure-sdk-for-python/)
For a more complete view of Azure libraries, see the [azure sdk python release](https://aka.ms/azsdk/python/all).


# Usage
Expand Down
2 changes: 1 addition & 1 deletion sdk/appconfiguration/azure-mgmt-appconfiguration/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

This is the Microsoft Azure App Configuration Management Client Library.
This package has been tested with Python 2.7, 3.5, 3.6, 3.7 and 3.8.
For a more complete view of Azure libraries, see the [Github repo](https://github.com/Azure/azure-sdk-for-python/)
For a more complete view of Azure libraries, see the [azure sdk python release](https://aka.ms/azsdk/python/all).


# Usage
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ For the older Azure Service Management (ASM) libraries, see
library.

For a more complete set of Azure libraries, see the
[azure](https://pypi.python.org/pypi/azure) bundle package.
[azure sdk python release](https://aka.ms/azsdk/python/all).

## Compatibility

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ For the older Azure Service Management (ASM) libraries, see
library.

For a more complete set of Azure libraries, see the
[azure](https://pypi.python.org/pypi/azure) bundle package.
[azure sdk python release](https://aka.ms/azsdk/python/all).

## Usage

Expand Down
2 changes: 1 addition & 1 deletion sdk/appplatform/azure-mgmt-appplatform/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

This is the Microsoft Azure MyService Management Client Library.
This package has been tested with Python 2.7, 3.5, 3.6, 3.7 and 3.8.
For a more complete view of Azure libraries, see the [Github repo](https://github.com/Azure/azure-sdk-for-python/)
For a more complete view of Azure libraries, see the [azure sdk python release](https://aka.ms/azsdk/python/all).


# Usage
Expand Down
2 changes: 1 addition & 1 deletion sdk/appservice/azure-mgmt-web/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

This is the Microsoft Azure Web Apps Management Client Library.
This package has been tested with Python 2.7, 3.5, 3.6, 3.7 and 3.8.
For a more complete view of Azure libraries, see the [Github repo](https://github.com/Azure/azure-sdk-for-python/)
For a more complete view of Azure libraries, see the [azure sdk python release](https://aka.ms/azsdk/python/all).


# Usage
Expand Down
2 changes: 1 addition & 1 deletion sdk/attestation/azure-mgmt-attestation/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

This is the Microsoft Azure MyService Management Client Library.
This package has been tested with Python 2.7, 3.5, 3.6, 3.7 and 3.8.
For a more complete view of Azure libraries, see the [Github repo](https://github.com/Azure/azure-sdk-for-python/)
For a more complete view of Azure libraries, see the [azure sdk python release](https://aka.ms/azsdk/python/all).


# Usage
Expand Down
2 changes: 1 addition & 1 deletion sdk/authorization/azure-mgmt-authorization/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ For the older Azure Service Management (ASM) libraries, see
library.

For a more complete set of Azure libraries, see the
[azure](https://pypi.python.org/pypi/azure) bundle package.
[azure sdk python release](https://aka.ms/azsdk/python/all).

## Usage

Expand Down
2 changes: 1 addition & 1 deletion sdk/automation/azure-mgmt-automation/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ For the older Azure Service Management (ASM) libraries, see
library.

For a more complete set of Azure libraries, see the
[azure](https://pypi.python.org/pypi/azure) bundle package.
[azure sdk python release](https://aka.ms/azsdk/python/all).

## Usage

Expand Down
8 changes: 1 addition & 7 deletions sdk/azurestack/azure-mgmt-azurestack/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,7 @@ For the older Azure Service Management (ASM) libraries, see
library.

For a more complete set of Azure libraries, see the
[azure](https://pypi.python.org/pypi/azure) bundle package.

## Usage

For code examples, see [AzureStack
Management](https://docs.microsoft.com/python/api/overview/azure/azurestack)
on docs.microsoft.com.
[azure sdk python release](https://aka.ms/azsdk/python/all).

## Provide Feedback

Expand Down
2 changes: 1 addition & 1 deletion sdk/batch/azure-mgmt-batch/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ For the older Azure Service Management (ASM) libraries, see
library.

For a more complete set of Azure libraries, see the
[azure](https://pypi.python.org/pypi/azure) bundle package.
[azure sdk python release](https://aka.ms/azsdk/python/all).

## Usage

Expand Down
2 changes: 1 addition & 1 deletion sdk/billing/azure-mgmt-billing/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ For the older Azure Service Management (ASM) libraries, see
library.

For a more complete set of Azure libraries, see the
[azure](https://pypi.python.org/pypi/azure) bundle package.
[azure sdk python release](https://aka.ms/azsdk/python/all).

## Usage

Expand Down
2 changes: 1 addition & 1 deletion sdk/botservice/azure-mgmt-botservice/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ For the older Azure Service Management (ASM) libraries, see
library.

For a more complete set of Azure libraries, see the
[azure](https://pypi.python.org/pypi/azure) bundle package.
[azure sdk python release](https://aka.ms/azsdk/python/all).

## Usage

Expand Down
2 changes: 1 addition & 1 deletion sdk/cdn/azure-mgmt-cdn/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ For the older Azure Service Management (ASM) libraries, see
library.

For a more complete set of Azure libraries, see the
[azure](https://pypi.python.org/pypi/azure) bundle package.
[azure sdk python release](https://aka.ms/azsdk/python/all).

## Usage

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,9 @@

This is the Microsoft Azure Cognitive Services Anomaly Detector Client Library.
This package has been tested with Python 2.7, 3.5, 3.6, 3.7 and 3.8.
For a more complete view of Azure libraries, see the [Github repo](https://github.com/Azure/azure-sdk-for-python/)

For a more complete set of Azure libraries, see the
[azure sdk python release](https://aka.ms/azsdk/python/all).

# Usage

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ Library.
This package has been tested with Python 2.7, 3.4, 3.5, 3.6 and 3.7.

For a more complete set of Azure libraries, see the
[azure](https://pypi.python.org/pypi/azure) bundle package.
[azure sdk python release](https://aka.ms/azsdk/python/all).

## Usage

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,6 @@ It provides the necessary files for other packages to extend the
azure.cognitiveservices.knowledge namespace.

If you are looking to install the Azure client libraries, see the
[azure](https://pypi.python.org/pypi/azure) bundle package.
[azure sdk python release](https://aka.ms/azsdk/python/all).

![image](https://azure-sdk-impressions.azurewebsites.net/api/impressions/azure-sdk-for-python%2Fazure-cognitiveservices-knowledge-nspkg%2FREADME.png)
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

This is the Microsoft Azure QnA Maker Client Library.
This package has been tested with Python 2.7, 3.5, 3.6, 3.7 and 3.8.
For a more complete view of Azure libraries, see the [Github repo](https://github.com/Azure/azure-sdk-for-python/)
For a more complete view of Azure libraries, see the [azure sdk python release](https://aka.ms/azsdk/python/all).


# Usage
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

This is the Microsoft Azure Cognitive Services LUIS Client Library.
This package has been tested with Python 2.7, 3.5, 3.6, 3.7 and 3.8.
For a more complete view of Azure libraries, see the [Github repo](https://github.com/Azure/azure-sdk-for-python/)
For a more complete view of Azure libraries, see the [azure sdk python release](https://aka.ms/azsdk/python/all).


# Usage
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,6 @@ It provides the necessary files for other packages to extend the
azure.cognitiveservices.language namespace.

If you are looking to install the Azure client libraries, see the
[azure](https://pypi.python.org/pypi/azure) bundle package.
[azure sdk python release](https://aka.ms/azsdk/python/all).

![image](https://azure-sdk-impressions.azurewebsites.net/api/impressions/azure-sdk-for-python%2Fazure-cognitiveservices-language-nspkg%2FREADME.png)
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ Library.
This package has been tested with Python 2.7, 3.5, 3.6, 3.7 and 3.8.

For a more complete set of Azure libraries, see the
[azure](https://pypi.python.org/pypi/azure) bundle package.
[azure sdk python release](https://aka.ms/azsdk/python/all).

## Usage

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ Library.
This package has been tested with Python 2.7, 3.5, 3.6 and 3.7.

For a more complete set of Azure libraries, see the
[azure](https://pypi.python.org/pypi/azure) bundle package.
[azure sdk python release](https://aka.ms/azsdk/python/all).

## Usage

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,6 @@ It provides the necessary files for other packages to extend the
azure.cognitiveservices namespace.

If you are looking to install the Azure client libraries, see the
[azure](https://pypi.python.org/pypi/azure) bundle package.
[azure sdk python release](https://aka.ms/azsdk/python/all).

![image](https://azure-sdk-impressions.azurewebsites.net/api/impressions/azure-sdk-for-python%2Fazure-cognitiveservices-nspkg%2FREADME.png)
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ This is the Microsoft Azure Personalizer Client Library.
This package has been tested with Python 2.7, 3.4, 3.5, 3.6 and 3.7.

For a more complete set of Azure libraries, see the
[azure](https://pypi.python.org/pypi/azure) bundle package.
[azure sdk python release](https://aka.ms/azsdk/python/all).

## What is Personalizer?

Expand All @@ -17,7 +17,7 @@ For a more complete set of Azure libraries, see the
## Usage

[Quickstart: Personalize client library for
Python](https://docs.microsoft.com/azure/cognitive-services/personalizer/python-quickstart-commandline-feedback-loop)
Python](https://docs.microsoft.com/azure/cognitive-services/personalizer/sdk-learning-loop?pivots=programming-language-python)

## Documentation

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ This is the Microsoft Azure Auto Suggest Client Library.
This package has been tested with Python 2.7, 3.5, 3.6, 3.7 and 3.8.

For a more complete set of Azure libraries, see the
[azure](https://pypi.python.org/pypi/azure) bundle package.
[azure sdk python release](https://aka.ms/azsdk/python/all).

## Usage

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ Client Library.
This package has been tested with Python 2.7, 3.5, 3.6, 3.7 and 3.8.

For a more complete set of Azure libraries, see the
[azure](https://pypi.python.org/pypi/azure) bundle package.
[azure sdk python release](https://aka.ms/azsdk/python/all).

## Usage

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ Library.
This package has been tested with Python 2.7, 3.5, 3.6, 3.7 and 3.8.

For a more complete set of Azure libraries, see the
[azure](https://pypi.python.org/pypi/azure) bundle package.
[azure sdk python release](https://aka.ms/azsdk/python/all).

## Usage

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ Library.
This package has been tested with Python 2.7, 3.5, 3.6, 3.7 and 3.8.

For a more complete set of Azure libraries, see the
[azure](https://pypi.python.org/pypi/azure) bundle package.
[azure sdk python release](https://aka.ms/azsdk/python/all).

## Usage

Expand Down
Loading

0 comments on commit 22be12d

Please sign in to comment.