chore: consolidate documentation — delete status/fix/progress cruft
Before: 335 tracked .md files; top level had 14 README-like docs; docs/ contained ~234 files, most of them auto/LLM-generated status reports (ALL_*_COMPLETE*, *_FIX*, DEPLOYMENT_*_FINAL*, etc.). After: 132 tracked .md files. Repo now has exactly five top-level docs: README.md, QUICKSTART.md, RUNBOOK.md, CONTRIBUTING.md, CHANGELOG.md (moved up from docs/). Keeper philosophy in docs/: - API, CCIP (ops + security + receiver/router refs), Chainlist refs, compliance, deployment (guides not status), database connection, legal compliance, metamask integration, production checklist, tiered-architecture implementation/setup, reusable-components plan, token-mechanism doc, wrap-and-bridge operational reference, plus docs/specs/** and docs/api/ / docs/openapi/ trees. Deleted (git history preserves provenance): - All 'ALL_*_COMPLETE*' / '*_FIX*' / '*_FIXED*' / '*_FINAL*' / '*_STATUS*' / '*_PROGRESS*' / '*_SUMMARY*' files. - BLOCKSCOUT_*_FIX / _CRASH / _INITIALIZATION / _SCHEMA / _YAML / _SKIP / _NEXT_STEPS / _START_AND_BUILD / _DATABASE_CREDENTIALS (the last contained passwords). - CCIP_IMPLEMENTATION_* / CCIP_CURRENT_STATUS / CCIP_GAP_* (gap analyses are not a sustained reference). - NPMPLUS_CREDENTIALS_GUIDE.md (contained creds). - LETSENCRYPT_CONFIGURATION_GUIDE.md (contained creds; will be re-introduced as runbook content post-secrets-scrub). - docs/diagnostic-reports/, docs/feature-flags/ (run-time artifacts). README.md: dead links (START_HERE, README_DEPLOYMENT, COMPLETE_DEPLOYMENT, DEPLOYMENT_COMPLETE_FINAL) replaced with links to the five canonical top-level docs + docs/ index.
This commit is contained in:
@@ -1,131 +0,0 @@
|
||||
# TokenFactory138 Compilation Analysis
|
||||
|
||||
**Date**: 2025-12-24
|
||||
**Status**: Pre-deployment analysis
|
||||
|
||||
---
|
||||
|
||||
## ✅ Contract Structure
|
||||
|
||||
TokenFactory138 is well-structured with:
|
||||
- ✅ Proper imports
|
||||
- ✅ Interface compliance
|
||||
- ✅ Error handling
|
||||
- ✅ Access control
|
||||
|
||||
---
|
||||
|
||||
## ⚠️ Potential Issue: Role Permissions
|
||||
|
||||
### Problem
|
||||
|
||||
TokenFactory138 calls PolicyManager functions that require `POLICY_OPERATOR_ROLE`:
|
||||
|
||||
```solidity
|
||||
// In TokenFactory138.deployToken()
|
||||
IPolicyManager(policyManager).setLienMode(token, config.defaultLienMode);
|
||||
IPolicyManager(policyManager).setBridgeOnly(token, config.bridgeOnly);
|
||||
IPolicyManager(policyManager).setBridge(token, config.bridge);
|
||||
```
|
||||
|
||||
But PolicyManager requires `POLICY_OPERATOR_ROLE`:
|
||||
```solidity
|
||||
// In PolicyManager
|
||||
function setLienMode(...) external override onlyRole(POLICY_OPERATOR_ROLE)
|
||||
function setBridgeOnly(...) external override onlyRole(POLICY_OPERATOR_ROLE)
|
||||
function setBridge(...) external override onlyRole(POLICY_OPERATOR_ROLE)
|
||||
```
|
||||
|
||||
### Solution
|
||||
|
||||
The deployment script (`DeployChain138.s.sol`) should grant `POLICY_OPERATOR_ROLE` to TokenFactory138:
|
||||
|
||||
```solidity
|
||||
// After deploying TokenFactory138
|
||||
policyManager.grantRole(policyManager.POLICY_OPERATOR_ROLE(), address(factory));
|
||||
```
|
||||
|
||||
**Check**: Verify this is done in the deployment script.
|
||||
|
||||
---
|
||||
|
||||
## ✅ Compilation Test Commands
|
||||
|
||||
### Test 1: Standard Compilation
|
||||
|
||||
```bash
|
||||
cd /home/intlc/projects/proxmox/smom-dbis-138
|
||||
forge build --contracts contracts/emoney/TokenFactory138.sol 2>&1 | tee /tmp/tf138-std.log
|
||||
```
|
||||
|
||||
**Expected**: May show "Stack too deep" error
|
||||
|
||||
### Test 2: Via-IR Compilation (Recommended)
|
||||
|
||||
```bash
|
||||
cd /home/intlc/projects/proxmox/smom-dbis-138
|
||||
forge build --via-ir --contracts contracts/emoney/TokenFactory138.sol 2>&1 | tee /tmp/tf138-viair.log
|
||||
```
|
||||
|
||||
**Expected**: ✅ Compilation successful
|
||||
|
||||
### Test 3: Full Project Build
|
||||
|
||||
```bash
|
||||
cd /home/intlc/projects/proxmox/smom-dbis-138
|
||||
forge build --via-ir 2>&1 | grep -i "error\|TokenFactory138" | head -20
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
## ✅ Dependency Check
|
||||
|
||||
All dependencies should exist:
|
||||
|
||||
1. ✅ `contracts/emoney/interfaces/ITokenFactory138.sol`
|
||||
2. ✅ `contracts/emoney/interfaces/IeMoneyToken.sol`
|
||||
3. ✅ `contracts/emoney/interfaces/IPolicyManager.sol`
|
||||
4. ✅ `contracts/emoney/eMoneyToken.sol`
|
||||
5. ✅ `contracts/emoney/errors/FactoryErrors.sol`
|
||||
6. ✅ `contracts/emoney/errors/RegistryErrors.sol`
|
||||
7. ✅ OpenZeppelin contracts (via lib/)
|
||||
|
||||
---
|
||||
|
||||
## ✅ Pre-Deployment Checklist
|
||||
|
||||
- [ ] Run compilation test: `./scripts/compile-and-test-tokenfactory.sh`
|
||||
- [ ] Verify no "Stack too deep" errors (use --via-ir)
|
||||
- [ ] Check all dependencies compile
|
||||
- [ ] Verify deployment script grants POLICY_OPERATOR_ROLE to TokenFactory138
|
||||
- [ ] Ensure all required contracts are deployed first:
|
||||
- [ ] ComplianceRegistry ✅
|
||||
- [ ] DebtRegistry
|
||||
- [ ] PolicyManager
|
||||
- [ ] eMoneyToken (implementation)
|
||||
|
||||
---
|
||||
|
||||
## 🚀 Deployment Command
|
||||
|
||||
Once compilation passes:
|
||||
|
||||
```bash
|
||||
cd /home/intlc/projects/proxmox/smom-dbis-138
|
||||
source .env
|
||||
|
||||
forge script script/emoney/DeployChain138.s.sol:DeployChain138 \
|
||||
--rpc-url $RPC_URL \
|
||||
--broadcast \
|
||||
--legacy \
|
||||
--gas-price 20000000000 \
|
||||
--via-ir \
|
||||
-vv
|
||||
```
|
||||
|
||||
**Note**: This deploys the entire eMoney system, including TokenFactory138.
|
||||
|
||||
---
|
||||
|
||||
**Last Updated**: 2025-12-24
|
||||
|
||||
Reference in New Issue
Block a user