@sprucelabs/spruce-cli 19.0.0 → 19.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.DS_Store +0 -0
- package/.env +25 -0
- package/.eslintcache +1 -0
- package/CHANGELOG.md +6 -0
- package/build/.spruce/errors/spruceCli/actionCancelled.schema.js.map +1 -1
- package/build/.spruce/errors/spruceCli/bootError.schema.js.map +1 -1
- package/build/.spruce/errors/spruceCli/buildFailed.schema.js.map +1 -1
- package/build/.spruce/errors/spruceCli/cacheNotEnabled.schema.js.map +1 -1
- package/build/.spruce/errors/spruceCli/commandAborted.schema.js.map +1 -1
- package/build/.spruce/errors/spruceCli/commandBlocked.schema.js.map +1 -1
- package/build/.spruce/errors/spruceCli/commandNotImplemented.schema.js.map +1 -1
- package/build/.spruce/errors/spruceCli/createAutoloaderFailed.schema.js.map +1 -1
- package/build/.spruce/errors/spruceCli/dependencyExists.schema.js.map +1 -1
- package/build/.spruce/errors/spruceCli/deployFailed.schema.js.map +1 -1
- package/build/.spruce/errors/spruceCli/directoryEmpty.schema.js.map +1 -1
- package/build/.spruce/errors/spruceCli/directoryNotSkill.schema.js.map +1 -1
- package/build/.spruce/errors/spruceCli/dockerNotStarted.schema.js.map +1 -1
- package/build/.spruce/errors/spruceCli/executingCommandFailed.schema.js.map +1 -1
- package/build/.spruce/errors/spruceCli/failedToImport.schema.js.map +1 -1
- package/build/.spruce/errors/spruceCli/featureNotInstalled.schema.js.map +1 -1
- package/build/.spruce/errors/spruceCli/fileExists.schema.js.map +1 -1
- package/build/.spruce/errors/spruceCli/generic.schema.js.map +1 -1
- package/build/.spruce/errors/spruceCli/invalidCommand.schema.js.map +1 -1
- package/build/.spruce/errors/spruceCli/invalidEventContract.schema.js.map +1 -1
- package/build/.spruce/errors/spruceCli/invalidFeatureCode.schema.js.map +1 -1
- package/build/.spruce/errors/spruceCli/invalidTestDirectory.schema.js.map +1 -1
- package/build/.spruce/errors/spruceCli/lintFailed.schema.js.map +1 -1
- package/build/.spruce/errors/spruceCli/mercuryResponseError.schema.js.map +1 -1
- package/build/.spruce/errors/spruceCli/missingDependencies.schema.js.map +1 -1
- package/build/.spruce/errors/spruceCli/missingDependenciesDependency.schema.js.map +1 -1
- package/build/.spruce/errors/spruceCli/noOrganizationsFound.schema.js.map +1 -1
- package/build/.spruce/errors/spruceCli/noSkillsRegistered.schema.js.map +1 -1
- package/build/.spruce/errors/spruceCli/notImplemented.schema.js.map +1 -1
- package/build/.spruce/errors/spruceCli/notLoggedIn.schema.js.map +1 -1
- package/build/.spruce/errors/spruceCli/schemaExists.schema.js.map +1 -1
- package/build/.spruce/errors/spruceCli/schemaFailedToImport.schema.js.map +1 -1
- package/build/.spruce/errors/spruceCli/schemaTemplateItemBuildingFailed.schema.js.map +1 -1
- package/build/.spruce/errors/spruceCli/skillNotFound.schema.js.map +1 -1
- package/build/.spruce/errors/spruceCli/skillNotRegistered.schema.js.map +1 -1
- package/build/.spruce/errors/spruceCli/skillViewExists.schema.js.map +1 -1
- package/build/.spruce/errors/spruceCli/storeExists.schema.js.map +1 -1
- package/build/.spruce/errors/spruceCli/testFailed.schema.js.map +1 -1
- package/build/.spruce/errors/spruceCli/themeExists.schema.js.map +1 -1
- package/build/.spruce/errors/spruceCli/transportAlreadyExists.schema.js.map +1 -1
- package/build/.spruce/errors/spruceCli/vscodeNotInstalled.schema.js.map +1 -1
- package/build/.spruce/events/events.contract.js.map +1 -1
- package/build/.spruce/events/heartwood/didRegisterSkillViews.v2021_02_11.contract.js.map +1 -1
- package/build/.spruce/events/heartwood/generateUrl.v2021_02_11.contract.js.map +1 -1
- package/build/.spruce/events/heartwood/getActiveTheme.v2021_02_11.contract.js.map +1 -1
- package/build/.spruce/events/heartwood/getSkillViews.v2021_02_11.contract.js.map +1 -1
- package/build/.spruce/events/heartwood/listViews.v2021_02_11.contract.js.map +1 -1
- package/build/.spruce/events/heartwood/registerDashboardCards.v2021_02_11.contract.js.map +1 -1
- package/build/.spruce/events/heartwood/registerSkillViews.v2021_02_11.contract.js.map +1 -1
- package/build/.spruce/events/heartwood/upsertTheme.v2021_02_11.contract.js.map +1 -1
- package/build/.spruce/events/spruceCli/registerSkillViews.v2021_04_11.contract.js.map +1 -1
- package/build/.spruce/schemas/fields/fieldClassMap.js.map +1 -1
- package/build/.spruce/schemas/fields/fields.types.js.map +1 -1
- package/build/.spruce/schemas/heartwood/v2021_02_11/didRegisterSkillViewsEmitPayload.schema.js.map +1 -1
- package/build/.spruce/schemas/heartwood/v2021_02_11/didRegisterSkillViewsEmitTarget.schema.js.map +1 -1
- package/build/.spruce/schemas/heartwood/v2021_02_11/didRegisterSkillViewsEmitTargetAndPayload.schema.js.map +1 -1
- package/build/.spruce/schemas/heartwood/v2021_02_11/generateUrlEmitPayload.schema.js.map +1 -1
- package/build/.spruce/schemas/heartwood/v2021_02_11/generateUrlEmitTarget.schema.js.map +1 -1
- package/build/.spruce/schemas/heartwood/v2021_02_11/generateUrlEmitTargetAndPayload.schema.js.map +1 -1
- package/build/.spruce/schemas/heartwood/v2021_02_11/generateUrlResponsePayload.schema.js.map +1 -1
- package/build/.spruce/schemas/heartwood/v2021_02_11/getActiveThemeEmitTarget.schema.js.map +1 -1
- package/build/.spruce/schemas/heartwood/v2021_02_11/getActiveThemeEmitTargetAndPayload.schema.js.map +1 -1
- package/build/.spruce/schemas/heartwood/v2021_02_11/getActiveThemeResponsePayload.schema.js.map +1 -1
- package/build/.spruce/schemas/heartwood/v2021_02_11/getSkillViewsEmitTargetAndPayload.schema.js.map +1 -1
- package/build/.spruce/schemas/heartwood/v2021_02_11/getSkillViewsResponsePayload.schema.js.map +1 -1
- package/build/.spruce/schemas/heartwood/v2021_02_11/getViewControllersEmitTarget.schema.js.map +1 -1
- package/build/.spruce/schemas/heartwood/v2021_02_11/listViewsResponsePayload.schema.js.map +1 -1
- package/build/.spruce/schemas/heartwood/v2021_02_11/listViewsResult.schema.js.map +1 -1
- package/build/.spruce/schemas/heartwood/v2021_02_11/registerDashboardCardsResponsePayload.schema.js.map +1 -1
- package/build/.spruce/schemas/heartwood/v2021_02_11/registerSkillViewsEmitPayload.schema.js.map +1 -1
- package/build/.spruce/schemas/heartwood/v2021_02_11/registerSkillViewsEmitTargetAndPayload.schema.js.map +1 -1
- package/build/.spruce/schemas/heartwood/v2021_02_11/registerSkillViewsResponsePayload.schema.js.map +1 -1
- package/build/.spruce/schemas/heartwood/v2021_02_11/theme.schema.js.map +1 -1
- package/build/.spruce/schemas/heartwood/v2021_02_11/upsertThemeEmitPayload.schema.js.map +1 -1
- package/build/.spruce/schemas/heartwood/v2021_02_11/upsertThemeEmitTarget.schema.js.map +1 -1
- package/build/.spruce/schemas/heartwood/v2021_02_11/upsertThemeEmitTargetAndPayload.schema.js.map +1 -1
- package/build/.spruce/schemas/heartwood/v2021_02_11/upsertThemeResponsePayload.schema.js.map +1 -1
- package/build/.spruce/schemas/heartwoodViewControllers/v2021_02_11/theme.schema.js.map +1 -1
- package/build/.spruce/schemas/heartwoodViewControllers/v2021_02_11/themeProps.schema.js.map +1 -1
- package/build/.spruce/schemas/schemas.types.js.map +1 -1
- package/build/.spruce/schemas/spruce/v2020_07_22/choice.schema.js.map +1 -1
- package/build/.spruce/schemas/spruce/v2020_07_22/link.schema.js.map +1 -1
- package/build/.spruce/schemas/spruce/v2020_07_22/location.schema.js.map +1 -1
- package/build/.spruce/schemas/spruce/v2020_07_22/message.schema.js.map +1 -1
- package/build/.spruce/schemas/spruce/v2020_07_22/messageSource.schema.js.map +1 -1
- package/build/.spruce/schemas/spruce/v2020_07_22/messageTarget.schema.js.map +1 -1
- package/build/.spruce/schemas/spruce/v2020_07_22/organization.schema.js.map +1 -1
- package/build/.spruce/schemas/spruce/v2020_07_22/person.schema.js.map +1 -1
- package/build/.spruce/schemas/spruce/v2020_07_22/personLocation.schema.js.map +1 -1
- package/build/.spruce/schemas/spruce/v2020_07_22/personOrganization.schema.js.map +1 -1
- package/build/.spruce/schemas/spruce/v2020_07_22/role.schema.js.map +1 -1
- package/build/.spruce/schemas/spruce/v2020_07_22/sendMessage.schema.js.map +1 -1
- package/build/.spruce/schemas/spruce/v2020_07_22/skill.schema.js.map +1 -1
- package/build/.spruce/schemas/spruce/v2020_07_22/skillCreator.schema.js.map +1 -1
- package/build/.spruce/schemas/spruceCli/v2020_07_22/actionResponse.schema.js.map +1 -1
- package/build/.spruce/schemas/spruceCli/v2020_07_22/bootSkillOptions.schema.js.map +1 -1
- package/build/.spruce/schemas/spruceCli/v2020_07_22/createConversationTopicOptions.schema.js.map +1 -1
- package/build/.spruce/schemas/spruceCli/v2020_07_22/createErrorOptions.schema.js.map +1 -1
- package/build/.spruce/schemas/spruceCli/v2020_07_22/createOrganizationOptions.schema.js.map +1 -1
- package/build/.spruce/schemas/spruceCli/v2020_07_22/createSchemaOptions.schema.js.map +1 -1
- package/build/.spruce/schemas/spruceCli/v2020_07_22/createTestOptions.schema.js.map +1 -1
- package/build/.spruce/schemas/spruceCli/v2020_07_22/generatedDir.schema.js.map +1 -1
- package/build/.spruce/schemas/spruceCli/v2020_07_22/generatedFile.schema.js.map +1 -1
- package/build/.spruce/schemas/spruceCli/v2020_07_22/installSkillAtOrganizationOptions.schema.js.map +1 -1
- package/build/.spruce/schemas/spruceCli/v2020_07_22/listenEventOptions.schema.js.map +1 -1
- package/build/.spruce/schemas/spruceCli/v2020_07_22/namedTemplateItem.schema.js.map +1 -1
- package/build/.spruce/schemas/spruceCli/v2020_07_22/nodeFeatureOptions.schema.js.map +1 -1
- package/build/.spruce/schemas/spruceCli/v2020_07_22/npmPackage.schema.js.map +1 -1
- package/build/.spruce/schemas/spruceCli/v2020_07_22/onboardOptions.schema.js.map +1 -1
- package/build/.spruce/schemas/spruceCli/v2020_07_22/onboarding.schema.js.map +1 -1
- package/build/.spruce/schemas/spruceCli/v2020_07_22/personWithToken.schema.js.map +1 -1
- package/build/.spruce/schemas/spruceCli/v2020_07_22/registerDashboardWidgetsEmitPayloadSchema.schema.js.map +1 -1
- package/build/.spruce/schemas/spruceCli/v2020_07_22/setupTestsOptions.schema.js.map +1 -1
- package/build/.spruce/schemas/spruceCli/v2020_07_22/setupVscodeOptions.schema.js.map +1 -1
- package/build/.spruce/schemas/spruceCli/v2020_07_22/skillFeature.schema.js.map +1 -1
- package/build/.spruce/schemas/spruceCli/v2020_07_22/syncErrorOptions.schema.js.map +1 -1
- package/build/.spruce/schemas/spruceCli/v2020_07_22/syncEventOptions.schema.js.map +1 -1
- package/build/.spruce/schemas/spruceCli/v2020_07_22/syncSchemaFieldsOptions.schema.js.map +1 -1
- package/build/.spruce/schemas/spruceCli/v2020_07_22/syncSchemasOptions.schema.js.map +1 -1
- package/build/.spruce/schemas/spruceCli/v2020_07_22/testOptions.schema.js.map +1 -1
- package/build/.spruce/schemas/spruceCli/v2020_07_22/upgradeSkillOptions.schema.js.map +1 -1
- package/build/.spruce/schemas/spruceCli/v2020_07_22/watcherDidDetectChangesEmitPayload.schema.js.map +1 -1
- package/build/.spruce/schemas/spruceEventUtils/v2021_09_13/eventSource.schema.js.map +1 -1
- package/build/.spruce/skill.types.js.map +1 -1
- package/build/GlobalEmitter.js.map +1 -1
- package/build/InFlightEntertainment.js.map +1 -1
- package/build/__tests__/behavioral/AddingADependency.test.js +130 -144
- package/build/__tests__/behavioral/AddingADependency.test.js.map +1 -1
- package/build/__tests__/behavioral/BlockingCommands.test.js +59 -63
- package/build/__tests__/behavioral/BlockingCommands.test.js.map +1 -1
- package/build/__tests__/behavioral/BootingTheCli.test.d.ts +2 -1
- package/build/__tests__/behavioral/BootingTheCli.test.js +60 -22
- package/build/__tests__/behavioral/BootingTheCli.test.js.map +1 -1
- package/build/__tests__/behavioral/BootingWithBadFiles.test.js +46 -52
- package/build/__tests__/behavioral/BootingWithBadFiles.test.js.map +1 -1
- package/build/__tests__/behavioral/CreatingAConversationTopic.test.js +50 -56
- package/build/__tests__/behavioral/CreatingAConversationTopic.test.js.map +1 -1
- package/build/__tests__/behavioral/DeployingASkill.test.js +512 -548
- package/build/__tests__/behavioral/DeployingASkill.test.js.map +1 -1
- package/build/__tests__/behavioral/DeployingToSandbox.test.js +321 -351
- package/build/__tests__/behavioral/DeployingToSandbox.test.js.map +1 -1
- package/build/__tests__/behavioral/EnablingAndDisablingCache.test.js +137 -153
- package/build/__tests__/behavioral/EnablingAndDisablingCache.test.js.map +1 -1
- package/build/__tests__/behavioral/GettingCliVersion.test.js +31 -37
- package/build/__tests__/behavioral/GettingCliVersion.test.js.map +1 -1
- package/build/__tests__/behavioral/ManagingDependencies.test.js +112 -122
- package/build/__tests__/behavioral/ManagingDependencies.test.js.map +1 -1
- package/build/__tests__/behavioral/OverridingCommandsInPackageJson.test.js +41 -45
- package/build/__tests__/behavioral/OverridingCommandsInPackageJson.test.js.map +1 -1
- package/build/__tests__/behavioral/RegisteringConversationsOnBoot.test.js +55 -59
- package/build/__tests__/behavioral/RegisteringConversationsOnBoot.test.js.map +1 -1
- package/build/__tests__/behavioral/RememberingUpgradeSelections.test.js +56 -64
- package/build/__tests__/behavioral/RememberingUpgradeSelections.test.js.map +1 -1
- package/build/__tests__/behavioral/SettingLogTransportsInASkill.test.js +90 -104
- package/build/__tests__/behavioral/SettingLogTransportsInASkill.test.js.map +1 -1
- package/build/__tests__/behavioral/SettingRemote.test.js +64 -74
- package/build/__tests__/behavioral/SettingRemote.test.js.map +1 -1
- package/build/__tests__/behavioral/SettingUpVscode.test.js +52 -56
- package/build/__tests__/behavioral/SettingUpVscode.test.js.map +1 -1
- package/build/__tests__/behavioral/TestingAConversation.test.js +143 -157
- package/build/__tests__/behavioral/TestingAConversation.test.js.map +1 -1
- package/build/__tests__/behavioral/errors/CreatingANewErrorBuilder.test.js +90 -100
- package/build/__tests__/behavioral/errors/CreatingANewErrorBuilder.test.js.map +1 -1
- package/build/__tests__/behavioral/errors/KeepingErrorClassInSync.test.js +74 -78
- package/build/__tests__/behavioral/errors/KeepingErrorClassInSync.test.js.map +1 -1
- package/build/__tests__/behavioral/errors/KeepingErrorsInSync.test.js +180 -190
- package/build/__tests__/behavioral/errors/KeepingErrorsInSync.test.js.map +1 -1
- package/build/__tests__/behavioral/errors/SettingUpErrors.test.js +34 -38
- package/build/__tests__/behavioral/errors/SettingUpErrors.test.js.map +1 -1
- package/build/__tests__/behavioral/eventContract/PullingMercuryEventContract.test.js +179 -201
- package/build/__tests__/behavioral/eventContract/PullingMercuryEventContract.test.js.map +1 -1
- package/build/__tests__/behavioral/events/CreatingAListener.test.js +423 -459
- package/build/__tests__/behavioral/events/CreatingAListener.test.js.map +1 -1
- package/build/__tests__/behavioral/events/CreatingAnEvent.test.js +287 -315
- package/build/__tests__/behavioral/events/CreatingAnEvent.test.js.map +1 -1
- package/build/__tests__/behavioral/events/EventWriter.test.js +64 -66
- package/build/__tests__/behavioral/events/EventWriter.test.js.map +1 -1
- package/build/__tests__/behavioral/events/KeepingEventsInSync.test.js +286 -316
- package/build/__tests__/behavioral/events/KeepingEventsInSync.test.js.map +1 -1
- package/build/__tests__/behavioral/events/KeepingEventsInSync2.test.js +398 -420
- package/build/__tests__/behavioral/events/KeepingEventsInSync2.test.js.map +1 -1
- package/build/__tests__/behavioral/events/KeepingListenersInSync.test.js +43 -49
- package/build/__tests__/behavioral/events/KeepingListenersInSync.test.js.map +1 -1
- package/build/__tests__/behavioral/events/ListeningToAnEventYouCreate.test.js +55 -59
- package/build/__tests__/behavioral/events/ListeningToAnEventYouCreate.test.js.map +1 -1
- package/build/__tests__/behavioral/events/ListeningToCoreEvents.test.js +31 -35
- package/build/__tests__/behavioral/events/ListeningToCoreEvents.test.js.map +1 -1
- package/build/__tests__/behavioral/events/RegisteringEventsOnBoot.test.js +98 -104
- package/build/__tests__/behavioral/events/RegisteringEventsOnBoot.test.js.map +1 -1
- package/build/__tests__/behavioral/events/RegisteringGlobalEvents.test.js +123 -135
- package/build/__tests__/behavioral/events/RegisteringGlobalEvents.test.js.map +1 -1
- package/build/__tests__/behavioral/events/SettingUpEvents.test.js +15 -17
- package/build/__tests__/behavioral/events/SettingUpEvents.test.js.map +1 -1
- package/build/__tests__/behavioral/events/SkillEmitsBootEvents.test.js +66 -72
- package/build/__tests__/behavioral/events/SkillEmitsBootEvents.test.js.map +1 -1
- package/build/__tests__/behavioral/events/SyncingEventsOnlyFromDependencies.test.js +76 -82
- package/build/__tests__/behavioral/events/SyncingEventsOnlyFromDependencies.test.js.map +1 -1
- package/build/__tests__/behavioral/node/CreatingANodeModule.test.js +49 -55
- package/build/__tests__/behavioral/node/CreatingANodeModule.test.js.map +1 -1
- package/build/__tests__/behavioral/onboard/StartingOnboarding.test.js +79 -85
- package/build/__tests__/behavioral/onboard/StartingOnboarding.test.js.map +1 -1
- package/build/__tests__/behavioral/organization/CreatingAnOrg.test.js +45 -49
- package/build/__tests__/behavioral/organization/CreatingAnOrg.test.js.map +1 -1
- package/build/__tests__/behavioral/permissions/CreatingPermissions.test.js +40 -46
- package/build/__tests__/behavioral/permissions/CreatingPermissions.test.js.map +1 -1
- package/build/__tests__/behavioral/permissions/PermissionPlugin.test.js +15 -19
- package/build/__tests__/behavioral/permissions/PermissionPlugin.test.js.map +1 -1
- package/build/__tests__/behavioral/permissions/PermissionStore.test.js +174 -198
- package/build/__tests__/behavioral/permissions/PermissionStore.test.js.map +1 -1
- package/build/__tests__/behavioral/permissions/PermissionWriter.test.js +23 -27
- package/build/__tests__/behavioral/permissions/PermissionWriter.test.js.map +1 -1
- package/build/__tests__/behavioral/permissions/SyncingPermissions.test.d.ts +1 -0
- package/build/__tests__/behavioral/permissions/SyncingPermissions.test.js +209 -208
- package/build/__tests__/behavioral/permissions/SyncingPermissions.test.js.map +1 -1
- package/build/__tests__/behavioral/permissions/support/AbstractPermissionsTest.js +34 -40
- package/build/__tests__/behavioral/permissions/support/AbstractPermissionsTest.js.map +1 -1
- package/build/__tests__/behavioral/permissions/support/generateShortAlphaId.js.map +1 -1
- package/build/__tests__/behavioral/permissions/support/renderPermissionTestFile.js.map +1 -1
- package/build/__tests__/behavioral/permissions/support/sortPermissionContracts.js.map +1 -1
- package/build/__tests__/behavioral/person/LoggingInAsPerson.test.js +153 -171
- package/build/__tests__/behavioral/person/LoggingInAsPerson.test.js.map +1 -1
- package/build/__tests__/behavioral/person/SeeWhoIsLoggedIn.test.js +40 -46
- package/build/__tests__/behavioral/person/SeeWhoIsLoggedIn.test.js.map +1 -1
- package/build/__tests__/behavioral/polish/SettingUpPolish.test.js +102 -116
- package/build/__tests__/behavioral/polish/SettingUpPolish.test.js.map +1 -1
- package/build/__tests__/behavioral/schemas/CreatingANewSchemaBuilder.test.js +227 -247
- package/build/__tests__/behavioral/schemas/CreatingANewSchemaBuilder.test.js.map +1 -1
- package/build/__tests__/behavioral/schemas/CreatingSchemasWithGenerics.test.js +27 -29
- package/build/__tests__/behavioral/schemas/CreatingSchemasWithGenerics.test.js.map +1 -1
- package/build/__tests__/behavioral/schemas/GeneratingFieldTypesOnly.test.js +38 -42
- package/build/__tests__/behavioral/schemas/GeneratingFieldTypesOnly.test.js.map +1 -1
- package/build/__tests__/behavioral/schemas/GettingSchemasFromHealthCheck.test.js +65 -73
- package/build/__tests__/behavioral/schemas/GettingSchemasFromHealthCheck.test.js.map +1 -1
- package/build/__tests__/behavioral/schemas/HandlesRelatedSchemas.test.js +100 -110
- package/build/__tests__/behavioral/schemas/HandlesRelatedSchemas.test.js.map +1 -1
- package/build/__tests__/behavioral/schemas/ImportingSchemaImports.test.js +25 -27
- package/build/__tests__/behavioral/schemas/ImportingSchemaImports.test.js.map +1 -1
- package/build/__tests__/behavioral/schemas/KeepingSchemasInSync.test.js +425 -465
- package/build/__tests__/behavioral/schemas/KeepingSchemasInSync.test.js.map +1 -1
- package/build/__tests__/behavioral/schemas/SettingUpSchemas.test.js +49 -55
- package/build/__tests__/behavioral/schemas/SettingUpSchemas.test.js.map +1 -1
- package/build/__tests__/behavioral/schemas/SettingUpSchemasForModuleDistribution.test.js +435 -467
- package/build/__tests__/behavioral/schemas/SettingUpSchemasForModuleDistribution.test.js.map +1 -1
- package/build/__tests__/behavioral/schemas/SyncingBadSchemasProvidesHelpfulErrorMessages.test.js +19 -21
- package/build/__tests__/behavioral/schemas/SyncingBadSchemasProvidesHelpfulErrorMessages.test.js.map +1 -1
- package/build/__tests__/behavioral/schemas/UsingSchemasInCli.test.js +9 -11
- package/build/__tests__/behavioral/schemas/UsingSchemasInCli.test.js.map +1 -1
- package/build/__tests__/behavioral/skill/BootingASkill.test.js +61 -67
- package/build/__tests__/behavioral/skill/BootingASkill.test.js.map +1 -1
- package/build/__tests__/behavioral/skill/CreatingASkill.test.js +37 -41
- package/build/__tests__/behavioral/skill/CreatingASkill.test.js.map +1 -1
- package/build/__tests__/behavioral/skill/InstallingASkillAtAnOrg.test.js +183 -199
- package/build/__tests__/behavioral/skill/InstallingASkillAtAnOrg.test.js.map +1 -1
- package/build/__tests__/behavioral/skill/LoggingInAsASkill.test.js +153 -171
- package/build/__tests__/behavioral/skill/LoggingInAsASkill.test.js.map +1 -1
- package/build/__tests__/behavioral/skill/RebuildingASkill.test.js +37 -43
- package/build/__tests__/behavioral/skill/RebuildingASkill.test.js.map +1 -1
- package/build/__tests__/behavioral/skill/RegisteringASkill.test.js +96 -104
- package/build/__tests__/behavioral/skill/RegisteringASkill.test.js.map +1 -1
- package/build/__tests__/behavioral/skill/SettingUpASkill.test.js +168 -184
- package/build/__tests__/behavioral/skill/SettingUpASkill.test.js.map +1 -1
- package/build/__tests__/behavioral/stores/CreatingADataStore.test.js +169 -191
- package/build/__tests__/behavioral/stores/CreatingADataStore.test.js.map +1 -1
- package/build/__tests__/behavioral/stores/KeepingDataStoresInSync.test.js +105 -125
- package/build/__tests__/behavioral/stores/KeepingDataStoresInSync.test.js.map +1 -1
- package/build/__tests__/behavioral/tests/CreatingATest.test.js +208 -232
- package/build/__tests__/behavioral/tests/CreatingATest.test.js.map +1 -1
- package/build/__tests__/behavioral/tests/RunningTests.test.js +75 -79
- package/build/__tests__/behavioral/tests/RunningTests.test.js.map +1 -1
- package/build/__tests__/behavioral/tests/SelectingAnAbstractTestClass.test.js +293 -355
- package/build/__tests__/behavioral/tests/SelectingAnAbstractTestClass.test.js.map +1 -1
- package/build/__tests__/behavioral/tests/SettingUpASkillForTesting.test.js +65 -75
- package/build/__tests__/behavioral/tests/SettingUpASkillForTesting.test.js.map +1 -1
- package/build/__tests__/behavioral/tests/SettingUpTests.test.js +29 -33
- package/build/__tests__/behavioral/tests/SettingUpTests.test.js.map +1 -1
- package/build/__tests__/behavioral/tests/TestReporterSettingsRemembered.test.js +50 -54
- package/build/__tests__/behavioral/tests/TestReporterSettingsRemembered.test.js.map +1 -1
- package/build/__tests__/behavioral/tests/TestingDataStores.test.js +87 -95
- package/build/__tests__/behavioral/tests/TestingDataStores.test.js.map +1 -1
- package/build/__tests__/behavioral/upgrading/UpdatingDependencies.test.js +57 -65
- package/build/__tests__/behavioral/upgrading/UpdatingDependencies.test.js.map +1 -1
- package/build/__tests__/behavioral/upgrading/UpdatingDependencies2.test.js +146 -156
- package/build/__tests__/behavioral/upgrading/UpdatingDependencies2.test.js.map +1 -1
- package/build/__tests__/behavioral/upgrading/UpgradingANodeModule.test.js +79 -87
- package/build/__tests__/behavioral/upgrading/UpgradingANodeModule.test.js.map +1 -1
- package/build/__tests__/behavioral/upgrading/UpgradingASkill.test.js +282 -302
- package/build/__tests__/behavioral/upgrading/UpgradingASkill.test.js.map +1 -1
- package/build/__tests__/behavioral/upgrading/UpgradingASkill2.test.js +183 -197
- package/build/__tests__/behavioral/upgrading/UpgradingASkill2.test.js.map +1 -1
- package/build/__tests__/behavioral/upgrading/UpgradingASkill3.test.js +214 -238
- package/build/__tests__/behavioral/upgrading/UpgradingASkill3.test.js.map +1 -1
- package/build/__tests__/behavioral/upgrading/UpgradingASkill4.test.js +118 -126
- package/build/__tests__/behavioral/upgrading/UpgradingASkill4.test.js.map +1 -1
- package/build/__tests__/behavioral/upgrading/UpgradingASkill5.test.js +138 -152
- package/build/__tests__/behavioral/upgrading/UpgradingASkill5.test.js.map +1 -1
- package/build/__tests__/behavioral/upgrading/UpgradingWithListeners.test.js +61 -69
- package/build/__tests__/behavioral/upgrading/UpgradingWithListeners.test.js.map +1 -1
- package/build/__tests__/behavioral/upgrading/UpgradingWithSandboxFeatureInstalled.test.js +90 -104
- package/build/__tests__/behavioral/upgrading/UpgradingWithSandboxFeatureInstalled.test.js.map +1 -1
- package/build/__tests__/behavioral/views/CreatingASkillView.test.js +194 -220
- package/build/__tests__/behavioral/views/CreatingASkillView.test.js.map +1 -1
- package/build/__tests__/behavioral/views/CreatingATheme.test.js +83 -97
- package/build/__tests__/behavioral/views/CreatingATheme.test.js.map +1 -1
- package/build/__tests__/behavioral/views/KeepingViewsInSync.test.js +64 -76
- package/build/__tests__/behavioral/views/KeepingViewsInSync.test.js.map +1 -1
- package/build/__tests__/behavioral/views/RegisteringSkillViewOnBoot.test.js +102 -114
- package/build/__tests__/behavioral/views/RegisteringSkillViewOnBoot.test.js.map +1 -1
- package/build/__tests__/behavioral/views/SettingUpViews.test.js +33 -37
- package/build/__tests__/behavioral/views/SettingUpViews.test.js.map +1 -1
- package/build/__tests__/behavioral/views/TestingViewControllers.test.js +94 -106
- package/build/__tests__/behavioral/views/TestingViewControllers.test.js.map +1 -1
- package/build/__tests__/behavioral/views/WatchingSkillViews.test.js +32 -38
- package/build/__tests__/behavioral/views/WatchingSkillViews.test.js.map +1 -1
- package/build/__tests__/behavioral/watchers/WatchingForChanges.test.js +302 -336
- package/build/__tests__/behavioral/watchers/WatchingForChanges.test.js.map +1 -1
- package/build/__tests__/implementation/ActionExecuter.test.js +132 -136
- package/build/__tests__/implementation/ActionExecuter.test.js.map +1 -1
- package/build/__tests__/implementation/ActionExecuter2.test.js +270 -286
- package/build/__tests__/implementation/ActionExecuter2.test.js.map +1 -1
- package/build/__tests__/implementation/ActionExecuter3.test.js +64 -72
- package/build/__tests__/implementation/ActionExecuter3.test.js.map +1 -1
- package/build/__tests__/implementation/ActionExecuter4.test.js +41 -47
- package/build/__tests__/implementation/ActionExecuter4.test.js.map +1 -1
- package/build/__tests__/implementation/ArgParser.test.js +13 -17
- package/build/__tests__/implementation/ArgParser.test.js.map +1 -1
- package/build/__tests__/implementation/BuildService.test.js +25 -29
- package/build/__tests__/implementation/BuildService.test.js.map +1 -1
- package/build/__tests__/implementation/BulkImporting.test.js +116 -136
- package/build/__tests__/implementation/BulkImporting.test.js.map +1 -1
- package/build/__tests__/implementation/CachingImports.test.js +89 -99
- package/build/__tests__/implementation/CachingImports.test.js.map +1 -1
- package/build/__tests__/implementation/CommandOptionBuilder.test.js.map +1 -1
- package/build/__tests__/implementation/CommanderCommandResultMapper.test.js +72 -90
- package/build/__tests__/implementation/CommanderCommandResultMapper.test.js.map +1 -1
- package/build/__tests__/implementation/DataStoreStore.test.js +127 -147
- package/build/__tests__/implementation/DataStoreStore.test.js.map +1 -1
- package/build/__tests__/implementation/DeletingOrphanedSchemaDefinitions.test.js +46 -52
- package/build/__tests__/implementation/DeletingOrphanedSchemaDefinitions.test.js.map +1 -1
- package/build/__tests__/implementation/EventContractCleanerUtil.test.js +27 -35
- package/build/__tests__/implementation/EventContractCleanerUtil.test.js.map +1 -1
- package/build/__tests__/implementation/EventStore.test.js +371 -399
- package/build/__tests__/implementation/EventStore.test.js.map +1 -1
- package/build/__tests__/implementation/EventTemplateItemBuilder.test.js +21 -27
- package/build/__tests__/implementation/EventTemplateItemBuilder.test.js.map +1 -1
- package/build/__tests__/implementation/FeatureCommandAttacher.test.js +155 -173
- package/build/__tests__/implementation/FeatureCommandAttacher.test.js.map +1 -1
- package/build/__tests__/implementation/FeatureFixture.test.js +54 -62
- package/build/__tests__/implementation/FeatureFixture.test.js.map +1 -1
- package/build/__tests__/implementation/FeatureInstaller.test.js +69 -77
- package/build/__tests__/implementation/FeatureInstaller.test.js.map +1 -1
- package/build/__tests__/implementation/FeaturesUtil.test.js +7 -9
- package/build/__tests__/implementation/FeaturesUtil.test.js.map +1 -1
- package/build/__tests__/implementation/FieldTemplateItemBuilder.test.js +6 -8
- package/build/__tests__/implementation/FieldTemplateItemBuilder.test.js.map +1 -1
- package/build/__tests__/implementation/GlobalEmitter.test.js +29 -33
- package/build/__tests__/implementation/GlobalEmitter.test.js.map +1 -1
- package/build/__tests__/implementation/Introspection.test.js.map +1 -1
- package/build/__tests__/implementation/JestJsonParser.test.js +9 -11
- package/build/__tests__/implementation/JestJsonParser.test.js.map +1 -1
- package/build/__tests__/implementation/LintService.test.js +32 -36
- package/build/__tests__/implementation/LintService.test.js.map +1 -1
- package/build/__tests__/implementation/ListenerStore.test.js.map +1 -1
- package/build/__tests__/implementation/OnboardingScriptLoader.test.js +72 -80
- package/build/__tests__/implementation/OnboardingScriptLoader.test.js.map +1 -1
- package/build/__tests__/implementation/OnboardingScriptPlayer.test.js +217 -243
- package/build/__tests__/implementation/OnboardingScriptPlayer.test.js.map +1 -1
- package/build/__tests__/implementation/OnboardingStore.test.js +19 -23
- package/build/__tests__/implementation/OnboardingStore.test.js.map +1 -1
- package/build/__tests__/implementation/OrganizationStore.test.js +114 -124
- package/build/__tests__/implementation/OrganizationStore.test.js.map +1 -1
- package/build/__tests__/implementation/ParentTestFinder.test.js +38 -44
- package/build/__tests__/implementation/ParentTestFinder.test.js.map +1 -1
- package/build/__tests__/implementation/PkgService.test.js +63 -75
- package/build/__tests__/implementation/PkgService.test.js.map +1 -1
- package/build/__tests__/implementation/SchemaStore.test.js +314 -346
- package/build/__tests__/implementation/SchemaStore.test.js.map +1 -1
- package/build/__tests__/implementation/SchemaTemplateItemBuilder.test.js +9 -11
- package/build/__tests__/implementation/SchemaTemplateItemBuilder.test.js.map +1 -1
- package/build/__tests__/implementation/SchemaValueTypeWriter.test.js +128 -142
- package/build/__tests__/implementation/SchemaValueTypeWriter.test.js.map +1 -1
- package/build/__tests__/implementation/ServiceFactory.test.js +8 -10
- package/build/__tests__/implementation/ServiceFactory.test.js.map +1 -1
- package/build/__tests__/implementation/SettingUpANodeModule.test.js +59 -65
- package/build/__tests__/implementation/SettingUpANodeModule.test.js.map +1 -1
- package/build/__tests__/implementation/SkillStore.test.js +153 -169
- package/build/__tests__/implementation/SkillStore.test.js.map +1 -1
- package/build/__tests__/implementation/StoreFeature.test.js +49 -53
- package/build/__tests__/implementation/StoreFeature.test.js.map +1 -1
- package/build/__tests__/implementation/TestReporter.test.js +31 -39
- package/build/__tests__/implementation/TestReporter.test.js.map +1 -1
- package/build/__tests__/implementation/TestRunner.test.js +215 -233
- package/build/__tests__/implementation/TestRunner.test.js.map +1 -1
- package/build/__tests__/implementation/ValueTypeMapping.test.js +24 -28
- package/build/__tests__/implementation/ValueTypeMapping.test.js.map +1 -1
- package/build/__tests__/implementation/Widgets.test.js +34 -42
- package/build/__tests__/implementation/Widgets.test.js.map +1 -1
- package/build/__tests__/support/EventFaker.js +12 -14
- package/build/__tests__/support/EventFaker.js.map +1 -1
- package/build/__tests__/support/onTestFileResult.js.map +1 -1
- package/build/__tests__/support/scripts/first.script.js +7 -9
- package/build/__tests__/support/scripts/first.script.js.map +1 -1
- package/build/__tests__/support/scripts/second.script.js.map +1 -1
- package/build/__tests__/support/scripts/third.test.script.js.map +1 -1
- package/build/addons/filePrompt.addon.js.map +1 -1
- package/build/boot.d.ts +2 -0
- package/build/boot.js +162 -0
- package/build/boot.js.map +1 -0
- package/build/{cli.d.ts → cli/Cli.d.ts} +9 -33
- package/build/cli/Cli.js +528 -0
- package/build/cli/Cli.js.map +1 -0
- package/build/components/AbstractComponent.js.map +1 -1
- package/build/components/FormComponent.js +156 -160
- package/build/components/FormComponent.js.map +1 -1
- package/build/components/QuizComponent.js +124 -128
- package/build/components/QuizComponent.js.map +1 -1
- package/build/constants.js.map +1 -1
- package/build/errors/SpruceError.js +1 -1
- package/build/errors/SpruceError.js.map +1 -1
- package/build/errors/actionCancelled.builder.js.map +1 -1
- package/build/errors/bootError.builder.js.map +1 -1
- package/build/errors/buildFailed.builder.js.map +1 -1
- package/build/errors/cacheNotEnabled.builder.js.map +1 -1
- package/build/errors/commandAborted.builder.js.map +1 -1
- package/build/errors/commandBlocked.builder.js.map +1 -1
- package/build/errors/commandNotImplemented.builder.js.map +1 -1
- package/build/errors/createAutoloaderFailed.builder.js.map +1 -1
- package/build/errors/dependencyExists.builder.js.map +1 -1
- package/build/errors/deployFailed.builder.js.map +1 -1
- package/build/errors/directoryEmpty.builder.js.map +1 -1
- package/build/errors/directoryNotSkill.builder.js.map +1 -1
- package/build/errors/dockerNotStarted.builder.js.map +1 -1
- package/build/errors/executingCommandFailed.builder.js.map +1 -1
- package/build/errors/failedToImport.builder.js.map +1 -1
- package/build/errors/featureNotInstalled.builder.js.map +1 -1
- package/build/errors/fileExists.builder.js.map +1 -1
- package/build/errors/generic.builder.js.map +1 -1
- package/build/errors/invalidCommand.builder.js.map +1 -1
- package/build/errors/invalidEventContract.builder.js.map +1 -1
- package/build/errors/invalidFeatureCode.builder.js.map +1 -1
- package/build/errors/invalidTestDirectory.builder.js.map +1 -1
- package/build/errors/lintFailed.builder.js.map +1 -1
- package/build/errors/mercuryResponseError.builder.js.map +1 -1
- package/build/errors/missingDependencies.builder.js.map +1 -1
- package/build/errors/noOrganizationsFound.builder.js.map +1 -1
- package/build/errors/noSkillsRegistered.builder.js.map +1 -1
- package/build/errors/notImplemented.builder.js.map +1 -1
- package/build/errors/notLoggedIn.builder.js.map +1 -1
- package/build/errors/schemaExists.builder.js.map +1 -1
- package/build/errors/schemaFailedToImport.builder.js.map +1 -1
- package/build/errors/schemaTemplateItemBuildingFailed.builder.js.map +1 -1
- package/build/errors/skillNotFound.builder.js.map +1 -1
- package/build/errors/skillNotRegistered.builder.js.map +1 -1
- package/build/errors/skillViewExists.builder.js.map +1 -1
- package/build/errors/storeExists.builder.js.map +1 -1
- package/build/errors/testFailed.builder.js.map +1 -1
- package/build/errors/themeExists.builder.js.map +1 -1
- package/build/errors/transportAlreadyExists.builder.js.map +1 -1
- package/build/errors/vscodeNotInstalled.builder.js.map +1 -1
- package/build/features/AbstractAction.js +65 -71
- package/build/features/AbstractAction.js.map +1 -1
- package/build/features/AbstractFeature.js +54 -62
- package/build/features/AbstractFeature.js.map +1 -1
- package/build/features/ActionExecuter.js +206 -210
- package/build/features/ActionExecuter.js.map +1 -1
- package/build/features/ActionFactory.js.map +1 -1
- package/build/features/ActionQuestionAsker.js +304 -320
- package/build/features/ActionQuestionAsker.js.map +1 -1
- package/build/features/FeatureCommandAttacher.js +45 -49
- package/build/features/FeatureCommandAttacher.js.map +1 -1
- package/build/features/FeatureInstaller.js +353 -375
- package/build/features/FeatureInstaller.js.map +1 -1
- package/build/features/FeatureInstallerFactory.js.map +1 -1
- package/build/features/OverrideActionDecorator.js +13 -15
- package/build/features/OverrideActionDecorator.js.map +1 -1
- package/build/features/cache/CacheFeature.js +6 -8
- package/build/features/cache/CacheFeature.js.map +1 -1
- package/build/features/cache/actions/DisableAction.js +42 -44
- package/build/features/cache/actions/DisableAction.js.map +1 -1
- package/build/features/cache/actions/EnableAction.js +37 -39
- package/build/features/cache/actions/EnableAction.js.map +1 -1
- package/build/features/cache/constants.js.map +1 -1
- package/build/features/conversation/ConversationFeature.js +40 -46
- package/build/features/conversation/ConversationFeature.js.map +1 -1
- package/build/features/conversation/actions/CreateAction.js +16 -18
- package/build/features/conversation/actions/CreateAction.js.map +1 -1
- package/build/features/conversation/actions/TestAction.js +96 -102
- package/build/features/conversation/actions/TestAction.js.map +1 -1
- package/build/features/conversation/stores/ConversationStore.js +19 -21
- package/build/features/conversation/stores/ConversationStore.js.map +1 -1
- package/build/features/conversation/writers/ConversationWriter.js +22 -24
- package/build/features/conversation/writers/ConversationWriter.js.map +1 -1
- package/build/features/dependencies/DependencyFeature.js +6 -8
- package/build/features/dependencies/DependencyFeature.js.map +1 -1
- package/build/features/dependencies/actions/AddAction.js +64 -66
- package/build/features/dependencies/actions/AddAction.js.map +1 -1
- package/build/features/dependencies/actions/ManageAction.js +63 -65
- package/build/features/dependencies/actions/ManageAction.js.map +1 -1
- package/build/features/deploy/DeployFeature.js +12 -14
- package/build/features/deploy/DeployFeature.js.map +1 -1
- package/build/features/deploy/actions/HerokuAction.js +389 -409
- package/build/features/deploy/actions/HerokuAction.js.map +1 -1
- package/build/features/deploy/writers/DeployWriter.js.map +1 -1
- package/build/features/error/ErrorFeature.js +84 -92
- package/build/features/error/ErrorFeature.js.map +1 -1
- package/build/features/error/ParentTestFinder.js +22 -24
- package/build/features/error/ParentTestFinder.js.map +1 -1
- package/build/features/error/actions/CreateAction.js +24 -26
- package/build/features/error/actions/CreateAction.js.map +1 -1
- package/build/features/error/actions/SyncAction.js +85 -91
- package/build/features/error/actions/SyncAction.js.map +1 -1
- package/build/features/error/writers/ErrorWriter.js +130 -140
- package/build/features/error/writers/ErrorWriter.js.map +1 -1
- package/build/features/event/EventFeature.js +153 -167
- package/build/features/event/EventFeature.js.map +1 -1
- package/build/features/event/actions/CreateAction.js +59 -61
- package/build/features/event/actions/CreateAction.js.map +1 -1
- package/build/features/event/actions/ListenAction.js +205 -219
- package/build/features/event/actions/ListenAction.js.map +1 -1
- package/build/features/event/actions/SetRemoteAction.js +11 -13
- package/build/features/event/actions/SetRemoteAction.js.map +1 -1
- package/build/features/event/actions/SyncAction.js +25 -27
- package/build/features/event/actions/SyncAction.js.map +1 -1
- package/build/features/event/actions/SyncListenersAction.js +23 -25
- package/build/features/event/actions/SyncListenersAction.js.map +1 -1
- package/build/features/event/builders/EventContractBuilder.js +136 -144
- package/build/features/event/builders/EventContractBuilder.js.map +1 -1
- package/build/features/event/builders/ListenerTemplateItemBuilder.js +1 -1
- package/build/features/event/builders/ListenerTemplateItemBuilder.js.map +1 -1
- package/build/features/event/services/EventSettingsService.js.map +1 -1
- package/build/features/event/services/RemoteService.js.map +1 -1
- package/build/features/event/stores/EventStore.js +246 -258
- package/build/features/event/stores/EventStore.js.map +1 -1
- package/build/features/event/stores/ListenerStore.js +26 -28
- package/build/features/event/stores/ListenerStore.js.map +1 -1
- package/build/features/event/writers/EventWriter.js +171 -183
- package/build/features/event/writers/EventWriter.js.map +1 -1
- package/build/features/eventContract/EventContractFeature.js +6 -8
- package/build/features/eventContract/EventContractFeature.js.map +1 -1
- package/build/features/eventContract/actions/PullAction.js +58 -62
- package/build/features/eventContract/actions/PullAction.js.map +1 -1
- package/build/features/feature.utilities.js.map +1 -1
- package/build/features/log/LogFeature.js.map +1 -1
- package/build/features/log/actions/CreateTransportAction.js +16 -18
- package/build/features/log/actions/CreateTransportAction.js.map +1 -1
- package/build/features/log/writers/LogWriter.js +23 -25
- package/build/features/log/writers/LogWriter.js.map +1 -1
- package/build/features/node/NodeFeature.js +110 -122
- package/build/features/node/NodeFeature.js.map +1 -1
- package/build/features/node/actions/CreateAction.js +9 -11
- package/build/features/node/actions/CreateAction.js.map +1 -1
- package/build/features/node/actions/UpdateDependenciesAction.js +140 -113
- package/build/features/node/actions/UpdateDependenciesAction.js.map +1 -1
- package/build/features/node/actions/UpgradeAction.js +70 -76
- package/build/features/node/actions/UpgradeAction.js.map +1 -1
- package/build/features/node/writers/NodeWriter.js +29 -31
- package/build/features/node/writers/NodeWriter.js.map +1 -1
- package/build/features/onboard/OnboardFeature.js +77 -87
- package/build/features/onboard/OnboardFeature.js.map +1 -1
- package/build/features/onboard/ScriptLoader.js +31 -33
- package/build/features/onboard/ScriptLoader.js.map +1 -1
- package/build/features/onboard/ScriptPlayer.js +80 -86
- package/build/features/onboard/ScriptPlayer.js.map +1 -1
- package/build/features/onboard/actions/OnboardAction.js +36 -38
- package/build/features/onboard/actions/OnboardAction.js.map +1 -1
- package/build/features/onboard/scripts/onboarding.first.script.js +68 -80
- package/build/features/onboard/scripts/onboarding.first.script.js.map +1 -1
- package/build/features/onboard/scripts/onboarding.immersive.script.js +24 -28
- package/build/features/onboard/scripts/onboarding.immersive.script.js.map +1 -1
- package/build/features/onboard/scripts/onboarding.returning.script.js +42 -44
- package/build/features/onboard/scripts/onboarding.returning.script.js.map +1 -1
- package/build/features/onboard/scripts/onboarding.short.script.js +38 -48
- package/build/features/onboard/scripts/onboarding.short.script.js.map +1 -1
- package/build/features/onboard/scripts/todo/todo.create.skill.script.js +9 -11
- package/build/features/onboard/scripts/todo/todo.create.skill.script.js.map +1 -1
- package/build/features/onboard/scripts/todo/todo.test.script.js +7 -9
- package/build/features/onboard/scripts/todo/todo.test.script.js.map +1 -1
- package/build/features/onboard/scripts/wrongCommand.script.js +40 -42
- package/build/features/onboard/scripts/wrongCommand.script.js.map +1 -1
- package/build/features/onboard/stores/OnboardingStore.js.map +1 -1
- package/build/features/organization/OrganizationFeature.js.map +1 -1
- package/build/features/organization/actions/CreateAction.js +18 -20
- package/build/features/organization/actions/CreateAction.js.map +1 -1
- package/build/features/organization/actions/InstallAction.js +81 -83
- package/build/features/organization/actions/InstallAction.js.map +1 -1
- package/build/features/organization/stores/OrganizationStore.js +101 -111
- package/build/features/organization/stores/OrganizationStore.js.map +1 -1
- package/build/features/permission/PermissionFeature.js +73 -79
- package/build/features/permission/PermissionFeature.js.map +1 -1
- package/build/features/permission/actions/CreateAction.js +23 -25
- package/build/features/permission/actions/CreateAction.js.map +1 -1
- package/build/features/permission/actions/SyncAction.js +50 -54
- package/build/features/permission/actions/SyncAction.js.map +1 -1
- package/build/features/permission/stores/PermissionStore.js +100 -104
- package/build/features/permission/stores/PermissionStore.js.map +1 -1
- package/build/features/permission/writers/PermissionWriter.js +57 -63
- package/build/features/permission/writers/PermissionWriter.js.map +1 -1
- package/build/features/person/PersonFeature.js.map +1 -1
- package/build/features/person/actions/LoginAction.js +69 -71
- package/build/features/person/actions/LoginAction.js.map +1 -1
- package/build/features/person/actions/LogoutAction.js +21 -23
- package/build/features/person/actions/LogoutAction.js.map +1 -1
- package/build/features/person/actions/WhoamiAction.js +24 -26
- package/build/features/person/actions/WhoamiAction.js.map +1 -1
- package/build/features/polish/PolishFeature.js.map +1 -1
- package/build/features/polish/actions/SetupAction.js +23 -25
- package/build/features/polish/actions/SetupAction.js.map +1 -1
- package/build/features/polish/writers/PolishWriter.js +16 -18
- package/build/features/polish/writers/PolishWriter.js.map +1 -1
- package/build/features/sandbox/SandboxFeature.js +20 -22
- package/build/features/sandbox/SandboxFeature.js.map +1 -1
- package/build/features/sandbox/actions/SetupAction.js +42 -44
- package/build/features/sandbox/actions/SetupAction.js.map +1 -1
- package/build/features/sandbox/writers/SandboxWriter.js +9 -11
- package/build/features/sandbox/writers/SandboxWriter.js.map +1 -1
- package/build/features/schema/SchemaFeature.js +82 -90
- package/build/features/schema/SchemaFeature.js.map +1 -1
- package/build/features/schema/ValueTypeBuilder.js +26 -28
- package/build/features/schema/ValueTypeBuilder.js.map +1 -1
- package/build/features/schema/actions/CreateAction.js +48 -50
- package/build/features/schema/actions/CreateAction.js.map +1 -1
- package/build/features/schema/actions/SyncAction.js +260 -270
- package/build/features/schema/actions/SyncAction.js.map +1 -1
- package/build/features/schema/actions/SyncFieldsAction.js +42 -44
- package/build/features/schema/actions/SyncFieldsAction.js.map +1 -1
- package/build/features/schema/services/SchemaService.js +24 -26
- package/build/features/schema/services/SchemaService.js.map +1 -1
- package/build/features/schema/stores/SchemaStore.js +205 -219
- package/build/features/schema/stores/SchemaStore.js.map +1 -1
- package/build/features/schema/utilities/schema.utility.js.map +1 -1
- package/build/features/schema/utilities/schemaDisk.utility.js +15 -17
- package/build/features/schema/utilities/schemaDisk.utility.js.map +1 -1
- package/build/features/schema/utilities/schemaGenerator.utility.js +40 -42
- package/build/features/schema/utilities/schemaGenerator.utility.js.map +1 -1
- package/build/features/schema/writers/SchemaWriter.js +173 -185
- package/build/features/schema/writers/SchemaWriter.js.map +1 -1
- package/build/features/skill/SkillFeature.js +99 -112
- package/build/features/skill/SkillFeature.js.map +1 -1
- package/build/features/skill/actions/BootAction.js +92 -96
- package/build/features/skill/actions/BootAction.js.map +1 -1
- package/build/features/skill/actions/CreateAction.js +9 -11
- package/build/features/skill/actions/CreateAction.js.map +1 -1
- package/build/features/skill/actions/DashboardAction.js +8 -10
- package/build/features/skill/actions/DashboardAction.js.map +1 -1
- package/build/features/skill/actions/LoginAction.js +122 -124
- package/build/features/skill/actions/LoginAction.js.map +1 -1
- package/build/features/skill/actions/RebuildAction.js +33 -35
- package/build/features/skill/actions/RebuildAction.js.map +1 -1
- package/build/features/skill/actions/RegisterAction.js +38 -40
- package/build/features/skill/actions/RegisterAction.js.map +1 -1
- package/build/features/skill/stores/SkillStore.d.ts +2 -2
- package/build/features/skill/stores/SkillStore.js +198 -216
- package/build/features/skill/stores/SkillStore.js.map +1 -1
- package/build/features/skill/updaters/Updater.js +38 -40
- package/build/features/skill/updaters/Updater.js.map +1 -1
- package/build/features/skill/writers/SkillWriter.js +15 -17
- package/build/features/skill/writers/SkillWriter.js.map +1 -1
- package/build/features/store/StoreFeature.js +50 -56
- package/build/features/store/StoreFeature.js.map +1 -1
- package/build/features/store/actions/CreateAction.js +29 -31
- package/build/features/store/actions/CreateAction.js.map +1 -1
- package/build/features/store/actions/SyncAction.js +35 -37
- package/build/features/store/actions/SyncAction.js.map +1 -1
- package/build/features/store/stores/StoreStore.js +39 -41
- package/build/features/store/stores/StoreStore.js.map +1 -1
- package/build/features/store/templateItemBuilders/StoreTemplateItemBuilder.js +1 -1
- package/build/features/store/templateItemBuilders/StoreTemplateItemBuilder.js.map +1 -1
- package/build/features/store/writers/StoreWriter.js +65 -73
- package/build/features/store/writers/StoreWriter.js.map +1 -1
- package/build/features/test/TestFeature.js +98 -102
- package/build/features/test/TestFeature.js.map +1 -1
- package/build/features/test/TestLogItemGenerator.js.map +1 -1
- package/build/features/test/TestReporter.d.ts +19 -19
- package/build/features/test/TestReporter.js +74 -82
- package/build/features/test/TestReporter.js.map +1 -1
- package/build/features/test/TestRunner.js +82 -88
- package/build/features/test/TestRunner.js.map +1 -1
- package/build/features/test/actions/CreateAction.js +145 -153
- package/build/features/test/actions/CreateAction.js.map +1 -1
- package/build/features/test/actions/SetupAction.js +37 -39
- package/build/features/test/actions/SetupAction.js.map +1 -1
- package/build/features/test/actions/TestAction.js +203 -213
- package/build/features/test/actions/TestAction.js.map +1 -1
- package/build/features/test/test.types.d.ts +1 -1
- package/build/features/test/test.types.js.map +1 -1
- package/build/features/test/writers/TestWriter.js +17 -19
- package/build/features/test/writers/TestWriter.js.map +1 -1
- package/build/features/universalDevDependencies.js.map +1 -1
- package/build/features/universalFileDescriptions.js.map +1 -1
- package/build/features/universalScripts.js.map +1 -1
- package/build/features/validateAndNormalize.utility.js.map +1 -1
- package/build/features/view/ViewFeature.js +52 -58
- package/build/features/view/ViewFeature.js.map +1 -1
- package/build/features/view/actions/CreateAction.js +64 -66
- package/build/features/view/actions/CreateAction.js.map +1 -1
- package/build/features/view/actions/CreateThemeAction.js +35 -37
- package/build/features/view/actions/CreateThemeAction.js.map +1 -1
- package/build/features/view/actions/SyncAction.js +61 -63
- package/build/features/view/actions/SyncAction.js.map +1 -1
- package/build/features/view/actions/WatchAction.d.ts +1 -0
- package/build/features/view/actions/WatchAction.js +26 -27
- package/build/features/view/actions/WatchAction.js.map +1 -1
- package/build/features/view/stores/ViewStore.js +35 -37
- package/build/features/view/stores/ViewStore.js.map +1 -1
- package/build/features/view/writers/ViewWriter.js +47 -51
- package/build/features/view/writers/ViewWriter.js.map +1 -1
- package/build/features/vscode/VsCodeFeature.js +18 -20
- package/build/features/vscode/VsCodeFeature.js.map +1 -1
- package/build/features/vscode/actions/SetupAction.js +173 -183
- package/build/features/vscode/actions/SetupAction.js.map +1 -1
- package/build/features/vscode/services/VsCodeService.js +63 -69
- package/build/features/vscode/services/VsCodeService.js.map +1 -1
- package/build/features/vscode/writers/VsCodeWriter.js +12 -14
- package/build/features/vscode/writers/VsCodeWriter.js.map +1 -1
- package/build/features/watch/WatchFeature.js +77 -88
- package/build/features/watch/WatchFeature.js.map +1 -1
- package/build/index.js +2 -2
- package/build/index.js.map +1 -1
- package/build/interfaces/SpyInterface.d.ts +1 -0
- package/build/interfaces/SpyInterface.js +139 -148
- package/build/interfaces/SpyInterface.js.map +1 -1
- package/build/interfaces/TerminalInterface.d.ts +1 -0
- package/build/interfaces/TerminalInterface.js +196 -207
- package/build/interfaces/TerminalInterface.js.map +1 -1
- package/build/schemas/v2020_07_22/actionResponse.builder.js.map +1 -1
- package/build/schemas/v2020_07_22/bootSkillOptions.builder.js.map +1 -1
- package/build/schemas/v2020_07_22/createConversationTopicOptions.builder.js.map +1 -1
- package/build/schemas/v2020_07_22/createErrorOptions.builder.js.map +1 -1
- package/build/schemas/v2020_07_22/createOrganizationOptions.builder.js.map +1 -1
- package/build/schemas/v2020_07_22/createSchemaOptions.builder.js.map +1 -1
- package/build/schemas/v2020_07_22/createTestOptions.builder.js.map +1 -1
- package/build/schemas/v2020_07_22/generatedFile.builder.js.map +1 -1
- package/build/schemas/v2020_07_22/installSkillAtOrganizationOptions.builder.js.map +1 -1
- package/build/schemas/v2020_07_22/listenEventOptions.builder.js.map +1 -1
- package/build/schemas/v2020_07_22/namedTemplateItem.builder.js.map +1 -1
- package/build/schemas/v2020_07_22/nodeFeatureOptions.builder.js.map +1 -1
- package/build/schemas/v2020_07_22/onboardOptions.builder.js.map +1 -1
- package/build/schemas/v2020_07_22/onboarding.builder.js.map +1 -1
- package/build/schemas/v2020_07_22/personWithToken.builder.js.map +1 -1
- package/build/schemas/v2020_07_22/registerDashboardWidgetsEmitPayloadSchema.builder.js.map +1 -1
- package/build/schemas/v2020_07_22/setupTestsOptions.builder.js.map +1 -1
- package/build/schemas/v2020_07_22/setupVscodeOptions.builder.js.map +1 -1
- package/build/schemas/v2020_07_22/skillFeature.builder.js.map +1 -1
- package/build/schemas/v2020_07_22/syncErrorOptions.builder.js.map +1 -1
- package/build/schemas/v2020_07_22/syncEventOptions.builder.js.map +1 -1
- package/build/schemas/v2020_07_22/syncSchemaFieldsOptions.builder.js.map +1 -1
- package/build/schemas/v2020_07_22/syncSchemasOptions.builder.js.map +1 -1
- package/build/schemas/v2020_07_22/testOptions.builder.js.map +1 -1
- package/build/schemas/v2020_07_22/upgradeSkillOptions.builder.js.map +1 -1
- package/build/schemas/v2020_07_22/watcherDidDetectChangesEmitPayload.builder.js.map +1 -1
- package/build/services/BuildService.js +16 -18
- package/build/services/BuildService.js.map +1 -1
- package/build/services/CommandService.js +107 -109
- package/build/services/CommandService.js.map +1 -1
- package/build/services/DependencyService.js.map +1 -1
- package/build/services/GameService.js +49 -51
- package/build/services/GameService.js.map +1 -1
- package/build/services/ImportService.js +186 -194
- package/build/services/ImportService.js.map +1 -1
- package/build/services/LintService.js +81 -83
- package/build/services/LintService.js.map +1 -1
- package/build/services/PkgService.js +85 -89
- package/build/services/PkgService.js.map +1 -1
- package/build/services/ServiceFactory.js.map +1 -1
- package/build/services/TypeCheckerService.js +7 -9
- package/build/services/TypeCheckerService.js.map +1 -1
- package/build/stores/AbstractLocalStore.js.map +1 -1
- package/build/stores/AbstractStore.js +6 -8
- package/build/stores/AbstractStore.js.map +1 -1
- package/build/stores/StoreFactory.js.map +1 -1
- package/build/templateItemBuilders/EventTemplateItemBuilder.js +1 -1
- package/build/templateItemBuilders/EventTemplateItemBuilder.js.map +1 -1
- package/build/templateItemBuilders/FieldTemplateItemBuilder.js +1 -1
- package/build/templateItemBuilders/FieldTemplateItemBuilder.js.map +1 -1
- package/build/templateItemBuilders/SchemaTemplateItemBuilder.js +1 -1
- package/build/templateItemBuilders/SchemaTemplateItemBuilder.js.map +1 -1
- package/build/tests/AbstractCliTest.d.ts +2 -3
- package/build/tests/AbstractCliTest.js +236 -266
- package/build/tests/AbstractCliTest.js.map +1 -1
- package/build/tests/AbstractErrorTest.d.ts +1 -1
- package/build/tests/AbstractErrorTest.js +19 -21
- package/build/tests/AbstractErrorTest.js.map +1 -1
- package/build/tests/AbstractEventTest.d.ts +3 -3
- package/build/tests/AbstractEventTest.js +89 -97
- package/build/tests/AbstractEventTest.js.map +1 -1
- package/build/tests/AbstractSchemaTest.d.ts +3 -3
- package/build/tests/AbstractSchemaTest.js +92 -98
- package/build/tests/AbstractSchemaTest.js.map +1 -1
- package/build/tests/AbstractSkillTest.d.ts +1 -1
- package/build/tests/AbstractSkillTest.js +40 -46
- package/build/tests/AbstractSkillTest.js.map +1 -1
- package/build/tests/AbstractTestTest.d.ts +1 -1
- package/build/tests/AbstractTestTest.js +14 -16
- package/build/tests/AbstractTestTest.js.map +1 -1
- package/build/tests/CommandFaker.js.map +1 -1
- package/build/tests/JestJsonParser.js +5 -2
- package/build/tests/JestJsonParser.js.map +1 -1
- package/build/tests/MockProgramFactory.js +11 -15
- package/build/tests/MockProgramFactory.js.map +1 -1
- package/build/tests/buildTestCache.js +223 -243
- package/build/tests/buildTestCache.js.map +1 -1
- package/build/tests/cleanTestCache.js.map +1 -1
- package/build/tests/cleanTestData.js +70 -72
- package/build/tests/cleanTestData.js.map +1 -1
- package/build/tests/constants.js.map +1 -1
- package/build/tests/fixtures/FeatureFixture.d.ts +15 -16
- package/build/tests/fixtures/FeatureFixture.js +142 -154
- package/build/tests/fixtures/FeatureFixture.js.map +1 -1
- package/build/tests/fixtures/MercuryFixture.js +9 -11
- package/build/tests/fixtures/MercuryFixture.js.map +1 -1
- package/build/tests/fixtures/OrganizationFixture.js +62 -68
- package/build/tests/fixtures/OrganizationFixture.js.map +1 -1
- package/build/tests/fixtures/PersonFixture.js +69 -73
- package/build/tests/fixtures/PersonFixture.js.map +1 -1
- package/build/tests/fixtures/SkillFixture.js +123 -137
- package/build/tests/fixtures/SkillFixture.js.map +1 -1
- package/build/tests/fixtures/ViewFixture.js +13 -15
- package/build/tests/fixtures/ViewFixture.js.map +1 -1
- package/build/tests/utilities/test.utility.js.map +1 -1
- package/build/tests/utilities/uiAssert.utility.js +31 -35
- package/build/tests/utilities/uiAssert.utility.js.map +1 -1
- package/build/types/cli.types.d.ts +26 -0
- package/build/types/cli.types.js.map +1 -1
- package/build/types/graphicsInterface.types.js.map +1 -1
- package/build/updaters/ScriptUpdater.js +78 -80
- package/build/updaters/ScriptUpdater.js.map +1 -1
- package/build/utilities/action.utility.js.map +1 -1
- package/build/utilities/apiClient.utility.js.map +1 -1
- package/build/utilities/argParser.utility.js +1 -1
- package/build/utilities/argParser.utility.js.map +1 -1
- package/build/utilities/commander.utility.js.map +1 -1
- package/build/utilities/duration.utility.js.map +1 -1
- package/build/utilities/eventContractCleaner.utility.js +1 -1
- package/build/utilities/eventContractCleaner.utility.js.map +1 -1
- package/build/utilities/form.utility.js.map +1 -1
- package/build/utilities/introspection.utility.js +3 -3
- package/build/utilities/introspection.utility.js.map +1 -1
- package/build/utilities/isCi.js.map +1 -1
- package/build/utilities/tsConfig.utility.js.map +1 -1
- package/build/utilities/ui.utility.js.map +1 -1
- package/build/widgets/Theme.js.map +1 -1
- package/build/widgets/WidgetFactory.js.map +1 -1
- package/build/widgets/keySelectChoices.js.map +1 -1
- package/build/widgets/terminalKit/TKButtonWidget.js.map +1 -1
- package/build/widgets/terminalKit/TkBaseWidget.js +8 -10
- package/build/widgets/terminalKit/TkBaseWidget.js.map +1 -1
- package/build/widgets/terminalKit/TkInputWidget.js +16 -20
- package/build/widgets/terminalKit/TkInputWidget.js.map +1 -1
- package/build/widgets/terminalKit/TkLayoutCellWidget.js.map +1 -1
- package/build/widgets/terminalKit/TkLayoutWidget.js +6 -8
- package/build/widgets/terminalKit/TkLayoutWidget.js.map +1 -1
- package/build/widgets/terminalKit/TkMenuBarWidget.js +1 -1
- package/build/widgets/terminalKit/TkMenuBarWidget.js.map +1 -1
- package/build/widgets/terminalKit/TkPopupWidget.js.map +1 -1
- package/build/widgets/terminalKit/TkProgressBarWidget.js.map +1 -1
- package/build/widgets/terminalKit/TkTextWidget.js +13 -15
- package/build/widgets/terminalKit/TkTextWidget.js.map +1 -1
- package/build/widgets/terminalKit/TkWindowWidget.js +39 -45
- package/build/widgets/terminalKit/TkWindowWidget.js.map +1 -1
- package/build/widgets/terminalKit/termKit.utility.js +1 -1
- package/build/widgets/terminalKit/termKit.utility.js.map +1 -1
- package/build/widgets/types/button.types.js.map +1 -1
- package/build/widgets/types/factory.types.js.map +1 -1
- package/build/widgets/types/input.types.js.map +1 -1
- package/build/widgets/types/menuBar.types.js.map +1 -1
- package/build/widgets/types/popup.types.js.map +1 -1
- package/build/widgets/types/text.types.js.map +1 -1
- package/build/widgets/types/window.types.js.map +1 -1
- package/build/widgets/widget.utilities.js.map +1 -1
- package/build/writers/AbstractWriter.js +160 -166
- package/build/writers/AbstractWriter.js.map +1 -1
- package/build/writers/WriterFactory.js.map +1 -1
- package/junit.xml +7 -0
- package/node_modules/@typescript-eslint/parser/package.json +5 -5
- package/node_modules/@typescript-eslint/scope-manager/dist/ScopeManager.js +1 -1
- package/node_modules/@typescript-eslint/scope-manager/dist/ScopeManager.js.map +1 -1
- package/node_modules/@typescript-eslint/scope-manager/dist/referencer/ClassVisitor.js +1 -1
- package/node_modules/@typescript-eslint/scope-manager/dist/referencer/ClassVisitor.js.map +1 -1
- package/node_modules/@typescript-eslint/scope-manager/dist/referencer/PatternVisitor.d.ts.map +1 -1
- package/node_modules/@typescript-eslint/scope-manager/dist/referencer/PatternVisitor.js +1 -3
- package/node_modules/@typescript-eslint/scope-manager/dist/referencer/PatternVisitor.js.map +1 -1
- package/node_modules/@typescript-eslint/scope-manager/dist/referencer/Referencer.js +2 -2
- package/node_modules/@typescript-eslint/scope-manager/dist/referencer/Referencer.js.map +1 -1
- package/node_modules/@typescript-eslint/scope-manager/package.json +5 -5
- package/node_modules/@typescript-eslint/types/_ts3.4/dist/generated/ast-spec.d.ts +62 -7
- package/node_modules/@typescript-eslint/types/_ts3.4/dist/parser-options.d.ts +6 -2
- package/node_modules/@typescript-eslint/types/dist/generated/ast-spec.d.ts +62 -7
- package/node_modules/@typescript-eslint/types/dist/generated/ast-spec.d.ts.map +1 -1
- package/node_modules/@typescript-eslint/types/dist/generated/ast-spec.js.map +1 -1
- package/node_modules/@typescript-eslint/types/dist/parser-options.d.ts +6 -2
- package/node_modules/@typescript-eslint/types/dist/parser-options.d.ts.map +1 -1
- package/node_modules/@typescript-eslint/types/package.json +4 -4
- package/node_modules/@typescript-eslint/typescript-estree/_ts3.4/dist/clear-caches.d.ts +10 -0
- package/node_modules/@typescript-eslint/typescript-estree/_ts3.4/dist/create-program/describeFilePath.d.ts +2 -0
- package/node_modules/@typescript-eslint/typescript-estree/_ts3.4/dist/create-program/shared.d.ts +7 -1
- package/node_modules/@typescript-eslint/typescript-estree/_ts3.4/dist/index.d.ts +2 -2
- package/node_modules/@typescript-eslint/typescript-estree/_ts3.4/dist/parseSettings/ExpiringCache.d.ts +17 -0
- package/node_modules/@typescript-eslint/typescript-estree/_ts3.4/dist/parseSettings/createParseSettings.d.ts +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/_ts3.4/dist/parseSettings/getProjectConfigFiles.d.ts +12 -0
- package/node_modules/@typescript-eslint/typescript-estree/_ts3.4/dist/parseSettings/index.d.ts +6 -1
- package/node_modules/@typescript-eslint/typescript-estree/_ts3.4/dist/parseSettings/resolveProjectList.d.ts +19 -0
- package/node_modules/@typescript-eslint/typescript-estree/_ts3.4/dist/parser-options.d.ts +22 -3
- package/node_modules/@typescript-eslint/typescript-estree/dist/clear-caches.d.ts +10 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/clear-caches.d.ts.map +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/clear-caches.js +24 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/clear-caches.js.map +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/convert-comments.js +1 -1
- package/node_modules/@typescript-eslint/typescript-estree/dist/convert-comments.js.map +1 -1
- package/node_modules/@typescript-eslint/typescript-estree/dist/convert.d.ts.map +1 -1
- package/node_modules/@typescript-eslint/typescript-estree/dist/convert.js +38 -12
- package/node_modules/@typescript-eslint/typescript-estree/dist/convert.js.map +1 -1
- package/node_modules/@typescript-eslint/typescript-estree/dist/create-program/createProjectProgram.d.ts.map +1 -1
- package/node_modules/@typescript-eslint/typescript-estree/dist/create-program/createProjectProgram.js +5 -10
- package/node_modules/@typescript-eslint/typescript-estree/dist/create-program/createProjectProgram.js.map +1 -1
- package/node_modules/@typescript-eslint/typescript-estree/dist/create-program/describeFilePath.d.ts +2 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/create-program/describeFilePath.d.ts.map +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/create-program/describeFilePath.js +32 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/create-program/describeFilePath.js.map +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/create-program/getWatchProgramsForProjects.d.ts.map +1 -1
- package/node_modules/@typescript-eslint/typescript-estree/dist/create-program/getWatchProgramsForProjects.js +2 -15
- package/node_modules/@typescript-eslint/typescript-estree/dist/create-program/getWatchProgramsForProjects.js.map +1 -1
- package/node_modules/@typescript-eslint/typescript-estree/dist/create-program/shared.d.ts +7 -1
- package/node_modules/@typescript-eslint/typescript-estree/dist/create-program/shared.d.ts.map +1 -1
- package/node_modules/@typescript-eslint/typescript-estree/dist/create-program/shared.js +15 -1
- package/node_modules/@typescript-eslint/typescript-estree/dist/create-program/shared.js.map +1 -1
- package/node_modules/@typescript-eslint/typescript-estree/dist/getModifiers.js +1 -1
- package/node_modules/@typescript-eslint/typescript-estree/dist/getModifiers.js.map +1 -1
- package/node_modules/@typescript-eslint/typescript-estree/dist/index.d.ts +2 -2
- package/node_modules/@typescript-eslint/typescript-estree/dist/index.d.ts.map +1 -1
- package/node_modules/@typescript-eslint/typescript-estree/dist/index.js +2 -4
- package/node_modules/@typescript-eslint/typescript-estree/dist/index.js.map +1 -1
- package/node_modules/@typescript-eslint/typescript-estree/dist/parseSettings/ExpiringCache.d.ts +17 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/parseSettings/ExpiringCache.d.ts.map +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/parseSettings/ExpiringCache.js +62 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/parseSettings/ExpiringCache.js.map +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/parseSettings/createParseSettings.d.ts +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/parseSettings/createParseSettings.d.ts.map +1 -1
- package/node_modules/@typescript-eslint/typescript-estree/dist/parseSettings/createParseSettings.js +22 -48
- package/node_modules/@typescript-eslint/typescript-estree/dist/parseSettings/createParseSettings.js.map +1 -1
- package/node_modules/@typescript-eslint/typescript-estree/dist/parseSettings/getProjectConfigFiles.d.ts +12 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/parseSettings/getProjectConfigFiles.d.ts.map +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/parseSettings/getProjectConfigFiles.js +70 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/parseSettings/getProjectConfigFiles.js.map +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/parseSettings/index.d.ts +6 -1
- package/node_modules/@typescript-eslint/typescript-estree/dist/parseSettings/index.d.ts.map +1 -1
- package/node_modules/@typescript-eslint/typescript-estree/dist/parseSettings/resolveProjectList.d.ts +19 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/parseSettings/resolveProjectList.d.ts.map +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/parseSettings/resolveProjectList.js +103 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/parseSettings/resolveProjectList.js.map +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/parseSettings/warnAboutTSVersion.js +1 -1
- package/node_modules/@typescript-eslint/typescript-estree/dist/parser-options.d.ts +22 -3
- package/node_modules/@typescript-eslint/typescript-estree/dist/parser-options.d.ts.map +1 -1
- package/node_modules/@typescript-eslint/typescript-estree/dist/simple-traverse.js +1 -1
- package/node_modules/@typescript-eslint/typescript-estree/dist/simple-traverse.js.map +1 -1
- package/node_modules/@typescript-eslint/typescript-estree/package.json +4 -5
- package/node_modules/@typescript-eslint/visitor-keys/package.json +3 -3
- package/package.json +592 -597
- package/src/.DS_Store +0 -0
- package/src/__tests__/behavioral/BootingTheCli.test.ts +32 -2
- package/src/__tests__/behavioral/CreatingAConversationTopic.test.ts +1 -1
- package/src/__tests__/behavioral/eventContract/PullingMercuryEventContract.test.ts +1 -1
- package/src/__tests__/behavioral/events/CreatingAnEvent.test.ts +1 -2
- package/src/__tests__/behavioral/permissions/SyncingPermissions.test.ts +11 -0
- package/src/__tests__/behavioral/schemas/GeneratingFieldTypesOnly.test.ts +1 -1
- package/src/__tests__/behavioral/schemas/GettingSchemasFromHealthCheck.test.ts +1 -1
- package/src/__tests__/behavioral/upgrading/UpgradingASkill.test.ts +1 -2
- package/src/__tests__/implementation/TestRunner.test.ts +1 -1
- package/src/boot.ts +92 -0
- package/src/{cli.ts → cli/Cli.ts} +48 -150
- package/src/features/AbstractFeature.ts +1 -1
- package/src/features/FeatureInstaller.ts +3 -3
- package/src/features/error/ParentTestFinder.ts +1 -1
- package/src/features/event/builders/EventContractBuilder.ts +1 -1
- package/src/features/event/stores/EventStore.ts +4 -2
- package/src/features/event/stores/ListenerStore.ts +1 -1
- package/src/features/onboard/ScriptLoader.ts +1 -1
- package/src/features/permission/PermissionFeature.ts +3 -1
- package/src/features/permission/stores/PermissionStore.ts +1 -1
- package/src/features/schema/stores/SchemaStore.ts +1 -1
- package/src/features/schema/utilities/schemaGenerator.utility.ts +1 -1
- package/src/features/skill/SkillFeature.ts +1 -1
- package/src/features/store/stores/StoreStore.ts +1 -1
- package/src/features/test/TestReporter.ts +25 -25
- package/src/features/test/test.types.ts +8 -1
- package/src/features/view/actions/SyncAction.ts +1 -1
- package/src/features/view/actions/WatchAction.ts +8 -3
- package/src/index.ts +1 -1
- package/src/interfaces/SpyInterface.ts +2 -0
- package/src/interfaces/TerminalInterface.ts +5 -1
- package/src/tests/AbstractCliTest.ts +2 -3
- package/src/tests/AbstractSchemaTest.ts +1 -1
- package/src/tests/AbstractSkillTest.ts +1 -1
- package/src/tests/JestJsonParser.ts +4 -1
- package/src/tests/fixtures/FeatureFixture.ts +24 -20
- package/src/tests/fixtures/MercuryFixture.ts +1 -1
- package/src/types/cli.types.ts +30 -0
- package/yarn-error.log +12174 -0
- package/LICENSE +0 -21
- package/build/__tests__/behavioral/events/EverythingInstalledInstaller.d.ts +0 -17
- package/build/__tests__/behavioral/events/EverythingInstalledInstaller.js +0 -137
- package/build/__tests__/behavioral/events/EverythingInstalledInstaller.js.map +0 -1
- package/build/cli.js +0 -690
- package/build/cli.js.map +0 -1
- package/node_modules/@typescript-eslint/typescript-estree/node_modules/globby/gitignore.js +0 -120
- package/node_modules/@typescript-eslint/typescript-estree/node_modules/globby/index.d.ts +0 -186
- package/node_modules/@typescript-eslint/typescript-estree/node_modules/globby/index.js +0 -181
- package/node_modules/@typescript-eslint/typescript-estree/node_modules/globby/license +0 -9
- package/node_modules/@typescript-eslint/typescript-estree/node_modules/globby/package.json +0 -82
- package/node_modules/@typescript-eslint/typescript-estree/node_modules/globby/readme.md +0 -170
- package/node_modules/@typescript-eslint/typescript-estree/node_modules/globby/stream-utils.js +0 -46
- package/src/__tests__/behavioral/events/EverythingInstalledInstaller.ts +0 -46
|
@@ -16,11 +16,11 @@ var _possibleConstructorReturn2 = _interopRequireDefault(require("@babel/runtime
|
|
|
16
16
|
var _getPrototypeOf2 = _interopRequireDefault(require("@babel/runtime/helpers/getPrototypeOf"));
|
|
17
17
|
var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
|
|
18
18
|
var _path = _interopRequireDefault(require("path"));
|
|
19
|
+
var _globby = _interopRequireDefault(require("@sprucelabs/globby"));
|
|
19
20
|
var _schema = require("@sprucelabs/schema");
|
|
20
21
|
var _spruceCoreSchemas = require("@sprucelabs/spruce-core-schemas");
|
|
21
22
|
var _spruceEventUtils = require("@sprucelabs/spruce-event-utils");
|
|
22
23
|
var _spruceSkillUtils = require("@sprucelabs/spruce-skill-utils");
|
|
23
|
-
var _globby = _interopRequireDefault(require("globby"));
|
|
24
24
|
var _lodash = require("lodash");
|
|
25
25
|
var _SpruceError = _interopRequireDefault(require("../../../errors/SpruceError"));
|
|
26
26
|
var _AbstractStore2 = _interopRequireDefault(require("../../../stores/AbstractStore"));
|
|
@@ -65,49 +65,47 @@ var SchemaStore = /*#__PURE__*/function (_AbstractStore) {
|
|
|
65
65
|
var _fetchSchemas = (0, _asyncToGenerator2["default"])( /*#__PURE__*/_regenerator["default"].mark(function _callee(options) {
|
|
66
66
|
var _ref, _ref$localSchemaLooku, localSchemaDir, _ref$shouldFetchLocal, shouldFetchLocalSchemas, _ref$shouldFetchRemot, shouldFetchRemoteSchemas, _ref$shouldEnableVers, shouldEnableVersioning, localNamespace, _ref$shouldFetchCoreS, shouldFetchCoreSchemas, didUpdateHandler, moduleToImportFromWhenRemote, results, _results$errors, locals;
|
|
67
67
|
return _regenerator["default"].wrap(function _callee$(_context) {
|
|
68
|
-
while (1) {
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
namespace: _spruceSkillUtils.CORE_NAMESPACE
|
|
80
|
-
});
|
|
81
|
-
});
|
|
82
|
-
}
|
|
83
|
-
if (!shouldFetchLocalSchemas) {
|
|
84
|
-
_context.next = 10;
|
|
85
|
-
break;
|
|
86
|
-
}
|
|
87
|
-
_context.next = 6;
|
|
88
|
-
return this.loadLocalSchemas(localSchemaDir, localNamespace, shouldEnableVersioning, didUpdateHandler);
|
|
89
|
-
case 6:
|
|
90
|
-
locals = _context.sent;
|
|
91
|
-
if (moduleToImportFromWhenRemote) {
|
|
92
|
-
locals.schemas.forEach(function (local) {
|
|
93
|
-
local.moduleToImportFromWhenRemote = moduleToImportFromWhenRemote;
|
|
68
|
+
while (1) switch (_context.prev = _context.next) {
|
|
69
|
+
case 0:
|
|
70
|
+
_ref = options || {}, _ref$localSchemaLooku = _ref.localSchemaLookupDir, localSchemaDir = _ref$localSchemaLooku === void 0 ? DEFAULT_LOCAL_SCHEMA_DIR : _ref$localSchemaLooku, _ref$shouldFetchLocal = _ref.shouldFetchLocalSchemas, shouldFetchLocalSchemas = _ref$shouldFetchLocal === void 0 ? true : _ref$shouldFetchLocal, _ref$shouldFetchRemot = _ref.shouldFetchRemoteSchemas, shouldFetchRemoteSchemas = _ref$shouldFetchRemot === void 0 ? true : _ref$shouldFetchRemot, _ref$shouldEnableVers = _ref.shouldEnableVersioning, shouldEnableVersioning = _ref$shouldEnableVers === void 0 ? true : _ref$shouldEnableVers, localNamespace = _ref.localNamespace, _ref$shouldFetchCoreS = _ref.shouldFetchCoreSchemas, shouldFetchCoreSchemas = _ref$shouldFetchCoreS === void 0 ? true : _ref$shouldFetchCoreS, didUpdateHandler = _ref.didUpdateHandler, moduleToImportFromWhenRemote = _ref.moduleToImportFromWhenRemote;
|
|
71
|
+
results = {
|
|
72
|
+
errors: [],
|
|
73
|
+
schemasByNamespace: {}
|
|
74
|
+
};
|
|
75
|
+
if (shouldFetchCoreSchemas) {
|
|
76
|
+
results.schemasByNamespace[_spruceSkillUtils.CORE_NAMESPACE] = Object.values(coreSchemas).map(function (schema) {
|
|
77
|
+
return _objectSpread(_objectSpread({}, schema), {}, {
|
|
78
|
+
namespace: _spruceSkillUtils.CORE_NAMESPACE
|
|
94
79
|
});
|
|
95
|
-
}
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
80
|
+
});
|
|
81
|
+
}
|
|
82
|
+
if (!shouldFetchLocalSchemas) {
|
|
83
|
+
_context.next = 10;
|
|
84
|
+
break;
|
|
85
|
+
}
|
|
86
|
+
_context.next = 6;
|
|
87
|
+
return this.loadLocalSchemas(localSchemaDir, localNamespace, shouldEnableVersioning, didUpdateHandler);
|
|
88
|
+
case 6:
|
|
89
|
+
locals = _context.sent;
|
|
90
|
+
if (moduleToImportFromWhenRemote) {
|
|
91
|
+
locals.schemas.forEach(function (local) {
|
|
92
|
+
local.moduleToImportFromWhenRemote = moduleToImportFromWhenRemote;
|
|
93
|
+
});
|
|
94
|
+
}
|
|
95
|
+
results.schemasByNamespace[localNamespace] = locals.schemas;
|
|
96
|
+
(_results$errors = results.errors).push.apply(_results$errors, (0, _toConsumableArray2["default"])(locals.errors));
|
|
97
|
+
case 10:
|
|
98
|
+
if (!shouldFetchRemoteSchemas) {
|
|
103
99
|
_context.next = 13;
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
100
|
+
break;
|
|
101
|
+
}
|
|
102
|
+
_context.next = 13;
|
|
103
|
+
return this.emitDidFetchSchemasAndMixinResults(localNamespace, results);
|
|
104
|
+
case 13:
|
|
105
|
+
return _context.abrupt("return", results);
|
|
106
|
+
case 14:
|
|
107
|
+
case "end":
|
|
108
|
+
return _context.stop();
|
|
111
109
|
}
|
|
112
110
|
}, _callee, this);
|
|
113
111
|
}));
|
|
@@ -123,34 +121,32 @@ var SchemaStore = /*#__PURE__*/function (_AbstractStore) {
|
|
|
123
121
|
var _this2 = this;
|
|
124
122
|
var schemas, _namespace, remoteResults, _eventResponseUtil$ge, payloads, errors, _results$errors2;
|
|
125
123
|
return _regenerator["default"].wrap(function _callee2$(_context2) {
|
|
126
|
-
while (1) {
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
_this2.mixinSchemaOrThrowIfExists(schema, localNamespace, results);
|
|
147
|
-
});
|
|
124
|
+
while (1) switch (_context2.prev = _context2.next) {
|
|
125
|
+
case 0:
|
|
126
|
+
schemas = [];
|
|
127
|
+
for (_namespace in results.schemasByNamespace) {
|
|
128
|
+
schemas.push.apply(schemas, (0, _toConsumableArray2["default"])(results.schemasByNamespace[_namespace]));
|
|
129
|
+
}
|
|
130
|
+
_context2.next = 4;
|
|
131
|
+
return this.emitter.emit('schema.did-fetch-schemas', {
|
|
132
|
+
schemas: schemas
|
|
133
|
+
});
|
|
134
|
+
case 4:
|
|
135
|
+
remoteResults = _context2.sent;
|
|
136
|
+
_eventResponseUtil$ge = _spruceEventUtils.eventResponseUtil.getAllResponsePayloadsAndErrors(remoteResults, _SpruceError["default"]), payloads = _eventResponseUtil$ge.payloads, errors = _eventResponseUtil$ge.errors;
|
|
137
|
+
if (errors && errors.length > 0) {
|
|
138
|
+
(_results$errors2 = results.errors).push.apply(_results$errors2, (0, _toConsumableArray2["default"])(errors));
|
|
139
|
+
} else {
|
|
140
|
+
payloads.forEach(function (payload) {
|
|
141
|
+
var _payload$schemas;
|
|
142
|
+
payload === null || payload === void 0 ? void 0 : (_payload$schemas = payload.schemas) === null || _payload$schemas === void 0 ? void 0 : _payload$schemas.forEach(function (schema) {
|
|
143
|
+
_this2.mixinSchemaOrThrowIfExists(schema, localNamespace, results);
|
|
148
144
|
});
|
|
149
|
-
}
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
145
|
+
});
|
|
146
|
+
}
|
|
147
|
+
case 7:
|
|
148
|
+
case "end":
|
|
149
|
+
return _context2.stop();
|
|
154
150
|
}
|
|
155
151
|
}, _callee2, this);
|
|
156
152
|
}));
|
|
@@ -181,18 +177,16 @@ var SchemaStore = /*#__PURE__*/function (_AbstractStore) {
|
|
|
181
177
|
var _hasLocalSchemas = (0, _asyncToGenerator2["default"])( /*#__PURE__*/_regenerator["default"].mark(function _callee3() {
|
|
182
178
|
var matches;
|
|
183
179
|
return _regenerator["default"].wrap(function _callee3$(_context3) {
|
|
184
|
-
while (1) {
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
return _context3.stop();
|
|
195
|
-
}
|
|
180
|
+
while (1) switch (_context3.prev = _context3.next) {
|
|
181
|
+
case 0:
|
|
182
|
+
_context3.next = 2;
|
|
183
|
+
return this.globbyLocalBuilders(DEFAULT_LOCAL_SCHEMA_DIR);
|
|
184
|
+
case 2:
|
|
185
|
+
matches = _context3.sent;
|
|
186
|
+
return _context3.abrupt("return", matches.length > 0);
|
|
187
|
+
case 4:
|
|
188
|
+
case "end":
|
|
189
|
+
return _context3.stop();
|
|
196
190
|
}
|
|
197
191
|
}, _callee3, this);
|
|
198
192
|
}));
|
|
@@ -207,58 +201,56 @@ var SchemaStore = /*#__PURE__*/function (_AbstractStore) {
|
|
|
207
201
|
var _loadLocalSchemas = (0, _asyncToGenerator2["default"])( /*#__PURE__*/_regenerator["default"].mark(function _callee4(localLookupDir, localNamespace, shouldEnableVersioning, didUpdateHandler) {
|
|
208
202
|
var localMatches, errors, schemas, importer, imported, c, local, schema, version, _err$options$file, _err$options, _err$originalError, _err$options$file2, _err$options2, _err$originalError2;
|
|
209
203
|
return _regenerator["default"].wrap(function _callee4$(_context4) {
|
|
210
|
-
while (1) {
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
schemas.push(schema);
|
|
234
|
-
}
|
|
235
|
-
} catch (err) {
|
|
236
|
-
errors.push(new _SpruceError["default"]({
|
|
237
|
-
code: 'SCHEMA_FAILED_TO_IMPORT',
|
|
238
|
-
file: (_err$options$file = err === null || err === void 0 ? void 0 : (_err$options = err.options) === null || _err$options === void 0 ? void 0 : _err$options.file) !== null && _err$options$file !== void 0 ? _err$options$file : '**UNKNOWN**',
|
|
239
|
-
originalError: (_err$originalError = err === null || err === void 0 ? void 0 : err.originalError) !== null && _err$originalError !== void 0 ? _err$originalError : err
|
|
240
|
-
}));
|
|
204
|
+
while (1) switch (_context4.prev = _context4.next) {
|
|
205
|
+
case 0:
|
|
206
|
+
_context4.next = 2;
|
|
207
|
+
return this.globbyLocalBuilders(localLookupDir);
|
|
208
|
+
case 2:
|
|
209
|
+
localMatches = _context4.sent;
|
|
210
|
+
errors = [];
|
|
211
|
+
schemas = [];
|
|
212
|
+
didUpdateHandler === null || didUpdateHandler === void 0 ? void 0 : didUpdateHandler("Starting import of ".concat(localMatches.length, " schema builders..."));
|
|
213
|
+
_context4.prev = 6;
|
|
214
|
+
importer = this.Service('import');
|
|
215
|
+
_context4.next = 10;
|
|
216
|
+
return importer.bulkImport(localMatches);
|
|
217
|
+
case 10:
|
|
218
|
+
imported = _context4.sent;
|
|
219
|
+
for (c = 0; c < localMatches.length; c++) {
|
|
220
|
+
try {
|
|
221
|
+
local = localMatches[c];
|
|
222
|
+
schema = imported[c];
|
|
223
|
+
version = this.resolveLocalVersion(shouldEnableVersioning, local, errors);
|
|
224
|
+
if (version || shouldEnableVersioning === false) {
|
|
225
|
+
schema = this.prepareLocalSchema(schema, localNamespace, version, didUpdateHandler);
|
|
226
|
+
schemas.push(schema);
|
|
241
227
|
}
|
|
228
|
+
} catch (err) {
|
|
229
|
+
errors.push(new _SpruceError["default"]({
|
|
230
|
+
code: 'SCHEMA_FAILED_TO_IMPORT',
|
|
231
|
+
file: (_err$options$file = err === null || err === void 0 ? void 0 : (_err$options = err.options) === null || _err$options === void 0 ? void 0 : _err$options.file) !== null && _err$options$file !== void 0 ? _err$options$file : '**UNKNOWN**',
|
|
232
|
+
originalError: (_err$originalError = err === null || err === void 0 ? void 0 : err.originalError) !== null && _err$originalError !== void 0 ? _err$originalError : err
|
|
233
|
+
}));
|
|
242
234
|
}
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
235
|
+
}
|
|
236
|
+
_context4.next = 17;
|
|
237
|
+
break;
|
|
238
|
+
case 14:
|
|
239
|
+
_context4.prev = 14;
|
|
240
|
+
_context4.t0 = _context4["catch"](6);
|
|
241
|
+
throw new _SpruceError["default"]({
|
|
242
|
+
code: 'SCHEMA_FAILED_TO_IMPORT',
|
|
243
|
+
file: (_err$options$file2 = _context4.t0 === null || _context4.t0 === void 0 ? void 0 : (_err$options2 = _context4.t0.options) === null || _err$options2 === void 0 ? void 0 : _err$options2.file) !== null && _err$options$file2 !== void 0 ? _err$options$file2 : '**UNKNOWN**',
|
|
244
|
+
originalError: (_err$originalError2 = _context4.t0 === null || _context4.t0 === void 0 ? void 0 : _context4.t0.originalError) !== null && _err$originalError2 !== void 0 ? _err$originalError2 : _context4.t0
|
|
245
|
+
});
|
|
246
|
+
case 17:
|
|
247
|
+
return _context4.abrupt("return", {
|
|
248
|
+
schemas: schemas,
|
|
249
|
+
errors: errors
|
|
250
|
+
});
|
|
251
|
+
case 18:
|
|
252
|
+
case "end":
|
|
253
|
+
return _context4.stop();
|
|
262
254
|
}
|
|
263
255
|
}, _callee4, this, [[6, 14]]);
|
|
264
256
|
}));
|
|
@@ -272,17 +264,15 @@ var SchemaStore = /*#__PURE__*/function (_AbstractStore) {
|
|
|
272
264
|
value: function () {
|
|
273
265
|
var _globbyLocalBuilders = (0, _asyncToGenerator2["default"])( /*#__PURE__*/_regenerator["default"].mark(function _callee5(localLookupDir) {
|
|
274
266
|
return _regenerator["default"].wrap(function _callee5$(_context5) {
|
|
275
|
-
while (1) {
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
return _context5.stop();
|
|
285
|
-
}
|
|
267
|
+
while (1) switch (_context5.prev = _context5.next) {
|
|
268
|
+
case 0:
|
|
269
|
+
_context5.next = 2;
|
|
270
|
+
return (0, _globby["default"])(_spruceSkillUtils.diskUtil.resolvePath(this.cwd, localLookupDir, '**/*.builder.[t|j]s'));
|
|
271
|
+
case 2:
|
|
272
|
+
return _context5.abrupt("return", _context5.sent);
|
|
273
|
+
case 3:
|
|
274
|
+
case "end":
|
|
275
|
+
return _context5.stop();
|
|
286
276
|
}
|
|
287
277
|
}, _callee5, this);
|
|
288
278
|
}));
|
|
@@ -336,84 +326,80 @@ var SchemaStore = /*#__PURE__*/function (_AbstractStore) {
|
|
|
336
326
|
var _this3 = this;
|
|
337
327
|
var _ref2, localAddonsDir, coreAddons, localErrors, localAddons, allFields;
|
|
338
328
|
return _regenerator["default"].wrap(function _callee7$(_context7) {
|
|
339
|
-
while (1) {
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
_context7.next = 7;
|
|
352
|
-
break;
|
|
353
|
-
}
|
|
354
|
-
_context7.t0 = [];
|
|
355
|
-
_context7.next = 14;
|
|
329
|
+
while (1) switch (_context7.prev = _context7.next) {
|
|
330
|
+
case 0:
|
|
331
|
+
_ref2 = options || {}, localAddonsDir = _ref2.localAddonsDir;
|
|
332
|
+
coreAddons = _schema.fieldRegistrations.map(function (registration) {
|
|
333
|
+
return {
|
|
334
|
+
registration: registration,
|
|
335
|
+
isLocal: false
|
|
336
|
+
};
|
|
337
|
+
});
|
|
338
|
+
localErrors = [];
|
|
339
|
+
if (localAddonsDir) {
|
|
340
|
+
_context7.next = 7;
|
|
356
341
|
break;
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
|
|
396
|
-
|
|
397
|
-
|
|
398
|
-
|
|
399
|
-
|
|
400
|
-
|
|
401
|
-
|
|
402
|
-
|
|
403
|
-
|
|
404
|
-
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
return
|
|
410
|
-
|
|
411
|
-
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
|
|
342
|
+
}
|
|
343
|
+
_context7.t0 = [];
|
|
344
|
+
_context7.next = 14;
|
|
345
|
+
break;
|
|
346
|
+
case 7:
|
|
347
|
+
_context7.t1 = Promise;
|
|
348
|
+
_context7.next = 10;
|
|
349
|
+
return (0, _globby["default"])([_path["default"].join(localAddonsDir, '/*Field.addon.[t|j]s')]);
|
|
350
|
+
case 10:
|
|
351
|
+
_context7.t2 = _context7.sent.map( /*#__PURE__*/function () {
|
|
352
|
+
var _ref3 = (0, _asyncToGenerator2["default"])( /*#__PURE__*/_regenerator["default"].mark(function _callee6(file) {
|
|
353
|
+
var importService, registration;
|
|
354
|
+
return _regenerator["default"].wrap(function _callee6$(_context6) {
|
|
355
|
+
while (1) switch (_context6.prev = _context6.next) {
|
|
356
|
+
case 0:
|
|
357
|
+
_context6.prev = 0;
|
|
358
|
+
importService = _this3.Service('import');
|
|
359
|
+
_context6.next = 4;
|
|
360
|
+
return importService.importDefault(file);
|
|
361
|
+
case 4:
|
|
362
|
+
registration = _context6.sent;
|
|
363
|
+
return _context6.abrupt("return", {
|
|
364
|
+
path: file,
|
|
365
|
+
registration: registration,
|
|
366
|
+
isLocal: true
|
|
367
|
+
});
|
|
368
|
+
case 8:
|
|
369
|
+
_context6.prev = 8;
|
|
370
|
+
_context6.t0 = _context6["catch"](0);
|
|
371
|
+
localErrors.push(new _SpruceError["default"]({
|
|
372
|
+
code: 'FAILED_TO_IMPORT',
|
|
373
|
+
file: file,
|
|
374
|
+
originalError: _context6.t0
|
|
375
|
+
}));
|
|
376
|
+
return _context6.abrupt("return", false);
|
|
377
|
+
case 12:
|
|
378
|
+
case "end":
|
|
379
|
+
return _context6.stop();
|
|
380
|
+
}
|
|
381
|
+
}, _callee6, null, [[0, 8]]);
|
|
382
|
+
}));
|
|
383
|
+
return function (_x10) {
|
|
384
|
+
return _ref3.apply(this, arguments);
|
|
385
|
+
};
|
|
386
|
+
}());
|
|
387
|
+
_context7.next = 13;
|
|
388
|
+
return _context7.t1.all.call(_context7.t1, _context7.t2);
|
|
389
|
+
case 13:
|
|
390
|
+
_context7.t0 = _context7.sent;
|
|
391
|
+
case 14:
|
|
392
|
+
localAddons = _context7.t0;
|
|
393
|
+
allFields = (0, _lodash.uniqBy)([].concat((0, _toConsumableArray2["default"])(coreAddons), (0, _toConsumableArray2["default"])(localAddons.filter(function (addon) {
|
|
394
|
+
return !!addon;
|
|
395
|
+
}))), 'registration.type');
|
|
396
|
+
return _context7.abrupt("return", {
|
|
397
|
+
fields: allFields,
|
|
398
|
+
errors: localErrors
|
|
399
|
+
});
|
|
400
|
+
case 17:
|
|
401
|
+
case "end":
|
|
402
|
+
return _context7.stop();
|
|
417
403
|
}
|
|
418
404
|
}, _callee7);
|
|
419
405
|
}));
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SchemaStore.js","names":["coreSchemas","personSchema","skillSchema","skillCreatorSchema","locationSchema","organizationSchema","personOrganizationSchema","personLocationSchema","roleSchema","messageSchema","messageSourceSchema","messageTargetSchema","sendMessageSchema","choiceSchema","linkSchema","DEFAULT_LOCAL_SCHEMA_DIR","SchemaStore","options","localSchemaLookupDir","localSchemaDir","shouldFetchLocalSchemas","shouldFetchRemoteSchemas","shouldEnableVersioning","localNamespace","shouldFetchCoreSchemas","didUpdateHandler","moduleToImportFromWhenRemote","results","errors","schemasByNamespace","CORE_NAMESPACE","Object","values","map","schema","namespace","loadLocalSchemas","locals","schemas","forEach","local","push","emitDidFetchSchemasAndMixinResults","emitter","emit","remoteResults","eventResponseUtil","getAllResponsePayloadsAndErrors","SpruceError","payloads","length","payload","mixinSchemaOrThrowIfExists","idWithVersion","normalizeSchemaToIdWithVersion","match","find","s","isEqual","globbyLocalBuilders","matches","localLookupDir","localMatches","importer","Service","bulkImport","imported","c","version","resolveLocalVersion","prepareLocalSchema","err","code","file","originalError","globby","diskUtil","resolvePath","cwd","undefined","versionUtil","extractVersion","constValue","friendlyMessage","generateVersion","dirValue","SchemaError","schemaId","id","localAddonsDir","coreAddons","fieldRegistrations","registration","isLocal","localErrors","Promise","pathUtil","join","importService","importDefault","path","all","localAddons","allFields","uniqBy","filter","addon","fields","AbstractStore"],"sources":["../../../../src/features/schema/stores/SchemaStore.ts"],"sourcesContent":["import pathUtil from 'path'\nimport {\n\tSchema,\n\tFieldRegistration,\n\tfieldRegistrations,\n\tnormalizeSchemaToIdWithVersion,\n\tSchemaError,\n} from '@sprucelabs/schema'\nimport {\n\tpersonSchema,\n\tskillSchema,\n\tskillCreatorSchema,\n\tlocationSchema,\n\torganizationSchema,\n\tpersonOrganizationSchema,\n\tpersonLocationSchema,\n\troleSchema,\n\tmessageSchema,\n\tmessageSourceSchema,\n\tmessageTargetSchema,\n\tsendMessageSchema,\n\tchoiceSchema,\n\tlinkSchema,\n} from '@sprucelabs/spruce-core-schemas'\nimport { eventResponseUtil } from '@sprucelabs/spruce-event-utils'\nimport { versionUtil } from '@sprucelabs/spruce-skill-utils'\nimport { diskUtil } from '@sprucelabs/spruce-skill-utils'\nimport { CORE_NAMESPACE } from '@sprucelabs/spruce-skill-utils'\nimport globby from 'globby'\nimport { isEqual, uniqBy } from 'lodash'\nimport SpruceError from '../../../errors/SpruceError'\nimport AbstractStore from '../../../stores/AbstractStore'\nimport { InternalUpdateHandler } from '../../../types/cli.types'\n\nexport const coreSchemas = {\n\tpersonSchema,\n\tskillSchema,\n\tskillCreatorSchema,\n\tlocationSchema,\n\torganizationSchema,\n\tpersonOrganizationSchema,\n\tpersonLocationSchema,\n\troleSchema,\n\tmessageSchema,\n\tmessageSourceSchema,\n\tmessageTargetSchema,\n\tsendMessageSchema,\n\tchoiceSchema,\n\tlinkSchema,\n}\n\ninterface AddonItem {\n\tpath: string\n\tregistration: FieldRegistration\n\tisLocal: boolean\n}\n\nexport interface SchemasByNamespace {\n\t[namespace: string]: Schema[]\n}\n\ninterface FetchSchemasResults {\n\tschemasByNamespace: SchemasByNamespace\n\terrors: SpruceError[]\n}\nexport interface FetchedField {\n\tpath?: string\n\tregistration: FieldRegistration\n\tisLocal: boolean\n}\n\ninterface FetchFieldsResults {\n\terrors: SpruceError[]\n\tfields: FetchedField[]\n}\n\nconst DEFAULT_LOCAL_SCHEMA_DIR = 'src/schemas'\n\nexport default class SchemaStore extends AbstractStore {\n\tpublic readonly name = 'schema'\n\n\tpublic async fetchSchemas(options: {\n\t\tlocalSchemaLookupDir?: string\n\t\tshouldFetchRemoteSchemas?: boolean\n\t\tshouldEnableVersioning?: boolean\n\t\tlocalNamespace: string\n\t\tshouldFetchCoreSchemas?: boolean\n\t\tmoduleToImportFromWhenRemote?: string\n\t\tshouldFetchLocalSchemas?: boolean\n\t\tdidUpdateHandler?: InternalUpdateHandler\n\t}): Promise<FetchSchemasResults> {\n\t\tconst {\n\t\t\tlocalSchemaLookupDir: localSchemaDir = DEFAULT_LOCAL_SCHEMA_DIR,\n\t\t\tshouldFetchLocalSchemas = true,\n\t\t\tshouldFetchRemoteSchemas = true,\n\t\t\tshouldEnableVersioning = true,\n\t\t\tlocalNamespace,\n\t\t\tshouldFetchCoreSchemas = true,\n\t\t\tdidUpdateHandler,\n\t\t\tmoduleToImportFromWhenRemote,\n\t\t} = options || {}\n\n\t\tconst results: FetchSchemasResults = {\n\t\t\terrors: [],\n\t\t\tschemasByNamespace: {},\n\t\t}\n\n\t\tif (shouldFetchCoreSchemas) {\n\t\t\tresults.schemasByNamespace[CORE_NAMESPACE] = Object.values(\n\t\t\t\tcoreSchemas\n\t\t\t).map((schema) => ({\n\t\t\t\t...schema,\n\t\t\t\tnamespace: CORE_NAMESPACE,\n\t\t\t}))\n\t\t}\n\n\t\tif (shouldFetchLocalSchemas) {\n\t\t\tconst locals = await this.loadLocalSchemas(\n\t\t\t\tlocalSchemaDir,\n\t\t\t\tlocalNamespace,\n\t\t\t\tshouldEnableVersioning,\n\t\t\t\tdidUpdateHandler\n\t\t\t)\n\n\t\t\tif (moduleToImportFromWhenRemote) {\n\t\t\t\tlocals.schemas.forEach((local) => {\n\t\t\t\t\tlocal.moduleToImportFromWhenRemote = moduleToImportFromWhenRemote\n\t\t\t\t})\n\t\t\t}\n\n\t\t\tresults.schemasByNamespace[localNamespace] = locals.schemas\n\t\t\tresults.errors.push(...locals.errors)\n\t\t}\n\n\t\tif (shouldFetchRemoteSchemas) {\n\t\t\tawait this.emitDidFetchSchemasAndMixinResults(localNamespace, results)\n\t\t}\n\n\t\treturn results\n\t}\n\n\tprivate async emitDidFetchSchemasAndMixinResults(\n\t\tlocalNamespace: string,\n\t\tresults: FetchSchemasResults\n\t) {\n\t\tconst schemas: Schema[] = []\n\t\tfor (const namespace in results.schemasByNamespace) {\n\t\t\tschemas.push(...results.schemasByNamespace[namespace])\n\t\t}\n\n\t\tconst remoteResults = await this.emitter.emit('schema.did-fetch-schemas', {\n\t\t\tschemas,\n\t\t})\n\n\t\tconst { payloads, errors } =\n\t\t\teventResponseUtil.getAllResponsePayloadsAndErrors(\n\t\t\t\tremoteResults,\n\t\t\t\tSpruceError\n\t\t\t)\n\n\t\tif (errors && errors.length > 0) {\n\t\t\tresults.errors.push(...errors)\n\t\t} else {\n\t\t\tpayloads.forEach((payload) => {\n\t\t\t\tpayload?.schemas?.forEach((schema: Schema) => {\n\t\t\t\t\tthis.mixinSchemaOrThrowIfExists(schema, localNamespace, results)\n\t\t\t\t})\n\t\t\t})\n\t\t}\n\t}\n\n\tprivate mixinSchemaOrThrowIfExists(\n\t\tschema: Schema,\n\t\tlocalNamespace: string,\n\t\tresults: FetchSchemasResults\n\t) {\n\t\tconst namespace = schema.namespace ?? localNamespace\n\n\t\tif (!results.schemasByNamespace[namespace]) {\n\t\t\tresults.schemasByNamespace[namespace] = []\n\t\t}\n\n\t\tconst idWithVersion = normalizeSchemaToIdWithVersion(schema)\n\t\tconst match = results.schemasByNamespace[namespace].find((s) =>\n\t\t\tisEqual(normalizeSchemaToIdWithVersion(s), idWithVersion)\n\t\t)\n\n\t\tif (!match) {\n\t\t\tresults.schemasByNamespace[namespace].push(schema)\n\t\t}\n\t}\n\n\tpublic async hasLocalSchemas() {\n\t\tconst matches = await this.globbyLocalBuilders(DEFAULT_LOCAL_SCHEMA_DIR)\n\t\treturn matches.length > 0\n\t}\n\n\tprivate async loadLocalSchemas(\n\t\tlocalLookupDir: string,\n\t\tlocalNamespace: string,\n\t\tshouldEnableVersioning?: boolean,\n\t\tdidUpdateHandler?: InternalUpdateHandler\n\t) {\n\t\tconst localMatches = await this.globbyLocalBuilders(localLookupDir)\n\n\t\tconst errors: SpruceError[] = []\n\t\tconst schemas: Schema[] = []\n\n\t\tdidUpdateHandler?.(\n\t\t\t`Starting import of ${localMatches.length} schema builders...`\n\t\t)\n\n\t\ttry {\n\t\t\tconst importer = this.Service('import')\n\t\t\tconst imported = await importer.bulkImport(localMatches)\n\n\t\t\tfor (let c = 0; c < localMatches.length; c++) {\n\t\t\t\ttry {\n\t\t\t\t\tconst local = localMatches[c]\n\t\t\t\t\tlet schema = imported[c]\n\n\t\t\t\t\tlet version: undefined | string = this.resolveLocalVersion(\n\t\t\t\t\t\tshouldEnableVersioning,\n\t\t\t\t\t\tlocal,\n\t\t\t\t\t\terrors\n\t\t\t\t\t)\n\t\t\t\t\tif (version || shouldEnableVersioning === false) {\n\t\t\t\t\t\tschema = this.prepareLocalSchema(\n\t\t\t\t\t\t\tschema,\n\t\t\t\t\t\t\tlocalNamespace,\n\t\t\t\t\t\t\tversion,\n\t\t\t\t\t\t\tdidUpdateHandler\n\t\t\t\t\t\t)\n\t\t\t\t\t\tschemas.push(schema)\n\t\t\t\t\t}\n\t\t\t\t} catch (err: any) {\n\t\t\t\t\terrors.push(\n\t\t\t\t\t\tnew SpruceError({\n\t\t\t\t\t\t\tcode: 'SCHEMA_FAILED_TO_IMPORT',\n\t\t\t\t\t\t\tfile: err?.options?.file ?? '**UNKNOWN**',\n\t\t\t\t\t\t\toriginalError: err?.originalError ?? err,\n\t\t\t\t\t\t})\n\t\t\t\t\t)\n\t\t\t\t}\n\t\t\t}\n\t\t} catch (err: any) {\n\t\t\tthrow new SpruceError({\n\t\t\t\tcode: 'SCHEMA_FAILED_TO_IMPORT',\n\t\t\t\tfile: err?.options?.file ?? '**UNKNOWN**',\n\t\t\t\toriginalError: err?.originalError ?? err,\n\t\t\t})\n\t\t}\n\n\t\treturn {\n\t\t\tschemas,\n\t\t\terrors,\n\t\t}\n\t}\n\n\tprivate async globbyLocalBuilders(localLookupDir: string) {\n\t\treturn await globby(\n\t\t\tdiskUtil.resolvePath(this.cwd, localLookupDir, '**/*.builder.[t|j]s')\n\t\t)\n\t}\n\n\tprivate resolveLocalVersion(\n\t\tshouldEnableVersioning: boolean | undefined,\n\t\tlocal: string,\n\t\terrors: SpruceError[]\n\t) {\n\t\tlet version: undefined | string\n\n\t\ttry {\n\t\t\tversion =\n\t\t\t\tshouldEnableVersioning === false\n\t\t\t\t\t? undefined\n\t\t\t\t\t: versionUtil.extractVersion(this.cwd, local).constValue\n\t\t} catch (err) {\n\t\t\terrors.push(\n\t\t\t\tnew SpruceError({\n\t\t\t\t\t// @ts-ignore\n\t\t\t\t\tcode: 'VERSION_MISSING',\n\t\t\t\t\tfriendlyMessage: `It looks like your schema's are not versioned. Make sure schemas are in a directory like src/schemas/${\n\t\t\t\t\t\tversionUtil.generateVersion().dirValue\n\t\t\t\t\t}/*.ts`,\n\t\t\t\t})\n\t\t\t)\n\t\t}\n\t\treturn version\n\t}\n\n\tprivate prepareLocalSchema(\n\t\tschema: Schema,\n\t\tlocalNamespace: string,\n\t\tversion: string | undefined,\n\t\tdidUpdateHandler: InternalUpdateHandler | undefined\n\t) {\n\t\tlet errors: string[] = []\n\n\t\tif (schema.version) {\n\t\t\terrors.push('version_should_not_be_set')\n\t\t}\n\n\t\tif (schema.namespace) {\n\t\t\terrors.push('namespace_should_not_be_set')\n\t\t}\n\n\t\tschema.namespace = localNamespace\n\n\t\tif (errors.length > 0) {\n\t\t\tthrow new SchemaError({\n\t\t\t\tcode: 'INVALID_SCHEMA',\n\t\t\t\tschemaId: schema.id,\n\t\t\t\terrors,\n\t\t\t\tfriendlyMessage:\n\t\t\t\t\t'You should not set a namespace nor version in your schema builder.',\n\t\t\t})\n\t\t}\n\n\t\tschema.version = version\n\n\t\tdidUpdateHandler?.(`Imported ${schema.id} builder.`)\n\n\t\treturn schema\n\t}\n\n\tpublic async fetchFields(options?: {\n\t\tlocalAddonsDir?: string\n\t}): Promise<FetchFieldsResults> {\n\t\tconst { localAddonsDir } = options || {}\n\n\t\tconst coreAddons = fieldRegistrations.map((registration) => {\n\t\t\treturn {\n\t\t\t\tregistration,\n\t\t\t\tisLocal: false,\n\t\t\t}\n\t\t})\n\n\t\tconst localErrors: SpruceError[] = []\n\n\t\tconst localAddons = !localAddonsDir\n\t\t\t? []\n\t\t\t: await Promise.all(\n\t\t\t\t\t(\n\t\t\t\t\t\tawait globby([\n\t\t\t\t\t\t\tpathUtil.join(localAddonsDir, '/*Field.addon.[t|j]s'),\n\t\t\t\t\t\t])\n\t\t\t\t\t).map(async (file: string) => {\n\t\t\t\t\t\ttry {\n\t\t\t\t\t\t\tconst importService = this.Service('import')\n\t\t\t\t\t\t\tconst registration =\n\t\t\t\t\t\t\t\tawait importService.importDefault<FieldRegistration>(file)\n\n\t\t\t\t\t\t\treturn {\n\t\t\t\t\t\t\t\tpath: file,\n\t\t\t\t\t\t\t\tregistration,\n\t\t\t\t\t\t\t\tisLocal: true,\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t} catch (err: any) {\n\t\t\t\t\t\t\tlocalErrors.push(\n\t\t\t\t\t\t\t\tnew SpruceError({\n\t\t\t\t\t\t\t\t\tcode: 'FAILED_TO_IMPORT',\n\t\t\t\t\t\t\t\t\tfile,\n\t\t\t\t\t\t\t\t\toriginalError: err,\n\t\t\t\t\t\t\t\t})\n\t\t\t\t\t\t\t)\n\t\t\t\t\t\t\treturn false\n\t\t\t\t\t\t}\n\t\t\t\t\t})\n\t\t\t )\n\n\t\tconst allFields = uniqBy(\n\t\t\t[\n\t\t\t\t...coreAddons,\n\t\t\t\t...(localAddons.filter((addon) => !!addon) as AddonItem[]),\n\t\t\t],\n\t\t\t'registration.type'\n\t\t)\n\n\t\treturn {\n\t\t\tfields: allFields,\n\t\t\terrors: localErrors,\n\t\t}\n\t}\n}\n"],"mappings":";;;;;;;;;;;;;;;;;AAAA;AACA;AAOA;AAgBA;AACA;AAGA;AACA;AACA;AACA;AAAyD;AAAA;AAAA;AAAA;AAGlD,IAAMA,WAAW,GAAG;EAC1BC,YAAY,EAAZA,+BAAY;EACZC,WAAW,EAAXA,8BAAW;EACXC,kBAAkB,EAAlBA,qCAAkB;EAClBC,cAAc,EAAdA,iCAAc;EACdC,kBAAkB,EAAlBA,qCAAkB;EAClBC,wBAAwB,EAAxBA,2CAAwB;EACxBC,oBAAoB,EAApBA,uCAAoB;EACpBC,UAAU,EAAVA,6BAAU;EACVC,aAAa,EAAbA,gCAAa;EACbC,mBAAmB,EAAnBA,sCAAmB;EACnBC,mBAAmB,EAAnBA,sCAAmB;EACnBC,iBAAiB,EAAjBA,oCAAiB;EACjBC,YAAY,EAAZA,+BAAY;EACZC,UAAU,EAAVA;AAC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AC;cAAA;gBAAA,8BACDxD,GAAG;kBAAA,0FAAC,kBAAOwC,IAAY;oBAAA;oBAAA;sBAAA;wBAAA;0BAAA;4BAAA;4BAEjByB,aAAa,GAAG,MAAI,CAAClC,OAAO,CAAC,QAAQ,CAAC;4BAAA;4BAAA,OAErCkC,aAAa,CAACC,aAAa,CAAoB1B,IAAI,CAAC;0BAAA;4BADrDmB,YAAY;4BAAA,kCAGX;8BACNQ,IAAI,EAAE3B,IAAI;8BACVmB,YAAY,EAAZA,YAAY;8BACZC,OAAO,EAAE;4BACV,CAAC;0BAAA;4BAAA;4BAAA;4BAEDC,WAAW,CAACrD,IAAI,CACf,IAAIO,uBAAW,CAAC;8BACfwB,IAAI,EAAE,kBAAkB;8BACxBC,IAAI,EAAJA,IAAI;8BACJC,aAAa;4BACd,CAAC,CAAC,CACF;4BAAA,kCACM,KAAK;0BAAA;0BAAA;4BAAA;wBAAA;sBAAA;oBAAA;kBAAA,CAEb;kBAAA;oBAAA;kBAAA;gBAAA;gBAAA;gBAAA,oBA1Ba2B,GAAG;cAAA;gBAAA;cAAA;gBAFdC,WAAW;gBA+BXC,SAAS,GAAG,IAAAC,cAAM,gDAEnBd,UAAU,uCACTY,WAAW,CAACG,MAAM,CAAC,UAACC,KAAK;kBAAA,OAAK,CAAC,CAACA,KAAK;gBAAA,EAAC,IAE3C,mBAAmB,CACnB;gBAAA,kCAEM;kBACNC,MAAM,EAAEJ,SAAS;kBACjB3E,MAAM,EAAEkE;gBACT,CAAC;cAAA;cAAA;gBAAA;YAAA;UAAA;QAAA;MAAA,CACD;MAAA;QAAA;MAAA;MAAA;IAAA;EAAA;EAAA;AAAA,EAjTuCc,0BAAa;AAAA"}
|
|
1
|
+
{"version":3,"file":"SchemaStore.js","names":["_path","_interopRequireDefault","require","_globby","_schema","_spruceCoreSchemas","_spruceEventUtils","_spruceSkillUtils","_lodash","_SpruceError","_AbstractStore2","ownKeys","object","enumerableOnly","keys","Object","getOwnPropertySymbols","symbols","filter","sym","getOwnPropertyDescriptor","enumerable","push","apply","_objectSpread","target","i","arguments","length","source","forEach","key","_defineProperty2","getOwnPropertyDescriptors","defineProperties","defineProperty","_createSuper","Derived","hasNativeReflectConstruct","_isNativeReflectConstruct","_createSuperInternal","Super","_getPrototypeOf2","result","NewTarget","constructor","Reflect","construct","_possibleConstructorReturn2","sham","Proxy","Boolean","prototype","valueOf","call","e","coreSchemas","personSchema","skillSchema","skillCreatorSchema","locationSchema","organizationSchema","personOrganizationSchema","personLocationSchema","roleSchema","messageSchema","messageSourceSchema","messageTargetSchema","sendMessageSchema","choiceSchema","linkSchema","exports","DEFAULT_LOCAL_SCHEMA_DIR","SchemaStore","_AbstractStore","_inherits2","_super","_this","_classCallCheck2","_len","args","Array","_key","concat","_assertThisInitialized2","_createClass2","value","_fetchSchemas","_asyncToGenerator2","_regenerator","mark","_callee","options","_ref","_ref$localSchemaLooku","localSchemaDir","_ref$shouldFetchLocal","shouldFetchLocalSchemas","_ref$shouldFetchRemot","shouldFetchRemoteSchemas","_ref$shouldEnableVers","shouldEnableVersioning","localNamespace","_ref$shouldFetchCoreS","shouldFetchCoreSchemas","didUpdateHandler","moduleToImportFromWhenRemote","results","_results$errors","locals","wrap","_callee$","_context","prev","next","localSchemaLookupDir","errors","schemasByNamespace","CORE_NAMESPACE","values","map","schema","namespace","loadLocalSchemas","sent","schemas","local","_toConsumableArray2","emitDidFetchSchemasAndMixinResults","abrupt","stop","fetchSchemas","_x","_emitDidFetchSchemasAndMixinResults","_callee2","_this2","_namespace","remoteResults","_eventResponseUtil$ge","payloads","_results$errors2","_callee2$","_context2","emitter","emit","eventResponseUtil","getAllResponsePayloadsAndErrors","SpruceError","payload","_payload$schemas","mixinSchemaOrThrowIfExists","_x2","_x3","_schema$namespace","idWithVersion","normalizeSchemaToIdWithVersion","match","find","s","isEqual","_hasLocalSchemas","_callee3","matches","_callee3$","_context3","globbyLocalBuilders","hasLocalSchemas","_loadLocalSchemas","_callee4","localLookupDir","localMatches","importer","imported","c","version","_err$options$file","_err$options","_err$originalError","_err$options$file2","_err$options2","_err$originalError2","_callee4$","_context4","Service","bulkImport","resolveLocalVersion","prepareLocalSchema","err","code","file","originalError","t0","_x4","_x5","_x6","_x7","_globbyLocalBuilders","_callee5","_callee5$","_context5","globby","diskUtil","resolvePath","cwd","_x8","undefined","versionUtil","extractVersion","constValue","friendlyMessage","generateVersion","dirValue","SchemaError","schemaId","id","_fetchFields","_callee7","_this3","_ref2","localAddonsDir","coreAddons","localErrors","localAddons","allFields","_callee7$","_context7","fieldRegistrations","registration","isLocal","t1","Promise","pathUtil","join","t2","_ref3","_callee6","importService","_callee6$","_context6","importDefault","path","_x10","all","uniqBy","addon","fields","fetchFields","_x9","AbstractStore"],"sources":["../../../../src/features/schema/stores/SchemaStore.ts"],"sourcesContent":["import pathUtil from 'path'\nimport globby from '@sprucelabs/globby'\nimport {\n\tSchema,\n\tFieldRegistration,\n\tfieldRegistrations,\n\tnormalizeSchemaToIdWithVersion,\n\tSchemaError,\n} from '@sprucelabs/schema'\nimport {\n\tpersonSchema,\n\tskillSchema,\n\tskillCreatorSchema,\n\tlocationSchema,\n\torganizationSchema,\n\tpersonOrganizationSchema,\n\tpersonLocationSchema,\n\troleSchema,\n\tmessageSchema,\n\tmessageSourceSchema,\n\tmessageTargetSchema,\n\tsendMessageSchema,\n\tchoiceSchema,\n\tlinkSchema,\n} from '@sprucelabs/spruce-core-schemas'\nimport { eventResponseUtil } from '@sprucelabs/spruce-event-utils'\nimport { versionUtil } from '@sprucelabs/spruce-skill-utils'\nimport { diskUtil } from '@sprucelabs/spruce-skill-utils'\nimport { CORE_NAMESPACE } from '@sprucelabs/spruce-skill-utils'\nimport { isEqual, uniqBy } from 'lodash'\nimport SpruceError from '../../../errors/SpruceError'\nimport AbstractStore from '../../../stores/AbstractStore'\nimport { InternalUpdateHandler } from '../../../types/cli.types'\n\nexport const coreSchemas = {\n\tpersonSchema,\n\tskillSchema,\n\tskillCreatorSchema,\n\tlocationSchema,\n\torganizationSchema,\n\tpersonOrganizationSchema,\n\tpersonLocationSchema,\n\troleSchema,\n\tmessageSchema,\n\tmessageSourceSchema,\n\tmessageTargetSchema,\n\tsendMessageSchema,\n\tchoiceSchema,\n\tlinkSchema,\n}\n\ninterface AddonItem {\n\tpath: string\n\tregistration: FieldRegistration\n\tisLocal: boolean\n}\n\nexport interface SchemasByNamespace {\n\t[namespace: string]: Schema[]\n}\n\ninterface FetchSchemasResults {\n\tschemasByNamespace: SchemasByNamespace\n\terrors: SpruceError[]\n}\nexport interface FetchedField {\n\tpath?: string\n\tregistration: FieldRegistration\n\tisLocal: boolean\n}\n\ninterface FetchFieldsResults {\n\terrors: SpruceError[]\n\tfields: FetchedField[]\n}\n\nconst DEFAULT_LOCAL_SCHEMA_DIR = 'src/schemas'\n\nexport default class SchemaStore extends AbstractStore {\n\tpublic readonly name = 'schema'\n\n\tpublic async fetchSchemas(options: {\n\t\tlocalSchemaLookupDir?: string\n\t\tshouldFetchRemoteSchemas?: boolean\n\t\tshouldEnableVersioning?: boolean\n\t\tlocalNamespace: string\n\t\tshouldFetchCoreSchemas?: boolean\n\t\tmoduleToImportFromWhenRemote?: string\n\t\tshouldFetchLocalSchemas?: boolean\n\t\tdidUpdateHandler?: InternalUpdateHandler\n\t}): Promise<FetchSchemasResults> {\n\t\tconst {\n\t\t\tlocalSchemaLookupDir: localSchemaDir = DEFAULT_LOCAL_SCHEMA_DIR,\n\t\t\tshouldFetchLocalSchemas = true,\n\t\t\tshouldFetchRemoteSchemas = true,\n\t\t\tshouldEnableVersioning = true,\n\t\t\tlocalNamespace,\n\t\t\tshouldFetchCoreSchemas = true,\n\t\t\tdidUpdateHandler,\n\t\t\tmoduleToImportFromWhenRemote,\n\t\t} = options || {}\n\n\t\tconst results: FetchSchemasResults = {\n\t\t\terrors: [],\n\t\t\tschemasByNamespace: {},\n\t\t}\n\n\t\tif (shouldFetchCoreSchemas) {\n\t\t\tresults.schemasByNamespace[CORE_NAMESPACE] = Object.values(\n\t\t\t\tcoreSchemas\n\t\t\t).map((schema) => ({\n\t\t\t\t...schema,\n\t\t\t\tnamespace: CORE_NAMESPACE,\n\t\t\t}))\n\t\t}\n\n\t\tif (shouldFetchLocalSchemas) {\n\t\t\tconst locals = await this.loadLocalSchemas(\n\t\t\t\tlocalSchemaDir,\n\t\t\t\tlocalNamespace,\n\t\t\t\tshouldEnableVersioning,\n\t\t\t\tdidUpdateHandler\n\t\t\t)\n\n\t\t\tif (moduleToImportFromWhenRemote) {\n\t\t\t\tlocals.schemas.forEach((local) => {\n\t\t\t\t\tlocal.moduleToImportFromWhenRemote = moduleToImportFromWhenRemote\n\t\t\t\t})\n\t\t\t}\n\n\t\t\tresults.schemasByNamespace[localNamespace] = locals.schemas\n\t\t\tresults.errors.push(...locals.errors)\n\t\t}\n\n\t\tif (shouldFetchRemoteSchemas) {\n\t\t\tawait this.emitDidFetchSchemasAndMixinResults(localNamespace, results)\n\t\t}\n\n\t\treturn results\n\t}\n\n\tprivate async emitDidFetchSchemasAndMixinResults(\n\t\tlocalNamespace: string,\n\t\tresults: FetchSchemasResults\n\t) {\n\t\tconst schemas: Schema[] = []\n\t\tfor (const namespace in results.schemasByNamespace) {\n\t\t\tschemas.push(...results.schemasByNamespace[namespace])\n\t\t}\n\n\t\tconst remoteResults = await this.emitter.emit('schema.did-fetch-schemas', {\n\t\t\tschemas,\n\t\t})\n\n\t\tconst { payloads, errors } =\n\t\t\teventResponseUtil.getAllResponsePayloadsAndErrors(\n\t\t\t\tremoteResults,\n\t\t\t\tSpruceError\n\t\t\t)\n\n\t\tif (errors && errors.length > 0) {\n\t\t\tresults.errors.push(...errors)\n\t\t} else {\n\t\t\tpayloads.forEach((payload) => {\n\t\t\t\tpayload?.schemas?.forEach((schema: Schema) => {\n\t\t\t\t\tthis.mixinSchemaOrThrowIfExists(schema, localNamespace, results)\n\t\t\t\t})\n\t\t\t})\n\t\t}\n\t}\n\n\tprivate mixinSchemaOrThrowIfExists(\n\t\tschema: Schema,\n\t\tlocalNamespace: string,\n\t\tresults: FetchSchemasResults\n\t) {\n\t\tconst namespace = schema.namespace ?? localNamespace\n\n\t\tif (!results.schemasByNamespace[namespace]) {\n\t\t\tresults.schemasByNamespace[namespace] = []\n\t\t}\n\n\t\tconst idWithVersion = normalizeSchemaToIdWithVersion(schema)\n\t\tconst match = results.schemasByNamespace[namespace].find((s) =>\n\t\t\tisEqual(normalizeSchemaToIdWithVersion(s), idWithVersion)\n\t\t)\n\n\t\tif (!match) {\n\t\t\tresults.schemasByNamespace[namespace].push(schema)\n\t\t}\n\t}\n\n\tpublic async hasLocalSchemas() {\n\t\tconst matches = await this.globbyLocalBuilders(DEFAULT_LOCAL_SCHEMA_DIR)\n\t\treturn matches.length > 0\n\t}\n\n\tprivate async loadLocalSchemas(\n\t\tlocalLookupDir: string,\n\t\tlocalNamespace: string,\n\t\tshouldEnableVersioning?: boolean,\n\t\tdidUpdateHandler?: InternalUpdateHandler\n\t) {\n\t\tconst localMatches = await this.globbyLocalBuilders(localLookupDir)\n\n\t\tconst errors: SpruceError[] = []\n\t\tconst schemas: Schema[] = []\n\n\t\tdidUpdateHandler?.(\n\t\t\t`Starting import of ${localMatches.length} schema builders...`\n\t\t)\n\n\t\ttry {\n\t\t\tconst importer = this.Service('import')\n\t\t\tconst imported = await importer.bulkImport(localMatches)\n\n\t\t\tfor (let c = 0; c < localMatches.length; c++) {\n\t\t\t\ttry {\n\t\t\t\t\tconst local = localMatches[c]\n\t\t\t\t\tlet schema = imported[c]\n\n\t\t\t\t\tlet version: undefined | string = this.resolveLocalVersion(\n\t\t\t\t\t\tshouldEnableVersioning,\n\t\t\t\t\t\tlocal,\n\t\t\t\t\t\terrors\n\t\t\t\t\t)\n\t\t\t\t\tif (version || shouldEnableVersioning === false) {\n\t\t\t\t\t\tschema = this.prepareLocalSchema(\n\t\t\t\t\t\t\tschema,\n\t\t\t\t\t\t\tlocalNamespace,\n\t\t\t\t\t\t\tversion,\n\t\t\t\t\t\t\tdidUpdateHandler\n\t\t\t\t\t\t)\n\t\t\t\t\t\tschemas.push(schema)\n\t\t\t\t\t}\n\t\t\t\t} catch (err: any) {\n\t\t\t\t\terrors.push(\n\t\t\t\t\t\tnew SpruceError({\n\t\t\t\t\t\t\tcode: 'SCHEMA_FAILED_TO_IMPORT',\n\t\t\t\t\t\t\tfile: err?.options?.file ?? '**UNKNOWN**',\n\t\t\t\t\t\t\toriginalError: err?.originalError ?? err,\n\t\t\t\t\t\t})\n\t\t\t\t\t)\n\t\t\t\t}\n\t\t\t}\n\t\t} catch (err: any) {\n\t\t\tthrow new SpruceError({\n\t\t\t\tcode: 'SCHEMA_FAILED_TO_IMPORT',\n\t\t\t\tfile: err?.options?.file ?? '**UNKNOWN**',\n\t\t\t\toriginalError: err?.originalError ?? err,\n\t\t\t})\n\t\t}\n\n\t\treturn {\n\t\t\tschemas,\n\t\t\terrors,\n\t\t}\n\t}\n\n\tprivate async globbyLocalBuilders(localLookupDir: string) {\n\t\treturn await globby(\n\t\t\tdiskUtil.resolvePath(this.cwd, localLookupDir, '**/*.builder.[t|j]s')\n\t\t)\n\t}\n\n\tprivate resolveLocalVersion(\n\t\tshouldEnableVersioning: boolean | undefined,\n\t\tlocal: string,\n\t\terrors: SpruceError[]\n\t) {\n\t\tlet version: undefined | string\n\n\t\ttry {\n\t\t\tversion =\n\t\t\t\tshouldEnableVersioning === false\n\t\t\t\t\t? undefined\n\t\t\t\t\t: versionUtil.extractVersion(this.cwd, local).constValue\n\t\t} catch (err) {\n\t\t\terrors.push(\n\t\t\t\tnew SpruceError({\n\t\t\t\t\t// @ts-ignore\n\t\t\t\t\tcode: 'VERSION_MISSING',\n\t\t\t\t\tfriendlyMessage: `It looks like your schema's are not versioned. Make sure schemas are in a directory like src/schemas/${\n\t\t\t\t\t\tversionUtil.generateVersion().dirValue\n\t\t\t\t\t}/*.ts`,\n\t\t\t\t})\n\t\t\t)\n\t\t}\n\t\treturn version\n\t}\n\n\tprivate prepareLocalSchema(\n\t\tschema: Schema,\n\t\tlocalNamespace: string,\n\t\tversion: string | undefined,\n\t\tdidUpdateHandler: InternalUpdateHandler | undefined\n\t) {\n\t\tlet errors: string[] = []\n\n\t\tif (schema.version) {\n\t\t\terrors.push('version_should_not_be_set')\n\t\t}\n\n\t\tif (schema.namespace) {\n\t\t\terrors.push('namespace_should_not_be_set')\n\t\t}\n\n\t\tschema.namespace = localNamespace\n\n\t\tif (errors.length > 0) {\n\t\t\tthrow new SchemaError({\n\t\t\t\tcode: 'INVALID_SCHEMA',\n\t\t\t\tschemaId: schema.id,\n\t\t\t\terrors,\n\t\t\t\tfriendlyMessage:\n\t\t\t\t\t'You should not set a namespace nor version in your schema builder.',\n\t\t\t})\n\t\t}\n\n\t\tschema.version = version\n\n\t\tdidUpdateHandler?.(`Imported ${schema.id} builder.`)\n\n\t\treturn schema\n\t}\n\n\tpublic async fetchFields(options?: {\n\t\tlocalAddonsDir?: string\n\t}): Promise<FetchFieldsResults> {\n\t\tconst { localAddonsDir } = options || {}\n\n\t\tconst coreAddons = fieldRegistrations.map((registration) => {\n\t\t\treturn {\n\t\t\t\tregistration,\n\t\t\t\tisLocal: false,\n\t\t\t}\n\t\t})\n\n\t\tconst localErrors: SpruceError[] = []\n\n\t\tconst localAddons = !localAddonsDir\n\t\t\t? []\n\t\t\t: await Promise.all(\n\t\t\t\t\t(\n\t\t\t\t\t\tawait globby([\n\t\t\t\t\t\t\tpathUtil.join(localAddonsDir, '/*Field.addon.[t|j]s'),\n\t\t\t\t\t\t])\n\t\t\t\t\t).map(async (file: string) => {\n\t\t\t\t\t\ttry {\n\t\t\t\t\t\t\tconst importService = this.Service('import')\n\t\t\t\t\t\t\tconst registration =\n\t\t\t\t\t\t\t\tawait importService.importDefault<FieldRegistration>(file)\n\n\t\t\t\t\t\t\treturn {\n\t\t\t\t\t\t\t\tpath: file,\n\t\t\t\t\t\t\t\tregistration,\n\t\t\t\t\t\t\t\tisLocal: true,\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t} catch (err: any) {\n\t\t\t\t\t\t\tlocalErrors.push(\n\t\t\t\t\t\t\t\tnew SpruceError({\n\t\t\t\t\t\t\t\t\tcode: 'FAILED_TO_IMPORT',\n\t\t\t\t\t\t\t\t\tfile,\n\t\t\t\t\t\t\t\t\toriginalError: err,\n\t\t\t\t\t\t\t\t})\n\t\t\t\t\t\t\t)\n\t\t\t\t\t\t\treturn false\n\t\t\t\t\t\t}\n\t\t\t\t\t})\n\t\t\t )\n\n\t\tconst allFields = uniqBy(\n\t\t\t[\n\t\t\t\t...coreAddons,\n\t\t\t\t...(localAddons.filter((addon) => !!addon) as AddonItem[]),\n\t\t\t],\n\t\t\t'registration.type'\n\t\t)\n\n\t\treturn {\n\t\t\tfields: allFields,\n\t\t\terrors: localErrors,\n\t\t}\n\t}\n}\n"],"mappings":";;;;;;;;;;;;;;;;;AAAA,IAAAA,KAAA,GAAAC,sBAAA,CAAAC,OAAA;AACA,IAAAC,OAAA,GAAAF,sBAAA,CAAAC,OAAA;AACA,IAAAE,OAAA,GAAAF,OAAA;AAOA,IAAAG,kBAAA,GAAAH,OAAA;AAgBA,IAAAI,iBAAA,GAAAJ,OAAA;AACA,IAAAK,iBAAA,GAAAL,OAAA;AAGA,IAAAM,OAAA,GAAAN,OAAA;AACA,IAAAO,YAAA,GAAAR,sBAAA,CAAAC,OAAA;AACA,IAAAQ,eAAA,GAAAT,sBAAA,CAAAC,OAAA;AAAyD,SAAAS,QAAAC,MAAA,EAAAC,cAAA,QAAAC,IAAA,GAAAC,MAAA,CAAAD,IAAA,CAAAF,MAAA,OAAAG,MAAA,CAAAC,qBAAA,QAAAC,OAAA,GAAAF,MAAA,CAAAC,qBAAA,CAAAJ,MAAA,GAAAC,cAAA,KAAAI,OAAA,GAAAA,OAAA,CAAAC,MAAA,WAAAC,GAAA,WAAAJ,MAAA,CAAAK,wBAAA,CAAAR,MAAA,EAAAO,GAAA,EAAAE,UAAA,OAAAP,IAAA,CAAAQ,IAAA,CAAAC,KAAA,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