[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M6HXVF0S9TE7XJ006KDZPR30":3,"skill-same:01M6HXVF0S9TE7XJ006KDZPR30":75},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":28,"publishedAt":42,"linkOnly":43,"markdownContent":44,"markdownBody":45,"frontMatter":46,"refName":47,"commitSha":48,"skillDirectory":49,"forksCount":50,"repositoryHtmlUrl":51,"repositoryHomepageUrl":6,"ownerHtmlUrl":52,"ownerBlogUrl":53,"ownerDescription":6,"updatedAt":54,"install":55,"resources":68},"01M6HXVF0S9TE7XJ006KDZPR30","python-spreadsheet-debug",null,"Systematic Python debugging workflow for spreadsheet tasks to isolate environment issues from script logic","HKUDS\u002FAgentPilot","HKUDS","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F118165258?v=4","01M6HW8VRNZP64G0P4MVJW2KKQ","✨Data Intelligence Lab@HKU✨","01M6HW8VWZVHBRHYH3T330PFWV",8029,"MIT","https:\u002F\u002Fgithub.com\u002FHKUDS\u002FAgentPilot\u002Fblob\u002Fmain\u002Fopenspace\u002Flegacy\u002Fv1\u002Fgdpval_bench\u002Fskills\u002Fpython-spreadsheet-debug\u002FSKILL.md",[18,23],{"categoryNo":19,"categoryName":20,"taxonomyType":21,"taxonomyTypeDesc":22},"01JBSEEDCAT000000000000004","电子表格","SCENARIO","使用场景",{"categoryNo":24,"categoryName":25,"taxonomyType":26,"taxonomyTypeDesc":27},"01JBSEEDCAT000000000000030","开发工程师","PROFESSION","适用职业",[29,30,31,32,33,34,35,36,37,38,39,40,41],"python","debug","spreadsheet","python spreadsheet debug","workflow","debugging","tasks","issues","environment","logic","systematic","script","for","2026-11-10 10:12:30",false,"---\nname: python-spreadsheet-debug\ndescription: Systematic Python debugging workflow for spreadsheet tasks to isolate environment issues from script logic\n---\n\n# Python Spreadsheet Debugging Workflow\n\nWhen executing Python scripts for spreadsheet\u002Fdata processing tasks, use this systematic debugging approach to efficiently isolate environment configuration issues from script logic errors, especially when `run_shell` returns opaque errors.\n\n## Step 1: Verify Python Environment\n\nFirst, confirm the Python interpreter path and version to ensure you're working in the expected environment:\n\n```bash\nwhich python python3\npython --version\npython3 --version\n```\n\nThis identifies whether Python is available and which version is being used.\n\n## Step 2: Test Library Imports in Isolation\n\nBefore running your full script, verify that required libraries can be imported successfully. Test each critical import individually:\n\n```bash\npython -c \"import pandas; print('pandas:', pandas.__version__)\"\npython -c \"import openpyxl; print('openpyxl:', openpyxl.__version__)\"\npython -c \"import xlrd; print('xlrd:', xlrd.__version__)\"\n```\n\nReplace library names based on your script's requirements. This identifies missing dependencies or version conflicts early.\n\n## Step 3: Run Minimal Test Script\n\nCreate and execute a minimal script that exercises only the core functionality without full business logic:\n\n```python\n# test_minimal.py\nimport pandas as pd\n\n# Test 1: Can we read a file?\ntry:\n    df = pd.read_excel('sample.xlsx')\n    print(f\"✓ File read successful: {len(df)} rows\")\nexcept Exception as e:\n    print(f\"✗ File read failed: {e}\")\n\n# Test 2: Can we perform basic operations?\ntry:\n    result = df.groupby('category')['amount'].sum()\n    print(f\"✓ GroupBy operation successful\")\nexcept Exception as e:\n    print(f\"✗ Operation failed: {e}\")\n```\n\nRun this with: `python test_minimal.py`\n\n**Purpose:** This isolates whether the issue is with file access, library functionality, or specific script logic.\n\n## Step 4: Execute Full Script\n\nOnce the minimal test passes, run the complete script:\n\n```bash\npython your_script.py\n```\n\nIf errors occur now, you know the environment is correctly configured and can focus on debugging the specific logic.\n\n## Quick Diagnostic Command\n\nFor rapid diagnosis, run all checks in sequence:\n\n```bash\necho \"=== Python Version ===\" && python --version && \\\necho \"=== Key Imports ===\" && python -c \"import pandas, openpyxl; print('OK')\" && \\\necho \"=== Ready for full script ===\"\n```\n\n## Common Issues and Resolutions\n\n| Symptom | Likely Cause | Resolution |\n|---------|--------------|------------|\n| `ModuleNotFoundError` | Missing package | `pip install \u003Cpackage-name>` |\n| `ImportError` with version | Version conflict | Check `pip list`, reinstall specific version |\n| `FileNotFoundError` | Wrong path\u002Fcontext | Verify working directory with `pwd` |\n| `PermissionError` | File access | Check file permissions or path |\n\n## When to Use This Pattern\n\n- `run_shell` returns cryptic or truncated error messages\n- Script worked previously but suddenly fails\n- Deploying to a new environment or container\n- Debugging spreadsheet processing with pandas, openpyxl, xlrd, etc.\n\n## Benefits\n\n- **Fast isolation:** Identifies environment vs. logic issues within seconds\n- **Incremental confidence:** Each passing step narrows the problem space\n- **Reusable pattern:** Apply consistently across all Python spreadsheet tasks","# Python Spreadsheet Debugging Workflow\n\nWhen executing Python scripts for spreadsheet\u002Fdata processing tasks, use this systematic debugging approach to efficiently isolate environment configuration issues from script logic errors, especially when `run_shell` returns opaque errors.\n\n## Step 1: Verify Python Environment\n\nFirst, confirm the Python interpreter path and version to ensure you're working in the expected environment:\n\n```bash\nwhich python python3\npython --version\npython3 --version\n```\n\nThis identifies whether Python is available and which version is being used.\n\n## Step 2: Test Library Imports in Isolation\n\nBefore running your full script, verify that required libraries can be imported successfully. Test each critical import individually:\n\n```bash\npython -c \"import pandas; print('pandas:', pandas.__version__)\"\npython -c \"import openpyxl; print('openpyxl:', openpyxl.__version__)\"\npython -c \"import xlrd; print('xlrd:', xlrd.__version__)\"\n```\n\nReplace library names based on your script's requirements. This identifies missing dependencies or version conflicts early.\n\n## Step 3: Run Minimal Test Script\n\nCreate and execute a minimal script that exercises only the core functionality without full business logic:\n\n```python\n# test_minimal.py\nimport pandas as pd\n\n# Test 1: Can we read a file?\ntry:\n    df = pd.read_excel('sample.xlsx')\n    print(f\"✓ File read successful: {len(df)} rows\")\nexcept Exception as e:\n    print(f\"✗ File read failed: {e}\")\n\n# Test 2: Can we perform basic operations?\ntry:\n    result = df.groupby('category')['amount'].sum()\n    print(f\"✓ GroupBy operation successful\")\nexcept Exception as e:\n    print(f\"✗ Operation failed: {e}\")\n```\n\nRun this with: `python test_minimal.py`\n\n**Purpose:** This isolates whether the issue is with file access, library functionality, or specific script logic.\n\n## Step 4: Execute Full Script\n\nOnce the minimal test passes, run the complete script:\n\n```bash\npython your_script.py\n```\n\nIf errors occur now, you know the environment is correctly configured and can focus on debugging the specific logic.\n\n## Quick Diagnostic Command\n\nFor rapid diagnosis, run all checks in sequence:\n\n```bash\necho \"=== Python Version ===\" && python --version && \\\necho \"=== Key Imports ===\" && python -c \"import pandas, openpyxl; print('OK')\" && \\\necho \"=== Ready for full script ===\"\n```\n\n## Common Issues and Resolutions\n\n| Symptom | Likely Cause | Resolution |\n|---------|--------------|------------|\n| `ModuleNotFoundError` | Missing package | `pip install \u003Cpackage-name>` |\n| `ImportError` with version | Version conflict | Check `pip list`, reinstall specific version |\n| `FileNotFoundError` | Wrong path\u002Fcontext | Verify working directory with `pwd` |\n| `PermissionError` | File access | Check file permissions or path |\n\n## When to Use This Pattern\n\n- `run_shell` returns cryptic or truncated error messages\n- Script worked previously but suddenly fails\n- Deploying to a new environment or container\n- Debugging spreadsheet processing with pandas, openpyxl, xlrd, etc.\n\n## Benefits\n\n- **Fast isolation:** Identifies environment vs. logic issues within seconds\n- **Incremental confidence:** Each passing step narrows the problem space\n- **Reusable pattern:** Apply consistently across all Python spreadsheet tasks",{"name":5,"description":7},"main","6b84b0689ca0d9e7b1e4061188ff6b60758e0f8a","openspace\u002Flegacy\u002Fv1\u002Fgdpval_bench\u002Fskills\u002Fpython-spreadsheet-debug",944,"https:\u002F\u002Fgithub.com\u002FHKUDS\u002FAgentPilot","https:\u002F\u002Fgithub.com\u002FHKUDS","https:\u002F\u002Fsites.google.com\u002Fview\u002Fchaoh","2026-11-12 22:26:39",{"source":8,"skillName":5,"commands":56,"prompt":66,"zipAvailable":67},[57,60,63],{"tool":58,"command":59},"npx","npx skills add HKUDS\u002FAgentPilot --skill python-spreadsheet-debug",{"tool":61,"command":62},"bunx","bunx skills add HKUDS\u002FAgentPilot --skill python-spreadsheet-debug",{"tool":64,"command":65},"pnpm","pnpm dlx skills add HKUDS\u002FAgentPilot --skill python-spreadsheet-debug","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002FHKUDS\u002FAgentPilot\u002Fblob\u002Fmain\u002Fopenspace\u002Flegacy\u002Fv1\u002Fgdpval_bench\u002Fskills\u002Fpython-spreadsheet-debug\u002FSKILL.md",true,[69],{"path":70,"resourceType":71,"resourceTypeDesc":72,"sizeBytes":73,"sourceHtmlUrl":74},".skill_id","OTHER","其他",38,"https:\u002F\u002Fgithub.com\u002FHKUDS\u002FAgentPilot\u002Fblob\u002Fmain\u002Fopenspace\u002Flegacy\u002Fv1\u002Fgdpval_bench\u002Fskills\u002Fpython-spreadsheet-debug\u002F.skill_id",[76,96,115,138,160,181],{"skillNo":77,"name":78,"nameZh":6,"description":79,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":80,"categories":81,"keywords":82,"publishedAt":42},"01M6HYB297NDABRERJRVG0K8R0","agentpilot","Set up AgentPilot and use its single entry to prepare missing inputs and run configured RSI experiments. Use when the user requests AgentPilot installation or work with AgentPilot.","https:\u002F\u002Fgithub.com\u002FHKUDS\u002FAgentPilot\u002Fblob\u002Fmain\u002Fplugins\u002Fagentpilot\u002Fskills\u002Fagentpilot\u002FSKILL.md",[],[78,83,84,85,86,87,88,89,90,91,92,93,94,95],"prepare","requests","with","missing","installation","rsi","up","use","user","work","SET","run","experiments",{"skillNo":97,"name":98,"nameZh":6,"description":99,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":100,"categories":101,"keywords":102,"publishedAt":42},"01M6HYAYWXTTE1J7DJM0MFNQ4H","remember","Review auto-memory entries and propose promotions to OPENSPACE.md, OPENSPACE.local.md, or retained auto-memory topics; detect duplicates, stale facts, conflicts, and ambiguous entries before making changes.","https:\u002F\u002Fgithub.com\u002FHKUDS\u002FAgentPilot\u002Fblob\u002Fmain\u002Fopenspace\u002Fopenspace\u002Fskills\u002Fremember\u002FSKILL.md",[],[98,103,104,105,106,107,108,109,110,111,112,113,114],"memory","review","auto","openspace","changes","facts","detect","entries","local","conflicts","stale","duplicates",{"skillNo":116,"name":117,"nameZh":6,"description":118,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":119,"categories":120,"keywords":124,"publishedAt":42},"01M6HYAVMPM4SBDV60R2B5HPV8","skill-discovery","Search reusable OpenSpace skills locally, and browse cloud packages step by step when a cloud skill may help. Reusing proven skills saves tokens, improves reliability, and extends your capabilities beyond built-in tools.","https:\u002F\u002Fgithub.com\u002FHKUDS\u002FAgentPilot\u002Fblob\u002Fmain\u002Fopenspace\u002Fopenspace\u002Fhost_skills\u002Fskill-discovery\u002FSKILL.md",[121],{"categoryNo":122,"categoryName":123,"taxonomyType":21,"taxonomyTypeDesc":22},"01JBSEEDCAT000000000000023","Skill与智能体开发",[125,126,127,106,128,129,130,131,132,133,134,135,136,137],"skill discovery","discovery","reusable","step by step","tokens","packages","help","cloud","reliability","capabilities","browse","search","Tools",{"skillNo":139,"name":140,"nameZh":6,"description":141,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":142,"categories":143,"keywords":145,"publishedAt":42},"01M6HYAR811B3RB0M50RBEDGN6","delegate-task","Delegate tasks to OpenSpace — a full-stack autonomous worker for coding, DevOps, web research, and desktop automation, backed by an extensive MCP tool and skill library. Skills auto-improve through use, reducing token consumption over time. A cloud community lets agents share and collectively evolve reusable skills.","https:\u002F\u002Fgithub.com\u002FHKUDS\u002FAgentPilot\u002Fblob\u002Fmain\u002Fopenspace\u002Fopenspace\u002Fhost_skills\u002Fdelegate-task\u002FSKILL.md",[144],{"categoryNo":122,"categoryName":123,"taxonomyType":21,"taxonomyTypeDesc":22},[146,147,148,106,149,150,151,152,153,127,105,90,154,155,156,41,157,35,158,159],"delegate","task","delegate task","time","improve","desktop automation","worker","community","autonomous","tool","stack","share","automation","MCP",{"skillNo":161,"name":162,"nameZh":6,"description":163,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":164,"categories":165,"keywords":166,"publishedAt":42},"01M6HYAM9FSGV6E52AYENDQXYH","write-special-chars-ts-check","Workaround for write_file failures caused by special characters (apostrophes, backticks, template literals) using a Python heredoc script, plus a reliable TypeScript type-checking step that filters output to only the newly-written files to avoid being misled by pre-existing errors.","https:\u002F\u002Fgithub.com\u002FHKUDS\u002FAgentPilot\u002Fblob\u002Fmain\u002Fopenspace\u002Flegacy\u002Fv1\u002Fshowcase\u002Fskills\u002Fwrite-special-chars-ts-check\u002FSKILL.md",[],[167,168,169,170,171,172,173,174,175,29,176,177,178,179,41,180,40],"write special chars ts check","write","check","type","files","filters","only","template","file","typescript","output","Existing","type-checking","errors",{"skillNo":182,"name":183,"nameZh":6,"description":184,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":185,"categories":186,"keywords":187,"publishedAt":42},"01M6HYAH05HGV7SVWSVR8PJRQD","write-special-chars-readback","Workaround for write_file failures caused by special characters (apostrophes, backticks, template literals) using a Python heredoc script, with mandatory post-write verification via read_file and cleanup of \u002Ftmp helper scripts.","https:\u002F\u002Fgithub.com\u002FHKUDS\u002FAgentPilot\u002Fblob\u002Fmain\u002Fopenspace\u002Flegacy\u002Fv1\u002Fshowcase\u002Fskills\u002Fwrite-special-chars-readback\u002FSKILL.md",[],[188,189,168,85,41,40,190,191,192,193,194,174,175,195,196,29],"write special chars readback","readback","helper","post","via","scripts","read","verification","cleanup"]