diff --git a/README.md b/README.md index c1dabbab..7defbbcc 100644 --- a/README.md +++ b/README.md @@ -66,7 +66,7 @@ Are you looking for [slackclient](https://pypi.org/project/slackclient/)? The sl --- -This library requires Python 3.6 and above. If you require Python 2, please use our [SlackClient - v1.x][slackclientv1]. If you're unsure how to check what version of Python you're on, you can check it using the following: +This library requires Python 3.7 and above. If you're unsure how to check what version of Python you're on, you can check it using the following: > **Note:** You may need to use `python3` before your commands to ensure you use the correct Python path. e.g. `python3 --version` diff --git a/docs/english/installation.md b/docs/english/installation.md index 9c8bfec2..bf818fe2 100644 --- a/docs/english/installation.md +++ b/docs/english/installation.md @@ -1,6 +1,6 @@ # Installation -This package supports Python 3.6 and higher. We recommend using [PyPI](https://pypi.python.org/pypi) for installation. Run the following command: +This package supports Python 3.7 and higher. We recommend using [PyPI](https://pypi.python.org/pypi) for installation. Run the following command: ```bash pip install slack-sdk diff --git a/docs/english/legacy/index.md b/docs/english/legacy/index.md index eec16581..e2ca2061 100644 --- a/docs/english/legacy/index.md +++ b/docs/english/legacy/index.md @@ -10,7 +10,7 @@ Refer to the [migration guide](/tools/python-slack-sdk/v3-migration) to learn ho Slack APIs allow anyone to build full featured integrations that extend and expand the capabilities of your Slack workspace. These APIs allow you to build applications that interact with Slack just like the people on your team. They can post messages, respond to events that happen, and build complex UIs for getting work done. -To make it easier for Python programmers to build Slack applications, we've provided this open source SDK that will help you get started building Python apps as quickly as possible. The current version is built for Python 3.6 and higher — if you need to target Python 2.x, you might consider using v1 of the SDK. +To make it easier for Python programmers to build Slack applications, we've provided this open source SDK that will help you get started building Python apps as quickly as possible. The current version is built for Python 3.7 and higher. ## Slack platform basics {#platform-basics} diff --git a/docs/english/tutorial/uploading-files.md b/docs/english/tutorial/uploading-files.md index 70cc6e1c..a9a62475 100644 --- a/docs/english/tutorial/uploading-files.md +++ b/docs/english/tutorial/uploading-files.md @@ -56,7 +56,7 @@ With this, all your Slack app configuration is done. Let's start coding. ### Creating a new project {#create-new-project} -First, ensure you're using Python version 3.6 or above. While the current standard is for the `python3` and `pip3` commands to use Python 3.6 or above, it's best to ensure your runtime is always using the latest version of Python. [pyenv](https://github.com/pyenv/pyenv) is a handy tool that can do this for you. +First, ensure you're using Python version 3.7 or above. While the current standard is for the `python3` and `pip3` commands to use Python 3.7 or above, it's best to ensure your runtime is always using the latest version of Python. [pyenv](https://github.com/pyenv/pyenv) is a handy tool that can do this for you. We'll create a brand new virtual environment and install the required library dependencies using the following commands. diff --git a/docs/english/v3-migration.md b/docs/english/v3-migration.md index 67199c2b..d599ac28 100644 --- a/docs/english/v3-migration.md +++ b/docs/english/v3-migration.md @@ -69,7 +69,7 @@ If you don't wish to upgrade yet, be sure to pin your module for the Python `sla ### Minimum Python versions {#minimum-versions} -`slackclient` v2.x requires Python 3.6 (or higher). Support for Python 2.7 is maintained in the existing `slackclient` v1.x. +`slackclient` v2.x requires Python 3.7 (or higher). Client v1 support: - Python 2: Python 2.7 was supported in the 1.x version of the client up until Dec 31st, 2019. diff --git a/pyproject.toml b/pyproject.toml index 9eb6201b..cb2e28d1 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -7,7 +7,7 @@ name = "slack_sdk" dynamic = ["version", "readme", "authors", "optional-dependencies"] description = "The Slack API Platform SDK for Python" license = { text = "MIT" } -requires-python = ">=3.6" +requires-python = ">=3.7" keywords = [ "slack", "slack-api", @@ -27,7 +27,6 @@ classifiers = [ "License :: OSI Approved :: MIT License", "Programming Language :: Python", "Programming Language :: Python :: 3 :: Only", - "Programming Language :: Python :: 3.6", "Programming Language :: Python :: 3.7", "Programming Language :: Python :: 3.8", "Programming Language :: Python :: 3.9", diff --git a/requirements/testing.txt b/requirements/testing.txt index 984af2f4..4ee8403c 100644 --- a/requirements/testing.txt +++ b/requirements/testing.txt @@ -4,12 +4,11 @@ pytest>=7.0.1,<9 pytest-asyncio<2 # for async pytest-cov>=2,<7 # while flake8 5.x have issues with Python 3.12, flake8 6.x requires Python >= 3.8.1, -# so 5.x should be kept in order to stay compatible with Python 3.6/3.7 +# so 5.x should be kept in order to stay compatible with Python 3.7/3.8 flake8>=5.0.4,<8 # Don't change this version without running CI builds; # The latest version may not be available for older Python runtime -black>=22.8.0; python_version=="3.6" -black==22.10.0; python_version>"3.6" +black==22.10.0; click==8.0.4 # black is affected by https://github.com/pallets/click/issues/2225 psutil>=6.0.0,<8 # used only under slack_sdk/*_store diff --git a/slack/web/async_internal_utils.py b/slack/web/async_internal_utils.py index 10c6c2fd..1148dc9e 100644 --- a/slack/web/async_internal_utils.py +++ b/slack/web/async_internal_utils.py @@ -56,7 +56,7 @@ def _get_headers( e.g. { 'Content-Type': 'application/json;charset=utf-8', 'Authorization': 'Bearer xoxb-1234-1243', - 'User-Agent': 'Python/3.6.8 slack/2.1.0 Darwin/17.7.0' + 'User-Agent': 'Python/3.7.17 slack/2.1.0 Darwin/17.7.0' } """ final_headers = { diff --git a/slack_sdk/web/internal_utils.py b/slack_sdk/web/internal_utils.py index 41a870c5..a76980f4 100644 --- a/slack_sdk/web/internal_utils.py +++ b/slack_sdk/web/internal_utils.py @@ -44,7 +44,7 @@ def get_user_agent(prefix: Optional[str] = None, suffix: Optional[str] = None): Returns: The user agent string. - e.g. 'Python/3.6.7 slackclient/2.0.0 Darwin/17.7.0' + e.g. 'Python/3.7.17 slackclient/2.0.0 Darwin/17.7.0' """ # __name__ returns all classes, we only want the client client = "{0}/{1}".format("slackclient", version.__version__) @@ -91,7 +91,7 @@ def _get_headers( e.g. { 'Content-Type': 'application/json;charset=utf-8', 'Authorization': 'Bearer xoxb-1234-1243', - 'User-Agent': 'Python/3.6.8 slack/2.1.0 Darwin/17.7.0' + 'User-Agent': 'Python/3.7.17 slack/2.1.0 Darwin/17.7.0' } """ final_headers = { diff --git a/tutorial/README.md b/tutorial/README.md index 0d4cc2e4..12d99c89 100644 --- a/tutorial/README.md +++ b/tutorial/README.md @@ -21,14 +21,14 @@ As you complete each task you'll see the message update with a green checkmark. 1. A Slack team. Before anything else you'll need a Slack team. You can [Sign into an existing Slack workspace](https://get.slack.help/hc/en-us/articles/212681477-Sign-in-to-Slack) or you can [create a new Slack workspace](https://get.slack.help/hc/en-us/articles/206845317-Create-a-Slack-workspace) to test your app first. -2. A terminal with Python 3.6+ installed. +2. A terminal with Python 3.7+ installed. Check your installation by running the following command in your terminal: ``` $ python3 --version --> Python 3.6.7 +-> Python 3.7.17 ``` -You'll need to install Python 3.6 if you receive the following error: +You'll need to install Python 3.7 if you receive the following error: ``` -> bash: python3: command not found ```