17
0
Commit Graph

36 Commits

Author SHA256 Message Date
cf5c8a7de0 Accepting request 1281832 from home:glaubitz:branches:devel:languages:python
- Update to 0.36.0
  * We have fixed a bug that caused specfile to traceback when
    section names with conditional macro expansions containing
    spaces were present in the spec file. (#476)

OBS-URL: https://build.opensuse.org/request/show/1281832
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-specfile?expand=0&rev=70
2025-06-03 13:15:04 +00:00
ac649af58f Accepting request 1281311 from home:glaubitz:branches:devel:languages:python
- Update to 0.35.1
  * We have fixed a bug that caused changes to get lost when a
    spec file passed as a path was replaced or deleted. (#470)

OBS-URL: https://build.opensuse.org/request/show/1281311
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-specfile?expand=0&rev=68
2025-05-30 09:20:44 +00:00
b4533ce5fe Accepting request 1277411 from home:nkrapp:branches:devel:languages:python
- Update to 0.35.0
  * Added support for creating Specfile instances from file objects
    and strings. (#458)
  * The context_management type stubs now use ParamSpec from typing_extensions
    to support Python < 3.10. (#466)

OBS-URL: https://build.opensuse.org/request/show/1277411
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-specfile?expand=0&rev=66
2025-05-14 12:24:42 +00:00
dab4fa3069 - update to 0.34.2:
* context_management: add a type stub override to fix typing.
    Type checkers like mypy and pyright can now correctly
    determine the types for `.sources()`, `.sections()`, and the
    other `Specfile` methods that return context managers.

OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-specfile?expand=0&rev=64
2025-03-29 09:46:07 +00:00
c36caba5a9 Accepting request 1245843 from home:glaubitz:branches:devel:languages:python
- Update to 0.34.1
  * Removed the usage of a walrus operator for Python 3.6 compatibility.
- Use Python 3.11 on SLE-15 by default

OBS-URL: https://build.opensuse.org/request/show/1245843
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-specfile?expand=0&rev=62
2025-02-14 10:42:42 +00:00
86d4bf8d95 - Update to 0.34.0:
- Added support for detached (open)SUSE style changelogs
- Update to 0.33.0:
  - There is a new convenience method Sections.get_or_create()
    that allows you to manipulate a section without checking
    if it exists first. If a section doesn't exist, it will be
    appended to the end. (#441) For example, this will work
    properly even on spec files without %changelog:
      with spec.sections() as sections:
          changelog = sections.get_or_create("changelog")
          changelog[:] = ["%autochangelog"]

OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-specfile?expand=0&rev=60
2025-02-01 22:19:13 +00:00
91fa7c1a33 Accepting request 1224076 from home:smolsheep:upgrades
- Update to 0.32.6:
  * New minor release for testing in CBS Koji
  * fix: assert existence of stderr

OBS-URL: https://build.opensuse.org/request/show/1224076
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-specfile?expand=0&rev=58
2024-11-14 07:14:13 +00:00
f4daf5cf7a Accepting request 1218992 from home:glaubitz:branches:devel:languages:python
- Update to 0.32.5
  * We have fixed our parser to take in account
    the deprecations introduced in Python 3.8

OBS-URL: https://build.opensuse.org/request/show/1218992
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-specfile?expand=0&rev=56
2024-10-29 17:05:56 +00:00
e42ad376e8 Accepting request 1208293 from home:smolsheep:upgrades
- Update to 0.32.4:
  * NEVR and NEVRA classes are now hashable

OBS-URL: https://build.opensuse.org/request/show/1208293
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-specfile?expand=0&rev=54
2024-10-17 08:30:43 +00:00
0f544303b7 - update to 0.32.3:
* specfile can now handle multi-line tag values (enclosed in a
    macro body, e.g. `%shrink`).

OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-specfile?expand=0&rev=52
2024-10-07 20:39:42 +00:00
641c15d225 Accepting request 1202273 from home:smolsheep:upgrades
- Update to 0.32.2:
  * Explicitly invalidate the global parse hash when a SpecParser
    instance is created to prevent this issue.

OBS-URL: https://build.opensuse.org/request/show/1202273
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-specfile?expand=0&rev=50
2024-09-20 22:34:57 +00:00
b5b93e9d8a Accepting request 1190298 from home:smolsheep:upgrades
- Update to 0.32.1:
  * Fixed two issues related to condition parsing.

OBS-URL: https://build.opensuse.org/request/show/1190298
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-specfile?expand=0&rev=48
2024-07-29 16:54:42 +00:00
d5969f3cca Accepting request 1188958 from home:smolsheep:upgrades
- Add typing_extensions to Requires as well -- Fix rpmlint error
- Update to 0.32.0:
  * It is now possible to bump a release in a manner similar to
    rpmdev-bumpspec using Specfile.bump_release() method.

OBS-URL: https://build.opensuse.org/request/show/1188958
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-specfile?expand=0&rev=46
2024-07-22 18:47:37 +00:00
67d73e8e63 Accepting request 1185798 from home:smolsheep:upgrades
Depends on SR#1185797 to build properly
https://build.opensuse.org/request/show/1185797

- Add typing_extensions to BuildRequires
- Remove typing_extensions from Requires -- gh#packit/specfile#179
- Update to 0.31.0:
  * Value of a Tag no longer includes trailing whitespace (if any)
  * specfile now tries to expand macros before processing
    conditions to be able to resolve conditional expressions
    defined by macros, for example OpenSUSE Tumbleweed defines
    %ifpython3 macro as %if "%{python_flavor}" == "python3"
- Updates from 0.30.0:
  * Fixed an exception that occured when accessing the
    Specfile.has_autochangelog property while having unparseable
    lines (e.g. lines ending with unescaped %) in %changelog

OBS-URL: https://build.opensuse.org/request/show/1185798
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-specfile?expand=0&rev=44
2024-07-09 13:28:14 +00:00
a6af711eff - update to 0.29.0:
* Improved compatibility with RPM 4.20 (alpha version is
    currently in Fedora Rawhide).
  * Fixed several minor issues such as processing seemingly
    commented-out macro definitions (e.g. `#%global prerel rc1`)
    and treating `SourceLicense` tag as a source.
  * Made `EVR`, `NEVR` and `NEVRA` objects comparable.
  * Handling of trailing newlines in the macro defintions has
    been improved.
  * We have fixed an issue in `%prep` section processing. For
    instance, if the `%patches` macro appeared there, it would
    have been converted to `%patch es`, causing failure when
    executing `%prep` later.
  * A trailing newline is no longer added to spec files without
    one upon saving.

OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-specfile?expand=0&rev=42
2024-06-10 08:54:47 +00:00
68e070598f - update to 0.27.0:
* Improved handling of commented-out macro definitions and
    fixed related logic in `Specfile.update_value()`.

OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-specfile?expand=0&rev=40
2024-01-25 08:27:50 +00:00
d6be41ed1c - update to 0.26.0:
* When accessing tags or macro definitions by name, specfile
    now takes validity into account when looking for the best
    match. For example if there are two instances of `Version`
    tag, one in the true and one in the false branch of a
    condition, `Specfile.version` will always access the one that
    is in the true branch. (#328)
  * Third pre-release for testing Packit support.
  - There is a new method, Specfile.update_version(), that allows
    updating spec file version even if it is a pre-release. (#317)
  - Sources now have a valid property that indicates whether a
    source is valid in the current context, meaning it is not
- reduce buildrequires to git-core
- Update to version 0.18.0:
- Update to version 0.17.0:
    heuristics as rpmdev-packager, meaning that the
  * Added Specfile.has_autorelease property to detect if a spec
- Update to version 0.15.0:
    necessary, greatly improving performance in certain scenarios.
  * Fixed a bug that broke parsing in case spec file contained
  * Specfile no longer depends on rpm-py-installer, it now depends
  * Fixed infinite loop that occured when section options were
  * Fixed a bug in section parsing that caused sections to be
- Update to version 0.13.0:
    the standard `copy()` and `deepcopy()` functions from `copy`
  * `Section.name` attribute has been renamed to a more fitting
  * `setup.cfg` now uses `license_files` instead of deprecated
  * Tags enclosed in conditional macro expansions are not ignored
- Update to version 0.11.0
    now be nested and combined together (with one exception -

OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-specfile?expand=0&rev=38
2023-12-29 10:18:36 +00:00
63b9a24756 Accepting request 1128265 from home:david.anes:branches:devel:languages:python
- Update to 0.25.0:
  - There is a new method, Specfile.update_version(), that allows 
    updating spec file version even if it is a pre-release. (#317)

OBS-URL: https://build.opensuse.org/request/show/1128265
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-specfile?expand=0&rev=36
2023-11-23 10:27:52 +00:00
15cc0915a6 - Update to 0.24.0:
- Improved type annotations for UserList subclasses. (#299)
  - Macro definitions gained a new commented_out property
    indicating that a macro definition is commented out. Another
    new property, comment_out_style, determines if it is achieved
    by using a %dnl (discard next line) directive (e.g. %dnl
    %global prerelease beta2) or by replacing the starting % with
    # (e.g. #global prerelease beta2). (#298)
- Fix a bad Requires: %{python_module typing_extensions}

OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-specfile?expand=0&rev=34
2023-11-08 10:17:40 +00:00
cc743a3f5e Accepting request 1121136 from home:david.anes:branches:devel:languages:python
- Update to 0.23.0:
  - Sources now have a valid property that indicates whether a 
    source is valid in the current context, meaning it is not 
    present in a false branch of any condition.

OBS-URL: https://build.opensuse.org/request/show/1121136
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-specfile?expand=0&rev=32
2023-10-30 10:57:41 +00:00
d33a5295be Accepting request 1118208 from home:david.anes:branches:devel:languages:python
- Update to 0.22.1:
  - Removed dependency on setuptools-scm-git-archive

OBS-URL: https://build.opensuse.org/request/show/1118208
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-specfile?expand=0&rev=30
2023-10-17 08:05:14 +00:00
7bc158f4c4 - reduce buildrequires to git-core
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-specfile?expand=0&rev=28
2023-09-04 10:49:47 +00:00
863840669f Accepting request 1108767 from home:mschreiner:branches:devel:languages:python
- Update to 0.22.0:
  - Changes from 0.22.0:
    * Macro definitions and tags gained a new valid attribute. A macro
      definition/tag is considered valid if it doesn't appear in a
      false branch of any condition appearing in the spec file.
  - Changes from 0.21.0:
    * specfile no longer tracebacks when some sources are missing and
      can't be emulated. In such case the spec file is parsed without
      them at the cost of %setup and %patch macros potentially
      expanding differently than with the sources present.
    * Specfile's license in RPM spec file is now confirmed to be SPDX
      compatible.
- Blacklist a new broken test on spec file: test_parse_texlive_spec.
- Add a new Python module dependency: typing_extensions.
- Apply spec-cleaner.

OBS-URL: https://build.opensuse.org/request/show/1108767
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-specfile?expand=0&rev=27
2023-09-04 10:43:57 +00:00
75c41fe10d - Update to 0.20.0:
* Fixed infinite loop when removing macros with `%` in the name. (#244)
  * Added a possibility to undefine system macros by setting a macro value
    to `None` in the `macros` argument of the `Specfile` constructor. (#244)
  * Fixed a bug in processing options of `%prep` macros. For instance, when
    a quoted string appeared inside an expression expansion, it could lead
    to improper parsing, rendering the spec file invalid after accessing
    the options. (#253)
  * Parsing has been optimized so that even spec files with hundreds of
    thousands of lines can be processed in reasonable time. (#240)
- Drop setuptools_scm_git_archive BuildRequires.
- Don't need to skip Python 3.8.

OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-specfile?expand=0&rev=25
2023-07-19 04:54:16 +00:00
8df6b1c1d6 Accepting request 1089540 from home:david.anes:branches:devel:languages:python
- Update to version 0.18.0: 
  * Specfile library now handles multiple %changelog sections. (#230)

OBS-URL: https://build.opensuse.org/request/show/1089540
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-specfile?expand=0&rev=23
2023-05-30 12:24:25 +00:00
86c81445ba Accepting request 1086509 from home:david.anes:branches:devel:languages:python
- Update to version 0.17.0: 
  * Added a new guess_packager() function that uses similar
    heuristics as rpmdev-packager, meaning that the 
    Specfile.add_changelog_entry() method no longer requires
    rpmdev-packager to guess the changelog entry author. (#220)
  * The Specfile.add_changelog_entry() method now uses dates based
    on UTC instead of the local timezone. (#223)

OBS-URL: https://build.opensuse.org/request/show/1086509
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-specfile?expand=0&rev=21
2023-05-11 13:29:15 +00:00
24c6f0b231 Accepting request 1082646 from home:david.anes:branches:devel:languages:python
- Update to version 0.16.0:
  * Added Specfile.has_autorelease property to detect if a spec 
    file uses the %autorelease macro. (#221)

OBS-URL: https://build.opensuse.org/request/show/1082646
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-specfile?expand=0&rev=19
2023-04-25 11:45:50 +00:00
3557954c5c Accepting request 1071124 from home:david.anes:branches:devel:languages:python
- Update to version 0.15.0: 
  * Parsing the spec file by RPM is now performed only if really
    necessary, greatly improving performance in certain scenarios. 
    (#212)
  * Checked that license is a valid SPDX license.

OBS-URL: https://build.opensuse.org/request/show/1071124
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-specfile?expand=0&rev=17
2023-03-13 12:48:53 +00:00
c68ac0e83e Accepting request 1067714 from home:david.anes:branches:devel:languages:python
- Update to version 0.14.0:
  * Fixed a bug that broke parsing in case spec file contained 
    conditionalized macro definitions or similar constructs
  * Specfile no longer depends on rpm-py-installer, it now depends 
    directly on rpm.

OBS-URL: https://build.opensuse.org/request/show/1067714
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-specfile?expand=0&rev=15
2023-02-27 07:17:02 +00:00
1c56bb1dac Accepting request 1063358 from home:david.anes:branches:devel:languages:python
- Update to version 0.13.2:
  * Fixed infinite loop that occured when section options were 
    followed by whitespace.

OBS-URL: https://build.opensuse.org/request/show/1063358
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-specfile?expand=0&rev=13
2023-02-06 12:29:06 +00:00
cef0ac679c Accepting request 1060457 from home:david.anes:branches:devel:languages:python
- Update to version 0.13.1:
  * Fixed a bug in section parsing that caused sections to be 
    ignored when there were macro definitions spread across the spec
    file and not cumulated at the top.
- Update to version 0.13.0: 
  * Added Section.options attribute for convenient manipulation of
    section options.
  * specfile now supports single-line sections where section content
    is represented by a macro starting with a newline.
  * Added evr argument to Specfile.add_changelog_entry(). This
    allows adding a changelog entry with an EVR value that's
    different from the current specfile's value. This makes it
    easier to reconstruct a specfile's %changelog based on another
    source using the higher level interface.

OBS-URL: https://build.opensuse.org/request/show/1060457
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-specfile?expand=0&rev=11
2023-01-23 22:00:59 +00:00
41be681c5f Accepting request 1057959 from home:david.anes:branches:devel:languages:python
- Remove patch (already upstream):
  * python-specfile-improve-setup-cfg.patch
- Update to version 0.12.0:
  * All classes including `Specfile` itself can now be copied using
    the standard `copy()` and `deepcopy()` functions from `copy` 
    module.
  * `Section.name` attribute has been renamed to a more fitting 
    `Section.id`.
  * `setup.cfg` now uses `license_files` instead of deprecated 
    `license_file`.

  * Fixed context managers being shared between Specfile instances.

OBS-URL: https://build.opensuse.org/request/show/1057959
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-specfile?expand=0&rev=9
2023-01-12 11:54:06 +00:00
0e49e1b352 Accepting request 1043093 from home:david.anes:branches:devel:languages:python
- Add config.cfg improvements to remove deprecation warnings
  * python-specfile-improve-setup-cfg.patch
- Update to version 0.11.1
  * Tags enclosed in conditional macro expansions are not ignored 
    anymore.
  * Fixed context managers being shared between Specfile instances. 1q
- Update to version 0.11.0 
  * Context managers (Specfile.sections(), Specfile.tags() etc.) can
    now be nested and combined together (with one exception - 
    Specfile.macro_definitions()), and it is also possible to use 
    tag properties (e.g. Specfile.version, Specfile.license) inside 
    them. It is also possible to access the data directly, avoiding 
    the with statement, by using the content property 
    (e.g. Specfile.tags().content), but be aware that no 
    modifications done to such data will be preserved. You must use 
    with to make changes.

OBS-URL: https://build.opensuse.org/request/show/1043093
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-specfile?expand=0&rev=7
2022-12-15 10:33:46 +00:00
790df79fa3 Accepting request 1039167 from home:david.anes:branches:devel:languages:python
- Update to version 0.10.0 
  * Fixed an issue that caused empty lines originally inside 
    changelog entries to appear at the end. (#140)
  * Renamed the ignore_missing_includes option to a more general 
    force_parse. If specified, it allows to attempt to parse the 
    spec file even if one or more sources required to be present at 
    parsing time are not available. Such sources include sources 
    referenced from shell expansions in tag values and sources 
    included using the %include directive. (#137)

OBS-URL: https://build.opensuse.org/request/show/1039167
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-specfile?expand=0&rev=5
2022-11-30 22:17:37 +00:00
3254253f6c Accepting request 1034926 from home:yarunachalam:branches:devel:languages:python
- Update to version 0.9.0 
  * Added utility classes for working with (N)EVR. (#113)
  * Fixed an issue with multiple instances of Specfile not expanding macros in the right context. (#117)

OBS-URL: https://build.opensuse.org/request/show/1034926
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-specfile?expand=0&rev=3
2022-11-11 13:04:39 +00:00
218acc3188 Accepting request 1031109 from home:dgarcia:py-new
- Update to version v0.8.0
  * Added Specfile.update_tag() method that allows updating tag values while
    trying to preserve macro expansions. You can watch a demo on YouTube.
    (#101)
- 0.7.0
  * It is now possible to filter changelog entries by specifying lower bound
    EVR, upper bound EVR or both. (#104)
  * Added support for filenames specified in source URL fragments, for example:
    https://example.com/foo/1.0/download.cgi#/%{name}-%{version}.tar.gz (#100)

OBS-URL: https://build.opensuse.org/request/show/1031109
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-specfile?expand=0&rev=1
2022-10-25 18:16:47 +00:00