Skip to content

Refactor: Unify duplicate project registries into a shared projects database #979

@nishtha-agarwal-211

Description

@nishtha-agarwal-211

Description

The project list registry is currently hardcoded and duplicated across multiple files:

  1. search_projects.py (under the PROJECTS array).
  2. utilities/Progress-Tracker/Progress-Tracker.py (under the ALL_PROJECTS dictionary).
  3. The Web App tracker system.

This duplication leads to inconsistencies when new projects are added.

Proposed Solution

  1. Create a central projects_registry.json database at the root of the project.
  2. The JSON should store schema information for each project:
    [
      {
        "name": "Rock Paper Scissors",
        "emoji": "🪨",
        "category": "games",
        "difficulty": "beginner",
        "description": "Battle against the computer...",
        "keywords": ["rock", "paper", "scissors"],
        "path": "games/Rock-Paper-Scissor/Rock-Paper-Scissor.py"
      }
    ]
  3. Refactor search_projects.py to read dynamically from this file using the json module.
  4. Refactor Progress-Tracker.py to populate its category lists dynamically using this file.

Metadata

Metadata

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions