Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
version: 2
updates:

# Maintain dependencies for GitHub Actions (main)
- package-ecosystem: "github-actions"
directory: "/"
target-branch: "main"
schedule:
interval: "weekly"

2 changes: 1 addition & 1 deletion .github/workflows/tests_scheduled.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ concurrency:

jobs:
test:
if: (github.repository == 'spacetelescope/costools' && (github.event_name == 'schedule' || github.event_name == 'push' || github.event_name == 'workflow_dispatch' || contains(github.event.pull_request.labels.*.name, 'Weekly CI')))
if: (github.repository == 'spacetelescope/costools' && (github.event_name == 'schedule' || github.event_name == 'push' || github.event_name == 'workflow_dispatch' || contains(github.event.pull_request.labels.*.name, 'run devdeps tests')))
uses: OpenAstronomy/github-actions-workflows/.github/workflows/tox.yml@v1
with:
envs: |
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -6,3 +6,4 @@ docs/build
dist
__pycache__
pip-wheel-metadata
**/version.py
9 changes: 3 additions & 6 deletions costools/__init__.py
Original file line number Diff line number Diff line change
@@ -1,12 +1,8 @@
from __future__ import absolute_import, division # confidence high

from pkg_resources import get_distribution, DistributionNotFound
try:
__version__ = get_distribution(__name__).version
except DistributionNotFound:
# package is not installed
__version__ = 'UNKNOWN'
from importlib.metadata import version

__version__ = version(__name__)

from . import timefilter
from . import splittag
Expand All @@ -16,4 +12,5 @@
# upon importing this package.
import os
from stsci.tools import teal

teal.print_tasknames(__name__, os.path.dirname(__file__))
65 changes: 65 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,71 @@
[project]
name = "costools"
description = "Tools for COS (Cosmic Origins Spectrograph)"
authors = [
{ name = "Warren Hack" },
{ name = "Nadezhda Dencheva" },
{ name = "Phil Hodge" },
]
classifiers = [
"Intended Audience :: Science/Research",
"License :: OSI Approved :: BSD License",
"Operating System :: OS Independent",
"Programming Language :: Python",
"Topic :: Scientific/Engineering :: Astronomy",
"Topic :: Software Development :: Libraries :: Python Modules",
]
dependencies = [
"astropy",
"calcos",
"numpy>=2.0.0rc1",
"stsci.tools",
]
dynamic = [
"version",
]

[project.readme]
file = "README.md"
content-type = "text/markdown"

[project.license]
file = "LICENSE.txt"
content-type = "text/plain"

[project.scripts]
timefilter = "costools.timefilter:main"
add_cos_s_region = "costools.add_cos_s_region:call_main"

[project.optional-dependencies]
docs = [
"sphinx",
"numpydoc",
]
test = [
"pytest",
"pytest-cov",
]

[build-system]
requires = [
"setuptools>=38.2.5",
"setuptools_scm",
"wheel",
"numpy>=2.0.0rc1",
]
build-backend = "setuptools.build_meta"

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

[tool.setuptools.packages.find]
namespaces = false

[tool.setuptools.package-data]
costools = [
"pars/*",
"*.help",
]

[tool.setuptools_scm]
version_file = "costools/version.py"
2 changes: 1 addition & 1 deletion requirements-dev.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,6 @@

# Use Bi-weekly numpy/scipy dev builds
--extra-index-url https://pypi.anaconda.org/scientific-python-nightly-wheels/simple
numpy>=0.0.dev0
numpy>=2.0.0b1
scipy>=0.0.dev0

59 changes: 0 additions & 59 deletions setup.py

This file was deleted.