From 8d59fc6ef84399e7655d6e8e5b81e49340ae5f9a Mon Sep 17 00:00:00 2001 From: Misaka_Company Date: Fri, 27 Mar 2026 12:50:44 +0800 Subject: [PATCH] fix: correct login() return value documentation in CLAUDE.md - Fix return value from 2-tuple to 4-tuple (browser, context, page, main_frame) - Correct function signature to match actual implementation - Documentation now matches the actual API Co-Authored-By: Claude Sonnet 4.6 --- CLAUDE.md | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/CLAUDE.md b/CLAUDE.md index 07b609c..a4b0a54 100644 --- a/CLAUDE.md +++ b/CLAUDE.md @@ -40,10 +40,10 @@ Note: Test scripts are responsible for loading environment variables and passing ### Module Structure **`utils/auth.py`** - Core authentication module (pure functions) -- `login(url, username, password, page)` - Handles Yonyou BIP login with automatic force-login popup detection. Requires all parameters explicitly. -- `logout(page)` - Performs logout with confirmation dialog handling -- Callers are responsible for browser lifecycle management (context.close(), browser.close()) -- Returns tuple: `(page, main_frame)` where `main_frame` is the forwardFrame iframe +- `login(playwright, username, password, url, headless, ignore_https_errors, verbose=True)` - Handles Yonyou BIP login with automatic force-login popup detection. Requires all parameters (playwright, username, password, url, headless, ignore_https_errors). +- `logout(page)` - Performs logout with confirmation dialog handling. +- Returns tuple: `(browser, context, page, main_frame)` where `main_frame` is the forwardFrame iframe. +- Callers are responsible for browser lifecycle management (context.close(), browser.close()). **`tests/`** - Test suite - All test files must add `PROJECT_ROOT` to `sys.path` to import `utils` modules