-
Notifications
You must be signed in to change notification settings - Fork 189
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Do not try to set usetex=False or resave if savefig fails. Instead just return error msg. * Replace check_call with check_out in sh() Allows collection of outputs. Added redirect_error arg so stderr can be redirected to stdout and user in error logging. * Collect stderr msgs from lastal for use in informative logging. * Log suggestion to use --notex if savefig fails * Add cleanup empty pdf before exit if savefig fails * Add logging to clarify why latex is deactivated. * ignore version and cython files * mv exclude to pyproject * use hatch for build * use hatch-vcs version * log error when no cblast * mv pkg into src * ignore version * init env yml * rm version, switch to dynamic vcs version * WIP: migrating to hatch * rm cblast.c from tracking * ignore dev files * Use setuptools for cython modules * automate run setup.py for cython build * setup_magick_home() assumes ImageMagick always installed with homebrew on MacOS, change error to warning if homebrew path not found. * install non-pip deps using conda. Install libmagic without homebrew. * fix bug - incorrect selection of wget on MocOS without wget * version to _version * bump min Python version. * conda env instructions * Do not try to set usetex=False or resave if savefig fails. Instead just return error msg. * Replace check_call with check_out in sh() Allows collection of outputs. Added redirect_error arg so stderr can be redirected to stdout and user in error logging. * Move files back to jcvi/ * Move jcvi to src/ directory with git mv * optparse not used * use logger instead of logging * fix conda env to py 3.12 * init pytest action * black fmt * use miniforge * switch run order * handle testing in build action * black fmt * Add cython to deps * typo * Add cli entrypoint to check version * update readme
- Loading branch information
1 parent
0a5b1f3
commit ea05c58
Showing
193 changed files
with
304 additions
and
178 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
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 was deleted.
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
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,9 @@ | ||
import subprocess | ||
from hatchling.builders.hooks.plugin.interface import BuildHookInterface | ||
|
||
|
||
class CustomBuildHook(BuildHookInterface): | ||
def initialize(self, version, build_data): | ||
# Run setup.py build_ext before main build | ||
subprocess.check_call(["python", "setup.py", "build_ext", "--inplace"]) | ||
return super().initialize(version, build_data) |
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,14 @@ | ||
name: jcvi-osx64 | ||
channels: | ||
- conda-forge/osx-64 | ||
- bioconda/osx-64 | ||
dependencies: | ||
- python 3.12 | ||
- bedtools | ||
- imagemagick | ||
- libmagic # System-level magic library | ||
- wand # Python bindings for ImageMagick | ||
- pip | ||
- pip: | ||
- hatch | ||
- pytest |
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,14 @@ | ||
name: jcvi | ||
channels: | ||
- conda-forge | ||
- bioconda | ||
dependencies: | ||
- python 3.12 | ||
- bedtools | ||
- imagemagick | ||
- libmagic # System-level magic library | ||
- wand # Python bindings for ImageMagick | ||
- pip | ||
- pip: | ||
- pytest | ||
- hatch |
This file was deleted.
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,15 +1,110 @@ | ||
# Specifies the build system requirements and backend | ||
[build-system] | ||
requires = [ | ||
"Cython", | ||
"numpy", | ||
"setuptools", | ||
"setuptools_scm[toml]", | ||
"setuptools_scm_git_archive", | ||
"wheel", | ||
] | ||
build-backend = "setuptools.build_meta" | ||
|
||
[tool.setuptools_scm] | ||
write_to = "jcvi/version.py" | ||
git_describe_command = "git describe --dirty --tags --long --match v* --first-parent" | ||
version_scheme = "no-guess-dev" | ||
"hatchling", # Build backend | ||
"hatch-vcs", # Version control system plugin for dynamic versioning | ||
"setuptools", # Setuptools for compiling C extensions | ||
"cython", # Cython for compiling C extensions | ||
"numpy", # NumPy for numerical operations and C extension includes | ||
] | ||
build-backend = "hatchling.build" | ||
|
||
[tool.hatch.build.hooks.custom] | ||
path = "build.py" | ||
|
||
# Project metadata and configuration | ||
[project] | ||
name = "jcvi" | ||
description = "Python utility libraries on genome assembly, annotation and comparative genomics" | ||
readme = "README.md" | ||
requires-python = ">=3.8" | ||
license = {text = "BSD"} | ||
authors = [ | ||
{name = "Haibao Tang", email = "tanghaibao@gmail.com"}, | ||
{name = "Vivek Krishnakumar"}, | ||
{name = "Jingping Li"} | ||
] | ||
|
||
classifiers = [ | ||
"Intended Audience :: Science/Research", | ||
"License :: OSI Approved :: BSD License", | ||
"Programming Language :: Python", | ||
"Programming Language :: Python :: 3", | ||
"Topic :: Scientific/Engineering :: Bio-Informatics" | ||
] | ||
|
||
dependencies = [ | ||
"biopython", | ||
"boto3", | ||
"brewer2mpl", | ||
"CrossMap", | ||
"cython", | ||
"deap", | ||
"ete3", | ||
"ftpretty", | ||
"genomepy", | ||
"gffutils", | ||
"goatools", | ||
"graphviz", | ||
"jinja2", | ||
"matplotlib", | ||
"more-itertools", | ||
"natsort", | ||
"networkx", | ||
"numpy<2", | ||
"ortools", | ||
"pybedtools", | ||
"pyefd", | ||
"pypdf", | ||
"pytesseract", | ||
"rich", | ||
"scikit-image", | ||
"scipy", | ||
"seaborn", | ||
"Wand", | ||
"webcolors" | ||
] | ||
|
||
dynamic = ["version"] | ||
|
||
[project.optional-dependencies] | ||
tests = [ | ||
"mock", | ||
"pytest-benchmark", | ||
"pytest-cov", | ||
"pytest", | ||
"PyYAML", | ||
] | ||
|
||
[project.urls] | ||
homepage = "http://github.com/tanghaibao/jcvi" | ||
|
||
# Command-line script entry point | ||
[project.scripts] | ||
jcvi = "jcvi.cli:main" | ||
|
||
[tool.hatch.metadata] | ||
allow-direct-references = true | ||
|
||
[tool.hatch.build] | ||
packages = ["src/jcvi"] | ||
|
||
[tool.hatch.version] | ||
source = "vcs" | ||
|
||
[tool.hatch.build.hooks.vcs] | ||
version-file = "src/jcvi/_version.py" | ||
|
||
[tool.hatch.version.vcs] | ||
tag-pattern = "v*" | ||
fallback-version = "0.0.0" | ||
|
||
[tool.hatch.build.targets.sdist] | ||
include = [ | ||
"src/**/*.py", | ||
"src/**/*.pyx", | ||
"README.md", | ||
] | ||
|
||
[tool.hatch.build.targets.wheel] | ||
packages = ["src/jcvi"] |
Oops, something went wrong.