Draft
Conversation
This reverts all changes from the hosted app project (Admin Extensibility → 'hosted app' sub-project). The hosted app project is being discontinued. This PR removes: - The admin extension specification (static_root, allowed_domains) - The HOSTED_APPS environment variable and template switching - Web build execution during deploy - Template application_url preservation during app creation - Admin-specific dev server asset serving What's preserved: - Asset upload infrastructure (include_assets client step) - used by other extension types - admin_link specification - separate extension type for admin links with intents - Client steps system - general build pipeline infrastructure - devSessionWatchConfig - general watch path infrastructure Reverted PRs: - #7027 - Add admin hosted app local spec - #7096 - Switch app init template to hosted app when HOSTED_APPS env var is set - #7208 - Run web build commands during deploy for hosted apps - #7225 - Preserve template application_url during app creation - #7227 - notify extension dev server of app assets updates (admin parts only) - #7312 - Default allowed_domains to empty array when not configured
Contributor
Differences in type declarationsWe detected differences in the type declarations generated by Typescript for this branch compared to the baseline ('main' branch). Please, review them to ensure they are backward-compatible. Here are some important things to keep in mind:
New type declarationsWe found no new type declarations in this PR Existing type declarationspackages/cli-kit/dist/private/node/constants.d.ts@@ -34,7 +34,6 @@ export declare const environmentVariables: {
skipNetworkLevelRetry: string;
maxRequestTimeForNetworkCalls: string;
disableImportScanning: string;
- hostedApps: string;
};
export declare const defaultThemeKitAccessDomain = "theme-kit-access.shopifyapps.com";
export declare const systemEnvironmentVariables: {
packages/cli-kit/dist/public/node/context/local.d.ts@@ -25,13 +25,6 @@ export declare function isDevelopment(env?: NodeJS.ProcessEnv): boolean;
* @returns True if SHOPIFY_FLAG_VERBOSE is truthy or the flag --verbose has been passed.
*/
export declare function isVerbose(env?: NodeJS.ProcessEnv): boolean;
-/**
- * Returns true if the hosted apps mode is enabled.
- *
- * @param env - The environment variables from the environment of the current process.
- * @returns True if HOSTED_APPS is truthy.
- */
-export declare function isHostedAppsMode(env?: NodeJS.ProcessEnv): boolean;
/**
* Returns true if the environment in which the CLI is running is either
* a local environment (where dev is present).
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Hosted App Revert Plan
Summary
Reverts all changes from the hosted app project (Admin Extensibility → "hosted app" sub-project) while preserving asset upload infrastructure used by other extension types.
PRs Reverted (Merged)
PRs KEPT (Asset Upload Infrastructure)
include_assetsstepadmin_linkspec (different from hosted appadmin)Open PRs to Close (manually)
Detailed File Changes
Deleted Files
packages/app/src/cli/models/extensions/specifications/admin.tsModified Files
cli-kit package
packages/cli-kit/src/private/node/constants.ts- RemovehostedApps: 'HOSTED_APPS'packages/cli-kit/src/public/node/context/local.ts- RemoveisHostedAppsMode()functionpackages/cli-kit/src/public/node/context/local.test.ts- Remove testsapp package - Init/Templates
packages/app/src/cli/prompts/init/init.ts- Remove hosted app template switching, restore staticnonetemplatepackages/app/src/cli/prompts/init/init.test.ts- Remove testsapp package - Extension Specifications
packages/app/src/cli/models/extensions/load-specifications.ts- Remove admin spec import and registrationpackages/app/src/cli/models/extensions/extension-instance.ts- Remove default case in UID generationapp package - Deploy
packages/app/src/cli/services/deploy/bundle.ts- Remove web build during deploypackages/app/src/cli/services/deploy/bundle.test.ts- Remove testsapp package - App Creation
packages/app/src/cli/utilities/developer-platform-client.ts- RemoveapplicationUrl,redirectUrls,staticRootfrom CreateAppOptionspackages/app/src/cli/utilities/developer-platform-client/partners-client.ts- Use default URLspackages/app/src/cli/utilities/developer-platform-client/partners-client.test.ts- Remove testpackages/app/src/cli/utilities/developer-platform-client/app-management-client.ts- Use default URLs, remove admin modulepackages/app/src/cli/utilities/developer-platform-client/app-management-client.test.ts- Remove testspackages/app/src/cli/models/app/loader.ts- Remove URL extraction from template configpackages/app/src/cli/models/app/loader.test.ts- Remove testspackages/app/src/cli/models/app/app.ts- Remove URLs from creationDefaultOptions()app package - Dev Server
packages/app/src/cli/services/dev/extension/payload/store.ts- Remove admin config, app assets, allowed_domainspackages/app/src/cli/services/dev/extension/payload/store.test.ts- Remove testspackages/app/src/cli/services/dev/extension/payload/models.ts- RemoveallowedDomainsandassetsfrom payloadpackages/app/src/cli/services/dev/extension/server.ts- Remove app assets middlewarepackages/app/src/cli/services/dev/extension/server/middlewares.ts- RemovegetAppAssetsMiddlewarepackages/app/src/cli/services/dev/extension.ts- Remove app assets and admin config handlingpackages/app/src/cli/services/dev/extension.test.ts- Remove testsTest plan
pnpm test- all existing tests passshopify app init- extension-only template usesshopify-app-template-noneshopify app deploy- web build does NOT runadmin_linkextensions still work correctly