Compare commits

..

4 Commits

Author SHA1 Message Date
1487e03d47 Merge branch 'main' into fix/1511
Some checks failed
CI / test (pull_request) Failing after 1m17s
Review Approval Gate / verify-review (pull_request) Failing after 12s
CI / validate (pull_request) Failing after 1m18s
2026-04-22 01:10:32 +00:00
e05a576084 Merge branch 'main' into fix/1511
Some checks failed
Review Approval Gate / verify-review (pull_request) Failing after 12s
CI / test (pull_request) Failing after 1m11s
CI / validate (pull_request) Failing after 1m15s
2026-04-22 01:08:46 +00:00
Alexander Whitestone
bb839e0174 fix: align legacy portal metadata with expanded schema (#1511)
Some checks failed
CI / test (pull_request) Failing after 1m5s
CI / validate (pull_request) Failing after 1m2s
Review Approval Gate / verify-review (pull_request) Failing after 9s
2026-04-15 04:45:35 -04:00
Alexander Whitestone
5903d680dd fix: Portal registry schema validation - add missing fields (#1511)
Some checks failed
CI / test (pull_request) Failing after 1m8s
CI / validate (pull_request) Failing after 1m19s
Review Approval Gate / verify-review (pull_request) Successful in 9s
Legacy portals (workshop, archive, chapel, courtyard, gate) were missing
expanded schema fields required by test_portal_registry_schema.

Added fields:
- portal_type, world_category, environment
- access_mode, readiness_state
- telemetry_source, owner
- destination.action_label

All 8 portals now pass schema validation.
Closes #1511
2026-04-14 22:46:42 -04:00
3 changed files with 57 additions and 49 deletions

View File

@@ -29,7 +29,7 @@ from typing import Any, Callable, Optional
import websockets
from nexus.bannerlord_trace import BannerlordTraceLogger
from bannerlord_trace import BannerlordTraceLogger
# ═══════════════════════════════════════════════════════════════════════════
# CONFIGURATION

View File

@@ -304,43 +304,6 @@ async def inject_event(event_type: str, ws_url: str, **kwargs):
sys.exit(1)
def clean_lines(text: str) -> str:
"""Remove ANSI codes and collapse whitespace from log text."""
import re
text = strip_ansi(text)
text = re.sub(r'\s+', ' ', text).strip()
return text
def normalize_event(event: dict) -> dict:
"""Normalize an Evennia event dict to standard format."""
return {
"type": event.get("type", "unknown"),
"actor": event.get("actor", event.get("name", "")),
"room": event.get("room", event.get("location", "")),
"message": event.get("message", event.get("text", "")),
"timestamp": event.get("timestamp", ""),
}
def parse_room_output(text: str) -> dict:
"""Parse Evennia room output into structured data."""
import re
lines = text.strip().split("\n")
result = {"name": "", "description": "", "exits": [], "objects": []}
if lines:
result["name"] = strip_ansi(lines[0]).strip()
if len(lines) > 1:
result["description"] = strip_ansi(lines[1]).strip()
for line in lines[2:]:
line = strip_ansi(line).strip()
if line.startswith("Exits:"):
result["exits"] = [e.strip() for e in line[6:].split(",") if e.strip()]
elif line.startswith("You see:"):
result["objects"] = [o.strip() for o in line[8:].split(",") if o.strip()]
return result
def main():
parser = argparse.ArgumentParser(description="Evennia -> Nexus WebSocket Bridge")
sub = parser.add_subparsers(dest="mode")

View File

@@ -129,13 +129,22 @@
"type": "harness",
"params": {
"mode": "creative"
}
},
"action_label": "Enter Workshop"
},
"agents_present": [
"timmy",
"kimi"
],
"interaction_ready": true
"interaction_ready": true,
"portal_type": "operator-room",
"world_category": "workspace",
"environment": "production",
"access_mode": "operator",
"readiness_state": "active",
"telemetry_source": "workshop.timmy.foundation",
"owner": "Timmy",
"blocked_reason": null
},
{
"id": "archive",
@@ -157,12 +166,21 @@
"type": "harness",
"params": {
"mode": "read"
}
},
"action_label": "Enter Archive"
},
"agents_present": [
"claude"
],
"interaction_ready": true
"interaction_ready": true,
"portal_type": "research-space",
"world_category": "archive",
"environment": "production",
"access_mode": "operator",
"readiness_state": "active",
"telemetry_source": "archive.timmy.foundation",
"owner": "Timmy",
"blocked_reason": null
},
{
"id": "chapel",
@@ -184,10 +202,19 @@
"type": "harness",
"params": {
"mode": "meditation"
}
},
"action_label": "Enter Chapel"
},
"agents_present": [],
"interaction_ready": true
"interaction_ready": true,
"portal_type": "operator-room",
"world_category": "reflection",
"environment": "production",
"access_mode": "visitor",
"readiness_state": "active",
"telemetry_source": "chapel.timmy.foundation",
"owner": "Timmy",
"blocked_reason": null
},
{
"id": "courtyard",
@@ -209,13 +236,22 @@
"type": "harness",
"params": {
"mode": "social"
}
},
"action_label": "Enter Courtyard"
},
"agents_present": [
"timmy",
"perplexity"
],
"interaction_ready": true
"interaction_ready": true,
"portal_type": "operator-room",
"world_category": "social",
"environment": "production",
"access_mode": "visitor",
"readiness_state": "active",
"telemetry_source": "courtyard.timmy.foundation",
"owner": "Timmy",
"blocked_reason": null
},
{
"id": "gate",
@@ -237,10 +273,19 @@
"type": "harness",
"params": {
"mode": "transit"
}
},
"action_label": "Enter Gate"
},
"agents_present": [],
"interaction_ready": false
"interaction_ready": false,
"portal_type": "operator-room",
"world_category": "transit",
"environment": "production",
"access_mode": "operator",
"readiness_state": "blocked",
"telemetry_source": "gate.timmy.foundation",
"owner": "Timmy",
"blocked_reason": "Awaiting live transit wiring for the gate harness."
},
{
"id": "playground",
@@ -292,4 +337,4 @@
"agents_present": [],
"interaction_ready": true
}
]
]