debugging-surveys
Skill này làm gì
Skill này chẩn đoán các vấn đề khảo sát, chẳng hạn khảo sát không xuất hiện hoặc phản hồi bị mất, trên ứng dụng web và di động. Skill dành cho lập trình viên và nhân viên hỗ trợ gặp các vấn đề với khảo sát.
Khi nào nên dùng
- ✓Khi một khảo sát không xuất hiện với những người dùng lẽ ra phải thấy nó.
- ✓Khi một khảo sát có ít phản hồi hơn mong đợi, hoặc một số phản hồi bị thiếu.
- ✓Khi chỉ một phần khảo sát được trả lời, hoặc khảo sát hiển thị sai nền tảng.
Liên kết skill
https://github.com/PostHog/posthog/blob/master/products/surveys/skills/debugging-surveys/SKILL.mdSao chép rồi dán vào AI của bạn (Claude, ChatGPT hoặc Cursor) và nhờ nó làm theo hướng dẫn.
Cách dùng
Cách dễ nhất: sao chép tin nhắn và dán vào AI của bạn. AI sẽ đọc skill và làm theo hướng dẫn.
Tin nhắn có sẵn để dán
Dành cho Claude Code, Codex hoặc Cursor: chạy lệnh trong thư mục dự án của bạn và skill sẽ được cài đặt.
Tải tệp SKILL.md về và thả vào thư mục skill của agent.
Ví dụ cách nhờ AI
“Vì sao khảo sát trong ứng dụng của tôi không hiển thị với những người dùng lẽ ra phải thấy nó?”
5 skill mới mỗi tuần. Đọc chỉ 1 phút.
Cách hoạt động
Skill kiểm tra xem mỗi người dùng có đáp ứng các quy tắc đủ điều kiện của khảo sát hay không, chẳng hạn nhắm mục tiêu và các tính năng được nền tảng hỗ trợ. Hầu hết vấn đề là do các cổng đủ điều kiện chứ không phải lỗi hiển thị, nên skill tìm xem cổng nào đã không qua và vì sao.
Nội dung kỹ thuật (SKILL.md gốc)
Lấy nguyên văn từ GitHub, do tác giả viết bằng tiếng Anh.
Debugging surveys
PostHog Surveys is a no-code in-app form builder. A customer creates a survey in the PostHog UI; it must then be evaluated and rendered by whichever SDK their app runs. Most "survey not showing" tickets are eligibility problems, not rendering bugs — the SDK correctly decided the user is not eligible, and the job is to find which gate failed and why.
Access requirements
Use PostHog MCP tools or the survey API to inspect survey configuration and responses. A checkout of the PostHog repository is not required for these diagnostic steps.
Cross-SDK feature parity (check this FIRST)
A large class of tickets is "customer expects a feature their platform doesn't support."
Confirm the survey's lib / the customer's platform before anything else, then consult
this table. Verified against the SDK source — re-verify if it's been months, the gaps
get filled over time.
| Feature | Web (posthog-js) | iOS | Android | Flutter | React Native |
|---|---|---|---|---|---|
| Rendering | DOM + shadow root | Native SwiftUI (SurveysWindow) |
No built-in UI — delegate only | Dart widgets (SurveyBottomSheet) |
RN components (SurveyModal) |
| Event-based triggers | yes (since 1.137.0, 2024-06-05) | yes | yes | yes (native side) | yes |
| URL / screen targeting | yes | decoded but NOT evaluated (// TODO) |
decoded but NOT evaluated | NOT evaluated (native gap) | explicitly excluded in filter |
| Feature-flag / cohort targeting | yes | yes | yes | yes (native side) | yes |
seenSurveyWaitPeriodInDays |
yes | yes | yes | yes (native side) | yes (≥ 4.81.5) |
surveyPopupDelaySeconds |
yes | not implemented | not implemented | not implemented | not implemented (TODO) |
enable_partial_responses |
yes (≥ 1.240.0) | no | no | no | no |
skipSubmitButton (auto-submit) |
yes (≥ 1.244.0) | no | no | no | no |
The last two rows are per the editor's own help text ("Doesn't work with the mobile SDKs for now" / "Not available for the mobile SDKs at the moment") rather than a per-SDK source audit.
Consequences worth memorizing:
surveyPopupDelaySecondsis web-only. If a mobile ticket blames the delay, it's a red herring.- Partial responses and auto-submit are web-only too. On mobile a survey always stores one response at the end, and a rating tap never self-submits. Don't carry a web diagnosis onto a mobile ticket.
- URL targeting is effectively web-only. Mobile SDKs decode the field but never enforce it; React Native filters those surveys out entirely. A mobile survey with a URL condition behaves as "no URL condition" (mobile/flutter) or "never shows" (RN).
- Android ships no survey UI. The app (or the Flutter plugin) must provide a
PostHogSurveysDelegate. "Survey never renders on Android" is often a missing delegate, not a PostHog bug. - Flutter is hybrid: triggering/eligibility runs in the native iOS/Android layer; rendering is Dart (
SurveyService.showSurvey→showModalBottomSheet). It does not "just call native" for UI. So a Flutter rendering bug lives in Dart; a Flutter eligibility bug lives in native. - React Native enforces the wait period from 4.81.5. Older versions skip the check, s
Câu hỏi thường gặp
Vì sao một khảo sát thường không được hiển thị?
Thường là SDK đã quyết định người dùng không đủ điều kiện, chẳng hạn khi không đáp ứng một quy tắc nhắm mục tiêu, chứ không phải lỗi hiển thị.
Mọi nền tảng có hỗ trợ cùng các tính năng khảo sát không?
Không. Skill có một bảng so sánh các tính năng trên web, iOS, Android, Flutter và React Native.
Nó có cần mã nguồn của ứng dụng không?
Không. Nó dùng các công cụ PostHog và API khảo sát để kiểm tra cấu hình và phản hồi.
Chi tiết
Mô tả gốc của tác giả
Diagnose PostHog Surveys configuration and responses across all five SDKs (web/posthog-js, iOS, Android, Flutter, React Native). Use whenever a Surveys support ticket is pasted ("survey not showing", "fewer responses than expected", "responses disappeared", "responses are incomplete", "only the first question was answered", "the user says they didn't mean to submit", "survey shows on wrong platform"), or when diagnosing why a survey does or doesn't display. Covers the eligibility pipeline, how a response actually gets stored (partial responses, branching, optional questions, auto-submit), cros
repo: PostHog/posthog
Độ phổ biến
- Sao GitHub
- 41k
- Vị trí xếp hạng
- #6959
- Giấy phép
- —
- Cập nhật
- 2/11/2026
Bình luận
- …
Thêm skill từ kho mã này
depot-ci
41kGiúp agent của bạn thiết lập và chạy quy trình Depot CI, một lựa chọn thay thế GitHub Actions, gồm chuyển các quy trình hiện có và đọc nhật ký chạy.
depot-container-builds
41kGiúp agent của bạn build image Docker trên các builder từ xa của Depot, gồm image đa nền tảng, đẩy lên registry và sửa lỗi build.
depot-github-runners
41kGiúp agent của bạn chuyển các job GitHub Actions sang runner do Depot quản lý, chọn kích thước và nhãn runner, và xử lý lỗi thiết lập runner.
editing-agents-md
41kGiúp agent của bạn quyết định một quy tắc nên nằm trong file AGENTS.md hay CLAUDE.md, và viết sao cho quy tắc được tuân thủ mà file không bị phình to.
Skill tương tự
openclaw-update
394kGiúp agent của bạn cập nhật OpenClaw Gateway đang có, chọn cách cập nhật phù hợp với cách cài đặt và giữ phiên làm việc của bạn hoạt động.
diagnose-gateway
394kGiúp agent của bạn tìm hiểu vì sao OpenClaw Gateway bị lỗi bằng cách kiểm tra cài đặt, kênh và cổng mà không thay đổi gì.
crabbox-apps
394kGiúp agent của bạn mở và chạy một app trên máy đám mây tạm thời, rồi hiển thị giao diện của nó trong thanh bên của chat.