Skip to content

Conversation

@shankangke
Copy link

Proposed changes:

Add function_exists check before calling getmypid() to prevent fatal errors in environments where the function is disabled (via disable_functions in php.ini by some hosting providers, e.g. [1] [2] [3] [4]).

Other information:

  • Have you written new tests for your changes, if applicable?
  • Have you checked the E2E test CI results, and verified that your changes do not break them?
  • Have you tested your changes on WordPress.com, if applicable (if so, you'll see a generated comment below with a script to run)?

Jetpack product discussion

Not applicable.

Does this pull request change what data or activity we track or use?

No.

Testing instructions:

  1. Disable getmypid() in php.ini disabled_functions.
  2. Go to WP Super Cache -> Debug. Click Enable Logging.
  3. Before this PR: fatal error. After this PR: no error.

@github-actions github-actions bot added the [Plugin] Super Cache A fast caching plugin for WordPress. label Dec 12, 2025
@github-actions
Copy link
Contributor

github-actions bot commented Dec 12, 2025

Thank you for your PR!

When contributing to Jetpack, we have a few suggestions that can help us test and review your patch:

  • ✅ Include a description of your PR changes.
  • ✅ Add testing instructions.
  • ✅ Specify whether this PR includes any changes to data or privacy.
  • ✅ Add changelog entries to affected projects

This comment will be updated as you work on your PR and make changes. If you think that some of those checks are not needed for your PR, please explain why you think so. Thanks for cooperation 🤖



Super Cache plugin:

No scheduled milestone found for this plugin.

If you have any questions about the release process, please ask in the #jetpack-releases channel on Slack.

@github-actions github-actions bot added [Status] Needs Author Reply We need more details from you. This label will be auto-added until the PR meets all requirements. OSS Citizen This Pull Request was opened by an Open Source contributor. labels Dec 12, 2025
@anomiex anomiex requested a review from donnchawp December 12, 2025 16:51
@shankangke shankangke force-pushed the shankangke-patch-1 branch 2 times, most recently from 46aaf03 to ea83e75 Compare December 12, 2025 18:04
…ug logging

Add function_exists check before calling getmypid() to prevent fatal errors in environments where the function is disabled (e.g., via disable_functions in php.ini by hosting providers).
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

OSS Citizen This Pull Request was opened by an Open Source contributor. [Plugin] Super Cache A fast caching plugin for WordPress. [Status] Needs Author Reply We need more details from you. This label will be auto-added until the PR meets all requirements.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant