Skip to content

Commit 1ec8bcc

Browse files
Merge pull request #11 from Azure/master
pulling master updates to fix merge conflict
2 parents 8de385c + a7ef6ad commit 1ec8bcc

File tree

9,272 files changed

+3155095
-1065179
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

9,272 files changed

+3155095
-1065179
lines changed

.github/CODEOWNERS

+59-8
Original file line numberDiff line numberDiff line change
@@ -9,36 +9,87 @@
99
/sdk/ @mayurid @lmazuel
1010

1111
# Core
12-
/sdk/core/ @lmazuel @xiangyan99 @johanste
13-
/sdk/core/azure-core/ @xiangyan99 @bryevdv @lmazuel
12+
# PRLabel: %Azure.Core
13+
/sdk/core/ @lmazuel @xiangyan99 @johanste @rakshith91
14+
/sdk/core/azure-core/ @xiangyan99 @lmazuel
1415

16+
####
1517
# Service team
18+
####
19+
# PRLabel: %Azure.Identity
1620
/sdk/identity/ @chlowell @schaabs
21+
22+
# PRLabel: %Event Hubs
1723
/sdk/eventhub/ @annatisch @yunhaoling @YijunXieMS
18-
/sdk/storage/ @amishra-dev @zezha-msft @annatisch @rakshith91 @xiafu-msft
19-
/sdk/applicationinsights/ @alexeldeib
24+
25+
# PRLabel: %Storage
26+
/sdk/storage/ @amishra-dev @zezha-msft @annatisch @rakshith91 @xiafu-msft
27+
28+
/sdk/applicationinsights/ @alexeldeib
29+
30+
# PRLabel: %Batch
2031
/sdk/batch/ @bgklein @xingwu1
21-
/sdk/cognitiveservices/azure-cognitiveservices-vision-customvision/ @areddish
32+
/sdk/cognitiveservices/azure-cognitiveservices-vision-customvision/ @areddish
33+
34+
# PRLabel: %KeyVault
2235
/sdk/keyvault/ @schaabs @chlowell @iscai-msft
36+
37+
# PRLabel: %Monitor - LogAnalytics
2338
/sdk/loganalytics/ @alexeldeib
39+
40+
# PRLabel: %Consumption
2441
/sdk/consumption/ @sandeepnl
42+
43+
# PRLabel: %Container Instances
2544
/sdk/containerinstance/ @samkreter @xizhamsft
45+
46+
# PRLabel: %Container Registry
2647
/sdk/containerregistry/ @djyou
2748
/sdk/containerservice/ @samkreter @zqingqing1 @GaneshaThirumurthi
28-
/sdk/cosmos/ @shurd
49+
50+
# PRLabel: %Cosmos
51+
/sdk/cosmos/ @southpolesteve @zfoster
52+
53+
# PRLabel: %Data Factory
2954
/sdk/datafactory/ @hvermis
30-
/sdk/datalake/ @ro-joowan
55+
/sdk/datalake/ @ro-joowan
3156
/sdk/datadatamigration/ @vchske
57+
58+
# PRLabel: %Event Grid
3259
/sdk/eventgrid/ @kalyanaj
60+
61+
# PRLabel: %HDInsight
3362
/sdk/hdinsight/ @idear1203
63+
64+
# PRLabel: %Machine Learning Compute
3465
/sdk/machinelearningcompute/ @shutchings
66+
67+
# PRLabel: %Recovery Services
3568
/sdk/recoveryservices/ @DheerendraRathor
69+
70+
# PRLabel: %Search
71+
/sdk/search/ @xiangyan99 @rakshith91
72+
73+
# PRLabel: %Service Fabric
3674
/sdk/servicefabric/ @QingChenmsft @samedder
75+
76+
# PRLabel: %SQL
3777
/sql/sql/ @jaredmoo
78+
79+
# PRLabel: %Service Bus
3880
/sdk/servicebus/ @annatisch @yunhaoling @YijunXieMS @KieranBrantnerMagee
81+
82+
# PRLabel: %Synapse
3983
/sdk/synapse/ @aim-for-better @idear1203
84+
85+
# PRLabel: %Cognitive - Text Analytics
4086
/sdk/textanalytics/ @kristapratico @iscai-msft
41-
/sdk/formrecognizer/ @kristapratico @iscai-msft
87+
88+
# PRLabel: %Cognitive - Form Recognizer
89+
/sdk/formrecognizer/ @kristapratico @iscai-msft @rakshith91
90+
91+
# Smoke Tests
92+
/common/smoketest/ @lmazuel @chlowell @annatisch @rakshith91 @shurd @southpolesteve
4293

4394
# Management Plane
4495
/**/*mgmt*/ @zikalino

.github/ISSUE_TEMPLATE/bug_bash.md

+39
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
---
2+
name: Bug Bash report
3+
about: Create a report about bug bash
4+
title: "[BUG Bash]"
5+
labels: bugbash, Mgmt
6+
assignees: ''
7+
8+
---
9+
10+
**Describe the bug**
11+
A clear and concise description of what the bug is.
12+
13+
***Exception or Stack Trace***
14+
Add the exception log and stack trace if available
15+
16+
**To Reproduce**
17+
Steps to reproduce the behavior:
18+
19+
***Code Snippet***
20+
Add the code snippet that causes the issue.
21+
22+
**Expected behavior**
23+
A clear and concise description of what you expected to happen.
24+
25+
**Screenshots**
26+
If applicable, add screenshots to help explain your problem.
27+
28+
**Setup (please complete the following information):**
29+
- Python Version: [e.g. Python 3.8]
30+
- SDK Version: [e.g. azure-mgmt-resource-15.0.0b1]
31+
32+
**Additional context**
33+
Add any other context about the problem here.
34+
35+
**Information Checklist**
36+
Kindly make sure that you have added all the following information above and checkoff the required fields otherwise we will treat the issuer as an incomplete report
37+
- [ ] Bug Description Added
38+
- [ ] Repro Steps Added
39+
- [ ] Setup information Added

NOTICE.txt

+15-5
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,17 @@
1-
This file list any third-party libraries or other resources that may be
2-
distributed under licenses different than the Azure SDK for Python software.
1+
NOTICES AND INFORMATION
2+
Do Not Translate or Localize
33

4-
In the event that we accidentally failed to list a required notice, please
5-
bring it to our attention by opening an issue.
4+
This software incorporates material from third parties. Microsoft makes certain
5+
open source code available at https://3rdpartysource.microsoft.com, or you may
6+
send a check or money order for US $5.00, including the product name, the open
7+
source component name, and version number, to:
68

7-
The attached notices are provided for information only.
9+
Source Code Compliance Team
10+
Microsoft Corporation
11+
One Microsoft Way
12+
Redmond, WA 98052
13+
USA
14+
15+
Notwithstanding any other terms, you may reverse engineer this software to the
16+
extent required to debug changes to any libraries licensed under the GNU Lesser
17+
General Public License.

README.md

+11-4
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,8 @@ The client libraries are supported on Python 2.7 and 3.5.3 or later.
1919
Each service might have a number of libraries available from each of the following categories:
2020
* [Client - New Releases](#Client-New-Releases)
2121
* [Client - Previous Versions](#Client-Previous-Versions)
22-
* [Management](#Management)
22+
* [Management - New Releases](#Management-New-Releases)
23+
* [Management - Previous Versions](#Management-Previous-Versions)
2324

2425
### Client: New Releases
2526

@@ -33,14 +34,20 @@ You can find the [most up to date list of all of the new packages on our page](h
3334

3435
Last stable versions of packages that have been provided for usage with Azure and are production-ready. These libraries provide you with similar functionalities to the Preview ones as they allow you to use and consume existing resources and interact with them, for example: upload a blob. They might not implement the [guidelines](https://azure.github.io/azure-sdk/python_introduction.html) or have the same feature set as the Novemeber releases. They do however offer wider coverage of services.
3536

36-
### Management
37+
### Management: New Releases
38+
A new set of management libraries that follow the [Azure SDK Design Guidelines for Python](https://azure.github.io/azure-sdk/python/guidelines/) are now in Public Preview. These new libraries provide a number of core capabilities that are shared amongst all Azure SDKs, including the intuitive Azure Identity library, an HTTP Pipeline with custom policies, error-handling, distributed tracing, and much more.
39+
You can find the list of new packages [on this page](https://azure.github.io/azure-sdk/releases/latest/python.html). Documentation and for these new libraries can be found [here](https://azure.github.io/azure-sdk-for-python). Code samples can also be viewed [here](https://docs.microsoft.com/samples/browse/?languages=python&term=Getting%20started%20-%20Managing)
3740

38-
Libraries which enable you to provision specific resources. They are responsible for directly mirroring and consuming Azure service's REST endpoints. The management libraries use the `azure-mgmt-<service name>` convention for their package names.
41+
> NOTE: If you need to ensure your code is ready for production use one of the stable, non-preview libraries.
42+
43+
### Management: Previous Versions
44+
For a complete list of management libraries which enable you to provision and manage Azure resources, please check [here](https://azure.github.io/azure-sdk/releases/latest/all/python.html). They might not have the same feature set as the new releases but they do offer wider coverage of services.
45+
Management libraries can be identified by namespaces that start with `azure-mgmt-`, e.g. `azure-mgmt-compute`
3946

4047
## Need help?
4148

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

4653
### Community

SECURITY.md

+37-4
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,41 @@
1-
# Security Policy
1+
<!-- BEGIN MICROSOFT SECURITY.MD V0.0.5 BLOCK -->
22

3-
## Reporting a Vulnerability
3+
## Security
44

5-
Security issues and bugs should be reported privately, via email, to the Microsoft Security Response Center (MSRC) <[email protected]>. You should receive a response within 24 hours. If for some reason you do not, please follow up via email to ensure we received your original message. Further information, including the MSRC PGP key, can be found in the [Security TechCenter](https://www.microsoft.com/msrc/faqs-report-an-issue).
5+
Microsoft takes the security of our software products and services seriously, which includes all source code repositories managed through our GitHub organizations, which include [Microsoft](https://github.com/Microsoft), [Azure](https://github.com/Azure), [DotNet](https://github.com/dotnet), [AspNet](https://github.com/aspnet), [Xamarin](https://github.com/xamarin), and [our GitHub organizations](https://opensource.microsoft.com/).
66

7-
Please do not open issues for anything you think might have a security implication.
7+
If you believe you have found a security vulnerability in any Microsoft-owned repository that meets [Microsoft's definition of a security vulnerability](https://docs.microsoft.com/en-us/previous-versions/tn-archive/cc751383(v=technet.10)), please report it to us as described below.
88

9+
## Reporting Security Issues
10+
11+
**Please do not report security vulnerabilities through public GitHub issues.**
12+
13+
Instead, please report them to the Microsoft Security Response Center (MSRC) at [https://msrc.microsoft.com/create-report](https://msrc.microsoft.com/create-report).
14+
15+
If you prefer to submit without logging in, send email to [[email protected]](mailto:[email protected]). If possible, encrypt your message with our PGP key; please download it from the [Microsoft Security Response Center PGP Key page](https://www.microsoft.com/en-us/msrc/pgp-key-msrc).
16+
17+
You should receive a response within 24 hours. If for some reason you do not, please follow up via email to ensure we received your original message. Additional information can be found at [microsoft.com/msrc](https://www.microsoft.com/msrc).
18+
19+
Please include the requested information listed below (as much as you can provide) to help us better understand the nature and scope of the possible issue:
20+
21+
* Type of issue (e.g. buffer overflow, SQL injection, cross-site scripting, etc.)
22+
* Full paths of source file(s) related to the manifestation of the issue
23+
* The location of the affected source code (tag/branch/commit or direct URL)
24+
* Any special configuration required to reproduce the issue
25+
* Step-by-step instructions to reproduce the issue
26+
* Proof-of-concept or exploit code (if possible)
27+
* Impact of the issue, including how an attacker might exploit the issue
28+
29+
This information will help us triage your report more quickly.
30+
31+
If you are reporting for a bug bounty, more complete reports can contribute to a higher bounty award. Please visit our [Microsoft Bug Bounty Program](https://microsoft.com/msrc/bounty) page for more details about our active programs.
32+
33+
## Preferred Languages
34+
35+
We prefer all communications to be in English.
36+
37+
## Policy
38+
39+
Microsoft follows the principle of [Coordinated Vulnerability Disclosure](https://www.microsoft.com/en-us/msrc/cvd).
40+
41+
<!-- END MICROSOFT SECURITY.MD BLOCK -->

common/smoketest/README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ pip install -r requiriments.txt
7474
pip install -r requiriments_async.txt
7575
```
7676

77-
If a python version below 3.5 is being used, it is still possible to run the samples. When it gets to the async tests a message `'Async not suported'` will be displayed.
77+
If a python version below 3.5 is being used, it is still possible to run the samples. When it gets to the async tests a message `'Async not supported'` will be displayed.
7878

7979
## Key concepts
8080

common/smoketest/dependencies.py

+71
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,71 @@
1+
import argparse
2+
import pkg_resources
3+
4+
try:
5+
# pip < 20
6+
from pip._internal.req import parse_requirements
7+
from pip._internal.download import PipSession
8+
except:
9+
# pip >= 20
10+
from pip._internal.req import parse_requirements
11+
from pip._internal.network.session import PipSession
12+
13+
def combine_requirements(requirements):
14+
name = requirements[0].project_name
15+
specs = []
16+
for req in requirements:
17+
if len(req.specs) == 0:
18+
continue
19+
20+
specs.extend([s[0] + s[1] for s in req.specs])
21+
22+
return name + ",".join(specs)
23+
24+
def get_dependencies(packages):
25+
requirements = []
26+
for package in packages:
27+
package_info = pkg_resources.working_set.by_key[package]
28+
29+
applicable_requirements = [r for r in package_info.requires() if r.marker is None or r.marker.evaluate()]
30+
requirements.extend(applicable_requirements)
31+
32+
return requirements
33+
34+
if __name__ == "__main__":
35+
parser = argparse.ArgumentParser(
36+
description="List dependencies for a given requirements.txt file"
37+
)
38+
39+
parser.add_argument(
40+
"-r",
41+
"--requirements",
42+
dest="requirements_file",
43+
help="File containing list of packages for which to find dependencies",
44+
required=True
45+
)
46+
47+
args = parser.parse_args()
48+
# Get package names from requirements.txt
49+
requirements = parse_requirements(args.requirements_file, session=PipSession())
50+
package_names = [item.req.name for item in requirements]
51+
52+
dependencies = get_dependencies(package_names)
53+
54+
# It may be the case that packages have multiple sets of dependency
55+
# requirements, for example:
56+
# Package A requires Foo>=1.0.0,<2.0.0
57+
# Package B requires Foo>=1.0.0,<1.2.3
58+
# This combines all required versions into one string for pip to resolve
59+
# Output: Foo>=1.0.0,<2.0.0,>=1.0.0,<1.2.3
60+
# Pip parses this value using the Requirement object (https://setuptools.readthedocs.io/en/latest/pkg_resources.html#requirement-objects)
61+
# According to https://packaging.python.org/glossary/#term-requirement-specifier
62+
grouped_dependencies = {}
63+
for dep in dependencies:
64+
if dep.key in grouped_dependencies:
65+
grouped_dependencies[dep.key].append(dep)
66+
else:
67+
grouped_dependencies[dep.key] = [dep]
68+
69+
final_dependencies = [combine_requirements(r) for r in grouped_dependencies.values()]
70+
71+
print("\n".join(final_dependencies))

0 commit comments

Comments
 (0)