Skip to content

Developer Experience Improvements #170

@manavgup

Description

@manavgup

Overview

Enhance the local development experience to boost productivity and reduce friction for developers working on RAG Modulo.

Motivation

Developer productivity directly impacts project velocity. Reducing context switches, wait times, and manual processes will improve code quality and developer satisfaction.

Proposed Implementation

1. Hot Reload for Backend

  • Configure FastAPI with watchdog for auto-reload
  • Set up proper file watching for Python changes
  • Optimize reload speed with smart caching
  • Add reload notifications to console

2. Dev Container Setup

  • Create .devcontainer configuration
  • Pre-install all development tools
  • Configure VS Code extensions
  • Add debugging configurations
  • Include database GUI tools

3. Improved Make Targets

  • make feature-branch name=<name> - Create and setup feature branch
  • make hotfix - Quick hotfix workflow
  • make release version=<version> - Automated release process
  • make clean-all - Complete cleanup including Docker volumes
  • make dev-reset - Reset to clean development state
  • make test-watch - Run tests on file changes

Technical Details

FastAPI Hot Reload Configuration

# docker-compose.override.yml for development
services:
  backend:
    command: uvicorn main:app --reload --host 0.0.0.0 --port 8000
    volumes:
      - ./backend:/app
    environment:
      - WATCHDOG_ENABLED=true

Dev Container Features

{
  "name": "RAG Modulo Dev",
  "dockerComposeFile": "docker-compose.yml",
  "service": "backend",
  "extensions": [
    "ms-python.python",
    "ms-python.vscode-pylance",
    "charliermarsh.ruff",
    "ms-azuretools.vscode-docker"
  ],
  "settings": {
    "python.linting.enabled": true,
    "python.formatting.provider": "black"
  }
}

Enhanced Makefile Workflows

# Smart feature branch creation
feature-branch:
	@git checkout -b feature/$(name)
	@git push -u origin feature/$(name)
	@echo "Feature branch created and pushed"
	@make install-deps
	@make run-services

# Development environment reset
dev-reset:
	@make stop-containers
	@docker volume prune -f
	@make clean
	@make install-deps
	@make migrate
	@make seed-data
	@echo "Development environment reset complete"

Success Criteria

  • Backend changes reflect immediately without manual restart
  • New developers can be productive in < 30 minutes
  • Common workflows automated with Make targets
  • Dev container works on Mac, Linux, and Windows
  • Debugging works out-of-the-box

Dependencies

Estimated Effort

  • Low to medium complexity
  • ~2-3 days implementation
  • High value for ongoing development

Related Issues

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or requestpriority:mediumMedium priority - nice to have

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions