Github messages for voidlinux
 help / color / mirror / Atom feed
* [PR PATCH] python3-ruamel.yaml: update to 0.17.21.
@ 2022-03-24 17:35 TinfoilSubmarine
  2022-05-07 21:41 ` [PR REVIEW] " paper42
                   ` (7 more replies)
  0 siblings, 8 replies; 9+ messages in thread
From: TinfoilSubmarine @ 2022-03-24 17:35 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 1392 bytes --]

There is a new pull request by TinfoilSubmarine against master on the void-packages repository

https://github.com/TinfoilSubmarine/void-packages ruamel.yaml
https://github.com/void-linux/void-packages/pull/36320

python3-ruamel.yaml: update to 0.17.21.
<!-- Uncomment relevant sections and delete options which are not applicable -->

#### Testing the changes
- I tested the changes in this PR: **YES**

Tested with all dependents:

- [x] borgmatic
- [x] khard
- [x] python3-ansible-lint
- [x] python3-pykwalify
- [x] whipper (needed patch)

<!--
#### New package
- This new package conforms to the [quality requirements](https://github.com/void-linux/void-packages/blob/master/Manual.md#quality-requirements): **YES**|**NO**
-->

<!-- Note: If the build is likely to take more than 2 hours, please [skip CI](https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#continuous-integration)
and test at least one native build and, if supported, at least one cross build.
Ignore this section if this PR is not skipping CI.
-->
<!-- 
#### Local build testing
- I built this PR locally for my native architecture, (ARCH-LIBC)
- I built this PR locally for these architectures (if supported. mark crossbuilds):
  - aarch64-musl
  - armv7l
  - armv6l-musl
-->


A patch file from https://github.com/void-linux/void-packages/pull/36320.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-ruamel.yaml-36320.patch --]
[-- Type: text/x-diff, Size: 5998 bytes --]

From 3772d4eba343246f8042b19a36ad786cb83327ec Mon Sep 17 00:00:00 2001
From: Joel Beckmeyer <joel@beckmeyer.us>
Date: Thu, 24 Mar 2022 13:12:36 -0400
Subject: [PATCH 1/2] python3-ruamel.yaml: update to 0.17.21.

---
 srcpkgs/python3-ruamel.yaml/template | 14 ++++++--------
 1 file changed, 6 insertions(+), 8 deletions(-)

diff --git a/srcpkgs/python3-ruamel.yaml/template b/srcpkgs/python3-ruamel.yaml/template
index b8ad65ed0883..3bd799927b90 100644
--- a/srcpkgs/python3-ruamel.yaml/template
+++ b/srcpkgs/python3-ruamel.yaml/template
@@ -1,25 +1,23 @@
 # Template file for 'python3-ruamel.yaml'
 pkgname=python3-ruamel.yaml
-version=0.16.12
-revision=4
+version=0.17.21
+revision=1
 wrksrc="ruamel.yaml-${version}"
 build_style=python3-module
 hostmakedepends="python3-setuptools"
 makedepends="python3-devel"
-depends="python3"
+depends="python3-ruamel.yaml.clib"
 short_desc="YAML parser/emitter in Python 3"
 maintainer="Orphaned <orphan@voidlinux.org>"
 license="MIT"
 homepage="http://yaml.readthedocs.io/"
+changelog="https://sourceforge.net/p/ruamel-yaml/code/ci/default/tree/CHANGES"
 distfiles="${PYPI_SITE}/r/ruamel.yaml/ruamel.yaml-${version}.tar.gz"
-checksum=076cc0bc34f1966d920a49f18b52b6ad559fbe656a0748e3535cf7b3f29ebf9e
+checksum=8b7ce697a2f212752a35c1ac414471dc16c424c9573be4926b56ff3f5d23b7af
+make_check=no
 
 export RUAMEL_NO_PIP_INSTALL_CHECK=1
 
-do_check() {
-	:
-}
-
 post_install() {
 	vlicense LICENSE
 }

From 4a2aaa626598bcb88420bac16a60c78b62d60184 Mon Sep 17 00:00:00 2001
From: Joel Beckmeyer <joel@beckmeyer.us>
Date: Thu, 24 Mar 2022 13:32:43 -0400
Subject: [PATCH 2/2] whipper: add patch to support ruamel.yaml>=0.17

---
 .../patches/ruamel.yaml-0.17_compat.patch     | 109 ++++++++++++++++++
 srcpkgs/whipper/template                      |   2 +-
 2 files changed, 110 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/whipper/patches/ruamel.yaml-0.17_compat.patch

diff --git a/srcpkgs/whipper/patches/ruamel.yaml-0.17_compat.patch b/srcpkgs/whipper/patches/ruamel.yaml-0.17_compat.patch
new file mode 100644
index 000000000000..206547e4b3e9
--- /dev/null
+++ b/srcpkgs/whipper/patches/ruamel.yaml-0.17_compat.patch
@@ -0,0 +1,109 @@
+From e0942417a1c267781a8b676789730457dcb2e6fa Mon Sep 17 00:00:00 2001
+From: Martin Weinelt <hexa@darmstadt.ccc.de>
+Date: Sun, 20 Jun 2021 15:18:37 +0200
+Subject: [PATCH] Use custom YAML subclass to be compatible with
+ ruamel_yaml>=0.17
+
+Signed-off-by: Martin Weinelt <hexa@darmstadt.ccc.de>
+---
+ whipper/common/yaml.py             | 18 ++++++++++++++++++
+ whipper/result/logger.py           | 11 ++++++-----
+ whipper/test/test_result_logger.py | 14 ++++++--------
+ 3 files changed, 30 insertions(+), 13 deletions(-)
+ create mode 100644 whipper/common/yaml.py
+
+diff --git a/whipper/common/yaml.py b/whipper/common/yaml.py
+new file mode 100644
+index 00000000..4edb0b36
+--- /dev/null
++++ b/whipper/common/yaml.py
+@@ -0,0 +1,18 @@
++from ruamel.yaml import YAML as ruamel_YAML
++from ruamel.yaml.compat import StringIO
++
++# https://yaml.readthedocs.io/en/latest/example.html#output-of-dump-as-a-string
++class YAML(ruamel_YAML):
++    def __init__(self, *args, **kwargs):
++        super().__init__()
++        self.width = 4000
++        self.default_flow_style = False
++
++    def dump(self, data, stream=None, **kw):
++        inefficient = False
++        if stream is None:
++            inefficient = True
++            stream = StringIO()
++        ruamel_YAML.dump(self, data, stream, **kw)
++        if inefficient:
++            return stream.getvalue()
+diff --git a/whipper/result/logger.py b/whipper/result/logger.py
+index b7043adc..f4471a00 100644
+--- a/whipper/result/logger.py
++++ b/whipper/result/logger.py
+@@ -1,12 +1,12 @@
+ import time
+ import hashlib
+ import re
+-import ruamel.yaml as yaml
+ from ruamel.yaml.comments import CommentedMap as OrderedDict
+ 
+ import whipper
+ 
+ from whipper.common import common
++from whipper.common.yaml import YAML
+ from whipper.result import result
+ 
+ 
+@@ -148,11 +148,12 @@ def logRip(self, ripResult, epoch):
+         data["EOF"] = "End of status report"
+         riplog["Conclusive status report"] = data
+ 
++        yaml = YAML(
++            typ="rt",
++            pure=True
++        )
+         riplog = yaml.dump(
+-            riplog,
+-            default_flow_style=False,
+-            width=4000,
+-            Dumper=yaml.RoundTripDumper
++            riplog
+         )
+         # Add a newline after the "Log creation date" line
+         riplog = re.sub(
+diff --git a/whipper/test/test_result_logger.py b/whipper/test/test_result_logger.py
+index 411b61af..98c89ab5 100644
+--- a/whipper/test/test_result_logger.py
++++ b/whipper/test/test_result_logger.py
+@@ -3,8 +3,8 @@
+ import os
+ import re
+ import unittest
+-import ruamel.yaml
+ 
++from whipper.common.yaml import YAML
+ from whipper.result.result import TrackResult, RipResult
+ from whipper.result.logger import WhipperLogger
+ 
+@@ -163,16 +163,14 @@ def testLogger(self):
+             ))
+         )
+ 
+-        yaml = ruamel.yaml.YAML()
++        yaml = YAML(
++            typ='rt',
++            pure=True
++        )
+         parsedLog = yaml.load(actual)
+         self.assertEqual(
+             actual,
+-            ruamel.yaml.dump(
+-                parsedLog,
+-                default_flow_style=False,
+-                width=4000,
+-                Dumper=ruamel.yaml.RoundTripDumper
+-            )
++            yaml.dump(parsedLog)
+         )
+         log_body = "\n".join(actualLines[:-1]).encode()
+         self.assertEqual(
diff --git a/srcpkgs/whipper/template b/srcpkgs/whipper/template
index c5bbd74cfacc..e0f5cf8b8026 100644
--- a/srcpkgs/whipper/template
+++ b/srcpkgs/whipper/template
@@ -1,7 +1,7 @@
 # Template file for 'whipper'
 pkgname=whipper
 version=0.10.0
-revision=2
+revision=3
 build_style=python3-module
 hostmakedepends="python3-setuptools_scm"
 makedepends="libsndfile-devel python3-devel"

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [PR REVIEW] python3-ruamel.yaml: update to 0.17.21.
  2022-03-24 17:35 [PR PATCH] python3-ruamel.yaml: update to 0.17.21 TinfoilSubmarine
@ 2022-05-07 21:41 ` paper42
  2022-05-08  0:12 ` [PR PATCH] [Updated] " TinfoilSubmarine
                   ` (6 subsequent siblings)
  7 siblings, 0 replies; 9+ messages in thread
From: paper42 @ 2022-05-07 21:41 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 187 bytes --]

New review comment by paper42 on void-packages repository

https://github.com/void-linux/void-packages/pull/36320#discussion_r867397816

Comment:
we should explain why tests are disabled

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [PR PATCH] [Updated] python3-ruamel.yaml: update to 0.17.21.
  2022-03-24 17:35 [PR PATCH] python3-ruamel.yaml: update to 0.17.21 TinfoilSubmarine
  2022-05-07 21:41 ` [PR REVIEW] " paper42
@ 2022-05-08  0:12 ` TinfoilSubmarine
  2022-05-08  0:12 ` [PR REVIEW] " TinfoilSubmarine
                   ` (5 subsequent siblings)
  7 siblings, 0 replies; 9+ messages in thread
From: TinfoilSubmarine @ 2022-05-08  0:12 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 1397 bytes --]

There is an updated pull request by TinfoilSubmarine against master on the void-packages repository

https://github.com/TinfoilSubmarine/void-packages ruamel.yaml
https://github.com/void-linux/void-packages/pull/36320

python3-ruamel.yaml: update to 0.17.21.
<!-- Uncomment relevant sections and delete options which are not applicable -->

#### Testing the changes
- I tested the changes in this PR: **YES**

Tested with all dependents:

- [x] borgmatic
- [x] khard
- [x] python3-ansible-lint
- [x] python3-pykwalify
- [x] whipper (needed patch)

<!--
#### New package
- This new package conforms to the [quality requirements](https://github.com/void-linux/void-packages/blob/master/Manual.md#quality-requirements): **YES**|**NO**
-->

<!-- Note: If the build is likely to take more than 2 hours, please [skip CI](https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#continuous-integration)
and test at least one native build and, if supported, at least one cross build.
Ignore this section if this PR is not skipping CI.
-->
<!-- 
#### Local build testing
- I built this PR locally for my native architecture, (ARCH-LIBC)
- I built this PR locally for these architectures (if supported. mark crossbuilds):
  - aarch64-musl
  - armv7l
  - armv6l-musl
-->


A patch file from https://github.com/void-linux/void-packages/pull/36320.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-ruamel.yaml-36320.patch --]
[-- Type: text/x-diff, Size: 6031 bytes --]

From de0b1736f01e2635897e7355c01284fd5084a710 Mon Sep 17 00:00:00 2001
From: Joel Beckmeyer <joel@beckmeyer.us>
Date: Thu, 24 Mar 2022 13:12:36 -0400
Subject: [PATCH 1/2] python3-ruamel.yaml: update to 0.17.21.

---
 srcpkgs/python3-ruamel.yaml/template | 14 ++++++--------
 1 file changed, 6 insertions(+), 8 deletions(-)

diff --git a/srcpkgs/python3-ruamel.yaml/template b/srcpkgs/python3-ruamel.yaml/template
index b8ad65ed0883..4f9dadaa0006 100644
--- a/srcpkgs/python3-ruamel.yaml/template
+++ b/srcpkgs/python3-ruamel.yaml/template
@@ -1,25 +1,23 @@
 # Template file for 'python3-ruamel.yaml'
 pkgname=python3-ruamel.yaml
-version=0.16.12
-revision=4
+version=0.17.21
+revision=1
 wrksrc="ruamel.yaml-${version}"
 build_style=python3-module
 hostmakedepends="python3-setuptools"
 makedepends="python3-devel"
-depends="python3"
+depends="python3-ruamel.yaml.clib"
 short_desc="YAML parser/emitter in Python 3"
 maintainer="Orphaned <orphan@voidlinux.org>"
 license="MIT"
 homepage="http://yaml.readthedocs.io/"
+changelog="https://sourceforge.net/p/ruamel-yaml/code/ci/default/tree/CHANGES"
 distfiles="${PYPI_SITE}/r/ruamel.yaml/ruamel.yaml-${version}.tar.gz"
-checksum=076cc0bc34f1966d920a49f18b52b6ad559fbe656a0748e3535cf7b3f29ebf9e
+checksum=8b7ce697a2f212752a35c1ac414471dc16c424c9573be4926b56ff3f5d23b7af
+make_check=no # no tests included in distfiles
 
 export RUAMEL_NO_PIP_INSTALL_CHECK=1
 
-do_check() {
-	:
-}
-
 post_install() {
 	vlicense LICENSE
 }

From daf4ae8e09e09bc3c2630fbc64faf84d4ab8389e Mon Sep 17 00:00:00 2001
From: Joel Beckmeyer <joel@beckmeyer.us>
Date: Thu, 24 Mar 2022 13:32:43 -0400
Subject: [PATCH 2/2] whipper: add patch to support ruamel.yaml>=0.17

---
 .../patches/ruamel.yaml-0.17_compat.patch     | 109 ++++++++++++++++++
 srcpkgs/whipper/template                      |   2 +-
 2 files changed, 110 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/whipper/patches/ruamel.yaml-0.17_compat.patch

diff --git a/srcpkgs/whipper/patches/ruamel.yaml-0.17_compat.patch b/srcpkgs/whipper/patches/ruamel.yaml-0.17_compat.patch
new file mode 100644
index 000000000000..206547e4b3e9
--- /dev/null
+++ b/srcpkgs/whipper/patches/ruamel.yaml-0.17_compat.patch
@@ -0,0 +1,109 @@
+From e0942417a1c267781a8b676789730457dcb2e6fa Mon Sep 17 00:00:00 2001
+From: Martin Weinelt <hexa@darmstadt.ccc.de>
+Date: Sun, 20 Jun 2021 15:18:37 +0200
+Subject: [PATCH] Use custom YAML subclass to be compatible with
+ ruamel_yaml>=0.17
+
+Signed-off-by: Martin Weinelt <hexa@darmstadt.ccc.de>
+---
+ whipper/common/yaml.py             | 18 ++++++++++++++++++
+ whipper/result/logger.py           | 11 ++++++-----
+ whipper/test/test_result_logger.py | 14 ++++++--------
+ 3 files changed, 30 insertions(+), 13 deletions(-)
+ create mode 100644 whipper/common/yaml.py
+
+diff --git a/whipper/common/yaml.py b/whipper/common/yaml.py
+new file mode 100644
+index 00000000..4edb0b36
+--- /dev/null
++++ b/whipper/common/yaml.py
+@@ -0,0 +1,18 @@
++from ruamel.yaml import YAML as ruamel_YAML
++from ruamel.yaml.compat import StringIO
++
++# https://yaml.readthedocs.io/en/latest/example.html#output-of-dump-as-a-string
++class YAML(ruamel_YAML):
++    def __init__(self, *args, **kwargs):
++        super().__init__()
++        self.width = 4000
++        self.default_flow_style = False
++
++    def dump(self, data, stream=None, **kw):
++        inefficient = False
++        if stream is None:
++            inefficient = True
++            stream = StringIO()
++        ruamel_YAML.dump(self, data, stream, **kw)
++        if inefficient:
++            return stream.getvalue()
+diff --git a/whipper/result/logger.py b/whipper/result/logger.py
+index b7043adc..f4471a00 100644
+--- a/whipper/result/logger.py
++++ b/whipper/result/logger.py
+@@ -1,12 +1,12 @@
+ import time
+ import hashlib
+ import re
+-import ruamel.yaml as yaml
+ from ruamel.yaml.comments import CommentedMap as OrderedDict
+ 
+ import whipper
+ 
+ from whipper.common import common
++from whipper.common.yaml import YAML
+ from whipper.result import result
+ 
+ 
+@@ -148,11 +148,12 @@ def logRip(self, ripResult, epoch):
+         data["EOF"] = "End of status report"
+         riplog["Conclusive status report"] = data
+ 
++        yaml = YAML(
++            typ="rt",
++            pure=True
++        )
+         riplog = yaml.dump(
+-            riplog,
+-            default_flow_style=False,
+-            width=4000,
+-            Dumper=yaml.RoundTripDumper
++            riplog
+         )
+         # Add a newline after the "Log creation date" line
+         riplog = re.sub(
+diff --git a/whipper/test/test_result_logger.py b/whipper/test/test_result_logger.py
+index 411b61af..98c89ab5 100644
+--- a/whipper/test/test_result_logger.py
++++ b/whipper/test/test_result_logger.py
+@@ -3,8 +3,8 @@
+ import os
+ import re
+ import unittest
+-import ruamel.yaml
+ 
++from whipper.common.yaml import YAML
+ from whipper.result.result import TrackResult, RipResult
+ from whipper.result.logger import WhipperLogger
+ 
+@@ -163,16 +163,14 @@ def testLogger(self):
+             ))
+         )
+ 
+-        yaml = ruamel.yaml.YAML()
++        yaml = YAML(
++            typ='rt',
++            pure=True
++        )
+         parsedLog = yaml.load(actual)
+         self.assertEqual(
+             actual,
+-            ruamel.yaml.dump(
+-                parsedLog,
+-                default_flow_style=False,
+-                width=4000,
+-                Dumper=ruamel.yaml.RoundTripDumper
+-            )
++            yaml.dump(parsedLog)
+         )
+         log_body = "\n".join(actualLines[:-1]).encode()
+         self.assertEqual(
diff --git a/srcpkgs/whipper/template b/srcpkgs/whipper/template
index c5bbd74cfacc..e0f5cf8b8026 100644
--- a/srcpkgs/whipper/template
+++ b/srcpkgs/whipper/template
@@ -1,7 +1,7 @@
 # Template file for 'whipper'
 pkgname=whipper
 version=0.10.0
-revision=2
+revision=3
 build_style=python3-module
 hostmakedepends="python3-setuptools_scm"
 makedepends="libsndfile-devel python3-devel"

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [PR REVIEW] python3-ruamel.yaml: update to 0.17.21.
  2022-03-24 17:35 [PR PATCH] python3-ruamel.yaml: update to 0.17.21 TinfoilSubmarine
  2022-05-07 21:41 ` [PR REVIEW] " paper42
  2022-05-08  0:12 ` [PR PATCH] [Updated] " TinfoilSubmarine
@ 2022-05-08  0:12 ` TinfoilSubmarine
  2022-05-09 12:49 ` [PR PATCH] [Updated] " TinfoilSubmarine
                   ` (4 subsequent siblings)
  7 siblings, 0 replies; 9+ messages in thread
From: TinfoilSubmarine @ 2022-05-08  0:12 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 169 bytes --]

New review comment by TinfoilSubmarine on void-packages repository

https://github.com/void-linux/void-packages/pull/36320#discussion_r867413210

Comment:
Indeed. Fixed

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [PR PATCH] [Updated] python3-ruamel.yaml: update to 0.17.21.
  2022-03-24 17:35 [PR PATCH] python3-ruamel.yaml: update to 0.17.21 TinfoilSubmarine
                   ` (2 preceding siblings ...)
  2022-05-08  0:12 ` [PR REVIEW] " TinfoilSubmarine
@ 2022-05-09 12:49 ` TinfoilSubmarine
  2022-05-09 12:56 ` TinfoilSubmarine
                   ` (3 subsequent siblings)
  7 siblings, 0 replies; 9+ messages in thread
From: TinfoilSubmarine @ 2022-05-09 12:49 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 1397 bytes --]

There is an updated pull request by TinfoilSubmarine against master on the void-packages repository

https://github.com/TinfoilSubmarine/void-packages ruamel.yaml
https://github.com/void-linux/void-packages/pull/36320

python3-ruamel.yaml: update to 0.17.21.
<!-- Uncomment relevant sections and delete options which are not applicable -->

#### Testing the changes
- I tested the changes in this PR: **YES**

Tested with all dependents:

- [x] borgmatic
- [x] khard
- [x] python3-ansible-lint
- [x] python3-pykwalify
- [x] whipper (needed patch)

<!--
#### New package
- This new package conforms to the [quality requirements](https://github.com/void-linux/void-packages/blob/master/Manual.md#quality-requirements): **YES**|**NO**
-->

<!-- Note: If the build is likely to take more than 2 hours, please [skip CI](https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#continuous-integration)
and test at least one native build and, if supported, at least one cross build.
Ignore this section if this PR is not skipping CI.
-->
<!-- 
#### Local build testing
- I built this PR locally for my native architecture, (ARCH-LIBC)
- I built this PR locally for these architectures (if supported. mark crossbuilds):
  - aarch64-musl
  - armv7l
  - armv6l-musl
-->


A patch file from https://github.com/void-linux/void-packages/pull/36320.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-ruamel.yaml-36320.patch --]
[-- Type: text/x-diff, Size: 6031 bytes --]

From 2ff44cf87067a6807ca7fd589fa4ac5619556bfe Mon Sep 17 00:00:00 2001
From: Joel Beckmeyer <joel@beckmeyer.us>
Date: Thu, 24 Mar 2022 13:12:36 -0400
Subject: [PATCH 1/2] python3-ruamel.yaml: update to 0.17.21.

---
 srcpkgs/python3-ruamel.yaml/template | 14 ++++++--------
 1 file changed, 6 insertions(+), 8 deletions(-)

diff --git a/srcpkgs/python3-ruamel.yaml/template b/srcpkgs/python3-ruamel.yaml/template
index b8ad65ed0883..4f9dadaa0006 100644
--- a/srcpkgs/python3-ruamel.yaml/template
+++ b/srcpkgs/python3-ruamel.yaml/template
@@ -1,25 +1,23 @@
 # Template file for 'python3-ruamel.yaml'
 pkgname=python3-ruamel.yaml
-version=0.16.12
-revision=4
+version=0.17.21
+revision=1
 wrksrc="ruamel.yaml-${version}"
 build_style=python3-module
 hostmakedepends="python3-setuptools"
 makedepends="python3-devel"
-depends="python3"
+depends="python3-ruamel.yaml.clib"
 short_desc="YAML parser/emitter in Python 3"
 maintainer="Orphaned <orphan@voidlinux.org>"
 license="MIT"
 homepage="http://yaml.readthedocs.io/"
+changelog="https://sourceforge.net/p/ruamel-yaml/code/ci/default/tree/CHANGES"
 distfiles="${PYPI_SITE}/r/ruamel.yaml/ruamel.yaml-${version}.tar.gz"
-checksum=076cc0bc34f1966d920a49f18b52b6ad559fbe656a0748e3535cf7b3f29ebf9e
+checksum=8b7ce697a2f212752a35c1ac414471dc16c424c9573be4926b56ff3f5d23b7af
+make_check=no # no tests included in distfiles
 
 export RUAMEL_NO_PIP_INSTALL_CHECK=1
 
-do_check() {
-	:
-}
-
 post_install() {
 	vlicense LICENSE
 }

From 8bb3380dee0a221fab47e3b691ed6426fc164dde Mon Sep 17 00:00:00 2001
From: Joel Beckmeyer <joel@beckmeyer.us>
Date: Thu, 24 Mar 2022 13:32:43 -0400
Subject: [PATCH 2/2] whipper: add patch to support ruamel.yaml>=0.17

---
 .../patches/ruamel.yaml-0.17_compat.patch     | 109 ++++++++++++++++++
 srcpkgs/whipper/template                      |   2 +-
 2 files changed, 110 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/whipper/patches/ruamel.yaml-0.17_compat.patch

diff --git a/srcpkgs/whipper/patches/ruamel.yaml-0.17_compat.patch b/srcpkgs/whipper/patches/ruamel.yaml-0.17_compat.patch
new file mode 100644
index 000000000000..206547e4b3e9
--- /dev/null
+++ b/srcpkgs/whipper/patches/ruamel.yaml-0.17_compat.patch
@@ -0,0 +1,109 @@
+From e0942417a1c267781a8b676789730457dcb2e6fa Mon Sep 17 00:00:00 2001
+From: Martin Weinelt <hexa@darmstadt.ccc.de>
+Date: Sun, 20 Jun 2021 15:18:37 +0200
+Subject: [PATCH] Use custom YAML subclass to be compatible with
+ ruamel_yaml>=0.17
+
+Signed-off-by: Martin Weinelt <hexa@darmstadt.ccc.de>
+---
+ whipper/common/yaml.py             | 18 ++++++++++++++++++
+ whipper/result/logger.py           | 11 ++++++-----
+ whipper/test/test_result_logger.py | 14 ++++++--------
+ 3 files changed, 30 insertions(+), 13 deletions(-)
+ create mode 100644 whipper/common/yaml.py
+
+diff --git a/whipper/common/yaml.py b/whipper/common/yaml.py
+new file mode 100644
+index 00000000..4edb0b36
+--- /dev/null
++++ b/whipper/common/yaml.py
+@@ -0,0 +1,18 @@
++from ruamel.yaml import YAML as ruamel_YAML
++from ruamel.yaml.compat import StringIO
++
++# https://yaml.readthedocs.io/en/latest/example.html#output-of-dump-as-a-string
++class YAML(ruamel_YAML):
++    def __init__(self, *args, **kwargs):
++        super().__init__()
++        self.width = 4000
++        self.default_flow_style = False
++
++    def dump(self, data, stream=None, **kw):
++        inefficient = False
++        if stream is None:
++            inefficient = True
++            stream = StringIO()
++        ruamel_YAML.dump(self, data, stream, **kw)
++        if inefficient:
++            return stream.getvalue()
+diff --git a/whipper/result/logger.py b/whipper/result/logger.py
+index b7043adc..f4471a00 100644
+--- a/whipper/result/logger.py
++++ b/whipper/result/logger.py
+@@ -1,12 +1,12 @@
+ import time
+ import hashlib
+ import re
+-import ruamel.yaml as yaml
+ from ruamel.yaml.comments import CommentedMap as OrderedDict
+ 
+ import whipper
+ 
+ from whipper.common import common
++from whipper.common.yaml import YAML
+ from whipper.result import result
+ 
+ 
+@@ -148,11 +148,12 @@ def logRip(self, ripResult, epoch):
+         data["EOF"] = "End of status report"
+         riplog["Conclusive status report"] = data
+ 
++        yaml = YAML(
++            typ="rt",
++            pure=True
++        )
+         riplog = yaml.dump(
+-            riplog,
+-            default_flow_style=False,
+-            width=4000,
+-            Dumper=yaml.RoundTripDumper
++            riplog
+         )
+         # Add a newline after the "Log creation date" line
+         riplog = re.sub(
+diff --git a/whipper/test/test_result_logger.py b/whipper/test/test_result_logger.py
+index 411b61af..98c89ab5 100644
+--- a/whipper/test/test_result_logger.py
++++ b/whipper/test/test_result_logger.py
+@@ -3,8 +3,8 @@
+ import os
+ import re
+ import unittest
+-import ruamel.yaml
+ 
++from whipper.common.yaml import YAML
+ from whipper.result.result import TrackResult, RipResult
+ from whipper.result.logger import WhipperLogger
+ 
+@@ -163,16 +163,14 @@ def testLogger(self):
+             ))
+         )
+ 
+-        yaml = ruamel.yaml.YAML()
++        yaml = YAML(
++            typ='rt',
++            pure=True
++        )
+         parsedLog = yaml.load(actual)
+         self.assertEqual(
+             actual,
+-            ruamel.yaml.dump(
+-                parsedLog,
+-                default_flow_style=False,
+-                width=4000,
+-                Dumper=ruamel.yaml.RoundTripDumper
+-            )
++            yaml.dump(parsedLog)
+         )
+         log_body = "\n".join(actualLines[:-1]).encode()
+         self.assertEqual(
diff --git a/srcpkgs/whipper/template b/srcpkgs/whipper/template
index c5bbd74cfacc..e0f5cf8b8026 100644
--- a/srcpkgs/whipper/template
+++ b/srcpkgs/whipper/template
@@ -1,7 +1,7 @@
 # Template file for 'whipper'
 pkgname=whipper
 version=0.10.0
-revision=2
+revision=3
 build_style=python3-module
 hostmakedepends="python3-setuptools_scm"
 makedepends="libsndfile-devel python3-devel"

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: python3-ruamel.yaml: update to 0.17.21.
  2022-03-24 17:35 [PR PATCH] python3-ruamel.yaml: update to 0.17.21 TinfoilSubmarine
                   ` (3 preceding siblings ...)
  2022-05-09 12:49 ` [PR PATCH] [Updated] " TinfoilSubmarine
@ 2022-05-09 12:56 ` TinfoilSubmarine
  2022-06-10 15:33 ` [PR REVIEW] " paper42
                   ` (2 subsequent siblings)
  7 siblings, 0 replies; 9+ messages in thread
From: TinfoilSubmarine @ 2022-05-09 12:56 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 249 bytes --]

New comment by TinfoilSubmarine on void-packages repository

https://github.com/void-linux/void-packages/pull/36320#issuecomment-1121064711

Comment:
Force-pushed to run tests since make_check_pre stuff is fixed now; everything looks good here now.

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [PR REVIEW] python3-ruamel.yaml: update to 0.17.21.
  2022-03-24 17:35 [PR PATCH] python3-ruamel.yaml: update to 0.17.21 TinfoilSubmarine
                   ` (4 preceding siblings ...)
  2022-05-09 12:56 ` TinfoilSubmarine
@ 2022-06-10 15:33 ` paper42
  2022-06-10 15:59 ` TinfoilSubmarine
  2022-07-01 21:08 ` [PR PATCH] [Merged]: " the-maldridge
  7 siblings, 0 replies; 9+ messages in thread
From: paper42 @ 2022-06-10 15:33 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 195 bytes --]

New review comment by paper42 on void-packages repository

https://github.com/void-linux/void-packages/pull/36320#discussion_r894657580

Comment:
could we use a distfiles source that has tests? 

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [PR REVIEW] python3-ruamel.yaml: update to 0.17.21.
  2022-03-24 17:35 [PR PATCH] python3-ruamel.yaml: update to 0.17.21 TinfoilSubmarine
                   ` (5 preceding siblings ...)
  2022-06-10 15:33 ` [PR REVIEW] " paper42
@ 2022-06-10 15:59 ` TinfoilSubmarine
  2022-07-01 21:08 ` [PR PATCH] [Merged]: " the-maldridge
  7 siblings, 0 replies; 9+ messages in thread
From: TinfoilSubmarine @ 2022-06-10 15:59 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 424 bytes --]

New review comment by TinfoilSubmarine on void-packages repository

https://github.com/void-linux/void-packages/pull/36320#discussion_r894680922

Comment:
Not sure if it's possible. It's hosted on sourceforge.net but there are no tarballs/downloads in https://sourceforge.net/projects/ruamel-yaml/files/ like there are for other packages with distfiles from sourceforge, e.g. https://sourceforge.net/projects/drumkv1/files/

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [PR PATCH] [Merged]: python3-ruamel.yaml: update to 0.17.21.
  2022-03-24 17:35 [PR PATCH] python3-ruamel.yaml: update to 0.17.21 TinfoilSubmarine
                   ` (6 preceding siblings ...)
  2022-06-10 15:59 ` TinfoilSubmarine
@ 2022-07-01 21:08 ` the-maldridge
  7 siblings, 0 replies; 9+ messages in thread
From: the-maldridge @ 2022-07-01 21:08 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 1219 bytes --]

There's a merged pull request on the void-packages repository

python3-ruamel.yaml: update to 0.17.21.
https://github.com/void-linux/void-packages/pull/36320

Description:
<!-- Uncomment relevant sections and delete options which are not applicable -->

#### Testing the changes
- I tested the changes in this PR: **YES**

Tested with all dependents:

- [x] borgmatic
- [x] khard
- [x] python3-ansible-lint
- [x] python3-pykwalify
- [x] whipper (needed patch)

<!--
#### New package
- This new package conforms to the [quality requirements](https://github.com/void-linux/void-packages/blob/master/Manual.md#quality-requirements): **YES**|**NO**
-->

<!-- Note: If the build is likely to take more than 2 hours, please [skip CI](https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#continuous-integration)
and test at least one native build and, if supported, at least one cross build.
Ignore this section if this PR is not skipping CI.
-->
<!-- 
#### Local build testing
- I built this PR locally for my native architecture, (ARCH-LIBC)
- I built this PR locally for these architectures (if supported. mark crossbuilds):
  - aarch64-musl
  - armv7l
  - armv6l-musl
-->


^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2022-07-01 21:08 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-03-24 17:35 [PR PATCH] python3-ruamel.yaml: update to 0.17.21 TinfoilSubmarine
2022-05-07 21:41 ` [PR REVIEW] " paper42
2022-05-08  0:12 ` [PR PATCH] [Updated] " TinfoilSubmarine
2022-05-08  0:12 ` [PR REVIEW] " TinfoilSubmarine
2022-05-09 12:49 ` [PR PATCH] [Updated] " TinfoilSubmarine
2022-05-09 12:56 ` TinfoilSubmarine
2022-06-10 15:33 ` [PR REVIEW] " paper42
2022-06-10 15:59 ` TinfoilSubmarine
2022-07-01 21:08 ` [PR PATCH] [Merged]: " the-maldridge

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).