Let's Play... some Debian packaged games from the Warehouse

from the message in the screenshoot (video won’t work for me) it seem to be related with ntp time sync delay

https://blog.sleeplessbeastie.eu/2019/11/15/how-to-deal-with-repository-is-not-valid-yet-error/

(on initial state of my arch port i went “similar” issue, cannot resolve any dns due to dnssec activated with a system time set to kernel compilation moment, ntp cannot setting goot time due to dnssec, have to manually set time at each boot, finally disabled dnssec …)

edit > time check can be disabled in apt https://unix.stackexchange.com/questions/2544/how-to-work-around-release-file-expired-problem-on-a-local-mirror

1 Like

Here’s a screen cap of the blurry part, split seconds before it would boot me back fo the launcher; as best as I could take it with my phone.

Needless to say, even after installing a fresh stock 0.5 image, and updating to the latest launcher version, I was able to replicate this error, again only with UQM.

Just for fun, taking @r043v’s post in mind, I tried to change my time zone to Asia/Bangkok, possibly matching up to the time server there. This shouldn’t make a difference, since where I’m from (Western Australia), it’s the time zone. Needless to say, it also didn’t work.

Awesome find! So it sounds like it sort of is an issue with the repository, and maybe also a bit of time travel shenanigans by @javelinface. :slight_smile:

The workaround in your second link doesn’t sound like a bad thing to add just to be safe. I’m assuming meddling with the time-space continuum wouldn’t cause any other problems… What could possibly go wrong? :wink:

So I’d replace the sudo apt-get -y update && sudo apt-get -y install $PKGNAME part with something like this:sudo apt-get -o Acquire::Check-Valid-Until=false -y update && sudo apt-get -o Acquire::Check-Valid-Until=false -y install $PKGNAME

@javelinface, would you mind trying something? Could you uninstall the packages (apt-get remove uqm uqm-content uqm-music uqm-voice) and then edit the file at /home/cpi/aria2download/madcock/warehouse/master/Games%20apt/Ur-Quan-Masters/file/Ur-Quan Masters/Ur-Quan Masters.sh and change this line:

x-terminal-emulator -e "printf '$PKGNAME not installed. Installing...\n' && sudo sed -i -- '/^deb .*stable main contrib$/ s/$/ non-free/' /etc/apt/sources.list && sudo apt-get -y update && sudo apt-get -y install $PKGNAME"

to this:

x-terminal-emulator -e "printf '$PKGNAME not installed. Installing...\n' && sudo sed -i -- '/^deb .*stable main contrib$/ s/$/ non-free/' /etc/apt/sources.list && sudo apt-get -o Acquire::Check-Valid-Until=false -y update && sudo apt-get -o Acquire::Check-Valid-Until=false -y install $PKGNAME"

That should mostly reset things to how they were before the install, and then running from the warehouse (without doing an update) should test the change to the script. Thanks!

1 Like

Onto it! Also for the record,

Reading package lists... Done
Building dependency tree       
Reading state information... Done
Package 'uqm' is not installed, so not removed
Package 'uqm-content' is not installed, so not removed
Package 'uqm-music' is not installed, so not removed
Package 'uqm-voice' is not installed, so not removed

That was to be expected, given nothing was installed.

Ah, fair enough, I forgot that you hadn’t manually installed on the fresh image. Even better, it should be totally clean!

1 Like

yes repo is out of date

curl https://mirrors.tuna.tsinghua.edu.cn/debian/dists/stable-updates/InRelease | less


Date: Thu, 16 Jan 2020 14:27:32 UTC
Valid-Until: Thu, 23 Jan 2020 14:27:32 UTC

you could off course disable date check but i think change server could be better

2 Likes

I agree about changing the server, but if we want this to work for everyone, then they will ALL need to change their server since the default unfortunately uses this (apparently) unreliable one. And I’m not sure it would be “easy” for everyone to change that on their Gameshell. Hopefully a future OS update can improve on these things and not require workarounds for seemingly basic stuff. :frowning:

2 Likes

GOOD NEWS MY FRIEND! It appears to be working! I was originally going to post a video of it, but it’s already gotten past the previous point, and is just doing the install normally! (Well, lets not count our eggs till they’re hatched - it’s still actually installing. I just got too excited and wanted to report back. Edit: AND IT HAS NOW INSTALLED! :D)

For the record, it was editing the *.sh file to contain

x-terminal-emulator -e "printf '$PKGNAME not installed. Installing...\n' && sudo sed -i -- '/^deb .*stable main contrib$/ s/$/ non-free/' /etc/apt/sources.list && sudo apt-get -o Acquire::Check-Valid-Until=false -y update && sudo apt-get -o Acquire::Check-Valid-Until=false -y install $PKGNAME"

that seemingly did the trick.

WE’VE DONE IT! Thanks @adcockm and @r043v! The community is now a better place, now that everyone can experience the UQM on the Gameshell! :smiley:

Now the strange thing. Why did adding “-o Acquire::Check-Valid-Until=false” work for the game shell warehouse, but seemingly wasn’t required when running the script independently via a SSH?

I just saw saw this part:

WHO TOLD YOU?? YOU KNOW TOO MUCH! :smiley:

2 Likes

nice :slight_smile:

you could patch each warehouse packages until better option
or why not create an “universal” “apt-check-mirror” command to run at each script start ?

@javelinface maybe because you wasn’t run “apt-update” before your install attempt ?

fun thing is that the Release file of the repo is valid, inRelease file is not, inRelease seem to be association of Release file & gpg key, maybe apt-get update will check inRelease file and catch Release later or anything like that, you may have a cache “issue” for the manual case who worked

1 Like

This is a good point! Although, I didn’t use it while SSHing remotely into the gameshell either, running

Either way, it was done on a clean image, and to make it easily accessible by everyone, having to apt update would be an additional step, hindering the ease of the warehouse system.

Awesome! And I’m not quite done yet because I haven’t updated the warehouse entry for the game yet. But I’ll do that right now. :wink:

WE’VE DONE IT! Thanks @adcockm and @r043v! The community is now a better place, now that everyone can experience the UQM on the Gameshell! :smiley:

I’ll post here when I’ve updated the script in the warehouse. Then it should be ready to go for anyone who goes through the warehouse. It’s still a bit of a hack, but like I say, I hope adding the time skipping parameter isn’t going to be a problem.

1 Like

Was it a problem to do with the chinese mirror?
What about making an entry in /etc/apt/sources.list.d/ to use the stock http://deb.debian.org/debian repositories, and point the apt-get to use that? At least until we get news of the sources.list using more conventional locations.

I just added the extra “-o Acquire::Check-Valid-Until=false” options to the script. The warehouse (well, git) should be updated now, so doing an “update” from the warehouse on a Gameshell should pull in the updated file.

I already changed my source.list to look like this, based on @r043v’s suggestion:

# deb http://mirrors.tuna.tsinghua.edu.cn/debian/ stable main

deb http://mirrors.accretive-networks.net/debian/ stable main contrib non-free
deb-src http://mirrors.accretive-networks.net/debian/ stable main

deb http://mirrors.accretive-networks.net/debian-security stable/updates main
deb-src http://mirrors.accretive-networks.net/debian-security stable/updates main

# stable-updates, previously known as ‘volatile’
deb http://mirrors.accretive-networks.net/debian/ stable-updates main
deb-src http://mirrors.accretive-networks.net/debian/ stable-updates main

(netselect-apt suggested that location as the fastest for me)

Speaking of /etc/apt/sources.list.d, I’ve got a couple of files in there that were created because of other stuff I’ve been doing. I’ve got a mono-official-stable.list for pulling in a bunch of stuff I needed to build mono, so I could try running more games. (I’ve got Fez partially working thanks to that.) I also have vivaldi.list in there because I wanted to see if I could get a browser running on Gameshell. (It does run, as does Chromium, both without any tweaking or hacks but the limited display size makes them pretty much unusable, and the mouse pointer is hidden even though I can control it, pretty much blindly, using the mouse Arduino hack.) At some point I’m going to see about setting up a browser in “kiosk” mode. It might be nice if there was an easy way to put up a full screen browser window, and then use the mouse Arduino hack to control it. It’s not like anyone could browser Facebook on the Gameshell, but it might be handy for some simpler sites that could just be launched from an icon via the launcher. That is my intention anyway, but it isn’t high on my priority list, especially since the default mouse pointer was invisible and I’d have to sort that out. Might be possible to used the d-pad (arrow keys) to select links though, and maybe some other button remappings to make using a browser a little easier. But like I say, I haven’t dug too deep on it yet. First step was to see if a browser would work at all. :slight_smile:

1 Like

check /home/cpi/.bashrc to remove the nocursor option on startx

1 Like

Ha! a browser on the gameshell!

The one thing that comes to mind was something I used to play at uni: Kingdom of Loathing. It’s a click based game, so could potentially work.

I remember playing it on my old Sony Ericsson w800i mobile phone; back in the pre smart phone era. It had a resolution of 176 x 220. It didn’t have a touch screen, but did have a small joystick that would simulate a mouse.

I have no idea how discourse would display on a 320x240 screen, but hey! Just displaying the forums here would be a nice way to use the gameshell. I’m grasping at straws here, especially seeing as these days, our mobile phones can do web browsing far better than a game device.

1 Like

I don’t see any mention of nocursor in my .bashrc file. :frowning:
I didn’t see any mention of it in /etc/bash.bashrc either. SO I’m not sure how the cursor is being hidden.

i cannot check but it must be on the startx command

found mention in this pretty old post > Manual Upgrade Clockworkpi OS V0.1 to V0.2 · clockworkpi/GameShellDocs Wiki · GitHub

edit > on arch it’s into .bash_profile file

[gs@gs ~]$ cat ~/.bash_profile
[[ -f ~/.bashrc ]] && . ~/.bashrc

if [[ ! $DISPLAY && $XDG_VTNR -eq 1 ]]; then
  exec startx
fi

it may be also run from a systemd service

1 Like

Yeah, I think most modern websites (including these forums) are not going to work very well on the Gameshell. Even if they load and display properly, there’s just not enough space on the 320x240 display. I haven’t gone searching, but someone may have made an application to load content from discourse or other forum software that could be ported.

I just figured it might be handy for some simple websites or web pages. I wasn’t thinking about doing much actual browsing this way, just as a way to show certain pages that are known to work. There might even still be some lingering WAP compatible pages on the web that would probably load fine, since they were designed with low res phone screens and PDA devices in mind. But most of that is probably gone now, or so out of date as to be useless. :frowning:

Another related thing I’d love to be able to get running on the Gameshell is a Flash player. There are plenty of old, classic games that should run fine even on the Gameshell display, but require Flash. I haven’t gone digging yet, but if anyone has a decent Flash option running on a Raspberry Pi then we might be able to use the same thing. Games like Canabalt (from the Humble Bundle) shoudl work great on the Gameshell if only there was a Flash player to run them. Some other games and apps that used Adobe’s Air to run are probably never going to be doable though. That was kind of like Flash, but even more proprietary, and as far as I know there’s no way to get that stuff running on other platforms. :frowning: There’s at least a slight chance an old X86 Linux version of Flash or something else proprietary might be usable with box86, but I wouldn’t have high hopes of it working well, if at all.

I imagine someone, somewhere has probably built something to run Flash games though, and hopefully if so it’s portable and able to be run on Gameshell. I just haven’t really gone looking yet.

2 Likes

I think I found it. There’s a lot of junk that needs to be cleaned up on the Gameshell that is referring to stuff that doesn’t exist anymore.

Looks like the cursor is now set in ~//launcher/.cpirc

SCREEN=cat /sys/class/graphics/fb0/modes

XORG_CONF=“~/launcher/.xorg.conf”
if [ -f /home/cpi/.lima ]
then
XORG_CONF=“~/launcher/.xorg_lima.conf”
fi

if [ -f /tmp/autologin ]
then
rm -f /tmp/autologin
mpd ~/.mpd.conf
if [[ $SCREEN =~ .320. ]]
then
while :
do
startx /home/cpi/launcher/.xinitrc – -xf86config $XORG_CONF -nocursor > /tmp/x.log 2>&1
sleep 1
done
else
while :
do
startx /home/cpi/launcher/.xinitrc hdmi – -xf86config $XORG_CONF > /tmp/x.log 2>&1
sleep 1
done
fi
fi

I’ll try commenting it out there, but I also wonder how annoying it will be to have a cursor on the screen on the time when I don’t need it. Do you know if there’s a way to toggle it on and off while inside of an X session without having to restart the X server? I’m just thinking if there was a command that could be run, I could try to do something sneaky like the volume/brightness hack uses, and just run a cursor toggle command whenever a certain key combo is pressed.

Ok, that worked – I get a cursor when I remove that flag. But unfortunately it’s at the center of the screen. If I move it to the bottom right corner of the screen, it’s effectively out of the way, and I only get one “stuck” pixel in the corner if I’m not using the mouse for anything. For now I can just move the mouse out of the way myself. But I wonder if there’s a way to set the starting location of the cursor at launch so it’s not in the center of the screen?

2 Likes

you can try these utils, they auto hide cursor after a specific no moving mouse time

https://wiki.archlinux.org/index.php/Unclutter

1 Like