fix: fail immediately on missing worker file by AlliBalliBaba · Pull Request #1963 · php/frankenphp

Skip to content

Navigation Menu

Sign in

Appearance settings

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up

Appearance settings

Conversation

@AlliBalliBaba

Copy link Copy Markdown

Contributor

No description provided.

Copy link Copy Markdown

Contributor

@henderkes henderkes left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good idea, won't spam logs with too many consecutive worker failures.

@dunglas

Copy link Copy Markdown

Member

dunglas commented

Nov 8, 2025

Shouldn't we do that in the library directly?

@henderkes

Copy link Copy Markdown

Contributor

henderkes commented

Nov 8, 2025

edited

Loading

Shouldn't we do that in the library directly?

Wouldn't that incur a runtime cost? This only runs during Caddy startup.

Edit: wouldn't matter much, since it's only on restarts.

@AlliBalliBaba

Copy link Copy Markdown

Contributor Author

Doing it like this seems cleanest to me since we just immediately return an error on Init() and don't have to panic.
image

@alexandre-daubois alexandre-daubois merged commit 407ef09 into main

Nov 10, 2025

24 checks passed

@alexandre-daubois alexandre-daubois deleted the fix/error-immediately-on-missing-worker branch

November 10, 2025 08:23

@alexandre-daubois

Copy link Copy Markdown

Member

Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

@dunglas dunglas dunglas approved these changes

@alexandre-daubois alexandre-daubois alexandre-daubois approved these changes

@henderkes henderkes henderkes approved these changes

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

4 participants

@AlliBalliBaba @dunglas @henderkes @alexandre-daubois