Add baseline: Business Case, Stakeholder Analysis, Project Plan and milestones

Refs the three milestones MIL-001 to MIL-003; reviews RC-001 to RC-005 (Go).
This commit is contained in:
2026-10-17 15:11:20 +08:00
parent f8ea3401bd
commit 052008f213
14 changed files with 904 additions and 0 deletions
+73
View File
@@ -0,0 +1,73 @@
# MIL-001 Project Setup
## Metadata
| Key | Value |
| --- | --- |
| ID | MIL-001 |
| CrossReference | [BC-001], [SA-001] |
| Language | en |
| Domain | it |
## Version History
| Date | Status | Author | Reviewer | Change | Commit |
| --- | --- | --- | --- | --- | --- |
| 2026-10-17 | Accepted | Jens Tirsvad Nielsen | S01 | Initial version; reviewed in RC-003 (Go) | pending |
---
## Purpose
Decide whether the project skeleton is ready to hold code: configuration, tooling, ignore rules and repository metadata are in place and reviewed.
## Deliverable
A Python 3.13+ project skeleton: `pyproject.toml` with pytest and no runtime dependencies, `.gitignore`, `.env.example`, `src/` and `tests/` folders, `constants.py`, `Doxyfile`, `.venv` instructions, the assignment data files, and the repository description and topics on the git host. One pull request.
## Go / No-Go Criteria
| # | Criterion (objectively checkable) | Go | No-Go |
| --- | --- | --- | --- |
| 1 | `python -m pip install -e .[dev]` succeeds in a fresh `.venv` and `python -m pytest` runs (a smoke test passes) | Go | No-Go |
| 2 | `pyproject.toml` requires Python `>=3.13` and lists no runtime dependencies | Go | No-Go |
| 3 | `.gitignore` ignores `.venv/`, `__pycache__/` and `.env`; `.env` is not tracked | Go | No-Go |
| 4 | `Doxyfile` exists and `doxygen Doxyfile` runs without error (or the gap is recorded) | Go | No-Go |
| 5 | Repository description and topics are set on the git host (checked through the API) | Go | No-Go |
## Dependencies
| Depends on | Reason |
| --- | --- |
| none | First milestone |
## Traceability
| Business Case objective / KPI / user story | Reference |
| --- | --- |
| Objective 3 (tests), objective 5 (publish) | [BC-001] |
| S01, S03 concerns | [SA-001] |
## Ownership
| Role | Stakeholder ID (SA) |
| --- | --- |
| Owner | S01 |
| Approving reviewer | S01 |
## Target Date
2026-10-18 - within the schedule of the Business Case constraints.
## Tasks
| # | Task | Summary | Needs its own Use Case/User Story? | Reference |
| --- | --- | --- | --- | --- |
| 1 | Configure pyproject and tooling | Create `pyproject.toml` (`requires-python >=3.13`, no runtime dependencies, an optional `dev` extra with pytest, pytest configuration with `pythonpath = src`), a Python `.gitignore` that also ignores `.env`, and `.env.example` listing `GMAIL_TOKEN`. The token in `.env` is for personal use only and is never read by tests. | No | |
| 2 | Create src and tests layout with constants.py | Create the `src/birthday_wisher/` package with `constants.py` (file names, `[NAME]` placeholder, SMTP host and port, subject, environment variable names) and a `tests/` folder with a smoke test, so later work has a place to land. | No | |
| 3 | Add assignment data files | Add `birthdays.csv` (header `name,email,year,month,day`, dummy rows only, never a real address) and `letter_templates/letter_1.txt` to `letter_3.txt` from the course starter, keeping the `[NAME]` placeholder. | No | |
| 4 | Add Doxyfile | Add a `Doxyfile` that documents `src/` from the Doxygen comments and writes its output to an ignored `docs/doxygen/` folder. | No | |
| 5 | Set repository description and topics | Set the description and topics on the git host through its API, using `GITEA_TOKEN` read from the environment or `.env` without printing it. Stop and report if the token is missing or rejected. | No | |
---
[BC-001]: ../business-case.md
[SA-001]: ../stakeholder-analysis.md
@@ -0,0 +1,76 @@
# MIL-002 Birthday Wisher Core
## Metadata
| Key | Value |
| --- | --- |
| ID | MIL-002 |
| CrossReference | [BC-001], [SA-001], [MIL-001] |
| Language | en |
| Domain | it |
## Version History
| Date | Status | Author | Reviewer | Change | Commit |
| --- | --- | --- | --- | --- | --- |
| 2026-10-17 | Accepted | Jens Tirsvad Nielsen | S01 | Initial version; reviewed in RC-004 (Go) | pending |
---
## Purpose
Decide whether the birthday wisher works: it finds today's birthdays, builds a letter and sends it, with tests that need no network and no credentials.
## Deliverable
The `birthday_wisher` package: loading `birthdays.csv`, matching today's month and day, choosing a random template and replacing `[NAME]`, sending by SMTP with STARTTLS, a `main` entry point, and a pytest suite. All public items carry Doxygen comments.
## Go / No-Go Criteria
| # | Criterion (objectively checkable) | Go | No-Go |
| --- | --- | --- | --- |
| 1 | `python -m pytest` passes with no network access and without a `.env` file | Go | No-Go |
| 2 | A test proves that a person whose month and day equal today receives exactly one letter and nobody else does | Go | No-Go |
| 3 | A test proves that `[NAME]` is replaced and every one of the three templates can be chosen | Go | No-Go |
| 4 | A test with a fake SMTP object proves STARTTLS is called before login and that the subject is "Happy Birthday" | Go | No-Go |
| 5 | No source or test file imports or reads `.env`; the token is read from the `GMAIL_TOKEN` environment variable only | Go | No-Go |
| 6 | The code is reviewed against `qc-programming-python` and the review record says Go | Go | No-Go |
## Dependencies
| Depends on | Reason |
| --- | --- |
| [MIL-001] | Needs the skeleton, constants and data files |
## Traceability
| Business Case objective / KPI / user story | Reference |
| --- | --- |
| Objectives 1, 2 and 3 | [BC-001] |
| S01, S02 concerns | [SA-001] |
## Ownership
| Role | Stakeholder ID (SA) |
| --- | --- |
| Owner | S01 |
| Approving reviewer | S01 |
## Target Date
2026-10-19 - within the schedule of the Business Case constraints.
## Tasks
| # | Task | Summary | Needs its own Use Case/User Story? | Reference |
| --- | --- | --- | --- | --- |
| 1 | Load and match birthdays | Read `birthdays.csv` with the standard `csv` module into a dictionary keyed by `(month, day)` as the course hint describes, and return the people whose key equals today's `(month, day)`. Today is a parameter so tests can fix the date. | No | |
| 2 | Build the letter | Choose one of the letter templates at random (the chooser is injectable for tests), and replace `[NAME]` with the person's name. Fail with a clear message when a template is missing. | No | |
| 3 | Send the letter by SMTP | Send the letter with `smtplib`: connect to the host in `constants.py`, call `starttls()`, log in with the sender address and the `GMAIL_TOKEN` environment variable, and send with the subject "Happy Birthday". The SMTP class is injected; the token is never logged. | No | |
| 4 | Add main entry point | Wire the pieces together in `main.py` (composition root): load, match, build, send. Add a `--dry-run` option that prints instead of sending, used for screenshots and by learners without credentials. Exit with a non-zero status on error. | No | |
| 5 | Write pytest tests | Cover matching, letters, sending with a fake SMTP and the entry point with a fixed date. Tests use temporary files and never touch the network or `.env`. | No | |
| 6 | Review code against the Python checklist | Review `src/` and `tests/` against `qc-programming-python`, write the `RC-*` record and fix findings before the pull request. | No | |
---
[BC-001]: ../business-case.md
[SA-001]: ../stakeholder-analysis.md
[MIL-001]: ./mil-001-project-setup.md
@@ -0,0 +1,75 @@
# MIL-003 Documentation and Publication
## Metadata
| Key | Value |
| --- | --- |
| ID | MIL-003 |
| CrossReference | [BC-001], [SA-001], [MIL-002] |
| Language | en |
| Domain | it |
## Version History
| Date | Status | Author | Reviewer | Change | Commit |
| --- | --- | --- | --- | --- | --- |
| 2026-10-17 | Accepted | Jens Tirsvad Nielsen | S01 | Initial version; reviewed in RC-005 (Go) | pending |
---
## Purpose
Decide whether the project is ready for its readers: instructions, generated documentation and a tri-lingual wiki with screenshots exist and are correct.
## Deliverable
A README from the framework template with run and test instructions and screenshots; the `.venv` and `python -m pip install --upgrade pip` instructions; a wiki in `docs/wiki/` in English, Danish (`-da`) and Bahasa Malaysia (`-ms`) with the same pages and screenshots; the wiki publish workflow.
## Go / No-Go Criteria
| # | Criterion (objectively checkable) | Go | No-Go |
| --- | --- | --- | --- |
| 1 | `bash framework/scripts/check-readme.sh` passes on `README.md` | Go | No-Go |
| 2 | README shows how to create and use a local `.venv`, run `python -m pip install --upgrade pip`, run the program and run the tests, and each command works as written | Go | No-Go |
| 3 | The wiki has the same page set in en, da and ms, each page with the language line, and `_Sidebar.md` lists all three | Go | No-Go |
| 4 | README and each wiki language contain at least one screenshot, and no screenshot shows an address or token | Go | No-Go |
| 5 | `bash framework/scripts/check-languages.sh` passes | Go | No-Go |
## Dependencies
| Depends on | Reason |
| --- | --- |
| [MIL-002] | The screenshots and instructions describe the working program |
## Traceability
| Business Case objective / KPI / user story | Reference |
| --- | --- |
| Objectives 4 and 5 | [BC-001] |
| S02 and S03 concerns | [SA-001] |
## Ownership
| Role | Stakeholder ID (SA) |
| --- | --- |
| Owner | S01 |
| Approving reviewer | S01 |
## Target Date
2026-10-20 - within the schedule of the Business Case constraints.
## Tasks
| # | Task | Summary | Needs its own Use Case/User Story? | Reference |
| --- | --- | --- | --- | --- |
| 1 | Capture screenshots | Produce screenshots of a dry run, a test run and the `.venv` setup using the dummy data only, stored in `docs/images/`. Screenshots are rendered from terminal output by a script, never taken on the host desktop, and never show an address or token. | No | |
| 2 | Write README | Create `README.md` from the framework template: overview, requirements, `.venv` and `python -m pip install --upgrade pip` setup, run, tests, license, links, appendix of project documents, and screenshots. | No | |
| 3 | Write English wiki | Write the wiki pages in `docs/wiki/` in English (Home, Setup, Usage, Configuration, Testing, Architecture), with screenshots and a `_Sidebar.md`. | No | |
| 4 | Translate wiki to Danish | Translate each English wiki page to `<Page>-da.md`, same page set, language line on top, code and commands unchanged. | No | |
| 5 | Translate wiki to Bahasa Malaysia | Translate each English wiki page to `<Page>-ms.md`, same page set, language line on top, code and commands unchanged. | No | |
| 6 | Add wiki publish workflow | Copy `framework/templates/ci/publish-wiki.yml` to the project CI folder so the wiki reaches the git host by merge. | No | |
---
[BC-001]: ../business-case.md
[SA-001]: ../stakeholder-analysis.md
[MIL-002]: ./mil-002-birthday-wisher-core.md