-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #10 from SEED-platform/task/ruff
Added ruff, updated python compatibility
- Loading branch information
Showing
11 changed files
with
926 additions
and
723 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -16,41 +16,28 @@ jobs: | |
pre-commit: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
# - name: Set up Python 3.8 | ||
# uses: actions/setup-python@v4 | ||
# with: | ||
# python-version: 3.8 | ||
# - name: Install and configure Poetry | ||
# uses: abatilo/actions-poetry@v2 | ||
# with: | ||
# poetry-version: 1.3.1 | ||
# - name: Install dependencies with Poetry | ||
# run: | | ||
# poetry --version | ||
# poetry install | ||
# poetry update | ||
- uses: actions/checkout@v4 | ||
- name: Run pre-commit | ||
uses: pre-commit/[email protected].0 | ||
uses: pre-commit/[email protected].1 | ||
with: | ||
extra_args: --all-files | ||
test: | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
os: [ubuntu-latest] | ||
python-version: ["3.8", "3.11"] | ||
python-version: ["3.9", "3.12"] | ||
runs-on: ${{ matrix.os }} | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: actions/checkout@v4 | ||
- name: Set up Python ${{ matrix.python-version }} | ||
uses: actions/setup-python@v4 | ||
uses: actions/setup-python@v5 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
- name: Install and configure Poetry | ||
uses: abatilo/actions-poetry@v2 | ||
uses: abatilo/actions-poetry@v3 | ||
with: | ||
poetry-version: 1.3.1 | ||
poetry-version: 1.8.3 | ||
- name: Install dependencies with Poetry | ||
run: | | ||
poetry --version | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,10 @@ | ||
# Change Log | ||
|
||
## Version 0.1.0 (unreleased) | ||
## Version 0.1.1 | ||
|
||
Updated Python compatibility for v3.9-v3.12, and reformatted with Ruff | ||
|
||
## Version 0.1.0 | ||
|
||
Develop a wrapper around the simple-salesforce Python module for | ||
communicating between SEED and Salesforce. |
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
[tool.poetry] | ||
name = "seed-salesforce" | ||
version = "0.1.0" | ||
version = "0.1.1" | ||
description = "Package for connecting SEED data to Salesforce" | ||
authors = ["Nicholas Long <[email protected]>", "Katherine Fleming <[email protected]>"] | ||
license = "BSD-3-Clause" | ||
|
@@ -14,27 +14,26 @@ keywords = ["SEED Platform", "Building Benchmarking", "Salesforce", "Building Pe | |
classifiers = [ | ||
"Development Status :: 4 - Beta", | ||
"Intended Audience :: Developers", | ||
"Programming Language :: Python :: 3.8", | ||
"Programming Language :: Python :: 3.9", | ||
"Programming Language :: Python :: 3.10", | ||
"Programming Language :: Python :: 3.11", | ||
"Programming Language :: Python :: 3.12", | ||
] | ||
packages = [ | ||
{ include = "seed_salesforce"} | ||
{ include = "seed_salesforce" } | ||
] | ||
|
||
[tool.poetry.dependencies] | ||
python = ">=3.8.1, <3.11" | ||
python-dateutil = "> 0" | ||
|
||
simple-salesforce = "^1.11.6" | ||
python = ">=3.9, <3.13" | ||
python-dateutil = "*" | ||
simple-salesforce = "^1.12.6" | ||
|
||
[tool.poetry.dev-dependencies] | ||
autopep8 = "2.0.1" | ||
flake8 = "6.0.0" | ||
mypy = "^1.0.1" | ||
pre-commit = "3.0.4" | ||
mypy = "^1.11.2" | ||
pre-commit = "^3.8.0" | ||
pytest = "^7.1.2" | ||
pytest-cov = "^4.0.0" | ||
ruff = "^0.6.7" | ||
|
||
[build-system] | ||
requires = ["poetry-core>=1.0.0"] | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,64 @@ | ||
fix = true | ||
line-length = 120 | ||
|
||
[format] | ||
# preview = true | ||
docstring-code-format = true | ||
|
||
# https://docs.astral.sh/ruff/linter/#rule-selection | ||
[lint] | ||
# preview = true | ||
# Enable these rules | ||
extend-select = [ | ||
"A", # flake8-builtins | ||
"ARG", # flake8-unused-arguments | ||
# "BLE", # flake8-blind-except | ||
"C4", # flake8-comprehensions | ||
"COM", # flake8-commas | ||
# "DTZ", # flake8-datetimez | ||
"E", # Error | ||
"EXE", # flake8-executable | ||
"F", # Pyflakes | ||
"I", # isort | ||
"ICN", # flake8-import-conventions | ||
"ISC", # flake8-implicit-str-concat | ||
"N", # pep8-naming | ||
"PD", # pandas-vet | ||
"PGH", # pygrep-hooks | ||
"PIE", # flake8-pie | ||
"PLC", # Pylint Convention | ||
"PLE", # Pylint Error | ||
"PLR", # Pylint Refactor | ||
"PLW", # Pylint Warning | ||
"PT", # flake8-pytest-style | ||
"Q", # flake8-quotes | ||
"RUF", # Ruff-specific rules | ||
"S", # flake8-bandit | ||
"SIM", # flake8-simplify | ||
"T10", # flake8-debugger | ||
"TID", # flake8-tidy-imports | ||
"UP", # pyupgrade | ||
] | ||
# except for these specific errors | ||
ignore = [ | ||
"E402", # module-import-not-at-top-of-file | ||
"E501", # line-too-long | ||
"E731", # lambda-assignment | ||
] | ||
|
||
[lint.per-file-ignores] | ||
"tests/test_*" = [ | ||
"S101", # assert | ||
"S311", # suspicious-non-cryptographic-random-usage | ||
] | ||
|
||
#exclude = | ||
# .tox | ||
# .eggs | ||
# build | ||
# dist | ||
|
||
[lint.pylint] | ||
# Raise the allowed limits the least possible amount https://docs.astral.sh/ruff/settings/#pylint-max-branches | ||
max-statements = 58 | ||
max-branches = 24 |
Oops, something went wrong.