Fix Windows encoding issues: UTF-8 log file and ASCII arrow in logging
Browse files- main.py +1 -1
- src/soci/actions/conversation.py +1 -1
main.py
CHANGED
|
@@ -227,7 +227,7 @@ def main():
|
|
| 227 |
logging.basicConfig(
|
| 228 |
level=logging.INFO,
|
| 229 |
format="%(asctime)s %(name)s %(levelname)s %(message)s",
|
| 230 |
-
handlers=[logging.FileHandler("data/soci.log", mode="a")],
|
| 231 |
)
|
| 232 |
|
| 233 |
asyncio.run(run_simulation(
|
|
|
|
| 227 |
logging.basicConfig(
|
| 228 |
level=logging.INFO,
|
| 229 |
format="%(asctime)s %(name)s %(levelname)s %(message)s",
|
| 230 |
+
handlers=[logging.FileHandler("data/soci.log", mode="a", encoding="utf-8")],
|
| 231 |
)
|
| 232 |
|
| 233 |
asyncio.run(run_simulation(
|
src/soci/actions/conversation.py
CHANGED
|
@@ -133,7 +133,7 @@ async def initiate_conversation(
|
|
| 133 |
)
|
| 134 |
conv.add_turn(turn)
|
| 135 |
|
| 136 |
-
logger.info(f"Conversation started: {initiator.name}
|
| 137 |
return conv
|
| 138 |
|
| 139 |
|
|
|
|
| 133 |
)
|
| 134 |
conv.add_turn(turn)
|
| 135 |
|
| 136 |
+
logger.info(f"Conversation started: {initiator.name} -> {target.name}: \"{message}\"")
|
| 137 |
return conv
|
| 138 |
|
| 139 |
|