Challenge 3: Trace the Publishing Steps — Possible Solution ==================================================================== 1. python -m build 2. twine upload --repository testpypi dist/* 3. (verify the package installs and works correctly from TestPyPI — e.g. pip install --index-url https://test.pypi.org/simple/ text_utils) 4. twine upload dist/* WHY THIS WORKS AS AN ANSWER ------------------------------ Step 1, python -m build, reuses this chapter's own build command exactly — it must run FIRST, since twine has nothing to upload until the distributable files actually exist in the dist/ folder it creates. Step 2, twine upload --repository testpypi dist/*, reuses the chapter's own TestPyPI command. This comes before the real upload specifically because the chapter calls TestPyPI out as "a safe practice environment, separate from the real registry" — uploading here first catches problems (a broken pyproject.toml, missing files, wrong metadata) in an environment where mistakes cost nothing and aren't effectively permanent. Step 3 is the verification step the challenge specifically asks to include: actually installing the TestPyPI version and confirming it works is the entire POINT of uploading there first — skipping this step and going straight to the real PyPI would defeat the purpose of having a practice registry at all. Step 4, twine upload dist/* (no --repository flag, meaning the real PyPI by default), only happens LAST, once the TestPyPI version is confirmed working — directly reflecting this chapter's warn-box point that a real PyPI release is effectively permanent, so it should be the final step taken only after everything else has already been verified, not the first thing tried.