mirror of
https://github.com/void-linux/void-packages.git
synced 2025-07-29 00:42:58 +02:00
s3cmd: update to 2.2.0.
This commit is contained in:
parent
5990a69d79
commit
ce4fdd7dc0
2 changed files with 5 additions and 58 deletions
|
@ -1,54 +0,0 @@
|
||||||
# This patch has been already merged into `master`
|
|
||||||
# and should be dropped after next release.
|
|
||||||
# See https://github.com/s3tools/s3cmd/pull/1137
|
|
||||||
|
|
||||||
From 328ced84fe688db5ef0385f5c763cd948087d81f Mon Sep 17 00:00:00 2001
|
|
||||||
From: =?UTF-8?q?Ond=C5=99ej=20Budai?= <obudai@redhat.com>
|
|
||||||
Date: Fri, 2 Oct 2020 14:24:09 +0200
|
|
||||||
Subject: [PATCH] fix compatibility with Python 3.9
|
|
||||||
|
|
||||||
getchildren() method was removed from the ElementTree and Element classes in
|
|
||||||
Python 3.9. See the release notes:
|
|
||||||
|
|
||||||
https://docs.python.org/3.9/whatsnew/3.9.html#removed
|
|
||||||
---
|
|
||||||
S3/Exceptions.py | 2 +-
|
|
||||||
S3/Utils.py | 8 ++++----
|
|
||||||
2 files changed, 5 insertions(+), 5 deletions(-)
|
|
||||||
|
|
||||||
--- a/S3/Exceptions.py
|
|
||||||
+++ b/S3/Exceptions.py
|
|
||||||
@@ -127,7 +127,7 @@ def parse_error_xml(tree):
|
|
||||||
if not error_node.tag == "Error":
|
|
||||||
error_node = tree.find(".//Error")
|
|
||||||
if error_node is not None:
|
|
||||||
- for child in error_node.getchildren():
|
|
||||||
+ for child in error_node:
|
|
||||||
if child.text != "":
|
|
||||||
debug("ErrorXML: " + child.tag + ": " + repr(child.text))
|
|
||||||
info[child.tag] = child.text
|
|
||||||
--- a/S3/Utils.py
|
|
||||||
+++ b/S3/Utils.py
|
|
||||||
@@ -65,9 +65,9 @@ def parseNodes(nodes):
|
|
||||||
retval = []
|
|
||||||
for node in nodes:
|
|
||||||
retval_item = {}
|
|
||||||
- for child in node.getchildren():
|
|
||||||
+ for child in node:
|
|
||||||
name = decode_from_s3(child.tag)
|
|
||||||
- if child.getchildren():
|
|
||||||
+ if len(child):
|
|
||||||
retval_item[name] = parseNodes([child])
|
|
||||||
else:
|
|
||||||
found_text = node.findtext(".//%s" % child.tag)
|
|
||||||
@@ -124,8 +124,8 @@ def getListFromXml(xml, node):
|
|
||||||
|
|
||||||
def getDictFromTree(tree):
|
|
||||||
ret_dict = {}
|
|
||||||
- for child in tree.getchildren():
|
|
||||||
- if child.getchildren():
|
|
||||||
+ for child in tree:
|
|
||||||
+ if len(child):
|
|
||||||
## Complex-type child. Recurse
|
|
||||||
content = getDictFromTree(child)
|
|
||||||
else:
|
|
|
@ -1,17 +1,18 @@
|
||||||
# Template file for 's3cmd'
|
# Template file for 's3cmd'
|
||||||
pkgname=s3cmd
|
pkgname=s3cmd
|
||||||
version=2.1.0
|
version=2.2.0
|
||||||
revision=4
|
revision=1
|
||||||
build_style=python3-module
|
build_style=python3-module
|
||||||
hostmakedepends="python3-setuptools"
|
hostmakedepends="python3-setuptools"
|
||||||
depends="python3-dateutil"
|
depends="python3-dateutil"
|
||||||
short_desc="Command line tool for Amazon S3"
|
short_desc="Command line tool for Amazon S3"
|
||||||
maintainer="Duncaen <duncaen@voidlinux.org>"
|
maintainer="Duncaen <duncaen@voidlinux.org>"
|
||||||
license="GPL-2.0-or-later"
|
license="GPL-2.0-or-later"
|
||||||
changelog="https://github.com/s3tools/s3cmd/raw/master/NEWS"
|
|
||||||
homepage="http://s3tools.org/s3cmd"
|
homepage="http://s3tools.org/s3cmd"
|
||||||
|
changelog="https://github.com/s3tools/s3cmd/raw/master/NEWS"
|
||||||
distfiles="https://github.com/s3tools/${pkgname}/archive/v${version}.tar.gz"
|
distfiles="https://github.com/s3tools/${pkgname}/archive/v${version}.tar.gz"
|
||||||
checksum=2293f775fde77201bf8e489f20516fd594168c77897168f129e5c1a2b33b7e37
|
checksum=97283ed51f0fe46d2fa82c196f775603f90dbe1d080fcb81acb361106599258d
|
||||||
|
make_check="no" # requires a s3 server
|
||||||
|
|
||||||
pre_install() {
|
pre_install() {
|
||||||
export S3CMD_INSTPATH_DOC="share/doc"
|
export S3CMD_INSTPATH_DOC="share/doc"
|
||||||
|
|
Loading…
Add table
Reference in a new issue