Skip to content

Commit b987958

Browse files
committed
Add complete user-facing documentation and remove dev-focused content
- Add example documentation: - HTTP GraphQL examples with schema and queries - WebSocket subscriptions with client integration - Django Channels complete setup guide - Advanced patterns for production optimization - Add reference documentation: - Complete API reference for all functions - Comprehensive configuration guide - Troubleshooting guide for common issues - Update existing documentation: - Remove testing and deployment guides (dev-focused) - Update contributing.md to reference justfile and uv - Fix broken anchor links in examples index - Remove architecture reference from navigation All documentation now builds without warnings.
1 parent 1db31ff commit b987958

11 files changed

Lines changed: 3485 additions & 41 deletions

File tree

docs/about/contributing.md

Lines changed: 33 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -26,11 +26,11 @@ cd graphql-sqlcommenter
2626
Using uv (recommended):
2727

2828
```bash
29-
# Install dependencies
30-
uv pip install -e ".[dev,docs]"
29+
# Install dependencies (syncs from pyproject.toml)
30+
uv sync
3131

3232
# Run tests to verify setup
33-
pytest tests/
33+
uv run pytest tests/
3434
```
3535

3636
### 3. Create a Branch
@@ -43,46 +43,59 @@ git checkout -b fix/issue-description
4343

4444
## Development Workflow
4545

46+
We use [uv](https://docs.astral.sh/uv/) for fast Python package management and [just](https://just.systems/) for common development tasks. Install both via your package manager.
47+
48+
### List Available Commands
49+
50+
```bash
51+
# See all available commands
52+
just
53+
```
54+
4655
### Running Tests
4756

4857
```bash
49-
# Run all tests
58+
# Run all tests with coverage
59+
just test
60+
61+
# Or run pytest directly:
5062
pytest tests/ -v
5163

5264
# Run specific test file
5365
pytest tests/test_middleware.py -v
54-
55-
# Run with coverage
56-
pytest tests/ --cov=graphql_sqlcommenter --cov-report=html
57-
58-
# View coverage report
59-
open htmlcov/index.html
6066
```
6167

68+
Coverage reports are generated in `htmlcov/index.html`.
69+
6270
### Code Style
6371

64-
We follow PEP 8 and use type hints where appropriate.
72+
We follow PEP 8 and use Ruff for linting/formatting, with mypy for type checking.
6573

6674
```bash
67-
# Format code (if using black)
68-
black graphql_sqlcommenter/ tests/
75+
# Format code
76+
just format
77+
78+
# Check code (lint and type check)
79+
just lint
6980

70-
# Check types
71-
uv run mypy graphql_sqlcommenter
81+
# Or run tools directly:
82+
uv run ruff format graphql_sqlcommenter/ tests/
83+
uv run ruff check graphql_sqlcommenter/ tests/
84+
uv run mypy graphql_sqlcommenter/
7285
```
7386

7487
### Documentation
7588

7689
Build documentation locally:
7790

7891
```bash
79-
# Install docs dependencies
80-
uv pip install -e ".[docs]"
92+
# Serve docs locally (with live reload)
93+
just docs
8194

82-
# Serve docs locally
83-
mkdocs serve
95+
# Or run mkdocs directly:
96+
uv run mkdocs serve
8497

85-
# Open http://127.0.0.1:8000
98+
# Open http://127.0.0.1:8800 (just docs) or http://127.0.0.1:8000 (mkdocs serve)
8699
```
87100

88101
## Making Changes

docs/about/project-summary.md

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -24,9 +24,7 @@ graphql-sqlcommenter/
2424
│ │ └── configuration.md
2525
│ ├── guides/
2626
│ │ ├── implementation-guide.md
27-
│ │ ├── subscription-guide.md
28-
│ │ ├── testing.md
29-
│ │ └── deployment.md
27+
│ │ └── subscription-guide.md
3028
│ ├── examples/
3129
│ ├── reference/
3230
│ └── about/
@@ -301,8 +299,6 @@ SQLCOMMENTER_GRAPHQL_PATHS = ['/graphql'] # GraphQL endpoints
301299
### Guides
302300
- [Implementation Guide](../guides/implementation-guide.md) - Comprehensive setup
303301
- [Subscription Guide](../guides/subscription-guide.md) - WebSocket/Channels
304-
- [Testing Guide](../guides/testing.md) - Test strategies
305-
- [Deployment Guide](../guides/deployment.md) - Production rollout
306302

307303
### Examples
308304
- [HTTP GraphQL](../examples/http-graphql.md) - Standard examples
@@ -313,7 +309,6 @@ SQLCOMMENTER_GRAPHQL_PATHS = ['/graphql'] # GraphQL endpoints
313309
### Reference
314310
- [API Reference](../reference/api.md) - API documentation
315311
- [Configuration](../reference/configuration.md) - Settings reference
316-
- [Architecture](../reference/architecture.md) - Technical details
317312
- [Troubleshooting](../reference/troubleshooting.md) - Common issues
318313

319314
## Production Deployment
@@ -387,7 +382,7 @@ SQLCOMMENTER_WITH_GRAPHQL = os.getenv('ENABLE_GRAPHQL_COMMENTS', 'false') == 'tr
387382
### For Users
388383
1. [Install the package](../getting-started/installation.md)
389384
2. [Follow quick start](../getting-started/quickstart.md)
390-
3. [Deploy to staging](../guides/deployment.md)
385+
3. [Configure your application](../getting-started/configuration.md)
391386
4. [Monitor in PlanetScale](../guides/implementation-guide.md)
392387

393388
### For Contributors

0 commit comments

Comments
 (0)