Repository navigation
O2 login succeeds in Chromium, but session detection times out and o2-session.json is never created #16
Description
Issue description
Hello, and thank you for this project. I have deployed the gateway successfully on a 64-bit Raspberry Pi by building the image locally for ARM64. The container and the interactive browser work, and O2 Cloud authentication completes successfully in Chromium. However, the gateway does not detect or persist the authenticated O2 session.
Environment
Raspberry Pi running Debian GNU/Linux 13 (Trixie), ARM64 / linux/arm64/v8.
Docker Engine 29.8.2 and Docker Compose.
Repository cloned from the main branch.
The published latest image did not include an ARM64 manifest, so docker-compose.yml was changed from image: to build: .
The local image built successfully and the container reports healthy.
PUID=1000 and PGID=1000.
CLOUD_PROVIDER=o2.
docker compose ps
o2cloud-webdav o2cloud_gateway_webdav-o2cloud-webdav Up (healthy) 0.0.0.0:6080->6080/tcp, 0.0.0.0:8088->8080/tcp
Steps to reproduce
Open the administration panel at /admin and sign in as the administrator.
Start the interactive O2 login.
Open the noVNC session and complete the O2 authentication in the Chromium browser.
O2 displays “Te has identificado correctamente” and then redirects automatically to the authenticated O2 Cloud area.
The real O2 Cloud content, including photos, is visible in Chromium.
Wait for the gateway to detect and save the session.
Actual result
The administration panel continues to show “Sesión: Sin configurar”.
Interactive login ends with: “O2 login timed out before a valid session was detected”.
The last error is: “O2 session is not configured”.
The expected session file /config/secrets/o2-session.json is never created.
Pressing “Probar conexión” raises CloudSessionMissing because no gateway session has been configured.
browser session renewal timed out
provider=o2
pageLocation=cloud.o2online.es/
o2gateway.operations.errors.CloudSessionMissing: O2 session is not configured
Expected result
After Chromium completes the O2 login and reaches the authenticated O2 Cloud area, the gateway should detect the valid browser session, create /config/secrets/o2-session.json, and show an active/configured O2 session in the administration panel.
Diagnostic evidence
The container health checks return HTTP 200.
Uvicorn starts successfully and the gateway reports “o2cloud gateway started”.
noVNC, Xvfb, Chromium and the O2 login page work correctly.
The persistent Chromium profile is created under /config/playwright-o2-profile/o2.
The profile contains Cookies, IndexedDB, Local Storage, Session Storage and other data for cloud.o2online.es.
The directory /config/secrets exists, is writable by o2gateway:o2gateway, and remains empty.
The installed gateway settings confirm the default session path is /config/secrets/o2-session.json.
Repeating the login with a restarted healthy container produces the same result.
/usr/local/lib/python3.12/site-packages/o2gateway/settings.py:
o2_session_file: str = "/config/secrets/o2-session.json"
Relevant configuration
CLOUD_PROVIDER=o2
PUID=1000
PGID=1000
CONFIG_DIR=/config
CACHE_DIR=/cache
DATA_DIR=/data
Question
Has the O2 Cloud login flow or the session-detection condition changed recently? Is there an additional debug mode or a supported method to import/export the authenticated Chromium session when the browser reaches the private O2 Cloud area but the gateway does not create o2-session.json?
Additional note
This does not appear to be the same as the noVNC black-screen or Chromium startup issue. In this case Chromium launches, authentication succeeds, and the authenticated O2 Cloud content is displayed. The failure occurs afterward, while detecting or exporting the session for API use.
I am also attaching a Word document containing the complete steps, configuration, diagnostic checks, and results obtained during the installation and troubleshooting process.
Thank you.
Raúl García
Activity
rulogar1234 commentedon Oct 4, 2026
P.D.
Podemos hablar español si lo prefieres.
garanda21 commentedon Oct 7, 2026
Thank you for the detailed report. The symptoms match the O2 session-capture issue reported in #14 and #17. The fix is now included in v0.1.2.
O2 requires the gateway to reuse the browser's device ID when replaying the captured session. Previously, a regular web login could leave that field empty, causing the gateway to send its fallback ID and receive 401 even though Chromium displayed the authenticated account. PR #15 captures the device ID from the configured O2 API requests. The change is restricted to O2. In #14, the reporter confirmed that the test image fixes the capture timeout; #17 also reports that manually importing a session containing
deviceIdworks.For your Raspberry Pi, the published v0.1.2 image is still linux/amd64 only. Please update the source checkout to tag
v0.1.2, retain your localbuild: .Compose configuration, and rebuild on the Pi:Preserve the
config,cache, anddatavolumes. Complete assisted login again if no valid session was previously saved, then check that the panel reports a captured session and that WebDAV listing works. A manual session export should not be necessary for this capture issue after the fix; ARM64 operation still needs confirmation on your environment.PR #22, also included in v0.1.2, disables proactive Chromium renewal by default for O2 while retaining API keepalive and reactive recovery. Remove any explicit positive
O2_PROACTIVE_REAUTH_SECONDSoverride or set it to0to use the tested configuration. A real O2 session test on Synology remained usable for over 104 hours and accepted Hyper Backup uploads with proactive renewal disabled.Please report whether the v0.1.2 ARM64 rebuild resolves the capture timeout. If it persists, include the displayed error and a short redacted log excerpt from the login attempt, without session keys, cookies, or tokens.
garanda21 commentedon Oct 10, 2026
Closing this as addressed by PR #15, released in v0.1.2. The gateway now captures and reuses the O2 browser device ID when validating the session, fixing the pattern where Chromium shows the authenticated account but the gateway cannot capture a valid session.
Related reports have now received user confirmation:
pr15test image fixed the problem, then confirmed successful login with the latest release.latestrestored assisted login, closed the browser after session capture, and left WebDAV accessible.This is a closure based on the matching symptoms, shipped fix, and confirmations in those related reports; we do not yet have confirmation from your Raspberry Pi installation. v0.1.2 is still published for amd64 only, so on ARM64 please rebuild from the v0.1.2 tag or newer main while retaining your volumes. Native ARM64 publication has been merged in #23 but is not yet included in a published release.
If session capture still times out after updating and completing assisted login again, please reply and we can reopen this issue. Include the gateway version/source revision and a short redacted log excerpt, without cookies, validation keys, or tokens.