Script 'mail_helper' called by obssrc Hello community, here is the log from the commit of package cvise for openSUSE:Factory checked in at 2022-11-21 15:30:18 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/cvise (Old) and /work/SRC/openSUSE:Factory/.cvise.new.1597 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "cvise" Mon Nov 21 15:30:18 2022 rev:60 rq:1037082 version:2.6.0+git.20221121.ff14486 Changes: -------- --- /work/SRC/openSUSE:Factory/cvise/cvise.changes 2022-10-18 12:46:05.981873973 +0200 +++ /work/SRC/openSUSE:Factory/.cvise.new.1597/cvise.changes 2022-11-21 15:30:47.997015151 +0100 @@ -1,0 +2,23 @@ +Mon Nov 21 11:01:27 UTC 2022 - mli...@suse.cz + +- Update to version 2.6.0+git.20221121.ff14486: + * Add c++2b for auto-detection in clangbinarysearch.py. + * Use detected --std in ClangBinarySearchPass + * Add extra llvm16 package. + * Port to LLVM ToT. + * Fix CI. + * CI: fix Leap + * CI: reorg installed packages + * CI: rename workflow + * CI: install findutils + * run pyupgrade + * run pyupgrade only with --py36-plus. + * Revert "run pyupgrade on the code" + * Revert "Expect Python 3.8+." + * Add pyupgrade to CI. + * run pyupgrade on the code + * Expect Python 3.8+. + * Fix name of badge + * Update badges. + +------------------------------------------------------------------- Old: ---- cvise-2.6.0+git.20221018.7c1f0b4.tar.xz New: ---- cvise-2.6.0+git.20221121.ff14486.tar.xz ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ cvise.spec ++++++ --- /var/tmp/diff_new_pack.kClGpN/_old 2022-11-21 15:30:48.809019273 +0100 +++ /var/tmp/diff_new_pack.kClGpN/_new 2022-11-21 15:30:48.813019293 +0100 @@ -17,7 +17,7 @@ Name: cvise -Version: 2.6.0+git.20221018.7c1f0b4 +Version: 2.6.0+git.20221121.ff14486 Release: 0 Summary: Super-parallel Python port of the C-Reduce License: BSD-3-Clause ++++++ _servicedata ++++++ --- /var/tmp/diff_new_pack.kClGpN/_old 2022-11-21 15:30:48.921019841 +0100 +++ /var/tmp/diff_new_pack.kClGpN/_new 2022-11-21 15:30:48.929019882 +0100 @@ -1,6 +1,6 @@ <servicedata> <service name="tar_scm"> <param name="url">https://github.com/marxin/cvise</param> - <param name="changesrevision">7c1f0b44034f6d00f1bcb548efc338c2356325b3</param></service></servicedata> + <param name="changesrevision">ff14486d5dfa3843230fc01970429d889752cee1</param></service></servicedata> (No newline at EOF) ++++++ cvise-2.6.0+git.20221018.7c1f0b4.tar.xz -> cvise-2.6.0+git.20221121.ff14486.tar.xz ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/cvise-2.6.0+git.20221018.7c1f0b4/.github/workflows/build-llvm-nightly.yml new/cvise-2.6.0+git.20221121.ff14486/.github/workflows/build-llvm-nightly.yml --- old/cvise-2.6.0+git.20221018.7c1f0b4/.github/workflows/build-llvm-nightly.yml 2022-10-18 09:42:24.000000000 +0200 +++ new/cvise-2.6.0+git.20221121.ff14486/.github/workflows/build-llvm-nightly.yml 2022-11-21 12:00:03.000000000 +0100 @@ -20,7 +20,7 @@ - run: wget https://apt.llvm.org/llvm.sh - run: chmod +x llvm.sh - run: ./llvm.sh 16 - - run: apt-get install -y bolt-16 clang-16 libclang-common-16-dev libclang-16-dev mlir-16-tools llvm-16-tools libclang-common-16-dev libclang-16-dev libclang1-16 clang-format-16 python3-clang-16 clangd-16 clang-tidy-16 + - run: apt-get install -y bolt-16 clang-16 libclang-common-16-dev libclang-16-dev mlir-16-tools llvm-16-tools libclang-common-16-dev libclang-16-dev libclang1-16 clang-format-16 python3-clang-16 clangd-16 clang-tidy-16 libomp-16-dev # TODO: fix it - run: ln -s /usr/lib/x86_64-linux-gnu/libclang-16.so.16.0.0 /usr/lib/x86_64-linux-gnu/libclang-16.so.1 - uses: actions/checkout@v3 diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/cvise-2.6.0+git.20221018.7c1f0b4/.github/workflows/build.yml new/cvise-2.6.0+git.20221121.ff14486/.github/workflows/build.yml --- old/cvise-2.6.0+git.20221018.7c1f0b4/.github/workflows/build.yml 2022-10-18 09:42:24.000000000 +0200 +++ new/cvise-2.6.0+git.20221121.ff14486/.github/workflows/build.yml 2022-11-21 12:00:03.000000000 +0100 @@ -1,4 +1,4 @@ -name: Build +name: Build openSUSE on: push: @@ -37,15 +37,17 @@ steps: - run: zypper -n install - binutils clang${{ matrix.llvm }}-devel cmake flex gcc-c++ llvm${{ matrix.llvm }}-devel python3-Pebble python3-pytest unifdef python3-psutil curl git python3-chardet + binutils clang${{ matrix.llvm }}-devel cmake flex gcc-c++ llvm${{ matrix.llvm }}-devel + python3-Pebble python3-pytest unifdef python3-psutil curl git python3-chardet findutils python3-flake8 python3-flake8-builtins python3-flake8-bugbear python3-flake8-import-order python3-flake8-quotes + python3-pip - run: zypper -n install gcc11-c++ if: matrix.docker == 'opensuse/leap' - - run: zypper -n install python3-pip python3-flake8-comprehensions python3 sqlite-devel + - run: zypper -n install python3-flake8-comprehensions sqlite-devel python3 if: matrix.docker == 'opensuse/tumbleweed' - run: pip install pytest-cov if: matrix.docker == 'opensuse/tumbleweed' @@ -59,6 +61,8 @@ make -j`nproc` VERBOSE=1 - name: flake8 run: flake8 + - run: pip install pyupgrade + - run: find . -name '*.py' | xargs pyupgrade --py36-plus - name: test run: pytest working-directory: objdir diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/cvise-2.6.0+git.20221018.7c1f0b4/README.md new/cvise-2.6.0+git.20221121.ff14486/README.md --- old/cvise-2.6.0+git.20221018.7c1f0b4/README.md 2022-10-18 09:42:24.000000000 +0200 +++ new/cvise-2.6.0+git.20221121.ff14486/README.md 2022-11-21 12:00:03.000000000 +0100 @@ -1,7 +1,7 @@ # C-Vise -[![OBS master](https://build.opensuse.org/assets/favicon-ac48595b97f38c2425d7ea77739a63d771fcda9f73cc8c474b66461c0836fc2a.ico)](https://build.opensuse.org/package/show/home:marxin:cvise-github/cvise) -[![GitHub Actions](https://github.com/marxin/cvise/workflows/Build/badge.svg)](https://github.com/marxin/cvise/actions) +[![Build](https://github.com/marxin/cvise/actions/workflows/build.yml/badge.svg)](https://github.com/marxin/cvise/actions/workflows/build.yml) +[![Build LLVM nightly](https://github.com/marxin/cvise/actions/workflows/build-llvm-nightly.yml/badge.svg)](https://github.com/marxin/cvise/actions/workflows/build-llvm-nightly.yml) [![Total alerts](https://img.shields.io/lgtm/alerts/g/marxin/cvise.svg?logo=lgtm&logoWidth=18)](https://lgtm.com/projects/g/marxin/cvise/alerts/) [![Language grade: Python](https://img.shields.io/lgtm/grade/python/g/marxin/cvise.svg?logo=lgtm&logoWidth=18)](https://lgtm.com/projects/g/marxin/cvise/context:python) [![Language grade: C/C++](https://img.shields.io/lgtm/grade/cpp/g/marxin/cvise.svg?logo=lgtm&logoWidth=18)](https://lgtm.com/projects/g/marxin/cvise/context:cpp) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/cvise-2.6.0+git.20221018.7c1f0b4/clang_delta/CommonRenameClassRewriteVisitor.h new/cvise-2.6.0+git.20221121.ff14486/clang_delta/CommonRenameClassRewriteVisitor.h --- old/cvise-2.6.0+git.20221018.7c1f0b4/clang_delta/CommonRenameClassRewriteVisitor.h 2022-10-18 09:42:24.000000000 +0200 +++ new/cvise-2.6.0+git.20221121.ff14486/clang_delta/CommonRenameClassRewriteVisitor.h 2022-11-21 12:00:03.000000000 +0100 @@ -420,8 +420,13 @@ return getDerived().TraverseStmt(ArgLoc.getSourceExpression()); case TemplateArgument::Pack: - return getDerived().TraverseTemplateArguments(Arg.pack_begin(), - Arg.pack_size()); + return getDerived().TraverseTemplateArguments( +#if LLVM_VERSION_MAJOR >= 16 + Arg.pack_elements() +#else + Arg.pack_begin(), Arg.pack_size() +#endif + ); } return true; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/cvise-2.6.0+git.20221018.7c1f0b4/clang_delta/RemoveNestedFunction.cpp new/cvise-2.6.0+git.20221121.ff14486/clang_delta/RemoveNestedFunction.cpp --- old/cvise-2.6.0+git.20221018.7c1f0b4/clang_delta/RemoveNestedFunction.cpp 2022-10-18 09:42:24.000000000 +0200 +++ new/cvise-2.6.0+git.20221121.ff14486/clang_delta/RemoveNestedFunction.cpp 2022-11-21 12:00:03.000000000 +0100 @@ -183,21 +183,21 @@ std::string &VarStr, const TemplateSpecializationType *TST) { - unsigned NumArgs = TST->getNumArgs(); + unsigned NumArgs = TST->template_arguments().size(); if (NumArgs == 0) { return; } std::string ArgStr; llvm::raw_string_ostream Stream(ArgStr); - TST->getArg(0).print(getPrintingPolicy(), Stream + TST->template_arguments()[0].print(getPrintingPolicy(), Stream #if LLVM_VERSION_MAJOR >= 13 , false #endif ); for (unsigned I = 1; I < NumArgs; ++I) { - const TemplateArgument &Arg = TST->getArg(I); + const TemplateArgument &Arg = TST->template_arguments()[I]; Stream << ", "; Arg.print(getPrintingPolicy(), Stream #if LLVM_VERSION_MAJOR >= 13 diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/cvise-2.6.0+git.20221018.7c1f0b4/clang_delta/Transformation.cpp new/cvise-2.6.0+git.20221121.ff14486/clang_delta/Transformation.cpp --- old/cvise-2.6.0+git.20221018.7c1f0b4/clang_delta/Transformation.cpp 2022-10-18 09:42:24.000000000 +0200 +++ new/cvise-2.6.0+git.20221121.ff14486/clang_delta/Transformation.cpp 2022-11-21 12:00:03.000000000 +0100 @@ -1043,8 +1043,8 @@ const TemplateArgument *Args = NULL; if (const TemplateSpecializationType *TST = Ty->getAs<TemplateSpecializationType>()) { - NumArgs = TST->getNumArgs(); - Args = TST->getArgs(); + NumArgs = TST->template_arguments().size(); + Args = TST->template_arguments().data(); } return getTypedefString(IdInfo->getName(), BaseDef, Args, NumArgs, Str, Typename); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/cvise-2.6.0+git.20221018.7c1f0b4/clang_delta/tests/test_clang_delta.py new/cvise-2.6.0+git.20221121.ff14486/clang_delta/tests/test_clang_delta.py --- old/cvise-2.6.0+git.20221018.7c1f0b4/clang_delta/tests/test_clang_delta.py 2022-10-18 09:42:24.000000000 +0200 +++ new/cvise-2.6.0+git.20221121.ff14486/clang_delta/tests/test_clang_delta.py 2022-11-21 12:00:03.000000000 +0100 @@ -9,7 +9,7 @@ def check_clang_delta(cls, testcase, arguments, output_file=None): current = os.path.dirname(__file__) binary = os.path.join(current, '../clang_delta') - cmd = '%s %s %s' % (binary, os.path.join(current, testcase), arguments) + cmd = f'{binary} {os.path.join(current, testcase)} {arguments}' output = subprocess.check_output(cmd, shell=True, encoding='utf8') if not output_file: output_file = os.path.splitext(testcase)[0] + '.output' @@ -21,7 +21,7 @@ def check_query_instances(cls, testcase, arguments, expected): current = os.path.dirname(__file__) binary = os.path.join(current, '../clang_delta') - cmd = '%s %s %s' % (binary, os.path.join(current, testcase), arguments) + cmd = f'{binary} {os.path.join(current, testcase)} {arguments}' output = subprocess.check_output(cmd, shell=True, encoding='utf8') assert output.strip() == expected @@ -29,7 +29,7 @@ def check_error_message(cls, testcase, arguments, error_message): current = os.path.dirname(__file__) binary = os.path.join(current, '../clang_delta') - cmd = '%s %s %s' % (binary, os.path.join(current, testcase), arguments) + cmd = f'{binary} {os.path.join(current, testcase)} {arguments}' proc = subprocess.run(cmd, shell=True, encoding='utf8', stdout=subprocess.PIPE) assert proc.returncode == 255 assert proc.stdout.strip() == error_message @@ -545,8 +545,8 @@ def test_piggypacking(self): current = os.path.dirname(__file__) binary = os.path.join(current, '../clang_delta') - cmd = '%s %s %s' % (binary, os.path.join(current, 'remove-unused-function/macro2.cc'), - '--transformation=remove-unused-function --counter=111 --to-counter=222 --warn-on-counter-out-of-bounds --report-instances-count') + args = '--transformation=remove-unused-function --counter=111 --to-counter=222 --warn-on-counter-out-of-bounds --report-instances-count' + cmd = '{} {} {}'.format(binary, os.path.join(current, 'remove-unused-function/macro2.cc'), args) run = subprocess.run(cmd, shell=True, encoding='utf8', stderr=subprocess.PIPE, stdout=subprocess.PIPE) assert 'Available transformation instances: 1' in run.stderr assert 'Warning: number of transformation instances exceeded' in run.stderr diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/cvise-2.6.0+git.20221018.7c1f0b4/cvise/cvise.py new/cvise-2.6.0+git.20221121.ff14486/cvise/cvise.py --- old/cvise-2.6.0+git.20221018.7c1f0b4/cvise/cvise.py 2022-10-18 09:42:24.000000000 +0200 +++ new/cvise-2.6.0+git.20221121.ff14486/cvise/cvise.py 2022-11-21 12:00:03.000000000 +0100 @@ -95,7 +95,7 @@ for category in ['first', 'main', 'last']: if category not in pass_group_dict: - raise CViseError('Missing category {}'.format(category)) + raise CViseError(f'Missing category {category}') pass_group[category] = [] @@ -104,7 +104,7 @@ continue if 'pass' not in pass_dict: - raise CViseError('Invalid pass in category {}'.format(category)) + raise CViseError(f'Invalid pass in category {category}') try: pass_class = cls.pass_name_mapping[pass_dict['pass']] @@ -131,7 +131,7 @@ if not self.skip_interestingness_test_check: self.test_manager.check_sanity(True) - logging.info('===< {} >==='.format(os.getpid())) + logging.info(f'===< {os.getpid()} >===') logging.info('running {} interestingness test{} in parallel'.format(self.test_manager.parallel_tests, '' if self.test_manager.parallel_tests == 1 else 's')) @@ -156,12 +156,12 @@ for category in pass_group: for p in pass_group[category]: if not p.check_prerequisites(): - logging.error('Prereqs not found for pass {}'.format(p)) + logging.error(f'Prereqs not found for pass {p}') def _run_additional_passes(self, passes): for p in passes: if not p.check_prerequisites(): - logging.error('Skipping {}'.format(p)) + logging.error(f'Skipping {p}') else: self.test_manager.run_pass(p) @@ -171,11 +171,11 @@ for p in passes: if not p.check_prerequisites(): - logging.error('Skipping pass {}'.format(p)) + logging.error(f'Skipping pass {p}') else: self.test_manager.run_pass(p) - logging.info('Termination check: size was {}; now {}'.format(total_file_size, self.test_manager.total_file_size)) + logging.info(f'Termination check: size was {total_file_size}; now {self.test_manager.total_file_size}') if self.test_manager.total_file_size >= total_file_size: break diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/cvise-2.6.0+git.20221018.7c1f0b4/cvise/passes/abstract.py new/cvise-2.6.0+git.20221121.ff14486/cvise/passes/abstract.py --- old/cvise-2.6.0+git.20221018.7c1f0b4/cvise/passes/abstract.py 2022-10-18 09:42:24.000000000 +0200 +++ new/cvise-2.6.0+git.20221121.ff14486/cvise/passes/abstract.py 2022-11-21 12:00:03.000000000 +0100 @@ -47,10 +47,10 @@ self.chunk = int(self.chunk / 2) if self.chunk < 1: return None - logging.debug('granularity reduced to {}'.format(self.chunk)) + logging.debug(f'granularity reduced to {self.chunk}') self.index = 0 else: - logging.debug('***ADVANCE*** from {} to {} with chunk {}'.format(original_index, self.index, self.chunk)) + logging.debug(f'***ADVANCE*** from {original_index} to {self.index} with chunk {self.chunk}') return self def advance_on_success(self, instances): @@ -75,9 +75,9 @@ def __repr__(self): if self.arg is not None: - return '{}::{}'.format(type(self).__name__, self.arg) + return f'{type(self).__name__}::{self.arg}' else: - return '{}'.format(type(self).__name__) + return f'{type(self).__name__}' def check_external_program(self, name): program = self.external_programs[name] @@ -85,23 +85,23 @@ return False result = shutil.which(program) is not None if not result: - logging.error('cannot find external program {}'.format(name)) + logging.error(f'cannot find external program {name}') return result def check_prerequisites(self): - raise NotImplementedError("Class {} has not implemented 'check_prerequisites'!".format(type(self).__name__)) + raise NotImplementedError(f"Class {type(self).__name__} has not implemented 'check_prerequisites'!") def new(self, test_case, check_sanity): - raise NotImplementedError("Class {} has not implemented 'new'!".format(type(self).__name__)) + raise NotImplementedError(f"Class {type(self).__name__} has not implemented 'new'!") def advance(self, test_case, state): - raise NotImplementedError("Class {} has not implemented 'advance'!".format(type(self).__name__)) + raise NotImplementedError(f"Class {type(self).__name__} has not implemented 'advance'!") def advance_on_success(self, test_case, state): - raise NotImplementedError("Class {} has not implemented 'advance_on_success'!".format(type(self).__name__)) + raise NotImplementedError(f"Class {type(self).__name__} has not implemented 'advance_on_success'!") def transform(self, test_case, state, process_event_notifier): - raise NotImplementedError("Class {} has not implemented 'transform'!".format(type(self).__name__)) + raise NotImplementedError(f"Class {type(self).__name__} has not implemented 'transform'!") @unique diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/cvise-2.6.0+git.20221018.7c1f0b4/cvise/passes/balanced.py new/cvise-2.6.0+git.20221121.ff14486/cvise/passes/balanced.py --- old/cvise-2.6.0+git.20221018.7c1f0b4/cvise/passes/balanced.py 2022-10-18 09:42:24.000000000 +0200 +++ new/cvise-2.6.0+git.20221121.ff14486/cvise/passes/balanced.py 2022-11-21 12:00:03.000000000 +0100 @@ -8,7 +8,7 @@ return True def __get_next_match(self, test_case, pos): - with open(test_case, 'r') as in_file: + with open(test_case) as in_file: prog = in_file.read() config = self.__get_config() @@ -92,7 +92,7 @@ return config def transform(self, test_case, state, process_event_notifier): - with open(test_case, 'r') as in_file: + with open(test_case) as in_file: prog = in_file.read() prog2 = prog diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/cvise-2.6.0+git.20221018.7c1f0b4/cvise/passes/blank.py new/cvise-2.6.0+git.20221121.ff14486/cvise/passes/blank.py --- old/cvise-2.6.0+git.20221018.7c1f0b4/cvise/passes/blank.py 2022-10-18 09:42:24.000000000 +0200 +++ new/cvise-2.6.0+git.20221121.ff14486/cvise/passes/blank.py 2022-11-21 12:00:03.000000000 +0100 @@ -23,7 +23,7 @@ def __transform(test_case, pattern): tmp = os.path.dirname(test_case) with tempfile.NamedTemporaryFile(mode='w+', delete=False, dir=tmp) as tmp_file: - with open(test_case, 'r') as in_file: + with open(test_case) as in_file: matched = False for line in in_file: diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/cvise-2.6.0+git.20221018.7c1f0b4/cvise/passes/clang.py new/cvise-2.6.0+git.20221121.ff14486/cvise/passes/clang.py --- old/cvise-2.6.0+git.20221018.7c1f0b4/cvise/passes/clang.py 2022-10-18 09:42:24.000000000 +0200 +++ new/cvise-2.6.0+git.20221121.ff14486/cvise/passes/clang.py 2022-11-21 12:00:03.000000000 +0100 @@ -22,9 +22,9 @@ def transform(self, test_case, state, process_event_notifier): tmp = os.path.dirname(test_case) with tempfile.NamedTemporaryFile(mode='w', delete=False, dir=tmp) as tmp_file: - args = [self.external_programs['clang_delta'], '--transformation={}'.format(self.arg), '--counter={}'.format(state)] + args = [self.external_programs['clang_delta'], f'--transformation={self.arg}', f'--counter={state}'] if self.user_clang_delta_std: - args.append('--std={}'.format(self.user_clang_delta_std)) + args.append(f'--std={self.user_clang_delta_std}') cmd = args + [test_case] logging.debug(' '.join(cmd)) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/cvise-2.6.0+git.20221018.7c1f0b4/cvise/passes/clangbinarysearch.py new/cvise-2.6.0+git.20221121.ff14486/cvise/passes/clangbinarysearch.py --- old/cvise-2.6.0+git.20221018.7c1f0b4/cvise/passes/clangbinarysearch.py 2022-10-18 09:42:24.000000000 +0200 +++ new/cvise-2.6.0+git.20221121.ff14486/cvise/passes/clangbinarysearch.py 2022-11-21 12:00:03.000000000 +0100 @@ -16,7 +16,7 @@ def detect_best_standard(self, test_case): best = None best_count = -1 - for std in ('c++98', 'c++11', 'c++14', 'c++17', 'c++20'): + for std in ('c++98', 'c++11', 'c++14', 'c++17', 'c++20', 'c++2b'): self.clang_delta_std = std start = time.monotonic() instances = self.count_instances(test_case) @@ -27,6 +27,8 @@ best_count = instances logging.debug('available transformation opportunities for %s: %d, took: %.2f s' % (std, instances, took)) logging.info('using C++ standard: %s with %d transformation opportunities' % (best, best_count)) + # Use the best standard option + self.clang_delta_std = best def new(self, test_case, _=None): if not self.user_clang_delta_std: @@ -46,9 +48,9 @@ return state def count_instances(self, test_case): - args = [self.external_programs['clang_delta'], '--query-instances={}'.format(self.arg)] + args = [self.external_programs['clang_delta'], f'--query-instances={self.arg}'] if self.clang_delta_std: - args.append('--std={}'.format(self.clang_delta_std)) + args.append(f'--std={self.clang_delta_std}') if self.clang_delta_preserve_routine: args.append(f'--preserve-routine="{self.clang_delta_preserve_routine}"') cmd = args + [test_case] @@ -79,14 +81,14 @@ pass def transform(self, test_case, state, process_event_notifier): - logging.debug('TRANSFORM: index = {}, chunk = {}, instances = {}'.format(state.index, state.chunk, state.instances)) + logging.debug(f'TRANSFORM: index = {state.index}, chunk = {state.chunk}, instances = {state.instances}') tmp = os.path.dirname(test_case) with tempfile.NamedTemporaryFile(mode='w', delete=False, dir=tmp) as tmp_file: - args = ['--transformation={}'.format(self.arg), '--counter={}'.format(state.index + 1), '--to-counter={}'.format(state.end()), + args = [f'--transformation={self.arg}', f'--counter={state.index + 1}', f'--to-counter={state.end()}', '--warn-on-counter-out-of-bounds', '--report-instances-count'] if self.clang_delta_std: - args.append('--std={}'.format(self.clang_delta_std)) + args.append(f'--std={self.clang_delta_std}') if self.clang_delta_preserve_routine: args.append(f'--preserve-routine="{self.clang_delta_preserve_routine}"') cmd = [self.external_programs['clang_delta']] + args + [test_case] diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/cvise-2.6.0+git.20221018.7c1f0b4/cvise/passes/comments.py new/cvise-2.6.0+git.20221121.ff14486/cvise/passes/comments.py --- old/cvise-2.6.0+git.20221018.7c1f0b4/cvise/passes/comments.py 2022-10-18 09:42:24.000000000 +0200 +++ new/cvise-2.6.0+git.20221121.ff14486/cvise/passes/comments.py 2022-11-21 12:00:03.000000000 +0100 @@ -17,7 +17,7 @@ return state def transform(self, test_case, state, process_event_notifier): - with open(test_case, 'r') as in_file: + with open(test_case) as in_file: prog = in_file.read() prog2 = prog diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/cvise-2.6.0+git.20221018.7c1f0b4/cvise/passes/ifs.py new/cvise-2.6.0+git.20221121.ff14486/cvise/passes/ifs.py --- old/cvise-2.6.0+git.20221018.7c1f0b4/cvise/passes/ifs.py 2022-10-18 09:42:24.000000000 +0200 +++ new/cvise-2.6.0+git.20221121.ff14486/cvise/passes/ifs.py 2022-11-21 12:00:03.000000000 +0100 @@ -18,7 +18,7 @@ def __count_instances(self, test_case): count = 0 in_multiline = False - with open(test_case, 'r') as in_file: + with open(test_case) as in_file: for line in in_file.readlines(): if in_multiline: if self.__macro_continues(line): @@ -54,7 +54,7 @@ def transform(self, test_case, state, process_event_notifier): tmp = os.path.dirname(test_case) with tempfile.NamedTemporaryFile(mode='w+', delete=False, dir=tmp) as tmp_file: - with open(test_case, 'r') as in_file: + with open(test_case) as in_file: i = 0 in_multiline = False for line in in_file.readlines(): @@ -68,7 +68,7 @@ if state.index <= i and i < state.end(): if self.__macro_continues(line): in_multiline = True - line = '#if {0}\n'.format(state.value) + line = f'#if {state.value}\n' i += 1 tmp_file.write(line) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/cvise-2.6.0+git.20221018.7c1f0b4/cvise/passes/includeincludes.py new/cvise-2.6.0+git.20221121.ff14486/cvise/passes/includeincludes.py --- old/cvise-2.6.0+git.20221018.7c1f0b4/cvise/passes/includeincludes.py 2022-10-18 09:42:24.000000000 +0200 +++ new/cvise-2.6.0+git.20221121.ff14486/cvise/passes/includeincludes.py 2022-11-21 12:00:03.000000000 +0100 @@ -20,7 +20,7 @@ return state def transform(self, test_case, state, process_event_notifier): - with open(test_case, 'r') as in_file: + with open(test_case) as in_file: tmp = os.path.dirname(test_case) with tempfile.NamedTemporaryFile(mode='w+', delete=False, dir=tmp) as tmp_file: includes = 0 @@ -34,7 +34,7 @@ if includes == state: try: - with open(include_match.group(1), 'r') as inc_file: + with open(include_match.group(1)) as inc_file: matched = True tmp_file.write(inc_file.read()) # Go to next include diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/cvise-2.6.0+git.20221018.7c1f0b4/cvise/passes/includes.py new/cvise-2.6.0+git.20221121.ff14486/cvise/passes/includes.py --- old/cvise-2.6.0+git.20221018.7c1f0b4/cvise/passes/includes.py 2022-10-18 09:42:24.000000000 +0200 +++ new/cvise-2.6.0+git.20221121.ff14486/cvise/passes/includes.py 2022-11-21 12:00:03.000000000 +0100 @@ -22,7 +22,7 @@ def transform(self, test_case, state, process_event_notifier): tmp = os.path.dirname(test_case) with tempfile.NamedTemporaryFile(mode='w+', delete=False, dir=tmp) as tmp_file: - with open(test_case, 'r') as in_file: + with open(test_case) as in_file: includes = 0 matched = False diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/cvise-2.6.0+git.20221018.7c1f0b4/cvise/passes/indent.py new/cvise-2.6.0+git.20221121.ff14486/cvise/passes/indent.py --- old/cvise-2.6.0+git.20221018.7c1f0b4/cvise/passes/indent.py 2022-10-18 09:42:24.000000000 +0200 +++ new/cvise-2.6.0+git.20221121.ff14486/cvise/passes/indent.py 2022-11-21 12:00:03.000000000 +0100 @@ -16,7 +16,7 @@ return state + 1 def transform(self, test_case, state, process_event_notifier): - with open(test_case, 'r') as in_file: + with open(test_case) as in_file: old = in_file.read() if state != 0: @@ -35,7 +35,7 @@ if returncode != 0: return (PassResult.ERROR, state) - with open(test_case, 'r') as in_file: + with open(test_case) as in_file: new = in_file.read() if old == new: diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/cvise-2.6.0+git.20221018.7c1f0b4/cvise/passes/ints.py new/cvise-2.6.0+git.20221121.ff14486/cvise/passes/ints.py --- old/cvise-2.6.0+git.20221018.7c1f0b4/cvise/passes/ints.py 2022-10-18 09:42:24.000000000 +0200 +++ new/cvise-2.6.0+git.20221121.ff14486/cvise/passes/ints.py 2022-11-21 12:00:03.000000000 +0100 @@ -47,7 +47,7 @@ def new(self, test_case, _=None): config = self.__get_config() - with open(test_case, 'r') as in_file: + with open(test_case) as in_file: prog = in_file.read() regex = re.compile(config['search'], flags=re.DOTALL) modifications = list(reversed([(m.span(), config['replace_fn'](m)) for m in regex.finditer(prog)])) @@ -66,7 +66,7 @@ return self.new(test_case) def transform(self, test_case, state, process_event_notifier): - with open(test_case, 'r') as in_file: + with open(test_case) as in_file: data = in_file.read() index = state['index'] ((start, end), replacement) = state['modifications'][index] diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/cvise-2.6.0+git.20221018.7c1f0b4/cvise/passes/line_markers.py new/cvise-2.6.0+git.20221121.ff14486/cvise/passes/line_markers.py --- old/cvise-2.6.0+git.20221018.7c1f0b4/cvise/passes/line_markers.py 2022-10-18 09:42:24.000000000 +0200 +++ new/cvise-2.6.0+git.20221121.ff14486/cvise/passes/line_markers.py 2022-11-21 12:00:03.000000000 +0100 @@ -14,7 +14,7 @@ def __count_instances(self, test_case): count = 0 - with open(test_case, 'r') as in_file: + with open(test_case) as in_file: for line in in_file.readlines(): if self.line_regex.search(line): count += 1 @@ -32,7 +32,7 @@ def transform(self, test_case, state, process_event_notifier): tmp = os.path.dirname(test_case) with tempfile.NamedTemporaryFile(mode='w+', delete=False, dir=tmp) as tmp_file: - with open(test_case, 'r') as in_file: + with open(test_case) as in_file: i = 0 for line in in_file.readlines(): if self.line_regex.search(line): diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/cvise-2.6.0+git.20221018.7c1f0b4/cvise/passes/lines.py new/cvise-2.6.0+git.20221121.ff14486/cvise/passes/lines.py --- old/cvise-2.6.0+git.20221018.7c1f0b4/cvise/passes/lines.py 2022-10-18 09:42:24.000000000 +0200 +++ new/cvise-2.6.0+git.20221121.ff14486/cvise/passes/lines.py 2022-11-21 12:00:03.000000000 +0100 @@ -16,7 +16,7 @@ tmp = os.path.dirname(test_case) with tempfile.NamedTemporaryFile(mode='w+', dir=tmp) as backup, tempfile.NamedTemporaryFile(mode='w+', dir=tmp) as tmp_file: - with open(test_case, 'r') as in_file: + with open(test_case) as in_file: try: cmd = [self.external_programs['topformflat'], self.arg] proc = subprocess.run(cmd, stdin=in_file, stdout=subprocess.PIPE, stderr=subprocess.PIPE, universal_newlines=True) @@ -43,7 +43,7 @@ shutil.copy(tmp_file.name, test_case) def __count_instances(self, test_case): - with open(test_case, 'r') as in_file: + with open(test_case) as in_file: lines = in_file.readlines() return len(lines) @@ -65,7 +65,7 @@ return state.advance_on_success(self.__count_instances(test_case)) def transform(self, test_case, state, process_event_notifier): - with open(test_case, 'r') as in_file: + with open(test_case) as in_file: data = in_file.readlines() old_len = len(data) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/cvise-2.6.0+git.20221018.7c1f0b4/cvise/passes/peep.py new/cvise-2.6.0+git.20221121.ff14486/cvise/passes/peep.py --- old/cvise-2.6.0+git.20221018.7c1f0b4/cvise/passes/peep.py 2022-10-18 09:42:24.000000000 +0200 +++ new/cvise-2.6.0+git.20221121.ff14486/cvise/passes/peep.py 2022-11-21 12:00:03.000000000 +0100 @@ -146,7 +146,7 @@ new_state['regex'] = 0 new_state['pos'] += 1 - with open(test_case, 'r') as in_file: + with open(test_case) as in_file: length = len(in_file.read()) if new_state['pos'] >= length: return None @@ -157,7 +157,7 @@ return state def transform(self, test_case, state, process_event_notifier): - with open(test_case, 'r') as in_file: + with open(test_case) as in_file: prog = in_file.read() prog2 = prog diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/cvise-2.6.0+git.20221018.7c1f0b4/cvise/passes/special.py new/cvise-2.6.0+git.20221121.ff14486/cvise/passes/special.py --- old/cvise-2.6.0+git.20221018.7c1f0b4/cvise/passes/special.py 2022-10-18 09:42:24.000000000 +0200 +++ new/cvise-2.6.0+git.20221121.ff14486/cvise/passes/special.py 2022-11-21 12:00:03.000000000 +0100 @@ -34,7 +34,7 @@ return config def __get_next_match(self, test_case, pos): - with open(test_case, 'r') as in_file: + with open(test_case) as in_file: prog = in_file.read() config = self.__get_config() @@ -45,7 +45,7 @@ def new(self, test_case, _=None): config = self.__get_config() - with open(test_case, 'r') as in_file: + with open(test_case) as in_file: prog = in_file.read() regex = re.compile(config['search'], flags=re.DOTALL) modifications = list(reversed([(m.span(), config['replace_fn'](m)) for m in regex.finditer(prog)])) @@ -64,7 +64,7 @@ return self.new(test_case) def transform(self, test_case, state, process_event_notifier): - with open(test_case, 'r') as in_file: + with open(test_case) as in_file: data = in_file.read() index = state['index'] ((start, end), replacement) = state['modifications'][index] diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/cvise-2.6.0+git.20221018.7c1f0b4/cvise/passes/ternary.py new/cvise-2.6.0+git.20221121.ff14486/cvise/passes/ternary.py --- old/cvise-2.6.0+git.20221018.7c1f0b4/cvise/passes/ternary.py 2022-10-18 09:42:24.000000000 +0200 +++ new/cvise-2.6.0+git.20221121.ff14486/cvise/passes/ternary.py 2022-11-21 12:00:03.000000000 +0100 @@ -24,7 +24,7 @@ return True def __get_next_match(self, test_case, pos): - with open(test_case, 'r') as in_file: + with open(test_case) as in_file: prog = in_file.read() m = nestedmatcher.search(self.parts, prog, pos=pos) @@ -41,7 +41,7 @@ return self.__get_next_match(test_case, pos=state['all'][0]) def transform(self, test_case, state, process_event_notifier): - with open(test_case, 'r') as in_file: + with open(test_case) as in_file: prog = in_file.read() prog2 = prog diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/cvise-2.6.0+git.20221018.7c1f0b4/cvise/passes/unifdef.py new/cvise-2.6.0+git.20221121.ff14486/cvise/passes/unifdef.py --- old/cvise-2.6.0+git.20221018.7c1f0b4/cvise/passes/unifdef.py 2022-10-18 09:42:24.000000000 +0200 +++ new/cvise-2.6.0+git.20221121.ff14486/cvise/passes/unifdef.py 2022-11-21 12:00:03.000000000 +0100 @@ -46,7 +46,7 @@ def_ = deflist[n_index] - cmd = [self.external_programs['unifdef'], '-B', '-x', '2', '{}{}'.format(du, def_), '-o', tmp_file.name, test_case] + cmd = [self.external_programs['unifdef'], '-B', '-x', '2', f'{du}{def_}', '-o', tmp_file.name, test_case] stdout, stderr, returncode = process_event_notifier.run_process(cmd) if returncode != 0: return (PassResult.ERROR, state) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/cvise-2.6.0+git.20221018.7c1f0b4/cvise/utils/error.py new/cvise-2.6.0+git.20221121.ff14486/cvise/utils/error.py --- old/cvise-2.6.0+git.20221018.7c1f0b4/cvise/utils/error.py 2022-10-18 09:42:24.000000000 +0200 +++ new/cvise-2.6.0+git.20221121.ff14486/cvise/utils/error.py 2022-11-21 12:00:03.000000000 +0100 @@ -19,7 +19,7 @@ self.arg = arg def __str__(self): - return "The argument '{}' is not valid for pass '{}'!".format(self.arg, self.pass_.__name__) + return f"The argument '{self.arg}' is not valid for pass '{self.pass_.__name__}'!" class InvalidFileError(CViseError): @@ -38,12 +38,12 @@ return 'accessed' def __str__(self): - return "The specified file '{}' cannot be {}!".format(self.path, self._get_error_name()) + return f"The specified file '{self.path}' cannot be {self._get_error_name()}!" class InvalidTestCaseError(InvalidFileError): def __str__(self): - return "The specified test case '{}' cannot be {}!".format(self.path, self._get_error_name()) + return f"The specified test case '{self.path}' cannot be {self._get_error_name()}!" class FolderInPathTestCaseError(CViseError): @@ -59,7 +59,7 @@ super().__init__(path, None) def __str__(self): - return "The specified interestingness test '{}' cannot be executed!".format(self.path) + return f"The specified interestingness test '{self.path}' cannot be executed!" class ZeroSizeError(CViseError): diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/cvise-2.6.0+git.20221018.7c1f0b4/cvise/utils/nestedmatcher.py new/cvise-2.6.0+git.20221121.ff14486/cvise/utils/nestedmatcher.py --- old/cvise-2.6.0+git.20221018.7c1f0b4/cvise/utils/nestedmatcher.py 2022-10-18 09:42:24.000000000 +0200 +++ new/cvise-2.6.0+git.20221121.ff14486/cvise/utils/nestedmatcher.py 2022-11-21 12:00:03.000000000 +0100 @@ -19,7 +19,7 @@ self.expr = expr def __repr__(self): - return '(expr={})'.format(self.expr) + return f'(expr={self.expr})' class BalancedPattern(Pattern): @@ -28,7 +28,7 @@ self.end = expr.value[1] def __repr__(self): - return '(start={}, end={})'.format(self.start, self.end) + return f'(start={self.start}, end={self.end})' class OrPattern(Pattern): @@ -37,7 +37,7 @@ self.right = right def __repr__(self): - return '(left={}, right={})'.format(self.left, self.right) + return f'(left={self.left}, right={self.right})' def __get_regex_match(pattern, string, pos=0, search=False): diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/cvise-2.6.0+git.20221018.7c1f0b4/cvise/utils/testing.py new/cvise-2.6.0+git.20221121.ff14486/cvise/utils/testing.py --- old/cvise-2.6.0+git.20221018.7c1f0b4/cvise/utils/testing.py 2022-10-18 09:42:24.000000000 +0200 +++ new/cvise-2.6.0+git.20221121.ff14486/cvise/utils/testing.py 2022-11-21 12:00:03.000000000 +0100 @@ -219,7 +219,7 @@ def backup_test_cases(self): for f in self.test_cases: - orig_file = '{}.orig'.format(f) + orig_file = f'{f}.orig' if not os.path.exists(orig_file): # Copy file and preserve attributes @@ -254,7 +254,7 @@ def report_pass_bug(self, test_env, problem): if not self.die_on_pass_bug: - logging.warning('{} has encountered a non fatal bug: {}'.format(self.current_pass, problem)) + logging.warning(f'{self.current_pass} has encountered a non fatal bug: {problem}') crash_dir = self.get_extra_dir('cvise_bug_', self.MAX_CRASH_DIRS) @@ -265,7 +265,7 @@ test_env.dump(crash_dir) if not self.die_on_pass_bug: - logging.debug('Please consider tarring up {} and creating an issue at https://github.com/marxin/cvise/issues and we will try to fix the bug.'.format(crash_dir)) + logging.debug(f'Please consider tarring up {crash_dir} and creating an issue at https://github.com/marxin/cvise/issues and we will try to fix the bug.') with open(os.path.join(crash_dir, 'PASS_BUG_INFO.TXT'), mode='w') as info_file: info_file.write('Package: %s\n' % CVise.Info.PACKAGE_STRING) @@ -294,7 +294,7 @@ folder = tempfile.mkdtemp(prefix=f'{self.TEMP_PREFIX}sanity-') test_env = TestEnvironment(None, 0, self.test_script, folder, None, self.test_cases, None) - logging.debug('sanity check tmpdir = {}'.format(test_env.folder)) + logging.debug(f'sanity check tmpdir = {test_env.folder}') returncode = test_env.run_test(verbose) if returncode == 0: @@ -349,7 +349,7 @@ if extra_dir is not None: os.mkdir(extra_dir) shutil.move(test_case_path, extra_dir) - logging.info('Created extra directory {} for you to look at later'.format(extra_dir)) + logging.info(f'Created extra directory {extra_dir} for you to look at later') def process_done_futures(self): quit_loop = False @@ -377,7 +377,7 @@ if test_env.success: if (self.max_improvement is not None and test_env.size_improvement > self.max_improvement): - logging.debug('Too large improvement: {} B'.format(test_env.size_improvement)) + logging.debug(f'Too large improvement: {test_env.size_improvement} B') else: # Report bug if transform did not change the file if filecmp.cmp(self.current_test_case, test_env.test_case_path): @@ -476,7 +476,7 @@ self.create_root() pass_key = repr(self.current_pass) - logging.info('===< {} >==='.format(self.current_pass)) + logging.info(f'===< {self.current_pass} >===') if self.total_file_size == 0: raise ZeroSizeError(self.test_cases) @@ -503,7 +503,7 @@ tmp_file.seek(0) tmp_file.truncate(0) tmp_file.write(self.cache[pass_key][test_case_before_pass]) - logging.info('cache hit for {}'.format(test_case)) + logging.info(f'cache hit for {test_case}') continue # create initial state diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/cvise-2.6.0+git.20221018.7c1f0b4/cvise.py new/cvise-2.6.0+git.20221121.ff14486/cvise.py --- old/cvise-2.6.0+git.20221018.7c1f0b4/cvise.py 2022-10-18 09:42:24.000000000 +0200 +++ new/cvise-2.6.0+git.20221121.ff14486/cvise.py 2022-11-21 12:00:03.000000000 +0100 @@ -119,7 +119,7 @@ pass_group_dict = CVise.load_pass_group_file(path) CVise.parse_pass_group_dict(pass_group_dict, set(), None, None, None, None, None, None) except MissingPassGroupsError: - logging.warning('Skipping file {}. Not valid pass group.'.format(path)) + logging.warning(f'Skipping file {path}. Not valid pass group.') else: (name, _) = os.path.splitext(entry) group_names.append(name) @@ -170,7 +170,7 @@ parser.add_argument('--debug', action='store_true', help='Print debug information (alias for --log-level=DEBUG)') parser.add_argument('--log-level', type=str, choices=['INFO', 'DEBUG', 'WARNING', 'ERROR'], default='INFO', help='Define the verbosity of the logged events') parser.add_argument('--log-file', type=str, help='Log events into LOG_FILE instead of stderr. New events are appended to the end of the file') - parser.add_argument('--no-give-up', action='store_true', help="Don't give up on a pass that hasn't made progress for {} iterations".format(testing.TestManager.GIVEUP_CONSTANT)) + parser.add_argument('--no-give-up', action='store_true', help=f"Don't give up on a pass that hasn't made progress for {testing.TestManager.GIVEUP_CONSTANT} iterations") parser.add_argument('--print-diff', action='store_true', help='Show changes made by transformations, for debugging') parser.add_argument('--save-temps', action='store_true', help="Don't delete /tmp/cvise-xxxxxx directories on termination") parser.add_argument('--skip-initial-passes', action='store_true', help='Skip initial passes (useful if input is already partially reduced)') @@ -277,7 +277,7 @@ encoding = chardet.detect(fd.read())['encoding'] if encoding not in ('ascii', 'utf-8'): logging.info(f'Converting {test_case} file ({encoding} encoding) to UTF-8') - data = open(test_case, 'r', encoding=encoding).read() + data = open(test_case, encoding=encoding).read() with open(test_case, 'w') as w: w.write(data) @@ -320,7 +320,7 @@ print() if not args.no_timing: - print('Runtime: {} seconds'.format(round((time_stop - time_start)))) + print(f'Runtime: {round((time_stop - time_start))} seconds') print('Reduced test-cases:\n') for test_case in sorted(test_manager.test_cases): diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/cvise-2.6.0+git.20221018.7c1f0b4/tests/test_cvise.py new/cvise-2.6.0+git.20221121.ff14486/tests/test_cvise.py --- old/cvise-2.6.0+git.20221018.7c1f0b4/tests/test_cvise.py 2022-10-18 09:42:24.000000000 +0200 +++ new/cvise-2.6.0+git.20221121.ff14486/tests/test_cvise.py 2022-11-21 12:00:03.000000000 +0100 @@ -13,7 +13,7 @@ binary = os.path.join(current, '../cvise.py') shutil.copy(os.path.join(current, 'sources', testcase), '.') os.chmod(testcase, 0o644) - cmd = '%s %s %s' % (binary, testcase, arguments) + cmd = f'{binary} {testcase} {arguments}' subprocess.check_output(cmd, shell=True, encoding='utf8') with open(testcase) as f: content = f.read()