python-traitlets/python-traitlets.spec

65 lines
1.9 KiB
RPMSpec
Raw Normal View History

#
# spec file for package python-traitlets
#
# Copyright (c) 2024 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via https://bugs.opensuse.org/
#
%{?sle15_python_module_pythons}
Name: python-traitlets
Version: 5.14.2
Release: 0
Accepting request 944201 from home:bnavigator:branches:devel:languages:python:jupyter - Update to version 5.1.1 * 5.1.1 fixes compatibility issues with Python 3.10 (rc2). - Release 5.1.0 * Traitlets 5.1 brings a couple of updates and changes to traitlets, and is recommended for all users. What follow is a non-exhaustive list of changes: * Removal of the ``ipython_genutils`` dependency, this should remove any direct and indirect reliance on ``nose`` and prepare traitlets 5.1 for Python 3.10 and above compatibility, some test suite changes also accommodate Python 3.10 changes. If you package traitlets downstream, make sure to remove this dependency. * Removal of ``ipython_genutils`` may have change the default encoding detected for the command line argument parsing when not utf-8. We expect this to affect a small portion of older windows version. If you encounter issue let us know. * Stop recommendation of ``CUnicode`` in some circumstances as it's deprecated. * Our test suite is now using GitHub action instead of travis CI. If you are packaging downstream using the git repository, you may have to exclude the ``.github`` folder now, and can remove exclusion of * It fixes a parsing issue for list of one single element on the CLI. * We reserve the right to remove official support for Python 3.7 in subsequent minor revisions. - Releases 5.0.2 to 5.0.5 * Support deprecated literals for sets, tuples on the command-line: ``nbconvert --TagRemovePreprocessor.remove_cell_tags=' *"tag"}'`` * Fix ``from_string_list`` for Tuples in general * Fix support for ``List(default_value=None, allow_none=True)`` and other Container traits * Fix help output for nested aliases and tuple traits * Support deprecated use of byte-literals for bytes on the command-line: ``ipython kernel --Session.key="b'abc'"``. The `b` prefix is no longer needed in traitlets 5.0, but is supported for backward-compatibility * Improve output of configuration errors, especially when help output would make it hard to find the helpful error message * Fix regression in handling `--opt=None` on the CLI for configurable traits with `allow_none=True` * Fix casting bytes to unicode - Traitlets 5.0 * Traitlets 5.0 is a new version of traitlets that accumulate changes over a period of more close to four years; A number of internal refactoring made the internal code structure cleaner and simpler, and greatly improved the diagnostic error messages as well has help and documentation generation. * We expect no code change needed for any consumer of the Python API (ipywidgets, and alike), though CLI argument parsing have seen a complete rewrite, so if you have an application that does use the parsing logic of traitlets you may see changes in behavior, and now have access to more features. * Major changes are: - Removal of Python 2 support, - Removal of Python 3.0-3.6 support - we now follow NEP 29, and are thus Python 3.7+ only. - remove ``six`` as a dependency - remove ``funcsig`` as a dependency. - Fix build without python2 - Update to version 4.3.3 * Adds Application.loaded_config_files property for accessing config files that have been loaded and makes the property idempotent on multiple loads. - Add missing python-six BuildRequires - Add missing python-six Requires - Implement single-spec version. - Update to 4.3.2 * using :meth:`_traitname_default()` without the ``@default`` decorator is no longer deprecated. * Passing ``config=True`` in traitlets constructors is no longer deprecated. - Update to 4.3.1 * Compatibility fix for Python 3.6a1 * Fix bug in Application.classes getting extra entries when multiple Applications are instantiated in the same process. - Update to 4.3.0 * Improve the generated config file output. * Allow TRAITLETS_APPLICATION_RAISE_CONFIG_FILE_ERROR env to override :attr:`Application.raise_config_file_errors`, so that config file errors can result in exiting immediately. * Avoid using root logger. If no application logger is registered, the ``'traitlets'`` logger will be used instead of the root logger. * Change/Validation arguments are now Bunch objects, allowing attribute-access, in addition to dictionary access. * Reduce number of common deprecation messages in certain cases. * Ensure command-line options always have higher priority than config files. * Add bounds on numeric traits. * Improves various error messages. - Update to 4.2.2 * Partially revert a change in 4.1 that prevented IPython's command-line options from taking priority over config files. - Update to 4.2.1 * Demotes warning about unused arguments in ``HasTraits.__init__`` introduced in 4.2.0 to DeprecationWarning. - Update to 4.2.0 * :class:`JSONFileConfigLoader` can be used as a context manager for updating configuration. * If a value in config does not map onto a configurable trait, a message is displayed that the value will have no effect. * Unused arguments are passed to ``super()`` in ``HasTraits.__init__``, improving support for multiple inheritance. * Various bugfixes and improvements in the new API introduced in 4.1. * Application subclasses may specify ``raise_config_file_errors = True`` to exit on failure to load config files, instead of the default of logging the failures. - Update to 4.1 * Decorators are used, rather than magic method names, for registering trait-related methods. See :doc:`using_traitlets` and :doc:`migration` for more info. * Deprecate ``Trait(config=True)`` in favor of ``Trait().tag(config=True)``. In general, metadata is added via ``tag`` instead of the constructor. * Trait attributes initialized with ``read_only=True`` can only be set with the ``set_trait`` method. Attempts to directly modify a read-only trait attribute raises a ``TraitError``. * The directional link now takes an optional `transform` attribute allowing the modification of the value. * Various fixes and improvements to config-file generation (fixed ordering, Undefined showing up, etc.) * Warn on unrecognized traits that aren't configurable, to avoid silently ignoring mistyped config. - Update to version - Fix package naming consistency - Update dependency names - Initial version OBS-URL: https://build.opensuse.org/request/show/944201 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python:jupyter/python-traitlets?expand=0&rev=8
2022-01-06 10:38:58 +00:00
Summary: Traitlets Python configuration system
License: BSD-3-Clause
URL: https://github.com/ipython/traitlets
Source: https://files.pythonhosted.org/packages/source/t/traitlets/traitlets-%{version}.tar.gz
Source99: python-traitlets.rpmlintrc
BuildRequires: %{python_module argcomplete >= 3.0.3}
BuildRequires: %{python_module base >= 3.8}
BuildRequires: %{python_module hatchling >= 1.5}
Accepting request 980912 from home:bnavigator:branches:devel:languages:python:jupyter - Update to 5.2.2 * Make all explicit and validate in test by @blink1073 in #737 * Fix KeyError in Application.get_default_logging_config by @tonyroberts in #724 - Release 5.2.1 * Switch to hatch backend by @blink1073 in #728 * logging: don't attempt to close handlers unless they have been opened by @oliver-sanders in #727 - Release 5.2.0 * Add mypy support by @blink1073 in #705 * Disambiguate the use of the term value in the example. by @metaperl in #694 * Correct spelling and grammar errors. by @metaperl in #695 * DOC: Add log example by @Carreau in #693 * Put description of signature_has_traits after the header for it. by @metaperl in #711 * Application: add logging_config trait by @oliver-sanders in #698 * [DOC] Give explicit list of private symbols for 5.0 by @vidartf in #692 * Add pre-commit and run auto-formatters by @blink1073 in #699 * Fix downstream test by @blink1073 in #701 * Add docs on pre-commit and use manual hooks where appropriate by @blink1073 in #700 * Set up flake8 by @blink1073 in #703 * Typing: tell mypy we have type, update all. by @Carreau in #713 * Improve CI by @blink1073 in #706 * Fix typing errors by @blink1073 in #718 * Use flit build backend by @blink1073 in #720 * Add Changelog Entry for 5.2.0 by @blink1073 in #717 OBS-URL: https://build.opensuse.org/request/show/980912 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python:jupyter/python-traitlets?expand=0&rev=10
2022-06-05 17:06:21 +00:00
BuildRequires: %{python_module pip}
BuildRequires: %{python_module pytest >= 7 with %python-pytest < 8.1}
BuildRequires: %{python_module pytest-mock}
BuildRequires: fdupes
BuildRequires: python-rpm-macros
BuildArch: noarch
%python_subpackages
%description
A configuration system for Python applications.
%prep
Accepting request 980912 from home:bnavigator:branches:devel:languages:python:jupyter - Update to 5.2.2 * Make all explicit and validate in test by @blink1073 in #737 * Fix KeyError in Application.get_default_logging_config by @tonyroberts in #724 - Release 5.2.1 * Switch to hatch backend by @blink1073 in #728 * logging: don't attempt to close handlers unless they have been opened by @oliver-sanders in #727 - Release 5.2.0 * Add mypy support by @blink1073 in #705 * Disambiguate the use of the term value in the example. by @metaperl in #694 * Correct spelling and grammar errors. by @metaperl in #695 * DOC: Add log example by @Carreau in #693 * Put description of signature_has_traits after the header for it. by @metaperl in #711 * Application: add logging_config trait by @oliver-sanders in #698 * [DOC] Give explicit list of private symbols for 5.0 by @vidartf in #692 * Add pre-commit and run auto-formatters by @blink1073 in #699 * Fix downstream test by @blink1073 in #701 * Add docs on pre-commit and use manual hooks where appropriate by @blink1073 in #700 * Set up flake8 by @blink1073 in #703 * Typing: tell mypy we have type, update all. by @Carreau in #713 * Improve CI by @blink1073 in #706 * Fix typing errors by @blink1073 in #718 * Use flit build backend by @blink1073 in #720 * Add Changelog Entry for 5.2.0 by @blink1073 in #717 OBS-URL: https://build.opensuse.org/request/show/980912 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python:jupyter/python-traitlets?expand=0&rev=10
2022-06-05 17:06:21 +00:00
%autosetup -p1 -n traitlets-%{version}
sed -i 's/"--color=yes",//' pyproject.toml
%build
Accepting request 980912 from home:bnavigator:branches:devel:languages:python:jupyter - Update to 5.2.2 * Make all explicit and validate in test by @blink1073 in #737 * Fix KeyError in Application.get_default_logging_config by @tonyroberts in #724 - Release 5.2.1 * Switch to hatch backend by @blink1073 in #728 * logging: don't attempt to close handlers unless they have been opened by @oliver-sanders in #727 - Release 5.2.0 * Add mypy support by @blink1073 in #705 * Disambiguate the use of the term value in the example. by @metaperl in #694 * Correct spelling and grammar errors. by @metaperl in #695 * DOC: Add log example by @Carreau in #693 * Put description of signature_has_traits after the header for it. by @metaperl in #711 * Application: add logging_config trait by @oliver-sanders in #698 * [DOC] Give explicit list of private symbols for 5.0 by @vidartf in #692 * Add pre-commit and run auto-formatters by @blink1073 in #699 * Fix downstream test by @blink1073 in #701 * Add docs on pre-commit and use manual hooks where appropriate by @blink1073 in #700 * Set up flake8 by @blink1073 in #703 * Typing: tell mypy we have type, update all. by @Carreau in #713 * Improve CI by @blink1073 in #706 * Fix typing errors by @blink1073 in #718 * Use flit build backend by @blink1073 in #720 * Add Changelog Entry for 5.2.0 by @blink1073 in #717 OBS-URL: https://build.opensuse.org/request/show/980912 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python:jupyter/python-traitlets?expand=0&rev=10
2022-06-05 17:06:21 +00:00
%pyproject_wheel
%install
Accepting request 980912 from home:bnavigator:branches:devel:languages:python:jupyter - Update to 5.2.2 * Make all explicit and validate in test by @blink1073 in #737 * Fix KeyError in Application.get_default_logging_config by @tonyroberts in #724 - Release 5.2.1 * Switch to hatch backend by @blink1073 in #728 * logging: don't attempt to close handlers unless they have been opened by @oliver-sanders in #727 - Release 5.2.0 * Add mypy support by @blink1073 in #705 * Disambiguate the use of the term value in the example. by @metaperl in #694 * Correct spelling and grammar errors. by @metaperl in #695 * DOC: Add log example by @Carreau in #693 * Put description of signature_has_traits after the header for it. by @metaperl in #711 * Application: add logging_config trait by @oliver-sanders in #698 * [DOC] Give explicit list of private symbols for 5.0 by @vidartf in #692 * Add pre-commit and run auto-formatters by @blink1073 in #699 * Fix downstream test by @blink1073 in #701 * Add docs on pre-commit and use manual hooks where appropriate by @blink1073 in #700 * Set up flake8 by @blink1073 in #703 * Typing: tell mypy we have type, update all. by @Carreau in #713 * Improve CI by @blink1073 in #706 * Fix typing errors by @blink1073 in #718 * Use flit build backend by @blink1073 in #720 * Add Changelog Entry for 5.2.0 by @blink1073 in #717 OBS-URL: https://build.opensuse.org/request/show/980912 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python:jupyter/python-traitlets?expand=0&rev=10
2022-06-05 17:06:21 +00:00
%pyproject_install
%python_expand %fdupes %{buildroot}%{$python_sitelib}
%check
# no mypy testing in Ring1
%pytest --ignore tests/test_typing.py
%files %{python_files}
%doc README.md
%doc examples/
%license LICENSE
%{python_sitelib}/traitlets/
Accepting request 944201 from home:bnavigator:branches:devel:languages:python:jupyter - Update to version 5.1.1 * 5.1.1 fixes compatibility issues with Python 3.10 (rc2). - Release 5.1.0 * Traitlets 5.1 brings a couple of updates and changes to traitlets, and is recommended for all users. What follow is a non-exhaustive list of changes: * Removal of the ``ipython_genutils`` dependency, this should remove any direct and indirect reliance on ``nose`` and prepare traitlets 5.1 for Python 3.10 and above compatibility, some test suite changes also accommodate Python 3.10 changes. If you package traitlets downstream, make sure to remove this dependency. * Removal of ``ipython_genutils`` may have change the default encoding detected for the command line argument parsing when not utf-8. We expect this to affect a small portion of older windows version. If you encounter issue let us know. * Stop recommendation of ``CUnicode`` in some circumstances as it's deprecated. * Our test suite is now using GitHub action instead of travis CI. If you are packaging downstream using the git repository, you may have to exclude the ``.github`` folder now, and can remove exclusion of * It fixes a parsing issue for list of one single element on the CLI. * We reserve the right to remove official support for Python 3.7 in subsequent minor revisions. - Releases 5.0.2 to 5.0.5 * Support deprecated literals for sets, tuples on the command-line: ``nbconvert --TagRemovePreprocessor.remove_cell_tags=' *"tag"}'`` * Fix ``from_string_list`` for Tuples in general * Fix support for ``List(default_value=None, allow_none=True)`` and other Container traits * Fix help output for nested aliases and tuple traits * Support deprecated use of byte-literals for bytes on the command-line: ``ipython kernel --Session.key="b'abc'"``. The `b` prefix is no longer needed in traitlets 5.0, but is supported for backward-compatibility * Improve output of configuration errors, especially when help output would make it hard to find the helpful error message * Fix regression in handling `--opt=None` on the CLI for configurable traits with `allow_none=True` * Fix casting bytes to unicode - Traitlets 5.0 * Traitlets 5.0 is a new version of traitlets that accumulate changes over a period of more close to four years; A number of internal refactoring made the internal code structure cleaner and simpler, and greatly improved the diagnostic error messages as well has help and documentation generation. * We expect no code change needed for any consumer of the Python API (ipywidgets, and alike), though CLI argument parsing have seen a complete rewrite, so if you have an application that does use the parsing logic of traitlets you may see changes in behavior, and now have access to more features. * Major changes are: - Removal of Python 2 support, - Removal of Python 3.0-3.6 support - we now follow NEP 29, and are thus Python 3.7+ only. - remove ``six`` as a dependency - remove ``funcsig`` as a dependency. - Fix build without python2 - Update to version 4.3.3 * Adds Application.loaded_config_files property for accessing config files that have been loaded and makes the property idempotent on multiple loads. - Add missing python-six BuildRequires - Add missing python-six Requires - Implement single-spec version. - Update to 4.3.2 * using :meth:`_traitname_default()` without the ``@default`` decorator is no longer deprecated. * Passing ``config=True`` in traitlets constructors is no longer deprecated. - Update to 4.3.1 * Compatibility fix for Python 3.6a1 * Fix bug in Application.classes getting extra entries when multiple Applications are instantiated in the same process. - Update to 4.3.0 * Improve the generated config file output. * Allow TRAITLETS_APPLICATION_RAISE_CONFIG_FILE_ERROR env to override :attr:`Application.raise_config_file_errors`, so that config file errors can result in exiting immediately. * Avoid using root logger. If no application logger is registered, the ``'traitlets'`` logger will be used instead of the root logger. * Change/Validation arguments are now Bunch objects, allowing attribute-access, in addition to dictionary access. * Reduce number of common deprecation messages in certain cases. * Ensure command-line options always have higher priority than config files. * Add bounds on numeric traits. * Improves various error messages. - Update to 4.2.2 * Partially revert a change in 4.1 that prevented IPython's command-line options from taking priority over config files. - Update to 4.2.1 * Demotes warning about unused arguments in ``HasTraits.__init__`` introduced in 4.2.0 to DeprecationWarning. - Update to 4.2.0 * :class:`JSONFileConfigLoader` can be used as a context manager for updating configuration. * If a value in config does not map onto a configurable trait, a message is displayed that the value will have no effect. * Unused arguments are passed to ``super()`` in ``HasTraits.__init__``, improving support for multiple inheritance. * Various bugfixes and improvements in the new API introduced in 4.1. * Application subclasses may specify ``raise_config_file_errors = True`` to exit on failure to load config files, instead of the default of logging the failures. - Update to 4.1 * Decorators are used, rather than magic method names, for registering trait-related methods. See :doc:`using_traitlets` and :doc:`migration` for more info. * Deprecate ``Trait(config=True)`` in favor of ``Trait().tag(config=True)``. In general, metadata is added via ``tag`` instead of the constructor. * Trait attributes initialized with ``read_only=True`` can only be set with the ``set_trait`` method. Attempts to directly modify a read-only trait attribute raises a ``TraitError``. * The directional link now takes an optional `transform` attribute allowing the modification of the value. * Various fixes and improvements to config-file generation (fixed ordering, Undefined showing up, etc.) * Warn on unrecognized traits that aren't configurable, to avoid silently ignoring mistyped config. - Update to version - Fix package naming consistency - Update dependency names - Initial version OBS-URL: https://build.opensuse.org/request/show/944201 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python:jupyter/python-traitlets?expand=0&rev=8
2022-01-06 10:38:58 +00:00
%{python_sitelib}/traitlets-%{version}*-info
%changelog