Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix pkg-json generation during tag #7013

Merged
merged 7 commits into from
Feb 7, 2023
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 2 additions & 4 deletions scopes/pkg/pkg/pkg.main.runtime.ts
Original file line number Diff line number Diff line change
Expand Up @@ -475,11 +475,9 @@ export class PkgMain implements CloneConfig {
legacyComponent: LegacyComponent,
packageJsonObject: Record<string, any>
): Promise<Record<string, any>> {
// const newId = await this.workspace.resolveComponentId(component.id);
// const newComponent = await this.workspace.get(newId);
const host = this.componentAspect.getHost();
const id = await host.resolveComponentId(legacyComponent.id);
const newComponent = await host.get(id);
const components = await host.getManyByLegacy([legacyComponent]);
const newComponent = components[0];
if (!newComponent) throw new Error(`cannot transform package.json of component: ${legacyComponent.id.toString()}`);
const newProps = this.getPackageJsonModifications(newComponent);
return Object.assign(packageJsonObject, newProps);
Expand Down
2 changes: 1 addition & 1 deletion scopes/typescript/ts-server/process-based-tsserver.ts
Original file line number Diff line number Diff line change
Expand Up @@ -188,7 +188,7 @@ export class ProcessBasedTsServer {
if (this.options.logToConsole) {
this.logger.console(`${msg} ${JSON.stringify(obj, undefined, 4)}`);
} else {
this.logger.debug(msg, obj);
this.logger.trace(msg, obj);
}
}

Expand Down