Skip to content

Multi-step form POST does not update page content (SAP SAML login) #1890

@MayoK-sys

Description

@MayoK-sys

Description

When using Lightpanda via CDP (Playwright connect_over_cdp), multi-step form submissions where the server returns a new page with different fields do not update the page content. The DOM remains unchanged after form.submit().

Use Case

Automating login to SAP for Me (me.sap.com) which uses SAP Universal ID SAML 2.0 authentication at accounts.sap.com. The login is a two-step form:

  1. Step 1: Enter username → submit form → server returns new page with password field
  2. Step 2: Enter password → submit form → SAML assertion redirect chain

Steps to Reproduce

# Using Playwright connected to Lightpanda CDP server
page.goto("https://me.sap.com/calendar/planEvts")  # Redirects through SAML to accounts.sap.com
# Login form loads correctly — #j_username is found ✓

page.evaluate("""
    document.getElementById('j_username').value = 'myuser';
    document.getElementById('logOnForm').submit();
""")
# After submit: URL stays at /saml2/idp/sso (correct — it POSTs to same URL)
# But: document.getElementById('j_password') returns null
# Expected: password field should now be present (server returns new HTML with password input)

What Works

  • ✅ Initial navigation through JS redirects (me.sap.com → XSUAA → SAML discovery → accounts.sap.com)
  • ✅ Login form HTML renders correctly with #j_username field
  • page.evaluate() can fill and submit the form
  • ✅ Memory usage is excellent: 33MB for the full SAP for Me SPA (vs 500MB+ for Chromium)

What Fails

  • ❌ After form.submit(), the page content does not update to reflect the server's response
  • document.getElementById('j_password') returns null after username submission
  • ❌ The page DOM appears to stay frozen at the pre-submit state

Environment

  • Lightpanda v0.2.6 (lightpanda-x86_64-linux)
  • Ubuntu 24.04 (WSL2)
  • Playwright 1.49.1 (Python) connecting via CDP
  • CDP server started with: lightpanda serve --host 127.0.0.1 --port 9222

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions