Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update the packaging strategy to use pyproject.toml files. #66

Merged
merged 1 commit into from
Nov 10, 2023
Merged
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
6 changes: 3 additions & 3 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ default_language_version:
repos:
# Run fast code improvement/checks before running PR specific helpers.
- repo: https://github.com/pre-commit/pre-commit-hooks.git
rev: v4.3.0
rev: v4.4.0
hooks:
- id: trailing-whitespace
args: [--markdown-linebreak-ext=md]
Expand All @@ -14,8 +14,8 @@ repos:
args: ['--maxkb=4096']
exclude: 'EVSVesuvio/experiments/original_inputs|unpackaged'

- repo: https://gitlab.com/pycqa/flake8.git
rev: 5.0.4
- repo: https://github.com/PyCQA/flake8.git
rev: 6.1.0
hooks:
- id: flake8
args: ['--config', 'config.flake8']
Expand Down
23 changes: 0 additions & 23 deletions CMakeLists.txt

This file was deleted.

9 changes: 9 additions & 0 deletions EVSVesuvio/scripts/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
"""Package defining top-level application
and entry points.
"""


def main():
"""Placeholder.
"""
print("TEST_VESUVIO_LAUNCH")
File renamed without changes.
6 changes: 0 additions & 6 deletions MANIFEST.in

This file was deleted.

2 changes: 0 additions & 2 deletions bld.bat

This file was deleted.

1 change: 0 additions & 1 deletion build.sh

This file was deleted.

8 changes: 0 additions & 8 deletions buildconfig/CMake/Bootstrap.cmake

This file was deleted.

61 changes: 0 additions & 61 deletions buildconfig/CMake/CommonSetup.cmake

This file was deleted.

29 changes: 0 additions & 29 deletions buildconfig/CMake/FindGitLFS.cmake

This file was deleted.

File renamed without changes.
20 changes: 10 additions & 10 deletions meta.yaml → conda/meta.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,32 +5,32 @@
{% set version = version_tag + version_number %}

package:
name: EVSvesuvio
name: mvesuvio
version: {{ version }}

source:
git_url: ./
git_url: ../

requirements:
host:
- python {{ python }}
build:
noarch: python
script: python -m pip install --ignore-installed .
entry_points:
- mvesuvio = EVSVesuvio.scripts:main

requirements:
build:
- python {{ python }}
- setuptools

run:
- python {{ python }}
- mantid>=6.4.0
- mantid==6.7.0
- matplotlib
- iminuit
- h5py
- mock
- jacobi==0.4.2 #pinned untill 0.5.0 is proven

test:
imports:
- EVSvesuvio

about:
home: https://github.com/mantidproject/vesuvio
license: GPL-3.0-or-later
Expand Down
5 changes: 2 additions & 3 deletions environment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,9 @@ channels:
dependencies:
- flake8
- conda-wrappers
- pre-commit==2.15
- cmake=3.19.*|>=3.21.0
- pre-commit==2.15 #review this
- coverage
- mantid==6.6.0
- mantid==6.7.0 #review this
- matplotlib
- iminuit
- h5py
Expand Down
5 changes: 0 additions & 5 deletions install-requirements.txt

This file was deleted.

84 changes: 84 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,84 @@
[build-system]
requires = ["setuptools >= 65.0.0",
"wheel",
"versioningit",]
build-backend = "setuptools.build_meta"

[project]
name = "mvesuvio"
dynamic = ["version"]
authors = [
{name = "The Mantid Project", email = "[email protected]"},
{name = "Guilherme Pereira", email = "[email protected]"},
{name = "More Credit", email = "[email protected]"},
]
description = "Analyse Vesuvio instrument data"
readme = "README.md"
requires-python = "==3.8.*"
classifiers = [
"Programming Language :: Python :: 3.8",
"License :: OSI Approved :: GNU General Public License v3 (GPLv3)",
"Operating System :: OS Independent",
"Topic :: Scientific/Engineering",
]
dependencies = [
"matplotlib",
"iminuit",
"h5py",
"jacobi==0.4.2",
]

[project.optional-dependencies]
tests_require = [
"coverage",
"mock>=2.0",
"pytest",
]

[project.urls]
"Repository" = "https://github.com/mantidproject/vesuvio"
"Bug Tracker" = "https://github.com/mantidproject/vesuvio/issues"

[project.entry-points]
console_scripts = { mvesuvio = "EVSVesuvio.scripts:main" }

[tool.setuptools.packages.find]
include = ["EVSVesuvio*"]
namespaces = false

[tool.setuptools.package-data]
"EVSVesuvio.vesuvio_analysis.ip_files" = ["*.OPJ", "*.par", "*.DAT", "*.DAT3", "*.DAT6", "*.txt"]

[tool.pytest.ini_options]
pythonpath = ["."]
testpaths = ["EVSVesuvio/system_tests"]
filterwarnings = ["error"]

[tool.coverage.report]
include = [
"*/EVSVesuvio/vesuvio_analysis/*",
]

omit = [
"*tests*",
"*unpackaged*",
]

fail_under = 0
show_missing = true
skip_empty = true

[tool.versioningit.vcs]
method = "git"
default-tag = "0.0.0"

[tool.versioningit.next-version]
method = "minor"

[tool.versioningit.format]
distance = "{version}.dev{distance}"
dirty = "{version}+uncommitted"
distance-dirty = "{version}.dev{distance}+uncommitted"

[tool.versioningit.write]
file = "EVSVesuvio/__init__.py"
3 changes: 0 additions & 3 deletions scripts/test.py

This file was deleted.

Empty file removed setup-requirements.txt
Empty file.
11 changes: 0 additions & 11 deletions setup.cfg

This file was deleted.

Loading
Loading