feat: Complete backend and docs rebrand from Patherly to ResolutionFlow
Update APP_NAME, OpenAPI metadata, log messages, root endpoint response, model docstrings, seed script comments, README heading, and CLAUDE.md branding references. Frontend rebrand was completed in PR #26; this covers everything else. Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
@@ -22,7 +22,7 @@ The project was rebranded from "Patherly" to "ResolutionFlow" in the frontend (P
|
||||
| Context | Name Used |
|
||||
|---------|-----------|
|
||||
| Repository / directory name | `patherly` |
|
||||
| Backend (FastAPI, env vars, APP_NAME) | Patherly |
|
||||
| Backend (FastAPI, env vars, APP_NAME) | ResolutionFlow |
|
||||
| Database / Docker container | `patherly` / `patherly_postgres` |
|
||||
| Production URLs | `app.patherly.com` / `api.patherly.com` |
|
||||
| **Frontend UI (header, login, register)** | **ResolutionFlow** |
|
||||
@@ -233,7 +233,7 @@ patherly/
|
||||
**Required in `backend/.env`:**
|
||||
```bash
|
||||
# Application
|
||||
APP_NAME=Patherly
|
||||
APP_NAME=ResolutionFlow
|
||||
DEBUG=true # Set false in production
|
||||
|
||||
# Database (matches docker-compose.yml)
|
||||
|
||||
@@ -5,7 +5,7 @@ from typing import Optional
|
||||
|
||||
class Settings(BaseSettings):
|
||||
# Application
|
||||
APP_NAME: str = "Patherly"
|
||||
APP_NAME: str = "ResolutionFlow"
|
||||
DEBUG: bool = False
|
||||
API_V1_PREFIX: str = "/api/v1"
|
||||
|
||||
|
||||
@@ -18,19 +18,19 @@ logger = logging.getLogger(__name__)
|
||||
async def lifespan(app: FastAPI):
|
||||
"""Application lifespan handler."""
|
||||
# Startup
|
||||
logger.info("Starting Patherly API server...")
|
||||
logger.info("Starting ResolutionFlow API server...")
|
||||
logger.info(f"Environment: {'Development' if settings.DEBUG else 'Production'}")
|
||||
logger.info(f"ALLOW_RAILWAY_ORIGINS: {settings.ALLOW_RAILWAY_ORIGINS}")
|
||||
# Note: In production, use Alembic migrations instead of init_db
|
||||
# await init_db()
|
||||
yield
|
||||
# Shutdown
|
||||
logger.info("Shutting down Patherly API server...")
|
||||
logger.info("Shutting down ResolutionFlow API server...")
|
||||
|
||||
|
||||
app = FastAPI(
|
||||
title=settings.APP_NAME,
|
||||
description="Patherly - Take the path MOST traveled. Guided troubleshooting with automatic documentation.",
|
||||
description="ResolutionFlow - Take the path MOST traveled. Guided troubleshooting with automatic documentation.",
|
||||
version="1.0.0",
|
||||
docs_url="/api/docs",
|
||||
redoc_url="/api/redoc",
|
||||
@@ -44,7 +44,7 @@ app.add_middleware(RequestLoggingMiddleware)
|
||||
|
||||
# Configure CORS
|
||||
# Note: When ALLOW_RAILWAY_ORIGINS is True, we use allow_origin_regex for Railway domains
|
||||
# PLUS the explicit allowed_origins list (for custom domains like app.patherly.com)
|
||||
# PLUS the explicit allowed_origins list (for custom domains like app.resolutionflow.com)
|
||||
if settings.ALLOW_RAILWAY_ORIGINS:
|
||||
app.add_middleware(
|
||||
CORSMiddleware,
|
||||
@@ -71,7 +71,7 @@ app.include_router(api_router, prefix=settings.API_V1_PREFIX)
|
||||
async def root():
|
||||
"""Root endpoint."""
|
||||
return {
|
||||
"message": "Patherly API",
|
||||
"message": "ResolutionFlow API",
|
||||
"docs": "/api/docs",
|
||||
"version": "1.0.0"
|
||||
}
|
||||
|
||||
@@ -16,7 +16,7 @@ class TreeCategory(Base):
|
||||
"""Admin-managed categories for organizing trees.
|
||||
|
||||
Categories can be:
|
||||
- Global (team_id=NULL): Created by Patherly admins, visible to all
|
||||
- Global (team_id=NULL): Created by ResolutionFlow admins, visible to all
|
||||
- Team-specific (team_id set): Created by team admins, visible to team members
|
||||
"""
|
||||
__tablename__ = "tree_categories"
|
||||
|
||||
@@ -15,7 +15,7 @@ class StepCategory(Base):
|
||||
"""Admin-managed categories for organizing step library entries.
|
||||
|
||||
Categories can be:
|
||||
- Global (team_id=NULL): Created by Patherly admins, visible to all
|
||||
- Global (team_id=NULL): Created by ResolutionFlow admins, visible to all
|
||||
- Team-specific (team_id set): Created by team admins, visible to team members
|
||||
"""
|
||||
__tablename__ = "step_categories"
|
||||
|
||||
@@ -50,7 +50,7 @@ class User(Base):
|
||||
|
||||
@property
|
||||
def is_admin(self) -> bool:
|
||||
"""Returns True if user is a global (Patherly) admin."""
|
||||
"""Returns True if user is a global (ResolutionFlow) admin."""
|
||||
return self.role == "admin"
|
||||
|
||||
@property
|
||||
|
||||
@@ -1 +1 @@
|
||||
# Patherly scripts package
|
||||
# ResolutionFlow scripts package
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
#!/usr/bin/env python3
|
||||
"""
|
||||
Seed data script for Patherly decision trees.
|
||||
Seed data script for ResolutionFlow decision trees.
|
||||
|
||||
This script creates example troubleshooting trees in the database.
|
||||
Run from the backend directory with: python -m scripts.seed_data
|
||||
@@ -406,7 +406,7 @@ async def create_tree(client: httpx.AsyncClient, token: str, tree_data: dict) ->
|
||||
|
||||
async def seed_database():
|
||||
"""Main seeding function."""
|
||||
print("\n[*] Patherly Database Seeder")
|
||||
print("\n[*] ResolutionFlow Database Seeder")
|
||||
print("=" * 50)
|
||||
|
||||
async with httpx.AsyncClient(timeout=30.0) as client:
|
||||
@@ -458,7 +458,7 @@ async def seed_database():
|
||||
|
||||
|
||||
def main():
|
||||
parser = argparse.ArgumentParser(description="Seed the Patherly database with example trees")
|
||||
parser = argparse.ArgumentParser(description="Seed the ResolutionFlow database with example trees")
|
||||
parser.add_argument("--direct", action="store_true", help="Insert directly to database (not implemented)")
|
||||
args = parser.parse_args()
|
||||
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
"""
|
||||
Comprehensive MSP/SMB Troubleshooting Decision Trees Seed Script.
|
||||
|
||||
This script populates Patherly with realistic troubleshooting decision trees
|
||||
This script populates ResolutionFlow with realistic troubleshooting decision trees
|
||||
covering common Tier 1, Tier 2, and Tier 3 support scenarios.
|
||||
|
||||
Run from the backend directory with: python -m scripts.seed_trees
|
||||
@@ -3434,7 +3434,7 @@ async def seed_database():
|
||||
|
||||
def main():
|
||||
parser = argparse.ArgumentParser(
|
||||
description="Seed the Patherly database with MSP/SMB troubleshooting trees"
|
||||
description="Seed the ResolutionFlow database with MSP/SMB troubleshooting trees"
|
||||
)
|
||||
parser.add_argument(
|
||||
"--api-url",
|
||||
|
||||
346
docs/plans/2026-02-04-complete-rebrand.md
Normal file
346
docs/plans/2026-02-04-complete-rebrand.md
Normal file
@@ -0,0 +1,346 @@
|
||||
# Complete Rebrand: Patherly → ResolutionFlow
|
||||
|
||||
> **For Claude:** REQUIRED SUB-SKILL: Use superpowers:executing-plans to implement this plan task-by-task.
|
||||
|
||||
**Goal:** Replace every remaining "Patherly" reference in the codebase with "ResolutionFlow" so the brand is consistent across frontend, backend, docs, and comments.
|
||||
|
||||
**Architecture:** The frontend rebrand is already complete (PR #26). This plan covers the backend (config, API metadata, log messages, model docstrings, seed scripts), the root README, and CLAUDE.md. No database schema changes — the database name `patherly` and Docker container `patherly_postgres` stay as-is (infrastructure identifiers, not user-facing brand).
|
||||
|
||||
**Tech Stack:** Python/FastAPI backend, Markdown docs
|
||||
|
||||
---
|
||||
|
||||
## Scope Summary
|
||||
|
||||
| Area | Files | Type of Change |
|
||||
|------|-------|---------------|
|
||||
| Backend config | `config.py` | APP_NAME value |
|
||||
| Backend API | `main.py` | OpenAPI metadata, log messages, root endpoint |
|
||||
| Backend models | `user.py`, `category.py`, `step_category.py` | Docstring/comment text |
|
||||
| Seed scripts | `seed_data.py`, `seed_trees.py` | Comments and print output |
|
||||
| Root docs | `README.md` | Full rewrite of heading and tagline |
|
||||
| Project context | `CLAUDE.md` | Update branding table and env var example |
|
||||
|
||||
**NOT changed** (infrastructure identifiers):
|
||||
- Database name `patherly`, Docker container `patherly_postgres`
|
||||
- Repository directory name `patherly/`
|
||||
- Production URLs `app.patherly.com` / `api.patherly.com`
|
||||
- Railway service name `patherly`
|
||||
- File paths like `C:\Dev\Projects\patherly`
|
||||
|
||||
---
|
||||
|
||||
### Task 1: Backend Config — APP_NAME
|
||||
|
||||
**Files:**
|
||||
- Modify: `backend/app/core/config.py:8`
|
||||
|
||||
**Step 1: Update APP_NAME**
|
||||
|
||||
Change line 8 from:
|
||||
```python
|
||||
APP_NAME: str = "Patherly"
|
||||
```
|
||||
to:
|
||||
```python
|
||||
APP_NAME: str = "ResolutionFlow"
|
||||
```
|
||||
|
||||
**Step 2: Verify no other references in config.py**
|
||||
|
||||
Search `config.py` for "Patherly" — should return 0 matches after the edit.
|
||||
|
||||
---
|
||||
|
||||
### Task 2: Backend API — main.py
|
||||
|
||||
**Files:**
|
||||
- Modify: `backend/app/main.py:21,28,33,47,74`
|
||||
|
||||
**Step 1: Update startup log (line 21)**
|
||||
|
||||
```python
|
||||
# FROM:
|
||||
logger.info("Starting Patherly API server...")
|
||||
# TO:
|
||||
logger.info("Starting ResolutionFlow API server...")
|
||||
```
|
||||
|
||||
**Step 2: Update shutdown log (line 28)**
|
||||
|
||||
```python
|
||||
# FROM:
|
||||
logger.info("Shutting down Patherly API server...")
|
||||
# TO:
|
||||
logger.info("Shutting down ResolutionFlow API server...")
|
||||
```
|
||||
|
||||
**Step 3: Update OpenAPI description (line 33)**
|
||||
|
||||
```python
|
||||
# FROM:
|
||||
description="Patherly - Take the path MOST traveled. Guided troubleshooting with automatic documentation.",
|
||||
# TO:
|
||||
description="ResolutionFlow - Take the path MOST traveled. Guided troubleshooting with automatic documentation.",
|
||||
```
|
||||
|
||||
**Step 4: Update CORS comment (line 47)**
|
||||
|
||||
```python
|
||||
# FROM:
|
||||
# PLUS the explicit allowed_origins list (for custom domains like app.patherly.com)
|
||||
# TO:
|
||||
# PLUS the explicit allowed_origins list (for custom domains like app.resolutionflow.com)
|
||||
```
|
||||
|
||||
Note: The actual CORS origin values in `config.py` are correct as-is (they use the real domain). This is just a comment.
|
||||
|
||||
**Step 5: Update root endpoint response (line 74)**
|
||||
|
||||
```python
|
||||
# FROM:
|
||||
"message": "Patherly API",
|
||||
# TO:
|
||||
"message": "ResolutionFlow API",
|
||||
```
|
||||
|
||||
**Step 6: Run backend tests**
|
||||
|
||||
Run: `cd backend && python -m pytest -x -q`
|
||||
Expected: All tests pass (no test references "Patherly" in assertions)
|
||||
|
||||
**Step 7: Commit**
|
||||
|
||||
```bash
|
||||
git add backend/app/core/config.py backend/app/main.py
|
||||
git commit -m "feat: Rebrand backend config and API metadata to ResolutionFlow"
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
### Task 3: Backend Model Docstrings
|
||||
|
||||
**Files:**
|
||||
- Modify: `backend/app/models/user.py:53`
|
||||
- Modify: `backend/app/models/category.py:19`
|
||||
- Modify: `backend/app/models/step_category.py:18`
|
||||
|
||||
**Step 1: Update user.py docstring (line 53)**
|
||||
|
||||
```python
|
||||
# FROM:
|
||||
"""Returns True if user is a global (Patherly) admin."""
|
||||
# TO:
|
||||
"""Returns True if user is a global (ResolutionFlow) admin."""
|
||||
```
|
||||
|
||||
**Step 2: Update category.py docstring (line 19)**
|
||||
|
||||
```python
|
||||
# FROM:
|
||||
- Global (team_id=NULL): Created by Patherly admins, visible to all
|
||||
# TO:
|
||||
- Global (team_id=NULL): Created by ResolutionFlow admins, visible to all
|
||||
```
|
||||
|
||||
**Step 3: Update step_category.py docstring (line 18)**
|
||||
|
||||
```python
|
||||
# FROM:
|
||||
- Global (team_id=NULL): Created by Patherly admins, visible to all
|
||||
# TO:
|
||||
- Global (team_id=NULL): Created by ResolutionFlow admins, visible to all
|
||||
```
|
||||
|
||||
**Step 4: Commit**
|
||||
|
||||
```bash
|
||||
git add backend/app/models/user.py backend/app/models/category.py backend/app/models/step_category.py
|
||||
git commit -m "docs: Update backend model docstrings from Patherly to ResolutionFlow"
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
### Task 4: Seed Scripts
|
||||
|
||||
**Files:**
|
||||
- Modify: `backend/scripts/seed_data.py:3,409,461`
|
||||
- Modify: `backend/scripts/seed_trees.py:5,3437`
|
||||
|
||||
**Step 1: Update seed_data.py docstring (line 3)**
|
||||
|
||||
```python
|
||||
# FROM:
|
||||
Seed data script for Patherly decision trees.
|
||||
# TO:
|
||||
Seed data script for ResolutionFlow decision trees.
|
||||
```
|
||||
|
||||
**Step 2: Update seed_data.py print output (line 409)**
|
||||
|
||||
```python
|
||||
# FROM:
|
||||
print("\n[*] Patherly Database Seeder")
|
||||
# TO:
|
||||
print("\n[*] ResolutionFlow Database Seeder")
|
||||
```
|
||||
|
||||
**Step 3: Update seed_data.py argparse description (line 461)**
|
||||
|
||||
```python
|
||||
# FROM:
|
||||
parser = argparse.ArgumentParser(description="Seed the Patherly database with example trees")
|
||||
# TO:
|
||||
parser = argparse.ArgumentParser(description="Seed the ResolutionFlow database with example trees")
|
||||
```
|
||||
|
||||
**Step 4: Update seed_trees.py docstring (line 5)**
|
||||
|
||||
```python
|
||||
# FROM:
|
||||
This script populates Patherly with realistic troubleshooting decision trees
|
||||
# TO:
|
||||
This script populates ResolutionFlow with realistic troubleshooting decision trees
|
||||
```
|
||||
|
||||
**Step 5: Update seed_trees.py argparse description (line 3437)**
|
||||
|
||||
```python
|
||||
# FROM:
|
||||
description="Seed the Patherly database with MSP/SMB troubleshooting trees"
|
||||
# TO:
|
||||
description="Seed the ResolutionFlow database with MSP/SMB troubleshooting trees"
|
||||
```
|
||||
|
||||
**Step 6: Commit**
|
||||
|
||||
```bash
|
||||
git add backend/scripts/seed_data.py backend/scripts/seed_trees.py
|
||||
git commit -m "docs: Update seed script references from Patherly to ResolutionFlow"
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
### Task 5: README.md
|
||||
|
||||
**Files:**
|
||||
- Modify: `README.md` (full update)
|
||||
|
||||
**Step 1: Update README heading and tagline (lines 1-2)**
|
||||
|
||||
```markdown
|
||||
# FROM:
|
||||
# Patherly
|
||||
|
||||
> Take the path MOST traveled.
|
||||
|
||||
# TO:
|
||||
# ResolutionFlow
|
||||
|
||||
> Take the path MOST traveled.
|
||||
```
|
||||
|
||||
**Step 2: Search the rest of README for "Patherly"**
|
||||
|
||||
The README is a legacy planning doc from early in the project. It doesn't reference "Patherly" elsewhere in the body text. Only the heading needs updating.
|
||||
|
||||
**Step 3: Commit**
|
||||
|
||||
```bash
|
||||
git add README.md
|
||||
git commit -m "docs: Update README heading from Patherly to ResolutionFlow"
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
### Task 6: CLAUDE.md — Branding Table and Env Var
|
||||
|
||||
**Files:**
|
||||
- Modify: `CLAUDE.md:25,236`
|
||||
|
||||
**Step 1: Update branding table (line 25)**
|
||||
|
||||
The branding table row for Backend APP_NAME should now reflect the change:
|
||||
|
||||
```markdown
|
||||
# FROM:
|
||||
| Backend (FastAPI, env vars, APP_NAME) | Patherly |
|
||||
# TO:
|
||||
| Backend (FastAPI, env vars, APP_NAME) | ResolutionFlow |
|
||||
```
|
||||
|
||||
**Step 2: Update env var example (line 236)**
|
||||
|
||||
```bash
|
||||
# FROM:
|
||||
APP_NAME=Patherly
|
||||
# TO:
|
||||
APP_NAME=ResolutionFlow
|
||||
```
|
||||
|
||||
**Step 3: Update CORS comment references (lines 471, 476)**
|
||||
|
||||
These reference `app.patherly.com` which is the current production URL. Keep as-is — they're accurate infrastructure references, not brand names.
|
||||
|
||||
**Step 4: Commit**
|
||||
|
||||
```bash
|
||||
git add CLAUDE.md
|
||||
git commit -m "docs: Update CLAUDE.md to reflect backend rebrand to ResolutionFlow"
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
### Task 7: Final Verification
|
||||
|
||||
**Step 1: Search entire codebase for remaining "Patherly" references**
|
||||
|
||||
Run: `grep -r "Patherly" --include="*.py" --include="*.ts" --include="*.tsx" --include="*.md" --include="*.html" --include="*.css" --include="*.json" .`
|
||||
|
||||
**Expected remaining matches (all legitimate):**
|
||||
- `CLAUDE.md` — only in the branding table context rows (repo name, database, URLs) and historical rebrand description
|
||||
- `REBRAND-IMPLEMENTATION-GUIDE.md` — historical guide documenting the rebrand process
|
||||
- `docs/plans/2026-02-04-complete-rebrand.md` — this plan file itself
|
||||
|
||||
**No matches should appear in:**
|
||||
- `backend/app/**/*.py`
|
||||
- `frontend/src/**/*`
|
||||
- `README.md`
|
||||
|
||||
**Step 2: Run frontend build**
|
||||
|
||||
Run: `cd frontend && npm run build`
|
||||
Expected: Build succeeds with no errors
|
||||
|
||||
**Step 3: Run backend tests**
|
||||
|
||||
Run: `cd backend && python -m pytest -x -q`
|
||||
Expected: All tests pass
|
||||
|
||||
**Step 4: Push**
|
||||
|
||||
```bash
|
||||
git push origin main
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
## Risk Assessment
|
||||
|
||||
**Risk: Backend tests break after APP_NAME change**
|
||||
- Likelihood: Low — no tests assert on APP_NAME or the root endpoint message
|
||||
- Mitigation: Run `pytest` after Task 2
|
||||
|
||||
**Risk: Production deployment affected**
|
||||
- Likelihood: None — APP_NAME only affects OpenAPI metadata and log messages
|
||||
- Mitigation: Railway auto-deploys on merge, no config change needed (APP_NAME is a code default, not an env var override)
|
||||
|
||||
**Risk: `.env` file has `APP_NAME=Patherly` hardcoded**
|
||||
- Note: The `.env` file may override the code default. If so, update `.env` to `APP_NAME=ResolutionFlow` locally. Railway env vars may also need updating in the dashboard.
|
||||
- This plan updates the code default. The `.env` file and Railway dashboard are manual steps flagged below.
|
||||
|
||||
## Manual Steps (Not in Git)
|
||||
|
||||
1. **Local `.env`**: If `backend/.env` has `APP_NAME=Patherly`, update to `APP_NAME=ResolutionFlow`
|
||||
2. **Railway Dashboard**: If `APP_NAME` is set as an env var in Railway, update it there too
|
||||
3. **Domain rename** (future): If/when `patherly.com` → `resolutionflow.com`, update production URLs in CLAUDE.md, config.py CORS, and Railway settings
|
||||
Reference in New Issue
Block a user