[wp-trac] [WordPress Trac] #65094: AI: Prompt construction fails with fatal error when wp_ai_client_default_request_timeout filter returns negative number

WordPress Trac noreply at wordpress.org
Sun Apr 26 06:15:16 UTC 2026


#65094: AI: Prompt construction fails with fatal error when
wp_ai_client_default_request_timeout filter returns negative number
-------------------------------------------------+-------------------------
 Reporter:  westonruter                          |       Owner:
                                                 |  westonruter
     Type:  defect (bug)                         |      Status:  reopened
 Priority:  normal                               |   Milestone:  7.0
Component:  AI                                   |     Version:
 Severity:  normal                               |  Resolution:
 Keywords:  has-patch has-unit-tests commit      |     Focuses:
  dev-feedback                                   |
-------------------------------------------------+-------------------------

Comment (by priyankaadbrains):

 I tested the issue and confirmed that returning a negative value for the ⁠
 wp_ai_client_default_request_timeout ⁠ filter causes a fatal error during
 prompt construction.

 The patch properly handles invalid timeout values and prevents the crash.
 AI requests are now functioning as expected.

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/65094#comment:29>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list