Script 'mail_helper' called by obssrc Hello community, here is the log from the commit of package bup for openSUSE:Factory checked in at 2023-06-22 23:27:16 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/bup (Old) and /work/SRC/openSUSE:Factory/.bup.new.15902 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "bup" Thu Jun 22 23:27:16 2023 rev:5 rq:1094712 version:0.32.1 Changes: -------- --- /work/SRC/openSUSE:Factory/bup/bup.changes 2021-09-20 23:34:21.383262764 +0200 +++ /work/SRC/openSUSE:Factory/.bup.new.15902/bup.changes 2023-06-22 23:28:04.598458328 +0200 @@ -1,0 +2,11 @@ +Thu Jun 22 16:44:45 UTC 2023 - ecsos <ec...@opensuse.org> + +- Update to 0.32.1 + - See https://github.com/bup/bup/blob/master/note/0.32.1-from-0.32.md + +------------------------------------------------------------------- +Thu Jun 22 16:44:45 UTC 2023 - ecsos <ec...@opensuse.org> + +- Update to 0.32.1 + - See https://github.com/bup/bup/blob/master/note/0.32.1-from-0.32.md +------------------------------------------------------------------- Old: ---- bup-0.32.tar.gz New: ---- bup-0.32.1.tar.gz ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ bup.spec ++++++ --- /var/tmp/diff_new_pack.0Cjkyf/_old 2023-06-22 23:28:05.074460756 +0200 +++ /var/tmp/diff_new_pack.0Cjkyf/_new 2023-06-22 23:28:05.078460777 +0200 @@ -1,7 +1,7 @@ # # spec file for package bup # -# Copyright (c) 2021 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 @@ -20,7 +20,7 @@ %define with_test 0 Name: bup -Version: 0.32 +Version: 0.32.1 Release: 0 Summary: Backup program based on git License: LGPL-2.0-only ++++++ bup-0.32.tar.gz -> bup-0.32.1.tar.gz ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/bup-0.32/.github/CONTRIBUTING.md new/bup-0.32.1/.github/CONTRIBUTING.md --- old/bup-0.32/.github/CONTRIBUTING.md 2021-01-09 23:11:10.000000000 +0100 +++ new/bup-0.32.1/.github/CONTRIBUTING.md 2023-05-28 22:46:16.000000000 +0200 @@ -1,3 +1,3 @@ -Please see https://github.com/bup/bup/blob/master/HACKING +Please see https://github.com/bup/bup/blob/main/HACKING diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/bup-0.32/.github/PULL_REQUEST_TEMPLATE new/bup-0.32.1/.github/PULL_REQUEST_TEMPLATE --- old/bup-0.32/.github/PULL_REQUEST_TEMPLATE 2021-01-09 23:11:10.000000000 +0100 +++ new/bup-0.32.1/.github/PULL_REQUEST_TEMPLATE 2023-05-28 22:46:16.000000000 +0200 @@ -11,7 +11,7 @@ we'll be able to include your work in the project. See ./SIGNED-OFF-BY for the meaning: - https://github.com/bup/bup/blob/master/SIGNED-OFF-BY + https://github.com/bup/bup/blob/main/SIGNED-OFF-BY After you submit the pull request, someone will eventually redirect it to the list for review, and you will of course be included in the @@ -21,5 +21,5 @@ equivalent), please post your patches to the list as described in the "Submitting Patches" section in ./HACKING: - https://github.com/bup/bup/blob/master/HACKING + https://github.com/bup/bup/blob/main/HACKING diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/bup-0.32/HACKING new/bup-0.32.1/HACKING --- old/bup-0.32/HACKING 2021-01-09 23:11:10.000000000 +0100 +++ new/bup-0.32.1/HACKING 2023-05-28 22:46:16.000000000 +0200 @@ -4,8 +4,9 @@ Code Branching Model ==================== -The master branch is what we consider the main-line of development, -and the last, non-rc tag on master is the most recent stable release. +The main branch is the development branch, and stable releases are +tagged either from there, or from `VERSION.x` branches, created as +needed, for example `0.33.x`. Any branch with a "tmp/" prefix might be rebased (often), so keep that in mind when using or depending on one. @@ -55,7 +56,7 @@ In most cases, we try to wait until we have at least one or two "Reviewed-by:" replies to a patch posted to the list before -incorporating it into master, so reviews are an important way to help. +incorporating it into main, so reviews are an important way to help. We also love a good "Tested-by:" -- the more the merrier. @@ -99,9 +100,9 @@ inclusion (see ./SIGNED-OFF-BY). You can create a "signed off" set of patches in ./patches, ready for submission to the list, like this: - git format-patch -s -o patches origin/master + git format-patch -s -o patches origin/main -which will include all of the patches since origin/master on your +which will include all of the patches since origin/main on your current branch. Then you can send them to the list like this: git send-email --to bup-l...@googlegroups.com --compose patches/* @@ -111,7 +112,7 @@ It's also possible to handle everything in one step: - git send-email -s --to bup-l...@googlegroups.com --compose origin/master + git send-email -s --to bup-l...@googlegroups.com --compose origin/main and you can add --annotate if you'd like to review or edit each patch before it's sent. diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/bup-0.32/README.md new/bup-0.32.1/README.md --- old/bup-0.32/README.md 2021-01-09 23:11:10.000000000 +0100 +++ new/bup-0.32.1/README.md 2023-05-28 22:46:16.000000000 +0200 @@ -91,6 +91,7 @@ Notable changes introduced by a release ======================================= + - <a href="note/0.32.1-from-0.32.md">Changes in 0.32.1 as compared to 0.32</a> - <a href="note/0.32-from-0.31.md">Changes in 0.32 as compared to 0.31</a> - <a href="note/0.31-from-0.30.1.md">Changes in 0.31 as compared to 0.30.1</a> - <a href="note/0.30.1-from-0.30.md">Changes in 0.30.1 as compared to 0.30</a> @@ -109,7 +110,7 @@ | branch | Debian | FreeBSD | macOS | |--------|------------------------------------------------------------------------------------------------------------------------------------------------|--------------------------------------------------------------------------------------------------------------------------------------------------|----------------------------------------------------------------------------------------------------------------------------------------------| -| master | [](https://cirrus-ci.com/github/bup/bup) | [](https://cirrus-ci.com/github/bup/bup) | [](https://cirrus-ci.com/github/bup/bup) | +| main | [](https://cirrus-ci.com/github/bup/bup) | [](https://cirrus-ci.com/github/bup/bup) | [](https://cirrus-ci.com/github/bup/bup) | | 0.30.x | [](https://cirrus-ci.com/github/bup/bup) | [](https://cirrus-ci.com/github/bup/bup) | [](https://cirrus-ci.com/github/bup/bup) | | 0.29.x | [](https://cirrus-ci.com/github/bup/bup) | [](https://cirrus-ci.com/github/bup/bup) | [](https://cirrus-ci.com/github/bup/bup) | @@ -125,12 +126,12 @@ git clone https://github.com/bup/bup ``` - - This will leave you on the master branch, which is perfect if you + - This will leave you on the main branch, which is perfect if you would like to help with development, but if you'd just like to use bup, please check out the latest stable release like this: ```sh - git checkout 0.32 + git checkout 0.32.1 ``` You can see the latest stable release here: diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/bup-0.32/dev/compare-trees new/bup-0.32.1/dev/compare-trees --- old/bup-0.32/dev/compare-trees 2021-01-09 23:11:10.000000000 +0100 +++ new/bup-0.32.1/dev/compare-trees 2023-05-28 22:46:16.000000000 +0200 @@ -1,13 +1,16 @@ #!/usr/bin/env bash -set -u +set -euo pipefail # Test that src and dest trees are as identical as bup is capable of # making them. For now, use rsync -niaHAX ... usage() { cat <<EOF -Usage: compare-trees [-h] [-c] [-x] SOURCE DEST +Usage: + compare-trees [-c] [-x] [--] SOURCE DEST + compare-trees --features + compare-trees -h OPTIONS: -h Display help @@ -15,46 +18,61 @@ Check file content (default) -x Don't check file content (rely on size/timestamps, etc.) + --times + --no-times + Check or don't check timestamps (checking is the default) + --features + Show enabled features + -- + Don't treat following arguments as options (e.g. compare-trees -- -c dest) EOF } +show_features='' verify_content=" --checksum" +verify_times=' --times' -while getopts "hcx" OPTION -do - case "$OPTION" in - h) usage; exit 0;; - c) verify_content=" --checksum";; - x) verify_content="";; - ?) usage 1>&2; exit 1;; - esac -done - -shift $(($OPTIND - 1)) || exit $? +case "$#/${1:-}" in + 1/-h) usage; exit 0;; + 1/--features) show_features=yes; shift;; + *) + while test $# -gt 0; do + case "$1" in + -h|--features) usage 1>&2; exit 2;; + -c) verify_content=" --checksum"; shift;; + -x) verify_content=""; shift;; + --times) verify_times=' --times'; shift;; + --no-times) verify_times=''; shift;; + --) shift; break;; + [^-]*) break;; + esac + done +esac -if ! test $# -eq 2 -then +if test $# -ne 2 -a -z "$show_features"; then usage 1>&2 - exit 1 + exit 2 fi -src="$1" -dest="$2" - -tmpfile="$(mktemp /tmp/bup-test-XXXXXXX)" || exit $? -trap "rm -rf '$tmpfile'" EXIT || exit $? +src="${1:-}" +dest="${2:-}" -rsync_opts="-niaH$verify_content --delete" +rsync_opts="-rlpgoD" # --archive, without --times +rsync_opts="$rsync_opts -niH --delete" +rsync_opts="$rsync_opts$verify_content" +rsync_opts="$rsync_opts$verify_times" +comparing_acls='' rsync_version=$(rsync --version) if [[ ! "$rsync_version" =~ "ACLs" ]] || [[ "$rsync_version" =~ "no ACLs" ]]; then echo "Not comparing ACLs (not supported by available rsync)" 1>&2 else - case $OSTYPE in + case "$OSTYPE" in cygwin|darwin|netbsd) echo "Not comparing ACLs (not yet supported on $OSTYPE)" 1>&2 ;; *) + comparing_acls=yes rsync_opts="$rsync_opts -A" ;; esac @@ -67,6 +85,18 @@ xattrs_available=yes fi +if test "$show_features"; then + echo "POSIX ACLs: ${comparing_acls:-no}" + echo "Extended attributes (xattrs): ${xattrs_available:-no}" +fi + +if test "$show_features"; then + exit 0 +fi + +tmpfile="$(mktemp /tmp/bup-test-XXXXXXX)" || exit $? +trap "rm -rf '$tmpfile'" EXIT || exit $? + # Even in dry-run mode, rsync may fail if -X is specified and the # filesystems don't support xattrs. diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/bup-0.32/lib/bup/_helpers.c new/bup-0.32.1/lib/bup/_helpers.c --- old/bup-0.32/lib/bup/_helpers.c 2021-01-09 23:11:10.000000000 +0100 +++ new/bup-0.32.1/lib/bup/_helpers.c 2023-05-28 22:46:16.000000000 +0200 @@ -1899,6 +1899,7 @@ if (gethostname(buf, sizeof(buf) - 1)) return PyErr_SetFromErrno(PyExc_IOError); + buf[sizeof(buf) - 1] = 0; return PyBytes_FromString(buf); } @@ -1912,10 +1913,23 @@ int rc = PyBytes_AsStringAndSize(bytes, &buf, &length); if (rc == -1) return NULL; - char *result = checked_malloc(length, sizeof(char)); + size_t c_len; + if (!INTEGRAL_ASSIGNMENT_FITS(&c_len, length)) { + PyErr_Format(PyExc_OverflowError, "length will not fit in size_t"); + return NULL; + } + if (c_len == SIZE_MAX) { + PyErr_Format(PyExc_OverflowError, + "Cannot convert bytes object of size %zd to C string", + length); + return NULL; + } + c_len += 1; + char *result = checked_malloc(c_len, sizeof(char)); if (!result) return NULL; memcpy(result, buf, length); + result[length] = 0; return result; } @@ -2207,7 +2221,8 @@ return ret; } -static int bup_apply_acl_string(const char *name, const char *s) +static int +bup_apply_acl_string(const char *name, acl_type_t type, const char *s) { acl_t acl = acl_from_text(s); int ret = 0; @@ -2217,7 +2232,7 @@ return -1; } - if (acl_set_file(name, ACL_TYPE_ACCESS, acl)) { + if (acl_set_file(name, type, acl)) { PyErr_SetFromErrno(PyExc_IOError); ret = -1; } @@ -2234,10 +2249,10 @@ if (!PyArg_ParseTuple(args, cstr_argf cstr_argf "|" cstr_argf, &name, &acl, &def)) return NULL; - if (bup_apply_acl_string(name, acl)) + if (bup_apply_acl_string(name, ACL_TYPE_ACCESS, acl)) return NULL; - if (def && bup_apply_acl_string(name, def)) + if (def && bup_apply_acl_string(name, ACL_TYPE_DEFAULT, def)) return NULL; Py_RETURN_NONE; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/bup-0.32/lib/bup/source_info.py new/bup-0.32.1/lib/bup/source_info.py --- old/bup-0.32/lib/bup/source_info.py 2021-01-09 23:11:10.000000000 +0100 +++ new/bup-0.32.1/lib/bup/source_info.py 2023-05-28 22:46:16.000000000 +0200 @@ -1,3 +1,3 @@ -commit='3b052c63c93a95193447945296e7ec5db97f6b6e' -date='2021-01-09 16:11:10 -0600' +commit='b8b85fe68f331f6b28d7ca21dfd0f4b8df65952a' +date='2023-05-28 15:46:16 -0500' modified=False diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/bup-0.32/lib/bup/version.py new/bup-0.32.1/lib/bup/version.py --- old/bup-0.32/lib/bup/version.py 2021-01-09 23:11:10.000000000 +0100 +++ new/bup-0.32.1/lib/bup/version.py 2023-05-28 22:46:16.000000000 +0200 @@ -25,7 +25,7 @@ # The ~ in a version is a Debian-style "always less than" marker: # https://www.debian.org/doc/debian-policy/ch-controlfields.html#version -base_version = b'0.32' +base_version = b'0.32.1' version = base_version if version.endswith(b'~'): diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/bup-0.32/note/0.32.1-from-0.32.md new/bup-0.32.1/note/0.32.1-from-0.32.md --- old/bup-0.32/note/0.32.1-from-0.32.md 1970-01-01 01:00:00.000000000 +0100 +++ new/bup-0.32.1/note/0.32.1-from-0.32.md 2023-05-28 22:46:16.000000000 +0200 @@ -0,0 +1,38 @@ + +Notable changes in 0.32.1 since 0.32 +==================================== + +Bugs +---- + +* POSIX1e ACLs should be restored more correctly now. + + Previously bup incorrectly restored default (`ACL_TYPE_DEFAULT`) + ACLs as access acls (`ACL_TYPE_ACCESS`). When both existed, it + restored the access ACL first and then the default ACL as an access + ACL. Now, bup should restore each with the proper type. This issue + only affects saves created on platforms where bup currently supports + ACLs, so presumably mostly just saves created on Linux since the + current ACL support depends on non-standard functions like + `acl_extended(3)`. + + There is one remaining issue, which isn't fixed in this release, but + is fixed in 0.33.1 (because fixing it here could create saves that + are backward incompatible with 0.33). + + The problem is that in this version and older versions, bup stores + ACLs in the `acl_to_any_text(3)` format with a newline delimiter, + when the standard (and `acl_from_text(3)` which restore depends on) + requires commas. This may cause restores that include ACLs (likely + only those from Linux right now) to fail on some platforms + (e.g. Cygwin). + +Build and install +----------------- + +* pytest 7 is now supported. + +Thanks to (at least) +==================== + +Johannes Berg and Rob Browning diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/bup-0.32/test/ext/conftest.py new/bup-0.32.1/test/ext/conftest.py --- old/bup-0.32/test/ext/conftest.py 2021-01-09 23:11:10.000000000 +0100 +++ new/bup-0.32.1/test/ext/conftest.py 2023-05-28 22:46:16.000000000 +0200 @@ -1,4 +1,5 @@ +from pathlib import Path from subprocess import CalledProcessError import pytest, subprocess, sys @@ -8,6 +9,9 @@ # Handle all test-* files as wvtest protocol subprocesses # cf. https://docs.pytest.org/en/latest/example/nonpython.html +# version_tuple was added in 7 +use_node_path = hasattr(pytest, 'version_tuple') + class BupSubprocFailure(Exception): def __init__(self, msg, cmd, status, failures): super(BupSubprocFailure, self).__init__(msg) @@ -67,10 +71,13 @@ def pytest_collect_file(parent, path): base = path.basename if base.startswith('test-') and not base.endswith('~'): - try: - item = BupSubprocTestFile.from_parent(parent, fspath=path) - except AttributeError: - item = BupSubprocTestFile(path, parent) + if use_node_path: + item = BupSubprocTestFile.from_parent(parent, path=Path(path)) + else: + try: + item = BupSubprocTestFile.from_parent(parent, fspath=path) + except AttributeError: + item = BupSubprocTestFile(path, parent) if base == 'test-release-archive': item.add_marker(pytest.mark.release) return item diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/bup-0.32/test/ext/test-meta-acls new/bup-0.32.1/test/ext/test-meta-acls --- old/bup-0.32/test/ext/test-meta-acls 1970-01-01 01:00:00.000000000 +0100 +++ new/bup-0.32.1/test/ext/test-meta-acls 2023-05-28 22:46:16.000000000 +0200 @@ -0,0 +1,107 @@ +#!/usr/bin/env bash +. wvtest.sh +. wvtest-bup.sh +. dev/lib.sh + +set -o pipefail + +if ! command -v getfacl > /dev/null || ! command -v setfacl > /dev/null; then + WVSKIP "No getfacl and setfacl; skipping test-meta-acls" + exit 0 +fi + +top="$(WVPASS pwd)" || exit $? + +bup() { "$top/bup" "$@"; } +compare-trees() { "$top/dev/compare-trees" "$@"; } +id-other-than() { "$top/dev/id-other-than" "$@"; } + +if ! bup features | grep -qi 'posix acls: yes'; then + WVSKIP "bup features missing POSIX ACLs; skipping test-meta-acls" + exit 0 +fi + +if ! compare-trees --features | grep -qi 'posix acls: yes'; then + WVSKIP "compare-trees --features missing POSIX ACLs; skipping test-meta-acls" + exit 0 +fi + +tmpdir="$(WVPASS wvmktempdir)" || exit $? +export BUP_DIR="$tmpdir/bup" + +uid=$(WVPASS id -un) || exit $? +other_uinfo="$(id-other-than --user "$uid")" || exit $? +other_user="${other_uinfo%%:*}" +other_uid="${other_uinfo##*:}" + +gid=$(WVPASS id -gn) || exit $? +other_ginfo="$(id-other-than --group "$gid")" || exit $? +other_group="${other_ginfo%%:*}" +other_gid="${other_ginfo##*:}" + +WVPASS cd "$tmpdir" + +WVPASS mkdir src +WVPASS touch src/u-r + +if ! setfacl -m "u:$other_user:r" src/u-r; then + WVSKIP "setfacl $top/testfile failed; skipping test-meta-acls" + exit 0 +fi + +WVSTART "Basic ACL support" + +# file ACL_USER access acl(5) +for perm in r rw rwx; do + WVPASS touch src/u-"$perm" + WVPASS setfacl -m "u:$other_user:$perm" src/u-"$perm" +done +# file ACL_GROUP access acl(5) +for perm in r rw rwx; do + WVPASS touch src/g-"$perm" + WVPASS setfacl -m "g:$other_group:$perm" src/g-"$perm" +done + +# directory ACL_USER access acl(5) +for perm in r rw rwx; do + WVPASS mkdir src/d-u-"$perm" + WVPASS setfacl -m "u:$other_user:$perm" src/d-u-"$perm" +done +# directory ACL_GROUP access acl(5) +for perm in r rw rwx; do + WVPASS mkdir src/d-g-"$perm" + WVPASS setfacl -m "g:$other_group:$perm" src/d-g-"$perm" +done + +# directory ACL_USER default acl(5) +for perm in r rw rwx; do + WVPASS mkdir src/d-def-u-"$perm" + WVPASS setfacl -d -m "u:$other_user:$perm" src/d-def-u-"$perm" +done +# directory ACL_GROUP default acl(5) +for perm in r rw rwx; do + WVPASS mkdir src/d-def-g-"$perm" + WVPASS setfacl -d -m "g:$other_group:$perm" src/d-def-g-"$perm" +done + +# directory ACL_USER access and default acl(5) +for perm in r rw rwx; do + WVPASS mkdir src/d-both-u-"$perm" + WVPASS setfacl -m "u:$other_user:$perm" src/d-both-u-"$perm" + WVPASS setfacl -d -m "u:$other_user:$perm" src/d-both-u-"$perm" +done +# directory ACL_GROUP access and default acl(5) +for perm in r rw rwx; do + WVPASS mkdir src/d-both-g-"$perm" + WVPASS setfacl -m "g:$other_group:$perm" src/d-both-g-"$perm" + WVPASS setfacl -d -m "g:$other_group:$perm" src/d-both-g-"$perm" +done + +WVPASS bup init +WVPASS bup index -u src +WVPASS bup save --strip -n acls src +WVPASS bup restore -C dest acls/latest/. +WVPASS compare-trees src/ dest/ + +cd "$top" +WVPASS rm -rf "$tmpdir" diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/bup-0.32/test/ext/test-misc new/bup-0.32.1/test/ext/test-misc --- old/bup-0.32/test/ext/test-misc 2021-01-09 23:11:10.000000000 +0100 +++ new/bup-0.32.1/test/ext/test-misc 2023-05-28 22:46:16.000000000 +0200 @@ -15,6 +15,8 @@ WVSTART "init" WVPASS bup init +# Be independent of git defaults or a configured defaultBranch +git --git-dir "$BUP_DIR" symbolic-ref HEAD refs/heads/main D=bupdata.tmp WVPASS force-delete $D WVPASS mkdir $D @@ -50,7 +52,7 @@ #git repack -Ad #git prune WVPASS bup random 4k | WVPASS bup split -b - (WVPASS cd "$top/test/sampledata" && WVPASS bup save -vvn master /) || exit $? + (WVPASS cd "$top/test/sampledata" && WVPASS bup save -vvn main /) || exit $? result="$(LC_ALL=C git fsck --full --strict 2>&1)" || exit $? n=$(echo "$result" | WVFAIL egrep -v 'dangling (commit|tree|blob)' | @@ -61,10 +63,10 @@ WVSTART "ftp" -WVPASS bup ftp "cat /master/latest/$tmpdir/$D/b" >$D/b.new -WVPASS bup ftp "cat /master/latest/$tmpdir/$D/f" >$D/f.new -WVPASS bup ftp "cat /master/latest/$tmpdir/$D/f"{,} >$D/f2.new -WVPASS bup ftp "cat /master/latest/$tmpdir/$D/a" >$D/a.new +WVPASS bup ftp "cat /main/latest/$tmpdir/$D/b" >$D/b.new +WVPASS bup ftp "cat /main/latest/$tmpdir/$D/f" >$D/f.new +WVPASS bup ftp "cat /main/latest/$tmpdir/$D/f"{,} >$D/f2.new +WVPASS bup ftp "cat /main/latest/$tmpdir/$D/a" >$D/a.new WVPASSEQ "$(sha1sum <$D/b)" "$(sha1sum <$D/b.new)" WVPASSEQ "$(sha1sum <$D/f)" "$(sha1sum <$D/f.new)" WVPASSEQ "$(cat $D/f.new{,} | sha1sum)" "$(sha1sum <$D/f2.new)" @@ -75,10 +77,10 @@ WVFAIL bup tag -d v0.n 2>/dev/null WVFAIL bup tag v0.n non-existant 2>/dev/null WVPASSEQ "$(bup tag)" "" -WVPASS bup tag v0.1 master +WVPASS bup tag v0.1 main WVPASSEQ "$(bup tag)" "v0.1" -WVFAIL bup tag v0.1 master -WVPASS bup tag -f v0.1 master +WVFAIL bup tag v0.1 main +WVPASS bup tag -f v0.1 main WVPASS bup tag -d v0.1 WVPASS bup tag -f -d v0.1 WVFAIL bup tag -d v0.1 diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/bup-0.32/test/ext/test-save-restore new/bup-0.32.1/test/ext/test-save-restore --- old/bup-0.32/test/ext/test-save-restore 2021-01-09 23:11:10.000000000 +0100 +++ new/bup-0.32.1/test/ext/test-save-restore 2023-05-28 22:46:16.000000000 +0200 @@ -27,6 +27,8 @@ WVSTART "init" WVPASS bup init +# Be independent of git defaults or a configured defaultBranch +git --git-dir "$BUP_DIR" symbolic-ref HEAD refs/heads/main D=bupdata.tmp WVPASS force-delete $D WVPASS mkdir $D @@ -45,11 +47,11 @@ WVFAIL bup restore boink WVPASS touch "$tmpdir/$D/$D" WVPASS bup index -u "$tmpdir/$D" -WVPASS bup save -n master / -WVPASS bup restore -C buprestore.tmp "/master/latest/$tmpdir/$D" +WVPASS bup save -n main / +WVPASS bup restore -C buprestore.tmp "/main/latest/$tmpdir/$D" WVPASSEQ "$(ls buprestore.tmp)" "bupdata.tmp" WVPASS force-delete buprestore.tmp -WVPASS bup restore -C buprestore.tmp "/master/latest/$tmpdir/$D/" +WVPASS bup restore -C buprestore.tmp "/main/latest/$tmpdir/$D/" WVPASS touch $D/non-existent-file buprestore.tmp/non-existent-file # else diff fails WVPASS diff -ur $D/ buprestore.tmp/ WVPASS force-delete buprestore.tmp diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/bup-0.32/test/ext/test_get.py new/bup-0.32.1/test/ext/test_get.py --- old/bup-0.32/test/ext/test_get.py 2021-01-09 23:11:10.000000000 +0100 +++ new/bup-0.32.1/test/ext/test_get.py 2023-05-28 22:46:16.000000000 +0200 @@ -164,7 +164,6 @@ def validate_save(dest_name, restore_subpath, commit_id, tree_id, orig_value, get_out): out = get_out.splitlines() - print('blarg: out', repr(out), file=sys.stderr) wvpasseq(2, len(out)) get_tree_id = out[0] get_commit_id = out[1] @@ -292,8 +291,6 @@ wvpasseq(b'', exr.out.strip()) def _test_replace(get_disposition, src_info): - print('blarg:', repr(src_info), file=sys.stderr) - wvstart(get_disposition + ' --replace to root fails') for item in (b'.tag/tinyfile', b'src/latest' + src_info['tinyfile-path'], diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/bup-0.32/test/ext/test_prune_older.py new/bup-0.32.1/test/ext/test_prune_older.py --- old/bup-0.32/test/ext/test_prune_older.py 2021-01-09 23:11:10.000000000 +0100 +++ new/bup-0.32.1/test/ext/test_prune_older.py 2023-05-28 22:46:16.000000000 +0200 @@ -158,14 +158,15 @@ three_years_ago = now - (60 * 60 * 24 * 366 * 3) chdir(tmpdir) ex([b'git', b'init', b'work']) + ex([b'git', b'symbolic-ref', b'HEAD', b'refs/heads/main']) ex([b'git', b'config', b'gc.autoDetach', b'false']) wvstart('generating ' + str(save_population) + ' random saves') chdir(tmpdir + b'/work') save_utcs = create_older_random_saves(save_population, three_years_ago, now) chdir(tmpdir) - test_set_hash = exo([b'git', b'show-ref', b'-s', b'master']).out.rstrip() - ls_saves = exo((bup_cmd, b'ls', b'master')).out.splitlines() + test_set_hash = exo([b'git', b'show-ref', b'-s', b'main']).out.rstrip() + ls_saves = exo((bup_cmd, b'ls', b'main')).out.splitlines() wvpasseq(save_population + 1, len(ls_saves)) wvstart('ensure everything kept, if no keep arguments') @@ -173,7 +174,7 @@ proc = ex((bup_cmd, b'prune-older', b'-v', b'--unsafe', b'--no-gc', b'--wrt', b'%d' % now) \ - + (b'master',), + + (b'main',), stdout=None, stderr=PIPE, check=False) wvpassne(proc.rc, 0) wvpass(b'at least one keep argument is required' in proc.err) @@ -193,7 +194,7 @@ b'prune-older', b'-v', b'--unsafe', b'--no-gc', b'--wrt', b'%d' % now) \ + period_spec_to_period_args(spec) \ - + (b'master',)) + + (b'main',)) check_prune_result(expected) @@ -213,5 +214,5 @@ ex((bup_cmd, b'prune-older', b'-v', b'--unsafe', b'--wrt', b'%d' % now) \ + period_spec_to_period_args(spec) \ - + (b'master',)) + + (b'main',)) check_prune_result(expected) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/bup-0.32/test/int/test_git.py new/bup-0.32.1/test/int/test_git.py --- old/bup-0.32/test/int/test_git.py 2021-01-09 23:11:10.000000000 +0100 +++ new/bup-0.32.1/test/int/test_git.py 2023-05-28 22:46:16.000000000 +0200 @@ -262,8 +262,9 @@ environ[b'GIT_AUTHOR_EMAIL'] = b'bup@a425bc70a02811e49bdf73ee56450e6f' environ[b'GIT_COMMITTER_EMAIL'] = environ[b'GIT_AUTHOR_EMAIL'] try: - readpipe([b'git', b'init', workdir]) environ[b'GIT_DIR'] = environ[b'BUP_DIR'] = repodir + readpipe([b'git', b'init', workdir]) + exc(b'git', b'symbolic-ref', b'HEAD', b'refs/heads/main') git.check_repo_or_die(repodir) os.chdir(workdir) with open('foo', 'w') as f: @@ -272,7 +273,7 @@ readpipe([b'git', b'commit', b'-am', b'Do something', b'--author', b'Someone <someone@somewhere>', b'--date', b'Sat Oct 3 19:48:49 2009 -0400']) - commit = readpipe([b'git', b'show-ref', b'-s', b'master']).strip() + commit = readpipe([b'git', b'show-ref', b'-s', b'main']).strip() parents = showval(commit, b'%P') tree = showval(commit, b'%T') cname = showval(commit, b'%cn') @@ -299,7 +300,7 @@ f.write(b'baz\n') readpipe([b'git', b'add', '.']) readpipe([b'git', b'commit', b'-am', b'Do something else']) - child = readpipe([b'git', b'show-ref', b'-s', b'master']).strip() + child = readpipe([b'git', b'show-ref', b'-s', b'main']).strip() parents = showval(child, b'%P') commit_items = git.get_commit_items(child, git.cp()) WVPASSEQ(commit_items.parents, [commit]) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/bup-0.32/test/lib/buptest/__init__.py new/bup-0.32.1/test/lib/buptest/__init__.py --- old/bup-0.32/test/lib/buptest/__init__.py 2021-01-09 23:11:10.000000000 +0100 +++ new/bup-0.32.1/test/lib/buptest/__init__.py 2023-05-28 22:46:16.000000000 +0200 @@ -3,7 +3,7 @@ from collections import namedtuple from contextlib import contextmanager from os.path import abspath, basename, dirname, realpath -from pipes import quote +from shlex import quote from subprocess import PIPE, Popen from traceback import extract_stack import errno, os, subprocess, sys, tempfile