Development Workflow Guide¶
Complete development workflow from issue creation through production deployment. Follow these processes to ensure smooth collaboration and code quality.
Related documentation:
- CI/CD Pipeline - Pipeline architecture
- CI/CD Workflows - GitHub Actions details
- Release Management - Release process
- Code Standards - Coding guidelines
Branch Strategy¶
We use a three-tier promotion model with automatic deployments:
main (pre-prod) ← stage (staging) ← dev (development) ← feature/*
Each branch maps to an environment:
| Branch | Environment | URL |
|---|---|---|
dev | Development | https://co2-calculator-dev.epfl.ch |
stage | Staging | https://co2-calculator-stage.epfl.ch |
main | Pre-Production | https://co2-calculator.epfl.ch |
Feature branches are created from dev and merged back to dev.
For deployment triggers and validation requirements, see CI/CD Pipeline.
Development Process¶
Follow this step-by-step workflow for all changes:
- Create issue - Describe feature or bug with acceptance criteria
- Branch from dev -
git checkout dev && git checkout -b issue-123-feature - Develop locally - Code, test, document
- Run CI checks -
make cimust pass before pushing - Push and PR - Create pull request targeting
dev - Code review - Address feedback within 1-2 days
- Merge to dev - Auto-deploys to development environment
- Validate - Test in dev environment
- Promote to stage - Manual PR at sprint end
- Production release - Tag and deploy to pre-prod
For CI/CD pipeline details, see CI/CD Pipeline.
Pull Request Lifecycle¶
Creating Pull Requests¶
For feature/fix → dev:
- PR created by developer
- Review by another IT4R developer
- Final approval by product owner
- Automatic deployment on merge
For dev → stage:
- PR created by lead developer
- Review and merge by product owner
- Manual deployment at sprint end
Review Timeline¶
| Activity | Expected Time |
|---|---|
| Code Review | 1-2 business days |
| Staging Release | End of sprint |
| Production Release | As needed (TBD) |
Review Criteria¶
Reviewers verify these aspects before approval:
- Code Quality - Follows standards, linter passes
- Documentation - Clear comments and updated docs
- Testing - 60% coverage minimum, tests pass
- Security - No secrets, follows security policy
- Performance - No obvious bottlenecks
- Accessibility - WCAG AA for UI changes
- Responsiveness - Works on mobile/tablet/desktop
For UI changes, include screenshots and test on multiple devices.
For detailed CI/CD checks, see CI/CD Pipeline.
Definition of Done¶
A feature is complete when:
- ✅ Code implemented with all planned functionality
- 📘 Documentation updated (code comments, README, guides)
- 🧪 Code reviewed and tests passing
- 🧩 Acceptance criteria met (validated by PM)
- 🧼 No critical bugs in staging environment
- 🚀 Deployed to production
Definition of Ready¶
Issues are ready for development when:
Functional Specs (by PM/Stakeholder)¶
- 🎯 Feature purpose and business value clear
- 🧩 Solution approach validated
- 🎨 Design mockups approved (if UI work)
- 💾 Sample data available
- ✅ Acceptance criteria defined with test strategy
Technical Specs (by Developer)¶
- ⚙️ Implementation approach documented
- 🔗 Dependencies identified and managed
- ⏱️ Time estimate provided
- 🤝 Scheduled at sprint planning
Issue Management¶
Issue Labels¶
Use these labels to categorize and prioritize work:
Type:
bug- Something brokenfeature- New functionalitydocs- Documentation workrefactor- Code improvementsecurity- Security issue
Priority:
priority: critical- Production blockerpriority: high- Important, schedule soonpriority: medium- Normal (default)priority: low- Nice to have
Status:
in-review- Under reviewin-code-review- PR submittedpending-spec- Needs clarificationwish- Future consideration
Issue Lifecycle¶
Issues progress through these states:
- Open - Created with template
- Triaged - Labeled and prioritized
- Ready - Meets Definition of Ready
- In Progress - Developer actively working
- Review - PR created, awaiting review
- Merged - PR merged to
dev - Validated - Tested in dev environment
- Closed - Resolved and deployed
Issue Templates¶
Use appropriate templates when creating issues:
Project Management¶
All development work flows through GitHub:
- Planning - GitHub Projects for sprint boards
- Tracking - Issues for all tasks
- Documentation - Each delivery includes guides for autonomy
- Communication - GitHub Discussions for questions
Sprint cycle:
- Sprint length: 2 weeks
- Planning: Start of sprint
- Review: End of sprint
- Retrospective: End of sprint
Common Scenarios¶
Adding a New Feature¶
- Create feature request issue with acceptance criteria
- Wait for triage and Definition of Ready
- Branch from
dev:git checkout -b issue-456-new-feature - Implement with tests and docs
- Run
make cilocally - Push and create PR to
dev - Address review feedback
- Merge and validate in dev environment
Fixing a Bug¶
- Create bug report with reproduction steps
- Branch from
dev:git checkout -b issue-789-fix-bug - Add test that reproduces bug
- Fix issue and verify test passes
- Run
make cilocally - Push and create PR to
dev - Reference issue in PR description
Updating Documentation¶
- Create docs issue describing update needed
- Branch from
dev:git checkout -b issue-101-update-docs - Update documentation files
- Preview changes locally
- Push and create PR to
dev - Merge after review
For urgent documentation fixes, smaller PRs are acceptable.