Skip to content

Commit 41e81c8

Browse files
authored
Drop support for Python 2.7/3.5 (Azure#22760)
* updates to drop 2.7/3.5 support * mgmt setup.py fix * cspell fix for azuremgmtcommunication * removing nspkg from dev requirements all communication packages * versions update for communication packages
1 parent 2bffcd0 commit 41e81c8

Some content is hidden

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

55 files changed

+90
-178
lines changed

.vscode/cspell.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -126,6 +126,7 @@
126126
"azcmagent",
127127
"azsdk",
128128
"azuremgmtcore",
129+
"azuremgmtcommunication",
129130
"bdist",
130131
"byref",
131132
"cdll",

sdk/communication/azure-communication-chat/CHANGELOG.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Release History
22

3-
## 1.1.1 (Unreleased)
3+
## 1.2.0 (Unreleased)
44

55
### Features Added
66

@@ -9,6 +9,7 @@
99
### Bugs Fixed
1010

1111
### Other Changes
12+
Python 2.7 is no longer supported. Please use Python version 3.6 or later.
1213

1314
## 1.1.0 (2021-09-15)
1415
- Updated `azure-communication-chat` version.

sdk/communication/azure-communication-chat/README.md

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,15 @@ Read more about Azure Communication Services [here](https://docs.microsoft.com/a
55

66
[Source code](https://github.com/Azure/azure-sdk-for-python/tree/main/sdk/communication/azure-communication-chat) | [Package (Pypi)](https://pypi.org/project/azure-communication-chat/) | [API reference documentation](https://azuresdkdocs.blob.core.windows.net/$web/python/azure-communication-chat/1.0.0b5/index.html) | [Product documentation](https://docs.microsoft.com/azure/communication-services/)
77

8+
## _Disclaimer_
9+
10+
_Azure SDK Python packages support for Python 2.7 has ended 01 January 2022. For more information and questions, please refer to https://github.com/Azure/azure-sdk-for-python/issues/20691_
11+
812
# Getting started
913

1014
## Prerequisites
1115

12-
- Python 2.7, or 3.6 or later is required to use this package.
16+
- Python 3.6 or later is required to use this package.
1317
- A deployed Communication Services resource. You can use the [Azure Portal](https://docs.microsoft.com/azure/communication-services/quickstarts/create-communication-resource?tabs=windows&pivots=platform-azp) or the [Azure PowerShell](https://docs.microsoft.com/powershell/module/az.communication/new-azcommunicationservice) to set it up.
1418

1519
## Install the package
@@ -25,7 +29,7 @@ pip install --pre azure-communication-chat
2529
User access tokens enable you to build client applications that directly authenticate to Azure Communication Services. You can generate these tokens with azure.communication.identity module, and then use them to initialize the Communication Services SDKs. Example of using azure.communication.identity:
2630

2731
```bash
28-
pip install --pre azure-communication-identity
32+
pip install azure-communication-identity
2933
```
3034

3135
```python
@@ -536,8 +540,7 @@ for read_receipt_page in read_receipts.by_page():
536540
## Sample Code
537541

538542
These are code samples that show common scenario operations with the Azure Communication Chat client library.
539-
The async versions of the samples (the python sample files appended with `_async`) show asynchronous operations,
540-
and require Python 3.6 or later.
543+
The async versions of the samples (the python sample files appended with `_async`) show asynchronous operations.
541544
Before run the sample code, refer to Prerequisites
542545
<!-- [Prerequisites](#Prerequisites) -->
543546
to create a resource, then set some Environment Variables

sdk/communication/azure-communication-chat/azure/communication/chat/_chat_client.py

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,7 @@
55
# --------------------------------------------------------------------------
66
from typing import TYPE_CHECKING
77
from uuid import uuid4
8-
try:
9-
from urllib.parse import urlparse
10-
except ImportError:
11-
from urlparse import urlparse # type: ignore
8+
from urllib.parse import urlparse
129

1310
from azure.core.tracing.decorator import distributed_trace
1411
from azure.core.pipeline.policies import BearerTokenCredentialPolicy

sdk/communication/azure-communication-chat/azure/communication/chat/_chat_thread_client.py

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,7 @@
55
# --------------------------------------------------------------------------
66
from typing import TYPE_CHECKING
77

8-
try:
9-
from urllib.parse import urlparse
10-
except ImportError:
11-
from urlparse import urlparse # type: ignore
8+
from urllib.parse import urlparse
129

1310
from azure.core.tracing.decorator import distributed_trace
1411
from azure.core.pipeline.policies import BearerTokenCredentialPolicy

sdk/communication/azure-communication-chat/azure/communication/chat/_version.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,6 @@
44
# license information.
55
# --------------------------------------------------------------------------
66

7-
VERSION = "1.1.1"
7+
VERSION = "1.2.0"
88

99
SDK_MONIKER = "communication-chat/{}".format(VERSION) # type: str

sdk/communication/azure-communication-chat/azure/communication/chat/aio/_chat_client_async.py

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,7 @@
33
# Licensed under the MIT License. See License.txt in the project root for
44
# license information.
55
# --------------------------------------------------------------------------
6-
try:
7-
from urllib.parse import urlparse
8-
except ImportError:
9-
from urlparse import urlparse # type: ignore
6+
from urllib.parse import urlparse
107

118
# pylint: disable=unused-import,ungrouped-imports
129
from typing import Any, Callable, Dict, Generic, List, Optional, TypeVar, Union

sdk/communication/azure-communication-chat/azure/communication/chat/aio/_chat_thread_client_async.py

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,7 @@
33
# Licensed under the MIT License. See License.txt in the project root for
44
# license information.
55
# --------------------------------------------------------------------------
6-
try:
7-
from urllib.parse import urlparse
8-
except ImportError:
9-
from urlparse import urlparse # type: ignore
6+
from urllib.parse import urlparse
107

118
# pylint: disable=unused-import,ungrouped-imports
129
from typing import Any, Callable, Dict, Generic, List, Optional, TypeVar, Union, Tuple
Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
-e ../../../tools/azure-sdk-tools
2-
../../nspkg/azure-communication-nspkg
32
-e ../azure-communication-identity
4-
aiohttp>=3.0; python_version >= '3.5'
3+
aiohttp>=3.0
54
-e ../../../tools/azure-devtools
6-
python-dateutil>=2.8.1; python_version >= '3.5'
5+
python-dateutil>=2.8.1

sdk/communication/azure-communication-chat/setup.cfg

Lines changed: 0 additions & 2 deletions
This file was deleted.

0 commit comments

Comments
 (0)