-
Notifications
You must be signed in to change notification settings - Fork 383
Fixes #1069 Added "Testing Your Changes" Section in CONTRIBUTING.md #1070
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -78,9 +78,16 @@ notesvault/ | |
|
|
||
| ### Prerequisites | ||
|
|
||
| - **Node.js 20+** (for frontend) | ||
| - **Python 3.x** (for backend) | ||
| - **npm 10+** | ||
| - **Node.js 20+** (for frontend) - [Download](https://nodejs.org/) | ||
| - **Python 3.8+** (for backend) - [Download](https://www.python.org/) | ||
| - **npm 10+** (usually comes with Node.js) | ||
|
|
||
| #### Verify installations: | ||
| ```bash | ||
| node --version | ||
| npm --version | ||
| python3 --version | ||
| ``` | ||
|
Comment on lines
+86
to
+90
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Resolve MD046 warnings on newly added code blocks. These fenced blocks are currently flagged by markdownlint ( Also applies to: 113-113, 120-120, 137-137 🧰 Tools🪛 markdownlint-cli2 (0.21.0)[warning] 86-86: Code block style (MD046, code-block-style) 🤖 Prompt for AI Agents |
||
|
|
||
| ### 1. Clone the repository | ||
|
|
||
|
|
@@ -100,11 +107,19 @@ The frontend will run at `http://localhost:5173` | |
|
|
||
| ### 3. Set up Backend (Flask) | ||
|
|
||
| **Terminal 2:** | ||
| **Terminal 2 (new terminal window):** | ||
|
|
||
| First, set up Python virtual environment: | ||
| ```bash | ||
| cd backup_existing_project/backend | ||
| python3 -m venv venv | ||
| source venv/bin/activate # On Windows: venv\Scripts\activate | ||
| ``` | ||
|
|
||
| Then install dependencies and run: | ||
| ```bash | ||
| pip install -r requirements.txt | ||
| python run.py | ||
| python3 run.py | ||
| ``` | ||
|
|
||
| The backend API will run at `http://localhost:5000` | ||
|
|
@@ -116,6 +131,32 @@ The backend API will run at `http://localhost:5000` | |
|
|
||
| The frontend is configured to proxy API requests to the backend automatically. | ||
|
|
||
| ### Troubleshooting | ||
|
|
||
| **Backend won't start - "Port 5000 in use"** | ||
| ```bash | ||
| # Check what's using port 5000 | ||
| lsof -i :5000 | ||
|
|
||
| # Kill the process (replace PID) | ||
| kill -9 <PID> | ||
|
|
||
| # Or start on a different port | ||
| python3 run.py --port 5001 | ||
| ``` | ||
|
Comment on lines
+145
to
+146
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🧩 Analysis chain🏁 Script executed: #!/bin/bash
# Verify whether backend run.py accepts/handles a --port argument.
# Expected:
# - If argparse/click/sys.argv handling exists for port, command is likely valid.
# - Otherwise, docs should be updated to the supported way (e.g., env var or app.run(port=...)).
set -euo pipefail
RUNPY_PATH="$(fd -t f 'run.py' | rg 'backup_existing_project/backend/run.py' || true)"
if [ -z "$RUNPY_PATH" ]; then
echo "run.py not found at expected location"
exit 0
fi
echo "Inspecting: $RUNPY_PATH"
nl -ba "$RUNPY_PATH" | sed -n '1,260p'
echo
echo "Searching for explicit CLI parsing related to port..."
rg -n -C2 'argparse|click|sys\.argv|--port|port\s*=|app\.run\(' "$RUNPY_PATH"Repository: opensource-society/notesvault Length of output: 184 🏁 Script executed: # Find and read the run.py file
cat backup_existing_project/backend/run.pyRepository: opensource-society/notesvault Length of output: 173 🏁 Script executed: # Also check the README.md context around lines 145-146
sed -n '140,150p' README.mdRepository: opensource-society/notesvault Length of output: 310 Remove or correct the The 🤖 Prompt for AI Agents |
||
|
|
||
| **Command not found: python or pip** | ||
| - Use `python3` and `pip3` instead | ||
| - Verify Python 3 is installed: `python3 --version` | ||
|
|
||
| **npm install fails** | ||
| - Clear npm cache: `npm cache clean --force` | ||
| - Delete `node_modules` and `package-lock.json`, then try again | ||
|
|
||
| **Module not found errors on backend** | ||
| - Ensure virtual environment is activated (should see `(venv)` in terminal) | ||
| - Reinstall requirements: `pip install -r requirements.txt --force-reinstall` | ||
|
|
||
| --- | ||
|
|
||
| ## 📜 Available Scripts | ||
|
|
||
Uh oh!
There was an error while loading. Please reload this page.