Skip to content

[FORNO-229] Image Studio: Enable Image Studio if AI Feature is enabled#47453

Open
kat3samsin wants to merge 9 commits intotrunkfrom
forno-229/disable-image-studio-in-big-sky
Open

[FORNO-229] Image Studio: Enable Image Studio if AI Feature is enabled#47453
kat3samsin wants to merge 9 commits intotrunkfrom
forno-229/disable-image-studio-in-big-sky

Conversation

@kat3samsin
Copy link
Contributor

@kat3samsin kat3samsin commented Mar 4, 2026

Fixes #

Proposed changes:

  • Enable Image Studio if AI features is enabled
  • Simple Site
    OR
  • Jetpack is connected AND jetpack_ai_enabled

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

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

Testing instructions:

See Big Sky PR

Changelog

  • Generate changelog entries for this PR (using AI).

@github-actions
Copy link
Contributor

github-actions bot commented Mar 4, 2026

Are you an Automattician? Please test your changes on all WordPress.com environments to help mitigate accidental explosions.

  • To test on WoA, go to the Plugins menu on a WoA dev site. Click on the "Upload" button and follow the upgrade flow to be able to upload, install, and activate the Jetpack Beta plugin. Once the plugin is active, go to Jetpack > Jetpack Beta, select your plugin (Jetpack), and enable the forno-229/disable-image-studio-in-big-sky branch.
  • To test on Simple, run the following command on your sandbox:
bin/jetpack-downloader test jetpack forno-229/disable-image-studio-in-big-sky

Interested in more tips and information?

  • In your local development environment, use the jetpack rsync command to sync your changes to a WoA dev blog.
  • Read more about our development workflow here: PCYsg-eg0-p2
  • Figure out when your changes will be shipped to customers here: PCYsg-eg5-p2

@github-actions github-actions bot added [Extension] Image Studio [Plugin] Jetpack Issues about the Jetpack plugin. https://wordpress.org/plugins/jetpack/ [Status] In Progress labels Mar 4, 2026
@github-actions
Copy link
Contributor

github-actions bot commented Mar 4, 2026

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 a "[Status]" label (In Progress, Needs Review, ...).
  • ✅ 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 🤖


Follow this PR Review Process:

  1. Ensure all required checks appearing at the bottom of this PR are passing.
  2. Make sure to test your changes on all platforms that it applies to. You're responsible for the quality of the code you ship.
  3. You can use GitHub's Reviewers functionality to request a review.
  4. When it's reviewed and merged, you will be pinged in Slack to deploy the changes to WordPress.com simple once the build is done.

If you have questions about anything, reach out in #jetpack-developers for guidance!


Jetpack plugin:

The Jetpack plugin has different release cadences depending on the platform:

  • WordPress.com Simple releases happen as soon as you deploy your changes after merging this PR (PCYsg-Jjm-p2).
  • WoA releases happen weekly.
  • Releases to self-hosted sites happen monthly:
    • Scheduled release: March 31, 2026
    • Code freeze: March 31, 2026

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

@github-actions github-actions bot added the [Status] Needs Author Reply We need more details from you. This label will be auto-added until the PR meets all requirements. label Mar 4, 2026
@jp-launch-control
Copy link

jp-launch-control bot commented Mar 4, 2026

Code Coverage Summary

Coverage changed in 1 file.

File Coverage Δ% Δ Uncovered
projects/plugins/jetpack/extensions/plugins/image-studio/image-studio.php 142/155 (91.61%) -0.95% 2 ❤️‍🩹

Full summary · PHP report · JS report

@kat3samsin kat3samsin changed the title Forno 229/disable image studio in big sky [FORNO-229] Image Studio: Enable Image Studio if Big Sky plugin is installed and enabled Mar 5, 2026
@kat3samsin kat3samsin marked this pull request as ready for review March 5, 2026 00:08
Copilot AI review requested due to automatic review settings March 5, 2026 00:08
@kat3samsin kat3samsin added [Status] Needs Review This PR is ready for review. and removed [Status] Needs Author Reply We need more details from you. This label will be auto-added until the PR meets all requirements. [Status] In Progress labels Mar 5, 2026
@kat3samsin kat3samsin self-assigned this Mar 5, 2026
@kat3samsin kat3samsin requested review from saroshaga and t-wright March 5, 2026 00:18
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR enables Image Studio when the Big Sky plugin is installed and enabled. It adds a new is_big_sky_enabled() helper function that checks for the presence of the Big_Sky class and a big_sky_enable option, and hooks it into is_image_studio_enabled() as an additional activation condition alongside the existing filter-based checks.

Changes:

  • Added is_big_sky_enabled() helper function to image-studio.php that detects the Big Sky plugin and its enabled option
  • Updated is_image_studio_enabled() to also return true when Big Sky is active
  • Added comprehensive test coverage for both is_big_sky_enabled() and its integration with is_image_studio_enabled(), with proper test isolation via option management in set_up/tear_down

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 3 comments.

File Description
extensions/plugins/image-studio/image-studio.php Adds is_big_sky_enabled() function and integrates it into is_image_studio_enabled()
tests/php/extensions/plugins/image-studio/Image_Studio_Test.php Adds test isolation (option in set_up/tear_down), simulate_big_sky_class() helper, and 9 new test cases
changelog/forno-229-disable-image-studio-in-big-sky Changelog entry for the patch

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Copilot AI review requested due to automatic review settings March 5, 2026 01:08
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@kat3samsin kat3samsin force-pushed the forno-229/disable-image-studio-in-big-sky branch from 28652d3 to 27bd1ac Compare March 5, 2026 01:19
Copilot AI review requested due to automatic review settings March 5, 2026 01:29
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

t-wright
t-wright previously approved these changes Mar 5, 2026
Copy link
Contributor

@t-wright t-wright left a comment

Choose a reason for hiding this comment

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

Tested on simple by toggling AI assistant to disable Big Sky. Works as expected!

@kat3samsin
Copy link
Contributor Author

Tested on simple by toggling AI assistant to disable Big Sky. Works as expected!

Thank you for testing! I realized there will be a short period where Jetpack will not be updated immediately in WoA due to weekly release cadence.

I set the jetpack_image_studio_enabled filter to true whenever AI feature is enabled. This would be checked in BigSky.

@kat3samsin kat3samsin changed the title [FORNO-229] Image Studio: Enable Image Studio if Big Sky plugin is installed and enabled [FORNO-229] Image Studio: Enable Image Studio if AI Feature is enabled Mar 5, 2026
@kat3samsin kat3samsin requested a review from t-wright March 5, 2026 19:39
@kat3samsin
Copy link
Contributor Author

Tested on simple by toggling AI assistant to disable Big Sky.

I realized we shouldn't disable Image Studio because we have Jetpack connected and AI features enabled.

Copilot AI review requested due to automatic review settings March 6, 2026 14:54
@kat3samsin kat3samsin force-pushed the forno-229/disable-image-studio-in-big-sky branch from 6398754 to 1cd9f1a Compare March 6, 2026 14:54
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Copilot encountered an error and was unable to review this pull request. You can try again by re-requesting a review.

Copilot AI review requested due to automatic review settings March 6, 2026 17:50
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 3 out of 3 changed files in this pull request and generated 3 comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Copilot AI review requested due to automatic review settings March 6, 2026 20:14
Require has_ai_features() AND (is_automattician() || is_big_sky_enabled())
for Image Studio to load. Uses \is_automattician() on Simple sites,
AT_PROXIED_REQUEST on Atomic/self-hosted.

Includes updated unit tests for the new enablement logic.
@kat3samsin kat3samsin force-pushed the forno-229/disable-image-studio-in-big-sky branch from 87a6ead to a928b19 Compare March 6, 2026 20:15
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

…-studio.php

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Copilot AI review requested due to automatic review settings March 6, 2026 20:19
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Copilot encountered an error and was unable to review this pull request. You can try again by re-requesting a review.

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

Labels

[Extension] Image Studio [Plugin] Jetpack Issues about the Jetpack plugin. https://wordpress.org/plugins/jetpack/ [Status] Needs Review This PR is ready for review. [Tests] Includes Tests

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants