Skip to content

Contributing

m1nd is open-source under the MIT License. Contributions are welcome!

Getting Started

1
Fork & clone
git clone https://github.com/YOUR_USER/projectmind_314lan.git
2
Create a branch
git checkout -b feature/your-feature-name
3
Set up the dev environment
Create a venv and install dependencies:
python3 -m venv .venv && source .venv/bin/activate && pip install -r requirements.txt
4
Make your changes
Follow the code style and conventions described below.
5
Test your changes
Run the Playwright E2E tests:
npx playwright test
6
Submit a pull request
Push your branch and open a PR against main. Describe what you changed and why.

Project Structure

projectmind_314lan/
├── app.py              # Main Flask application (6,172 lines — being split)
├── main.py             # Entry point
├── config.yaml         # Runtime configuration
├── requirements.txt    # Python dependencies
├── web/
│   ├── templates/      # Jinja2 HTML templates
│   └── static/
│       ├── js/         # Legacy JavaScript + Vue islands
│       ├── css/        # Stylesheets
│       └── img/        # Images and icons
├── vue-islands/        # Vue 3 SFC source (6 islands)
│   ├── brain/
│   ├── v1sion/
│   ├── monitors/
│   ├── settings/
│   ├── dashboard/
│   └── shared/
├── scripts/
│   └── install.sh      # One-line installer
├── tests/
│   └── e2e/            # Playwright E2E tests (120+)
└── data/               # SQLite database + SSL certs + backups

Code Style

Python

  • PEP 8 with 120 char line length
  • Use snake_case for functions and variables
  • Type hints encouraged but not enforced
  • Docstrings for public functions

JavaScript / Vue

  • Vue 3 Composition API (<script setup>)
  • camelCase for variables, PascalCase for components
  • Use const by default, let when reassignment is needed
  • Template refs over DOM queries

CSS

  • Use CSS custom properties (defined in styles.css)
  • Prefer var(--bg-1) over hardcoded colours
  • Avoid !important (we're trying to reduce the current 164 uses)

What to Contribute

High Priority

  • Backend unit tests — currently zero; auth, RBAC, and API endpoints need coverage
  • Accessibility — add aria-label to icon-only buttons, role="dialog" to modals
  • CSP nonces — replace unsafe-inline with nonce-based Content Security Policy

Medium Priority

  • Blueprint split — help break app.py into Flask Blueprints
  • Timer cleanup — fix 77 setInterval creates with only 14 clearInterval calls
  • New vendor SNMP profiles — add OID profiles for Arista, HPE, Dell, Huawei

Always Welcome

  • Bug reports with clear reproduction steps
  • Documentation improvements
  • Performance optimisations
  • UI/UX polish

Commit Messages

Use conventional commits:

feat: add SNMPv3 context engine ID support
fix: prevent duplicate monitor creation on double-click
docs: update API authentication examples
refactor: extract SNMP polling into separate module
test: add E2E tests for Brain CRUD operations

Reporting Issues

  1. Search existing issues first
  2. Include: m1nd version, OS, browser, and steps to reproduce
  3. Attach screenshots or console output if applicable
  4. Use labels: bug, enhancement, documentation, question

Released under the MIT License.