pacstall / pacup

Help maintainers update pacscripts (next-gen Perl rewrite)
GNU General Public License v3.0
6 stars 2 forks source link

awk: fatal: cannot open file `distrolist' for reading #22

Closed Zahrun closed 2 months ago

Zahrun commented 3 months ago

Describe the bug

pacup fails to parse distolist

To reproduce

  1. pacup -s -p linux-wifi-hotspot-deb/linux-wifi-hotspot-deb.pacscript -c 4.7.2

Expected behavior

pacup don't fail

Screenshots

  pacup -s -p linux-wifi-hotspot-deb/linux-wifi-hotspot-deb.pacscript -c 4.7.2
[+] INFO: Parsing .SRCINFO for linux-wifi-hotspot-deb.pacscript
    [>] Found pkgname: linux-wifi-hotspot-deb
    [>] Found pkgver: 4.7.1
    [>] Found maintainer: Zahrun <Zahrun@github.com>
    [>] Current: 4.7.1 ~> Latest: 4.7.2
Proceed with updating linux-wifi-hotspot-deb to 4.7.2? [Y/n] 
** GET https://raw.githubusercontent.com/pacstall/pacstall-programs/master/distrolist ==> 200 OK
awk: fatal: cannot open file `distrolist' for reading: No such file or directory
/usr/bin/srcinfo.sh: line 183: local: `depends_{}': invalid variable name for name reference
/usr/bin/srcinfo.sh: line 183: local: `makedepends_{}': invalid variable name for name reference
/usr/bin/srcinfo.sh: line 183: local: `optdepends_{}': invalid variable name for name reference
/usr/bin/srcinfo.sh: line 183: local: `pacdeps_{}': invalid variable name for name reference
/usr/bin/srcinfo.sh: line 183: local: `checkdepends_{}': invalid variable name for name reference
/usr/bin/srcinfo.sh: line 183: local: `provides_{}': invalid variable name for name reference
/usr/bin/srcinfo.sh: line 183: local: `conflicts_{}': invalid variable name for name reference
/usr/bin/srcinfo.sh: line 183: local: `breaks_{}': invalid variable name for name reference
/usr/bin/srcinfo.sh: line 183: local: `replaces_{}': invalid variable name for name reference
/usr/bin/srcinfo.sh: line 183: local: `enhances_{}': invalid variable name for name reference
/usr/bin/srcinfo.sh: line 183: local: `recommends_{}': invalid variable name for name reference
/usr/bin/srcinfo.sh: line 183: local: `makeconflicts_{}': invalid variable name for name reference
/usr/bin/srcinfo.sh: line 183: local: `checkconflicts_{}': invalid variable name for name reference
/usr/bin/srcinfo.sh: line 183: local: `source_{}': invalid variable name for name reference
/usr/bin/srcinfo.sh: line 183: local: `b2sums_{}': invalid variable name for name reference
/usr/bin/srcinfo.sh: line 183: local: `sha512sums_{}': invalid variable name for name reference
/usr/bin/srcinfo.sh: line 183: local: `sha384sums_{}': invalid variable name for name reference
/usr/bin/srcinfo.sh: line 183: local: `sha256sums_{}': invalid variable name for name reference
/usr/bin/srcinfo.sh: line 183: local: `sha224sums_{}': invalid variable name for name reference
/usr/bin/srcinfo.sh: line 183: local: `sha1sums_{}': invalid variable name for name reference
/usr/bin/srcinfo.sh: line 183: local: `md5sums_{}': invalid variable name for name reference
/usr/bin/srcinfo.sh: line 66: gives_{}: invalid variable name
[!] ERROR: Could not find sources
[+] INFO: Cleaning up
oklopfer commented 3 months ago

If you run this one step up (from the head of the repo) you should be able to use it still, but a fix is in the works

oklopfer commented 3 months ago

fixed in https://github.com/pacstall/pacup/pull/23

Zahrun commented 3 months ago

Thanks

Zahrun commented 3 months ago

Actually, it still fails in the end

 pacup -s -p linux-wifi-hotspot-deb/linux-wifi-hotspot-deb.pacscript -c 4.7.2
[+] INFO: Parsing .SRCINFO for linux-wifi-hotspot-deb.pacscript
    [>] Found pkgname: linux-wifi-hotspot-deb
    [>] Found pkgver: 4.7.1
    [>] Found maintainer: Zahrun <Zahrun@github.com>
    [>] Current: 4.7.1 ~> Latest: 4.7.2
Proceed with updating linux-wifi-hotspot-deb to 4.7.2? [Y/n] 
** GET https://raw.githubusercontent.com/pacstall/pacstall-programs/master/distrolist ==> 200 OK (2s)
    [>] Found source https://github.com/lakinduakash/linux-wifi-hotspot/releases/download/v4.7.2/linux-wifi-hotspot_4.7.2_amd64.deb
[+] INFO: Fetching sources for linux-wifi-hotspot-deb
[+] INFO: Downloading linux-wifi-hotspot_4.7.2_amd64.deb
100% [===========================================================================================]D 0h00m06s    [>] Calculating sha256sum for source entry
[+] INFO: updating linux-wifi-hotspot-deb.pacscript
[+] INFO: Installing from linux-wifi-hotspot-deb.pacscript
(linux-wifi-hotspot-deb) Do you want to view/edit the pacscript? [y/N] 
[+] INFO: Sourcing pacscript
[sudo] password for aroun: 
[+] INFO: Checking apt dependencies
[+] INFO: Retrieving packages
[+] INFO: Copying local archive linux-wifi-hotspot_4.7.2_amd64.deb
        [>] Checking hash 3231bade[...]
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
Note, selecting 'linux-wifi-hotspot' instead of './linux-wifi-hotspot_4.7.2_amd64.deb'
The following packages will be upgraded:
  linux-wifi-hotspot
1 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
Need to get 0 B/87.7 kB of archives.
After this operation, 20.5 kB disk space will be freed.
Get:1 /tmp/pacstall/linux-wifi-hotspot-deb~4.7.2/linux-wifi-hotspot_4.7.2_amd64.deb linux-wifi-hotspot amd64 4.7.2 [87.7 kB]
(Reading database ... 616077 files and directories currently installed.)
Preparing to unpack .../linux-wifi-hotspot_4.7.2_amd64.deb ...
Unpacking linux-wifi-hotspot (4.7.2) over (4.7.1) ...
Setting up linux-wifi-hotspot (4.7.2) ...
Processing triggers for hicolor-icon-theme (0.17-2) ...
Processing triggers for gnome-menus (3.36.0-1ubuntu3) ...
Processing triggers for mailcap (3.70+nmu1ubuntu1) ...
Processing triggers for desktop-file-utils (0.26-1ubuntu3) ...
[+] INFO: Performing post install operations
        [>] Storing pacscript
[+] INFO: Done installing linux-wifi-hotspot-deb
Does linux-wifi-hotspot-deb work? [y/n] y
Delete existing branch ship-linux-wifi-hotspot-deb? [Y/n] 
Deleted branch ship-linux-wifi-hotspot-deb (was 3a351400).
Switched to a new branch 'ship-linux-wifi-hotspot-deb'
trim trailing whitespace.................................................Passed
fix end of files.........................................................Passed
check yaml...........................................(no files to check)Skipped
check for added large files..............................................Passed
mixed line ending........................................................Passed
shellcheck...............................................................Passed
shfmt....................................................................Passed
update .SRCINFO data.....................................................Passed
check for .SRCINFO.......................................................Passed
update packagelist file..................................................Failed
- hook id: update-packagelist
- files were modified by this hook

awk: fatal: cannot open file `packages/distrolist/distrolist.pacscript' for reading: Not a directory

"git" unexpectedly returned exit value 1 at /usr/bin/pacup line 573.
[+] INFO: Cleaning up
oklopfer commented 2 months ago

Alright I know what the issue is, will release a fix today

oklopfer commented 2 months ago

@Zahrun can you install pacup-git and make sure this is completely fixed before we push as a full release :P

vigress8 commented 2 months ago

I tested, 'tworks (though there's a different issue)

Zahrun commented 2 months ago

@Zahrun can you install pacup-git and make sure this is completely fixed before we push as a full release :P

Confirmed :+1: