#2 DO NOT MERGE: WIP: feat: update to 1.4.0.2
Merged a year ago by ankursinha. Opened a year ago by ankursinha.
rpms/ ankursinha/python-SALib feat/v1.4.0.2  into  rawhide

file modified
+1
@@ -2,3 +2,4 @@ 

  *.src.rpm

  /SALib-1.3.8.tar.gz

  /SALib-1.3.11.tar.gz

+ /python-SALib-1.4.0.2.tar.gz

@@ -0,0 +1,583 @@ 

+ From f33e24b87f4a9bd04990dd7cd917d091e10688cc Mon Sep 17 00:00:00 2001

+ From: "Ankur Sinha (Ankur Sinha Gmail)" <sanjay.ankur@gmail.com>

+ Date: Wed, 7 Jul 2021 21:16:36 +0100

+ Subject: [PATCH 1/2] build(pyscaffold): update existing files for pyscaffold

+  v4

+ 

+ ---

+  docs/Makefile         | 192 +++---------------------------------------

+  docs/conf.py          | 114 +++++++++++++------------

+  setup.cfg             |  15 +++-

+  setup.py              |  24 +++---

+  src/SALib/__init__.py |  17 ++--

+  5 files changed, 111 insertions(+), 251 deletions(-)

+ 

+ diff --git a/docs/Makefile b/docs/Makefile

+ index 1728fc2..fa2cc35 100644

+ --- a/docs/Makefile

+ +++ b/docs/Makefile

+ @@ -1,193 +1,29 @@

+  # Makefile for Sphinx documentation

+  #

+  

+ -# You can set these variables from the command line.

+ -SPHINXOPTS    =

+ -SPHINXBUILD   = sphinx-build

+ -PAPER         =

+ -BUILDDIR      = ../build/sphinx/

+ +# You can set these variables from the command line, and also

+ +# from the environment for the first two.

+ +SPHINXOPTS    ?=

+ +SPHINXBUILD   ?= sphinx-build

+ +SOURCEDIR     = .

+ +BUILDDIR      = _build

+  AUTODOCDIR    = api

+ -AUTODOCBUILD  = sphinx-apidoc

+ -PROJECT       = SALib

+ -MODULEDIR     = ../src/salib

+  

+  # User-friendly check for sphinx-build

+  ifeq ($(shell which $(SPHINXBUILD) >/dev/null 2>&1; echo $?), 1)

+ -$(error The '$(SPHINXBUILD)' command was not found. Make sure you have Sphinx installed, then set the SPHINXBUILD environment variable to point to the full path of the '$(SPHINXBUILD)' executable. Alternatively you can add the directory with the executable to your PATH. If you don't have Sphinx installed, grab it from http://sphinx-doc.org/)

+ +$(error "The '$(SPHINXBUILD)' command was not found. Make sure you have Sphinx installed, then set the SPHINXBUILD environment variable to point to the full path of the '$(SPHINXBUILD)' executable. Alternatively you can add the directory with the executable to your PATH. If you don't have Sphinx installed, grab it from http://sphinx-doc.org/")

+  endif

+  

+ -# Internal variables.

+ -PAPEROPT_a4     = -D latex_paper_size=a4

+ -PAPEROPT_letter = -D latex_paper_size=letter

+ -ALLSPHINXOPTS   = -d $(BUILDDIR)/doctrees $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) .

+ -# the i18n builder cannot share the environment and doctrees with the others

+ -I18NSPHINXOPTS  = $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) .

+ -

+ -.PHONY: help clean html dirhtml singlehtml pickle json htmlhelp qthelp devhelp epub latex latexpdf text man changes linkcheck doctest gettext doc-requirements

+ +.PHONY: help clean Makefile

+  

+ +# Put it first so that "make" without argument is like "make help".

+  help:

+ -	@echo "Please use \`make <target>' where <target> is one of"

+ -	@echo "  html       to make standalone HTML files"

+ -	@echo "  dirhtml    to make HTML files named index.html in directories"

+ -	@echo "  singlehtml to make a single large HTML file"

+ -	@echo "  pickle     to make pickle files"

+ -	@echo "  json       to make JSON files"

+ -	@echo "  htmlhelp   to make HTML files and a HTML help project"

+ -	@echo "  qthelp     to make HTML files and a qthelp project"

+ -	@echo "  devhelp    to make HTML files and a Devhelp project"

+ -	@echo "  epub       to make an epub"

+ -	@echo "  latex      to make LaTeX files, you can set PAPER=a4 or PAPER=letter"

+ -	@echo "  latexpdf   to make LaTeX files and run them through pdflatex"

+ -	@echo "  latexpdfja to make LaTeX files and run them through platex/dvipdfmx"

+ -	@echo "  text       to make text files"

+ -	@echo "  man        to make manual pages"

+ -	@echo "  texinfo    to make Texinfo files"

+ -	@echo "  info       to make Texinfo files and run them through makeinfo"

+ -	@echo "  gettext    to make PO message catalogs"

+ -	@echo "  changes    to make an overview of all changed/added/deprecated items"

+ -	@echo "  xml        to make Docutils-native XML files"

+ -	@echo "  pseudoxml  to make pseudoxml-XML files for display purposes"

+ -	@echo "  linkcheck  to check all external links for integrity"

+ -	@echo "  doctest    to run all doctests embedded in the documentation (if enabled)"

+ +	@$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)

+  

+  clean:

+  	rm -rf $(BUILDDIR)/* $(AUTODOCDIR)

+  

+ -$(AUTODOCDIR): $(MODULEDIR)

+ -	mkdir -p $@

+ -	$(AUTODOCBUILD) -f -o $@ $^

+ -

+ -doc-requirements: $(AUTODOCDIR)

+ -

+ -html: doc-requirements

+ -	$(SPHINXBUILD) -b html $(ALLSPHINXOPTS) $(BUILDDIR)/html

+ -	@echo

+ -	@echo "Build finished. The HTML pages are in $(BUILDDIR)/html."

+ -

+ -dirhtml: doc-requirements

+ -	$(SPHINXBUILD) -b dirhtml $(ALLSPHINXOPTS) $(BUILDDIR)/dirhtml

+ -	@echo

+ -	@echo "Build finished. The HTML pages are in $(BUILDDIR)/dirhtml."

+ -

+ -singlehtml: doc-requirements

+ -	$(SPHINXBUILD) -b singlehtml $(ALLSPHINXOPTS) $(BUILDDIR)/singlehtml

+ -	@echo

+ -	@echo "Build finished. The HTML page is in $(BUILDDIR)/singlehtml."

+ -

+ -pickle: doc-requirements

+ -	$(SPHINXBUILD) -b pickle $(ALLSPHINXOPTS) $(BUILDDIR)/pickle

+ -	@echo

+ -	@echo "Build finished; now you can process the pickle files."

+ -

+ -json: doc-requirements

+ -	$(SPHINXBUILD) -b json $(ALLSPHINXOPTS) $(BUILDDIR)/json

+ -	@echo

+ -	@echo "Build finished; now you can process the JSON files."

+ -

+ -htmlhelp: doc-requirements

+ -	$(SPHINXBUILD) -b htmlhelp $(ALLSPHINXOPTS) $(BUILDDIR)/htmlhelp

+ -	@echo

+ -	@echo "Build finished; now you can run HTML Help Workshop with the" \

+ -	      ".hhp project file in $(BUILDDIR)/htmlhelp."

+ -

+ -qthelp: doc-requirements

+ -	$(SPHINXBUILD) -b qthelp $(ALLSPHINXOPTS) $(BUILDDIR)/qthelp

+ -	@echo

+ -	@echo "Build finished; now you can run "qcollectiongenerator" with the" \

+ -	      ".qhcp project file in $(BUILDDIR)/qthelp, like this:"

+ -	@echo "# qcollectiongenerator $(BUILDDIR)/qthelp/$(PROJECT).qhcp"

+ -	@echo "To view the help file:"

+ -	@echo "# assistant -collectionFile $(BUILDDIR)/qthelp/$(PROJECT).qhc"

+ -

+ -devhelp: doc-requirements

+ -	$(SPHINXBUILD) -b devhelp $(ALLSPHINXOPTS) $(BUILDDIR)/devhelp

+ -	@echo

+ -	@echo "Build finished."

+ -	@echo "To view the help file:"

+ -	@echo "# mkdir -p $HOME/.local/share/devhelp/$(PROJECT)"

+ -	@echo "# ln -s $(BUILDDIR)/devhelp $HOME/.local/share/devhelp/$(PROJEC)"

+ -	@echo "# devhelp"

+ -

+ -epub: doc-requirements

+ -	$(SPHINXBUILD) -b epub $(ALLSPHINXOPTS) $(BUILDDIR)/epub

+ -	@echo

+ -	@echo "Build finished. The epub file is in $(BUILDDIR)/epub."

+ -

+ -patch-latex:

+ -	find _build/latex -iname "*.tex" | xargs -- \

+ -		sed -i'' 's~includegraphics{~includegraphics\[keepaspectratio,max size={\\textwidth}{\\textheight}\]{~g'

+ -

+ -latex: doc-requirements

+ -	$(SPHINXBUILD) -b latex $(ALLSPHINXOPTS) $(BUILDDIR)/latex

+ -	$(MAKE) patch-latex

+ -	@echo

+ -	@echo "Build finished; the LaTeX files are in $(BUILDDIR)/latex."

+ -	@echo "Run \`make' in that directory to run these through (pdf)latex" \

+ -	      "(use \`make latexpdf' here to do that automatically)."

+ -

+ -latexpdf: doc-requirements

+ -	$(SPHINXBUILD) -b latex $(ALLSPHINXOPTS) $(BUILDDIR)/latex

+ -	$(MAKE) patch-latex

+ -	@echo "Running LaTeX files through pdflatex..."

+ -	$(MAKE) -C $(BUILDDIR)/latex all-pdf

+ -	@echo "pdflatex finished; the PDF files are in $(BUILDDIR)/latex."

+ -

+ -latexpdfja: doc-requirements

+ -	$(SPHINXBUILD) -b latex $(ALLSPHINXOPTS) $(BUILDDIR)/latex

+ -	@echo "Running LaTeX files through platex and dvipdfmx..."

+ -	$(MAKE) -C $(BUILDDIR)/latex all-pdf-ja

+ -	@echo "pdflatex finished; the PDF files are in $(BUILDDIR)/latex."

+ -

+ -text: doc-requirements

+ -	$(SPHINXBUILD) -b text $(ALLSPHINXOPTS) $(BUILDDIR)/text

+ -	@echo

+ -	@echo "Build finished. The text files are in $(BUILDDIR)/text."

+ -

+ -man: doc-requirements

+ -	$(SPHINXBUILD) -b man $(ALLSPHINXOPTS) $(BUILDDIR)/man

+ -	@echo

+ -	@echo "Build finished. The manual pages are in $(BUILDDIR)/man."

+ -

+ -texinfo: doc-requirements

+ -	$(SPHINXBUILD) -b texinfo $(ALLSPHINXOPTS) $(BUILDDIR)/texinfo

+ -	@echo

+ -	@echo "Build finished. The Texinfo files are in $(BUILDDIR)/texinfo."

+ -	@echo "Run \`make' in that directory to run these through makeinfo" \

+ -	      "(use \`make info' here to do that automatically)."

+ -

+ -info: doc-requirements

+ -	$(SPHINXBUILD) -b texinfo $(ALLSPHINXOPTS) $(BUILDDIR)/texinfo

+ -	@echo "Running Texinfo files through makeinfo..."

+ -	make -C $(BUILDDIR)/texinfo info

+ -	@echo "makeinfo finished; the Info files are in $(BUILDDIR)/texinfo."

+ -

+ -gettext: doc-requirements

+ -	$(SPHINXBUILD) -b gettext $(I18NSPHINXOPTS) $(BUILDDIR)/locale

+ -	@echo

+ -	@echo "Build finished. The message catalogs are in $(BUILDDIR)/locale."

+ -

+ -changes: doc-requirements

+ -	$(SPHINXBUILD) -b changes $(ALLSPHINXOPTS) $(BUILDDIR)/changes

+ -	@echo

+ -	@echo "The overview file is in $(BUILDDIR)/changes."

+ -

+ -linkcheck: doc-requirements

+ -	$(SPHINXBUILD) -b linkcheck $(ALLSPHINXOPTS) $(BUILDDIR)/linkcheck

+ -	@echo

+ -	@echo "Link check complete; look for any errors in the above output " \

+ -	      "or in $(BUILDDIR)/linkcheck/output.txt."

+ -

+ -doctest: doc-requirements

+ -	$(SPHINXBUILD) -b doctest $(ALLSPHINXOPTS) $(BUILDDIR)/doctest

+ -	@echo "Testing of doctests in the sources finished, look at the " \

+ -	      "results in $(BUILDDIR)/doctest/output.txt."

+ -

+ -xml: doc-requirements

+ -	$(SPHINXBUILD) -b xml $(ALLSPHINXOPTS) $(BUILDDIR)/xml

+ -	@echo

+ -	@echo "Build finished. The XML files are in $(BUILDDIR)/xml."

+ -

+ -pseudoxml: doc-requirements

+ -	$(SPHINXBUILD) -b pseudoxml $(ALLSPHINXOPTS) $(BUILDDIR)/pseudoxml

+ -	@echo

+ -	@echo "Build finished. The pseudo-XML files are in $(BUILDDIR)/pseudoxml."

+ +# Catch-all target: route all unknown targets to Sphinx using the new

+ +# "make mode" option.  $(O) is meant as a shortcut for $(SPHINXOPTS).

+ +%: Makefile

+ +	@$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)

+ diff --git a/docs/conf.py b/docs/conf.py

+ index 1db7cf5..6fee8d5 100644

+ --- a/docs/conf.py

+ +++ b/docs/conf.py

+ @@ -1,9 +1,9 @@

+  # -*- coding: utf-8 -*-

+ -#

+  # This file is execfile()d with the current directory set to its containing dir.

+  #

+ -# Note that not all possible configuration values are present in this

+ -# autogenerated file.

+ +# This file only contains a selection of the most common options. For a full

+ +# list see the documentation:

+ +# https://www.sphinx-doc.org/en/master/usage/configuration.html

+  #

+  # All configuration values have a default; values that are commented out

+  # serve to show the default.

+ @@ -13,22 +13,24 @@ import sys

+  import inspect

+  import shutil

+  

+ -__location__ = os.path.join(os.getcwd(), os.path.dirname(

+ -    inspect.getfile(inspect.currentframe())))

+ -

+  # Support markdown

+  from recommonmark.parser import CommonMarkParser

+ -

+  source_parsers = {

+      '.md': CommonMarkParser,

+  }

+  

+ +# -- Path setup --------------------------------------------------------------

+ +

+ +__location__ = os.path.join(

+ +    os.getcwd(), os.path.dirname(inspect.getfile(inspect.currentframe()))

+ +)

+ +

+  # If extensions (or modules to document with autodoc) are in another directory,

+  # add these directories to sys.path here. If the directory is relative to the

+  # documentation root, use os.path.abspath to make it absolute, like shown here.

+ -sys.path.insert(0, os.path.join(__location__, '../src'))

+ +sys.path.insert(0, os.path.join(__location__, "../src"))

+  

+ -# -- Run sphinx-apidoc ------------------------------------------------------

+ +# -- Run sphinx-apidoc -------------------------------------------------------

+  # This hack is necessary since RTD does not issue `sphinx-apidoc` before running

+  # `sphinx-build -b html . _build/html`. See Issue:

+  # https://github.com/rtfd/readthedocs.org/issues/1139

+ @@ -50,55 +52,65 @@ except FileNotFoundError:

+  

+  try:

+      import sphinx

+ -    from pkg_resources import parse_version

+  

+ -    cmd_line_template = "sphinx-apidoc -f -o {outputdir} {moduledir}"

+ +    cmd_line_template = (

+ +        "sphinx-apidoc --implicit-namespaces -f -o {outputdir} {moduledir}"

+ +    )

+      cmd_line = cmd_line_template.format(outputdir=output_dir, moduledir=module_dir)

+  

+      args = cmd_line.split(" ")

+ -    if parse_version(sphinx.__version__) >= parse_version('1.7'):

+ +    if tuple(sphinx.__version__.split(".")) >= ("1", "7"):

+ +        # This is a rudimentary parse_version to avoid external dependencies

+          args = args[1:]

+  

+      apidoc.main(args)

+  except Exception as e:

+      print("Running `sphinx-apidoc` failed!\n{}".format(e))

+  

+ -# -- General configuration -----------------------------------------------------

+ +# -- General configuration ---------------------------------------------------

+  

+  # If your documentation needs a minimal Sphinx version, state it here.

+  # needs_sphinx = '1.0'

+  

+  # Add any Sphinx extension module names here, as strings. They can be extensions

+  # coming with Sphinx (named 'sphinx.ext.*') or your custom ones.

+ -extensions = ['sphinx.ext.autodoc', 'sphinx.ext.intersphinx', 'sphinx.ext.todo',

+ -              'sphinx.ext.autosummary', 'sphinx.ext.viewcode', 'sphinx.ext.coverage',

+ -              'sphinx.ext.doctest', 'sphinx.ext.ifconfig', 'sphinx.ext.mathjax',

+ -              'sphinx.ext.napoleon']

+ +extensions = [

+ +    "sphinx.ext.autodoc",

+ +    "sphinx.ext.intersphinx",

+ +    "sphinx.ext.todo",

+ +    "sphinx.ext.autosummary",

+ +    "sphinx.ext.viewcode",

+ +    "sphinx.ext.coverage",

+ +    "sphinx.ext.doctest",

+ +    "sphinx.ext.ifconfig",

+ +    "sphinx.ext.mathjax",

+ +    "sphinx.ext.napoleon",

+ +]

+  

+  # Add any paths that contain templates here, relative to this directory.

+ -templates_path = ['_templates']

+ +templates_path = ["_templates"]

+  

+  # The suffix of source filenames.

+ -source_suffix = ['.rst', '.md']

+ +source_suffix = [".rst", ".md"]

+  

+  # The encoding of source files.

+  # source_encoding = 'utf-8-sig'

+  

+  # The master toctree document.

+ -master_doc = 'index'

+ +master_doc = "index"

+  

+  # General information about the project.

+ -project = u'SALib'

+ -copyright = u'2019, Jon Herman, Will Usher and others'

+ +project = "SALib"

+ +copyright = "2021, Jon Herman, Will Usher and others"

+  

+  # The version info for the project you're documenting, acts as replacement for

+  # |version| and |release|, also used in various other places throughout the

+  # built documents.

+  #

+  # The short X.Y version.

+ -version = ''  # Is set by calling `setup.py docs`

+ +version = ""  # Is set by calling `setup.py docs`

+  # The full version, including alpha/beta/rc tags.

+ -release = ''  # Is set by calling `setup.py docs`

+ +release = ""  # Is set by calling `setup.py docs`

+  

+  # The language for content autogenerated by Sphinx. Refer to documentation

+  # for a list of supported languages.

+ @@ -112,7 +124,7 @@ release = ''  # Is set by calling `setup.py docs`

+  

+  # List of patterns, relative to source directory, that match files and

+  # directories to ignore when looking for source files.

+ -exclude_patterns = ['_build']

+ +exclude_patterns = ["_build", "Thumbs.db", ".DS_Store", ".venv"]

+  

+  # The reST default role (used for this markup: `text`) to use for all documents.

+  # default_role = None

+ @@ -129,7 +141,7 @@ exclude_patterns = ['_build']

+  # show_authors = False

+  

+  # The name of the Pygments (syntax highlighting) style to use.

+ -pygments_style = 'sphinx'

+ +pygments_style = "sphinx"

+  

+  # A list of ignored prefixes for module index sorting.

+  # modindex_common_prefix = []

+ @@ -138,18 +150,18 @@ pygments_style = 'sphinx'

+  # keep_warnings = False

+  

+  

+ -# -- Options for HTML output ---------------------------------------------------

+ +# -- Options for HTML output -------------------------------------------------

+  

+  # The theme to use for HTML and HTML Help pages.  See the documentation for

+  # a list of builtin themes.

+ -html_theme = 'alabaster'

+ +html_theme = "alabaster"

+  

+  # Theme options are theme-specific and customize the look and feel of a theme

+  # further.  For a list of options available for each theme, see the

+  # documentation.

+  html_theme_options = {

+ -    'sidebar_width': '300px',

+ -    'page_width': '1200px'

+ +    "sidebar_width": "300px",

+ +    "page_width": "1200px"

+  }

+  

+  # Add any paths that contain custom themes here, relative to this directory.

+ @@ -179,7 +191,7 @@ else:

+  # Add any paths that contain custom static files (such as style sheets) here,

+  # relative to this directory. They are copied after the builtin static files,

+  # so a file named "default.css" will overwrite the builtin "default.css".

+ -html_static_path = ['_static']

+ +html_static_path = ["_static"]

+  

+  # If not '', a 'Last updated on:' timestamp is inserted at every page bottom,

+  # using the given strftime format.

+ @@ -223,27 +235,24 @@ html_static_path = ['_static']

+  # html_file_suffix = None

+  

+  # Output file base name for HTML help builder.

+ -htmlhelp_basename = 'salib-doc'

+ +htmlhelp_basename = "SALib-doc"

+  

+  

+ -# -- Options for LaTeX output --------------------------------------------------

+ +# -- Options for LaTeX output ------------------------------------------------

+  

+  latex_elements = {

+ -# The paper size ('letterpaper' or 'a4paper').

+ -# 'papersize': 'letterpaper',

+ -

+ -# The font size ('10pt', '11pt' or '12pt').

+ -# 'pointsize': '10pt',

+ -

+ -# Additional stuff for the LaTeX preamble.

+ -# 'preamble': '',

+ +    # The paper size ("letterpaper" or "a4paper").

+ +    # "papersize": "letterpaper",

+ +    # The font size ("10pt", "11pt" or "12pt").

+ +    # "pointsize": "10pt",

+ +    # Additional stuff for the LaTeX preamble.

+ +    # "preamble": "",

+  }

+  

+  # Grouping the document tree into LaTeX files. List of tuples

+  # (source start file, target name, title, author, documentclass [howto/manual]).

+  latex_documents = [

+ -  ('index', 'user_guide.tex', u'SALib Documentation',

+ -   u'Jon Herman, Will Usher and others', 'manual'),

+ +    ("index", "user_guide.tex", "SALib Documentation", "Jon Herman, Will Usher and others", "manual")

+  ]

+  

+  # The name of an image file (relative to this directory) to place at the top of

+ @@ -266,14 +275,15 @@ latex_documents = [

+  # If false, no module index is generated.

+  # latex_domain_indices = True

+  

+ -# -- External mapping ------------------------------------------------------------

+ -python_version = '.'.join(map(str, sys.version_info[0:2]))

+ +# -- External mapping --------------------------------------------------------

+ +python_version = ".".join(map(str, sys.version_info[0:2]))

+  intersphinx_mapping = {

+ -    'sphinx': ('http://www.sphinx-doc.org/en/stable', None),

+ -    'python': ('https://docs.python.org/' + python_version, None),

+ -    'matplotlib': ('https://matplotlib.org', None),

+ -    'numpy': ('https://docs.scipy.org/doc/numpy', None),

+ -    'sklearn': ('http://scikit-learn.org/stable', None),

+ -    'pandas': ('http://pandas.pydata.org/pandas-docs/stable', None),

+ -    'scipy': ('https://docs.scipy.org/doc/scipy/reference', None),

+ +    "sphinx": ("http://www.sphinx-doc.org/en/stable", None),

+ +    "python": ("https://docs.python.org/" + python_version, None),

+ +    "matplotlib": ("https://matplotlib.org", None),

+ +    "numpy": ("https://docs.scipy.org/doc/numpy", None),

+ +    "sklearn": ("https://scikit-learn.org/stable", None),

+ +    "pandas": ("https://pandas.pydata.org/pandas-docs/stable", None),

+ +    "scipy": ("https://docs.scipy.org/doc/scipy/reference", None),

+ +    "pyscaffold": ("https://pyscaffold.org/en/stable", None),

+  }

+ diff --git a/setup.cfg b/setup.cfg

+ index 4da5eda..0dbf80c 100644

+ --- a/setup.cfg

+ +++ b/setup.cfg

+ @@ -26,15 +26,22 @@ platforms = any

+  

+  [options]

+  zip_safe = False

+ -packages = find:

+ +packages = find_namespace:

+  include_package_data = True

+  package_dir =

+      =src

+  # DON'T CHANGE THE FOLLOWING LINE! IT WILL BE UPDATED BY PYSCAFFOLD!

+ -setup_requires = pyscaffold>=3.2a0,<3.3a0

+  # Add here dependencies of your project (semicolon-separated), e.g.

+  # install_requires = numpy; scipy

+ -install_requires = numpy; scipy; matplotlib; pandas; pathos; setuptools; wheel

+ +install_requires =

+ +    importlib-metadata; python_version<"3.8"

+ +    numpy

+ +    scipy

+ +    matplotlib

+ +    pandas

+ +    pathos

+ +    setuptools

+ +    wheel

+  

+  # Add here test requirements (semicolon-separated)

+  tests_require = pytest; pytest-cov

+ @@ -124,7 +131,7 @@ exclude =

+  [pyscaffold]

+  # PyScaffold's parameters when the project was created.

+  # This will be used when updating. Do not change!

+ -version = 3.2.2

+ +version = 4.0.2

+  package = SALib

+  extensions =

+      no_skeleton

+ diff --git a/setup.py b/setup.py

+ index 1420fce..b09462d 100644

+ --- a/setup.py

+ +++ b/setup.py

+ @@ -1,28 +1,30 @@

+  # -*- coding: utf-8 -*-

+  """

+ -    Setup file for salib.

+ +    Setup file for SALib.

+      Use setup.cfg to configure your project.

+  

+ -    This file was generated with PyScaffold 3.2.2.

+ +    This file was generated with PyScaffold 4.0.2.

+      PyScaffold helps you to put up the scaffold of your new Python project.

+      Learn more under: https://pyscaffold.org/

+  """

+  import os

+  import sys

+  

+ -from pkg_resources import VersionConflict, require

+  from setuptools import setup

+  

+  scripts = ['src/SALib/scripts/salib.py']

+  if os.name == 'nt':

+      scripts.append('src/SALib/scripts/salib.bat')

+  

+ -try:

+ -    require('setuptools>=38.3')

+ -except VersionConflict:

+ -    print("Error: version of setuptools is too old (<38.3)!")

+ -    sys.exit(1)

+ -

+ -

+  if __name__ == "__main__":

+ -    setup(use_pyscaffold=True, scripts=scripts)

+ +    try:

+ +        setup(use_scm_version={"version_scheme": "no-guess-dev"},

+ +              scripts=scripts)

+ +    except:  # noqa

+ +        print(

+ +            "\n\nAn error occurred while building the project, "

+ +            "please ensure you have the most updated version of setuptools, "

+ +            "setuptools_scm and wheel with:\n"

+ +            "   pip install -U setuptools setuptools_scm wheel\n\n"

+ +        )

+ +        raise

+ diff --git a/src/SALib/__init__.py b/src/SALib/__init__.py

+ index 43a144f..8b04532 100644

+ --- a/src/SALib/__init__.py

+ +++ b/src/SALib/__init__.py

+ @@ -1,12 +1,17 @@

+  # -*- coding: utf-8 -*-

+ -from pkg_resources import get_distribution, DistributionNotFound

+ +import sys

+  from SALib.util import ProblemSpec

+ +if sys.version_info[:2] >= (3, 8):

+ +    # TODO: Import directly (no need for conditional) when `python_requires = >= 3.8`

+ +    from importlib.metadata import PackageNotFoundError, version  # pragma: no cover

+ +else:

+ +    from importlib_metadata import PackageNotFoundError, version  # pragma: no cover

+  

+  try:

+      # Change here if project is renamed and does not equal the package name

+ -    dist_name = 'SALib'

+ -    __version__ = get_distribution(dist_name).version

+ -except DistributionNotFound:

+ -    __version__ = 'unknown'

+ +    dist_name = __name__

+ +    __version__ = version(dist_name)

+ +except PackageNotFoundError:  # pragma: no cover

+ +    __version__ = "unknown"

+  finally:

+ -    del get_distribution, DistributionNotFound

+ +    del version, PackageNotFoundError

+ -- 

+ 2.31.1

+ 

file modified
+32 -29
@@ -24,16 +24,21 @@ 

  - Fractional Factorial Sensitivity Analysis (Saltelli et al. 2008)}

  

  Name:           python-%{srcname}

- Version:        1.3.11

- Release:        7%{?dist}

+ Version:        1.4.0.2

+ Release:        1%{?dist}

  Summary:        Sensitivity Analysis Library

  

  License:        MIT

  URL:            http://salib.github.io/SALib/

- Source0:        %pypi_source

+ Source0:        https://github.com/%{srcname}/%{srcname}/archive/v%{version}/%{name}-%{version}.tar.gz

+ 

+ # Patches for pyscaffold v4

+ Patch0:         0001-build-pyscaffold-update-existing-files-for-pyscaffol.patch

  

  BuildArch:      noarch

  

+ BuildRequires: pyproject-rpm-macros

+ 

  %{?python_enable_dependency_generator}

  

  %description %_description
@@ -41,7 +46,11 @@ 

  %package -n python3-%{srcname}

  Summary:        %{summary}

  BuildRequires:  python3-devel

- BuildRequires:  %{py3_dist setuptools}

+ BuildRequires:  git

+ %if %{with tests}

+ BuildRequires:  %{py3_dist pytest}

+ BuildRequires:  %{py3_dist pytest-cov}

+ %endif

  

  # Not mentioned in setup.py, so won't be picked up by the generator

  Requires:  %{py3_dist pandas}
@@ -49,18 +58,6 @@ 

  Requires:  %{py3_dist scipy}

  Requires:  %{py3_dist matplotlib} >= 1.4.3

  

- %if %{with tests}

- BuildRequires:  %{py3_dist pytest}

- BuildRequires:  %{py3_dist pytest-cov}

- BuildRequires:  %{py3_dist pandas}

- BuildRequires:  %{py3_dist numpy} >= 1.9.0

- BuildRequires:  %{py3_dist scipy}

- BuildRequires:  %{py3_dist matplotlib} >= 1.4.3

- BuildRequires:  %{py3_dist pyscaffold}

- %endif

- 

- %{?python_provide:%python_provide python3-%{srcname}}

- 

  %description -n python3-%{srcname} %_description

  

  %package doc
@@ -72,11 +69,7 @@ 

  Documentation for %{name}.

  

  %prep

- %autosetup -n %{srcname}-%{version}

- # Remove egg info

- rm -rf src/%{srcname}.egg-info

- # Remove uneeded version lock on pyscaffold

- sed -i "s/pyscaffold.*']/pyscaffold']/" setup.py

+ %autosetup -n %{srcname}-%{version} -S git

  

  # python3, not python in tests

  sed -i 's/python {cli}/python3 {cli}/' tests/test_cli_sample.py
@@ -95,36 +88,46 @@ 

  sed -i 's/\r$//' LICENSE.txt

  sed -i 's/\r$//' src/SALib/analyze/rbd_fast.py

  

+ %generate_buildrequires

+ %if %{with tests}

+ %pyproject_buildrequires -r

+ %else

+ %pyproject_buildrequires

+ %endif

+ 

  %build

- %py3_build

+ %pyproject_wheel

  

  sphinx-build-%{python3_version} docs html-docs

  rm -rf html-docs/{.doctrees,.buildinfo} -vf

  

  %install

- %py3_install

+ %pyproject_install

+ %pyproject_save_files %{srcname}

  

  # Add a shebang to missing script

  sed -i "1 i \#\!%{__python3}" $RPM_BUILD_ROOT/%{_bindir}/salib.py

  

  %check

  %if %{with tests}

- PYTHONPATH=$RPM_BUILD_ROOT%{python3_sitelib} pytest-%{python3_version}

+ PYTHONPATH=$RPM_BUILD_ROOT%{python3_sitelib} %{pytest}

  %endif

  

- %files -n python3-%{srcname}

+ %files -n python3-%{srcname} -f %{pyproject_files}

  %license LICENSE.txt

- %doc README.rst README-advanced.md CHANGELOG.rst CITATIONS.rst AUTHORS.rst

- %{python3_sitelib}/%{srcname}

- %{python3_sitelib}/%{srcname}-%{version}-py%{python3_version}.egg-info

+ %doc README.rst README-advanced.md CHANGELOG.md CITATIONS.rst AUTHORS.rst FAQ.MD

  %{_bindir}/salib

  %{_bindir}/salib.py

  

  %files doc

  %license LICENSE.txt

- %doc html-docs

+ %doc html-docs CODE_OF_CONDUCT.md CONTRIBUTING.md

  

  %changelog

+ * Fri Sep 03 2021 Ankur Sinha <ankursinha AT fedoraproject DOT org> - 1.4.0.2-1

+ - Update to new release

+ - Use pyproject macros

+ 

  * Fri Jul 23 2021 Fedora Release Engineering <releng@fedoraproject.org> - 1.3.11-7

  - Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild

  

file modified
+1 -1
@@ -1,1 +1,1 @@ 

- SHA512 (SALib-1.3.11.tar.gz) = 9a09b3163dd765b86636977a1d1cb13d02c743ef85b31fd363648aa75dfa3d6272731bb2209fc0913b972f619e908cc4b6124915c670c0fff693e89864a24f51

+ SHA512 (python-SALib-1.4.0.2.tar.gz) = b3fa0db3787f2e7027719c6f0fab498efdf7007a8cdd5f7c85be9109eb9a3845796d3ec887f1ebedf5c2a3c713546c8efd2f42a823231ac2725203ac35c18058

WIP: requires pathos which isn't in Fedora

rebased onto 13522f5

a year ago

Pull-Request has been merged by ankursinha

a year ago