SEO panel calls the AI feature endpoint even when Jetpack AI is disabled
Maintainers usually reply within 1 day
Nobody has claimed this yet.
Assessment
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Newbie friendliness
- 74/100
Research direction
Start with the SEO panel component, its SEO enhancer hook, and useAiFeature() in editor.js, following the initiator stack described in the issue. Check where availability is determined and why the hook runs when Jetpack AI is disabled and SEO Tools is inactive. Done when opening the editor under those conditions no longer requests the AI feature endpoint; verify in the network panel.
Written by the indexing model from the issue text.
Description
Impacted plugin
Jetpack
Quick summary
With add_filter( 'jetpack_ai_enabled', '__return_false' ), the block editor still requests GET /wp-json/wpcom/v2/jetpack-ai/ai-assistant-feature on every load. The request comes from the Jetpack SEO panel: its component calls the SEO enhancer hook, which calls useAiFeature() before anything checks whether the AI SEO enhancer is available. On sites where the editing user has no WordPress.com token, the endpoint returns a 500.
Steps to reproduce
- On a Jetpack-connected site, add
add_filter( 'jetpack_ai_enabled', '__return_false' );and leave the SEO Tools module inactive. - Log in as a user who can activate modules but is not linked to a WordPress.com account.
- Open a post in the block editor with the network panel open.
- Observe
GET /wp-json/wpcom/v2/jetpack-ai/ai-assistant-featureon load, status 500, bodyfailed_to_fetch_data. The initiator stack runs from the SEO panel component through the SEO enhancer hook touseAiFeatureineditor.js.
Site owner impact
Fewer than 20% of the total website/platform users
Severity
Moderate
What other impact(s) does this issue have?
No revenue impact
If a workaround is available, please outline it here.
No response
Platform (Simple and/or Atomic)
No response
- Dominant language
- PHP
- Stars
- 1.9k
- Forks
- 906
- Avg merge
- 1d 18h
- Merged PRs (30d)
- 793
Getting set up
- No Dockerfile or Docker Compose file
- Has a pull request template
- Read the contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from Automattic/jetpack
-
Bug Needs triage
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
Automattic/jetpack#54575 ·
Maintainers usually reply within 1 day
-
[Package] My Jetpack [Type] Bug
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
Automattic/jetpack#54189 ·
Maintainers usually reply within 1 day
-
[Package] Stats Admin [Type] Bug
Difficulty 1/5 Under an hour Newbie friendliness 86/100
Automattic/jetpack#54188 ·
Maintainers usually reply within 1 day
-
Brute_Force_Protection: two deprecated static wrappers throw Error on PHP 8 (self:: to non-static methods)Possibly taken @Valley-15 claimed this 63 days ago. OpenBug Needs triage
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
Automattic/jetpack#51728 ·
Maintainers usually reply within 1 day
-
Bug Needs triage
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
Automattic/jetpack#51662 ·
Maintainers usually reply within 1 day
All issues in Automattic/jetpack
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
Maintainers usually reply within 3 days
-
sync-en
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
Maintainers usually reply within 1 day
-
[Sync EN] Formatting improvements to "Large Objects (LOBs)" docs (#6056)Possibly taken A pull request linked to this issue is open or already merged. Opensync-en
Difficulty 1/5 Under an hour Newbie friendliness 74/100
Maintainers usually reply within 1 day
-
Перевод устарел
Difficulty 2/5 1-3 hours Newbie friendliness 73/100
Maintainers usually reply within 1 day
-
repo:cms
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
craftcms/cms#20613 · 1 comment ·
Maintainers usually reply within 1 day