Repository navigation
#230 - Logs in database: store invalid UTF-8 and long messages, do not fail the process when storing the logs fails - #233
Merged
Merged
Conversation
…s, and do not fail the process when storing logs fails Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Fixes #230.
DoctrineProcessHandler/LogRecord: a log record with an invalid UTF-8 sequence in its message or context (e.g. a Latin-1 file imported), or with a message longer than 512 code points once truncated to 512 graphemes (emojis, combining marks), made the insertion of the logs fail. The whole batch (up to 500 records) was lost, the process failed on the 500th record (even witherror_strategy: skip), the records then accumulated (500 === count()never true again), and at the end of the processsuccess()/fail()were not called: the execution stayedstartedand the command exited with 1.mb_scrub(), NUL characters removed) and truncated in code points (mb_substr()), as the column length is counted by MySQL and PostgreSQL.null; an encodable context is unchanged.cleverage_processchannel (log file of the execution, not stored in database); the process goes on and the status of its execution is saved. The batch is flushed at>= 500records.Requirements
Breaking changes
None.
🤖 Generated with Claude Code