I: pbuilder: network access will be disabled during build
I: Current time: Mon Mar  3 14:37:06 -12 2025
I: pbuilder-time-stamp: 1741055826
I: Building the build Environment
I: extracting base tarball [/var/cache/pbuilder/unstable-reproducible-base.tgz]
I: copying local configuration
W: --override-config is not set; not updating apt.conf Read the manpage for details.
I: mounting /proc filesystem
I: mounting /sys filesystem
I: creating /{dev,run}/shm
I: mounting /dev/pts filesystem
I: redirecting /dev/ptmx to /dev/pts/ptmx
I: policy-rc.d already exists
I: Copying source file
I: copying [commonmark-bkrs_0.5.4+ds-7.1.dsc]
I: copying [./commonmark-bkrs_0.5.4+ds.orig.tar.xz]
I: copying [./commonmark-bkrs_0.5.4+ds-7.1.debian.tar.xz]
I: Extracting source
dpkg-source: warning: cannot verify inline signature for ./commonmark-bkrs_0.5.4+ds-7.1.dsc: unsupported subcommand
dpkg-source: info: extracting commonmark-bkrs in commonmark-bkrs-0.5.4+ds
dpkg-source: info: unpacking commonmark-bkrs_0.5.4+ds.orig.tar.xz
dpkg-source: info: unpacking commonmark-bkrs_0.5.4+ds-7.1.debian.tar.xz
dpkg-source: info: using patch list from debian/patches/series
dpkg-source: info: applying upstream-fix-deprecation-HTMLunescape.patch
dpkg-source: info: applying upstream-fix-deprecation-time.patch
dpkg-source: info: applying debianization.patch
dpkg-source: info: applying python3.12.diff
I: Not using root during the build.
I: Installing the build-deps
I: user script /srv/workspace/pbuilder/247930/tmp/hooks/D02_print_environment starting
I: set
  BUILDDIR='/build/reproducible-path'
  BUILDUSERGECOS='first user,first room,first work-phone,first home-phone,first other'
  BUILDUSERNAME='pbuilder1'
  BUILD_ARCH='amd64'
  DEBIAN_FRONTEND='noninteractive'
  DEB_BUILD_OPTIONS='buildinfo=+all reproducible=+all parallel=20 '
  DISTRIBUTION='unstable'
  HOME='/root'
  HOST_ARCH='amd64'
  IFS=' 	
  '
  INVOCATION_ID='f5130258351c4f7c83730c6a14407bf7'
  LANG='C'
  LANGUAGE='en_US:en'
  LC_ALL='C'
  MAIL='/var/mail/root'
  OPTIND='1'
  PATH='/usr/sbin:/usr/bin:/sbin:/bin:/usr/games'
  PBCURRENTCOMMANDLINEOPERATION='build'
  PBUILDER_OPERATION='build'
  PBUILDER_PKGDATADIR='/usr/share/pbuilder'
  PBUILDER_PKGLIBDIR='/usr/lib/pbuilder'
  PBUILDER_SYSCONFDIR='/etc'
  PPID='247930'
  PS1='# '
  PS2='> '
  PS4='+ '
  PWD='/'
  SHELL='/bin/bash'
  SHLVL='2'
  SUDO_COMMAND='/usr/bin/timeout -k 18.1h 18h /usr/bin/ionice -c 3 /usr/bin/nice /usr/sbin/pbuilder --build --configfile /srv/reproducible-results/rbuild-debian/r-b-build.z5PZaC3r/pbuilderrc_CRJn --distribution unstable --hookdir /etc/pbuilder/first-build-hooks --debbuildopts -b --basetgz /var/cache/pbuilder/unstable-reproducible-base.tgz --buildresult /srv/reproducible-results/rbuild-debian/r-b-build.z5PZaC3r/b1 --logfile b1/build.log commonmark-bkrs_0.5.4+ds-7.1.dsc'
  SUDO_GID='110'
  SUDO_UID='105'
  SUDO_USER='jenkins'
  TERM='unknown'
  TZ='/usr/share/zoneinfo/Etc/GMT+12'
  USER='root'
  _='/usr/bin/systemd-run'
  http_proxy='http://46.16.76.132:3128'
I: uname -a
  Linux ionos1-amd64 6.1.0-31-amd64 #1 SMP PREEMPT_DYNAMIC Debian 6.1.128-1 (2025-02-07) x86_64 GNU/Linux
I: ls -l /bin
  lrwxrwxrwx 1 root root 7 Nov 22 14:40 /bin -> usr/bin
I: user script /srv/workspace/pbuilder/247930/tmp/hooks/D02_print_environment finished
 -> Attempting to satisfy build-dependencies
 -> Creating pbuilder-satisfydepends-dummy package
Package: pbuilder-satisfydepends-dummy
Version: 0.invalid.0
Architecture: amd64
Maintainer: Debian Pbuilder Team <pbuilder-maint@lists.alioth.debian.org>
Description: Dummy package to satisfy dependencies with aptitude - created by pbuilder
 This package was created automatically by pbuilder to satisfy the
 build-dependencies of the package being currently built.
Depends: debhelper-compat (= 12), dh-python, help2man, python3-all, python3-docutils, python3-setuptools
dpkg-deb: building package 'pbuilder-satisfydepends-dummy' in '/tmp/satisfydepends-aptitude/pbuilder-satisfydepends-dummy.deb'.
Selecting previously unselected package pbuilder-satisfydepends-dummy.
(Reading database ... 19783 files and directories currently installed.)
Preparing to unpack .../pbuilder-satisfydepends-dummy.deb ...
Unpacking pbuilder-satisfydepends-dummy (0.invalid.0) ...
dpkg: pbuilder-satisfydepends-dummy: dependency problems, but configuring anyway as you requested:
 pbuilder-satisfydepends-dummy depends on debhelper-compat (= 12); however:
  Package debhelper-compat is not installed.
 pbuilder-satisfydepends-dummy depends on dh-python; however:
  Package dh-python is not installed.
 pbuilder-satisfydepends-dummy depends on help2man; however:
  Package help2man is not installed.
 pbuilder-satisfydepends-dummy depends on python3-all; however:
  Package python3-all is not installed.
 pbuilder-satisfydepends-dummy depends on python3-docutils; however:
  Package python3-docutils is not installed.
 pbuilder-satisfydepends-dummy depends on python3-setuptools; however:
  Package python3-setuptools is not installed.

Setting up pbuilder-satisfydepends-dummy (0.invalid.0) ...
Reading package lists...
Building dependency tree...
Reading state information...
Initializing package states...
Writing extended state information...
Building tag database...
pbuilder-satisfydepends-dummy is already installed at the requested version (0.invalid.0)
pbuilder-satisfydepends-dummy is already installed at the requested version (0.invalid.0)
The following NEW packages will be installed:
  autoconf{a} automake{a} autopoint{a} autotools-dev{a} bsdextrautils{a} debhelper{a} dh-autoreconf{a} dh-python{a} dh-strip-nondeterminism{a} docutils-common{a} dwz{a} file{a} gettext{a} gettext-base{a} groff-base{a} help2man{a} intltool-debian{a} libarchive-zip-perl{a} libdebhelper-perl{a} libelf1t64{a} libexpat1{a} libffi8{a} libfile-stripnondeterminism-perl{a} libicu72{a} liblocale-gettext-perl{a} libmagic-mgc{a} libmagic1t64{a} libpipeline1{a} libpython3-stdlib{a} libpython3.13-minimal{a} libpython3.13-stdlib{a} libreadline8t64{a} libtool{a} libuchardet0{a} libunistring5{a} libxml2{a} m4{a} man-db{a} media-types{a} netbase{a} po-debconf{a} python3{a} python3-all{a} python3-autocommand{a} python3-docutils{a} python3-inflect{a} python3-jaraco.context{a} python3-jaraco.functools{a} python3-jaraco.text{a} python3-minimal{a} python3-more-itertools{a} python3-pkg-resources{a} python3-roman{a} python3-setuptools{a} python3-typeguard{a} python3-typing-extensions{a} python3-zipp{a} python3.13{a} python3.13-minimal{a} readline-common{a} sensible-utils{a} sgml-base{a} tzdata{a} xml-core{a} 
The following packages are RECOMMENDED but will NOT be installed:
  ca-certificates curl libarchive-cpio-perl libltdl-dev libmail-sendmail-perl libpaper-utils lynx python3-pil python3-pygments wget 
0 packages upgraded, 64 newly installed, 0 to remove and 0 not upgraded.
Need to get 29.2 MB of archives. After unpacking 113 MB will be used.
Writing extended state information...
Get: 1 http://deb.debian.org/debian unstable/main amd64 liblocale-gettext-perl amd64 1.07-7+b1 [15.3 kB]
Get: 2 http://deb.debian.org/debian unstable/main amd64 libpython3.13-minimal amd64 3.13.2-1 [859 kB]
Get: 3 http://deb.debian.org/debian unstable/main amd64 libexpat1 amd64 2.6.4-1 [106 kB]
Get: 4 http://deb.debian.org/debian unstable/main amd64 python3.13-minimal amd64 3.13.2-1 [2205 kB]
Get: 5 http://deb.debian.org/debian unstable/main amd64 python3-minimal amd64 3.13.2-1 [27.1 kB]
Get: 6 http://deb.debian.org/debian unstable/main amd64 media-types all 12.0.0 [28.9 kB]
Get: 7 http://deb.debian.org/debian unstable/main amd64 netbase all 6.4 [12.8 kB]
Get: 8 http://deb.debian.org/debian unstable/main amd64 tzdata all 2025a-2 [259 kB]
Get: 9 http://deb.debian.org/debian unstable/main amd64 libffi8 amd64 3.4.7-1 [23.9 kB]
Get: 10 http://deb.debian.org/debian unstable/main amd64 readline-common all 8.2-6 [69.4 kB]
Get: 11 http://deb.debian.org/debian unstable/main amd64 libreadline8t64 amd64 8.2-6 [169 kB]
Get: 12 http://deb.debian.org/debian unstable/main amd64 libpython3.13-stdlib amd64 3.13.2-1 [1979 kB]
Get: 13 http://deb.debian.org/debian unstable/main amd64 python3.13 amd64 3.13.2-1 [745 kB]
Get: 14 http://deb.debian.org/debian unstable/main amd64 libpython3-stdlib amd64 3.13.2-1 [10.0 kB]
Get: 15 http://deb.debian.org/debian unstable/main amd64 python3 amd64 3.13.2-1 [28.1 kB]
Get: 16 http://deb.debian.org/debian unstable/main amd64 sgml-base all 1.31 [15.4 kB]
Get: 17 http://deb.debian.org/debian unstable/main amd64 sensible-utils all 0.0.24 [24.8 kB]
Get: 18 http://deb.debian.org/debian unstable/main amd64 libmagic-mgc amd64 1:5.45-3+b1 [314 kB]
Get: 19 http://deb.debian.org/debian unstable/main amd64 libmagic1t64 amd64 1:5.45-3+b1 [108 kB]
Get: 20 http://deb.debian.org/debian unstable/main amd64 file amd64 1:5.45-3+b1 [43.3 kB]
Get: 21 http://deb.debian.org/debian unstable/main amd64 gettext-base amd64 0.23.1-1 [243 kB]
Get: 22 http://deb.debian.org/debian unstable/main amd64 libuchardet0 amd64 0.0.8-1+b2 [68.9 kB]
Get: 23 http://deb.debian.org/debian unstable/main amd64 groff-base amd64 1.23.0-7 [1185 kB]
Get: 24 http://deb.debian.org/debian unstable/main amd64 bsdextrautils amd64 2.40.4-5 [92.4 kB]
Get: 25 http://deb.debian.org/debian unstable/main amd64 libpipeline1 amd64 1.5.8-1 [42.0 kB]
Get: 26 http://deb.debian.org/debian unstable/main amd64 man-db amd64 2.13.0-1 [1420 kB]
Get: 27 http://deb.debian.org/debian unstable/main amd64 m4 amd64 1.4.19-5 [294 kB]
Get: 28 http://deb.debian.org/debian unstable/main amd64 autoconf all 2.72-3 [493 kB]
Get: 29 http://deb.debian.org/debian unstable/main amd64 autotools-dev all 20220109.1 [51.6 kB]
Get: 30 http://deb.debian.org/debian unstable/main amd64 automake all 1:1.17-3 [862 kB]
Get: 31 http://deb.debian.org/debian unstable/main amd64 autopoint all 0.23.1-1 [770 kB]
Get: 32 http://deb.debian.org/debian unstable/main amd64 libdebhelper-perl all 13.24.1 [90.9 kB]
Get: 33 http://deb.debian.org/debian unstable/main amd64 libtool all 2.5.4-3 [539 kB]
Get: 34 http://deb.debian.org/debian unstable/main amd64 dh-autoreconf all 20 [17.1 kB]
Get: 35 http://deb.debian.org/debian unstable/main amd64 libarchive-zip-perl all 1.68-1 [104 kB]
Get: 36 http://deb.debian.org/debian unstable/main amd64 libfile-stripnondeterminism-perl all 1.14.1-2 [19.7 kB]
Get: 37 http://deb.debian.org/debian unstable/main amd64 dh-strip-nondeterminism all 1.14.1-2 [8620 B]
Get: 38 http://deb.debian.org/debian unstable/main amd64 libelf1t64 amd64 0.192-4 [189 kB]
Get: 39 http://deb.debian.org/debian unstable/main amd64 dwz amd64 0.15-1+b1 [110 kB]
Get: 40 http://deb.debian.org/debian unstable/main amd64 libunistring5 amd64 1.3-1 [476 kB]
Get: 41 http://deb.debian.org/debian unstable/main amd64 libicu72 amd64 72.1-6 [9421 kB]
Get: 42 http://deb.debian.org/debian unstable/main amd64 libxml2 amd64 2.12.7+dfsg+really2.9.14-0.2+b2 [699 kB]
Get: 43 http://deb.debian.org/debian unstable/main amd64 gettext amd64 0.23.1-1 [1680 kB]
Get: 44 http://deb.debian.org/debian unstable/main amd64 intltool-debian all 0.35.0+20060710.6 [22.9 kB]
Get: 45 http://deb.debian.org/debian unstable/main amd64 po-debconf all 1.0.21+nmu1 [248 kB]
Get: 46 http://deb.debian.org/debian unstable/main amd64 debhelper all 13.24.1 [920 kB]
Get: 47 http://deb.debian.org/debian unstable/main amd64 python3-autocommand all 2.2.2-3 [13.6 kB]
Get: 48 http://deb.debian.org/debian unstable/main amd64 python3-more-itertools all 10.6.0-1 [65.3 kB]
Get: 49 http://deb.debian.org/debian unstable/main amd64 python3-typing-extensions all 4.12.2-2 [73.0 kB]
Get: 50 http://deb.debian.org/debian unstable/main amd64 python3-typeguard all 4.4.2-1 [37.3 kB]
Get: 51 http://deb.debian.org/debian unstable/main amd64 python3-inflect all 7.3.1-2 [32.4 kB]
Get: 52 http://deb.debian.org/debian unstable/main amd64 python3-jaraco.context all 6.0.0-1 [7984 B]
Get: 53 http://deb.debian.org/debian unstable/main amd64 python3-jaraco.functools all 4.1.0-1 [12.0 kB]
Get: 54 http://deb.debian.org/debian unstable/main amd64 python3-pkg-resources all 75.8.0-1 [222 kB]
Get: 55 http://deb.debian.org/debian unstable/main amd64 python3-jaraco.text all 4.0.0-1 [11.4 kB]
Get: 56 http://deb.debian.org/debian unstable/main amd64 python3-zipp all 3.21.0-1 [10.6 kB]
Get: 57 http://deb.debian.org/debian unstable/main amd64 python3-setuptools all 75.8.0-1 [724 kB]
Get: 58 http://deb.debian.org/debian unstable/main amd64 dh-python all 6.20250108 [113 kB]
Get: 59 http://deb.debian.org/debian unstable/main amd64 xml-core all 0.19 [20.1 kB]
Get: 60 http://deb.debian.org/debian unstable/main amd64 docutils-common all 0.21.2+dfsg-2 [128 kB]
Get: 61 http://deb.debian.org/debian unstable/main amd64 help2man amd64 1.49.3 [198 kB]
Get: 62 http://deb.debian.org/debian unstable/main amd64 python3-all amd64 3.13.2-1 [1048 B]
Get: 63 http://deb.debian.org/debian unstable/main amd64 python3-roman all 5.0-1 [10.6 kB]
Get: 64 http://deb.debian.org/debian unstable/main amd64 python3-docutils all 0.21.2+dfsg-2 [403 kB]
Fetched 29.2 MB in 13s (2273 kB/s)
Preconfiguring packages ...
Selecting previously unselected package liblocale-gettext-perl.
(Reading database ... 
(Reading database ... 5%
(Reading database ... 10%
(Reading database ... 15%
(Reading database ... 20%
(Reading database ... 25%
(Reading database ... 30%
(Reading database ... 35%
(Reading database ... 40%
(Reading database ... 45%
(Reading database ... 50%
(Reading database ... 55%
(Reading database ... 60%
(Reading database ... 65%
(Reading database ... 70%
(Reading database ... 75%
(Reading database ... 80%
(Reading database ... 85%
(Reading database ... 90%
(Reading database ... 95%
(Reading database ... 100%
(Reading database ... 19783 files and directories currently installed.)
Preparing to unpack .../liblocale-gettext-perl_1.07-7+b1_amd64.deb ...
Unpacking liblocale-gettext-perl (1.07-7+b1) ...
Selecting previously unselected package libpython3.13-minimal:amd64.
Preparing to unpack .../libpython3.13-minimal_3.13.2-1_amd64.deb ...
Unpacking libpython3.13-minimal:amd64 (3.13.2-1) ...
Selecting previously unselected package libexpat1:amd64.
Preparing to unpack .../libexpat1_2.6.4-1_amd64.deb ...
Unpacking libexpat1:amd64 (2.6.4-1) ...
Selecting previously unselected package python3.13-minimal.
Preparing to unpack .../python3.13-minimal_3.13.2-1_amd64.deb ...
Unpacking python3.13-minimal (3.13.2-1) ...
Setting up libpython3.13-minimal:amd64 (3.13.2-1) ...
Setting up libexpat1:amd64 (2.6.4-1) ...
Setting up python3.13-minimal (3.13.2-1) ...
Selecting previously unselected package python3-minimal.
(Reading database ... 
(Reading database ... 5%
(Reading database ... 10%
(Reading database ... 15%
(Reading database ... 20%
(Reading database ... 25%
(Reading database ... 30%
(Reading database ... 35%
(Reading database ... 40%
(Reading database ... 45%
(Reading database ... 50%
(Reading database ... 55%
(Reading database ... 60%
(Reading database ... 65%
(Reading database ... 70%
(Reading database ... 75%
(Reading database ... 80%
(Reading database ... 85%
(Reading database ... 90%
(Reading database ... 95%
(Reading database ... 100%
(Reading database ... 20132 files and directories currently installed.)
Preparing to unpack .../0-python3-minimal_3.13.2-1_amd64.deb ...
Unpacking python3-minimal (3.13.2-1) ...
Selecting previously unselected package media-types.
Preparing to unpack .../1-media-types_12.0.0_all.deb ...
Unpacking media-types (12.0.0) ...
Selecting previously unselected package netbase.
Preparing to unpack .../2-netbase_6.4_all.deb ...
Unpacking netbase (6.4) ...
Selecting previously unselected package tzdata.
Preparing to unpack .../3-tzdata_2025a-2_all.deb ...
Unpacking tzdata (2025a-2) ...
Selecting previously unselected package libffi8:amd64.
Preparing to unpack .../4-libffi8_3.4.7-1_amd64.deb ...
Unpacking libffi8:amd64 (3.4.7-1) ...
Selecting previously unselected package readline-common.
Preparing to unpack .../5-readline-common_8.2-6_all.deb ...
Unpacking readline-common (8.2-6) ...
Selecting previously unselected package libreadline8t64:amd64.
Preparing to unpack .../6-libreadline8t64_8.2-6_amd64.deb ...
Adding 'diversion of /lib/x86_64-linux-gnu/libhistory.so.8 to /lib/x86_64-linux-gnu/libhistory.so.8.usr-is-merged by libreadline8t64'
Adding 'diversion of /lib/x86_64-linux-gnu/libhistory.so.8.2 to /lib/x86_64-linux-gnu/libhistory.so.8.2.usr-is-merged by libreadline8t64'
Adding 'diversion of /lib/x86_64-linux-gnu/libreadline.so.8 to /lib/x86_64-linux-gnu/libreadline.so.8.usr-is-merged by libreadline8t64'
Adding 'diversion of /lib/x86_64-linux-gnu/libreadline.so.8.2 to /lib/x86_64-linux-gnu/libreadline.so.8.2.usr-is-merged by libreadline8t64'
Unpacking libreadline8t64:amd64 (8.2-6) ...
Selecting previously unselected package libpython3.13-stdlib:amd64.
Preparing to unpack .../7-libpython3.13-stdlib_3.13.2-1_amd64.deb ...
Unpacking libpython3.13-stdlib:amd64 (3.13.2-1) ...
Selecting previously unselected package python3.13.
Preparing to unpack .../8-python3.13_3.13.2-1_amd64.deb ...
Unpacking python3.13 (3.13.2-1) ...
Selecting previously unselected package libpython3-stdlib:amd64.
Preparing to unpack .../9-libpython3-stdlib_3.13.2-1_amd64.deb ...
Unpacking libpython3-stdlib:amd64 (3.13.2-1) ...
Setting up python3-minimal (3.13.2-1) ...
Selecting previously unselected package python3.
(Reading database ... 
(Reading database ... 5%
(Reading database ... 10%
(Reading database ... 15%
(Reading database ... 20%
(Reading database ... 25%
(Reading database ... 30%
(Reading database ... 35%
(Reading database ... 40%
(Reading database ... 45%
(Reading database ... 50%
(Reading database ... 55%
(Reading database ... 60%
(Reading database ... 65%
(Reading database ... 70%
(Reading database ... 75%
(Reading database ... 80%
(Reading database ... 85%
(Reading database ... 90%
(Reading database ... 95%
(Reading database ... 100%
(Reading database ... 21142 files and directories currently installed.)
Preparing to unpack .../00-python3_3.13.2-1_amd64.deb ...
Unpacking python3 (3.13.2-1) ...
Selecting previously unselected package sgml-base.
Preparing to unpack .../01-sgml-base_1.31_all.deb ...
Unpacking sgml-base (1.31) ...
Selecting previously unselected package sensible-utils.
Preparing to unpack .../02-sensible-utils_0.0.24_all.deb ...
Unpacking sensible-utils (0.0.24) ...
Selecting previously unselected package libmagic-mgc.
Preparing to unpack .../03-libmagic-mgc_1%3a5.45-3+b1_amd64.deb ...
Unpacking libmagic-mgc (1:5.45-3+b1) ...
Selecting previously unselected package libmagic1t64:amd64.
Preparing to unpack .../04-libmagic1t64_1%3a5.45-3+b1_amd64.deb ...
Unpacking libmagic1t64:amd64 (1:5.45-3+b1) ...
Selecting previously unselected package file.
Preparing to unpack .../05-file_1%3a5.45-3+b1_amd64.deb ...
Unpacking file (1:5.45-3+b1) ...
Selecting previously unselected package gettext-base.
Preparing to unpack .../06-gettext-base_0.23.1-1_amd64.deb ...
Unpacking gettext-base (0.23.1-1) ...
Selecting previously unselected package libuchardet0:amd64.
Preparing to unpack .../07-libuchardet0_0.0.8-1+b2_amd64.deb ...
Unpacking libuchardet0:amd64 (0.0.8-1+b2) ...
Selecting previously unselected package groff-base.
Preparing to unpack .../08-groff-base_1.23.0-7_amd64.deb ...
Unpacking groff-base (1.23.0-7) ...
Selecting previously unselected package bsdextrautils.
Preparing to unpack .../09-bsdextrautils_2.40.4-5_amd64.deb ...
Unpacking bsdextrautils (2.40.4-5) ...
Selecting previously unselected package libpipeline1:amd64.
Preparing to unpack .../10-libpipeline1_1.5.8-1_amd64.deb ...
Unpacking libpipeline1:amd64 (1.5.8-1) ...
Selecting previously unselected package man-db.
Preparing to unpack .../11-man-db_2.13.0-1_amd64.deb ...
Unpacking man-db (2.13.0-1) ...
Selecting previously unselected package m4.
Preparing to unpack .../12-m4_1.4.19-5_amd64.deb ...
Unpacking m4 (1.4.19-5) ...
Selecting previously unselected package autoconf.
Preparing to unpack .../13-autoconf_2.72-3_all.deb ...
Unpacking autoconf (2.72-3) ...
Selecting previously unselected package autotools-dev.
Preparing to unpack .../14-autotools-dev_20220109.1_all.deb ...
Unpacking autotools-dev (20220109.1) ...
Selecting previously unselected package automake.
Preparing to unpack .../15-automake_1%3a1.17-3_all.deb ...
Unpacking automake (1:1.17-3) ...
Selecting previously unselected package autopoint.
Preparing to unpack .../16-autopoint_0.23.1-1_all.deb ...
Unpacking autopoint (0.23.1-1) ...
Selecting previously unselected package libdebhelper-perl.
Preparing to unpack .../17-libdebhelper-perl_13.24.1_all.deb ...
Unpacking libdebhelper-perl (13.24.1) ...
Selecting previously unselected package libtool.
Preparing to unpack .../18-libtool_2.5.4-3_all.deb ...
Unpacking libtool (2.5.4-3) ...
Selecting previously unselected package dh-autoreconf.
Preparing to unpack .../19-dh-autoreconf_20_all.deb ...
Unpacking dh-autoreconf (20) ...
Selecting previously unselected package libarchive-zip-perl.
Preparing to unpack .../20-libarchive-zip-perl_1.68-1_all.deb ...
Unpacking libarchive-zip-perl (1.68-1) ...
Selecting previously unselected package libfile-stripnondeterminism-perl.
Preparing to unpack .../21-libfile-stripnondeterminism-perl_1.14.1-2_all.deb ...
Unpacking libfile-stripnondeterminism-perl (1.14.1-2) ...
Selecting previously unselected package dh-strip-nondeterminism.
Preparing to unpack .../22-dh-strip-nondeterminism_1.14.1-2_all.deb ...
Unpacking dh-strip-nondeterminism (1.14.1-2) ...
Selecting previously unselected package libelf1t64:amd64.
Preparing to unpack .../23-libelf1t64_0.192-4_amd64.deb ...
Unpacking libelf1t64:amd64 (0.192-4) ...
Selecting previously unselected package dwz.
Preparing to unpack .../24-dwz_0.15-1+b1_amd64.deb ...
Unpacking dwz (0.15-1+b1) ...
Selecting previously unselected package libunistring5:amd64.
Preparing to unpack .../25-libunistring5_1.3-1_amd64.deb ...
Unpacking libunistring5:amd64 (1.3-1) ...
Selecting previously unselected package libicu72:amd64.
Preparing to unpack .../26-libicu72_72.1-6_amd64.deb ...
Unpacking libicu72:amd64 (72.1-6) ...
Selecting previously unselected package libxml2:amd64.
Preparing to unpack .../27-libxml2_2.12.7+dfsg+really2.9.14-0.2+b2_amd64.deb ...
Unpacking libxml2:amd64 (2.12.7+dfsg+really2.9.14-0.2+b2) ...
Selecting previously unselected package gettext.
Preparing to unpack .../28-gettext_0.23.1-1_amd64.deb ...
Unpacking gettext (0.23.1-1) ...
Selecting previously unselected package intltool-debian.
Preparing to unpack .../29-intltool-debian_0.35.0+20060710.6_all.deb ...
Unpacking intltool-debian (0.35.0+20060710.6) ...
Selecting previously unselected package po-debconf.
Preparing to unpack .../30-po-debconf_1.0.21+nmu1_all.deb ...
Unpacking po-debconf (1.0.21+nmu1) ...
Selecting previously unselected package debhelper.
Preparing to unpack .../31-debhelper_13.24.1_all.deb ...
Unpacking debhelper (13.24.1) ...
Selecting previously unselected package python3-autocommand.
Preparing to unpack .../32-python3-autocommand_2.2.2-3_all.deb ...
Unpacking python3-autocommand (2.2.2-3) ...
Selecting previously unselected package python3-more-itertools.
Preparing to unpack .../33-python3-more-itertools_10.6.0-1_all.deb ...
Unpacking python3-more-itertools (10.6.0-1) ...
Selecting previously unselected package python3-typing-extensions.
Preparing to unpack .../34-python3-typing-extensions_4.12.2-2_all.deb ...
Unpacking python3-typing-extensions (4.12.2-2) ...
Selecting previously unselected package python3-typeguard.
Preparing to unpack .../35-python3-typeguard_4.4.2-1_all.deb ...
Unpacking python3-typeguard (4.4.2-1) ...
Selecting previously unselected package python3-inflect.
Preparing to unpack .../36-python3-inflect_7.3.1-2_all.deb ...
Unpacking python3-inflect (7.3.1-2) ...
Selecting previously unselected package python3-jaraco.context.
Preparing to unpack .../37-python3-jaraco.context_6.0.0-1_all.deb ...
Unpacking python3-jaraco.context (6.0.0-1) ...
Selecting previously unselected package python3-jaraco.functools.
Preparing to unpack .../38-python3-jaraco.functools_4.1.0-1_all.deb ...
Unpacking python3-jaraco.functools (4.1.0-1) ...
Selecting previously unselected package python3-pkg-resources.
Preparing to unpack .../39-python3-pkg-resources_75.8.0-1_all.deb ...
Unpacking python3-pkg-resources (75.8.0-1) ...
Selecting previously unselected package python3-jaraco.text.
Preparing to unpack .../40-python3-jaraco.text_4.0.0-1_all.deb ...
Unpacking python3-jaraco.text (4.0.0-1) ...
Selecting previously unselected package python3-zipp.
Preparing to unpack .../41-python3-zipp_3.21.0-1_all.deb ...
Unpacking python3-zipp (3.21.0-1) ...
Selecting previously unselected package python3-setuptools.
Preparing to unpack .../42-python3-setuptools_75.8.0-1_all.deb ...
Unpacking python3-setuptools (75.8.0-1) ...
Selecting previously unselected package dh-python.
Preparing to unpack .../43-dh-python_6.20250108_all.deb ...
Unpacking dh-python (6.20250108) ...
Selecting previously unselected package xml-core.
Preparing to unpack .../44-xml-core_0.19_all.deb ...
Unpacking xml-core (0.19) ...
Selecting previously unselected package docutils-common.
Preparing to unpack .../45-docutils-common_0.21.2+dfsg-2_all.deb ...
Unpacking docutils-common (0.21.2+dfsg-2) ...
Selecting previously unselected package help2man.
Preparing to unpack .../46-help2man_1.49.3_amd64.deb ...
Unpacking help2man (1.49.3) ...
Selecting previously unselected package python3-all.
Preparing to unpack .../47-python3-all_3.13.2-1_amd64.deb ...
Unpacking python3-all (3.13.2-1) ...
Selecting previously unselected package python3-roman.
Preparing to unpack .../48-python3-roman_5.0-1_all.deb ...
Unpacking python3-roman (5.0-1) ...
Selecting previously unselected package python3-docutils.
Preparing to unpack .../49-python3-docutils_0.21.2+dfsg-2_all.deb ...
Unpacking python3-docutils (0.21.2+dfsg-2) ...
Setting up media-types (12.0.0) ...
Setting up libpipeline1:amd64 (1.5.8-1) ...
Setting up libicu72:amd64 (72.1-6) ...
Setting up bsdextrautils (2.40.4-5) ...
Setting up libmagic-mgc (1:5.45-3+b1) ...
Setting up libarchive-zip-perl (1.68-1) ...
Setting up libdebhelper-perl (13.24.1) ...
Setting up libmagic1t64:amd64 (1:5.45-3+b1) ...
Setting up gettext-base (0.23.1-1) ...
Setting up m4 (1.4.19-5) ...
Setting up file (1:5.45-3+b1) ...
Setting up libelf1t64:amd64 (0.192-4) ...
Setting up tzdata (2025a-2) ...

Current default time zone: 'Etc/UTC'
Local time is now:      Tue Mar  4 02:38:33 UTC 2025.
Universal Time is now:  Tue Mar  4 02:38:33 UTC 2025.
Run 'dpkg-reconfigure tzdata' if you wish to change it.

Setting up autotools-dev (20220109.1) ...
Setting up libunistring5:amd64 (1.3-1) ...
Setting up autopoint (0.23.1-1) ...
Setting up autoconf (2.72-3) ...
Setting up libffi8:amd64 (3.4.7-1) ...
Setting up dwz (0.15-1+b1) ...
Setting up sensible-utils (0.0.24) ...
Setting up libuchardet0:amd64 (0.0.8-1+b2) ...
Setting up netbase (6.4) ...
Setting up sgml-base (1.31) ...
Setting up readline-common (8.2-6) ...
Setting up libxml2:amd64 (2.12.7+dfsg+really2.9.14-0.2+b2) ...
Setting up liblocale-gettext-perl (1.07-7+b1) ...
Setting up automake (1:1.17-3) ...
update-alternatives: using /usr/bin/automake-1.17 to provide /usr/bin/automake (automake) in auto mode
Setting up libfile-stripnondeterminism-perl (1.14.1-2) ...
Setting up gettext (0.23.1-1) ...
Setting up libtool (2.5.4-3) ...
Setting up intltool-debian (0.35.0+20060710.6) ...
Setting up help2man (1.49.3) ...
Setting up dh-autoreconf (20) ...
Setting up libreadline8t64:amd64 (8.2-6) ...
Setting up dh-strip-nondeterminism (1.14.1-2) ...
Setting up groff-base (1.23.0-7) ...
Setting up xml-core (0.19) ...
Setting up libpython3.13-stdlib:amd64 (3.13.2-1) ...
Setting up libpython3-stdlib:amd64 (3.13.2-1) ...
Setting up python3.13 (3.13.2-1) ...
Setting up po-debconf (1.0.21+nmu1) ...
Setting up python3 (3.13.2-1) ...
Setting up python3-zipp (3.21.0-1) ...
Setting up python3-autocommand (2.2.2-3) ...
Setting up man-db (2.13.0-1) ...
Not building database; man-db/auto-update is not 'true'.
Setting up python3-roman (5.0-1) ...
Setting up python3-typing-extensions (4.12.2-2) ...
Setting up python3-more-itertools (10.6.0-1) ...
Setting up python3-jaraco.functools (4.1.0-1) ...
Setting up python3-jaraco.context (6.0.0-1) ...
Setting up python3-typeguard (4.4.2-1) ...
Setting up python3-all (3.13.2-1) ...
Setting up debhelper (13.24.1) ...
Setting up python3-inflect (7.3.1-2) ...
Setting up python3-jaraco.text (4.0.0-1) ...
Setting up python3-pkg-resources (75.8.0-1) ...
Setting up python3-setuptools (75.8.0-1) ...
Setting up dh-python (6.20250108) ...
Processing triggers for libc-bin (2.41-3) ...
Processing triggers for sgml-base (1.31) ...
Setting up docutils-common (0.21.2+dfsg-2) ...
Processing triggers for sgml-base (1.31) ...
Setting up python3-docutils (0.21.2+dfsg-2) ...
Reading package lists...
Building dependency tree...
Reading state information...
Reading extended state information...
Initializing package states...
Writing extended state information...
Building tag database...
 -> Finished parsing the build-deps
I: Building the package
I: Running cd /build/reproducible-path/commonmark-bkrs-0.5.4+ds/ && env PATH="/usr/sbin:/usr/bin:/sbin:/bin:/usr/games" HOME="/nonexistent/first-build" dpkg-buildpackage -us -uc -b && env PATH="/usr/sbin:/usr/bin:/sbin:/bin:/usr/games" HOME="/nonexistent/first-build" dpkg-genchanges -S  > ../commonmark-bkrs_0.5.4+ds-7.1_source.changes
dpkg-buildpackage: info: source package commonmark-bkrs
dpkg-buildpackage: info: source version 0.5.4+ds-7.1
dpkg-buildpackage: info: source distribution unstable
dpkg-buildpackage: info: source changed by Matthias Klose <doko@debian.org>
 dpkg-source --before-build .
dpkg-buildpackage: info: host architecture amd64
 debian/rules clean
dh clean --with python3 --buildsystem=pybuild
   dh_auto_clean -O--buildsystem=pybuild
I: pybuild base:311: python3.13 setup.py clean 
'build/bdist.linux-x86_64' does not exist -- can't clean it
'build/scripts-3.13' does not exist -- can't clean it
   dh_autoreconf_clean -O--buildsystem=pybuild
   dh_clean -O--buildsystem=pybuild
 debian/rules binary
dh binary --with python3 --buildsystem=pybuild
   dh_update_autotools_config -O--buildsystem=pybuild
   dh_autoreconf -O--buildsystem=pybuild
   dh_auto_configure -O--buildsystem=pybuild
I: pybuild base:311: python3.13 setup.py config 
   dh_auto_build -O--buildsystem=pybuild
I: pybuild base:311: /usr/bin/python3 setup.py build 
I: pybuild pybuild:334: rm -f build/scripts-3 ; ln -rsf build/scripts-3.13 build/scripts-3 ; ln -f build/scripts-3.13/cmark.py build/scripts-3.13/cmark-bkrs ; mkdir -p build/scripts-3.13/tests ; ln -f build/scripts-3.13/test-CommonMark.py build/scripts-3.13/tests/test-CommonMark.py
   debian/rules override_dh_auto_test
make[1]: Entering directory '/build/reproducible-path/commonmark-bkrs-0.5.4+ds'
PYBUILD_SYSTEM=custom PYBUILD_TEST_ARGS="{interpreter} CommonMark/test/test-CommonMark.py" dh_auto_test
I: pybuild base:311: python3.13 CommonMark/test/test-CommonMark.py
/build/reproducible-path/commonmark-bkrs-0.5.4+ds/CommonMark/test/test-CommonMark.py:67: SyntaxWarning: invalid escape sequence '\.'
  testMatch = re.findall(re.compile("^\.\n([\s\S]*?)^\.\n([\s\S]*?)^.$|^#{1,6} *(.*)$", re.M), tests)
/build/reproducible-path/commonmark-bkrs-0.5.4+ds/.pybuild/cpython3_3.13/build/CommonMark_bkrs/CommonMark.py:186: SyntaxWarning: invalid escape sequence '\s'
  return bool(re.compile("^\s*$").match(s))
/build/reproducible-path/commonmark-bkrs-0.5.4+ds/.pybuild/cpython3_3.13/build/CommonMark_bkrs/CommonMark.py:338: SyntaxWarning: invalid escape sequence '\/'
  "^<([a-zA-Z0-9.!#$%&'*+\/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*)>")
/build/reproducible-path/commonmark-bkrs-0.5.4+ds/.pybuild/cpython3_3.13/build/CommonMark_bkrs/CommonMark.py:385: SyntaxWarning: invalid escape sequence '\s'
  numdelims <= 3) and (not re.match("\s", char_after))
/build/reproducible-path/commonmark-bkrs-0.5.4+ds/.pybuild/cpython3_3.13/build/CommonMark_bkrs/CommonMark.py:387: SyntaxWarning: invalid escape sequence '\s'
  numdelims <= 3) and (not re.match("\s", char_before))
/build/reproducible-path/commonmark-bkrs-0.5.4+ds/.pybuild/cpython3_3.13/build/CommonMark_bkrs/CommonMark.py:1008: SyntaxWarning: invalid escape sequence '\g'
  re.sub(r'(?:(\\#) *#*| *#+) *$', '\g<1>', ln[offset:])]
[Preprocessing]
Test #1
tick
Test #2
tick
[Precedence]
Test #3
tick
[Horizontal rules]
Test #4
tick
Test #5
tick
Test #6
tick
Test #7
tick
Test #8
tick
Test #9
tick
Test #10
tick
Test #11
tick
Test #12
tick
Test #13
tick
Test #14
tick
Test #15
tick
Test #16
tick
Test #17
tick
Test #18
tick
Test #19
tick
Test #20
tick
Test #21
tick
Test #22
tick
[ATX headers]
Test #23
tick
Test #24
tick
Test #25
tick
Test #26
tick
Test #27
tick
Test #28
tick
Test #29
tick
Test #30
tick
Test #31
tick
Test #32
tick
Test #33
tick
Test #34
tick
Test #35
tick
Test #36
tick
Test #37
tick
Test #38
tick
Test #39
tick
[Setext headers]
Test #40
tick
Test #41
tick
Test #42
tick
Test #43
tick
Test #44
tick
Test #45
tick
Test #46
tick
Test #47
tick
Test #48
tick
Test #49
tick
Test #50
tick
Test #51
tick
Test #52
tick
Test #53
tick
[Indented code blocks]
Test #54
tick
Test #55
tick
Test #56
tick
Test #57
tick
Test #58
tick
Test #59
tick
Test #60
tick
Test #61
tick
Test #62
cross
=== markdown ===============

␣␣␣␣
␣␣␣␣foo
␣␣␣␣


=== expected ===============
<pre><code>foo
</code></pre>

=== got ====================
<pre><code>foo

</code></pre>

Test #63
tick
[Fenced code blocks]
Test #64
tick
Test #65
tick
Test #66
tick
Test #67
tick
Test #68
tick
Test #69
tick
Test #70
tick
Test #71
tick
Test #72
tick
Test #73
tick
Test #74
tick
Test #75
tick
Test #76
tick
Test #77
tick
Test #78
tick
Test #79
tick
Test #80
tick
Test #81
tick
Test #82
tick
Test #83
tick
Test #84
tick
Test #85
tick
Test #86
tick
[HTML blocks]
Test #87
tick
Test #88
tick
Test #89
tick
Test #90
tick
Test #91
tick
Test #92
tick
Test #93
cross
=== markdown ===============
<![CDATA[
function␣matchwo(a,b)
{
if␣(a␣<␣b␣&&␣a␣<␣0)␣then
␣␣{
␣␣return␣1;
␣␣}
else
␣␣{
␣␣return␣0;
␣␣}
}
]]>

=== expected ===============
<![CDATA[
function␣matchwo(a,b)

=== got ====================
<![CDATA[
function␣matchwo(a,b)
{
if␣(a␣<␣b␣&&␣a␣<␣0)␣then
␣␣{
␣␣return␣1;
␣␣}
else
␣␣{
␣␣return␣0;
␣␣}
}
]]>

Test #94
cross
=== markdown ===============

The␣opening␣tag␣can␣be␣indented␣1-3␣spaces,␣but␣not␣4:


=== expected ===============
␣␣<!--␣foo␣-->

␣␣␣␣<!--␣foo␣-->

=== got ====================
<p>The␣opening␣tag␣can␣be␣indented␣1-3␣spaces,␣but␣not␣4:</p>

Test #95
cross
=== markdown ===============

An␣HTML␣block␣can␣interrupt␣a␣paragraph,␣and␣need␣not␣be␣preceded
by␣a␣blank␣line.


=== expected ===============
Foo
<div>
bar
</div>

=== got ====================
<p>An␣HTML␣block␣can␣interrupt␣a␣paragraph,␣and␣need␣not␣be␣preceded
by␣a␣blank␣line.</p>

Test #96
cross
=== markdown ===============

However,␣a␣following␣blank␣line␣is␣always␣needed,␣except␣at␣the␣end␣of
a␣document:


=== expected ===============
<div>
bar
</div>
*foo*

=== got ====================
<p>However,␣a␣following␣blank␣line␣is␣always␣needed,␣except␣at␣the␣end␣of
a␣document:</p>

Test #97
cross
=== markdown ===============

An␣incomplete␣HTML␣block␣tag␣may␣also␣start␣an␣HTML␣block:


=== expected ===============
<div␣class
foo

=== got ====================
<p>An␣incomplete␣HTML␣block␣tag␣may␣also␣start␣an␣HTML␣block:</p>

Test #98
cross
=== markdown ===============

This␣rule␣differs␣from␣John␣Gruber's␣original␣Markdown␣syntax
specification,␣which␣says:

>␣The␣only␣restrictions␣are␣that␣block-level␣HTML␣elements␣—
>␣e.g.␣`<div>`,␣`<table>`,␣`<pre>`,␣`<p>`,␣etc.␣—␣must␣be␣separated␣from
>␣surrounding␣content␣by␣blank␣lines,␣and␣the␣start␣and␣end␣tags␣of␣the
>␣block␣should␣not␣be␣indented␣with␣tabs␣or␣spaces.

In␣some␣ways␣Gruber's␣rule␣is␣more␣restrictive␣than␣the␣one␣given
here:

-␣It␣requires␣that␣an␣HTML␣block␣be␣preceded␣by␣a␣blank␣line.
-␣It␣does␣not␣allow␣the␣start␣tag␣to␣be␣indented.
-␣It␣requires␣a␣matching␣end␣tag,␣which␣it␣also␣does␣not␣allow␣to
␣␣be␣indented.

Indeed,␣most␣Markdown␣implementations,␣including␣some␣of␣Gruber's
own␣perl␣implementations,␣do␣not␣impose␣these␣restrictions.

There␣is␣one␣respect,␣however,␣in␣which␣Gruber's␣rule␣is␣more␣liberal
than␣the␣one␣given␣here,␣since␣it␣allows␣blank␣lines␣to␣occur␣inside
an␣HTML␣block.␣␣There␣are␣two␣reasons␣for␣disallowing␣them␣here.
First,␣it␣removes␣the␣need␣to␣parse␣balanced␣tags,␣which␣is
expensive␣and␣can␣require␣backtracking␣from␣the␣end␣of␣the␣document
if␣no␣matching␣end␣tag␣is␣found.␣Second,␣it␣provides␣a␣very␣simple
and␣flexible␣way␣of␣including␣Markdown␣content␣inside␣HTML␣tags:
simply␣separate␣the␣Markdown␣from␣the␣HTML␣using␣blank␣lines:


=== expected ===============
<div>

*Emphasized*␣text.

</div>

=== got ====================
<p>This␣rule␣differs␣from␣John␣Gruber's␣original␣Markdown␣syntax
specification,␣which␣says:</p>
<blockquote>
<p>The␣only␣restrictions␣are␣that␣block-level␣HTML␣elements␣—
e.g.␣<code>&lt;div&gt;</code>,␣<code>&lt;table&gt;</code>,␣<code>&lt;pre&gt;</code>,␣<code>&lt;p&gt;</code>,␣etc.␣—␣must␣be␣separated␣from
surrounding␣content␣by␣blank␣lines,␣and␣the␣start␣and␣end␣tags␣of␣the
block␣should␣not␣be␣indented␣with␣tabs␣or␣spaces.</p>
</blockquote>
<p>In␣some␣ways␣Gruber's␣rule␣is␣more␣restrictive␣than␣the␣one␣given
here:</p>
<ul>
<li>It␣requires␣that␣an␣HTML␣block␣be␣preceded␣by␣a␣blank␣line.</li>
<li>It␣does␣not␣allow␣the␣start␣tag␣to␣be␣indented.</li>
<li>It␣requires␣a␣matching␣end␣tag,␣which␣it␣also␣does␣not␣allow␣to
be␣indented.</li>
</ul>
<p>Indeed,␣most␣Markdown␣implementations,␣including␣some␣of␣Gruber's
own␣perl␣implementations,␣do␣not␣impose␣these␣restrictions.</p>
<p>There␣is␣one␣respect,␣however,␣in␣which␣Gruber's␣rule␣is␣more␣liberal
than␣the␣one␣given␣here,␣since␣it␣allows␣blank␣lines␣to␣occur␣inside
an␣HTML␣block.␣␣There␣are␣two␣reasons␣for␣disallowing␣them␣here.
First,␣it␣removes␣the␣need␣to␣parse␣balanced␣tags,␣which␣is
expensive␣and␣can␣require␣backtracking␣from␣the␣end␣of␣the␣document
if␣no␣matching␣end␣tag␣is␣found.␣Second,␣it␣provides␣a␣very␣simple
and␣flexible␣way␣of␣including␣Markdown␣content␣inside␣HTML␣tags:
simply␣separate␣the␣Markdown␣from␣the␣HTML␣using␣blank␣lines:</p>

Test #99
cross
=== markdown ===============

Compare:


=== expected ===============
<div>
*Emphasized*␣text.
</div>

=== got ====================
<p>Compare:</p>

Test #100
cross
=== markdown ===============

Some␣Markdown␣implementations␣have␣adopted␣a␣convention␣of
interpreting␣content␣inside␣tags␣as␣text␣if␣the␣open␣tag␣has
the␣attribute␣`markdown=1`.␣␣The␣rule␣given␣above␣seems␣a␣simpler␣and
more␣elegant␣way␣of␣achieving␣the␣same␣expressive␣power,␣which␣is␣also
much␣simpler␣to␣parse.

The␣main␣potential␣drawback␣is␣that␣one␣can␣no␣longer␣paste␣HTML
blocks␣into␣Markdown␣documents␣with␣100%␣reliability.␣␣However,
*in␣most␣cases*␣this␣will␣work␣fine,␣because␣the␣blank␣lines␣in
HTML␣are␣usually␣followed␣by␣HTML␣block␣tags.␣␣For␣example:


=== expected ===============
<table>

<tr>

<td>
Hi
</td>

</tr>

</table>

=== got ====================
<p>Some␣Markdown␣implementations␣have␣adopted␣a␣convention␣of
interpreting␣content␣inside␣tags␣as␣text␣if␣the␣open␣tag␣has
the␣attribute␣<code>markdown=1</code>.␣␣The␣rule␣given␣above␣seems␣a␣simpler␣and
more␣elegant␣way␣of␣achieving␣the␣same␣expressive␣power,␣which␣is␣also
much␣simpler␣to␣parse.</p>
<p>The␣main␣potential␣drawback␣is␣that␣one␣can␣no␣longer␣paste␣HTML
blocks␣into␣Markdown␣documents␣with␣100%␣reliability.␣␣However,
<em>in␣most␣cases</em>␣this␣will␣work␣fine,␣because␣the␣blank␣lines␣in
HTML␣are␣usually␣followed␣by␣HTML␣block␣tags.␣␣For␣example:</p>

Test #101
cross
=== markdown ===============

Moreover,␣blank␣lines␣are␣usually␣not␣necessary␣and␣can␣be
deleted.␣␣The␣exception␣is␣inside␣`<pre>`␣tags;␣here,␣one␣can
replace␣the␣blank␣lines␣with␣`&#10;`␣entities.

So␣there␣is␣no␣important␣loss␣of␣expressive␣power␣with␣the␣new␣rule.

##␣Link␣reference␣definitions

A␣[link␣reference␣definition](#link-reference-definition)
<a␣id="link-reference-definition"></a>␣consists␣of␣a␣[link
label](#link-label),␣indented␣up␣to␣three␣spaces,␣followed
by␣a␣colon␣(`:`),␣optional␣blank␣space␣(including␣up␣to␣one
newline),␣a␣[link␣destination](#link-destination),␣optional
blank␣space␣(including␣up␣to␣one␣newline),␣and␣an␣optional␣[link
title](#link-title),␣which␣if␣it␣is␣present␣must␣be␣separated
from␣the␣[link␣destination](#link-destination)␣by␣whitespace.
No␣further␣non-space␣characters␣may␣occur␣on␣the␣line.

A␣[link␣reference-definition](#link-reference-definition)
does␣not␣correspond␣to␣a␣structural␣element␣of␣a␣document.␣␣Instead,␣it
defines␣a␣label␣which␣can␣be␣used␣in␣[reference␣links](#reference-link)
and␣reference-style␣[images](#image)␣elsewhere␣in␣the␣document.␣␣[Link
reference␣definitions]␣can␣come␣either␣before␣or␣after␣the␣links␣that␣use
them.


=== expected ===============
[foo]:␣/url␣"title"

[foo]

=== got ====================
<p>Moreover,␣blank␣lines␣are␣usually␣not␣necessary␣and␣can␣be
deleted.␣␣The␣exception␣is␣inside␣<code>&lt;pre&gt;</code>␣tags;␣here,␣one␣can
replace␣the␣blank␣lines␣with␣<code>&amp;#10;</code>␣entities.</p>
<p>So␣there␣is␣no␣important␣loss␣of␣expressive␣power␣with␣the␣new␣rule.</p>
<h2>Link␣reference␣definitions</h2>
<p>A␣<a␣href="#link-reference-definition">link␣reference␣definition</a>
<a␣id="link-reference-definition"></a>␣consists␣of␣a␣<a␣href="#link-label">link
label</a>,␣indented␣up␣to␣three␣spaces,␣followed
by␣a␣colon␣(<code>:</code>),␣optional␣blank␣space␣(including␣up␣to␣one
newline),␣a␣<a␣href="#link-destination">link␣destination</a>,␣optional
blank␣space␣(including␣up␣to␣one␣newline),␣and␣an␣optional␣<a␣href="#link-title">link
title</a>,␣which␣if␣it␣is␣present␣must␣be␣separated
from␣the␣<a␣href="#link-destination">link␣destination</a>␣by␣whitespace.
No␣further␣non-space␣characters␣may␣occur␣on␣the␣line.</p>
<p>A␣<a␣href="#link-reference-definition">link␣reference-definition</a>
does␣not␣correspond␣to␣a␣structural␣element␣of␣a␣document.␣␣Instead,␣it
defines␣a␣label␣which␣can␣be␣used␣in␣<a␣href="#reference-link">reference␣links</a>
and␣reference-style␣<a␣href="#image">images</a>␣elsewhere␣in␣the␣document.␣␣[Link
reference␣definitions]␣can␣come␣either␣before␣or␣after␣the␣links␣that␣use
them.</p>

Test #102
cross
=== markdown ===============


=== expected ===============
␣␣␣[foo]:␣
␣␣␣␣␣␣/url␣␣
␣␣␣␣␣␣␣␣␣␣␣'the␣title'␣␣

[foo]

=== got ====================

Test #103
cross
=== markdown ===============


=== expected ===============
[Foo*bar\]]:my_(url)␣'title␣(with␣parens)'

[Foo*bar\]]

=== got ====================

Test #104
cross
=== markdown ===============


=== expected ===============
[Foo␣bar]:
<my␣url>
'title'

[Foo␣bar]

=== got ====================

Test #105
cross
=== markdown ===============

The␣title␣may␣be␣omitted:


=== expected ===============
[foo]:
/url

[foo]

=== got ====================
<p>The␣title␣may␣be␣omitted:</p>

Test #106
cross
=== markdown ===============

The␣link␣destination␣may␣not␣be␣omitted:


=== expected ===============
[foo]:

[foo]

=== got ====================
<p>The␣link␣destination␣may␣not␣be␣omitted:</p>

Test #107
cross
=== markdown ===============

A␣link␣can␣come␣before␣its␣corresponding␣definition:


=== expected ===============
[foo]

[foo]:␣url

=== got ====================
<p>A␣link␣can␣come␣before␣its␣corresponding␣definition:</p>

Test #108
cross
=== markdown ===============

If␣there␣are␣several␣matching␣definitions,␣the␣first␣one␣takes
precedence:


=== expected ===============
[foo]

[foo]:␣first
[foo]:␣second

=== got ====================
<p>If␣there␣are␣several␣matching␣definitions,␣the␣first␣one␣takes
precedence:</p>

Test #109
cross
=== markdown ===============

As␣noted␣in␣the␣section␣on␣[Links],␣matching␣of␣labels␣is
case-insensitive␣(see␣[matches](#matches)).


=== expected ===============
[FOO]:␣/url

[Foo]

=== got ====================
<p>As␣noted␣in␣the␣section␣on␣[Links],␣matching␣of␣labels␣is
case-insensitive␣(see␣<a␣href="#matches">matches</a>).</p>

Test #110
cross
=== markdown ===============


=== expected ===============
[ΑΓΩ]:␣/φου

[αγω]

=== got ====================

Test #111
cross
=== markdown ===============

Here␣is␣a␣link␣reference␣definition␣with␣no␣corresponding␣link.
It␣contributes␣nothing␣to␣the␣document.


=== expected ===============
[foo]:␣/url

=== got ====================
<p>Here␣is␣a␣link␣reference␣definition␣with␣no␣corresponding␣link.
It␣contributes␣nothing␣to␣the␣document.</p>

Test #112
cross
=== markdown ===============

This␣is␣not␣a␣link␣reference␣definition,␣because␣there␣are
non-space␣characters␣after␣the␣title:


=== expected ===============
[foo]:␣/url␣"title"␣ok

=== got ====================
<p>This␣is␣not␣a␣link␣reference␣definition,␣because␣there␣are
non-space␣characters␣after␣the␣title:</p>

Test #113
cross
=== markdown ===============

This␣is␣not␣a␣link␣reference␣definition,␣because␣it␣is␣indented
four␣spaces:


=== expected ===============
␣␣␣␣[foo]:␣/url␣"title"

[foo]

=== got ====================
<p>This␣is␣not␣a␣link␣reference␣definition,␣because␣it␣is␣indented
four␣spaces:</p>

Test #114
cross
=== markdown ===============

This␣is␣not␣a␣link␣reference␣definition,␣because␣it␣occurs␣inside
a␣code␣block:


=== expected ===============
```
[foo]:␣/url
```

[foo]

=== got ====================
<p>This␣is␣not␣a␣link␣reference␣definition,␣because␣it␣occurs␣inside
a␣code␣block:</p>

Test #115
cross
=== markdown ===============

A␣[link␣reference␣definition](#link-reference-definition)␣cannot
interrupt␣a␣paragraph.


=== expected ===============
Foo
[bar]:␣/baz

[bar]

=== got ====================
<p>A␣<a␣href="#link-reference-definition">link␣reference␣definition</a>␣cannot
interrupt␣a␣paragraph.</p>

Test #116
cross
=== markdown ===============

However,␣it␣can␣directly␣follow␣other␣block␣elements,␣such␣as␣headers
and␣horizontal␣rules,␣and␣it␣need␣not␣be␣followed␣by␣a␣blank␣line.


=== expected ===============
#␣[Foo]
[foo]:␣/url
>␣bar

=== got ====================
<p>However,␣it␣can␣directly␣follow␣other␣block␣elements,␣such␣as␣headers
and␣horizontal␣rules,␣and␣it␣need␣not␣be␣followed␣by␣a␣blank␣line.</p>

Test #117
cross
=== markdown ===============

Several␣[link␣references](#link-reference)␣can␣occur␣one␣after␣another,
without␣intervening␣blank␣lines.


=== expected ===============
[foo]:␣/foo-url␣"foo"
[bar]:␣/bar-url
␣␣"bar"
[baz]:␣/baz-url

[foo],
[bar],
[baz]

=== got ====================
<p>Several␣<a␣href="#link-reference">link␣references</a>␣can␣occur␣one␣after␣another,
without␣intervening␣blank␣lines.</p>

Test #118
cross
=== markdown ===============

[Link␣reference␣definitions](#link-reference-definition)␣can␣occur
inside␣block␣containers,␣like␣lists␣and␣block␣quotations.␣␣They
affect␣the␣entire␣document,␣not␣just␣the␣container␣in␣which␣they
are␣defined:


=== expected ===============
[foo]

>␣[foo]:␣/url

=== got ====================
<p><a␣href="#link-reference-definition">Link␣reference␣definitions</a>␣can␣occur
inside␣block␣containers,␣like␣lists␣and␣block␣quotations.␣␣They
affect␣the␣entire␣document,␣not␣just␣the␣container␣in␣which␣they
are␣defined:</p>

Test #119
cross
=== markdown ===============


##␣Paragraphs

A␣sequence␣of␣non-blank␣lines␣that␣cannot␣be␣interpreted␣as␣other
kinds␣of␣blocks␣forms␣a␣[paragraph](#paragraph).<a␣id="paragraph"></a>
The␣contents␣of␣the␣paragraph␣are␣the␣result␣of␣parsing␣the
paragraph's␣raw␣content␣as␣inlines.␣␣The␣paragraph's␣raw␣content
is␣formed␣by␣concatenating␣the␣lines␣and␣removing␣initial␣and␣final
spaces.

A␣simple␣example␣with␣two␣paragraphs:


=== expected ===============
aaa

bbb

=== got ====================
<h2>Paragraphs</h2>
<p>A␣sequence␣of␣non-blank␣lines␣that␣cannot␣be␣interpreted␣as␣other
kinds␣of␣blocks␣forms␣a␣<a␣href="#paragraph">paragraph</a>.<a␣id="paragraph"></a>
The␣contents␣of␣the␣paragraph␣are␣the␣result␣of␣parsing␣the
paragraph's␣raw␣content␣as␣inlines.␣␣The␣paragraph's␣raw␣content
is␣formed␣by␣concatenating␣the␣lines␣and␣removing␣initial␣and␣final
spaces.</p>
<p>A␣simple␣example␣with␣two␣paragraphs:</p>

Test #120
cross
=== markdown ===============

Paragraphs␣can␣contain␣multiple␣lines,␣but␣no␣blank␣lines:


=== expected ===============
aaa
bbb

ccc
ddd

=== got ====================
<p>Paragraphs␣can␣contain␣multiple␣lines,␣but␣no␣blank␣lines:</p>

Test #121
cross
=== markdown ===============

Multiple␣blank␣lines␣between␣paragraph␣have␣no␣effect:


=== expected ===============
aaa


bbb

=== got ====================
<p>Multiple␣blank␣lines␣between␣paragraph␣have␣no␣effect:</p>

Test #122
cross
=== markdown ===============

Leading␣spaces␣are␣skipped:


=== expected ===============
␣␣aaa
␣bbb

=== got ====================
<p>Leading␣spaces␣are␣skipped:</p>

Test #123
cross
=== markdown ===============

Lines␣after␣the␣first␣may␣be␣indented␣any␣amount,␣since␣indented
code␣blocks␣cannot␣interrupt␣paragraphs.


=== expected ===============
aaa
␣␣␣␣␣␣␣␣␣␣␣␣␣bbb
␣␣␣␣␣␣␣␣␣␣␣␣␣␣␣␣␣␣␣␣␣␣␣␣␣␣␣␣␣␣␣␣␣␣␣␣␣␣␣ccc

=== got ====================
<p>Lines␣after␣the␣first␣may␣be␣indented␣any␣amount,␣since␣indented
code␣blocks␣cannot␣interrupt␣paragraphs.</p>

Test #124
cross
=== markdown ===============

However,␣the␣first␣line␣may␣be␣indented␣at␣most␣three␣spaces,
or␣an␣indented␣code␣block␣will␣be␣triggered:


=== expected ===============
␣␣␣aaa
bbb

=== got ====================
<p>However,␣the␣first␣line␣may␣be␣indented␣at␣most␣three␣spaces,
or␣an␣indented␣code␣block␣will␣be␣triggered:</p>

Test #125
cross
=== markdown ===============


=== expected ===============
␣␣␣␣aaa
bbb

=== got ====================

Test #126
cross
=== markdown ===============

Final␣spaces␣are␣stripped␣before␣inline␣parsing,␣so␣a␣paragraph
that␣ends␣with␣two␣or␣more␣spaces␣will␣not␣end␣with␣a␣hard␣line
break:


=== expected ===============
aaa␣␣␣␣␣
bbb␣␣␣␣␣

=== got ====================
<p>Final␣spaces␣are␣stripped␣before␣inline␣parsing,␣so␣a␣paragraph
that␣ends␣with␣two␣or␣more␣spaces␣will␣not␣end␣with␣a␣hard␣line
break:</p>

Test #127
cross
=== markdown ===============

##␣Blank␣lines

[Blank␣lines](#blank-line)␣between␣block-level␣elements␣are␣ignored,
except␣for␣the␣role␣they␣play␣in␣determining␣whether␣a␣[list](#list)
is␣[tight](#tight)␣or␣[loose](#loose).

Blank␣lines␣at␣the␣beginning␣and␣end␣of␣the␣document␣are␣also␣ignored.


=== expected ===============
␣␣

aaa
␣␣

#␣aaa

␣␣

=== got ====================
<h2>Blank␣lines</h2>
<p><a␣href="#blank-line">Blank␣lines</a>␣between␣block-level␣elements␣are␣ignored,
except␣for␣the␣role␣they␣play␣in␣determining␣whether␣a␣<a␣href="#list">list</a>
is␣<a␣href="#tight">tight</a>␣or␣<a␣href="#loose">loose</a>.</p>
<p>Blank␣lines␣at␣the␣beginning␣and␣end␣of␣the␣document␣are␣also␣ignored.</p>

Test #128
cross
=== markdown ===============


#␣Container␣blocks

A␣[container␣block](#container-block)␣is␣a␣block␣that␣has␣other
blocks␣as␣its␣contents.␣␣There␣are␣two␣basic␣kinds␣of␣container␣blocks:
[block␣quotes](#block-quote)␣and␣[list␣items](#list-item).
[Lists](#list)␣are␣meta-containers␣for␣[list␣items](#list-item).

We␣define␣the␣syntax␣for␣container␣blocks␣recursively.␣␣The␣general
form␣of␣the␣definition␣is:

>␣If␣X␣is␣a␣sequence␣of␣blocks,␣then␣the␣result␣of
>␣transforming␣X␣in␣such-and-such␣a␣way␣is␣a␣container␣of␣type␣Y
>␣with␣these␣blocks␣as␣its␣content.

So,␣we␣explain␣what␣counts␣as␣a␣block␣quote␣or␣list␣item␣by␣explaining
how␣these␣can␣be␣*generated*␣from␣their␣contents.␣This␣should␣suffice
to␣define␣the␣syntax,␣although␣it␣does␣not␣give␣a␣recipe␣for␣*parsing*
these␣constructions.␣␣(A␣recipe␣is␣provided␣below␣in␣the␣section␣entitled
[A␣parsing␣strategy](#appendix-a-a-parsing-strategy).)

##␣Block␣quotes

A␣[block␣quote␣marker](#block-quote-marker)␣<a␣id="block-quote-marker"></a>
consists␣of␣0-3␣spaces␣of␣initial␣indent,␣plus␣(a)␣the␣character␣`>`␣together
with␣a␣following␣space,␣or␣(b)␣a␣single␣character␣`>`␣not␣followed␣by␣a␣space.

The␣following␣rules␣define␣[block␣quotes](#block-quote):
<a␣id="block-quote"></a>

1.␣␣**Basic␣case.**␣␣If␣a␣string␣of␣lines␣*Ls*␣constitute␣a␣sequence
␣␣␣␣of␣blocks␣*Bs*,␣then␣the␣result␣of␣appending␣a␣[block␣quote
␣␣␣␣marker](#block-quote-marker)␣to␣the␣beginning␣of␣each␣line␣in␣*Ls*
␣␣␣␣is␣a␣[block␣quote](#block-quote)␣containing␣*Bs*.

2.␣␣**Laziness.**␣␣If␣a␣string␣of␣lines␣*Ls*␣constitute␣a␣[block
␣␣␣␣quote](#block-quote)␣with␣contents␣*Bs*,␣then␣the␣result␣of␣deleting
␣␣␣␣the␣initial␣[block␣quote␣marker](#block-quote-marker)␣from␣one␣or
␣␣␣␣more␣lines␣in␣which␣the␣next␣non-space␣character␣after␣the␣[block
␣␣␣␣quote␣marker](#block-quote-marker)␣is␣[paragraph␣continuation
␣␣␣␣text](#paragraph-continuation-text)␣is␣a␣block␣quote␣with␣*Bs*␣as
␣␣␣␣its␣content.␣␣<a␣id="paragraph-continuation-text"></a>
␣␣␣␣[Paragraph␣continuation␣text](#paragraph-continuation-text)␣is␣text
␣␣␣␣that␣will␣be␣parsed␣as␣part␣of␣the␣content␣of␣a␣paragraph,␣but␣does
␣␣␣␣not␣occur␣at␣the␣beginning␣of␣the␣paragraph.

3.␣␣**Consecutiveness.**␣␣A␣document␣cannot␣contain␣two␣[block
␣␣␣␣quotes](#block-quote)␣in␣a␣row␣unless␣there␣is␣a␣[blank
␣␣␣␣line](#blank-line)␣between␣them.

Nothing␣else␣counts␣as␣a␣[block␣quote](#block-quote).

Here␣is␣a␣simple␣example:


=== expected ===============
>␣#␣Foo
>␣bar
>␣baz

=== got ====================
<h1>Container␣blocks</h1>
<p>A␣<a␣href="#container-block">container␣block</a>␣is␣a␣block␣that␣has␣other
blocks␣as␣its␣contents.␣␣There␣are␣two␣basic␣kinds␣of␣container␣blocks:
<a␣href="#block-quote">block␣quotes</a>␣and␣<a␣href="#list-item">list␣items</a>.
<a␣href="#list">Lists</a>␣are␣meta-containers␣for␣<a␣href="#list-item">list␣items</a>.</p>
<p>We␣define␣the␣syntax␣for␣container␣blocks␣recursively.␣␣The␣general
form␣of␣the␣definition␣is:</p>
<blockquote>
<p>If␣X␣is␣a␣sequence␣of␣blocks,␣then␣the␣result␣of
transforming␣X␣in␣such-and-such␣a␣way␣is␣a␣container␣of␣type␣Y
with␣these␣blocks␣as␣its␣content.</p>
</blockquote>
<p>So,␣we␣explain␣what␣counts␣as␣a␣block␣quote␣or␣list␣item␣by␣explaining
how␣these␣can␣be␣<em>generated</em>␣from␣their␣contents.␣This␣should␣suffice
to␣define␣the␣syntax,␣although␣it␣does␣not␣give␣a␣recipe␣for␣<em>parsing</em>
these␣constructions.␣␣(A␣recipe␣is␣provided␣below␣in␣the␣section␣entitled
<a␣href="#appendix-a-a-parsing-strategy">A␣parsing␣strategy</a>.)</p>
<h2>Block␣quotes</h2>
<p>A␣<a␣href="#block-quote-marker">block␣quote␣marker</a>␣<a␣id="block-quote-marker"></a>
consists␣of␣0-3␣spaces␣of␣initial␣indent,␣plus␣(a)␣the␣character␣<code>&gt;</code>␣together
with␣a␣following␣space,␣or␣(b)␣a␣single␣character␣<code>&gt;</code>␣not␣followed␣by␣a␣space.</p>
<p>The␣following␣rules␣define␣<a␣href="#block-quote">block␣quotes</a>:
<a␣id="block-quote"></a></p>
<ol>
<li><p><strong>Basic␣case.</strong>␣␣If␣a␣string␣of␣lines␣<em>Ls</em>␣constitute␣a␣sequence
of␣blocks␣<em>Bs</em>,␣then␣the␣result␣of␣appending␣a␣<a␣href="#block-quote-marker">block␣quote
marker</a>␣to␣the␣beginning␣of␣each␣line␣in␣<em>Ls</em>
is␣a␣<a␣href="#block-quote">block␣quote</a>␣containing␣<em>Bs</em>.</p></li>
<li><p><strong>Laziness.</strong>␣␣If␣a␣string␣of␣lines␣<em>Ls</em>␣constitute␣a␣<a␣href="#block-quote">block
quote</a>␣with␣contents␣<em>Bs</em>,␣then␣the␣result␣of␣deleting
the␣initial␣<a␣href="#block-quote-marker">block␣quote␣marker</a>␣from␣one␣or
more␣lines␣in␣which␣the␣next␣non-space␣character␣after␣the␣<a␣href="#block-quote-marker">block
quote␣marker</a>␣is␣<a␣href="#paragraph-continuation-text">paragraph␣continuation
text</a>␣is␣a␣block␣quote␣with␣<em>Bs</em>␣as
its␣content.␣␣<a␣id="paragraph-continuation-text"></a>
<a␣href="#paragraph-continuation-text">Paragraph␣continuation␣text</a>␣is␣text
that␣will␣be␣parsed␣as␣part␣of␣the␣content␣of␣a␣paragraph,␣but␣does
not␣occur␣at␣the␣beginning␣of␣the␣paragraph.</p></li>
<li><p><strong>Consecutiveness.</strong>␣␣A␣document␣cannot␣contain␣two␣<a␣href="#block-quote">block
quotes</a>␣in␣a␣row␣unless␣there␣is␣a␣<a␣href="#blank-line">blank
line</a>␣between␣them.</p></li>
</ol>
<p>Nothing␣else␣counts␣as␣a␣<a␣href="#block-quote">block␣quote</a>.</p>
<p>Here␣is␣a␣simple␣example:</p>

Test #129
cross
=== markdown ===============

The␣spaces␣after␣the␣`>`␣characters␣can␣be␣omitted:


=== expected ===============
>#␣Foo
>bar
>␣baz

=== got ====================
<p>The␣spaces␣after␣the␣<code>&gt;</code>␣characters␣can␣be␣omitted:</p>

Test #130
cross
=== markdown ===============

The␣`>`␣characters␣can␣be␣indented␣1-3␣spaces:


=== expected ===============
␣␣␣>␣#␣Foo
␣␣␣>␣bar
␣>␣baz

=== got ====================
<p>The␣<code>&gt;</code>␣characters␣can␣be␣indented␣1-3␣spaces:</p>

Test #131
cross
=== markdown ===============

Four␣spaces␣gives␣us␣a␣code␣block:


=== expected ===============
␣␣␣␣>␣#␣Foo
␣␣␣␣>␣bar
␣␣␣␣>␣baz

=== got ====================
<p>Four␣spaces␣gives␣us␣a␣code␣block:</p>

Test #132
cross
=== markdown ===============

The␣Laziness␣clause␣allows␣us␣to␣omit␣the␣`>`␣before␣a
paragraph␣continuation␣line:


=== expected ===============
>␣#␣Foo
>␣bar
baz

=== got ====================
<p>The␣Laziness␣clause␣allows␣us␣to␣omit␣the␣<code>&gt;</code>␣before␣a
paragraph␣continuation␣line:</p>

Test #133
cross
=== markdown ===============

A␣block␣quote␣can␣contain␣some␣lazy␣and␣some␣non-lazy
continuation␣lines:


=== expected ===============
>␣bar
baz
>␣foo

=== got ====================
<p>A␣block␣quote␣can␣contain␣some␣lazy␣and␣some␣non-lazy
continuation␣lines:</p>

Test #134
cross
=== markdown ===============

Laziness␣only␣applies␣to␣lines␣that␣are␣continuations␣of
paragraphs.␣Lines␣containing␣characters␣or␣indentation␣that␣indicate
block␣structure␣cannot␣be␣lazy.


=== expected ===============
>␣foo
---

=== got ====================
<p>Laziness␣only␣applies␣to␣lines␣that␣are␣continuations␣of
paragraphs.␣Lines␣containing␣characters␣or␣indentation␣that␣indicate
block␣structure␣cannot␣be␣lazy.</p>

Test #135
cross
=== markdown ===============


=== expected ===============
>␣-␣foo
-␣bar

=== got ====================

Test #136
cross
=== markdown ===============


=== expected ===============
>␣␣␣␣␣foo
␣␣␣␣bar

=== got ====================

Test #137
cross
=== markdown ===============


=== expected ===============
>␣```
foo
```

=== got ====================

Test #138
cross
=== markdown ===============

A␣block␣quote␣can␣be␣empty:


=== expected ===============

=== got ====================
<p>A␣block␣quote␣can␣be␣empty:</p>

Test #139
cross
=== markdown ===============
<blockquote>
</blockquote>

=== expected ===============


=== got ====================
<blockquote>
</blockquote>

Test #140
cross
=== markdown ===============
<blockquote>
</blockquote>

=== expected ===============

A␣block␣quote␣can␣have␣initial␣or␣final␣blank␣lines:


=== got ====================
<blockquote>
</blockquote>

Test #141
cross
=== markdown ===============
<blockquote>
<p>foo</p>
</blockquote>

=== expected ===============

A␣blank␣line␣always␣separates␣block␣quotes:


=== got ====================
<blockquote>
<p>foo</p>
</blockquote>

Test #142
cross
=== markdown ===============
<blockquote>
<p>foo</p>
</blockquote>
<blockquote>
<p>bar</p>
</blockquote>

=== expected ===============

(Most␣current␣Markdown␣implementations,␣including␣John␣Gruber's
original␣`Markdown.pl`,␣will␣parse␣this␣example␣as␣a␣single␣block␣quote
with␣two␣paragraphs.␣␣But␣it␣seems␣better␣to␣allow␣the␣author␣to␣decide
whether␣two␣block␣quotes␣or␣one␣are␣wanted.)

Consecutiveness␣means␣that␣if␣we␣put␣these␣block␣quotes␣together,
we␣get␣a␣single␣block␣quote:


=== got ====================
<blockquote>
<p>foo</p>
</blockquote>
<blockquote>
<p>bar</p>
</blockquote>

Test #143
cross
=== markdown ===============
<blockquote>
<p>foo
bar</p>
</blockquote>

=== expected ===============

To␣get␣a␣block␣quote␣with␣two␣paragraphs,␣use:


=== got ====================
<blockquote>
<p>foo
bar</p>
</blockquote>

Test #144
cross
=== markdown ===============
<blockquote>
<p>foo</p>
<p>bar</p>
</blockquote>

=== expected ===============

Block␣quotes␣can␣interrupt␣paragraphs:


=== got ====================
<blockquote>
<p>foo</p>
<p>bar</p>
</blockquote>

Test #145
cross
=== markdown ===============
<p>foo</p>
<blockquote>
<p>bar</p>
</blockquote>

=== expected ===============

In␣general,␣blank␣lines␣are␣not␣needed␣before␣or␣after␣block
quotes:


=== got ====================
<p>foo</p>
<blockquote>
<p>bar</p>
</blockquote>

Test #146
cross
=== markdown ===============
<blockquote>
<p>aaa</p>
</blockquote>
<hr␣/>
<blockquote>
<p>bbb</p>
</blockquote>

=== expected ===============

However,␣because␣of␣laziness,␣a␣blank␣line␣is␣needed␣between
a␣block␣quote␣and␣a␣following␣paragraph:


=== got ====================
<blockquote>
<p>aaa</p>
</blockquote>
<hr␣/>
<blockquote>
<p>bbb</p>
</blockquote>

Test #147
cross
=== markdown ===============
<blockquote>
<p>bar
baz</p>
</blockquote>

=== expected ===============


=== got ====================
<blockquote>
<p>bar
baz</p>
</blockquote>

Test #148
cross
=== markdown ===============
<blockquote>
<p>bar</p>
</blockquote>
<p>baz</p>

=== expected ===============


=== got ====================
<blockquote>
<p>bar</p>
</blockquote>
<p>baz</p>

Test #149
cross
=== markdown ===============
<blockquote>
<p>bar</p>
</blockquote>
<p>baz</p>

=== expected ===============

It␣is␣a␣consequence␣of␣the␣Laziness␣rule␣that␣any␣number
of␣initial␣`>`s␣may␣be␣omitted␣on␣a␣continuation␣line␣of␣a
nested␣block␣quote:


=== got ====================
<blockquote>
<p>bar</p>
</blockquote>
<p>baz</p>

Test #150
cross
=== markdown ===============
<blockquote>
<blockquote>
<blockquote>
<p>foo
bar</p>
</blockquote>
</blockquote>
</blockquote>

=== expected ===============


=== got ====================
<blockquote>
<blockquote>
<blockquote>
<p>foo
bar</p>
</blockquote>
</blockquote>
</blockquote>

Test #151
cross
=== markdown ===============
<blockquote>
<blockquote>
<blockquote>
<p>foo
bar
baz</p>
</blockquote>
</blockquote>
</blockquote>

=== expected ===============

When␣including␣an␣indented␣code␣block␣in␣a␣block␣quote,
remember␣that␣the␣[block␣quote␣marker](#block-quote-marker)␣includes
both␣the␣`>`␣and␣a␣following␣space.␣␣So␣*five␣spaces*␣are␣needed␣after
the␣`>`:


=== got ====================
<blockquote>
<blockquote>
<blockquote>
<p>foo
bar
baz</p>
</blockquote>
</blockquote>
</blockquote>

Test #152
cross
=== markdown ===============
<blockquote>
<pre><code>code
</code></pre>
</blockquote>
<blockquote>
<p>not␣code</p>
</blockquote>

=== expected ===============


##␣List␣items

A␣[list␣marker](#list-marker)␣<a␣id="list-marker"></a>␣is␣a
[bullet␣list␣marker](#bullet-list-marker)␣or␣an␣[ordered␣list
marker](#ordered-list-marker).

A␣[bullet␣list␣marker](#bullet-list-marker)␣<a␣id="bullet-list-marker"></a>
is␣a␣`-`,␣`+`,␣or␣`*`␣character.

An␣[ordered␣list␣marker](#ordered-list-marker)␣<a␣id="ordered-list-marker"></a>
is␣a␣sequence␣of␣one␣of␣more␣digits␣(`0-9`),␣followed␣by␣either␣a
`.`␣character␣or␣a␣`)`␣character.

The␣following␣rules␣define␣[list␣items](#list-item):

1.␣␣**Basic␣case.**␣␣If␣a␣sequence␣of␣lines␣*Ls*␣constitute␣a␣sequence␣of
␣␣␣␣blocks␣*Bs*␣starting␣with␣a␣non-space␣character␣and␣not␣separated
␣␣␣␣from␣each␣other␣by␣more␣than␣one␣blank␣line,␣and␣*M*␣is␣a␣list
␣␣␣␣marker␣*M*␣of␣width␣*W*␣followed␣by␣0␣<␣*N*␣<␣5␣spaces,␣then␣the␣result
␣␣␣␣of␣prepending␣*M*␣and␣the␣following␣spaces␣to␣the␣first␣line␣of
␣␣␣␣*Ls*,␣and␣indenting␣subsequent␣lines␣of␣*Ls*␣by␣*W␣+␣N*␣spaces,␣is␣a
␣␣␣␣list␣item␣with␣*Bs*␣as␣its␣contents.␣␣The␣type␣of␣the␣list␣item
␣␣␣␣(bullet␣or␣ordered)␣is␣determined␣by␣the␣type␣of␣its␣list␣marker.
␣␣␣␣If␣the␣list␣item␣is␣ordered,␣then␣it␣is␣also␣assigned␣a␣start
␣␣␣␣number,␣based␣on␣the␣ordered␣list␣marker.

For␣example,␣let␣*Ls*␣be␣the␣lines


=== got ====================
<blockquote>
<pre><code>code
</code></pre>
</blockquote>
<blockquote>
<p>not␣code</p>
</blockquote>

Test #153
cross
=== markdown ===============
<p>A␣paragraph
with␣two␣lines.</p>
<pre><code>indented␣code
</code></pre>
<blockquote>
<p>A␣block␣quote.</p>
</blockquote>

=== expected ===============

And␣let␣*M*␣be␣the␣marker␣`1.`,␣and␣*N*␣=␣2.␣␣Then␣rule␣#1␣says
that␣the␣following␣is␣an␣ordered␣list␣item␣with␣start␣number␣1,
and␣the␣same␣contents␣as␣*Ls*:


=== got ====================
<p>A␣paragraph
with␣two␣lines.</p>
<pre><code>indented␣code
</code></pre>
<blockquote>
<p>A␣block␣quote.</p>
</blockquote>

Test #154
cross
=== markdown ===============
<ol>
<li><p>A␣paragraph
with␣two␣lines.</p>
<pre><code>indented␣code
</code></pre>
<blockquote>
<p>A␣block␣quote.</p>
</blockquote></li>
</ol>

=== expected ===============

The␣most␣important␣thing␣to␣notice␣is␣that␣the␣position␣of
the␣text␣after␣the␣list␣marker␣determines␣how␣much␣indentation
is␣needed␣in␣subsequent␣blocks␣in␣the␣list␣item.␣␣If␣the␣list
marker␣takes␣up␣two␣spaces,␣and␣there␣are␣three␣spaces␣between
the␣list␣marker␣and␣the␣next␣nonspace␣character,␣then␣blocks
must␣be␣indented␣five␣spaces␣in␣order␣to␣fall␣under␣the␣list
item.

Here␣are␣some␣examples␣showing␣how␣far␣content␣must␣be␣indented␣to␣be
put␣under␣the␣list␣item:


=== got ====================
<ol>
<li><p>A␣paragraph
with␣two␣lines.</p>
<pre><code>indented␣code
</code></pre>
<blockquote>
<p>A␣block␣quote.</p>
</blockquote></li>
</ol>

Test #155
cross
=== markdown ===============
<ul>
<li>one</li>
</ul>
<p>two</p>

=== expected ===============


=== got ====================
<ul>
<li>one</li>
</ul>
<p>two</p>

Test #156
cross
=== markdown ===============
<ul>
<li><p>one</p>
<p>two</p></li>
</ul>

=== expected ===============


=== got ====================
<ul>
<li><p>one</p>
<p>two</p></li>
</ul>

Test #157
cross
=== markdown ===============
<ul>
<li>one</li>
</ul>
<pre><code>␣two
</code></pre>

=== expected ===============


=== got ====================
<ul>
<li>one</li>
</ul>
<pre><code>␣two
</code></pre>

Test #158
cross
=== markdown ===============
<ul>
<li><p>one</p>
<p>two</p></li>
</ul>

=== expected ===============

It␣is␣tempting␣to␣think␣of␣this␣in␣terms␣of␣columns:␣␣the␣continuation
blocks␣must␣be␣indented␣at␣least␣to␣the␣column␣of␣the␣first␣nonspace
character␣after␣the␣list␣marker.␣␣However,␣that␣is␣not␣quite␣right.
The␣spaces␣after␣the␣list␣marker␣determine␣how␣much␣relative␣indentation
is␣needed.␣␣Which␣column␣this␣indentation␣reaches␣will␣depend␣on
how␣the␣list␣item␣is␣embedded␣in␣other␣constructions,␣as␣shown␣by
this␣example:


=== got ====================
<ul>
<li><p>one</p>
<p>two</p></li>
</ul>

Test #159
cross
=== markdown ===============
<blockquote>
<blockquote>
<ol>
<li><p>one</p>
<p>two</p></li>
</ol>
</blockquote>
</blockquote>

=== expected ===============

Here␣`two`␣occurs␣in␣the␣same␣column␣as␣the␣list␣marker␣`1.`,
but␣is␣actually␣contained␣in␣the␣list␣item,␣because␣there␣is
sufficent␣indentation␣after␣the␣last␣containing␣blockquote␣marker.

The␣converse␣is␣also␣possible.␣␣In␣the␣following␣example,␣the␣word␣`two`
occurs␣far␣to␣the␣right␣of␣the␣initial␣text␣of␣the␣list␣item,␣`one`,␣but
it␣is␣not␣considered␣part␣of␣the␣list␣item,␣because␣it␣is␣not␣indented
far␣enough␣past␣the␣blockquote␣marker:


=== got ====================
<blockquote>
<blockquote>
<ol>
<li><p>one</p>
<p>two</p></li>
</ol>
</blockquote>
</blockquote>

Test #160
cross
=== markdown ===============
<blockquote>
<blockquote>
<ul>
<li>one</li>
</ul>
<p>two</p>
</blockquote>
</blockquote>

=== expected ===============

A␣list␣item␣may␣not␣contain␣blocks␣that␣are␣separated␣by␣more␣than
one␣blank␣line.␣␣Thus,␣two␣blank␣lines␣will␣end␣a␣list,␣unless␣the
two␣blanks␣are␣contained␣in␣a␣[fenced␣code␣block](#fenced-code-block).


=== got ====================
<blockquote>
<blockquote>
<ul>
<li>one</li>
</ul>
<p>two</p>
</blockquote>
</blockquote>

Test #161
cross
=== markdown ===============
<ul>
<li><p>foo</p>
<p>bar</p></li>
<li><p>foo</p></li>
</ul>
<p>bar</p>
<ul>
<li><pre><code>foo


bar
</code></pre></li>
</ul>

=== expected ===============

A␣list␣item␣may␣contain␣any␣kind␣of␣block:


=== got ====================
<ul>
<li><p>foo</p>
<p>bar</p></li>
<li><p>foo</p></li>
</ul>
<p>bar</p>
<ul>
<li><pre><code>foo
<p>bar
</code></pre></li></p>
</ul>

Test #162
cross
=== markdown ===============
<ol>
<li><p>foo</p>
<pre><code>bar
</code></pre>
<p>baz</p>
<blockquote>
<p>bam</p>
</blockquote></li>
</ol>

=== expected ===============

2.␣␣**Item␣starting␣with␣indented␣code.**␣␣If␣a␣sequence␣of␣lines␣*Ls*
␣␣␣␣constitute␣a␣sequence␣of␣blocks␣*Bs*␣starting␣with␣an␣indented␣code
␣␣␣␣block␣and␣not␣separated␣from␣each␣other␣by␣more␣than␣one␣blank␣line,
␣␣␣␣and␣*M*␣is␣a␣list␣marker␣*M*␣of␣width␣*W*␣followed␣by
␣␣␣␣one␣space,␣then␣the␣result␣of␣prepending␣*M*␣and␣the␣following
␣␣␣␣space␣to␣the␣first␣line␣of␣*Ls*,␣and␣indenting␣subsequent␣lines␣of
␣␣␣␣*Ls*␣by␣*W␣+␣1*␣spaces,␣is␣a␣list␣item␣with␣*Bs*␣as␣its␣contents.
␣␣␣␣If␣a␣line␣is␣empty,␣then␣it␣need␣not␣be␣indented.␣␣The␣type␣of␣the
␣␣␣␣list␣item␣(bullet␣or␣ordered)␣is␣determined␣by␣the␣type␣of␣its␣list
␣␣␣␣marker.␣␣If␣the␣list␣item␣is␣ordered,␣then␣it␣is␣also␣assigned␣a
␣␣␣␣start␣number,␣based␣on␣the␣ordered␣list␣marker.

An␣indented␣code␣block␣will␣have␣to␣be␣indented␣four␣spaces␣beyond
the␣edge␣of␣the␣region␣where␣text␣will␣be␣included␣in␣the␣list␣item.
In␣the␣following␣case␣that␣is␣6␣spaces:


=== got ====================
<ol>
<li><p>foo</p>
<pre><code>bar
</code></pre>
<p>baz</p>
<blockquote>
<p>bam</p>
</blockquote></li>
</ol>

Test #163
cross
=== markdown ===============
<ul>
<li><p>foo</p>
<pre><code>bar
</code></pre></li>
</ul>

=== expected ===============

And␣in␣this␣case␣it␣is␣11␣spaces:


=== got ====================
<ul>
<li><p>foo</p>
<pre><code>bar
</code></pre></li>
</ul>

Test #164
cross
=== markdown ===============
<ol␣start="10">
<li><p>foo</p>
<pre><code>bar
</code></pre></li>
</ol>

=== expected ===============

If␣the␣*first*␣block␣in␣the␣list␣item␣is␣an␣indented␣code␣block,
then␣by␣rule␣#2,␣the␣contents␣must␣be␣indented␣*one*␣space␣after␣the
list␣marker:


=== got ====================
<ol␣start="10">
<li><p>foo</p>
<pre><code>bar
</code></pre></li>
</ol>

Test #165
cross
=== markdown ===============
<pre><code>indented␣code
</code></pre>
<p>paragraph</p>
<pre><code>more␣code
</code></pre>

=== expected ===============


=== got ====================
<pre><code>indented␣code
</code></pre>
<p>paragraph</p>
<pre><code>more␣code
</code></pre>

Test #166
cross
=== markdown ===============
<ol>
<li><pre><code>indented␣code
</code></pre>
<p>paragraph</p>
<pre><code>more␣code
</code></pre></li>
</ol>

=== expected ===============

Note␣that␣an␣additional␣space␣indent␣is␣interpreted␣as␣space
inside␣the␣code␣block:


=== got ====================
<ol>
<li><pre><code>indented␣code
</code></pre>
<p>paragraph</p>
<pre><code>more␣code
</code></pre></li>
</ol>

Test #167
cross
=== markdown ===============
<ol>
<li><pre><code>␣indented␣code
</code></pre>
<p>paragraph</p>
<pre><code>more␣code
</code></pre></li>
</ol>

=== expected ===============

Note␣that␣rules␣#1␣and␣#2␣only␣apply␣to␣two␣cases:␣␣(a)␣cases
in␣which␣the␣lines␣to␣be␣included␣in␣a␣list␣item␣begin␣with␣a␣nonspace
character,␣and␣(b)␣cases␣in␣which␣they␣begin␣with␣an␣indented␣code
block.␣␣In␣a␣case␣like␣the␣following,␣where␣the␣first␣block␣begins␣with
a␣three-space␣indent,␣the␣rules␣do␣not␣allow␣us␣to␣form␣a␣list␣item␣by
indenting␣the␣whole␣thing␣and␣prepending␣a␣list␣marker:


=== got ====================
<ol>
<li><pre><code>␣indented␣code
</code></pre>
<p>paragraph</p>
<pre><code>more␣code
</code></pre></li>
</ol>

Test #168
cross
=== markdown ===============
<p>foo</p>
<p>bar</p>

=== expected ===============


=== got ====================
<p>foo</p>
<p>bar</p>

Test #169
cross
=== markdown ===============
<ul>
<li>foo</li>
</ul>
<p>bar</p>

=== expected ===============

This␣is␣not␣a␣significant␣restriction,␣because␣when␣a␣block␣begins
with␣1-3␣spaces␣indent,␣the␣indentation␣can␣always␣be␣removed␣without
a␣change␣in␣interpretation,␣allowing␣rule␣#1␣to␣be␣applied.␣␣So,␣in
the␣above␣case:


=== got ====================
<ul>
<li>foo</li>
</ul>
<p>bar</p>

Test #170
cross
=== markdown ===============
<ul>
<li><p>foo</p>
<p>bar</p></li>
</ul>

=== expected ===============


3.␣␣**Indentation.**␣␣If␣a␣sequence␣of␣lines␣*Ls*␣constitutes␣a␣list␣item
␣␣␣␣according␣to␣rule␣#1␣or␣#2,␣then␣the␣result␣of␣indenting␣each␣line
␣␣␣␣of␣*L*␣by␣1-3␣spaces␣(the␣same␣for␣each␣line)␣also␣constitutes␣a
␣␣␣␣list␣item␣with␣the␣same␣contents␣and␣attributes.␣␣If␣a␣line␣is
␣␣␣␣empty,␣then␣it␣need␣not␣be␣indented.

Indented␣one␣space:


=== got ====================
<ul>
<li><p>foo</p>
<p>bar</p></li>
</ul>

Test #171
cross
=== markdown ===============
<ol>
<li><p>A␣paragraph
with␣two␣lines.</p>
<pre><code>indented␣code
</code></pre>
<blockquote>
<p>A␣block␣quote.</p>
</blockquote></li>
</ol>

=== expected ===============

Indented␣two␣spaces:


=== got ====================
<ol>
<li><p>A␣paragraph
with␣two␣lines.</p>
<pre><code>indented␣code
</code></pre>
<blockquote>
<p>A␣block␣quote.</p>
</blockquote></li>
</ol>

Test #172
cross
=== markdown ===============
<ol>
<li><p>A␣paragraph
with␣two␣lines.</p>
<pre><code>indented␣code
</code></pre>
<blockquote>
<p>A␣block␣quote.</p>
</blockquote></li>
</ol>

=== expected ===============

Indented␣three␣spaces:


=== got ====================
<ol>
<li><p>A␣paragraph
with␣two␣lines.</p>
<pre><code>indented␣code
</code></pre>
<blockquote>
<p>A␣block␣quote.</p>
</blockquote></li>
</ol>

Test #173
cross
=== markdown ===============
<ol>
<li><p>A␣paragraph
with␣two␣lines.</p>
<pre><code>indented␣code
</code></pre>
<blockquote>
<p>A␣block␣quote.</p>
</blockquote></li>
</ol>

=== expected ===============

Four␣spaces␣indent␣gives␣a␣code␣block:


=== got ====================
<ol>
<li><p>A␣paragraph
with␣two␣lines.</p>
<pre><code>indented␣code
</code></pre>
<blockquote>
<p>A␣block␣quote.</p>
</blockquote></li>
</ol>

Test #174
cross
=== markdown ===============
<pre><code>1.␣␣A␣paragraph
␣␣␣␣with␣two␣lines.

␣␣␣␣␣␣␣␣indented␣code

␣␣␣␣&gt;␣A␣block␣quote.
</code></pre>

=== expected ===============


4.␣␣**Laziness.**␣␣If␣a␣string␣of␣lines␣*Ls*␣constitute␣a␣[list
␣␣␣␣item](#list-item)␣with␣contents␣*Bs*,␣then␣the␣result␣of␣deleting
␣␣␣␣some␣or␣all␣of␣the␣indentation␣from␣one␣or␣more␣lines␣in␣which␣the
␣␣␣␣next␣non-space␣character␣after␣the␣indentation␣is
␣␣␣␣[paragraph␣continuation␣text](#paragraph-continuation-text)␣is␣a
␣␣␣␣list␣item␣with␣the␣same␣contents␣and␣attributes.

Here␣is␣an␣example␣with␣lazy␣continuation␣lines:


=== got ====================
<pre><code>1.␣␣A␣paragraph
␣␣␣␣with␣two␣lines.
<pre><code>␣␣␣␣indented␣code

&amp;gt;␣A␣block␣quote.
</code></pre>
<p></code></pre></p>

Test #175
cross
=== markdown ===============
<ol>
<li><p>A␣paragraph
with␣two␣lines.</p>
<pre><code>indented␣code
</code></pre>
<blockquote>
<p>A␣block␣quote.</p>
</blockquote></li>
</ol>

=== expected ===============

Indentation␣can␣be␣partially␣deleted:


=== got ====================
<ol>
<li><p>A␣paragraph
with␣two␣lines.</p>
<pre><code>indented␣code
</code></pre>
<blockquote>
<p>A␣block␣quote.</p>
</blockquote></li>
</ol>

Test #176
cross
=== markdown ===============
<ol>
<li>A␣paragraph
with␣two␣lines.</li>
</ol>

=== expected ===============

These␣examples␣show␣how␣laziness␣can␣work␣in␣nested␣structures:


=== got ====================
<ol>
<li>A␣paragraph
with␣two␣lines.</li>
</ol>

Test #177
cross
=== markdown ===============
<blockquote>
<ol>
<li><blockquote>
<p>Blockquote
continued␣here.</p>
</blockquote></li>
</ol>
</blockquote>

=== expected ===============


=== got ====================
<blockquote>
<ol>
<li><blockquote>
<p>Blockquote
continued␣here.</p>
</blockquote></li>
</ol>
</blockquote>

Test #178
cross
=== markdown ===============
<blockquote>
<ol>
<li><blockquote>
<p>Blockquote
continued␣here.</p>
</blockquote></li>
</ol>
</blockquote>

=== expected ===============


5.␣␣**That's␣all.**␣Nothing␣that␣is␣not␣counted␣as␣a␣list␣item␣by␣rules
␣␣␣␣#1--4␣counts␣as␣a␣[list␣item](#list-item).

The␣rules␣for␣sublists␣follow␣from␣the␣general␣rules␣above.␣␣A␣sublist
must␣be␣indented␣the␣same␣number␣of␣spaces␣a␣paragraph␣would␣need␣to␣be
in␣order␣to␣be␣included␣in␣the␣list␣item.

So,␣in␣this␣case␣we␣need␣two␣spaces␣indent:


=== got ====================
<blockquote>
<ol>
<li><blockquote>
<p>Blockquote
continued␣here.</p>
</blockquote></li>
</ol>
</blockquote>

Test #179
cross
=== markdown ===============
<ul>
<li>foo
<ul>
<li>bar
<ul>
<li>baz</li>
</ul></li>
</ul></li>
</ul>

=== expected ===============

One␣is␣not␣enough:


=== got ====================
<ul>
<li>foo
<ul>
<li>bar
<ul>
<li>baz</li>
</ul></li>
</ul></li>
</ul>

Test #180
cross
=== markdown ===============
<ul>
<li>foo</li>
<li>bar</li>
<li>baz</li>
</ul>

=== expected ===============

Here␣we␣need␣four,␣because␣the␣list␣marker␣is␣wider:


=== got ====================
<ul>
<li>foo</li>
<li>bar</li>
<li>baz</li>
</ul>

Test #181
cross
=== markdown ===============
<ol␣start="10">
<li>foo
<ul>
<li>bar</li>
</ul></li>
</ol>

=== expected ===============

Three␣is␣not␣enough:


=== got ====================
<ol␣start="10">
<li>foo
<ul>
<li>bar</li>
</ul></li>
</ol>

Test #182
cross
=== markdown ===============
<ol␣start="10">
<li>foo</li>
</ol>
<ul>
<li>bar</li>
</ul>

=== expected ===============

A␣list␣may␣be␣the␣first␣block␣in␣a␣list␣item:


=== got ====================
<ol␣start="10">
<li>foo</li>
</ol>
<ul>
<li>bar</li>
</ul>

Test #183
cross
=== markdown ===============
<ul>
<li><ul>
<li>foo</li>
</ul></li>
</ul>

=== expected ===============


=== got ====================
<ul>
<li><ul>
<li>foo</li>
</ul></li>
</ul>

Test #184
cross
=== markdown ===============
<ol>
<li><ul>
<li><ol␣start="2">
<li>foo</li>
</ol></li>
</ul></li>
</ol>

=== expected ===============

A␣list␣item␣may␣be␣empty:


=== got ====================
<ol>
<li><ul>
<li><ol␣start="2">
<li>foo</li>
</ol></li>
</ul></li>
</ol>

Test #185
cross
=== markdown ===============
<ul>
<li>foo</li>
<li></li>
<li>bar</li>
</ul>

=== expected ===============


=== got ====================
<ul>
<li>foo</li>
<li></li>
<li>bar</li>
</ul>

Test #186
cross
=== markdown ===============
<ul>
<li></li>
</ul>

=== expected ===============

###␣Motivation

John␣Gruber's␣Markdown␣spec␣says␣the␣following␣about␣list␣items:

1.␣"List␣markers␣typically␣start␣at␣the␣left␣margin,␣but␣may␣be␣indented
␣␣␣by␣up␣to␣three␣spaces.␣List␣markers␣must␣be␣followed␣by␣one␣or␣more
␣␣␣spaces␣or␣a␣tab."

2.␣"To␣make␣lists␣look␣nice,␣you␣can␣wrap␣items␣with␣hanging␣indents....
␣␣␣But␣if␣you␣don't␣want␣to,␣you␣don't␣have␣to."

3.␣"List␣items␣may␣consist␣of␣multiple␣paragraphs.␣Each␣subsequent
␣␣␣paragraph␣in␣a␣list␣item␣must␣be␣indented␣by␣either␣4␣spaces␣or␣one
␣␣␣tab."

4.␣"It␣looks␣nice␣if␣you␣indent␣every␣line␣of␣the␣subsequent␣paragraphs,
␣␣␣but␣here␣again,␣Markdown␣will␣allow␣you␣to␣be␣lazy."

5.␣"To␣put␣a␣blockquote␣within␣a␣list␣item,␣the␣blockquote's␣`>`
␣␣␣delimiters␣need␣to␣be␣indented."

6.␣"To␣put␣a␣code␣block␣within␣a␣list␣item,␣the␣code␣block␣needs␣to␣be
␣␣␣indented␣twice␣—␣8␣spaces␣or␣two␣tabs."

These␣rules␣specify␣that␣a␣paragraph␣under␣a␣list␣item␣must␣be␣indented
four␣spaces␣(presumably,␣from␣the␣left␣margin,␣rather␣than␣the␣start␣of
the␣list␣marker,␣but␣this␣is␣not␣said),␣and␣that␣code␣under␣a␣list␣item
must␣be␣indented␣eight␣spaces␣instead␣of␣the␣usual␣four.␣␣They␣also␣say
that␣a␣block␣quote␣must␣be␣indented,␣but␣not␣by␣how␣much;␣however,␣the
example␣given␣has␣four␣spaces␣indentation.␣␣Although␣nothing␣is␣said
about␣other␣kinds␣of␣block-level␣content,␣it␣is␣certainly␣reasonable␣to
infer␣that␣*all*␣block␣elements␣under␣a␣list␣item,␣including␣other
lists,␣must␣be␣indented␣four␣spaces.␣␣This␣principle␣has␣been␣called␣the
*four-space␣rule*.

The␣four-space␣rule␣is␣clear␣and␣principled,␣and␣if␣the␣reference
implementation␣`Markdown.pl`␣had␣followed␣it,␣it␣probably␣would␣have
become␣the␣standard.␣␣However,␣`Markdown.pl`␣allowed␣paragraphs␣and
sublists␣to␣start␣with␣only␣two␣spaces␣indentation,␣at␣least␣on␣the
outer␣level.␣␣Worse,␣its␣behavior␣was␣inconsistent:␣a␣sublist␣of␣an
outer-level␣list␣needed␣two␣spaces␣indentation,␣but␣a␣sublist␣of␣this
sublist␣needed␣three␣spaces.␣␣It␣is␣not␣surprising,␣then,␣that␣different
implementations␣of␣Markdown␣have␣developed␣very␣different␣rules␣for
determining␣what␣comes␣under␣a␣list␣item.␣␣(Pandoc␣and␣python-Markdown,
for␣example,␣stuck␣with␣Gruber's␣syntax␣description␣and␣the␣four-space
rule,␣while␣discount,␣redcarpet,␣marked,␣PHP␣Markdown,␣and␣others
followed␣`Markdown.pl`'s␣behavior␣more␣closely.)

Unfortunately,␣given␣the␣divergences␣between␣implementations,␣there
is␣no␣way␣to␣give␣a␣spec␣for␣list␣items␣that␣will␣be␣guaranteed␣not
to␣break␣any␣existing␣documents.␣␣However,␣the␣spec␣given␣here␣should
correctly␣handle␣lists␣formatted␣with␣either␣the␣four-space␣rule␣or
the␣more␣forgiving␣`Markdown.pl`␣behavior,␣provided␣they␣are␣laid␣out
in␣a␣way␣that␣is␣natural␣for␣a␣human␣to␣read.

The␣strategy␣here␣is␣to␣let␣the␣width␣and␣indentation␣of␣the␣list␣marker
determine␣the␣indentation␣necessary␣for␣blocks␣to␣fall␣under␣the␣list
item,␣rather␣than␣having␣a␣fixed␣and␣arbitrary␣number.␣␣The␣writer␣can
think␣of␣the␣body␣of␣the␣list␣item␣as␣a␣unit␣which␣gets␣indented␣to␣the
right␣enough␣to␣fit␣the␣list␣marker␣(and␣any␣indentation␣on␣the␣list
marker).␣␣(The␣laziness␣rule,␣#4,␣then␣allows␣continuation␣lines␣to␣be
unindented␣if␣needed.)

This␣rule␣is␣superior,␣we␣claim,␣to␣any␣rule␣requiring␣a␣fixed␣level␣of
indentation␣from␣the␣margin.␣␣The␣four-space␣rule␣is␣clear␣but
unnatural.␣It␣is␣quite␣unintuitive␣that

```␣markdown
-␣foo

␣␣bar

␣␣-␣baz
```

should␣be␣parsed␣as␣two␣lists␣with␣an␣intervening␣paragraph,

```␣html
<ul>
<li>foo</li>
</ul>
<p>bar</p>
<ul>
<li>baz</li>
</ul>
```

as␣the␣four-space␣rule␣demands,␣rather␣than␣a␣single␣list,

```␣html
<ul>
<li><p>foo</p>
<p>bar</p>
<ul>
<li>baz</li>
</ul></li>
</ul>
```

The␣choice␣of␣four␣spaces␣is␣arbitrary.␣␣It␣can␣be␣learned,␣but␣it␣is
not␣likely␣to␣be␣guessed,␣and␣it␣trips␣up␣beginners␣regularly.

Would␣it␣help␣to␣adopt␣a␣two-space␣rule?␣␣The␣problem␣is␣that␣such
a␣rule,␣together␣with␣the␣rule␣allowing␣1--3␣spaces␣indentation␣of␣the
initial␣list␣marker,␣allows␣text␣that␣is␣indented␣*less␣than*␣the
original␣list␣marker␣to␣be␣included␣in␣the␣list␣item.␣For␣example,
`Markdown.pl`␣parses

```␣markdown
␣␣␣-␣one

␣␣two
```

as␣a␣single␣list␣item,␣with␣`two`␣a␣continuation␣paragraph:

```␣html
<ul>
<li><p>one</p>
<p>two</p></li>
</ul>
```

and␣similarly

```␣markdown
>␣␣␣-␣one

=== got ====================
<ul>
<li></li>
</ul>

[Lists]
Test #187
tick
Test #188
tick
Test #189
tick
Test #190
tick
Test #191
tick
Test #192
tick
Test #193
tick
Test #194
tick
Test #195
tick
Test #196
tick
Test #197
tick
Test #198
tick
Test #199
tick
Test #200
tick
Test #201
tick
Test #202
tick
Test #203
tick
Test #204
tick
Test #205
tick
Test #206
tick
[Inlines]
Test #207
tick
[Backslash escapes]
Test #208
tick
Test #209
tick
Test #210
tick
Test #211
tick
Test #212
tick
Test #213
tick
Test #214
tick
Test #215
tick
Test #216
tick
Test #217
tick
Test #218
tick
Test #219
tick
Test #220
tick
[Entities]
Test #221
tick
Test #222
tick
Test #223
tick
Test #224
tick
Test #225
tick
Test #226
tick
Test #227
tick
Test #228
tick
Test #229
tick
Test #230
tick
Test #231
tick
Test #232
tick
[Code span]
Test #233
tick
Test #234
tick
Test #235
tick
Test #236
tick
Test #237
tick
Test #238
tick
Test #239
tick
Test #240
tick
Test #241
tick
Test #242
tick
Test #243
tick
Test #244
tick
Test #245
tick
[Emphasis and strong emphasis]
Test #246
tick
Test #247
tick
Test #248
tick
Test #249
tick
Test #250
tick
Test #251
tick
Test #252
tick
Test #253
tick
Test #254
tick
Test #255
tick
Test #256
tick
Test #257
tick
Test #258
tick
Test #259
tick
Test #260
tick
Test #261
tick
Test #262
tick
Test #263
tick
Test #264
tick
Test #265
tick
Test #266
tick
Test #267
tick
Test #268
tick
Test #269
tick
Test #270
tick
Test #271
tick
Test #272
tick
Test #273
tick
Test #274
tick
Test #275
tick
Test #276
tick
Test #277
tick
Test #278
tick
Test #279
tick
Test #280
tick
Test #281
tick
Test #282
tick
Test #283
tick
Test #284
tick
Test #285
tick
Test #286
tick
Test #287
tick
Test #288
tick
Test #289
tick
Test #290
tick
Test #291
tick
Test #292
tick
Test #293
tick
Test #294
tick
Test #295
tick
Test #296
tick
Test #297
tick
Test #298
tick
Test #299
tick
Test #300
tick
Test #301
tick
Test #302
tick
Test #303
tick
Test #304
tick
Test #305
tick
Test #306
tick
Test #307
tick
Test #308
tick
Test #309
tick
Test #310
tick
Test #311
tick
Test #312
tick
Test #313
tick
Test #314
tick
Test #315
tick
Test #316
tick
Test #317
tick
Test #318
tick
Test #319
tick
Test #320
tick
Test #321
tick
Test #322
tick
Test #323
tick
Test #324
tick
Test #325
tick
Test #326
tick
Test #327
tick
[Links]
Test #328
tick
Test #329
tick
Test #330
tick
Test #331
tick
Test #332
tick
Test #333
tick
Test #334
tick
Test #335
tick
Test #336
tick
Test #337
tick
Test #338
tick
Test #339
tick
Test #340
tick
Test #341
tick
Test #342
tick
Test #343
tick
Test #344
tick
Test #345
tick
Test #346
tick
Test #347
tick
Test #348
tick
Test #349
tick
Test #350
tick
Test #351
tick
Test #352
tick
Test #353
tick
Test #354
tick
Test #355
tick
Test #356
tick
Test #357
tick
Test #358
tick
Test #359
tick
Test #360
tick
Test #361
tick
Test #362
tick
Test #363
tick
Test #364
tick
Test #365
tick
Test #366
tick
Test #367
tick
Test #368
tick
Test #369
tick
Test #370
tick
Test #371
tick
Test #372
tick
Test #373
tick
Test #374
tick
Test #375
tick
[Images]
Test #376
tick
Test #377
tick
Test #378
tick
Test #379
tick
Test #380
tick
Test #381
tick
Test #382
tick
Test #383
tick
Test #384
tick
Test #385
tick
Test #386
tick
Test #387
tick
Test #388
tick
Test #389
tick
Test #390
tick
Test #391
tick
Test #392
tick
Test #393
tick
Test #394
tick
Test #395
tick
[Autolinks]
Test #396
tick
Test #397
tick
Test #398
tick
Test #399
tick
Test #400
tick
Test #401
tick
Test #402
tick
Test #403
tick
Test #404
tick
Test #405
tick
Test #406
tick
Test #407
tick
Test #408
tick
Test #409
tick
[Raw HTML]
Test #410
tick
Test #411
tick
Test #412
tick
Test #413
tick
Test #414
tick
Test #415
tick
Test #416
tick
Test #417
tick
Test #418
tick
Test #419
tick
Test #420
tick
Test #421
tick
Test #422
tick
Test #423
tick
Test #424
tick
Test #425
tick
Test #426
tick
Test #427
tick
Test #428
tick
[Hard line breaks]
Test #429
tick
Test #430
tick
Test #431
tick
Test #432
tick
Test #433
tick
Test #434
tick
Test #435
tick
Test #436
tick
Test #437
tick
Test #438
tick
Test #439
tick
[Soft line breaks]
Test #440
tick
Test #441
tick
[Strings]
Test #442
tick
Test #443
tick
Test #444
tick
349 tests passed, 95 failed
runtime: 0.109322742s
make[1]: Leaving directory '/build/reproducible-path/commonmark-bkrs-0.5.4+ds'
   create-stamp debian/debhelper-build-stamp
   dh_testroot -O--buildsystem=pybuild
   dh_prep -O--buildsystem=pybuild
   dh_auto_install -O--buildsystem=pybuild
I: pybuild base:311: /usr/bin/python3 setup.py install --root /build/reproducible-path/commonmark-bkrs-0.5.4+ds/debian/tmp 
/usr/lib/python3/dist-packages/setuptools/_distutils/cmd.py:79: SetuptoolsDeprecationWarning: setup.py install is deprecated.
!!

        ********************************************************************************
        Please avoid running ``setup.py`` directly.
        Instead, use pypa/build, pypa/installer or other
        standards-based tools.

        See https://blog.ganssle.io/articles/2021/10/setup-py-deprecated.html for details.
        ********************************************************************************

!!
  self.initialize_options()
/usr/lib/python3.13/dist-packages/CommonMark_bkrs/CommonMark.py:186: SyntaxWarning: invalid escape sequence '\s'
/usr/lib/python3.13/dist-packages/CommonMark_bkrs/CommonMark.py:338: SyntaxWarning: invalid escape sequence '\/'
/usr/lib/python3.13/dist-packages/CommonMark_bkrs/CommonMark.py:385: SyntaxWarning: invalid escape sequence '\s'
/usr/lib/python3.13/dist-packages/CommonMark_bkrs/CommonMark.py:387: SyntaxWarning: invalid escape sequence '\s'
/usr/lib/python3.13/dist-packages/CommonMark_bkrs/CommonMark.py:1008: SyntaxWarning: invalid escape sequence '\g'
warning: no files found matching '.gitignore'
I: pybuild pybuild:334: LC_ALL=C PYTHONPATH=/build/reproducible-path/commonmark-bkrs-0.5.4+ds/.pybuild/cpython3_3.13/build help2man --manual="CommonMark Python package (Bibek Kafle and Roland Shoemaker)" --source="CMark-BKRS (Debian 0.5.4+ds-7.1)" --version-string="CMark-BKRS - 0.5.4+ds-7.1" --no-info -s 1 -I debian/man/cmark-bkrs.h2m -n "pure Python script parser for the CommonMark Markdown spec" -o build/scripts-3.13/cmark-bkrs.1 debian/adhoc/wrappers/python3/cmark-bkrs
   dh_install -O--buildsystem=pybuild
   debian/rules override_dh_installdocs
make[1]: Entering directory '/build/reproducible-path/commonmark-bkrs-0.5.4+ds'
dh_installdocs --all debian/README.Debian
dh_installdocs: warning: Cannot auto-detect main package for python-commonmark-bkrs-doc.  If the default is wrong, please use --doc-main-package
make[1]: Leaving directory '/build/reproducible-path/commonmark-bkrs-0.5.4+ds'
   dh_installchangelogs -O--buildsystem=pybuild
   dh_installexamples -O--buildsystem=pybuild
dh_installexamples: warning: Cannot auto-detect main package for python-commonmark-bkrs-doc.  If the default is wrong, please use --doc-main-package
   dh_installman -O--buildsystem=pybuild
   dh_python3 -O--buildsystem=pybuild
   dh_installinit -O--buildsystem=pybuild
   dh_installsystemduser -O--buildsystem=pybuild
   dh_lintian -O--buildsystem=pybuild
   dh_perl -O--buildsystem=pybuild
   dh_link -O--buildsystem=pybuild
   dh_strip_nondeterminism -O--buildsystem=pybuild
   debian/rules override_dh_compress
make[1]: Entering directory '/build/reproducible-path/commonmark-bkrs-0.5.4+ds'
dh_compress -XREADME.md -Xspec.txt -Xexamples
make[1]: Leaving directory '/build/reproducible-path/commonmark-bkrs-0.5.4+ds'
   dh_fixperms -O--buildsystem=pybuild
   dh_missing -O--buildsystem=pybuild
dh_missing: warning: usr/bin/cmark-bkrs exists in debian/tmp but is not installed to anywhere (related file: "build/scripts-3/cmark-bkrs")
dh_missing: warning: usr/bin/cmark.py exists in debian/tmp but is not installed to anywhere 
dh_missing: warning: usr/bin/test-CommonMark.py exists in debian/tmp but is not installed to anywhere 
dh_missing: warning: usr/bin/tests/test-CommonMark.py exists in debian/tmp but is not installed to anywhere 
dh_missing: warning: usr/lib/python3.13/dist-packages/CommonMark_bkrs/CommonMark.py exists in debian/tmp but is not installed to anywhere 
dh_missing: warning: usr/lib/python3.13/dist-packages/CommonMark_bkrs/__init__.py exists in debian/tmp but is not installed to anywhere 
dh_missing: warning: usr/lib/python3.13/dist-packages/CommonMark_bkrs/__pycache__/CommonMark.cpython-313.pyc exists in debian/tmp but is not installed to anywhere 
dh_missing: warning: usr/lib/python3.13/dist-packages/CommonMark_bkrs/__pycache__/__init__.cpython-313.pyc exists in debian/tmp but is not installed to anywhere 
dh_missing: warning: usr/lib/python3.13/dist-packages/CommonMark_bkrs/__pycache__/entitytrans.cpython-313.pyc exists in debian/tmp but is not installed to anywhere 
dh_missing: warning: usr/lib/python3.13/dist-packages/CommonMark_bkrs/entitytrans.py exists in debian/tmp but is not installed to anywhere 

	While detecting missing files, dh_missing noted some files with a similar name to those
	that were missing.  This warning /might/ be resolved by replacing references to the
	missing files with the similarly named ones that dh_missing found - assuming the content
	is identical.

	As an example, you might want to replace:
	 * build/scripts-3/cmark-bkrs
	with:
	 * usr/bin/cmark-bkrs
	in a file in debian/ or as argument to one of the dh_* tools called from debian/rules.
	(Note it is possible the paths are not used verbatim but instead directories 
	containing or globs matching them are used instead)

	Alternatively, add the missing file to debian/not-installed if it cannot and should not
	be used.

	The following debhelper tools have reported what they installed (with files per package)
	 * dh_install: python-commonmark-bkrs-doc (0), python3-commonmark-bkrs (2)
	 * dh_installdocs: python-commonmark-bkrs-doc (5), python3-commonmark-bkrs (1)
	 * dh_installexamples: python-commonmark-bkrs-doc (2), python3-commonmark-bkrs (0)
	 * dh_installman: python-commonmark-bkrs-doc (0), python3-commonmark-bkrs (1)
	If the missing files are installed by another tool, please file a bug against it.
	When filing the report, if the tool is not part of debhelper itself, please reference the
	"Logging helpers and dh_missing" section from the "PROGRAMMING" guide for debhelper (10.6.3+).
	  (in the debhelper package: /usr/share/doc/debhelper/PROGRAMMING.md.gz)
	Be sure to test with dpkg-buildpackage -A/-B as the results may vary when only a subset is built
	If the omission is intentional or no other helper can take care of this consider adding the
	paths to debian/not-installed.
   dh_installdeb -O--buildsystem=pybuild
   dh_gencontrol -O--buildsystem=pybuild
   dh_md5sums -O--buildsystem=pybuild
   dh_builddeb -O--buildsystem=pybuild
dpkg-deb: building package 'python3-commonmark-bkrs' in '../python3-commonmark-bkrs_0.5.4+ds-7.1_all.deb'.
dpkg-deb: building package 'python-commonmark-bkrs-doc' in '../python-commonmark-bkrs-doc_0.5.4+ds-7.1_all.deb'.
 dpkg-genbuildinfo --build=binary -O../commonmark-bkrs_0.5.4+ds-7.1_amd64.buildinfo
 dpkg-genchanges --build=binary -O../commonmark-bkrs_0.5.4+ds-7.1_amd64.changes
dpkg-genchanges: info: binary-only upload (no source code included)
 dpkg-source --after-build .
dpkg-buildpackage: info: binary-only upload (no source included)
dpkg-genchanges: info: not including original source code in upload
I: copying local configuration
I: unmounting dev/ptmx filesystem
I: unmounting dev/pts filesystem
I: unmounting dev/shm filesystem
I: unmounting proc filesystem
I: unmounting sys filesystem
I: cleaning the build env 
I: removing directory /srv/workspace/pbuilder/247930 and its subdirectories
I: Current time: Mon Mar  3 14:39:07 -12 2025
I: pbuilder-time-stamp: 1741055947