Skip to content

Commit c789033

Browse files
committed
chore: added AGENTS.md
1 parent ec24b9d commit c789033

File tree

1 file changed

+17
-0
lines changed

1 file changed

+17
-0
lines changed

AGENTS.md

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
# DIRAC Agent Guidelines
2+
3+
## Build/Lint/Test Commands
4+
- **Build**: `pip install -e .`
5+
- **Lint**: `ruff check src/ && pylint src/`
6+
- **Test**: `pytest tests/`
7+
- **Single test**: `pytest src/DIRAC/path/to/test.py::test_function`
8+
9+
## Code Style Guidelines
10+
- **Formatting**: Use `black` with line length 120 (configured in pyproject.toml)
11+
- **Imports**: Absolute imports only; sort with `isort` (black profile)
12+
- **Naming**: CamelCase for classes, snake_case for functions/variables
13+
- **Types**: Use type hints; run `mypy` for strict checking
14+
- **Error handling**: Return `S_OK(result)` or `S_ERROR(message)` from DIRAC.Core.Utilities.ReturnValues
15+
- **Logging**: Use `gLogger.info/warn/error` (from DIRAC import gLogger)
16+
- **Docstrings**: Follow Google/NumPy style where present
17+
- **Security**: Never log secrets; validate inputs

0 commit comments

Comments
 (0)