flathub / com.amazon.Workspaces

https://flathub.org/apps/details/com.amazon.Workspaces
4 stars 7 forks source link

Unable to login #29

Closed mberlinger3 closed 2 years ago

mberlinger3 commented 2 years ago

I cannot login and keep getting a "Contact Network Admin" error. Works fine through the native ubuntu app.

System:

jkatzmewing commented 2 years ago

Samesies. Log attached below.

I noticed this in the logs. Looks like a shared library may be missing?

WorkSpacesClient_2022_10_07_13_00_09.log


 ---> Autofac.Core.DependencyResolutionException: An exception was thrown while invoking the constructor 'Void .ctor(WorkSpacesClient.Gtk.WindowManager.IGtkWindowManager, WorkSpacesClient.Common.Infrastructure.IDevice)' on type 'GtkPcoipProtocolAdapter'.
 ---> System.DllNotFoundException: Unable to load shared library 'pcoip_core' or one of its dependencies. In order to help diagnose loading problems, consider setting the LD_DEBUG environment variable: libpcoip_core: cannot open shared object file: No such file or directory
   at WorkSpacesClient.Gtk.InSession.Pcoip.GtkPcoipProtocolAdapter.pcoip_core_api_version_get()
   at WorkSpacesClient.Gtk.InSession.Pcoip.GtkPcoipProtocolAdapter..ctor(IGtkWindowManager windowManager, IDevice device) in /Users/jenkins/workspace/Singularity-Xamarin-Linux2/src/WorkSpacesClient.Gtk/InSession/Pcoip/GtkPcoipProtocolAdapter.cs:line 67
   at lambda_method(Closure , Object[] )
   at Autofac.Core.Activators.Reflection.ConstructorParameterBinding.Instantiate()
   --- End of inner exception stack trace ---
   at Autofac.Core.Activators.Reflection.ConstructorParameterBinding.Instantiate()
   at Autofac.Core.Activators.Reflection.ReflectionActivator.ActivateInstance(IComponentContext context, IEnumerable`1 parameters)
   at Autofac.Core.Resolving.InstanceLookup.CreateInstance(IEnumerable`1 parameters)
   --- End of inner exception stack trace ---
   at Autofac.Core.Resolving.InstanceLookup.CreateInstance(IEnumerable`1 parameters)
   at Autofac.Core.Resolving.InstanceLookup.Execute()
   at Autofac.Core.Resolving.ResolveOperation.GetOrCreateInstance(ISharingLifetimeScope currentOperationScope, ResolveRequest request)
   at Autofac.Core.Resolving.ResolveOperation.ResolveComponent(ResolveRequest request)
   at Autofac.Core.Resolving.ResolveOperation.Execute(ResolveRequest request)
   at Autofac.Core.Lifetime.LifetimeScope.ResolveComponent(ResolveRequest request)
   at Autofac.ResolutionExtensions.TryResolveService(IComponentContext context, Service service, IEnumerable`1 parameters, Object& instance)
   at Autofac.ResolutionExtensions.ResolveService(IComponentContext context, Service service, IEnumerable`1 parameters)
   at Autofac.ResolutionExtensions.Resolve(IComponentContext context, Type serviceType, IEnumerable`1 parameters)
   at Autofac.ResolutionExtensions.Resolve[TService](IComponentContext context, IEnumerable`1 parameters)
   at Autofac.ResolutionExtensions.Resolve[TService](IComponentContext context)
   at WorkSpacesClient.Gtk.InSession.GtkSessionFactory.ConstructPcoipSession(PreparedResource resource) in /Users/jenkins/workspace/Singularity-Xamarin-Linux2/src/WorkSpacesClient.Gtk/InSession/GtkSessionFactory.cs:line 33
   at WorkSpacesClient.Gtk.UseCases.PcoipSessionProvisionUseCase.PcoipSessionProvisionRouter.NavigateToStreamingUseCase(PreparedResource resource) in /Users/jenkins/workspace/Singularity-Xamarin-Linux2/src/WorkSpacesClient.Gtk/UseCases/PcoipSessionProvisionUseCase/PcoipSessionProvisionRouter.cs:line 43
   at WorkSpacesClient.Common.UseCases.SessionProvisionUseCase.SessionProvisionPresenter.BeginUseCase() in /Users/jenkins/workspace/Singularity-Xamarin-Linux2/src/WorkSpacesClient.Common/UseCases/PcoipSessionProvisionUseCase/SessionProvisionPresenter.cs:line 65
2022-10-07T12:58:08.416Z { Version: "4.3.0.1766" }: [INF] Navigating to Use Case WorkSpacesClient.Common.UseCases.ErrorUseCase.ErrorPresenter```
Nightmayr commented 2 years ago

Same issue, and seeing the same thing in the logs as @jkatzmewing, It does look like the library is present:

$ ls -l /var/lib/flatpak/app/com.amazon.Workspaces/x86_64/stable/active/files/extra/bin/libpcoip_core.so 
-rwxr-xr-x. 1 root root 7123496 Jul 30 03:40 /var/lib/flatpak/app/com.amazon.Workspaces/x86_64/stable/active/files/extra/bin/libpcoip_core.so

I'm guessing LD_LIBRARY_PATH might need to be set to include the path to that lib

danieldg commented 2 years ago

Note ldd /app/extra/bin/libpcoip_core.so hints that there are some missing libraries which will prevent libpcoip_core.so from being loaded:

        libusb-1.0.so.0 => not found
        libhiredis.so.0.13 => not found

Adding those two files to the flatpak is also needed; I haven't had time to find them and test that it works with them added.

danieldg commented 2 years ago

Just confirmed, unpacking the libraries from https://packages.ubuntu.com/bionic/libusb-1.0-0 and https://packages.ubuntu.com/bionic/libs/libhiredis0.13 and placing them inside the flatpak (adjusting LD_LIBRARY_PATH to point where I dropped them) will fix this issue.

bbhtt commented 2 years ago

Note ldd /app/extra/bin/libpcoip_core.so hints that there are some missing libraries which will prevent libpcoip_core.so from being loaded:

        libusb-1.0.so.0 => not found
        libhiredis.so.0.13 => not found

Adding those two files to the flatpak is also needed; I haven't had time to find them and test that it works with them added.

Thank you for the analysis. I've opened a PR with those two libraries added, please test the build once posted and let me know if it works.

I think the dependencies were added with 4.3.x

The original maintainer enabled auto-merging PRs as long as the build passes, this is a bad idea because there is no manual testing (they were last active here in 2020, inactive since) and it is a repackage of the deb.

jkatzmewing commented 2 years ago

I can confirm the latest version on Flathub works :D