Skip to content

feat: make frankenphp_log() available in php-cli - #2719

Merged
dunglas merged 2 commits into
mainfrom
feat/cli-frankenphp-log
Oct 16, 2026
Merged

dunglas merged 2 commits into
mainfrom
feat/cli-frankenphp-log

Conversation

@dunglas

@dunglas dunglas commented Oct 16, 2026 •

Copy link
Copy Markdown
Member

Registers frankenphp_log() and the FRANKENPHP_LOG_LEVEL_* constants in the frankenphp-cli module, so code shared between web requests and commands can log the same way.

  • ExecuteScriptCLI() accepts the WithLogger and WithContext options (variadic, existing callers still compile).
  • frankenphp php-cli passes Caddy's default logger, so CLI entries have the same format and logger name as the server's, written to stderr. The Caddyfile isn't loaded, so its log directives don't apply.

mercure_publish() stays unavailable in CLI, see #2718.

@dunglas
dunglas marked this pull request as ready for review October 16, 2026 12:13
@dunglas
dunglas merged commit c035bcf into main Oct 16, 2026
41 checks passed
@dunglas
dunglas deleted the feat/cli-frankenphp-log branch October 16, 2026 21:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants