← Mục lục tài liệu

Clear Local Test Profile

key: manager.clear_local_test_profile nhóm: ManagerAction hàm Client A13: clear_local_test_profile

Chức năng

Xóa sạch thư mục sandbox local_test_profile. Dùng để reset về profile trắng khi cần test lại luồng đăng nhập từ đầu, thu hồi dung lượng, hoặc dọn cookie/session còn sót sau khi chạy xong. Không đụng tới profile gốc.

Chi tiết hoạt động

shutil.rmtree(runtime_profiles/local_test_profile, ignore_errors=True). Trả {target, deleted}deleted cho biết thư mục có tồn tại trước đó hay không.

Không đụng tới master profile — chỉ hủy bản sao. Idempotent: gọi khi chưa có thư mục vẫn trả về bình thường.

Khi nào dùng

Bộ ba sync (nạp) → local_browser_connect (dùng) → clear (hủy) bổ trợ nhau, không thay thế nhau.

Tham số (0)

Action này không có tham số riêng.

Payload MQTT gửi đi

{
  "version": "great-lotus-pyauto-v1",
  "action": {
    "key": "manager.clear_local_test_profile",
    "group": "ManagerAction",
    "function": "clear_local_test_profile"
  },
  "inputs": {},
  "meta": {
    "requestId": "<16 hex>",
    "requestTopic": "WP2_PC176",
    "responseTopic": "RES_WP2_PC176",
    "waitForResponse": true,
    "responseTimeoutSec": 60
  }
}

Publish lên topic bạn nhập ở ô Topic; nếu bật Wait For Response, node chờ Client trả lời trên RES_<topic> với đúng meta.requestId. return: "NG" ⇒ node ném lỗi.

Sinh tự động bởi tools/gen_doc_html.js từ ACTION_SPECS (package n8n-nodes-c12_pyautogui_web@0.1.34) · 2026-07-22 · Đừng sửa tay file này — sửa _notes/ hoặc source rồi chạy lại npm run doc:build.