JohanDegraeve / xdripswift

xdrip for iOS, written in Swift
GNU General Public License v3.0
344 stars 343 forks source link

LibreLink Up EU2 connection error #490

Closed vanzaam closed 11 months ago

vanzaam commented 11 months ago

When I try to connect librelink up - United Kingdom (EU2 region) - it doesn't work.

(would it better - manually select server)

App name: xDrip4iO5 Version: 5.0.2 Build number: 4193

2023-12-28 22:04:30.1640 5.0.2 4194 LibreLinkUpFollowManager            in checkLoginAndConnections, redirect flag received. Switching region from 'Global' to 'Global' and repeating checkLogin
2023-12-28 22:04:30.1650 5.0.2 4194 LibreLinkUpFollowManager            in checkLoginAndConnections, auth token is nil or is expired so processing new login request
2023-12-28 22:04:30.1660 5.0.2 4194 LibreLinkUpFollowManager            in requestLogin, running login request
2023-12-28 22:04:30.1670 5.0.2 4194 LibreLinkUpFollowManager            in requestLogin, no region stored, will try and login with generic URL and see if we get redirected
2023-12-28 22:04:30.1680 5.0.2 4194 LibreLinkUpFollowManager            in requestLogin, processing login request with URL: https://api.libreview.io/llu/auth/login
2023-12-28 22:04:31.1710 5.0.2 4194 LibreLinkUpFollowManager            in requestLogin, server response status code: 200
2023-12-28 22:04:31.1750 5.0.2 4194 LibreLinkUpFollowManager            in requestLogin, server response: {"status":0,"data":{"redirect":true,"region":"eu2"}}

2023-12-28 22:04:31.1780 5.0.2 4194 LibreLinkUpFollowManager            in checkLoginAndConnections, redirect flag received. Switching region from 'Global' to 'Global' and repeating checkLogin
2023-12-28 22:04:31.1800 5.0.2 4194 LibreLinkUpFollowManager            in checkLoginAndConnections, auth token is nil or is expired so processing new login request
2023-12-28 22:04:31.1810 5.0.2 4194 LibreLinkUpFollowManager            in requestLogin, running login request
2023-12-28 22:04:31.1830 5.0.2 4194 LibreLinkUpFollowManager            in requestLogin, no region stored, will try and login with generic URL and see if we get redirected
2023-12-28 22:04:31.1840 5.0.2 4194 LibreLinkUpFollowManager            in requestLogin, processing login request with URL: https://api.libreview.io/llu/auth/login
2023-12-28 22:04:31.2330 5.0.2 4194 LibreLinkUpFollowManager            in requestLogin, server response status code: 429
2023-12-28 22:04:31.2360 5.0.2 4194 LibreLinkUpFollowManager            in requestLogin, server response: {}
2023-12-28 22:04:31.2390 5.0.2 4194 LibreLinkUpFollowManager            in requestLogin, unable to process response. Existing authentication data will be nillified
2023-12-28 22:04:31.2530 5.0.2 4194 LibreLinkUpFollowManager            in checkLoginAndConnections, error = The operation couldn’t be completed. (xdrip.(unknown context at $1003615d4).LibreLinkUpFollowError error 6.)
2023-12-28 22:04:31.2550 5.0.2 4194 LibreLinkUpFollowManager        in scheduleNewDownload
2023-12-28 22:04:34.6530 5.0.2 4194 LibreLinkUpFollowManager        in eventhandler checking if audioplayer exists
2023-12-28 22:04:34.6560 5.0.2 4194 LibreLinkUpFollowManager        playing audio every  seconds. LibreLinkUp keep-alive: Normal
2023-12-28 22:04:39.6520 5.0.2 4194 LibreLinkUpFollowManager        in eventhandler checking if audioplayer exists
2023-12-28 22:04:39.6560 5.0.2 4194 LibreLinkUpFollowManager        playing audio every  seconds. LibreLinkUp keep-alive: Normal
2023-12-28 22:04:44.6520 5.0.2 4194 LibreLinkUpFollowManager        in eventhandler checking if audioplayer exists
2023-12-28 22:04:44.6560 5.0.2 4194 LibreLinkUpFollowManager        playing audio every  seconds. LibreLinkUp keep-alive: Normal
2023-12-28 22:04:49.6520 5.0.2 4194 LibreLinkUpFollowManager        in eventhandler checking if audioplayer exists
2023-12-28 22:04:49.6550 5.0.2 4194 LibreLinkUpFollowManager        playing audio every  seconds. LibreLinkUp keep-alive: Normal
2023-12-28 22:04:54.6520 5.0.2 4194 LibreLinkUpFollowManager        in eventhandler checking if audioplayer exists
2023-12-28 22:04:54.6550 5.0.2 4194 LibreLinkUpFollowManager        playing audio every  seconds. LibreLinkUp keep-alive: Normal
2023-12-28 22:04:59.6500 5.0.2 4194 LibreLinkUpFollowManager        in eventhandler checking if audioplayer exists
2023-12-28 22:04:59.6510 5.0.2 4194 LibreLinkUpFollowManager        playing audio every  seconds. LibreLinkUp keep-alive: Normal
2023-12-28 22:05:04.6520 5.0.2 4194 LibreLinkUpFollowManager        in eventhandler checking if audioplayer exists
2023-12-28 22:05:04.6550 5.0.2 4194 LibreLinkUpFollowManager        playing audio every  seconds. LibreLinkUp keep-alive: Normal
2023-12-28 22:05:09.6520 5.0.2 4194 LibreLinkUpFollowManager        in eventhandler checking if audioplayer exists
2023-12-28 22:05:09.6560 5.0.2 4194 LibreLinkUpFollowManager        playing audio every  seconds. LibreLinkUp keep-alive: Normal
2023-12-28 22:05:14.6520 5.0.2 4194 LibreLinkUpFollowManager        in eventhandler checking if audioplayer exists
2023-12-28 22:05:14.6550 5.0.2 4194 LibreLinkUpFollowManager        playing audio every  seconds. LibreLinkUp keep-alive: Normal
2023-12-28 22:05:19.6480 5.0.2 4194 LibreLinkUpFollowManager        in eventhandler checking if audioplayer exists
2023-12-28 22:05:19.6520 5.0.2 4194 LibreLinkUpFollowManager        playing audio every  seconds. LibreLinkUp keep-alive: Normal
2023-12-28 22:05:24.6530 5.0.2 4194 LibreLinkUpFollowManager        in eventhandler checking if audioplayer exists
2023-12-28 22:05:24.6560 5.0.2 4194 LibreLinkUpFollowManager        playing audio every  seconds. LibreLinkUp keep-alive: Normal
2023-12-28 22:05:29.5950 5.0.2 4194 RootView                       Application will enter foreground
2023-12-28 22:05:32.4840 5.0.2 4194 LibreLinkUpFollowManager        in download
2023-12-28 22:05:32.4880 5.0.2 4194 LibreLinkUpFollowManager            setting nightScoutSyncTreatmentsRequired to true, this will also initiate a treatments sync
2023-12-28 22:05:32.4900 5.0.2 4194 LibreLinkUpFollowManager            in checkLoginAndConnections, auth token is nil or is expired so processing new login request
2023-12-28 22:05:32.4930 5.0.2 4194 LibreLinkUpFollowManager            in requestLogin, running login request
2023-12-28 22:05:32.4950 5.0.2 4194 LibreLinkUpFollowManager            in requestLogin, no region stored, will try and login with generic URL and see if we get redirected
2023-12-28 22:05:32.4960 5.0.2 4194 LibreLinkUpFollowManager            in requestLogin, processing login request with URL: https://api.libreview.io/llu/auth/login
2023-12-28 22:05:33.3270 5.0.2 4194 LibreLinkUpFollowManager            in requestLogin, server response status code: 200
2023-12-28 22:05:33.3300 5.0.2 4194 LibreLinkUpFollowManager            in requestLogin, server response: {"status":0,"data":{"redirect":true,"region":"eu2"}}

2023-12-28 22:05:33.3330 5.0.2 4194 LibreLinkUpFollowManager            in checkLoginAndConnections, redirect flag received. Switching region from 'Global' to 'Global' and repeating checkLogin
2023-12-28 22:05:33.3360 5.0.2 4194 LibreLinkUpFollowManager            in checkLoginAndConnections, auth token is nil or is expired so processing new login request
2023-12-28 22:05:33.3380 5.0.2 4194 LibreLinkUpFollowManager            in requestLogin, running login request
2023-12-28 22:05:33.3400 5.0.2 4194 LibreLinkUpFollowManager            in requestLogin, no region stored, will try and login with generic URL and see if we get redirected
2023-12-28 22:05:33.3410 5.0.2 4194 LibreLinkUpFollowManager            in requestLogin, processing login request with URL: https://api.libreview.io/llu/auth/login
2023-12-28 22:05:34.0440 5.0.2 4194 LibreLinkUpFollowManager            in requestLogin, server response status code: 200
2023-12-28 22:05:34.0470 5.0.2 4194 LibreLinkUpFollowManager            in requestLogin, server response: {"status":0,"data":{"redirect":true,"region":"eu2"}}

2023-12-28 22:05:34.0500 5.0.2 4194 LibreLinkUpFollowManager            in checkLoginAndConnections, redirect flag received. Switching region from 'Global' to 'Global' and repeating checkLogin
2023-12-28 22:05:34.0510 5.0.2 4194 LibreLinkUpFollowManager            in checkLoginAndConnections, auth token is nil or is expired so processing new login request
2023-12-28 22:05:34.0530 5.0.2 4194 LibreLinkUpFollowManager            in requestLogin, running login request
2023-12-28 22:05:34.0550 5.0.2 4194 LibreLinkUpFollowManager            in requestLogin, no region stored, will try and login with generic URL and see if we get redirected
2023-12-28 22:05:34.0570 5.0.2 4194 LibreLinkUpFollowManager            in requestLogin, processing login request with URL: https://api.libreview.io/llu/auth/login
2023-12-28 22:05:34.1100 5.0.2 4194 LibreLinkUpFollowManager            in requestLogin, server response status code: 429
2023-12-28 22:05:34.1130 5.0.2 4194 LibreLinkUpFollowManager            in requestLogin, server response: {}
2023-12-28 22:05:34.1150 5.0.2 4194 LibreLinkUpFollowManager            in requestLogin, unable to process response. Existing authentication data will be nillified
2023-12-28 22:05:34.1170 5.0.2 4194 LibreLinkUpFollowManager            in checkLoginAndConnections, error = The operation couldn’t be completed. (xdrip.(unknown context at $1003615d4).LibreLinkUpFollowError error 6.)
2023-12-28 22:05:34.1200 5.0.2 4194 LibreLinkUpFollowManager        in scheduleNewDownload

xdrip appinfo (1).txt xdriptrace.0 (1).log

vanzaam commented 11 months ago

Please, add function to manually select which server should be used

paulplant commented 11 months ago

Thanks for the attached information. It's useful.

There is no need to manually select the server. The app should detect and redirect correctly, but it isn't doing it here.

I'll check it tomorrow but this is the first time somebody has tested and been redirected to the eu2 server. It should be an easy fix.

paulplant commented 11 months ago

fixed by #489