This guide explains how to extend and integrate new educational features (tutorials, assessments, curriculum integration, community tools) into the FLL-Sim platform. All development should use the fll-sim-env virtual environment for consistency and reproducibility.
- Modularity: Educational features are implemented as independent, reusable modules in
src/fll_sim/education/. - Extensible APIs: Each module exposes clear interfaces for integration and extension.
- Separation of Concerns: UI, logic, and data management are separated for maintainability.
- Testing: All new features require automated unit tests in
tests/and must be run usingfll-sim-env/bin/python.
- Create a new Python file in
src/fll_sim/education/ - Define a base class or API for your feature
- Implement core logic and public methods with docstrings and type hints
- Add unit tests in
tests/test_education_modules.py - Document your module in this guide and update API docs
# src/fll_sim/education/my_tutorial.py
class MyTutorial:
"""Custom tutorial module for FLL-Sim."""
def __init__(self, steps: list[str]):
self.steps = steps
def run(self):
for step in self.steps:
print(step)- Add tests to
tests/test_education_modules.py:
import unittest
from fll_sim.education.my_tutorial import MyTutorial
class TestMyTutorial(unittest.TestCase):
def test_run(self):
tutorial = MyTutorial(["Step 1", "Step 2"])
tutorial.run()- Run tests with:
fll-sim-env/bin/python -m unittest tests/test_education_modules.py
- Use type hints and docstrings for all public classes and methods
- Follow PEP8 and project style guides
- Keep modules small and focused
- Update documentation and API references
- Log changes in
/data/logs/change_log.txt
- Inherit from base classes in
src/fll_sim/education/ - Register new modules in the main application as needed
- Add integration tests for complex features
- See
/docs/api_education.mdfor detailed module APIs