Linux: Error when clicking "Download" button
Leshuguita opened this issue · 19 comments
Describe the bug
Just installed it, following the instructions from https://github.com/AM2R-Community-Developers/AM2RLauncher/wiki/Installation-Process#arch-linux, and an error pops up when clicking the Download button, saying "The type initializer for 'Libgit2Sharp.Core.NativeMethods' threw an exception"
Platform
- OS: Arch Linux
- AM2RLauncher Version: 2.3.0
Additional context
Add any other context about the problem here.
Log file
AM2RLauncher.log
When was the last time you -Syu
d? If it wasn't some time recently, can you try to -Syu
, reboot, and see if it still happens?
Also, from where did you get the launcher? The release on github, some aur package (if yes, which) or from flathub?
I'd last -Syu
d yesterday, before installing everyting. Still happens after another -Syu
and a reboot, with both the am2rlauncher
and am2rlauncher-git
packages
Hm, need to check later whether I can replicate.
In the meantime, would you be able to test the following:
Clone the Repo, and modify the following line in AM2RLauncher.csproj
- <PackageReference Include="LibGit2Sharp" Version="0.26.2" />
+ <PackageReference Include="LibGit2Sharp" Version="0.27.0-preview-0182 " />
Then try to compile it (instructions should be both in the Wiki, as well as in the PKGBUILD of am2rlauncher-git
)
Still not working, but different error: "could not load ssl libraries"
Logs:
AM2RLauncher.log
That sounds like libgit2/libgit2sharp#2003
According to the thread there, using 0.27.0-preview-0182
should fix it. What if for compiling, instead of using -r ubuntu.18.04-x64
, you use -r ubuntu.20.04-x64
?
(A workaround would probably be to install libssl-compat
or however its called, but non-arch distros don't offer those, so it'd be nice to find a proper workaround that works on all linux distros instead of just arch)
Didn't work either, same error.
It managed to start the download after installing the openssl-1.1
package, though I do not know if that's option on other distros
It probably is, but I wouldn't rely on it.
I guess something that can be tried as well is to just check all the 0.27 preview packages here and see if any one of them works? (and obviously remove openssl-1.1 before attempting)
https://www.nuget.org/packages/LibGit2Sharp/#versions-body-tab
any updates on this? the error still persists
As this is an upstream issue, the error will persist until it's fixed upstream. Updates will more likely be found in the linked libgit2sharp issue from above than here.
@rehtlaw @Leshuguita I've updated to the newest libgit2sharp release, can you pull down the artifacts and see if the error persists?
(https://github.com/AM2R-Community-Developers/AM2RLauncher/actions/runs/4667573051)
Nope, it works now!
Nope, it works now!
Do you have openssl-1.1
installed? If yes, can you please remove it and try without it again?
I made sure to delete openssl-1.1 before, and it also works for me.
Thank you! If anyone still has that error, feel free to reopen this issue.
Issue (hopefully) fixed due to c86dee0
Hello,
I am also trying to install AM2R on Linux Mint and I am getting the same error. I have added a photo the error.
Edit: I've also found the log file, here it is:
AM2RLauncher.log
I've cloned the repo and changed the libgit2sharp dependency to v0.29.0 like here in my pull request. I then ran dotnet publish AM2RLauncher.Gtk -p:PublishSingleFile=true -p:DebugType=embedded -c release -r ubuntu.18.04-x64 --no-self-contained -o LinuxBuild
in AM2RLauncher-main/AM2RLauncher .
I then get the following error:
"/home/jj/Documents/AM2RLauncher-main/AM2RLauncher/AM2RLauncher/MainForm/MainForm.Events.cs(268,64): error CS0117: 'CloneOptions' does not contain a definition for 'OnTransferProgress' [/home/jj/Documents/AM2RLauncher-main/AM2RLauncher/AM2RLauncher/AM2RLauncher.csproj]"
I've tried the same using -r ubuntu.20.04-x64
instead but I get the same error.
I've cloned the repo and changed the libgit2sharp dependency to v0.29.0 like here in my pull request. I then ran
dotnet publish AM2RLauncher.Gtk -p:PublishSingleFile=true -p:DebugType=embedded -c release -r ubuntu.18.04-x64 --no-self-contained -o LinuxBuild
in AM2RLauncher-main/AM2RLauncher .I then get the following error:
"/home/jj/Documents/AM2RLauncher-main/AM2RLauncher/AM2RLauncher/MainForm/MainForm.Events.cs(268,64): error CS0117: 'CloneOptions' does not contain a definition for 'OnTransferProgress' [/home/jj/Documents/AM2RLauncher-main/AM2RLauncher/AM2RLauncher/AM2RLauncher.csproj]"
I've tried the same using
-r ubuntu.20.04-x64
instead but I get the same error.
Never mind, I changed the dependency back to version 0.27.2 and it seems to be compiling fine. However, when I try to run AM2RLauncher in the LinuxBuild folder it doesn't seem to be running. Any advice on this?
Not unless I can see any log info.
I've actually switched to the flatpak version and I am trying to solve some issues with that at the moment, but here is the log file when I run AM2RLauncher in the LinuxBuild folder if you would like to take a look anyway.
AM2RLauncher.log