Compare commits
3
Commits
d8b08cb0b3
...
6809db7930
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
6809db7930 | ||
|
|
31c713e995 | ||
|
|
8ccefffef7 |
+175
-176
@@ -1,176 +1,175 @@
|
|||||||
# ---> Python
|
# ---> Python
|
||||||
# Byte-compiled / optimized / DLL files
|
# Byte-compiled / optimized / DLL files
|
||||||
__pycache__/
|
__pycache__/
|
||||||
*.py[cod]
|
*.py[cod]
|
||||||
*$py.class
|
*$py.class
|
||||||
|
|
||||||
# C extensions
|
# C extensions
|
||||||
*.so
|
*.so
|
||||||
|
|
||||||
# Distribution / packaging
|
# Distribution / packaging
|
||||||
.Python
|
.Python
|
||||||
build/
|
build/
|
||||||
develop-eggs/
|
develop-eggs/
|
||||||
dist/
|
dist/
|
||||||
downloads/
|
downloads/
|
||||||
eggs/
|
eggs/
|
||||||
.eggs/
|
.eggs/
|
||||||
lib/
|
lib/
|
||||||
lib64/
|
lib64/
|
||||||
parts/
|
parts/
|
||||||
sdist/
|
sdist/
|
||||||
var/
|
var/
|
||||||
wheels/
|
wheels/
|
||||||
share/python-wheels/
|
share/python-wheels/
|
||||||
*.egg-info/
|
*.egg-info/
|
||||||
.installed.cfg
|
.installed.cfg
|
||||||
*.egg
|
*.egg
|
||||||
MANIFEST
|
MANIFEST
|
||||||
|
|
||||||
# PyInstaller
|
# PyInstaller
|
||||||
# Usually these files are written by a python script from a template
|
# Usually these files are written by a python script from a template
|
||||||
# before PyInstaller builds the exe, so as to inject date/other infos into it.
|
# before PyInstaller builds the exe, so as to inject date/other infos into it.
|
||||||
*.manifest
|
*.manifest
|
||||||
*.spec
|
*.spec
|
||||||
|
|
||||||
# Installer logs
|
# Installer logs
|
||||||
pip-log.txt
|
pip-log.txt
|
||||||
pip-delete-this-directory.txt
|
pip-delete-this-directory.txt
|
||||||
|
|
||||||
# Unit test / coverage reports
|
# Unit test / coverage reports
|
||||||
htmlcov/
|
htmlcov/
|
||||||
.tox/
|
.tox/
|
||||||
.nox/
|
.nox/
|
||||||
.coverage
|
.coverage
|
||||||
.coverage.*
|
.coverage.*
|
||||||
.cache
|
.cache
|
||||||
nosetests.xml
|
nosetests.xml
|
||||||
coverage.xml
|
coverage.xml
|
||||||
*.cover
|
*.cover
|
||||||
*.py,cover
|
*.py,cover
|
||||||
.hypothesis/
|
.hypothesis/
|
||||||
.pytest_cache/
|
.pytest_cache/
|
||||||
cover/
|
cover/
|
||||||
|
|
||||||
# Translations
|
# Translations
|
||||||
*.mo
|
*.mo
|
||||||
*.pot
|
*.pot
|
||||||
|
|
||||||
# Django stuff:
|
# Django stuff:
|
||||||
*.log
|
*.log
|
||||||
local_settings.py
|
local_settings.py
|
||||||
db.sqlite3
|
db.sqlite3
|
||||||
db.sqlite3-journal
|
db.sqlite3-journal
|
||||||
|
|
||||||
# Flask stuff:
|
# Flask stuff:
|
||||||
instance/
|
instance/
|
||||||
.webassets-cache
|
.webassets-cache
|
||||||
|
|
||||||
# Scrapy stuff:
|
# Scrapy stuff:
|
||||||
.scrapy
|
.scrapy
|
||||||
|
|
||||||
# Sphinx documentation
|
# Sphinx documentation
|
||||||
docs/_build/
|
docs/_build/
|
||||||
|
|
||||||
# PyBuilder
|
# PyBuilder
|
||||||
.pybuilder/
|
.pybuilder/
|
||||||
target/
|
target/
|
||||||
|
|
||||||
# Jupyter Notebook
|
# Jupyter Notebook
|
||||||
.ipynb_checkpoints
|
.ipynb_checkpoints
|
||||||
|
|
||||||
# IPython
|
# IPython
|
||||||
profile_default/
|
profile_default/
|
||||||
ipython_config.py
|
ipython_config.py
|
||||||
|
|
||||||
# pyenv
|
# pyenv
|
||||||
# For a library or package, you might want to ignore these files since the code is
|
# For a library or package, you might want to ignore these files since the code is
|
||||||
# intended to run in multiple environments; otherwise, check them in:
|
# intended to run in multiple environments; otherwise, check them in:
|
||||||
# .python-version
|
# .python-version
|
||||||
|
|
||||||
# pipenv
|
# pipenv
|
||||||
# According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control.
|
# According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control.
|
||||||
# However, in case of collaboration, if having platform-specific dependencies or dependencies
|
# However, in case of collaboration, if having platform-specific dependencies or dependencies
|
||||||
# having no cross-platform support, pipenv may install dependencies that don't work, or not
|
# having no cross-platform support, pipenv may install dependencies that don't work, or not
|
||||||
# install all needed dependencies.
|
# install all needed dependencies.
|
||||||
#Pipfile.lock
|
#Pipfile.lock
|
||||||
|
|
||||||
# UV
|
# UV
|
||||||
# Similar to Pipfile.lock, it is generally recommended to include uv.lock in version control.
|
# Similar to Pipfile.lock, it is generally recommended to include uv.lock in version control.
|
||||||
# This is especially recommended for binary packages to ensure reproducibility, and is more
|
# This is especially recommended for binary packages to ensure reproducibility, and is more
|
||||||
# commonly ignored for libraries.
|
# commonly ignored for libraries.
|
||||||
#uv.lock
|
#uv.lock
|
||||||
|
|
||||||
# poetry
|
# poetry
|
||||||
# Similar to Pipfile.lock, it is generally recommended to include poetry.lock in version control.
|
# Similar to Pipfile.lock, it is generally recommended to include poetry.lock in version control.
|
||||||
# This is especially recommended for binary packages to ensure reproducibility, and is more
|
# This is especially recommended for binary packages to ensure reproducibility, and is more
|
||||||
# commonly ignored for libraries.
|
# commonly ignored for libraries.
|
||||||
# https://python-poetry.org/docs/basic-usage/#commit-your-poetrylock-file-to-version-control
|
# https://python-poetry.org/docs/basic-usage/#commit-your-poetrylock-file-to-version-control
|
||||||
#poetry.lock
|
#poetry.lock
|
||||||
|
|
||||||
# pdm
|
# pdm
|
||||||
# Similar to Pipfile.lock, it is generally recommended to include pdm.lock in version control.
|
# Similar to Pipfile.lock, it is generally recommended to include pdm.lock in version control.
|
||||||
#pdm.lock
|
#pdm.lock
|
||||||
# pdm stores project-wide configurations in .pdm.toml, but it is recommended to not include it
|
# pdm stores project-wide configurations in .pdm.toml, but it is recommended to not include it
|
||||||
# in version control.
|
# in version control.
|
||||||
# https://pdm.fming.dev/latest/usage/project/#working-with-version-control
|
# https://pdm.fming.dev/latest/usage/project/#working-with-version-control
|
||||||
.pdm.toml
|
.pdm.toml
|
||||||
.pdm-python
|
.pdm-python
|
||||||
.pdm-build/
|
.pdm-build/
|
||||||
|
|
||||||
# PEP 582; used by e.g. github.com/David-OConnor/pyflow and github.com/pdm-project/pdm
|
# PEP 582; used by e.g. github.com/David-OConnor/pyflow and github.com/pdm-project/pdm
|
||||||
__pypackages__/
|
__pypackages__/
|
||||||
|
|
||||||
# Celery stuff
|
# Celery stuff
|
||||||
celerybeat-schedule
|
celerybeat-schedule
|
||||||
celerybeat.pid
|
celerybeat.pid
|
||||||
|
|
||||||
# SageMath parsed files
|
# SageMath parsed files
|
||||||
*.sage.py
|
*.sage.py
|
||||||
|
|
||||||
# Environments
|
# Environments
|
||||||
.env
|
.env
|
||||||
.venv
|
.venv
|
||||||
env/
|
env/
|
||||||
venv/
|
venv/
|
||||||
ENV/
|
ENV/
|
||||||
env.bak/
|
env.bak/
|
||||||
venv.bak/
|
venv.bak/
|
||||||
|
|
||||||
# Spyder project settings
|
# Spyder project settings
|
||||||
.spyderproject
|
.spyderproject
|
||||||
.spyproject
|
.spyproject
|
||||||
|
|
||||||
# Rope project settings
|
# Rope project settings
|
||||||
.ropeproject
|
.ropeproject
|
||||||
|
|
||||||
# mkdocs documentation
|
# mkdocs documentation
|
||||||
/site
|
/site
|
||||||
|
|
||||||
# mypy
|
# mypy
|
||||||
.mypy_cache/
|
.mypy_cache/
|
||||||
.dmypy.json
|
.dmypy.json
|
||||||
dmypy.json
|
dmypy.json
|
||||||
|
|
||||||
# Pyre type checker
|
# Pyre type checker
|
||||||
.pyre/
|
.pyre/
|
||||||
|
|
||||||
# pytype static type analyzer
|
# pytype static type analyzer
|
||||||
.pytype/
|
.pytype/
|
||||||
|
|
||||||
# Cython debug symbols
|
# Cython debug symbols
|
||||||
cython_debug/
|
cython_debug/
|
||||||
|
|
||||||
# PyCharm
|
# PyCharm
|
||||||
# JetBrains specific template is maintained in a separate JetBrains.gitignore that can
|
# JetBrains specific template is maintained in a separate JetBrains.gitignore that can
|
||||||
# be found at https://github.com/github/gitignore/blob/main/Global/JetBrains.gitignore
|
# be found at https://github.com/github/gitignore/blob/main/Global/JetBrains.gitignore
|
||||||
# and can be added to the global gitignore or merged into this file. For a more nuclear
|
# and can be added to the global gitignore or merged into this file. For a more nuclear
|
||||||
# option (not recommended) you can uncomment the following to ignore the entire idea folder.
|
# option (not recommended) you can uncomment the following to ignore the entire idea folder.
|
||||||
#.idea/
|
#.idea/
|
||||||
|
|
||||||
# Ruff stuff:
|
# Ruff stuff:
|
||||||
.ruff_cache/
|
.ruff_cache/
|
||||||
|
|
||||||
# PyPI configuration file
|
# PyPI configuration file
|
||||||
.pypirc
|
.pypirc
|
||||||
|
|
||||||
|
|||||||
@@ -0,0 +1,3 @@
|
|||||||
|
[submodule "framework"]
|
||||||
|
path = framework
|
||||||
|
url = ssh://git@git.tirsystem.com:10022/TirSystem/SQA-QC-Framework.git
|
||||||
@@ -0,0 +1,43 @@
|
|||||||
|
# Artifact Registry
|
||||||
|
|
||||||
|
This project's artifact state. Types, short names and `CrossReference
|
||||||
|
Candidates` come from the framework catalog
|
||||||
|
(`framework/registry/artifact-catalog.md`); this file only records where
|
||||||
|
each document lives in *this* project and the next version to use.
|
||||||
|
|
||||||
|
Delete rows for types you don't use. Add a row the first time you create a
|
||||||
|
document of a type. `Primary File` may contain a glob (e.g.
|
||||||
|
`docs/uc-*/uc.md`); `framework/scripts/find-crossreferences.sh` reads it.
|
||||||
|
|
||||||
|
| Short Name | Artifact Type | Primary File | Next Available Version |
|
||||||
|
| --- | --- | --- | --- |
|
||||||
|
| PP | Project Plan | docs/project-plan.md | 002 |
|
||||||
|
| MIL | Milestone / Gateway | docs/milestones/*.md | 005 |
|
||||||
|
| BC | Business Case | docs/business-case.md | 002 |
|
||||||
|
| SA | Stakeholder Analysis | docs/stakeholder-analysis.md | 002 |
|
||||||
|
|
||||||
|
## Languages
|
||||||
|
|
||||||
|
Set the PO language when the project starts; `project-planning` asks for it
|
||||||
|
if it is missing. A translated artifact is named `<artifact>.<language>.md`
|
||||||
|
(for example `business-case.da.md`); the English file stays the source.
|
||||||
|
|
||||||
|
| Setting | Value |
|
||||||
|
| --- | --- |
|
||||||
|
| PO language | en |
|
||||||
|
| High-level register | IT Executive English |
|
||||||
|
| Technical register | IT Professional English |
|
||||||
|
|
||||||
|
| Artifact types | Register | Also kept as a PO-language file |
|
||||||
|
| --- | --- | --- |
|
||||||
|
| BC, KPI, PP, MIL | IT Executive English | Yes |
|
||||||
|
| SA, BMC, BPMN, UCD, US, UC, SSD, DM, RA, GOV, DICT | IT Professional English | Yes |
|
||||||
|
| OC, SD, DCD, ERD, ADR, TM, RC, QC, source code | IT Professional English | No |
|
||||||
|
|
||||||
|
## Notes
|
||||||
|
|
||||||
|
- "Next Available Version" is the zero-padded (3-digit) version to use the
|
||||||
|
*next* time a new document of that type is created. Increment it only when
|
||||||
|
a brand-new document is created, not when an existing document's
|
||||||
|
`## Version History` gets a row.
|
||||||
|
- `ADR` uses 4 digits (`0001`); `RC` is sequential across all artifact types.
|
||||||
@@ -0,0 +1,107 @@
|
|||||||
|
# Business Case
|
||||||
|
|
||||||
|
## Metadata
|
||||||
|
| Key | Value |
|
||||||
|
| --- | --- |
|
||||||
|
| ID | BC-001 |
|
||||||
|
| CrossReference | [SA-001] |
|
||||||
|
|
||||||
|
## Version History
|
||||||
|
| Date | Status | Author | Reviewer | Change | Commit |
|
||||||
|
| --- | --- | --- | --- | --- | --- |
|
||||||
|
| 2026-10-04 | Accepted | Jens Tirsvad Nielsen | S01 | Initial version | [8ccefff] |
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Executive Summary
|
||||||
|
|
||||||
|
Day 10 of the Udemy course "100 Days of Code: The Complete Python Pro Bootcamp" asks for a console calculator that uses functions, a dictionary of functions, user input, a loop and recursion. This project delivers it as a small, tested and documented Python 3.13+ program with no runtime dependencies.
|
||||||
|
|
||||||
|
## Methodological and Standards Foundation
|
||||||
|
|
||||||
|
The SQA and QC framework in `framework/` (plan first, then code), ISO/IEC 25010:2023 for quality characteristics, and the Python conventions of the `coding-conventions` skill.
|
||||||
|
|
||||||
|
## Problem Statement
|
||||||
|
|
||||||
|
The assignment needs a finished, verifiable result with setup and run instructions, not a single untested script.
|
||||||
|
|
||||||
|
## Business Opportunity
|
||||||
|
|
||||||
|
A compact reference project that shows the lecture concepts and can serve as the template for later course days.
|
||||||
|
|
||||||
|
## Objectives
|
||||||
|
|
||||||
|
1. Add, subtract, multiply and divide two numbers from console input.
|
||||||
|
2. Store the operations as functions in a dictionary and call them through it.
|
||||||
|
3. Let the user continue with the previous result or start a new calculation, restarting by recursion.
|
||||||
|
4. Cover the behaviour with automated tests and document setup, run and tests in the README.
|
||||||
|
|
||||||
|
## Scope
|
||||||
|
|
||||||
|
### In Scope
|
||||||
|
|
||||||
|
Console program under `src/`, tests under `tests/`, `pyproject.toml`, `Doxyfile`, README, ASCII title and calculator, repository description and topics.
|
||||||
|
|
||||||
|
### Out of Scope
|
||||||
|
|
||||||
|
Graphical or web interface, further operations, packaging for PyPI, runtime dependencies.
|
||||||
|
|
||||||
|
## Expected Benefits
|
||||||
|
|
||||||
|
### Tangible Benefits
|
||||||
|
|
||||||
|
A working, tested calculator and a reproducible setup with a local `.venv`.
|
||||||
|
|
||||||
|
### Intangible Benefits
|
||||||
|
|
||||||
|
Practice with the plan-first process on a small project.
|
||||||
|
|
||||||
|
## Strategic Alignment
|
||||||
|
|
||||||
|
Supports completing the Python Pro Bootcamp with reviewed, portfolio-quality projects.
|
||||||
|
|
||||||
|
## Success Criteria
|
||||||
|
|
||||||
|
| # | Criterion | Target | Measure |
|
||||||
|
| --- | --- | --- | --- |
|
||||||
|
| 1 | Operations and loop work | All tests pass | `python -m pytest` |
|
||||||
|
| 2 | Setup is reproducible | README steps work on a clean `.venv` | Manual run of the README |
|
||||||
|
| 3 | No runtime dependencies | Empty dependency list | `pyproject.toml` |
|
||||||
|
|
||||||
|
## Risks
|
||||||
|
|
||||||
|
| Risk | Impact | Mitigation |
|
||||||
|
| --- | --- | --- |
|
||||||
|
| Doxygen is not installed locally | Docs build not checked | README names it as optional |
|
||||||
|
| Token in `.env` leaks | Account compromise | `.env` stays git-ignored and is never read by the project |
|
||||||
|
|
||||||
|
## Assumptions
|
||||||
|
|
||||||
|
- Python 3.13 or newer is installed.
|
||||||
|
- The git host is reachable for issues and pull requests.
|
||||||
|
|
||||||
|
## Constraints
|
||||||
|
|
||||||
|
- Python 3.13 or newer, `venv`, folders `src/`, `tests/`, `docs/`, constants in `constants.py`.
|
||||||
|
- No commit or push without the Product Owner's request.
|
||||||
|
|
||||||
|
## Cost–Benefit Assessment
|
||||||
|
|
||||||
|
| Costs | Benefits |
|
||||||
|
| --- | --- |
|
||||||
|
| A few hours of the Product Owner's time | A finished, documented assignment and a reusable project skeleton |
|
||||||
|
|
||||||
|
## Stakeholders
|
||||||
|
|
||||||
|
| Stakeholder ID (SA) | Interest in this project |
|
||||||
|
| --- | --- |
|
||||||
|
| S01 | Owns the assignment, does the work and accepts each milestone |
|
||||||
|
|
||||||
|
## Recommendation
|
||||||
|
|
||||||
|
Proceed — the scope is small, the cost is low and it completes the assignment.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
[SA-001]: ./stakeholder-analysis.md
|
||||||
|
[8ccefff]: https://git.tirsystem.com/Tirsvad-Udemy-100_days_of_code/010-calc/commit/8ccefffef7ec1f9ecbf548085a5c92fae75e1341
|
||||||
@@ -0,0 +1,70 @@
|
|||||||
|
# MIL-001 Project scaffold
|
||||||
|
|
||||||
|
## Metadata
|
||||||
|
| Key | Value |
|
||||||
|
| --- | --- |
|
||||||
|
| ID | MIL-001 |
|
||||||
|
| CrossReference | [PP-001], [SA-001], [BC-001] |
|
||||||
|
|
||||||
|
## Version History
|
||||||
|
| Date | Status | Author | Reviewer | Change | Commit |
|
||||||
|
| --- | --- | --- | --- | --- | --- |
|
||||||
|
| 2026-10-04 | Accepted | Jens Tirsvad Nielsen | S01 | Initial version | [8ccefff] |
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Purpose
|
||||||
|
|
||||||
|
Decide whether the repository is ready for code: layout, tooling and configuration exist and a fresh clone can create a local virtual environment.
|
||||||
|
|
||||||
|
## Deliverable
|
||||||
|
|
||||||
|
`pyproject.toml`, Python `.gitignore`, `src/calc/` and `tests/` skeletons, `Doxyfile`, repository description and topics on the git host.
|
||||||
|
|
||||||
|
## Go / No-Go Criteria
|
||||||
|
|
||||||
|
| # | Criterion (objectively checkable) | Go | No-Go |
|
||||||
|
| --- | --- | --- | --- |
|
||||||
|
| 1 | `pyproject.toml` requires Python 3.13 or newer and has no runtime dependencies | Met | Not met |
|
||||||
|
| 2 | `.gitignore` covers `.venv`, `.env` and `docs/doxygen/` | Met | Not met |
|
||||||
|
| 3 | Folders `src/`, `tests/` and `docs/` exist | Met | Not met |
|
||||||
|
| 4 | Repository description and topics are set on the git host | Met | Not met |
|
||||||
|
|
||||||
|
## Dependencies
|
||||||
|
|
||||||
|
| Depends on | Reason |
|
||||||
|
| --- | --- |
|
||||||
|
| None | First milestone |
|
||||||
|
|
||||||
|
## Traceability
|
||||||
|
|
||||||
|
| Business Case objective / KPI / user story | Reference |
|
||||||
|
| --- | --- |
|
||||||
|
| Objectives 1 to 4 | [BC-001] |
|
||||||
|
|
||||||
|
## Ownership
|
||||||
|
|
||||||
|
| Role | Stakeholder ID (SA) |
|
||||||
|
| --- | --- |
|
||||||
|
| Owner | S01 |
|
||||||
|
| Approving reviewer | S01 |
|
||||||
|
|
||||||
|
## Target Date
|
||||||
|
|
||||||
|
2026-10-05
|
||||||
|
|
||||||
|
## Tasks
|
||||||
|
|
||||||
|
| # | Task | Summary | Needs its own Use Case/User Story? | Reference |
|
||||||
|
| --- | --- | --- | --- | --- |
|
||||||
|
| 1 | Add pyproject.toml | Project configuration: name, version, Python 3.13+ requirement, empty runtime dependencies, `dev` extra with pytest, console script `calc`, pytest settings. | No | |
|
||||||
|
| 2 | Add Python .gitignore and folder layout | Python `.gitignore` that also ignores `.env`, `.venv` and `docs/doxygen/`; create `src/calc/` and `tests/`. | No | |
|
||||||
|
| 3 | Add Doxyfile | Doxygen configuration reading `src/`, writing to `docs/doxygen/`, so Doxygen-style comments can be built into API docs. | No | |
|
||||||
|
| 4 | Set repository description and topics | Set the description and topics on the git host repository through its API, with the token from `.env`, which is personal tooling and never part of the project. | No | |
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
[PP-001]: ../project-plan.md
|
||||||
|
[SA-001]: ../stakeholder-analysis.md
|
||||||
|
[BC-001]: ../business-case.md
|
||||||
|
[8ccefff]: https://git.tirsystem.com/Tirsvad-Udemy-100_days_of_code/010-calc/commit/8ccefffef7ec1f9ecbf548085a5c92fae75e1341
|
||||||
@@ -0,0 +1,70 @@
|
|||||||
|
# MIL-002 Calculator core
|
||||||
|
|
||||||
|
## Metadata
|
||||||
|
| Key | Value |
|
||||||
|
| --- | --- |
|
||||||
|
| ID | MIL-002 |
|
||||||
|
| CrossReference | [PP-001], [SA-001], [BC-001] |
|
||||||
|
|
||||||
|
## Version History
|
||||||
|
| Date | Status | Author | Reviewer | Change | Commit |
|
||||||
|
| --- | --- | --- | --- | --- | --- |
|
||||||
|
| 2026-10-04 | Accepted | Jens Tirsvad Nielsen | S01 | Initial version | [8ccefff] |
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Purpose
|
||||||
|
|
||||||
|
Decide whether the arithmetic core is correct and tested before the console interface is built on it.
|
||||||
|
|
||||||
|
## Deliverable
|
||||||
|
|
||||||
|
`src/calc/constants.py` and `src/calc/operations.py` with add, subtract, multiply, divide and the `OPERATIONS` dictionary, plus `tests/test_operations.py`.
|
||||||
|
|
||||||
|
## Go / No-Go Criteria
|
||||||
|
|
||||||
|
| # | Criterion (objectively checkable) | Go | No-Go |
|
||||||
|
| --- | --- | --- | --- |
|
||||||
|
| 1 | The four operations return correct results in the tests | Met | Not met |
|
||||||
|
| 2 | Division by zero raises `ZeroDivisionError` | Met | Not met |
|
||||||
|
| 3 | `OPERATIONS` maps `+ - * /` to the stored (not called) functions | Met | Not met |
|
||||||
|
| 4 | All constants live in `constants.py` | Met | Not met |
|
||||||
|
| 5 | Every function has a Doxygen comment | Met | Not met |
|
||||||
|
|
||||||
|
## Dependencies
|
||||||
|
|
||||||
|
| Depends on | Reason |
|
||||||
|
| --- | --- |
|
||||||
|
| MIL-001 | Needs the package layout and configuration |
|
||||||
|
|
||||||
|
## Traceability
|
||||||
|
|
||||||
|
| Business Case objective / KPI / user story | Reference |
|
||||||
|
| --- | --- |
|
||||||
|
| Objectives 1 to 4 | [BC-001] |
|
||||||
|
|
||||||
|
## Ownership
|
||||||
|
|
||||||
|
| Role | Stakeholder ID (SA) |
|
||||||
|
| --- | --- |
|
||||||
|
| Owner | S01 |
|
||||||
|
| Approving reviewer | S01 |
|
||||||
|
|
||||||
|
## Target Date
|
||||||
|
|
||||||
|
2026-10-06
|
||||||
|
|
||||||
|
## Tasks
|
||||||
|
|
||||||
|
| # | Task | Summary | Needs its own Use Case/User Story? | Reference |
|
||||||
|
| --- | --- | --- | --- | --- |
|
||||||
|
| 1 | Add constants module | `constants.py` holding operation symbols, answers, prompts, messages and the ASCII art, so no literals are scattered through the code. | No | |
|
||||||
|
| 2 | Implement the four operations and the OPERATIONS dictionary | Functions `add`, `subtract`, `multiply`, `divide` and a dictionary mapping each symbol to its function, stored without calling them, as taught in the lecture. | No | |
|
||||||
|
| 3 | Add operation tests | pytest tests for each operation, division by zero and the dictionary contents. | No | |
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
[PP-001]: ../project-plan.md
|
||||||
|
[SA-001]: ../stakeholder-analysis.md
|
||||||
|
[BC-001]: ../business-case.md
|
||||||
|
[8ccefff]: https://git.tirsystem.com/Tirsvad-Udemy-100_days_of_code/010-calc/commit/8ccefffef7ec1f9ecbf548085a5c92fae75e1341
|
||||||
@@ -0,0 +1,71 @@
|
|||||||
|
# MIL-003 Console interface
|
||||||
|
|
||||||
|
## Metadata
|
||||||
|
| Key | Value |
|
||||||
|
| --- | --- |
|
||||||
|
| ID | MIL-003 |
|
||||||
|
| CrossReference | [PP-001], [SA-001], [BC-001] |
|
||||||
|
|
||||||
|
## Version History
|
||||||
|
| Date | Status | Author | Reviewer | Change | Commit |
|
||||||
|
| --- | --- | --- | --- | --- | --- |
|
||||||
|
| 2026-10-04 | Accepted | Jens Tirsvad Nielsen | S01 | Initial version | [8ccefff] |
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Purpose
|
||||||
|
|
||||||
|
Decide whether the interactive calculator behaves as the lecture describes, including continuing with the result and restarting by recursion.
|
||||||
|
|
||||||
|
## Deliverable
|
||||||
|
|
||||||
|
`src/calc/calculator.py` and `src/calc/__main__.py` with the ASCII title and calculator, input handling and the recursive restart, plus `tests/test_calculator.py`.
|
||||||
|
|
||||||
|
## Go / No-Go Criteria
|
||||||
|
|
||||||
|
| # | Criterion (objectively checkable) | Go | No-Go |
|
||||||
|
| --- | --- | --- | --- |
|
||||||
|
| 1 | The program asks for a number, an operation and a second number | Met | Not met |
|
||||||
|
| 2 | Answer `y` continues with the previous result, `n` starts a new calculation by calling `calculator()` again, `q` quits | Met | Not met |
|
||||||
|
| 3 | Invalid numbers, operations and answers are re-prompted; division by zero restarts the calculator | Met | Not met |
|
||||||
|
| 4 | ASCII title and ASCII calculator are shown at start | Met | Not met |
|
||||||
|
| 5 | `python -m calc` runs and the tests pass | Met | Not met |
|
||||||
|
|
||||||
|
## Dependencies
|
||||||
|
|
||||||
|
| Depends on | Reason |
|
||||||
|
| --- | --- |
|
||||||
|
| MIL-002 | Uses the operations dictionary and constants |
|
||||||
|
|
||||||
|
## Traceability
|
||||||
|
|
||||||
|
| Business Case objective / KPI / user story | Reference |
|
||||||
|
| --- | --- |
|
||||||
|
| Objectives 1 to 4 | [BC-001] |
|
||||||
|
|
||||||
|
## Ownership
|
||||||
|
|
||||||
|
| Role | Stakeholder ID (SA) |
|
||||||
|
| --- | --- |
|
||||||
|
| Owner | S01 |
|
||||||
|
| Approving reviewer | S01 |
|
||||||
|
|
||||||
|
## Target Date
|
||||||
|
|
||||||
|
2026-10-07
|
||||||
|
|
||||||
|
## Tasks
|
||||||
|
|
||||||
|
| # | Task | Summary | Needs its own Use Case/User Story? | Reference |
|
||||||
|
| --- | --- | --- | --- | --- |
|
||||||
|
| 1 | Implement the calculator loop with recursive restart | `calculator()` reads the numbers and operation, looks the function up in `OPERATIONS`, and lets the user continue with the result or call `calculator()` again for a new calculation. | No | |
|
||||||
|
| 2 | Add ASCII title and ASCII calculator | Show the ASCII title and an ASCII calculator when the program starts, taken from `constants.py`. | No | |
|
||||||
|
| 3 | Handle invalid input and division by zero | Re-prompt on non-numeric input, unknown operations and unknown answers; print a message and restart on division by zero. | No | |
|
||||||
|
| 4 | Add interface tests | pytest tests that feed `input()` through monkeypatch and check the printed results, the continue and new paths, re-prompts and the ASCII art. | No | |
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
[PP-001]: ../project-plan.md
|
||||||
|
[SA-001]: ../stakeholder-analysis.md
|
||||||
|
[BC-001]: ../business-case.md
|
||||||
|
[8ccefff]: https://git.tirsystem.com/Tirsvad-Udemy-100_days_of_code/010-calc/commit/8ccefffef7ec1f9ecbf548085a5c92fae75e1341
|
||||||
@@ -0,0 +1,69 @@
|
|||||||
|
# MIL-004 Documentation and release
|
||||||
|
|
||||||
|
## Metadata
|
||||||
|
| Key | Value |
|
||||||
|
| --- | --- |
|
||||||
|
| ID | MIL-004 |
|
||||||
|
| CrossReference | [PP-001], [SA-001], [BC-001] |
|
||||||
|
|
||||||
|
## Version History
|
||||||
|
| Date | Status | Author | Reviewer | Change | Commit |
|
||||||
|
| --- | --- | --- | --- | --- | --- |
|
||||||
|
| 2026-10-04 | Accepted | Jens Tirsvad Nielsen | S01 | Initial version | [8ccefff] |
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Purpose
|
||||||
|
|
||||||
|
Decide whether the project can be handed over: a new user can set it up, run it and test it from the README alone.
|
||||||
|
|
||||||
|
## Deliverable
|
||||||
|
|
||||||
|
`README.md` following the project template, Doxygen output building without warnings, AGPL licence referenced.
|
||||||
|
|
||||||
|
## Go / No-Go Criteria
|
||||||
|
|
||||||
|
| # | Criterion (objectively checkable) | Go | No-Go |
|
||||||
|
| --- | --- | --- | --- |
|
||||||
|
| 1 | README has Overview, Requirements, Setup, Run, Tests, License and Links | Met | Not met |
|
||||||
|
| 2 | README explains creating `.venv` and `python -m pip install --upgrade pip` | Met | Not met |
|
||||||
|
| 3 | `doxygen Doxyfile` builds with no warnings | Met | Not met |
|
||||||
|
| 4 | Following the README on a clean clone, the program runs and the tests pass | Met | Not met |
|
||||||
|
|
||||||
|
## Dependencies
|
||||||
|
|
||||||
|
| Depends on | Reason |
|
||||||
|
| --- | --- |
|
||||||
|
| MIL-003 | Documents the finished program |
|
||||||
|
|
||||||
|
## Traceability
|
||||||
|
|
||||||
|
| Business Case objective / KPI / user story | Reference |
|
||||||
|
| --- | --- |
|
||||||
|
| Objectives 1 to 4 | [BC-001] |
|
||||||
|
|
||||||
|
## Ownership
|
||||||
|
|
||||||
|
| Role | Stakeholder ID (SA) |
|
||||||
|
| --- | --- |
|
||||||
|
| Owner | S01 |
|
||||||
|
| Approving reviewer | S01 |
|
||||||
|
|
||||||
|
## Target Date
|
||||||
|
|
||||||
|
2026-10-08
|
||||||
|
|
||||||
|
## Tasks
|
||||||
|
|
||||||
|
| # | Task | Summary | Needs its own Use Case/User Story? | Reference |
|
||||||
|
| --- | --- | --- | --- | --- |
|
||||||
|
| 1 | Write README.md | README from the project template with calculator-specific text: venv setup, pip upgrade, run, tests, AGPL license and links. | No | |
|
||||||
|
| 2 | Verify Doxygen build | Run `doxygen Doxyfile` and fix any warnings so every module and function is documented. | No | |
|
||||||
|
| 3 | Verify setup from a clean clone | Follow the README in a fresh `.venv` to confirm install, run and test commands work as written. | No | |
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
[PP-001]: ../project-plan.md
|
||||||
|
[SA-001]: ../stakeholder-analysis.md
|
||||||
|
[BC-001]: ../business-case.md
|
||||||
|
[8ccefff]: https://git.tirsystem.com/Tirsvad-Udemy-100_days_of_code/010-calc/commit/8ccefffef7ec1f9ecbf548085a5c92fae75e1341
|
||||||
@@ -0,0 +1,88 @@
|
|||||||
|
# Project Plan
|
||||||
|
|
||||||
|
## Metadata
|
||||||
|
| Key | Value |
|
||||||
|
| --- | --- |
|
||||||
|
| ID | PP-001 |
|
||||||
|
| CrossReference | [MIL-001], [MIL-002], [MIL-003], [MIL-004], [SA-001], [BC-001] |
|
||||||
|
|
||||||
|
## Version History
|
||||||
|
| Date | Status | Author | Reviewer | Change | Commit |
|
||||||
|
| --- | --- | --- | --- | --- | --- |
|
||||||
|
| 2026-10-04 | Accepted | Jens Tirsvad Nielsen | S01 | Initial version | [8ccefff] |
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Purpose
|
||||||
|
|
||||||
|
Schedule the four phases that deliver the console calculator of Udemy's "100 Days of Code" day 10 assignment. This is a very small project, so the Business Case is short and the Stakeholder Analysis names only the Product Owner (S01); the plan, the milestones and their tasks are the whole planning trail. Each phase is one branch and one pull request, and each task is synced as an issue.
|
||||||
|
|
||||||
|
## Planning Assumptions
|
||||||
|
|
||||||
|
- Work starts 2026-10-05 and ends by 2026-10-08, one phase per day.
|
||||||
|
- Owner and reviewer are the Product Owner, S01. The review is the Product Owner accepting the document.
|
||||||
|
- Product Owner language: English.
|
||||||
|
- Python 3.13 or newer, `venv`, `src/ tests/ docs/` layout, constants in `constants.py`, Doxygen comments.
|
||||||
|
- `.env` holds a personal token used only for tooling; the project never reads or tests it.
|
||||||
|
- Nothing is committed or pushed until the Product Owner asks.
|
||||||
|
|
||||||
|
## Gateway Schedule
|
||||||
|
|
||||||
|
| Gateway | Document | Window | Decision date | Owner | Stories | Main deliverable | Milestone |
|
||||||
|
| --- | --- | --- | --- | --- | --- | --- | --- |
|
||||||
|
| Project scaffold | [MIL-001] | 2026-10-05 | 2026-10-05 | S01 | | `pyproject.toml` | |
|
||||||
|
| Calculator core | [MIL-002] | 2026-10-06 | 2026-10-06 | S01 | | `src/calc/constants.py` and `src/calc/operations.py` | |
|
||||||
|
| Console interface | [MIL-003] | 2026-10-07 | 2026-10-07 | S01 | | `src/calc/calculator.py` and `src/calc/__main__.py` | |
|
||||||
|
| Documentation and release | [MIL-004] | 2026-10-08 | 2026-10-08 | S01 | | `README.md` following the project template | |
|
||||||
|
|
||||||
|
```plantuml
|
||||||
|
@startgantt
|
||||||
|
Project starts 2026-10-05
|
||||||
|
[Project scaffold] starts 2026-10-05 and ends 2026-10-05
|
||||||
|
[Project scaffold Go/No-Go] happens 2026-10-05
|
||||||
|
[Calculator core] starts 2026-10-06 and ends 2026-10-06
|
||||||
|
[Calculator core Go/No-Go] happens 2026-10-06
|
||||||
|
[Console interface] starts 2026-10-07 and ends 2026-10-07
|
||||||
|
[Console interface Go/No-Go] happens 2026-10-07
|
||||||
|
[Documentation and release] starts 2026-10-08 and ends 2026-10-08
|
||||||
|
[Documentation and release Go/No-Go] happens 2026-10-08
|
||||||
|
@endgantt
|
||||||
|
```
|
||||||
|
|
||||||
|
## Scope Coverage
|
||||||
|
|
||||||
|
| Scope item | Gateway |
|
||||||
|
| --- | --- |
|
||||||
|
| Project configuration, layout, `.gitignore`, Doxyfile, repository metadata | [MIL-001] |
|
||||||
|
| Operations stored in a dictionary of functions, constants, tests | [MIL-002] |
|
||||||
|
| Console interaction, ASCII art, continue with result, recursion | [MIL-003] |
|
||||||
|
| README, Doxygen build, setup verification, AGPL licence | [MIL-004] |
|
||||||
|
|
||||||
|
## Dependencies
|
||||||
|
|
||||||
|
```
|
||||||
|
MIL-001 -> MIL-002 -> MIL-003 -> MIL-004
|
||||||
|
```
|
||||||
|
|
||||||
|
A No-Go moves every later date by the time needed to fix the failed criterion.
|
||||||
|
|
||||||
|
## Plan Risks
|
||||||
|
|
||||||
|
| Risk | Impact | Mitigation |
|
||||||
|
| --- | --- | --- |
|
||||||
|
| Doxygen not installed on the machine | Docs check skipped | README names it as optional |
|
||||||
|
| Recursion depth on very long sessions | Crash after many restarts | Documented limit; sessions are short |
|
||||||
|
|
||||||
|
## Open Issues
|
||||||
|
|
||||||
|
- Milestone links in the Gateway Schedule are filled in after `sync-project.sh --apply`.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
[MIL-001]: ./milestones/mil-001-project-scaffold.md
|
||||||
|
[MIL-002]: ./milestones/mil-002-calculator-core.md
|
||||||
|
[MIL-003]: ./milestones/mil-003-console-interface.md
|
||||||
|
[MIL-004]: ./milestones/mil-004-documentation-and-release.md
|
||||||
|
[SA-001]: ./stakeholder-analysis.md
|
||||||
|
[BC-001]: ./business-case.md
|
||||||
|
[8ccefff]: https://git.tirsystem.com/Tirsvad-Udemy-100_days_of_code/010-calc/commit/8ccefffef7ec1f9ecbf548085a5c92fae75e1341
|
||||||
@@ -0,0 +1,64 @@
|
|||||||
|
# Stakeholder Analysis
|
||||||
|
|
||||||
|
## Metadata
|
||||||
|
| Key | Value |
|
||||||
|
| --- | --- |
|
||||||
|
| ID | SA-001 |
|
||||||
|
| CrossReference | [BC-001] |
|
||||||
|
|
||||||
|
## Version History
|
||||||
|
| Date | Status | Author | Reviewer | Change | Commit |
|
||||||
|
| --- | --- | --- | --- | --- | --- |
|
||||||
|
| 2026-10-04 | Accepted | Jens Tirsvad Nielsen | S01 | Initial version | [8ccefff] |
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## Purpose
|
||||||
|
|
||||||
|
Name the one stakeholder of this very small project, so that owners and reviewers in the other documents can cite a stakeholder ID. The project is a single-person course assignment with a short Business Case ([BC-001]).
|
||||||
|
|
||||||
|
## Stakeholder Summary Table
|
||||||
|
|
||||||
|
| ID | Name | Role/Title | Organization | Power Level | Interest Level | Quadrant | Primary Concern (Business Language) |
|
||||||
|
| --- | --- | --- | --- | --- | --- | --- | --- |
|
||||||
|
| S01 | Jens Tirsvad Nielsen | Product Owner | Tirsvad | HIGH | HIGH | Manage Closely | A working, tested, documented console calculator that matches the lecture |
|
||||||
|
|
||||||
|
## Power/Interest Classification Rationale
|
||||||
|
|
||||||
|
S01 decides scope, does the work and accepts every milestone, so S01 is managed closely.
|
||||||
|
|
||||||
|
## Primary Concerns and FURPS+ Mapping
|
||||||
|
|
||||||
|
| ID | Concern | FURPS+ attribute |
|
||||||
|
| --- | --- | --- |
|
||||||
|
| S01 | Operations stored in a dictionary, continue with result, restart by recursion | Functionality |
|
||||||
|
| S01 | Simple setup with a local venv and no runtime dependencies | Supportability |
|
||||||
|
|
||||||
|
## Communication Requirements
|
||||||
|
|
||||||
|
| ID | Channel | Frequency | Deliverable | Phase / Milestone |
|
||||||
|
| --- | --- | --- | --- | --- |
|
||||||
|
| S01 | Chat | Per milestone | Working-tree changes and summary | MIL-001 to MIL-004 |
|
||||||
|
|
||||||
|
## Conflicting Interests and Mitigations
|
||||||
|
|
||||||
|
| Conflict | Stakeholders | Mitigation |
|
||||||
|
| --- | --- | --- |
|
||||||
|
| None, there is one stakeholder | S01 | Not applicable |
|
||||||
|
|
||||||
|
## Traceability Analysis
|
||||||
|
|
||||||
|
### Business Goal Alignment
|
||||||
|
|
||||||
|
| Stakeholder | Concern | Business Case objective |
|
||||||
|
| --- | --- | --- |
|
||||||
|
| S01 | Finish the day 10 assignment | Objectives 1 to 4 in [BC-001] |
|
||||||
|
|
||||||
|
## Sign-Off
|
||||||
|
|
||||||
|
Accepted by S01.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
[BC-001]: ./business-case.md
|
||||||
|
[8ccefff]: https://git.tirsystem.com/Tirsvad-Udemy-100_days_of_code/010-calc/commit/8ccefffef7ec1f9ecbf548085a5c92fae75e1341
|
||||||
Submodule
+1
Submodule framework added at 14d221ec1c
Reference in New Issue
Block a user