Mock Version: 3.0 Mock Version: 3.0 Mock Version: 3.0 ENTER ['do_with_status'](['bash', '--login', '-c', '/usr/bin/rpmbuild -bs --target noarch --nodeps /builddir/build/SPECS/python-pygments.spec'], chrootPath='/var/lib/mock/module-python27-2.7-8050020220619111603-c7643c7d-build-9729-1357/root'env={'TERM': 'vt100', 'SHELL': '/bin/bash', 'HOME': '/builddir', 'HOSTNAME': 'mock', 'PATH': '/usr/bin:/bin:/usr/sbin:/sbin', 'PROMPT_COMMAND': 'printf "\\033]0;\\007"', 'PS1': ' \\s-\\v\\$ ', 'LANG': 'C.UTF-8'}shell=Falselogger=timeout=86400uid=991gid=135user='mockbuild'nspawn_args=[]unshare_net=TrueprintOutput=False) Executing command: ['bash', '--login', '-c', '/usr/bin/rpmbuild -bs --target noarch --nodeps /builddir/build/SPECS/python-pygments.spec'] with env {'TERM': 'vt100', 'SHELL': '/bin/bash', 'HOME': '/builddir', 'HOSTNAME': 'mock', 'PATH': '/usr/bin:/bin:/usr/sbin:/sbin', 'PROMPT_COMMAND': 'printf "\\033]0;\\007"', 'PS1': ' \\s-\\v\\$ ', 'LANG': 'C.UTF-8'} and shell False warning: bogus date in %changelog: Thu Mar 22 2017 Steve Milner - 2.2.0-7 Building target platforms: noarch Building for target noarch Wrote: /builddir/build/SRPMS/python-pygments-2.2.0-22.module+oc8.5.0+83+7490e917.src.rpm Child return code was: 0 ENTER ['do_with_status'](['bash', '--login', '-c', '/usr/bin/rpmbuild -bb --target noarch --nodeps /builddir/build/SPECS/python-pygments.spec'], chrootPath='/var/lib/mock/module-python27-2.7-8050020220619111603-c7643c7d-build-9729-1357/root'env={'TERM': 'vt100', 'SHELL': '/bin/bash', 'HOME': '/builddir', 'HOSTNAME': 'mock', 'PATH': '/usr/bin:/bin:/usr/sbin:/sbin', 'PROMPT_COMMAND': 'printf "\\033]0;\\007"', 'PS1': ' \\s-\\v\\$ ', 'LANG': 'C.UTF-8'}shell=Falselogger=timeout=86400uid=991gid=135user='mockbuild'nspawn_args=[]unshare_net=TrueprintOutput=False) Executing command: ['bash', '--login', '-c', '/usr/bin/rpmbuild -bb --target noarch --nodeps /builddir/build/SPECS/python-pygments.spec'] with env {'TERM': 'vt100', 'SHELL': '/bin/bash', 'HOME': '/builddir', 'HOSTNAME': 'mock', 'PATH': '/usr/bin:/bin:/usr/sbin:/sbin', 'PROMPT_COMMAND': 'printf "\\033]0;\\007"', 'PS1': ' \\s-\\v\\$ ', 'LANG': 'C.UTF-8'} and shell False warning: bogus date in %changelog: Thu Mar 22 2017 Steve Milner - 2.2.0-7 Building target platforms: noarch Building for target noarch Executing(%prep): /bin/sh -e /var/tmp/rpm-tmp.DVYx67 + umask 022 + cd /builddir/build/BUILD + cd /builddir/build/BUILD + rm -rf Pygments-2.2.0 + /usr/bin/gzip -dc /builddir/build/SOURCES/Pygments-2.2.0.tar.gz + /usr/bin/tar -xof - + STATUS=0 + '[' 0 -ne 0 ']' + cd Pygments-2.2.0 + /usr/bin/chmod -Rf a+rX,u+w,g-w,o-w . Patch #0 (import-directive.patch): + echo 'Patch #0 (import-directive.patch):' + /usr/bin/patch --no-backup-if-mismatch -p1 --fuzz=0 patching file pygments/sphinxext.py Patch #1 (CVE-2021-20270-infinite-loop-in-SML-lexer.patch): + echo 'Patch #1 (CVE-2021-20270-infinite-loop-in-SML-lexer.patch):' + /usr/bin/patch --no-backup-if-mismatch -p1 --fuzz=0 patching file pygments/lexers/ml.py Patch #2 (CVE-2021-27291.patch): + echo 'Patch #2 (CVE-2021-27291.patch):' + /usr/bin/patch --no-backup-if-mismatch -p1 --fuzz=0 patching file pygments/lexers/archetype.py patching file pygments/lexers/factor.py patching file pygments/lexers/jvm.py patching file pygments/lexers/matlab.py patching file pygments/lexers/objective.py patching file pygments/lexers/templates.py patching file pygments/lexers/varnish.py + exit 0 Executing(%build): /bin/sh -e /var/tmp/rpm-tmp.EFmmS5 + umask 022 + cd /builddir/build/BUILD + cd Pygments-2.2.0 + /usr/bin/sed -i 's/\r//' LICENSE + CFLAGS='-O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -fexceptions -fstack-protector-strong -grecord-gcc-switches -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -fasynchronous-unwind-tables -fstack-clash-protection' + LDFLAGS='-Wl,-z,relro -Wl,-z,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld' + /usr/bin/python2 setup.py build '--executable=/usr/bin/python2 -s' ERROR: Python 2 is disabled in RHEL8. - For guidance on porting to Python 3, see the Conservative Python3 Porting Guide: http://portingguide.readthedocs.io/ - If you need Python 2 at runtime: - Use the python27 module - If you do not have access to BZ#1533919: - Use the python27 module - If you need to use Python 2 only at RPM build time: - File a bug blocking BZ#1533919: https://bugzilla.redhat.com/show_bug.cgi?id=1533919 - Set the environment variable RHEL_ALLOW_PYTHON2_FOR_BUILD=1 (Note that if you do not file the bug as above, this workaround will break without warning in the future.) - If you need to use Python 2 only for tests: - File a bug blocking BZ#1533919: https://bugzilla.redhat.com/show_bug.cgi?id=1533919 (If your test tool does not have a Bugzilla component, feel free to use `python2`.) - Use /usr/bin/python2-for-tests instead of python2 to run your tests. (Note that if you do not file the bug as above, this workaround will break without warning in the future.) For details, see https://hurl.corp.redhat.com/rhel8-py2 Fatal Python error: Python 2 is disabled /var/tmp/rpm-tmp.EFmmS5: line 37: 2457555 Aborted (core dumped) CFLAGS="${CFLAGS:-${RPM_OPT_FLAGS}}" LDFLAGS="${LDFLAGS:-${RPM_LD_FLAGS}}" /usr/bin/python2 setup.py build --executable="/usr/bin/python2 -s" RPM build errors: error: Bad exit status from /var/tmp/rpm-tmp.EFmmS5 (%build) bogus date in %changelog: Thu Mar 22 2017 Steve Milner - 2.2.0-7 Bad exit status from /var/tmp/rpm-tmp.EFmmS5 (%build) Child return code was: 1 EXCEPTION: [Error()] Traceback (most recent call last): File "/usr/lib/python3.6/site-packages/mockbuild/trace_decorator.py", line 93, in trace result = func(*args, **kw) File "/usr/lib/python3.6/site-packages/mockbuild/util.py", line 598, in do_with_status raise exception.Error("Command failed: \n # %s\n%s" % (command, output), child.returncode) mockbuild.exception.Error: Command failed: # bash --login -c /usr/bin/rpmbuild -bb --target noarch --nodeps /builddir/build/SPECS/python-pygments.spec