MCPcopy Create free account
hub / github.com/observablehq/framework / markDeployUploaded

Method markDeployUploaded

src/deploy.ts:641–659  ·  view source on GitHub ↗
(deployId: string)

Source from the content-addressed store, hash-verified

639 }
640
641 private async markDeployUploaded(deployId: string) {
642 // Mark the deploy as uploaded
643 let buildManifest: null | BuildManifest = null;
644 try {
645 const source = await this.effects.readCacheFile(this.deployOptions.config.root, "_build.json");
646 buildManifest = JSON.parse(source);
647 Telemetry.record({event: "deploy", buildManifest: "found"});
648 } catch (error) {
649 if (isEnoent(error)) {
650 Telemetry.record({event: "deploy", buildManifest: "missing"});
651 } else {
652 // The error message here might contain sensitive information, so
653 // don't send it in telemetry.
654 Telemetry.record({event: "deploy", buildManifest: "error"});
655 this.effects.clack.log.warn(`Could not read build manifest: ${error}`);
656 }
657 }
658 await this.apiClient.postDeployUploaded(deployId, buildManifest);
659 }
660
661 private async pollForProcessingCompletion(deployId: string): Promise<GetDeployResponse> {
662 const {deployPollInterval: pollInterval = DEPLOY_POLL_INTERVAL_MS} = this.deployOptions;

Callers 2

startNewDeployMethod · 0.95

Calls 5

isEnoentFunction · 0.85
readCacheFileMethod · 0.80
recordMethod · 0.80
postDeployUploadedMethod · 0.80
warnMethod · 0.45

Tested by

no test coverage detected