Loading...
Loading...
Guide for modernizing legacy Python 2 scientific computing code to Python 3 with modern libraries. This skill should be used when migrating scientific scripts involving data processing, numerical computation, or analysis from Python 2 to Python 3, or when updating deprecated scientific computing patterns to modern equivalents (pandas, numpy, pathlib).
npx skill4agent add letta-ai/skills modernize-scientific-stack| Legacy Pattern | Modern Replacement |
|---|---|
| |
| |
| |
| |
| |
| |
| |
| Manual file iteration | Context managers ( |
| |
Integer division | Explicit |
config_path = Path("config.json")
if config_path.exists():
config = json.loads(config_path.read_text(encoding='utf-8'))python -m py_compile script.pypython -c "from script import *"... [truncated]encoding='utf-8'os.path.join()pathlib.Path