Incremental audio production with duration mismatch handling, adaptive stem extension, and pre-mix alignment verification
日本語の概要は準備中です。原文の説明を表示しています。
Debug Python script execution failures by capturing full output with exit codes and verifying working directory before file operations
インストール方法を見るインストールする前に、エージェントに与えられる指示の中身を確認できます。
This skill provides a reusable pattern for debugging Python script execution failures. It ensures you capture actual tracebacks instead of opaque errors and verify the working directory before file operations.
When running Python scripts, always use this command pattern to surface actual tracebacks:
python3 script.py 2>&1 ; echo Exit code: $?
Why this works:
2>&1 redirects stderr to stdout, capturing both regular output and errors; echo Exit code: $? displays the actual exit code after executionExamples:
# Good: Full error capture
python3 process_data.py 2>&1 ; echo Exit code: $?
# Bad: Opaque error (no stderr capture, no exit code)
python3 process_data.py
Before any file read/write operations in Python, verify the current working directory:
import os
# At script start, log the working directory
print(f"Working directory: {os.getcwd()}")
# For file operations, use absolute paths or log the resolved path
file_path = "output/result.csv"
abs_path = os.path.abspath(file_path)
print(f"Writing to: {abs_path}")
Why this works:
Full example script structure:
#!/usr/bin/env python3
import os
import sys
def main():
# Debug: verify working directory
print(f"Working directory: {os.getcwd()}", file=sys.stderr)
# Debug: list directory contents if dealing with files
print(f"Directory contents: {os.listdir('.')}", file=sys.stderr)
# Your actual logic here
# ...
if __name__ == "__main__":
main()
2>&1 ; echo Exit code: $? patternos.getcwd() logging at script startos.path.abspath() for file pathsos.listdir('.') if relevant| Symptom | Without Pattern | With Pattern |
|---|---|---|
| File not found | "Error: failed" | Full traceback showing exact path attempted |
| Permission denied | Script exits silently | stderr shows permission error |
| Missing module | Opaque exit | ImportError with module name |
| Wrong directory | Confusing path errors | cwd logged, reveals directory mismatch |
まだレビューはありません。使ってみた感想をお寄せください。
概要と使いどころ
Incremental audio production with duration mismatch handling, adaptive stem extension, and pre-mix alignment verification
日本語の概要は準備中です。原文の説明を表示しています。
Incremental audio production with duration alignment handling, per-stem verification, and adaptive extension strategies
日本語の概要は準備中です。原文の説明を表示しています。
Create serverless API proxy endpoints that hide API keys and provide a unified backend for the dashboard frontend. Designed for Vercel deployment.
日本語の概要は準備中です。原文の説明を表示しています。
End-to-end audio production workflow with stems, effects, archiving, and verification
日本語の概要は準備中です。原文の説明を表示しています。
Handle cascading data retrieval tool failures by falling back to embedded knowledge generation
日本語の概要は準備中です。原文の説明を表示しています。
Fallback pattern for executing Python code when execute_code_sandbox fails
日本語の概要は準備中です。原文の説明を表示しています。