Skip to content

Add Copilot instructions to help navigate CodeCarbon repository#884

Merged
inimaz merged 6 commits into
masterfrom
copilot/fix-881
Jul 7, 2025
Merged

Add Copilot instructions to help navigate CodeCarbon repository#884
inimaz merged 6 commits into
masterfrom
copilot/fix-881

Conversation

Copilot AI commented Jul 2, 2025

Copy link
Copy Markdown
Contributor

This PR adds comprehensive GitHub Copilot instructions to help developers navigate the CodeCarbon repository more effectively.

What's Added

Created .github/copilot-instructions.md following VS Code Copilot customization guidelines that documents:

Repository Structure

  • 📦 codecarbon/ - Core Python package with emission tracking and CLI tools
  • 🔌 carbonserver/ - FastAPI backend with PostgreSQL database
  • 📊 dashboard/ - Python Dash-based interactive dashboard
  • 🌐 webapp/ - Next.js React web application

Development Workflows

# Core package testing
hatch run test:package

# API development
hatch run api:docker    # Start with Docker
hatch run api:local     # Or run locally

# Dashboard development  
hatch run dashboard:run  # Python dashboard
cd webapp && pnpm dev   # Next.js dashboard

Key Features

  • Component-specific setup and testing instructions
  • Hatch environment management guidance
  • Architecture overview with visual diagram
  • References to existing documentation (CONTRIBUTING.md, README.md, etc.)
  • VS Code debugging configuration tips
  • Development best practices and troubleshooting

Why This Helps

The CodeCarbon repository contains multiple interconnected components that can be confusing to navigate. These instructions will help Copilot:

  • Understand the multi-component architecture
  • Provide better code suggestions based on context
  • Guide developers to the right testing and setup commands
  • Reference appropriate documentation for each component

Fixes #881.

Warning

Firewall rules blocked me from connecting to one or more addresses

I tried to connect to the following addresses, but was blocked by firewall rules:

  • mlco2.github.io
    • Triggering command: curl -s -o /dev/null -w %{http_code} REDACTED (dns block)

If you need me to access, download, or install something from one of these locations, you can either:


💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.

Co-authored-by: benoit-cty <6603048+benoit-cty@users.noreply.github.com>
Copilot AI changed the title [WIP] Add instructions to Copilot Add Copilot instructions to help navigate CodeCarbon repository Jul 2, 2025
Copilot AI requested a review from benoit-cty July 2, 2025 12:12
@benoit-cty benoit-cty marked this pull request as ready for review July 2, 2025 15:41
@benoit-cty benoit-cty requested a review from inimaz July 6, 2025 13:19
@inimaz

inimaz commented Jul 7, 2025

Copy link
Copy Markdown
Collaborator

@copilot now we are using uv instead of hatch. Please update accordingly this PR

Co-authored-by: inimaz <49730431+inimaz@users.noreply.github.com>

Copilot AI commented Jul 7, 2025

Copy link
Copy Markdown
Contributor Author

@copilot now we are using uv instead of hatch. Please update accordingly this PR

Updated the Copilot instructions to use uv instead of hatch following the repository migration. All development commands have been updated to use uv run task <task-name> format. Commit d7ddb3f

Copilot finished work on behalf of inimaz July 7, 2025 08:59
@inimaz inimaz requested a review from benoit-cty July 7, 2025 09:09

@inimaz inimaz left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice thanks @benoit-cty and @copilot :D

@inimaz inimaz merged commit a4c3adb into master Jul 7, 2025
5 checks passed
@inimaz inimaz deleted the copilot/fix-881 branch July 7, 2025 12:02
@benoit-cty benoit-cty mentioned this pull request Jul 11, 2025
6 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add instructions to Copilot

3 participants