[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M69ANR5T01TYC63Z1X4E2YQV":3,"skill-same:01M69ANR5T01TYC63Z1X4E2YQV":111},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":8,"repositoryFullName":9,"ownerLogin":10,"ownerAvatarUrl":11,"ownerAccountNo":12,"ownerDisplayName":13,"repositoryNo":14,"starsCount":15,"licenseSpdxId":16,"licenseFileUrl":17,"sourceHtmlUrl":18,"categories":19,"keywords":30,"publishedAt":40,"linkOnly":41,"markdownContent":42,"markdownBody":43,"frontMatter":44,"refName":45,"commitSha":46,"skillDirectory":47,"forksCount":48,"repositoryHtmlUrl":49,"repositoryHomepageUrl":50,"ownerHtmlUrl":51,"ownerBlogUrl":52,"ownerDescription":53,"updatedAt":54,"install":55,"resources":68},"01M69ANR5T01TYC63Z1X4E2YQV","debug-failing-test","失败测试调试排查","Debug a failing test using an iterative logging approach, then clean up and document the learning.","使用迭代式日志方法调试失败的测试，随后清理现场并记录所学经验。","microsoft\u002Fvscode-python-environments","microsoft","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F6154722?v=4","01M698VYDXZ6JW5WH3CRV650R8","Microsoft","01M69ANKH8QP6PYCYYVP4340EX",147,"MIT",null,"https:\u002F\u002Fgithub.com\u002Fmicrosoft\u002Fvscode-python-environments\u002Fblob\u002Fmain\u002F.github\u002Fskills\u002Fdebug-failing-test\u002FSKILL.md",[20,25],{"categoryNo":21,"categoryName":22,"taxonomyType":23,"taxonomyTypeDesc":24},"01M8BQGD5WG86P4AQ5GPSSKBFR","测试工程师","PROFESSION","适用职业",{"categoryNo":26,"categoryName":27,"taxonomyType":28,"taxonomyTypeDesc":29},"01M8BRSRYQ3M8N5063NNQPF2B1","调试与故障排查","SCENARIO","使用场景",[31,32,33,34,35,36,37,38,39],"test","debug","debug failing test","failing","logging","learning","up","document","clean","2026-11-10 10:12:30",false,"---\nname: debug-failing-test\ndescription: Debug a failing test using an iterative logging approach, then clean up and document the learning.\n---\n\nDebug a failing unit test by iteratively adding verbose logging, running the test, and analyzing the output until the root cause is found and fixed.\n\n## Workflow\n\n### Phase 1: Initial Assessment\n\n1. **Run the failing test** to capture the current error message and stack trace\n2. **Read the test file** to understand what is being tested\n3. **Read the source file** being tested to understand the expected behavior\n4. **Identify the assertion that fails** and what values are involved\n\n### Phase 2: Iterative Debugging Loop\n\nRepeat until the root cause is understood:\n\n1. **Add verbose logging** around the suspicious code:\n    - Use `console.log('[DEBUG]', ...)` with descriptive labels\n    - Log input values, intermediate states, and return values\n    - Log before\u002Fafter key operations\n    - Add timestamps if timing might be relevant\n\n2. **Run the test** and capture output\n\n3. **Assess the logging output:**\n    - What values are unexpected?\n    - Where does the behavior diverge from expectations?\n    - What additional logging would help narrow down the issue?\n\n4. **Decide next action:**\n    - If root cause is clear → proceed to fix\n    - If more information needed → add more targeted logging and repeat\n\n### Phase 3: Fix and Verify\n\n1. **Implement the fix** based on findings\n2. **Run the test** to verify it passes\n3. **Run related tests** to ensure no regressions\n\n### Phase 4: Clean Up\n\n1. **Remove ALL debugging artifacts:**\n    - Delete all `console.log('[DEBUG]', ...)` statements added\n    - Remove any temporary variables or code added for debugging\n    - Ensure the code is in a clean, production-ready state\n\n2. **Verify the test still passes** after cleanup\n\n### Phase 5: Document and Learn\n\n1. **Provide a summary** to the user (1-3 sentences):\n    - What was the bug?\n    - What was the fix?\n\n2. **Record the learning** by following the learning instructions (if you have them):\n    - Extract a single, clear learning from this debugging session\n    - Add it to the \"Learnings\" section of the most relevant instruction file\n    - If a similar learning already exists, increment its counter instead\n\n## Logging Conventions\n\nWhen adding debug logging, use this format for easy identification and removal:\n\n```typescript\nconsole.log('[DEBUG] \u003Clocation>:', \u003Cvalue>);\nconsole.log('[DEBUG] before \u003Coperation>:', { input, state });\nconsole.log('[DEBUG] after \u003Coperation>:', { result, state });\n```\n\n## Example Debug Session\n\n```typescript\n\u002F\u002F Added logging example:\nconsole.log('[DEBUG] getEnvironments input:', { workspaceFolder });\nconst envs = await manager.getEnvironments(workspaceFolder);\nconsole.log('[DEBUG] getEnvironments result:', { count: envs.length, envs });\n```\n\n## Notes\n\n- Prefer targeted logging over flooding the output\n- Start with the failing assertion and work backwards\n- Consider async timing issues, race conditions, and mock setup problems\n- Check that mocks are returning expected values\n- Verify test setup\u002Fteardown is correct\n","Debug a failing unit test by iteratively adding verbose logging, running the test, and analyzing the output until the root cause is found and fixed.\n\n## Workflow\n\n### Phase 1: Initial Assessment\n\n1. **Run the failing test** to capture the current error message and stack trace\n2. **Read the test file** to understand what is being tested\n3. **Read the source file** being tested to understand the expected behavior\n4. **Identify the assertion that fails** and what values are involved\n\n### Phase 2: Iterative Debugging Loop\n\nRepeat until the root cause is understood:\n\n1. **Add verbose logging** around the suspicious code:\n    - Use `console.log('[DEBUG]', ...)` with descriptive labels\n    - Log input values, intermediate states, and return values\n    - Log before\u002Fafter key operations\n    - Add timestamps if timing might be relevant\n\n2. **Run the test** and capture output\n\n3. **Assess the logging output:**\n    - What values are unexpected?\n    - Where does the behavior diverge from expectations?\n    - What additional logging would help narrow down the issue?\n\n4. **Decide next action:**\n    - If root cause is clear → proceed to fix\n    - If more information needed → add more targeted logging and repeat\n\n### Phase 3: Fix and Verify\n\n1. **Implement the fix** based on findings\n2. **Run the test** to verify it passes\n3. **Run related tests** to ensure no regressions\n\n### Phase 4: Clean Up\n\n1. **Remove ALL debugging artifacts:**\n    - Delete all `console.log('[DEBUG]', ...)` statements added\n    - Remove any temporary variables or code added for debugging\n    - Ensure the code is in a clean, production-ready state\n\n2. **Verify the test still passes** after cleanup\n\n### Phase 5: Document and Learn\n\n1. **Provide a summary** to the user (1-3 sentences):\n    - What was the bug?\n    - What was the fix?\n\n2. **Record the learning** by following the learning instructions (if you have them):\n    - Extract a single, clear learning from this debugging session\n    - Add it to the \"Learnings\" section of the most relevant instruction file\n    - If a similar learning already exists, increment its counter instead\n\n## Logging Conventions\n\nWhen adding debug logging, use this format for easy identification and removal:\n\n```typescript\nconsole.log('[DEBUG] \u003Clocation>:', \u003Cvalue>);\nconsole.log('[DEBUG] before \u003Coperation>:', { input, state });\nconsole.log('[DEBUG] after \u003Coperation>:', { result, state });\n```\n\n## Example Debug Session\n\n```typescript\n\u002F\u002F Added logging example:\nconsole.log('[DEBUG] getEnvironments input:', { workspaceFolder });\nconst envs = await manager.getEnvironments(workspaceFolder);\nconsole.log('[DEBUG] getEnvironments result:', { count: envs.length, envs });\n```\n\n## Notes\n\n- Prefer targeted logging over flooding the output\n- Start with the failing assertion and work backwards\n- Consider async timing issues, race conditions, and mock setup problems\n- Check that mocks are returning expected values\n- Verify test setup\u002Fteardown is correct\n",{"name":5,"description":7},"main","92c13e7942499b7608a22bf1cb86b881a90afc98",".github\u002Fskills\u002Fdebug-failing-test",83,"https:\u002F\u002Fgithub.com\u002Fmicrosoft\u002Fvscode-python-environments","https:\u002F\u002Fmarketplace.visualstudio.com\u002Fitems?itemName=ms-python.vscode-python-envs","https:\u002F\u002Fgithub.com\u002Fmicrosoft","https:\u002F\u002Fopensource.microsoft.com","Open source projects and samples from Microsoft","2026-11-14 07:15:14",{"source":9,"skillName":5,"commands":56,"prompt":66,"zipAvailable":67},[57,60,63],{"tool":58,"command":59},"npx","npx skills add microsoft\u002Fvscode-python-environments --skill debug-failing-test",{"tool":61,"command":62},"bunx","bunx skills add microsoft\u002Fvscode-python-environments --skill debug-failing-test",{"tool":64,"command":65},"pnpm","pnpm dlx skills add microsoft\u002Fvscode-python-environments --skill debug-failing-test","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Fmicrosoft\u002Fvscode-python-environments\u002Fblob\u002Fmain\u002F.github\u002Fskills\u002Fdebug-failing-test\u002FSKILL.md",true,[69,75,79,83,87,91,95,99,103,107],{"path":70,"resourceType":71,"resourceTypeDesc":72,"sizeBytes":73,"sourceHtmlUrl":74},"AGENTS.md","REFERENCE","参考文档",1785,"https:\u002F\u002Fgithub.com\u002Fmdnaimul22\u002Fhuman-skills\u002Fblob\u002Fmain\u002Fskills\u002Fstorage\u002Fagent-zero_skills\u002Fa0-development\u002FAGENTS.md",{"path":76,"resourceType":71,"resourceTypeDesc":72,"sizeBytes":77,"sourceHtmlUrl":78},"references\u002Fagents-prompts-skills-projects.md",4671,"https:\u002F\u002Fgithub.com\u002Fmdnaimul22\u002Fhuman-skills\u002Fblob\u002Fmain\u002Fskills\u002Fstorage\u002Fagent-zero_skills\u002Fa0-development\u002Freferences\u002Fagents-prompts-skills-projects.md",{"path":80,"resourceType":71,"resourceTypeDesc":72,"sizeBytes":81,"sourceHtmlUrl":82},"references\u002FAGENTS.md",2080,"https:\u002F\u002Fgithub.com\u002Fmdnaimul22\u002Fhuman-skills\u002Fblob\u002Fmain\u002Fskills\u002Fstorage\u002Fagent-zero_skills\u002Fa0-development\u002Freferences\u002FAGENTS.md",{"path":84,"resourceType":71,"resourceTypeDesc":72,"sizeBytes":85,"sourceHtmlUrl":86},"references\u002Fapi-webui.md",3562,"https:\u002F\u002Fgithub.com\u002Fmdnaimul22\u002Fhuman-skills\u002Fblob\u002Fmain\u002Fskills\u002Fstorage\u002Fagent-zero_skills\u002Fa0-development\u002Freferences\u002Fapi-webui.md",{"path":88,"resourceType":71,"resourceTypeDesc":72,"sizeBytes":89,"sourceHtmlUrl":90},"references\u002Farchitecture-runtime.md",4110,"https:\u002F\u002Fgithub.com\u002Fmdnaimul22\u002Fhuman-skills\u002Fblob\u002Fmain\u002Fskills\u002Fstorage\u002Fagent-zero_skills\u002Fa0-development\u002Freferences\u002Farchitecture-runtime.md",{"path":92,"resourceType":71,"resourceTypeDesc":72,"sizeBytes":93,"sourceHtmlUrl":94},"references\u002Fdox-workflow.md",2838,"https:\u002F\u002Fgithub.com\u002Fmdnaimul22\u002Fhuman-skills\u002Fblob\u002Fmain\u002Fskills\u002Fstorage\u002Fagent-zero_skills\u002Fa0-development\u002Freferences\u002Fdox-workflow.md",{"path":96,"resourceType":71,"resourceTypeDesc":72,"sizeBytes":97,"sourceHtmlUrl":98},"references\u002Fextensions.md",4635,"https:\u002F\u002Fgithub.com\u002Fmdnaimul22\u002Fhuman-skills\u002Fblob\u002Fmain\u002Fskills\u002Fstorage\u002Fagent-zero_skills\u002Fa0-development\u002Freferences\u002Fextensions.md",{"path":100,"resourceType":71,"resourceTypeDesc":72,"sizeBytes":101,"sourceHtmlUrl":102},"references\u002Foperate-agent-zero.md",15562,"https:\u002F\u002Fgithub.com\u002Fmdnaimul22\u002Fhuman-skills\u002Fblob\u002Fmain\u002Fskills\u002Fstorage\u002Fagent-zero_skills\u002Fa0-development\u002Freferences\u002Foperate-agent-zero.md",{"path":104,"resourceType":71,"resourceTypeDesc":72,"sizeBytes":105,"sourceHtmlUrl":106},"references\u002Fplugins-workflow.md",3820,"https:\u002F\u002Fgithub.com\u002Fmdnaimul22\u002Fhuman-skills\u002Fblob\u002Fmain\u002Fskills\u002Fstorage\u002Fagent-zero_skills\u002Fa0-development\u002Freferences\u002Fplugins-workflow.md",{"path":108,"resourceType":71,"resourceTypeDesc":72,"sizeBytes":109,"sourceHtmlUrl":110},"references\u002Ftools.md",3166,"https:\u002F\u002Fgithub.com\u002Fmdnaimul22\u002Fhuman-skills\u002Fblob\u002Fmain\u002Fskills\u002Fstorage\u002Fagent-zero_skills\u002Fa0-development\u002Freferences\u002Ftools.md",[112,145,172,198,214,237],{"skillNo":113,"name":114,"nameZh":115,"description":116,"descriptionZh":117,"repositoryFullName":9,"ownerLogin":10,"ownerAvatarUrl":11,"ownerAccountNo":12,"ownerDisplayName":13,"repositoryNo":14,"starsCount":15,"licenseSpdxId":16,"licenseFileUrl":17,"sourceHtmlUrl":118,"categories":119,"keywords":126,"publishedAt":40},"01M69AP5C8W366N8TDNBZA2YQ4","settings-precedence","VS Code 设置优先级规则","VS Code settings precedence rules and common pitfalls. Essential for any code that reads or writes settings. Covers getConfiguration scope, inspect() vs get(), and multi-workspace handling.","VS Code 设置优先级规则及常见陷阱。适用于任何读取或写入设置的代码。涵盖 getConfiguration 作用域、inspect() 与 get() 的区别，以及多工作区处理。","https:\u002F\u002Fgithub.com\u002Fmicrosoft\u002Fvscode-python-environments\u002Fblob\u002Fmain\u002F.github\u002Fskills\u002Fsettings-precedence\u002FSKILL.md",[120,123],{"categoryNo":121,"categoryName":122,"taxonomyType":23,"taxonomyTypeDesc":24},"01M8BQ6TQZN6R52WBJ9H8NRMQM","软件开发工程师",{"categoryNo":124,"categoryName":125,"taxonomyType":28,"taxonomyTypeDesc":29},"01M8BSTR9G4A4GZ0VB2DFN9490","开发环境与工具链管理",[127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144],"settings precedence","settings","inspect","pitfalls","common pitfalls","multi","scope","false","essential","for","code","file","component","review","get","workspace","common","Rules",{"skillNo":146,"name":147,"nameZh":148,"description":149,"descriptionZh":150,"repositoryFullName":9,"ownerLogin":10,"ownerAvatarUrl":11,"ownerAccountNo":12,"ownerDisplayName":13,"repositoryNo":14,"starsCount":15,"licenseSpdxId":16,"licenseFileUrl":17,"sourceHtmlUrl":151,"categories":152,"keywords":157,"publishedAt":40},"01M69AP3CMT4CYDAZ6GQXCJN1D","run-smoke-tests","VS Code 扩展冒烟测试","Run smoke tests to verify extension functionality in a real VS Code environment. Use this when checking if basic features work after changes.","运行冒烟测试，在真实 VS Code 环境中验证扩展功能。在更改后检查基本功能是否正常工作时使用。","https:\u002F\u002Fgithub.com\u002Fmicrosoft\u002Fvscode-python-environments\u002Fblob\u002Fmain\u002F.github\u002Fskills\u002Frun-smoke-tests\u002FSKILL.md",[153,154],{"categoryNo":21,"categoryName":22,"taxonomyType":23,"taxonomyTypeDesc":24},{"categoryNo":155,"categoryName":156,"taxonomyType":28,"taxonomyTypeDesc":29},"01M8BQJH394GT47X57A9Q8G7HX","测试与质量保障",[158,159,160,161,162,137,163,164,165,166,167,168,169,170,171],"tests","smoke","run","run smoke tests","smoke tests","basic","when","features","changes","extension","use","environment","work","verify",{"skillNo":173,"name":174,"nameZh":175,"description":176,"descriptionZh":177,"repositoryFullName":9,"ownerLogin":10,"ownerAvatarUrl":11,"ownerAccountNo":12,"ownerDisplayName":13,"repositoryNo":14,"starsCount":15,"licenseSpdxId":16,"licenseFileUrl":17,"sourceHtmlUrl":178,"categories":179,"keywords":184,"publishedAt":40},"01M69AP1H7465VYNYGZA7RSAMW","run-pre-commit-checks","代码提交前(pre-commit)检查","Run the mandatory pre-commit checks before committing code. Includes lint, type checking, and unit tests. MUST be run before every commit.","在提交代码前运行强制性的 pre-commit 检查，包括 lint（代码规范检查）、类型检查和单元测试。每次提交前都必须运行。","https:\u002F\u002Fgithub.com\u002Fmicrosoft\u002Fvscode-python-environments\u002Fblob\u002Fmain\u002F.github\u002Fskills\u002Frun-pre-commit-checks\u002FSKILL.md",[180,181],{"categoryNo":121,"categoryName":122,"taxonomyType":23,"taxonomyTypeDesc":24},{"categoryNo":182,"categoryName":183,"taxonomyType":28,"taxonomyTypeDesc":29},"01M8BR5V701HCN066VEP7H4812","代码仓库协作管理",[185,186,160,187,188,158,189,190,191,192,193,194,137,195,196,197],"commit","run pre commit checks","pre commit","pre commit checks","type","auto","unit","auto-fix","pre-commit","issues","lint","unit tests","fix",{"skillNo":199,"name":200,"nameZh":201,"description":202,"descriptionZh":203,"repositoryFullName":9,"ownerLogin":10,"ownerAvatarUrl":11,"ownerAccountNo":12,"ownerDisplayName":13,"repositoryNo":14,"starsCount":15,"licenseSpdxId":16,"licenseFileUrl":17,"sourceHtmlUrl":204,"categories":205,"keywords":208,"publishedAt":40},"01M69ANZK45PDMWHSTKZKZTS2V","run-integration-tests","扩展组件集成测试运行","Run integration tests to verify that extension components work together correctly. Use this after modifying component interactions or event handling.","运行集成测试以验证扩展的各个组件能否正确协同工作。在修改组件交互或事件处理后使用此技能。","https:\u002F\u002Fgithub.com\u002Fmicrosoft\u002Fvscode-python-environments\u002Fblob\u002Fmain\u002F.github\u002Fskills\u002Frun-integration-tests\u002FSKILL.md",[206,207],{"categoryNo":21,"categoryName":22,"taxonomyType":23,"taxonomyTypeDesc":24},{"categoryNo":155,"categoryName":156,"taxonomyType":28,"taxonomyTypeDesc":29},[209,210,211,160,158,171,212,167,168,170,139,213],"integration","integration tests","run integration tests","event","components",{"skillNo":215,"name":216,"nameZh":217,"description":218,"descriptionZh":219,"repositoryFullName":9,"ownerLogin":10,"ownerAvatarUrl":11,"ownerAccountNo":12,"ownerDisplayName":13,"repositoryNo":14,"starsCount":15,"licenseSpdxId":16,"licenseFileUrl":17,"sourceHtmlUrl":220,"categories":221,"keywords":224,"publishedAt":40},"01M69ANXP7SBRDK7TK3C54V695","run-e2e-tests","E2E 端到端测试运行","Run E2E tests to verify complete user workflows like environment discovery, creation, and selection. Use this before releases or after major changes.","运行 E2E 测试以验证完整的用户工作流（如环境的发现、创建和选择）。在发布前或进行重大变更后使用此技能。","https:\u002F\u002Fgithub.com\u002Fmicrosoft\u002Fvscode-python-environments\u002Fblob\u002Fmain\u002F.github\u002Fskills\u002Frun-e2e-tests\u002FSKILL.md",[222,223],{"categoryNo":21,"categoryName":22,"taxonomyType":23,"taxonomyTypeDesc":24},{"categoryNo":155,"categoryName":156,"taxonomyType":28,"taxonomyTypeDesc":29},[225,160,226,227,158,228,229,171,230,231,169,232,166,233,234,235,236,168],"e2e tests","run e2e","e2e","run e2e tests","user","discovery","workflows","environment discovery","complete","creation","selection","releases",{"skillNo":238,"name":239,"nameZh":240,"description":241,"descriptionZh":242,"repositoryFullName":9,"ownerLogin":10,"ownerAvatarUrl":11,"ownerAccountNo":12,"ownerDisplayName":13,"repositoryNo":14,"starsCount":15,"licenseSpdxId":16,"licenseFileUrl":17,"sourceHtmlUrl":243,"categories":244,"keywords":247,"publishedAt":40},"01M69ANVY2ABDQCXJBQNBV587M","python-manager-discovery","Python 环境管理器探测","Environment manager-specific discovery patterns and known issues. Use when working on or reviewing environment discovery code for conda, poetry, pipenv, pyenv, or venv.","针对特定环境管理器的探测模式及已知问题。在编写或审查 conda、poetry、pipenv、pyenv 或 venv 的环境探测代码时使用。","https:\u002F\u002Fgithub.com\u002Fmicrosoft\u002Fvscode-python-environments\u002Fblob\u002Fmain\u002F.github\u002Fskills\u002Fpython-manager-discovery\u002FSKILL.md",[245,246],{"categoryNo":121,"categoryName":122,"taxonomyType":23,"taxonomyTypeDesc":24},{"categoryNo":124,"categoryName":125,"taxonomyType":28,"taxonomyTypeDesc":29},[248,249,230,250,251,232,164,136,252,253,254,134,255,256,257,168,169,194,137],"python manager discovery","manager","python","pipenv","venv","pyenv","name","conda","patterns","Poetry"]