Hi,
using
connection = openeo.connect(“openeo.vito.be”).authenticate_oidc()
don’t produce anything and timeout after 300 s
Can I get an account at openeo.vito.be and use something like
connection.authenticate_basic(“john”, “j0hn123”) as described at
https://open-eo.github.io/openeo-python-client/auth.html
Regards
/Jonas
Error message:
connection = openeo.connect(“openeo.vito.be”).authenticate_oidc()
OidcDeviceCodePollTimeout Traceback (most recent call last)
Cell In[10], line 1
----> 1 connection = openeo.connect(“openeo.vito.be”).authenticate_oidc()
File ~\AppData\Local\anaconda3\envs\HRVPP_openEO\Lib\site-packages\openeo\rest\connection.py:798, in Connection.authenticate_oidc(self, provider_id, client_id, client_secret, store_refresh_token, use_pkce, display, max_poll_time)
794 _log.info(“Trying device code flow.”)
795 authenticator = OidcDeviceAuthenticator(
796 client_info=client_info, use_pkce=use_pkce, display=display, max_poll_time=max_poll_time
797 )
→ 798 con = self._authenticate_oidc(
799 authenticator,
800 provider_id=provider_id,
801 store_refresh_token=store_refresh_token,
802 )
803 print(“Authenticated using device code flow.”)
804 return con
File ~\AppData\Local\anaconda3\envs\HRVPP_openEO\Lib\site-packages\openeo\rest\connection.py:528, in Connection._authenticate_oidc(self, authenticator, provider_id, store_refresh_token, fallback_refresh_token_to_store, oidc_auth_renewer)
516 def _authenticate_oidc(
517 self,
518 authenticator: OidcAuthenticator,
(…)
523 oidc_auth_renewer: Optional[OidcAuthenticator] = None,
524 ) → Connection:
525 “”"
526 Authenticate through OIDC and set up bearer token (based on OIDC access_token) for further requests.
527 “”"
→ 528 tokens = authenticator.get_tokens(request_refresh_token=store_refresh_token)
529 _log.info(“Obtained tokens: {t}”.format(t=[k for k, v in tokens._asdict().items() if v]))
530 if store_refresh_token:
File ~\AppData\Local\anaconda3\envs\HRVPP_openEO\Lib\site-packages\openeo\rest\auth\oidc.py:943, in OidcDeviceAuthenticator.get_tokens(self, request_refresh_token)
940 next_poll = elapsed() + poll_interval
942 poll_ui.show_progress(status=“Timed out”, include_bar=False)
→ 943 raise OidcDeviceCodePollTimeout(f"Timeout ({self._max_poll_time:.1f}s) while polling for access token.")
OidcDeviceCodePollTimeout: Timeout (300.0s) while polling for access token.