Chapter 8 · practice
Put It All Together
Diagnose the Missing Project
Someone says, “The project is missing.” That report names a symptom, not a cause. Your job is to gather enough evidence to distinguish a missing command, a wrong path, a permission problem, and a program failure.
The evidence packet
Reset the Chapter 8 workspace. Its starting tree is:
/workspace
├── README.md
├── report.py
├── data
│ └── README.txt
├── destination
│ └── README.txt
├── evidence
│ └── safety-check.txt
└── notes with spaces.txt
The report you receive contains these facts:
Prompt location: /workspace
Command: python data/report.py
Error: python: can't open file '/workspace/data/report.py': [Errno 2] No such file or directory
That is all the diagnosis you get. Do not install, move, rename, or edit anything yet. First decide how far the request got, which path it attempted, and which path the tree actually contains.
Investigate without changing the tree
The /workspace and supply the python launcher.
Get-Location
python ./data/report.py
Get-Item -LiteralPath ./report.py
pwd
python data/report.py
ls report.py
pwd
python data/report.py
ls report.py
Now answer four questions from the evidence:
Which layer failed first?
Which complete path did Python attempt?
Which complete path does the tree show?
What is the smallest corrected command from the current directory?
Run that correction. Do not change directory or alter the supplied file: a good diagnosis should make a small fix possible without rearranging the scene.
Success is the exact output Workspace report: ready.
Leave a diagnosis another person can inspect
Create evidence/diagnosis.txt with exactly four nonblank lines in this schema:
layer=
attempted=
actual=
correction=
Use the canonical layer labels from Chapter 7. Write complete /workspace paths for the middle two fields. For correction, record the shortest working command from /workspace; omit an optional leading ./ from its file argument.
Use Set-Content followed by Add-Content in PowerShell, or one > followed by >> in Bash. Read the receipt back before checking your work.
The checker validates that receipt and the preserved project fixtures. It cannot replay your commands, so the strength of the diagnosis still comes from doing the investigation rather than copying a likely-looking path.
Which single fact most directly disproves the claim that the whole project is missing?
On another computer, python report.py produces python: command not found. The file is visible in the current directory. Which layer should you investigate first?
You turned a vague report into a justified diagnosis and a minimal correction. The capstone now asks you to build a durable workspace and leave evidence that someone else can inspect.