Skip to content

Commit 13ab444

Browse files
committed
Update version to 0.10.0, performance improvements
1 parent 6597282 commit 13ab444

File tree

16 files changed

+1317
-700
lines changed

16 files changed

+1317
-700
lines changed

Makefile

Lines changed: 24 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# NetGraph Development Makefile
22
# This Makefile provides convenient shortcuts for common development tasks
33

4-
.PHONY: help venv clean-venv dev install check check-ci lint format test qt clean docs docs-serve docs-diagrams build check-dist publish-test publish validate perf info check-python
4+
.PHONY: help venv clean-venv dev install check check-ci lint format test qt clean docs docs-serve docs-diagrams build check-dist publish-test publish validate perf info check-python hooks
55

66
# Default target - show help
77
.DEFAULT_GOAL := help
@@ -51,14 +51,23 @@ help:
5151
@echo ""
5252
@echo "Utilities:"
5353
@echo " make info - Show project information"
54+
@echo " make hooks - Run pre-commit on all files"
5455
@echo " make check-python - Check if venv Python matches system Python"
5556

5657
# Setup and Installation
5758
dev:
5859
@echo "🚀 Setting up development environment..."
5960
@if [ ! -x "$(VENV_BIN)/python" ]; then \
61+
if [ -z "$(PY_FIND)" ]; then \
62+
echo "❌ Error: No Python interpreter found (python3 or python)"; \
63+
exit 1; \
64+
fi; \
6065
echo "🐍 Creating virtual environment with $(PY_FIND) ..."; \
61-
$(PY_FIND) -m venv venv; \
66+
$(PY_FIND) -m venv venv || { echo "❌ Failed to create venv"; exit 1; }; \
67+
if [ ! -x "$(VENV_BIN)/python" ]; then \
68+
echo "❌ Error: venv creation failed - $(VENV_BIN)/python not found"; \
69+
exit 1; \
70+
fi; \
6271
$(VENV_BIN)/python -m pip install -U pip wheel; \
6372
fi
6473
@echo "📦 Installing dev dependencies..."
@@ -70,7 +79,15 @@ dev:
7079

7180
venv:
7281
@echo "🐍 Creating virtual environment in ./venv ..."
73-
@$(PY_FIND) -m venv venv
82+
@if [ -z "$(PY_FIND)" ]; then \
83+
echo "❌ Error: No Python interpreter found (python3 or python)"; \
84+
exit 1; \
85+
fi
86+
@$(PY_FIND) -m venv venv || { echo "❌ Failed to create venv"; exit 1; }
87+
@if [ ! -x "$(VENV_BIN)/python" ]; then \
88+
echo "❌ Error: venv creation failed - $(VENV_BIN)/python not found"; \
89+
exit 1; \
90+
fi
7491
@$(VENV_BIN)/python -m pip install -U pip wheel
7592
@echo "✅ venv ready. Activate with: source venv/bin/activate"
7693

@@ -236,6 +253,10 @@ info:
236253
fi; \
237254
fi
238255

256+
hooks:
257+
@echo "🔗 Running pre-commit on all files..."
258+
@$(PRECOMMIT) run --all-files || (echo "Some pre-commit hooks failed. Fix and re-run." && exit 1)
259+
239260
check-python:
240261
@if [ -x "$(VENV_BIN)/python" ]; then \
241262
VENV_VER=$$($(VENV_BIN)/python -c "import sys; print(f'{sys.version_info.major}.{sys.version_info.minor}')" 2>/dev/null || echo "unknown"); \

README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -128,10 +128,10 @@ network:
128128
# Define traffic matrix
129129
traffic_matrix_set:
130130
global_traffic:
131-
- source_path: ^site1/leaf/leaf1$
132-
sink_path: ^site2/leaf/leaf1$
133-
demand: 10.0
134-
mode: pairwise
131+
- source_path: ^site1/leaf/
132+
sink_path: ^site2/leaf/
133+
demand: 100.0
134+
mode: combine
135135
flow_policy_config: SHORTEST_PATHS_ECMP
136136

137137
# Define analysis workflow

dev/dev.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,6 @@ make docs-serve # Serve docs locally
2424
pyproject.toml # Package config, dependencies, tool settings
2525
Makefile # Development commands
2626
.pre-commit-config.yaml # Code quality hooks
27-
dev/setup-dev.sh # Development environment setup script
2827
dev/run-checks.sh # Manual code quality checks
2928
```
3029

dev/perf/benchmark_concurrency.py

Lines changed: 0 additions & 222 deletions
This file was deleted.

dev/setup-dev.sh

Lines changed: 0 additions & 48 deletions
This file was deleted.

0 commit comments

Comments
 (0)