Skip to content

Commit

Permalink
DEV 2122 drop py36 (#65)
Browse files Browse the repository at this point in the history
* drop py36 in gitlab-ci and upgrade gitlab-ci

* update setup.py, add MANIFEST.in, add pyproject.toml
  • Loading branch information
qqiao2024 authored Aug 28, 2023
1 parent 5069196 commit 10d90c1
Show file tree
Hide file tree
Showing 4 changed files with 62 additions and 13 deletions.
11 changes: 3 additions & 8 deletions .gitlab-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

include:
- project: nci-gdc/gitlab-templates
ref: 0.2.1
ref: 0.3.0
file:
- templates/global/full.yaml
- templates/python/full.yaml
Expand All @@ -11,7 +11,7 @@ include:
tox:
parallel:
matrix:
- BUILD_PY_VERSION: [ 'python3.6', 'python3.7', 'python3.8', 'python3.9' ]
- BUILD_PY_VERSION: [ 'python3.7', 'python3.8', 'python3.9' ]
services:
- name: docker.osdc.io/ncigdc/ci-postgres-13:${BASE_CONTAINER_VERSION}
alias: postgres
Expand All @@ -22,16 +22,11 @@ tox:
POSTGRES_PASSWORD: gdc_test
POSTGRES_HOST_AUTH_METHOD: trust
PG_HOST: postgres
before_script:
- !reference [.load_github_key, script]
- pip install "tox<4"
script:
- pip install "tox<4"
- tox -r -e py


release:
parallel:
matrix:
- RELEASE_PY_VERSION: [ python3.6 ]
before_script:
- git fetch --unshallow || true
9 changes: 9 additions & 0 deletions MANIFEST.in
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
graft gdc_ng_models
include alembic.ini LICENSE

exclude .pre-commit-config.yaml .gitlab-ci.yml .gitignore .secrets.baseline

prune tests
prune */__pycache__

global-exclude *.pyc
30 changes: 30 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
[build-system]
requires = [
"setuptools>=42",
"wheel",
"setuptools_scm[toml]>=3.4"
]
build-backend = "setuptools.build_meta"

[tool.setuptools_scm]
local_scheme = "no-local-version"

[tool.black]
line-length = 88
target-version = [
'py37',
]
include = '\.pyi?$'

[tool.coverage.run]
branch = true
context = "tests"
source = ["gdc-ng-models"]

[tool.coverage.html]
title = "gdc-ng-models coverage report"
directory = "htmlcov"
show_contexts = true

[tool.isort]
profile = "black"
25 changes: 20 additions & 5 deletions setup.py
Original file line number Diff line number Diff line change
@@ -1,12 +1,28 @@
from setuptools import setup, find_packages
# read the contents of your README file
from pathlib import Path

from setuptools import find_packages, setup

this_directory = Path(__file__).parent
long_description = (this_directory / "README.md").read_text()

setup(
name="gdc_ng_models",
setup_requires=["setuptools_scm<6"],
use_scm_version={"local_scheme": "dirty-tag", "fallback_version": "local"},
description="Non-graph GDC models",
long_description=long_description,
long_description_content_type="text/markdown",
author="NCI GDC",
author_email="gdc_dev_questions-aaaaae2lhsbell56tlvh3upgoq@cdis.slack.com",
url="https://github.com/NCI-GDC/gdc-ng-models",
classifiers=[
"Programming Language :: Python",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.7",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
],
license="Apache",
install_requires=[
"cryptography~=3.2",
"psycopg2~=2.9",
"pytz~=2020.5",
"sqlalchemy~=1.3.14",
Expand All @@ -20,7 +36,6 @@
],
"alembic": ["alembic~=1.4"],
},
license="Apache",
packages=find_packages(),
package_data={"gdc_ng_models": ["alembic/*"]},
include_package_data=True,
Expand Down

0 comments on commit 10d90c1

Please sign in to comment.