You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@superset.apache.org by "msyavuz (via GitHub)" <gi...@apache.org> on 2025/09/08 19:05:59 UTC

[PR] feat(embedded): Enable extensions in embedded context [superset]

msyavuz opened a new pull request, #35062:
URL: https://github.com/apache/superset/pull/35062

   <!---
   Please write the PR title following the conventions at https://www.conventionalcommits.org/en/v1.0.0/
   Example:
   fix(dashboard): load charts correctly
   -->
   
   ### SUMMARY
   <!--- Describe the change below, including rationale and design decisions -->
   Extensions are not set up in embedded context. This PR enables them in embedded and adds an option as argument to differentiate embedded. Other options can be added in the future to enable extensions for different contexts
   
   ### BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF
   <!--- Skip this if not applicable -->
   
   ### TESTING INSTRUCTIONS
   <!--- Required! What steps can be taken to manually verify the changes? -->
   
   ### ADDITIONAL INFORMATION
   <!--- Check any relevant boxes with "x" -->
   <!--- HINT: Include "Fixes #nnn" if you are fixing an existing issue -->
   - [ ] Has associated issue:
   - [ ] Required feature flags:
   - [ ] Changes UI
   - [ ] Includes DB Migration (follow approval process in [SIP-59](https://github.com/apache/superset/issues/13351))
     - [ ] Migration is atomic, supports rollback & is backwards-compatible
     - [ ] Confirm DB migration upgrade and downgrade tested
     - [ ] Runtime estimates and downtime expectations provided
   - [ ] Introduces new feature or API
   - [ ] Removes existing feature or API
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


Re: [PR] feat(embedded): Change function signature of setupExtensions [superset]

Posted by "msyavuz (via GitHub)" <gi...@apache.org>.
msyavuz merged PR #35062:
URL: https://github.com/apache/superset/pull/35062


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


Re: [PR] feat(embedded): Change function signature of setupExtensions [superset]

Posted by "michael-s-molina (via GitHub)" <gi...@apache.org>.
michael-s-molina commented on code in PR #35062:
URL: https://github.com/apache/superset/pull/35062#discussion_r2331295735


##########
superset-frontend/src/setup/setupCodeOverrides.ts:
##########
@@ -17,5 +17,20 @@
  * under the License.
  */
 
-// For individual deployments to add custom overrides
-export default function setupExtensions() {}
+/**
+ * Configuration options for setting up code overrides in different contexts.
+ */
+interface setupCodeOverridesOptions {

Review Comment:
   ```suggestion
   interface CodeOverrideOptions {
   ```



##########
UPDATING.md:
##########
@@ -23,6 +23,7 @@ This file documents any backwards-incompatible changes in Superset and
 assists people when migrating to a new version.
 
 ## Next
+-  35062    : Change the function signature of `setupExtensions` to `setupCodeOverrides` with options as arguments.

Review Comment:
   ```suggestion
   -  [35062](https://github.com/apache/superset/pull/34871): Changed the function signature of `setupExtensions` to `setupCodeOverrides` with options as arguments.
   ```



##########
superset-frontend/src/setup/setupCodeOverrides.ts:
##########
@@ -17,5 +17,20 @@
  * under the License.
  */
 
-// For individual deployments to add custom overrides
-export default function setupExtensions() {}
+/**
+ * Configuration options for setting up code overrides in different contexts.
+ */
+interface setupCodeOverridesOptions {
+  /**
+   * Whether the application is running in embedded mode.
+   */
+  embedded?: boolean;
+}
+
+/**
+ * Hook for individual deployments to add custom overrides
+ * @param options - Configuration options for the setup process
+ */
+export default function setupCodeOverrides(
+  options: setupCodeOverridesOptions = {},
+) {}

Review Comment:
   ```suggestion
   export default function setupCodeOverrides(
     options: CodeOverridesOptions = {},
   ) {}
   ```



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


Re: [PR] feat(embedded): Enable extensions in embedded context [superset]

Posted by "korbit-ai[bot] (via GitHub)" <gi...@apache.org>.
korbit-ai[bot] commented on code in PR #35062:
URL: https://github.com/apache/superset/pull/35062#discussion_r2331136008


##########
superset-frontend/src/setup/setupExtensions.ts:
##########
@@ -18,4 +18,8 @@
  */
 
 // For individual deployments to add custom overrides
-export default function setupExtensions() {}
+interface SetupExtensionsOptions {
+  embedded?: boolean;
+}
+
+export default function setupExtensions(options: SetupExtensionsOptions = {}) {}

Review Comment:
   ### Missing Interface and Function Documentation <sub>![category Design](https://img.shields.io/badge/Design-0d9488)</sub>
   
   <details>
     <summary>Tell me more</summary>
   
   ###### What is the issue?
   The setupExtensions function and its interface lack documentation about their purpose, usage, and the significance of the 'embedded' option.
   
   
   ###### Why this matters
   Without proper documentation, other developers won't understand when and how to use this extension point, potentially leading to misuse or missed functionality.
   
   ###### Suggested change ∙ *Feature Preview*
   ```typescript
   /**
    * Configuration options for setting up custom extensions
    */
   interface SetupExtensionsOptions {
     /**
      * Whether the application is running in embedded mode
      */
     embedded?: boolean;
   }
   
   /**
    * Hook for individual deployments to add custom overrides and extensions
    * @param options - Configuration options for the setup process
    */
   export default function setupExtensions(options: SetupExtensionsOptions = {}) {}
   ```
   
   
   ###### Provide feedback to improve future suggestions
   [![Nice Catch](https://img.shields.io/badge/👍%20Nice%20Catch-71BC78)](https://app.korbit.ai/feedback/aa91ff46-6083-4491-9416-b83dd1994b51/77f8801d-afac-46a6-bcd7-07169963c06f/upvote) [![Incorrect](https://img.shields.io/badge/👎%20Incorrect-white)](https://app.korbit.ai/feedback/aa91ff46-6083-4491-9416-b83dd1994b51/77f8801d-afac-46a6-bcd7-07169963c06f?what_not_true=true)  [![Not in Scope](https://img.shields.io/badge/👎%20Out%20of%20PR%20scope-white)](https://app.korbit.ai/feedback/aa91ff46-6083-4491-9416-b83dd1994b51/77f8801d-afac-46a6-bcd7-07169963c06f?what_out_of_scope=true) [![Not in coding standard](https://img.shields.io/badge/👎%20Not%20in%20our%20standards-white)](https://app.korbit.ai/feedback/aa91ff46-6083-4491-9416-b83dd1994b51/77f8801d-afac-46a6-bcd7-07169963c06f?what_not_in_standard=true) [![Other](https://img.shields.io/badge/👎%20Other-white)](https://app.korbit.ai/feedback/aa91ff46-6083-4491-9416-b83dd1994b51/77f8801d-afac-46a6-bcd7-07169963c06f)
   </details>
   
   <sub>
   
   💬 Looking for more details? Reply to this comment to chat with Korbit.
   </sub>
   
   <!--- korbi internal id:27c9a074-480f-4360-9e02-98038ee1747c -->
   
   
   [](27c9a074-480f-4360-9e02-98038ee1747c)



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


Re: [PR] feat(embedded): Change function signature of setupExtensions [superset]

Posted by "michael-s-molina (via GitHub)" <gi...@apache.org>.
michael-s-molina commented on code in PR #35062:
URL: https://github.com/apache/superset/pull/35062#discussion_r2331296907


##########
superset-frontend/src/setup/setupCodeOverrides.ts:
##########
@@ -17,5 +17,20 @@
  * under the License.
  */
 
-// For individual deployments to add custom overrides
-export default function setupExtensions() {}
+/**
+ * Configuration options for setting up code overrides in different contexts.
+ */
+interface setupCodeOverridesOptions {
+  /**
+   * Whether the application is running in embedded mode.
+   */
+  embedded?: boolean;
+}
+
+/**
+ * Hook for individual deployments to add custom overrides
+ * @param options - Configuration options for the setup process
+ */
+export default function setupCodeOverrides(
+  options: setupCodeOverridesOptions = {},
+) {}

Review Comment:
   ```suggestion
   export default function setupCodeOverrides(
     options: CodeOverrideOptions = {},
   ) {}
   ```



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


Re: [PR] feat(embedded): Enable extensions in embedded context [superset]

Posted by "msyavuz (via GitHub)" <gi...@apache.org>.
msyavuz commented on PR #35062:
URL: https://github.com/apache/superset/pull/35062#issuecomment-3267751698

   @michael-s-molina I don't think this is a breaking change though? The modifications here are entirely optional. Only thing changing here is that extensions now apply to embedded as well. Not sure how this relates to the extension work you guys are doing but happy to sync up if this breaks anything there


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org


Re: [PR] feat(embedded): Enable extensions in embedded context [superset]

Posted by "korbit-ai[bot] (via GitHub)" <gi...@apache.org>.
korbit-ai[bot] commented on PR #35062:
URL: https://github.com/apache/superset/pull/35062#issuecomment-3267581076

   Based on your review schedule, I'll hold off on reviewing this PR until it's marked as ready for review. If you'd like me to take a look now, comment `/korbit-review`.
   
   > Your admin can change your review schedule in the [Korbit Console](https://app.korbit.ai/settings)
   
   
   
   [](d9410372-e87d-4366-a022-30561ae202fa)


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org