PA Alternative Launcher v0.4

Discussion in 'Mac and Linux' started by DeathByDenim, October 7, 2014.

  1. DeathByDenim

    DeathByDenim Post Master General

    Messages:
    4,327
    Likes Received:
    2,125
    Since it's now multiplatform, I started a new thread in General. Go here: https://forums.uberent.com/threads/alternative-pa-launcher.68233/

    So, I know there are already two (most excellent!) command-line tools out there for Linux to update PA to the latest version without downloading the whole bz2 file again for every update, but we are still lacking the launcher that Uber has for Windows and Mac. So I created this:
    paalternativelauncher.png
    I think it does everything the official launcher does, but I don't have Windows, so I'm basing that on screenshots and such. Anyway, it also automatically logs you in because it saves the session ticket and furthermore, if you launch PA through this launcher, it will also automatically log in there.

    Now I just need some testers to weed out the bugs and then I'll compile a Windows version for the poor fellows on the support forum that can't get the regular one working because Uber's launcher depends on oddly specific versions of DirectX, possibly .NET, possibly not, and who knows what more. And a Mac version too, because why not?

    You can get it here from GitHub. It depends on Qt4, QJson and Zlib. Those are most likely installed on your average Linux distro anyway, but just in case, on Ubuntu, you can install those packages using:
    Code:
    sudo apt-get install libqt4-core libqt4-gui libqt4-network libqjson0 zlib1g
    However, a .deb is also available that takes care of that for you.

    And similar for other distros, I suppose.
    Last edited: September 8, 2015
    uggla88, tatsujb, dukyduke and 4 others like this.
  2. gerii

    gerii Member

    Messages:
    90
    Likes Received:
    32
    Awesome!
    One bug I found is that I can't remove the 'Use optirun' checkbox after I accidently applied it. Also I usually use primusrun, would be nice to have an option to set this too.
    And I think it's called zlib1g on Ubuntu, at least here on Mint it couldn't find zlib.
  3. DeathByDenim

    DeathByDenim Post Master General

    Messages:
    4,327
    Likes Received:
    2,125
    Whoops. Fixed. Also good call on the zlib thing. I mistyped.
    tatsujb likes this.
  4. websterx01

    websterx01 Post Master General

    Messages:
    1,682
    Likes Received:
    1,063
    jkl;ag.png
    Install directory: C:\Program Files (x86)\Planetary Annihilation\PAalternate

    Launcher stops responding during "Downloading and installing bundles," and it does not actually pull any network data according to tastmanager and my router.

    Edit: Sorry about the white space, I'm a bit lazy when cutting .5MB off a file :p

    Also: is there anywhere that it writes a log file to? If not, adding that would be amazing to help you troubleshoot.
    Last edited: October 18, 2014
    tatsujb likes this.
  5. DeathByDenim

    DeathByDenim Post Master General

    Messages:
    4,327
    Likes Received:
    2,125
    Yeah, it does. For Windows, I think it's "C:\Windows\Temp\PAAlternativeLauncher.log", or whatever %TEMP% is set to for you. It seems to be just stuck though even though the download and install is supposed to be at 100%. Huh... Did it at least install anything?

    Also, you probably wish you had cut the image properly...:
    websterx01.png
    :rolleyes:
    tatsujb and websterx01 like this.
  6. websterx01

    websterx01 Post Master General

    Messages:
    1,682
    Likes Received:
    1,063
    @DeathByDenim

    I have the log file, it's in the AppData\Local\Temp folder. However, apparently, no data was written to it. (Edit: after running again, it wrote to the log file. I had to change it to .txt to upload, but I think no data was changed.)

    Also, the installer created all of the necessary files and folders, but wrote no data to them either (the are all 0kb and don't work).

    Finally, screenshot of it freezing on verification. (Edit: its currently frozen on 95% verification.)

    Edit Dxdiag.txt just in case.

    Attached Files:

    Last edited: October 18, 2014
  7. DeathByDenim

    DeathByDenim Post Master General

    Messages:
    4,327
    Likes Received:
    2,125
    Weird. I've made a version with even more logging and enhanced error checking. You can use the same link I sent you earlier.
    tatsujb likes this.
  8. websterx01

    websterx01 Post Master General

    Messages:
    1,682
    Likes Received:
    1,063
    Same .exe as before, unless you added auto update. On Download and install I now get "I/O Error" "Decompressing Update (1) (-3)," when downloading manifest. The bar goes from 0-100%. When I hit Okay, it says Done 0%. (If I hit Okay before the bar is at 100%, it gives me seeming random numbers like 0%, 2%, 5%, 7% (most common), 13%, 22% and 100%.
  9. DeathByDenim

    DeathByDenim Post Master General

    Messages:
    4,327
    Likes Received:
    2,125
    Ah, bah... The (-3) means that the data was not valid gzipped data. That means either the data got corrupted or that there is something odd in my code. Probably the latter.
    tatsujb likes this.
  10. websterx01

    websterx01 Post Master General

    Messages:
    1,682
    Likes Received:
    1,063
    Woo! Getting somewhere. I wish I knew more so I could debug some of the code myself. After using version .3.1, I get the same results as my first test, and I doublechecked the network utilization with windows and it pulled no data when it stopped responding.

    Attached Files:

  11. DeathByDenim

    DeathByDenim Post Master General

    Messages:
    4,327
    Likes Received:
    2,125
    Well, according to that log, the program does try to start the downloads, but it never receives any data. So what happens is that the launcher can download the manifest. The launcher uses that manifest to determine which files you already have and proceeds to download the bundles that contain those files. That's where it goes wrong for you (and that's probably tripping up Uber's launcher as well). It never receives any data! Even odder is that you never get an error about it either. It should at least say "connection timed out" or something. But no, it just freezes apparently, which should be impossible, since it's in a different thread.

    Do you maybe have some weird firewall settings or some such? Can you disable your firewall and try again? Do you have trouble downloading large files (>5MB) in general?
    tatsujb likes this.
  12. websterx01

    websterx01 Post Master General

    Messages:
    1,682
    Likes Received:
    1,063
    @DeathByDenim Windows firewall is disabled, router firewall is disabled. I may be behind my ISP's firewall (Secondary merchant for Comcast, wireless broadband), but that hasn't really interfered before.

    Also, to see network utilization: 3.png
    My router conforms with the graph--no data is being transmitted.
  13. DeathByDenim

    DeathByDenim Post Master General

    Messages:
    4,327
    Likes Received:
    2,125
    Ok, I've updated it with yet more logging and also a minor bugfix that shouldn't affect you. Download it again from the same link (sorry, forgot to update the version number, so it's still 0.3.1). I have a new assignment for you, assuming you are not sick and tired of this yet. :)

    It will now log the URL of the bundle it is trying to download. When my launcher fails again, can you open the log file, find a URL that looks like "Preparing to download http://download.uberent.com/PA/hash...f441f88037576591?Policy=eyJTdGF0ZW1lbnQiOlt7I......". Plug that into your browser and see if your browser is able to download it or if you get some error. Also please post the new log here again.
    Last edited: October 20, 2014
    tatsujb likes this.
  14. websterx01

    websterx01 Post Master General

    Messages:
    1,682
    Likes Received:
    1,063
    Okay! Some new information. First, when I tried logging in after getting the new one, I had Caps on apparently and it gives a very strange message: "Host must authenticate." If you could change it to something along the lines of "Password-I.D. Missmatch" I'd feel better. :p Also, no log out button?

    Code:
    http://download.uberent.com/PA/hashed/7fda4e0ee8616c3cfcbc7974f24d03ec571fc109?Policy=eyJTdGF0ZW1lbnQiOlt7IlJlc291cmNlIjoiaHR0cDovL2Rvd25sb2FkLnViZXJlbnQuY29tL1BBLyoiLCJDb25kaXRpb24iOnsiRGF0ZUxlc3NUaGFuIjp7IkFXUzpFcG9jaFRpbWUiOjE0MTM4NDMzMTJ9fX1dfQ__&Signature=AJgP3yhtSmFKY~8VAzcXrCJrSOJy9Q3VH~oORqf20tzZOskQlWL9zpZ66WWIMnyb6cqwrs~UKS6faFsOSRWHvPKxNOLdicSXJLVgFsDhagvu2YcuFx1fXYBKedTy5xhdZLuLyfZAvUX7nPx963aBk29Efs-fC3HBO6h~c3wCw~o_&Key-Pair-Id=APKAIOVJ4VBNZZU4TTQA
    This was the last file that it attempted to download, after which it stated that it received 1024 bytes. I plugged that URL into chrome, and it downloaded all 3,190,702 bytes without an issue.

    Edit: is there any notification in the log when there is an error?
    Also, the first time I tried to download it, it gave me the (1) (-3) error, and now it pings before it stops responding, but not dialogue box shows up.

    Attached Files:

  15. DeathByDenim

    DeathByDenim Post Master General

    Messages:
    4,327
    Likes Received:
    2,125
    Meh. Why'd you want to log out? And just type in your password correctly. ;)
    That's just polishing though.

    Any errors should appear in the log, yes. Although I noticed just now that it only does so after you have clicked ok. I've reversed the order now. I've also added more logging as well as some more error checking. It's getting more bizarre by the minute though. I've uploaded a new version again.
    tatsujb likes this.
  16. websterx01

    websterx01 Post Master General

    Messages:
    1,682
    Likes Received:
    1,063
    @DeathByDenim

    Okay, I've tried the new version, and I have the same issue of it no longer responding. However, I tried some other things out: I launched it on one of my other PCs (AMD) and I got the same result. Then, I tried using my AT&T network tethering, and got the same result there too, so it seems unlikely that its my network. Even the log looks about the same.

    I will edit this in a moment from my other PC so that I can upload it's log as well.
    I well try to use my Lubuntu 12.04 and see how well it does there. Though I don't know so much about linux :p

    Edit: I forget how to do things. :p Once I get some time to google everything, I'll report back any network stuff. (The AMD64 threw me off, and I don't remember .tar.gz off the top of my head. Been a year or so.)

    Attached Files:

    Last edited: October 21, 2014
  17. DeathByDenim

    DeathByDenim Post Master General

    Messages:
    4,327
    Likes Received:
    2,125
    Well, it definitely works on Linux. I use it on there all the time. :)
    I even have a .deb package up, which you can just use on Lubuntu and it will take of everything it needs.

    Anyway, I've updated the link again. I've added some more error checking, but it's the last thing I could think off, so if this doesn't tell me anything, I'm completely out of ideas...
    tatsujb likes this.
  18. websterx01

    websterx01 Post Master General

    Messages:
    1,682
    Likes Received:
    1,063
    It gave me an AMD64 error thing that confused the heck out of me because lubuntu uses debian stuff. Anyway, I'll check the new version and tell you more in the morning I think. I'll just edit the post :D

    Edit: Nah, I'll just do it now :p I get the "Decompress error (1) (-3)"

    Edit: Woah, its doing something without crashing! Making good use of my 575kb/s.

    I'm baffled as to what's making it work, but perhaps that's where your knowledge of your software comes in :p I tried it repeatedly, it seems to work. I'll give it a quick go in the morning to see if it's a network fluke.
    Last edited: October 22, 2014
  19. DeathByDenim

    DeathByDenim Post Master General

    Messages:
    4,327
    Likes Received:
    2,125
    Whaow. I wasn't expecting that. I did change only a minor thing where I read out the buffer. According to the spec as far as I understand them, I am allowed to request a larger number of bytes than is actually available. This works fine under Linux. What I changed was that I limit the request to the number of available bytes. I guess that did the trick. Weird.

    So you got the Decompress error (1) (-3) once and than it just magically disappeared? Huh... Oh, wait was this for Windows or Linux?

    Also, yeah the deb is 64-bit. PA won't work on 32-bit anyway for Linux.
    tatsujb likes this.
  20. websterx01

    websterx01 Post Master General

    Messages:
    1,682
    Likes Received:
    1,063
    @DeathByDenim I confirmed that it is working for at least 16% (I'm too impatient to fully check it right now. I'll let you know later if there's any more issues). I plan on trying it out on two other computers that I have just to be a bit more thorough, but Windows is funny sometimes :p

    I haven't tried again on Lubuntu yet, I'm not ready to get back into linux with 3 papers due in 2 weeks :D Though I'm sure your launcher is fine there, since you run linux to test it on.
    DeathByDenim likes this.

Share This Page