MCPcopy
hub / github.com/AstrBotDevs/AstrBot / publish

Method publish

astrbot/core/log.py:141–147  ·  view source on GitHub ↗
(self, log_entry: dict)

Source from the content-addressed store, hash-verified

139 self.subscribers.remove(q)
140
141 def publish(self, log_entry: dict) -> None:
142 self.log_cache.append(log_entry)
143 for q in self.subscribers:
144 try:
145 q.put_nowait(log_entry)
146 except asyncio.QueueFull:
147 pass
148
149
150class LogQueueHandler(logging.Handler):

Callers 2

emitMethod · 0.80
recordMethod · 0.80

Calls 1

appendMethod · 0.45

Tested by

no test coverage detected