mikkeloscar / gopkgbuild

A golang package for parsing Arch Linux PKGBUILDs
GNU General Public License v3.0
22 stars 5 forks source link

Infinite loop parsing certain srcinfos #24

Open Morganamilo opened 6 years ago

Morganamilo commented 6 years ago

The following packages get stuck infinitely when calling ParseSRCINFO:

brother-dcp-l8400cdn
caret-bin
cndrvcups-lt
dolphin-emu-git-netplay
mpd-mpris
portscan
sharp-mx-182to232d-ps

Also while I was doing this I ended up generating a list of srcinfos that fail to parse. Although it's likely most of these fail to parse for good reason and is not actually a bug in gopkgbuild.

airdcnano-git [invalid version string: 20140305-git]
akasha-bin [unable to parse character:  ]
alienarena-svn [invalid version format:  sdl]
android-sdk-build-tools-24 [unable to parse character:  ]
antileech [invalid version string: v4405.r15.a9f4304 ]
archlinux-python-helper [missing pkgname]
argobots-git [invalid version format:  automake autoconf gcc libtool]
arm-none-eabi-newlib-linaro-git [invalid version string: .17991.eb4bfe462]
ar-sdk3-git [invalid version format:  yasm jdk8-openjdk python-virtualenv]
asciiquarium-lock [unable to parse character:  ]
asix-module [invalid version format: ]
auale [unable to parse character:  ]
bash-snippets [unable to parse character:  ]
bdf-ctrld-git [unable to parse character:  ]
bibledit [invalid version format: ,]
blender-plugin-bligify [unable to parse character:  ]
brave-git [invalid version string: 0.22.0.^3.0.18546.]
brother-dcp-l8400cdn [missing pkgname]
brother-hll2300d [unable to parse character:  ]
brother-hll2340dw [unable to parse character:  ]
brother-pj723 [unable to parse character:  ]
buku [unable to parse character:  ]
canon-pixma-mg5200-complete [unable to parse character:  ]
caret-bin [missing pkgname]
ccm [invalid version format: 3,]
chkservice [unable to parse character:  ]
cinnamon-theme-numix-darkred [unable to parse character:  ]
clearsilver [invalid version format: ]
cndrvcups-lt [missing pkgname]
coquillo [unable to parse character:  ]
cvt12-git [invalid version format: 4.8.0,]
deadbeef-plugin-fb [invalid version format: 0.6,]
deadbeef-plugin-fb-gtk3 [invalid version format: 0.6,]
djgpp-gcc [invalid version format: ,]
dosbox-binutils [unable to parse character:  ]
dosbox-gcc [unable to parse character:  ]
easea [invalid version format: 4.4,]
eclipse-jubula [invalid version format: 4.6.0,]
elastix-git [invalid version string: 4.304@3344.r945.g522843d9]
emacs-helm [invalid version format:  emacs-async]
evolution-on-git [invalid version format: 1.8libtool>=1.4.3]
exo-git [invalid version format: 2,24]
fin [unable to parse character:  ]
fnotify [invalid version format: ,]
fortunereader [invalid version format: 3,]
fuel [invalid version format: 5.4.0,]
gesture-manager-git [invalid version format: 3.18,python]
gnome-shell-extension-taskbar [invalid version string: 57.0 ]
gnupg-clavator [invalid version string: 2.1.16-clavator]
gpaste-git [unable to parse character:  ]
gpmdp-remote [unable to parse character:  ]
gppcscconnectionplugin [unable to parse character:  ]
graphscad [unable to parse character:  ]
grappl [invalid version string: 1.5.9 ]
grub-btrfs-git [invalid version string: v1.7.r6.g4388c33-1]
guark [invalid version format: ,]
highmoon [Arch missing]
http-parser-git [unable to parse character:  ]
huaweicalc-git [invalid version format:  git gcc qtchooser]
hyper-appimage [unable to parse character:  ]
imagemagick-fftw [invalid version format: ]
imagemagick-full-git [invalid version format: ]
imagemagick-no-hdri [invalid version format: ]
i-score [unable to parse character:  ]
iscore-git [unable to parse character:  ]
iview [Arch missing]
jamomacore-git [unable to parse character:  ]
jdk8-openj9-bin [invalid version string: 8u162-b12]
juman++ [unable to parse character:  ]
kayak-git [invalid version string: .]
kdbus-ck [invalid version format: (detects ck kernel)-headers>=4.3]
kde-servicemenus-unarchiver [invalid version string: 1,0]
kimai-git [invalid version format: ,]
kiwiirc [invalid version format: 4.0.0,]
libtranslate [invalid version format: ,]
libvirt-git [unable to parse character:  ]
lldb-git [invalid version format: ]
lua-stringy [invalid version string: 0.4-1]
mcabber-module-disco-hg [invalid version string: r63.d644c08bbc27]
mcp2210-git [invalid version format: ]
minergate [unable to parse character:  ]
mingw-w64-async++-git [unable to parse character:  ]
mingw-w64-gperftools [unable to parse character:  ]
mingw-w64-libxdiff [unable to parse character:  ]
mingw-w64-lua51 [unable to parse character:  ]
mingw-w64-physfs-hg [unable to parse character:  ]
mipsel-linux-gcc3 [Arch missing]
mipsel-linux-gcc3-initial [Arch missing]
mipsel-linux-libstdc++5 [Arch missing]
mips-harvard-os161-gdb [unable to parse character:  ]
mmsap2 [invalid version format:  gtkmm dbus dbus-glib libglade]
mpd-mpris [missing pkgname]
msmtpqd [invalid version format:  python-attrs python-appdirs]
mulet-nightly-bin [invalid version string: 51.0a1@20160808224700]
mundus [unable to parse character:  ]
net-snmp-lmsensors [invalid version format: ]
numix-cinnamon-green-2 [unable to parse character:  ]
nvidiux [unable to parse character:  ]
one-context [unable to parse character:  ]
onemoresamegame [invalid version format: ]
openra-kang [unable to parse character:  ]
openss7-git [invalid version format: ]
oscam-emu [invalid version string: 769-11410]
owo-cli [unable to parse character:  ]
pacliner-git [invalid version format: ,perl]
pass-patched-passmenu-notify-git [invalid version string: latest-passmenu-notify]
pear-net-ldap2 [invalid version format:  php-pear]
perl-catalyst-plugin-session [invalid version format: 6.59 perl-test-www-mechanize-psgi]
perl-catalyst-view-tt [unable to parse character:  ]
perl-cgi-session-driver-memcached [invalid version format: 4,]
perl-gstreamer [invalid version format: ]
perl-gtk2-webkit [invalid version format: ]
perl-libapreq2 [invalid version format: ]
perl-rpsl-parser [invalid version format: 5.10.0,]
perl-xml-fast [invalid version format: ]
php56-trace [invalid version format: 5.2,]
php-alpm [invalid version format: ]
php-event [invalid version format: 7.0,libevent]
php-pam [unable to parse character:  ]
phpsh [invalid version format: 6.0,python2>=2.6]
plus-dm [invalid version format:  ]
poltroon [invalid version format: 1.7 make go-bindata>=3.0.7 libunistring>=0.9.6-2 gcc]
portscan [missing pkgname]
pppd-ldap-simple [invalid version format: ]
prips [invalid version string: 1.0.1-1]
python2-elasticsearch-curator [invalid version format: 3.10,]
python2-hmmlearn [unable to parse character:  ]
python2-htpasswd-git [invalid version string: .r31.ef677a5]
python2-openstackclient-kilo [invalid version format: ]
python2-orderedmultidict-git [invalid version string: .r66.af36f63]
python2-proxyenv-git [invalid version string: .r24.a790e3a]
python2-pyvirtualdisplay [invalid version format: 2.6,]
python-glue [invalid version format: 3.1 python-jinja python-pillow]
python-htpasswd-git [invalid version string: .r31.ef677a5]
python-linotype [unable to parse character:  ]
python-orderedmultidict-git [invalid version string: .r66.af36f63]
python-proxyenv-git [invalid version string: .r24.a790e3a]
python-pyassimp-git [invalid version string: git-1]
python-pyvirtualdisplay [invalid version format: 2.7,]
python-sqlalchemy-utils [unable to parse character:  ]
python-zerodb [invalid version format: ,]
qbittorrent-nogui-git [invalid version string: .7653]
qcma [unable to parse character:  ]
r8168-aufs [invalid version format: ]
r8723bs-git [invalid version string: .804.e12be86]
rdkit-git [unable to parse character:  ]
rdkit-git-python3 [unable to parse character:  ]
readeef-client-git [invalid version format:  npm findutils]
regd-git [invalid version format: 3.3,git]
repetier-server [unable to parse character:  ]
rhythmbox-plugin-ampache-git [invalid version string: 0d233e3 ]
riemann-c-client [unable to parse character:  ]
riscv-isa-sim-git [invalid version format: ,]
rocket-depot-git [unable to parse character:  ]
ros-jade-libmavconn [unable to parse character:  ]
rt3562sta [invalid version format: ]
rt3562sta-aufs [invalid version format: ]
ruby-capifony [invalid version format: 2.0.2,]
ruby-sawyer [invalid version format: 2.5>=2.3.5]
salientia-git [invalid version string: _]
salome-yacs [invalid version format: ${pkgver:0:2}$((${pkgver:2:1}+1)).0]
scangearmp-common-mp495series [invalid version format: 0.1.12,]
servoblaster-git [invalid version string: r73.96014c8-1]
session-nanny-git [unable to parse character:  ]
sfml-rpi-git [invalid version string: 2.2.r77.gf797384-1]
shadowsocks-git [invalid version string: 2.9.1.r24.ge332ec9 ]
sharp-mx-182to232d-ps [missing pkgname]
spyquiz [invalid version format:  curl sl lolcat]
syncany-git [invalid version format: 7,]
triplea [invalid version string: 1.9.0.0.7594 ]
tty2gif-git [invalid version string: .8a9f400]
udpspeeder-git [invalid version string: v2@20171021.0.r20.g20a5547]
ulauncher-git [unable to parse character:  ]
umip [invalid version format:  bison]
upwork-appimage [unable to parse character:  ]
vaulty [unable to parse character:  ]
virt-bootstrap-git [unable to parse character:  ]
work-hours-counter [invalid version format: ('java-environment')]
wumwum [invalid version format: ]
x-arc-darker [unable to parse character:  ]
x-arc-plus [unable to parse character:  ]
x-arc-shadow [unable to parse character:  ]
x-arc-white [unable to parse character:  ]
xinput_calibrator-git [unable to parse character:  ]
xz-java [invalid version format: 1.4,]
yagv-git [invalid version format: -1.1.4]
Morganamilo commented 6 years ago

A lot of the error messages are a little vague. Maybe a line number should me added to the message as well?

Morganamilo commented 6 years ago

Figured it out it seems. All these srcinfos do not end with a new line.