# Chapter 1 Guided Lab: Data Engineering Setup Checkpoint

This lab verifies that your machine is ready for the hands-on work in *Data Engineering in Action*. The goal is not to install every tool in the book at once. The goal is to prove that you can work with the four foundations used throughout the labs: **Git**, **Python**, **Docker**, and **documented evidence**.

## Learning Goals

By completing this lab, you should be able to verify your local development environment, create a Python virtual environment, start a lightweight Docker Compose service, and document the evidence in a setup report.

| Goal | Evidence |
|---|---|
| Git is available | `git --version`, current branch, and repository status. |
| Python is isolated | `.venv` exists and `python -m pip --version` points to it. |
| Docker is running | `docker version` and `docker compose version` succeed. |
| Compose service works | `docker compose ps` shows the Chapter 1 checkpoint service. |
| Setup is documented | `setup_report.md` contains commands, outputs, and troubleshooting notes. |

## Files

| File | Purpose |
|---|---|
| `README.md` | Lab instructions and expected outputs. |
| `docker-compose.yml` | Lightweight service used to verify Docker Compose. |
| `environment_summary.py` | Starter script for collecting local environment metadata. |
| `setup_report_template.md` | Template for the reader's setup report. |
| `exercises/README.md` | Extension tasks for independent practice. |

## Quick Start

Run these commands from this lab directory.

```bash
python3 --version
python3 -m venv .venv
source .venv/bin/activate
python -m pip install --upgrade pip
python environment_summary.py

docker compose up -d
docker compose ps
docker compose logs ch01-checkpoint
docker compose down
```

On Windows PowerShell, activate the virtual environment with:

```powershell
.venv\Scripts\Activate.ps1
```

## Expected Output

The Python script should print a small environment summary containing the Python version, executable path, platform, and current working directory. The Docker Compose service should print a short confirmation message and remain available long enough for `docker compose ps` to show it.

## Completion Checklist

| Check | Status |
|---|---|
| I created or activated a Python virtual environment. | Pass/Fail |
| I ran `environment_summary.py`. | Pass/Fail |
| I started the Docker Compose checkpoint service. | Pass/Fail |
| I stopped the Docker Compose checkpoint service cleanly. | Pass/Fail |
| I completed `setup_report.md` using the provided template. | Pass/Fail |

## Cleanup

```bash
docker compose down
rm -rf .venv
```

Remove `.venv` only if you want to recreate the environment from scratch.
