chore: refactor logging module, update genesis timestamp, remove model relationships, and reorganize routers

- Rename logging.py to logger.py and update import paths in poa.py and main.py
- Update devnet genesis timestamp to 1766828620
- Remove SQLModel Relationship declarations from Block, Transaction, and Receipt models
- Add SessionDep type alias and get_session dependency in coordinator-api deps
- Reorganize coordinator-api routers: replace explorer/registry with exchange, users, marketplace
This commit is contained in:
oib
2025-12-28 21:05:53 +01:00
parent cdaf1122c3
commit ff5486fe08
146 changed files with 33301 additions and 219 deletions

View File

@ -13,7 +13,8 @@ This document tracks components that have been successfully deployed and are ope
- Full-featured blockchain explorer
- Mock data with genesis block (height 0) displayed
- Blocks, transactions, addresses, receipts tracking
- Mock/live data toggle functionality
- Mock/live data toggle functionality (live mode backed by Coordinator API)
- Live API (nginx): `/api/explorer/*`
-**Marketplace Web** - Deployed at https://aitbc.bubuit.net/marketplace/
- Vite + TypeScript frontend
@ -21,10 +22,12 @@ This document tracks components that have been successfully deployed and are ope
- Mock data fixtures with API abstraction
-**Coordinator API** - Deployed in container
- Minimal FastAPI service running on port 8000
- Health endpoint: /v1/health returns {"status":"ok","env":"container"}
- nginx proxy: /api/v1/ routes to container service
- Note: Full codebase has import issues, minimal version deployed
- FastAPI service running on port 8000
- Health endpoint: `/api/v1/health` returns `{"status":"ok","env":"dev"}`
- nginx proxy: `/api/` routes to container service (so `/api/v1/*` works)
- Explorer API (nginx): `/api/explorer/*` → backend `/v1/explorer/*`
- Users API: `/api/v1/users/*` (compat: `/api/users/*` for Exchange)
- ZK Applications API: /api/zk/ endpoints for privacy-preserving features
-**Wallet Daemon** - Deployed in container
- FastAPI service with encrypted keystore (Argon2id + XChaCha20-Poly1305)
@ -38,6 +41,27 @@ This document tracks components that have been successfully deployed and are ope
- Miner, client, developer guides
- API references and technical specs
-**Trade Exchange** - Deployed at https://aitbc.bubuit.net/Exchange/
- Bitcoin wallet integration for AITBC purchases
- User management system with individual wallets
- QR code generation for payments
- Real-time payment monitoring
- Session-based authentication
- Exchange rate: 1 BTC = 100,000 AITBC
-**ZK Applications** - Privacy-preserving features deployed
- Circom compiler v2.2.3 installed
- ZK circuits compiled (receipt_simple with 300 constraints)
- Trusted setup ceremony completed (Powers of Tau)
- Available features:
- Identity commitments
- Stealth addresses
- Private receipt attestation
- Group membership proofs
- Private bidding
- Computation proofs
- API endpoints: /api/zk/
## Host Services (GPU Access)
-**Blockchain Node** - Running on host
@ -56,7 +80,11 @@ This document tracks components that have been successfully deployed and are ope
-**nginx Configuration** - All routes configured
- /explorer/ → Explorer Web
- /marketplace/ → Marketplace Web
- /api/ → Coordinator API (container)
- /api/v1/ → Coordinator API (container)
- /api/explorer/ → Explorer API (container)
- /api/users/ → Users API (container, Exchange compatibility)
- /api/zk/ → ZK Applications API (container)
- /rpc/ → Blockchain RPC (host)
- /v1/ → Mock Coordinator (host)
- /wallet/ → Wallet Daemon (container)
@ -73,7 +101,7 @@ This document tracks components that have been successfully deployed and are ope
## Deployment Architecture
- **Container Services**: Public web access, no GPU required
- Website, Explorer, Marketplace, Coordinator API, Wallet Daemon, Docs
- Website, Explorer, Marketplace, Coordinator API, Wallet Daemon, Docs, ZK Apps
- **Host Services**: GPU access required, private network
- Blockchain Node, Mining operations
- **nginx Proxy**: Routes requests between container and host
@ -82,11 +110,13 @@ This document tracks components that have been successfully deployed and are ope
## Current Status
**Production Ready**: All core services deployed and operational
-6 container services running
-8 container services running (including ZK Applications)
- ✅ 1 host service running
- ✅ Complete nginx proxy configuration
- ✅ SSL/HTTPS fully configured
- ✅ DNS resolution working
- ✅ Trade Exchange with Bitcoin integration
- ✅ Zero-Knowledge proof capabilities enabled
## Remaining Tasks