Agent Skills

reflex-process-management

Manage Reflex application processes: compile to test, run the server in production mode, reload a running app by finding and restarting the app process, and manage logs for debugging. Use when the user wants to test, run, restart, or reload a Reflex app, when troubleshooting a running Reflex server, or when investigating errors.

Install

npx skills add https://github.com/reflex-dev/agent-skills --skill reflex-process-management
SKILL.md

Reflex Process Management

This skill covers how to compile, run, and reload a Reflex application.

Compiling (Testing the App)

To verify the app compiles without errors, run:

reflex compile --dry

This checks for syntax errors, import issues, and component problems without starting the server. Use this as a quick validation step after making changes.

Running the Server

When instructed to run the Reflex server, always use production mode and redirect output to a log file:

reflex run --env prod --single-port 2>&1 | tee reflex.log

This command starts a long-running server process that does not support hot reload in production mode. Code changes will not be picked up automatically — you must stop and restart the server to apply changes (see Reloading a Running App below).

Using 2>&1 | tee reflex.log captures both stdout and stderr to reflex.log while still printing to the terminal.

Important: Always use --env prod unless the user explicitly requests development mode.

Reloading a Running App

To reload the app without manually stopping and restarting from the terminal, follow these steps:

Step 1: Determine the app port

Read reflex.log to find the port the app is listening on. Look for a line like App running at: http://0.0.0.0:<port>. Do not assume the port is 8000.

Step 2: Find the app process

Using the port from Step 1, locate the listening process (not browser connections):

lsof -i :<port> -sTCP:LISTEN -t

The -sTCP:LISTEN flag is critical — it filters to only the server process that is listening on the port, excluding browser or client connections. Without it, you may kill the user's browser.

If lsof is not available, use:

ss -tlnp | grep :<port>

Or:

fuser <port>/tcp

Step 3: Send an interrupt signal

Send SIGINT (equivalent to Ctrl+C) to gracefully stop the process:

kill -INT $(lsof -i :<port> -sTCP:LISTEN -t)

If the process doesn't stop, escalate to SIGTERM:

kill -TERM $(lsof -i :<port> -sTCP:LISTEN -t)

Step 4: Restart the server

Once the old process has exited, truncate the old log and start the server again:

> reflex.log
reflex run --env prod --single-port 2>&1 | tee reflex.log

Investigating Errors

When the user reports an error, read reflex.log to find and diagnose the issue.

Related skills

azure-diagnosticsmicrosoft608KDebug Azure production issues on Azure using AppLens, Azure Monitor, resource health, and safe triage. WHEN: debug production issues, troubleshoot app service, app service high CPU, app service deployment failure, troubleshoot container apps, troubleshoot functions, troubleshoot AKS, VM RDP, Linux SSH, VM black screen, can't connect to VM, reset VM password, NSG or firewall blocking, kubectl cannot connect, kube-system/CoreDNS failures, pod pending, crashloop, node not ready, upgrade failures, aazure-preparemicrosoft608KPrepare azd-based Azure projects for deployment: generates azure.yaml, infrastructure (Bicep/Terraform), and Dockerfiles for the Azure Developer CLI (azd) workflow. USE ONLY when the user explicitly wants to use azd as the deployment tool, or the project already has an azure.yaml file. DO NOT USE FOR: non-azd deployments, Python App Service code-only deploys (use python-appservice-deploy), or cross-cloud migration (use azure-cloud-migrate). WHEN: prepare app for azd, create azure.yaml, set up azazure-aimicrosoft608KUse for Azure AI: Search, Speech, OpenAI, Document Intelligence. Helps with search, vector/hybrid search, speech-to-text, text-to-speech, transcription, OCR. WHEN: AI Search, query search, vector search, hybrid search, semantic search, speech-to-text, text-to-speech, transcribe, OCR, convert text to speech.azure-deploymicrosoft607KExecute Azure deployments for ALREADY-PREPARED applications that have existing .azure/deployment-plan.md and infrastructure files. DO NOT use this skill when the user asks to CREATE a new application — use azure-prepare instead. This skill runs azd up, azd deploy, terraform apply, and az deployment commands with built-in error recovery. Requires .azure/deployment-plan.md from azure-prepare and validated status from azure-validate. WHEN: \"run azd up\", \"run azd deploy\", \"execute deployment\",

Search skills and MCP servers

Fuzzy search across 23,137 skills and servers