Script 'mail_helper' called by obssrc Hello community, here is the log from the commit of package python-pyct for openSUSE:Factory checked in at 2023-02-22 15:21:38 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/python-pyct (Old) and /work/SRC/openSUSE:Factory/.python-pyct.new.1706 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python-pyct" Wed Feb 22 15:21:38 2023 rev:4 rq:1067094 version:0.5.0 Changes: -------- --- /work/SRC/openSUSE:Factory/python-pyct/python-pyct.changes 2022-08-22 11:05:11.189708634 +0200 +++ /work/SRC/openSUSE:Factory/.python-pyct.new.1706/python-pyct.changes 2023-02-22 15:21:42.865904802 +0100 @@ -1,0 +2,7 @@ +Wed Feb 22 07:03:54 UTC 2023 - Steve Kowalik <steven.kowa...@suse.com> + +- Update to 0.5.0: + * Minor release that drops support of Python 2.7 and 3.7 and adds + support to Python 3.11. + +------------------------------------------------------------------- Old: ---- pyct-0.4.8.tar.gz New: ---- pyct-0.5.0.tar.gz ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ python-pyct.spec ++++++ --- /var/tmp/diff_new_pack.5l0r4k/_old 2023-02-22 15:21:43.313907343 +0100 +++ /var/tmp/diff_new_pack.5l0r4k/_new 2023-02-22 15:21:43.317907366 +0100 @@ -1,7 +1,7 @@ # # spec file for package python-pyct # -# Copyright (c) 2022 SUSE LLC +# Copyright (c) 2023 SUSE LLC # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -16,13 +16,11 @@ # -%{?!python_module:%define python_module() python-%{**} python3-%{**}} Name: python-pyct -Version: 0.4.8 +Version: 0.5.0 Release: 0 Summary: Python package for common tasks for users License: BSD-3-Clause -Group: Development/Languages/Python URL: https://github.com/pyviz/pyct Source0: https://files.pythonhosted.org/packages/source/p/pyct/pyct-%{version}.tar.gz Source100: python-pyct-rpmlintrc @@ -36,6 +34,7 @@ # SECTION test requirements BuildRequires: %{python_module PyYAML} BuildRequires: %{python_module flake8} +BuildRequires: %{python_module numpy} BuildRequires: %{python_module param >= 1.7.0} BuildRequires: %{python_module pytest} BuildRequires: %{python_module requests} ++++++ pyct-0.4.8.tar.gz -> pyct-0.5.0.tar.gz ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pyct-0.4.8/PKG-INFO new/pyct-0.5.0/PKG-INFO --- old/pyct-0.4.8/PKG-INFO 2020-09-11 23:35:50.000000000 +0200 +++ new/pyct-0.5.0/PKG-INFO 2023-01-30 12:10:58.000000000 +0100 @@ -1,180 +1,183 @@ Metadata-Version: 2.1 Name: pyct -Version: 0.4.8 +Version: 0.5.0 Summary: Python package common tasks for users (e.g. copy examples, fetch data, ...) Home-page: https://github.com/pyviz-dev/pyct Author: HoloViz -Author-email: holovi...@gmail.com +Author-email: develop...@holoviz.org Maintainer: HoloViz -Maintainer-email: holovi...@gmail.com +Maintainer-email: develop...@holoviz.org License: BSD 3-Clause License Project-URL: Bug Tracker, https://github.com/pyviz-dev/pyct/issues Project-URL: Source Code, https://github.com/pyviz-dev/pyct -Description: # pyct - - A utility package that includes: - - 1. **pyct.cmd**: Makes various commands available to other - packages. (Currently no sophisticated plugin system, just a try - import/except in the other packages.) The same commands are - available from within python. Can either add new subcommands to - an existing argparse based command if the module has an existing - command, or create the entire command if the module has no - existing command. Currently, there are commands for copying - examples and fetching data. See - - 2. **pyct.build**: Provides various commands to help package - building, primarily as a convenience for project maintainers. - - ## pyct.cmd - - To install pyct with the dependencies required for pyct.cmd: `pip - install pyct[cmd]` or `conda install -c pyviz pyct`. - - An example of how to use in a project: - https://github.com/ioam/geoviews/blob/master/geoviews/__main__.py - - Once added, users can copy the examples of a package and download the - required data with the `examples` command: - - ``` - $ datashader examples --help - usage: datashader examples [-h] [--path PATH] [-v] [--force] [--use-test-data] - - optional arguments: - -h, --help show this help message and exit - --path PATH location to place examples and data - -v, --verbose - --force if PATH already exists, force overwrite existing examples - if older than source examples. ALSO force any existing data - files to be replaced - --use-test-data Use data's test files, if any, instead of fetching full - data. If test file not in '.data_stubs', fall back to - fetching full data. - ``` - - To copy the examples of e.g. datashader but not download the data, - there's a `copy-examples` command: - - ``` - usage: datashader copy-examples [-h] [--path PATH] [-v] [--force] - - optional arguments: - -h, --help show this help message and exit - --path PATH where to copy examples - -v, --verbose - --force if PATH already exists, force overwrite existing files if - older than source files - ``` - - And to download the data only, the `fetch-data` command: - - ``` - usage: datashader fetch-data [-h] [--path PATH] [--datasets DATASETS] [-v] - [--force] [--use-test-data] - - optional arguments: - -h, --help show this help message and exit - --path PATH where to put data - --datasets DATASETS *name* of datasets file; must exist either in path - specified by --path or in package/examples/ - -v, --verbose - --force Force any existing data files to be replaced - --use-test-data Use data's test files, if any, instead of fetching full - data. If test file not in '.data_stubs', fall back to - fetching full data. - ``` - - Can specify different 'datasets' file: - - ``` - $ cat earthsim-examples/test.yml - --- - - data: - - - url: http://s3.amazonaws.com/datashader-data/Chesapeake_and_Delaware_Bays.zip - title: 'Depth data for the Chesapeake and Delaware Bay region of the USA' - files: - - Chesapeake_and_Delaware_Bays.3dm - - $ earthsim fetch-data --path earthsim-examples --datasets-filename test.yml - Downloading data defined in /tmp/earthsim-examples/test.yml to /tmp/earthsim-examples/data - Skipping Depth data for the Chesapeake and Delaware Bay region of the USA - ``` - - Can use smaller files instead of large ones by using the `--use-test-data` flag - and placing a small file with the same name in `examples/data/.data_stubs`: - - ``` - $ tree examples/data -a - examples/data - âââ .data_stubs - â  âââ nyc_taxi_wide.parq - âââ diamonds.csv - - $ cat examples/dataset.yml - data: - - - url: http://s3.amazonaws.com/datashader-data/nyc_taxi_wide.parq - title: 'NYC Taxi Data' - files: - - nyc_taxi_wide.parq - - - url: http://s3.amazonaws.com/datashader-data/maccdc2012_graph.zip - title: 'National CyberWatch Mid-Atlantic Collegiate Cyber Defense Competition' - files: - - maccdc2012_nodes.parq - - maccdc2012_edges.parq - - maccdc2012_full_nodes.parq - - maccdc2012_full_edges.parq - - $ pyviz fetch-data --path=examples --use-test-data - Fetching data defined in /tmp/pyviz/examples/datasets.yml and placing in /tmp/pyviz/examples/data - Copying test data file '/tmp/pyviz/examples/data/.data_stubs/nyc_taxi_wide.parq' to '/tmp/pyviz/examples/data/nyc_taxi_wide.parq' - No test file found for: /tmp/pyviz/examples/data/.data_stubs/maccdc2012_nodes.parq. Using regular file instead - Downloading National CyberWatch Mid-Atlantic Collegiate Cyber Defense Competition 1 of 1 - [################################] 59/59 - 00:00:00 - ``` - - To clean up any potential test files masquerading as real data use `clean-data`: - - ``` - usage: pyviz clean-data [-h] [--path PATH] - - optional arguments: - -h, --help show this help message and exit - --path PATH where to clean data - ``` - - ## pyct.build - - Currently provides a way to package examples with a project, by - copying an examples folder into the package directory whenever - setup.py is run. The way this works is likely to change in the near - future, but is provided here as the first step towards - unifying/simplifying the maintenance of a number of pyviz projects. - - ## pyct report - - Provides a way to check the package versions in the current environment using: - 1. A console script (entry point): `pyct report [packages]`, or - 2. A python function: `import pyct; pyct.report(packages)` - - The python function can be particularly useful for e.g. jupyter notebook users, since it is the packages in the current kernel that we usually care about (not those in the environment from which jupyter notebook server/lab was launched). - - Note that `packages` above can include the name of any Python package (returning the `__version__`), along with the special cases `python` or `conda` (returning the version of the command-line tool) or `system` (returning the OS version). - -Platform: UNKNOWN Classifier: License :: OSI Approved :: BSD License Classifier: Operating System :: OS Independent Classifier: Programming Language :: Python -Classifier: Programming Language :: Python :: 2.7 -Classifier: Programming Language :: Python :: 3.6 +Classifier: Programming Language :: Python :: 3.7 +Classifier: Programming Language :: Python :: 3.8 +Classifier: Programming Language :: Python :: 3.9 +Classifier: Programming Language :: Python :: 3.10 +Classifier: Programming Language :: Python :: 3.11 Classifier: Development Status :: 4 - Beta -Requires-Python: >=2.7 +Requires-Python: >=3.7 Description-Content-Type: text/markdown Provides-Extra: cmd Provides-Extra: tests Provides-Extra: doc Provides-Extra: build +License-File: LICENSE.txt + +# pyct + +A utility package that includes: + + 1. **pyct.cmd**: Makes various commands available to other + packages. (Currently no sophisticated plugin system, just a try + import/except in the other packages.) The same commands are + available from within python. Can either add new subcommands to + an existing argparse based command if the module has an existing + command, or create the entire command if the module has no + existing command. Currently, there are commands for copying + examples and fetching data. See + + 2. **pyct.build**: Provides various commands to help package + building, primarily as a convenience for project maintainers. + +## pyct.cmd + +To install pyct with the dependencies required for pyct.cmd: `pip +install pyct[cmd]` or `conda install -c pyviz pyct`. + +An example of how to use in a project: +https://github.com/holoviz/geoviews/blob/main/geoviews/__main__.py + +Once added, users can copy the examples of a package and download the +required data with the `examples` command: + +``` +$ datashader examples --help +usage: datashader examples [-h] [--path PATH] [-v] [--force] [--use-test-data] + +optional arguments: + -h, --help show this help message and exit + --path PATH location to place examples and data + -v, --verbose + --force if PATH already exists, force overwrite existing examples + if older than source examples. ALSO force any existing data + files to be replaced + --use-test-data Use data's test files, if any, instead of fetching full + data. If test file not in '.data_stubs', fall back to + fetching full data. +``` + +To copy the examples of e.g. datashader but not download the data, +there's a `copy-examples` command: + +``` +usage: datashader copy-examples [-h] [--path PATH] [-v] [--force] + +optional arguments: + -h, --help show this help message and exit + --path PATH where to copy examples + -v, --verbose + --force if PATH already exists, force overwrite existing files if + older than source files +``` + +And to download the data only, the `fetch-data` command: + +``` +usage: datashader fetch-data [-h] [--path PATH] [--datasets DATASETS] [-v] + [--force] [--use-test-data] + +optional arguments: + -h, --help show this help message and exit + --path PATH where to put data + --datasets DATASETS *name* of datasets file; must exist either in path + specified by --path or in package/examples/ + -v, --verbose + --force Force any existing data files to be replaced + --use-test-data Use data's test files, if any, instead of fetching full + data. If test file not in '.data_stubs', fall back to + fetching full data. +``` + +Can specify different 'datasets' file: + +``` +$ cat earthsim-examples/test.yml +--- + +data: + + - url: http://s3.amazonaws.com/datashader-data/Chesapeake_and_Delaware_Bays.zip + title: 'Depth data for the Chesapeake and Delaware Bay region of the USA' + files: + - Chesapeake_and_Delaware_Bays.3dm + +$ earthsim fetch-data --path earthsim-examples --datasets-filename test.yml +Downloading data defined in /tmp/earthsim-examples/test.yml to /tmp/earthsim-examples/data +Skipping Depth data for the Chesapeake and Delaware Bay region of the USA +``` + +Can use smaller files instead of large ones by using the `--use-test-data` flag +and placing a small file with the same name in `examples/data/.data_stubs`: + +``` +$ tree examples/data -a +examples/data +âââ .data_stubs +â  âââ nyc_taxi_wide.parq +âââ diamonds.csv + +$ cat examples/dataset.yml +data: + + - url: http://s3.amazonaws.com/datashader-data/nyc_taxi_wide.parq + title: 'NYC Taxi Data' + files: + - nyc_taxi_wide.parq + + - url: http://s3.amazonaws.com/datashader-data/maccdc2012_graph.zip + title: 'National CyberWatch Mid-Atlantic Collegiate Cyber Defense Competition' + files: + - maccdc2012_nodes.parq + - maccdc2012_edges.parq + - maccdc2012_full_nodes.parq + - maccdc2012_full_edges.parq + +$ pyviz fetch-data --path=examples --use-test-data +Fetching data defined in /tmp/pyviz/examples/datasets.yml and placing in /tmp/pyviz/examples/data +Copying test data file '/tmp/pyviz/examples/data/.data_stubs/nyc_taxi_wide.parq' to '/tmp/pyviz/examples/data/nyc_taxi_wide.parq' +No test file found for: /tmp/pyviz/examples/data/.data_stubs/maccdc2012_nodes.parq. Using regular file instead +Downloading National CyberWatch Mid-Atlantic Collegiate Cyber Defense Competition 1 of 1 +[################################] 59/59 - 00:00:00 +``` + +To clean up any potential test files masquerading as real data use `clean-data`: + +``` +usage: pyviz clean-data [-h] [--path PATH] + +optional arguments: + -h, --help show this help message and exit + --path PATH where to clean data +``` + +## pyct.build + +Currently provides a way to package examples with a project, by +copying an examples folder into the package directory whenever +setup.py is run. The way this works is likely to change in the near +future, but is provided here as the first step towards +unifying/simplifying the maintenance of a number of pyviz projects. + +## pyct report + +Provides a way to check the package versions in the current environment using: + 1. A console script (entry point): `pyct report [packages]`, or + 2. A python function: `import pyct; pyct.report(packages)` + +The python function can be particularly useful for e.g. jupyter notebook users, since it is the packages in the current kernel that we usually care about (not those in the environment from which jupyter notebook server/lab was launched). + +Note that `packages` above can include the name of any Python package (returning the `__version__`), along with the special cases `python` or `conda` (returning the version of the command-line tool) or `system` (returning the OS version). diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pyct-0.4.8/README.md new/pyct-0.5.0/README.md --- old/pyct-0.4.8/README.md 2020-09-11 23:34:29.000000000 +0200 +++ new/pyct-0.5.0/README.md 2023-01-30 12:08:19.000000000 +0100 @@ -20,7 +20,7 @@ install pyct[cmd]` or `conda install -c pyviz pyct`. An example of how to use in a project: -https://github.com/ioam/geoviews/blob/master/geoviews/__main__.py +https://github.com/holoviz/geoviews/blob/main/geoviews/__main__.py Once added, users can copy the examples of a package and download the required data with the `examples` command: diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pyct-0.4.8/pyct/.version new/pyct-0.5.0/pyct/.version --- old/pyct-0.4.8/pyct/.version 2020-09-11 23:35:50.000000000 +0200 +++ new/pyct-0.5.0/pyct/.version 2023-01-30 12:10:58.000000000 +0100 @@ -1 +1 @@ -{"git_describe": "v0.4.8-0-g740720a", "version_string": "0.4.8"} \ No newline at end of file +{"git_describe": "v0.5.0-0-gb273398", "version_string": "0.5.0"} \ No newline at end of file diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pyct-0.4.8/pyct/tests/test_report.py new/pyct-0.5.0/pyct/tests/test_report.py --- old/pyct-0.4.8/pyct/tests/test_report.py 2020-09-11 23:34:29.000000000 +0200 +++ new/pyct-0.5.0/pyct/tests/test_report.py 2023-01-30 12:08:19.000000000 +0100 @@ -5,9 +5,9 @@ __version__ = "1.9.3" __file__ = "/mock/opt/anaconda3/envs/pyct/lib/python3.7/site-packages/param/__init__.py" -@patch("builtins.print") @patch("importlib.import_module") -def test_report_gives_package_version(mock_import_module, mock_print): +@patch("builtins.print") +def test_report_gives_package_version(mock_print, mock_import_module): module = TestModule() mock_import_module.return_value = module @@ -47,4 +47,4 @@ def test_unknown_package_output(mock_print): report("fake_package") - mock_print.assert_called_with("fake_package=unknown # not installed in this environment") \ No newline at end of file + mock_print.assert_called_with("fake_package=unknown # not installed in this environment") diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pyct-0.4.8/pyct.egg-info/PKG-INFO new/pyct-0.5.0/pyct.egg-info/PKG-INFO --- old/pyct-0.4.8/pyct.egg-info/PKG-INFO 2020-09-11 23:35:50.000000000 +0200 +++ new/pyct-0.5.0/pyct.egg-info/PKG-INFO 2023-01-30 12:10:58.000000000 +0100 @@ -1,180 +1,183 @@ Metadata-Version: 2.1 Name: pyct -Version: 0.4.8 +Version: 0.5.0 Summary: Python package common tasks for users (e.g. copy examples, fetch data, ...) Home-page: https://github.com/pyviz-dev/pyct Author: HoloViz -Author-email: holovi...@gmail.com +Author-email: develop...@holoviz.org Maintainer: HoloViz -Maintainer-email: holovi...@gmail.com +Maintainer-email: develop...@holoviz.org License: BSD 3-Clause License Project-URL: Bug Tracker, https://github.com/pyviz-dev/pyct/issues Project-URL: Source Code, https://github.com/pyviz-dev/pyct -Description: # pyct - - A utility package that includes: - - 1. **pyct.cmd**: Makes various commands available to other - packages. (Currently no sophisticated plugin system, just a try - import/except in the other packages.) The same commands are - available from within python. Can either add new subcommands to - an existing argparse based command if the module has an existing - command, or create the entire command if the module has no - existing command. Currently, there are commands for copying - examples and fetching data. See - - 2. **pyct.build**: Provides various commands to help package - building, primarily as a convenience for project maintainers. - - ## pyct.cmd - - To install pyct with the dependencies required for pyct.cmd: `pip - install pyct[cmd]` or `conda install -c pyviz pyct`. - - An example of how to use in a project: - https://github.com/ioam/geoviews/blob/master/geoviews/__main__.py - - Once added, users can copy the examples of a package and download the - required data with the `examples` command: - - ``` - $ datashader examples --help - usage: datashader examples [-h] [--path PATH] [-v] [--force] [--use-test-data] - - optional arguments: - -h, --help show this help message and exit - --path PATH location to place examples and data - -v, --verbose - --force if PATH already exists, force overwrite existing examples - if older than source examples. ALSO force any existing data - files to be replaced - --use-test-data Use data's test files, if any, instead of fetching full - data. If test file not in '.data_stubs', fall back to - fetching full data. - ``` - - To copy the examples of e.g. datashader but not download the data, - there's a `copy-examples` command: - - ``` - usage: datashader copy-examples [-h] [--path PATH] [-v] [--force] - - optional arguments: - -h, --help show this help message and exit - --path PATH where to copy examples - -v, --verbose - --force if PATH already exists, force overwrite existing files if - older than source files - ``` - - And to download the data only, the `fetch-data` command: - - ``` - usage: datashader fetch-data [-h] [--path PATH] [--datasets DATASETS] [-v] - [--force] [--use-test-data] - - optional arguments: - -h, --help show this help message and exit - --path PATH where to put data - --datasets DATASETS *name* of datasets file; must exist either in path - specified by --path or in package/examples/ - -v, --verbose - --force Force any existing data files to be replaced - --use-test-data Use data's test files, if any, instead of fetching full - data. If test file not in '.data_stubs', fall back to - fetching full data. - ``` - - Can specify different 'datasets' file: - - ``` - $ cat earthsim-examples/test.yml - --- - - data: - - - url: http://s3.amazonaws.com/datashader-data/Chesapeake_and_Delaware_Bays.zip - title: 'Depth data for the Chesapeake and Delaware Bay region of the USA' - files: - - Chesapeake_and_Delaware_Bays.3dm - - $ earthsim fetch-data --path earthsim-examples --datasets-filename test.yml - Downloading data defined in /tmp/earthsim-examples/test.yml to /tmp/earthsim-examples/data - Skipping Depth data for the Chesapeake and Delaware Bay region of the USA - ``` - - Can use smaller files instead of large ones by using the `--use-test-data` flag - and placing a small file with the same name in `examples/data/.data_stubs`: - - ``` - $ tree examples/data -a - examples/data - âââ .data_stubs - â  âââ nyc_taxi_wide.parq - âââ diamonds.csv - - $ cat examples/dataset.yml - data: - - - url: http://s3.amazonaws.com/datashader-data/nyc_taxi_wide.parq - title: 'NYC Taxi Data' - files: - - nyc_taxi_wide.parq - - - url: http://s3.amazonaws.com/datashader-data/maccdc2012_graph.zip - title: 'National CyberWatch Mid-Atlantic Collegiate Cyber Defense Competition' - files: - - maccdc2012_nodes.parq - - maccdc2012_edges.parq - - maccdc2012_full_nodes.parq - - maccdc2012_full_edges.parq - - $ pyviz fetch-data --path=examples --use-test-data - Fetching data defined in /tmp/pyviz/examples/datasets.yml and placing in /tmp/pyviz/examples/data - Copying test data file '/tmp/pyviz/examples/data/.data_stubs/nyc_taxi_wide.parq' to '/tmp/pyviz/examples/data/nyc_taxi_wide.parq' - No test file found for: /tmp/pyviz/examples/data/.data_stubs/maccdc2012_nodes.parq. Using regular file instead - Downloading National CyberWatch Mid-Atlantic Collegiate Cyber Defense Competition 1 of 1 - [################################] 59/59 - 00:00:00 - ``` - - To clean up any potential test files masquerading as real data use `clean-data`: - - ``` - usage: pyviz clean-data [-h] [--path PATH] - - optional arguments: - -h, --help show this help message and exit - --path PATH where to clean data - ``` - - ## pyct.build - - Currently provides a way to package examples with a project, by - copying an examples folder into the package directory whenever - setup.py is run. The way this works is likely to change in the near - future, but is provided here as the first step towards - unifying/simplifying the maintenance of a number of pyviz projects. - - ## pyct report - - Provides a way to check the package versions in the current environment using: - 1. A console script (entry point): `pyct report [packages]`, or - 2. A python function: `import pyct; pyct.report(packages)` - - The python function can be particularly useful for e.g. jupyter notebook users, since it is the packages in the current kernel that we usually care about (not those in the environment from which jupyter notebook server/lab was launched). - - Note that `packages` above can include the name of any Python package (returning the `__version__`), along with the special cases `python` or `conda` (returning the version of the command-line tool) or `system` (returning the OS version). - -Platform: UNKNOWN Classifier: License :: OSI Approved :: BSD License Classifier: Operating System :: OS Independent Classifier: Programming Language :: Python -Classifier: Programming Language :: Python :: 2.7 -Classifier: Programming Language :: Python :: 3.6 +Classifier: Programming Language :: Python :: 3.7 +Classifier: Programming Language :: Python :: 3.8 +Classifier: Programming Language :: Python :: 3.9 +Classifier: Programming Language :: Python :: 3.10 +Classifier: Programming Language :: Python :: 3.11 Classifier: Development Status :: 4 - Beta -Requires-Python: >=2.7 +Requires-Python: >=3.7 Description-Content-Type: text/markdown Provides-Extra: cmd Provides-Extra: tests Provides-Extra: doc Provides-Extra: build +License-File: LICENSE.txt + +# pyct + +A utility package that includes: + + 1. **pyct.cmd**: Makes various commands available to other + packages. (Currently no sophisticated plugin system, just a try + import/except in the other packages.) The same commands are + available from within python. Can either add new subcommands to + an existing argparse based command if the module has an existing + command, or create the entire command if the module has no + existing command. Currently, there are commands for copying + examples and fetching data. See + + 2. **pyct.build**: Provides various commands to help package + building, primarily as a convenience for project maintainers. + +## pyct.cmd + +To install pyct with the dependencies required for pyct.cmd: `pip +install pyct[cmd]` or `conda install -c pyviz pyct`. + +An example of how to use in a project: +https://github.com/holoviz/geoviews/blob/main/geoviews/__main__.py + +Once added, users can copy the examples of a package and download the +required data with the `examples` command: + +``` +$ datashader examples --help +usage: datashader examples [-h] [--path PATH] [-v] [--force] [--use-test-data] + +optional arguments: + -h, --help show this help message and exit + --path PATH location to place examples and data + -v, --verbose + --force if PATH already exists, force overwrite existing examples + if older than source examples. ALSO force any existing data + files to be replaced + --use-test-data Use data's test files, if any, instead of fetching full + data. If test file not in '.data_stubs', fall back to + fetching full data. +``` + +To copy the examples of e.g. datashader but not download the data, +there's a `copy-examples` command: + +``` +usage: datashader copy-examples [-h] [--path PATH] [-v] [--force] + +optional arguments: + -h, --help show this help message and exit + --path PATH where to copy examples + -v, --verbose + --force if PATH already exists, force overwrite existing files if + older than source files +``` + +And to download the data only, the `fetch-data` command: + +``` +usage: datashader fetch-data [-h] [--path PATH] [--datasets DATASETS] [-v] + [--force] [--use-test-data] + +optional arguments: + -h, --help show this help message and exit + --path PATH where to put data + --datasets DATASETS *name* of datasets file; must exist either in path + specified by --path or in package/examples/ + -v, --verbose + --force Force any existing data files to be replaced + --use-test-data Use data's test files, if any, instead of fetching full + data. If test file not in '.data_stubs', fall back to + fetching full data. +``` + +Can specify different 'datasets' file: + +``` +$ cat earthsim-examples/test.yml +--- + +data: + + - url: http://s3.amazonaws.com/datashader-data/Chesapeake_and_Delaware_Bays.zip + title: 'Depth data for the Chesapeake and Delaware Bay region of the USA' + files: + - Chesapeake_and_Delaware_Bays.3dm + +$ earthsim fetch-data --path earthsim-examples --datasets-filename test.yml +Downloading data defined in /tmp/earthsim-examples/test.yml to /tmp/earthsim-examples/data +Skipping Depth data for the Chesapeake and Delaware Bay region of the USA +``` + +Can use smaller files instead of large ones by using the `--use-test-data` flag +and placing a small file with the same name in `examples/data/.data_stubs`: + +``` +$ tree examples/data -a +examples/data +âââ .data_stubs +â  âââ nyc_taxi_wide.parq +âââ diamonds.csv + +$ cat examples/dataset.yml +data: + + - url: http://s3.amazonaws.com/datashader-data/nyc_taxi_wide.parq + title: 'NYC Taxi Data' + files: + - nyc_taxi_wide.parq + + - url: http://s3.amazonaws.com/datashader-data/maccdc2012_graph.zip + title: 'National CyberWatch Mid-Atlantic Collegiate Cyber Defense Competition' + files: + - maccdc2012_nodes.parq + - maccdc2012_edges.parq + - maccdc2012_full_nodes.parq + - maccdc2012_full_edges.parq + +$ pyviz fetch-data --path=examples --use-test-data +Fetching data defined in /tmp/pyviz/examples/datasets.yml and placing in /tmp/pyviz/examples/data +Copying test data file '/tmp/pyviz/examples/data/.data_stubs/nyc_taxi_wide.parq' to '/tmp/pyviz/examples/data/nyc_taxi_wide.parq' +No test file found for: /tmp/pyviz/examples/data/.data_stubs/maccdc2012_nodes.parq. Using regular file instead +Downloading National CyberWatch Mid-Atlantic Collegiate Cyber Defense Competition 1 of 1 +[################################] 59/59 - 00:00:00 +``` + +To clean up any potential test files masquerading as real data use `clean-data`: + +``` +usage: pyviz clean-data [-h] [--path PATH] + +optional arguments: + -h, --help show this help message and exit + --path PATH where to clean data +``` + +## pyct.build + +Currently provides a way to package examples with a project, by +copying an examples folder into the package directory whenever +setup.py is run. The way this works is likely to change in the near +future, but is provided here as the first step towards +unifying/simplifying the maintenance of a number of pyviz projects. + +## pyct report + +Provides a way to check the package versions in the current environment using: + 1. A console script (entry point): `pyct report [packages]`, or + 2. A python function: `import pyct; pyct.report(packages)` + +The python function can be particularly useful for e.g. jupyter notebook users, since it is the packages in the current kernel that we usually care about (not those in the environment from which jupyter notebook server/lab was launched). + +Note that `packages` above can include the name of any Python package (returning the `__version__`), along with the special cases `python` or `conda` (returning the version of the command-line tool) or `system` (returning the OS version). diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pyct-0.4.8/pyct.egg-info/SOURCES.txt new/pyct-0.5.0/pyct.egg-info/SOURCES.txt --- old/pyct-0.4.8/pyct.egg-info/SOURCES.txt 2020-09-11 23:35:50.000000000 +0200 +++ new/pyct-0.5.0/pyct.egg-info/SOURCES.txt 2023-01-30 12:10:58.000000000 +0100 @@ -2,7 +2,6 @@ MANIFEST.in README.md pyproject.toml -setup.cfg setup.py pyct/.version pyct/__init__.py diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pyct-0.4.8/pyct.egg-info/entry_points.txt new/pyct-0.5.0/pyct.egg-info/entry_points.txt --- old/pyct-0.4.8/pyct.egg-info/entry_points.txt 2020-09-11 23:35:50.000000000 +0200 +++ new/pyct-0.5.0/pyct.egg-info/entry_points.txt 2023-01-30 12:10:58.000000000 +0100 @@ -1,3 +1,2 @@ [console_scripts] pyct = pyct.__main__:main - diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pyct-0.4.8/pyproject.toml new/pyct-0.5.0/pyproject.toml --- old/pyct-0.4.8/pyproject.toml 2020-09-11 23:34:29.000000000 +0200 +++ new/pyct-0.5.0/pyproject.toml 2023-01-30 12:08:19.000000000 +0100 @@ -1,5 +1,6 @@ [build-system] requires = [ "param >=1.7.0", - "setuptools >=30.3.0" + "setuptools >=61.0" ] +build-backend = "setuptools.build_meta" diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pyct-0.4.8/setup.cfg new/pyct-0.5.0/setup.cfg --- old/pyct-0.4.8/setup.cfg 2020-09-11 23:35:50.000000000 +0200 +++ new/pyct-0.5.0/setup.cfg 2023-01-30 12:10:58.000000000 +0100 @@ -1,9 +1,3 @@ -[metadata] -license_file = LICENSE.txt - -[wheel] -universal = 1 - [egg_info] tag_build = tag_date = 0 diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pyct-0.4.8/setup.py new/pyct-0.5.0/setup.py --- old/pyct-0.4.8/setup.py 2020-09-11 23:34:29.000000000 +0200 +++ new/pyct-0.5.0/setup.py 2023-01-30 12:08:19.000000000 +0100 @@ -37,19 +37,22 @@ long_description=open("README.md").read(), long_description_content_type="text/markdown", license='BSD 3-Clause License', - license_file='LICENSE.txt', + license_files=['LICENSE.txt'], classifiers = [ 'License :: OSI Approved :: BSD License', 'Operating System :: OS Independent', 'Programming Language :: Python', - 'Programming Language :: Python :: 2.7', - 'Programming Language :: Python :: 3.6', + 'Programming Language :: Python :: 3.7', + 'Programming Language :: Python :: 3.8', + 'Programming Language :: Python :: 3.9', + 'Programming Language :: Python :: 3.10', + 'Programming Language :: Python :: 3.11', 'Development Status :: 4 - Beta' ], author='HoloViz', - author_email='holovi...@gmail.com', + author_email='develop...@holoviz.org', maintainer='HoloViz', - maintainer_email='holovi...@gmail.com', + maintainer_email='develop...@holoviz.org', url='https://github.com/pyviz-dev/{}'.format(NAME), project_urls = { 'Bug Tracker': 'https://github.com/pyviz-dev/{}/issues'.format(NAME), @@ -57,7 +60,7 @@ }, include_package_data=True, packages=find_packages(), - python_requires='>=2.7', + python_requires='>=3.7', install_requires=[ 'param >=1.7.0', ],