Documentation · Chapter 01

Solve problems
without guessing.

Start from the exact message and use AML diagnostics before reinstalling anything.

Common problems

aml: command not found

Open a new terminal, then check PATH.

not a PHPAML project

Move into the folder containing phpaml.json.

Permission denied

Check project and cache permissions, then run aml doctor again.

GitHub unavailable

Check the connection or use --offline when archives are already cached.

A method that avoids false fixes.

Copy the exact message before changing anything. Then identify the command, current folder, and first error. A complete reinstall can temporarily hide the problem without explaining its cause.

  1. ReproduceRun the failing command once more.
  2. ObserveRecord the message, file, and current folder.
  3. DiagnoseUse aml doctor and begin with the first error.
  4. ConfirmRun exactly the same command after the fix.
FINAL EXERCISE

Create and open your first application.

phpaml — zsh
aml doctor
aml create task-app
cd task-app
aml serve

The chapter is complete when doctor reports no blocking error, phpaml.json exists, and the local page responds. Do not run aml install after a successful creation.

EXPLAINED SOLUTION

Verify evidence, not only commands.

  1. aml doctorproves that the global environment is usable.
  2. phpaml.jsonproves that you are at a PHPAML project root.
  3. runtime/proves that creation installed the engine.
  4. HTTP 200proves that the browser, server, and application completed the full cycle.

CHECK YOUR UNDERSTANDING

Why do we not run aml install in the normal solution?

Show the answer

Because aml create already installs the project. aml install is for rebuilding or deferred installation.

SUMMARY

What to remember

  • Solve a problem from the first exact message.
  • Always verify the current folder.
  • doctor confirms the machine’s overall state.
  • The final expected result is an HTTP response in the browser.