Skip to content

Commit

Permalink
Merge pull request #139 from biocommons/138-seqrepo-cli-not-installed…
Browse files Browse the repository at this point in the history
…-in-066-and-067

fix: finish migrating from setup.cfg to pyproject.toml in order to install seqrepo cli
  • Loading branch information
reece authored Feb 20, 2024
2 parents 695cb14 + 9f9e001 commit 344d9d6
Show file tree
Hide file tree
Showing 4 changed files with 79 additions and 77 deletions.
4 changes: 3 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,9 @@
.PRECIOUS:
.SUFFIXES:

SHELL:=/bin/bash -e -o pipefail -O globstar

SHELL:=bash -e -o pipefail -O globstar

SELF:=$(firstword $(MAKEFILE_LIST))

VE_DIR=venv
Expand Down
20 changes: 18 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -105,10 +105,18 @@ answer](https://apple.stackexchange.com/questions/254380/why-am-i-getting-an-inv

## Quick Start

On Ubuntu 16.04:
### OSX

$ brew install python libpq

### On Ubuntu 16.04

$ sudo apt install -y python3-dev gcc zlib1g-dev tabix
(OSX: $ brew install python libpq)

### All platforms

$ python -m venv venv
$ source venv/bin/activate
$ pip install seqrepo
$ sudo mkdir -p /usr/local/share/seqrepo
$ sudo chown $USER /usr/local/share/seqrepo
Expand Down Expand Up @@ -157,6 +165,14 @@ a moderate value (>10) will greatly increase performance of sequence retrieval.

## Developing

### OSX

brew install python libpq bash

### Ubuntu

sudo apt install -y python3-dev gcc zlib1g-dev tabix

Here's how to get started developing:

make devready
Expand Down
76 changes: 58 additions & 18 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
[project]
name = "biocommons.seqrepo"
authors = [
{ name="biocommons contributors", email="biocommons-dev@googlegroups.com" },
{ name = "biocommons contributors", email = "biocommons-dev@googlegroups.com" },
]
description = "Non-redundant, compressed, journalled, file-based storage for biological sequences"
readme = "README.md"
license = { file="LICENSE.txt" }
license = { file = "LICENSE.txt" }
requires-python = ">=3.9"
classifiers = [
"Programming Language :: Python :: 3",
Expand All @@ -15,31 +15,64 @@ classifiers = [
"License :: OSI Approved :: MIT License",
"Operating System :: OS Independent",
]
dynamic = ["version", "optional-dependencies"]
dynamic = ["version"]
dependencies = [
"bioutils > 0.4",
"coloredlogs",
"ipython",
"pysam",
"requests",
"requests_html",
"six",
"tqdm",
"yoyo-migrations"
"coloredlogs ~= 15.0",
"ipython ~= 8.4",
"pysam ~= 0.22",
"requests ~= 2.31",
"six ~= 1.16",
"yoyo-migrations ~= 8.2",
]

[project.optional-dependencies]
dev = [
"bandit ~= 1.7",
"black ~= 22.3",
"build ~= 0.8",
"flake8 ~= 4.0",
"ipython ~= 8.4",
"isort ~= 5.10",
"mypy-extensions ~= 1.0",
"pre-commit ~= 3.4",
"pylint ~= 2.14",
"pytest-cov ~= 4.1",
"pytest-optional-tests",
"pytest ~= 7.1",
"pyright~=1.1",
"requests_html ~= 0.10",
"tqdm ~= 4.66",
"tox ~= 3.25",
"vcrpy",
]
docs = ["mkdocs"]

[project.scripts]
seqrepo = "biocommons.seqrepo.cli:main"

[project.urls]
"Homepage" = "https://github.com/biocommons/biocommons.seqrepo"
"Bug Tracker" = "https://github.com/biocommons/biocommons.seqrepo/issues"

[build-system]
requires = [
"setuptools >= 69.0.2",
"setuptools_scm[toml] >= 8.0"
]
requires = ["setuptools ~= 69.0", "setuptools_scm[toml] ~= 8.0"]
build-backend = "setuptools.build_meta"


[tool.setuptools]
include-package-data = true

[tool.setuptools.packages.find]
where = ["src"]
exclude = ["__pycache__", "*.pyc"]
namespaces = true

[tool.setuptools.package-data]
"biocommons.seqrepo.fastadir" = ["_data/migrations/*"]
"biocommons.seqrepo.seqaliasdb" = ["_data/migrations/*"]


[tool.setuptools_scm]


Expand All @@ -54,9 +87,9 @@ doctest_optionflags = [
"NORMALIZE_WHITESPACE",
]
markers = [
"network: tests that require network connectivity",
"slow: slow tests that should be run infrequently",
"vcr: tests with cached data",
"network: tests that require network connectivity",
"slow: slow tests that should be run infrequently",
"vcr: tests with cached data",
]


Expand Down Expand Up @@ -87,12 +120,19 @@ exclude_lines = [
[tool.black]
line-length = 100

[tool.isort]
profile = "black"
src_paths = ["src", "tests"]

# [tool.flake8]
# flake8 does not support configuration in pyproject.toml
# https://github.com/PyCQA/flake8/issues/234#issuecomment-812800832
# The config in setup.cfg

[tool.pyright]
include = ["src", "tests"]


[tool.pylint.'MESSAGES CONTROL']
disable = "R0913"

Expand Down
56 changes: 0 additions & 56 deletions setup.cfg

This file was deleted.

0 comments on commit 344d9d6

Please sign in to comment.