MediaElch icon indicating copy to clipboard operation
MediaElch copied to clipboard

With proxy enabled the library update does not work

Open b-m-f opened this issue 2 years ago • 15 comments

Describe the bug With the proxy enabled, the request to update the library in Kodi will not trigger

To Reproduce Steps to reproduce the behavior:

  1. Enable Socks5 Proxy
  2. Click on update Kodi library/Clean library
  3. Nothing is triggered on the Kodi Instance
  4. See error / Crash

Expected behavior Library update is triggered

MediaElch Version:

  • [ X] 2.8.16 stable

Operating System:

  • [X ] Linux (distribution: Fedora 35)

b-m-f avatar Mar 29 '22 17:03 b-m-f

Hi,

sorry to hear that. Proxies as well as the sync feature is not something I use myself. I will try to reproduce and fix this issue soon.

Does MediaElch crash? If so, do you get any output?

For others reading this: Help is welcome, though.

Regards, Andre

bugwelle avatar Apr 05 '22 16:04 bugwelle

Hi,

It does not affect MediaElch in any way. The API call simply doesn't reach the Kodi instance on the local network.

I'm guessing there I single point where all traffic leaves MediaElch from?

Maybe the Kodi Update function needs to have a special way of sending traffic or a boolean to bypass the proxy?

b-m-f avatar Apr 05 '22 16:04 b-m-f

Out of curiosity: What proxy are you using? i.e. do you use a local one or a public one? Is your Kodi instance reachable through the (public) proxy? Can you download movies/concerts/shows/... with the proxy enabled?

bugwelle avatar Apr 10 '22 18:04 bugwelle

The Kodi instance is not reachable through the proxy. It lives on the local network.

Downloading works as expected. Its a public SOCKS5 proxy.

b-m-f avatar Apr 15 '22 17:04 b-m-f

Hi,

ok. Maybe I am misunderstanding your issue, but if the Kodi instance can't be reached through the proxy, what do you expect MediaElch to do? We don't skip the proxy just for the Kodi instance. It is a global setting, i.e. either all or no network requests go through the proxy. :-)

Regards, Andre

bugwelle avatar Apr 22 '22 20:04 bugwelle

I was thinking to split the traffic. Sent internet traffic through a proxy and route traffic to the Kodi instance normally.

Purely for privacy concerns :)

b-m-f avatar Apr 23 '22 10:04 b-m-f

Ah, thanks. :-)

We use Qt's QNetworkProxy with QNetworkProxy::setApplicationProxy(proxy);, i.e. a global proxy that is used for all connections.

It may be possible to deactivate the proxy for the Kodi connection only. Would that be sufficient for you?

Regards, Andre

bugwelle avatar May 09 '22 10:05 bugwelle

That would fit the use-case 100%!

b-m-f avatar May 09 '22 13:05 b-m-f

Sorry for the late reply. #1442 will implement this. Disclaimer: I haven't deeply tested this.

Do you use an AppImage or did you build MediaElch yourself? :-)

bugwelle avatar May 27 '22 19:05 bugwelle

Using AppImage. But I can build it to test during the week.

b-m-f avatar May 28 '22 05:05 b-m-f

Latest AppImage available on https://mediaelch-downloads.ameyering.de/snapshots/Linux/

bugwelle avatar May 28 '22 15:05 bugwelle

MediaElch 2022-06-01 17:37:17.912 DEBUG : [KodiSync] Disbaled Proxy
MediaElch 2022-06-01 17:37:19.127 INFO  : [KodiSync] Start Sync
MediaElch 2022-06-01 17:37:23.408 WARN  : [TmdbApi] Network Error: "Operation canceled" for URL QUrl("https://api.themoviedb.org/3/configuration?api_key=5d832bdf69dcb884922381ab01548d5b&language=en-US")

The proxy doesnt seem to start back up again.

Going into the settings enables it again. MediaElch 2022-06-01 17:39:47.853 INFO : Using Proxy: Socks5Proxy

b-m-f avatar Jun 01 '22 15:06 b-m-f

MediaElch_linux_2.8.17-dev_2022-06-01_03-16_git-master-387e02f.AppImage is the version I have tried

b-m-f avatar Jun 01 '22 15:06 b-m-f

The proxy doesnt seem to start back up again.

hmmm... Should only be disabled for Kodi. Could [TmdbApi] Network Error: "Operation canceled" for URL be due to the proxy or do you think this happens because the proxy is not used?

bugwelle avatar Jun 01 '22 15:06 bugwelle

I'll recheck soon and let you know!

b-m-f avatar Jun 01 '22 16:06 b-m-f

I'm closing this issue due to inactivity. If you find the time to re-check and the issue still persists, don't hesitate to reply and I will re-open this issue.

Regards, Andre

bugwelle avatar Jul 31 '23 19:07 bugwelle