Skip to content

Commit

Permalink
fix: bump up min supported python version to 3.8
Browse files Browse the repository at this point in the history
Signed-off-by: Subin Shekhar <[email protected]>
  • Loading branch information
subinpc committed Jan 3, 2024
1 parent 8b02c58 commit 7ed431a
Show file tree
Hide file tree
Showing 9 changed files with 29 additions and 40 deletions.
12 changes: 3 additions & 9 deletions .pylintrc
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,9 @@ disable=too-many-arguments,
useless-suppression,
deprecated-pragma,
use-symbolic-message-instead,
invalid-name
invalid-name,
global-statement,
use-implicit-booleaness-not-comparison

# Enable the message, report, category or checker with the given id(s). You can
# either give multiple identifier separated by comma (,) or put this option
Expand Down Expand Up @@ -191,14 +193,6 @@ attr-naming-style=snake_case
# style.
#attr-rgx=

# Bad variable names which should always be refused, separated by a comma.
bad-names=foo,
bar,
baz,
toto,
tutu,
tata

# Naming style matching correct class attribute names.
class-attribute-naming-style=any

Expand Down
7 changes: 5 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@
# to be ready for development work in the local sandbox.
# example: "make setup"

LINT_DIRS=iaesdk test/unit test/integration examples

setup: deps dev_deps install_project

all: upgrade_pip setup test-unit lint
Expand Down Expand Up @@ -32,7 +34,8 @@ test-examples:
python -m pytest examples

lint:
./pylint.sh && black --check .
python -m pylint ${LINT_DIRS} --exit-zero
black --check ${LINT_DIRS}

lint-fix:
black .
black ${LINT_DIRS}
12 changes: 3 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,20 +40,14 @@ IBM Analytics Engine v3 is for the Standard Serverless for Apache Spark plan

* An [IBM Cloud][ibm-cloud-onboarding] account.
* An IAM API key to allow the SDK to access your account. Create one [here](https://cloud.ibm.com/iam/apikeys).
* Python 3.7 or above.
* Python 3.8 or above.

## Installation

To install, use `pip` or `easy_install`:
To install, use `pip`:

```bash
pip install --upgrade "iaesdk>=3.2.0"
```

or

```bash
easy_install --upgrade "iaesdk>=3.2.0"
python -m pip install --upgrade iaesdk
```

## Using the SDK
Expand Down
7 changes: 5 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,14 @@
"description": "This package.json is being used to manage semantic-release and its dependencies",
"license": "Apache-2.0",
"devDependencies": {
"semantic-release": "19.0.5",
"@semantic-release/changelog": "6.0.2",
"semantic-release": "21.0.7",
"@semantic-release/changelog": "6.0.3",
"@semantic-release/exec": "6.0.3",
"@semantic-release/git": "10.0.1"
},
"overrides": {
"semver": "^7.5.3"
},
"scripts": {
"semantic-release": "semantic-release"
}
Expand Down
14 changes: 6 additions & 8 deletions requirements-dev.txt
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
# test dependencies
coverage>=4.5.4
pylint>=2.6.0,<3.0.0
pytest>=7.0.1,<8.0.0
pytest-cov>=2.2.1,<3.0.0
pytest-rerunfailures>=3.1
responses>=0.12.1,<1.0.0
black>=22.10
coverage>=7.3.2,<8.0.0
pylint>=3.0.0,<4.0.0
pytest>=7.4.2,<8.0.0
pytest-cov>=4.1.0,<5.0.0
responses>=0.23.3,<1.0.0
black>=23.9.1
5 changes: 1 addition & 4 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1 @@
requests>=2.26.0,<3.0.0
urllib3>=1.26.0,<2.0.0
python_dateutil>=2.5.3,<3.0.0
ibm_cloud_sdk_core>=3.16.0,<4.0.0
ibm_cloud_sdk_core>=3.18.2,<4.0.0
4 changes: 2 additions & 2 deletions setup.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#!/usr/bin/env python
# Copyright 2016,2022 IBM All Rights Reserved.
# Copyright 2016,2024 IBM All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
Expand Down Expand Up @@ -59,10 +59,10 @@
classifiers=[
"Programming Language :: Python",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.7",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Development Status :: 4 - Beta",
"Intended Audience :: Developers",
"License :: OSI Approved :: Apache Software License",
Expand Down
4 changes: 2 additions & 2 deletions test/unit/test_ibm_analytics_engine_api_v2.py
Original file line number Diff line number Diff line change
Expand Up @@ -58,8 +58,8 @@ def preprocess_url(operation_path: str):
# Otherwise, return a regular expression that matches one or more trailing /.
if re.fullmatch(".*/+", request_url) is None:
return request_url
else:
return re.compile(request_url.rstrip("/") + "/+")

return re.compile(request_url.rstrip("/") + "/+")


##############################################################################
Expand Down
4 changes: 2 additions & 2 deletions test/unit/test_ibm_analytics_engine_api_v3.py
Original file line number Diff line number Diff line change
Expand Up @@ -59,8 +59,8 @@ def preprocess_url(operation_path: str):
# Otherwise, return a regular expression that matches one or more trailing /.
if re.fullmatch('.*/+', request_url) is None:
return request_url
else:
return re.compile(request_url.rstrip('/') + '/+')

return re.compile(request_url.rstrip('/') + '/+')


def test_get_service_url_for_region():
Expand Down

0 comments on commit 7ed431a

Please sign in to comment.