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

Generate Code from TypeSpec in VSCode #5312

Open
wants to merge 82 commits into
base: main
Choose a base branch
from

Conversation

chunyu3
Copy link
Contributor

@chunyu3 chunyu3 commented Dec 10, 2024

Fix #5025
Fix #5463

Integrate Code Generation in VSCode extension

@chunyu3 chunyu3 marked this pull request as draft December 10, 2024 01:48
@microsoft-github-policy-service microsoft-github-policy-service bot added the ide Issues for VS, VSCode, Monaco, etc. label Dec 10, 2024
@azure-sdk
Copy link
Collaborator

azure-sdk commented Dec 10, 2024

All changed packages have been documented.

  • @typespec/internal-build-utils
  • typespec-vscode
Show changes

typespec-vscode - feature ✏️

integrate client SDK generation

@typespec/internal-build-utils - fix ✏️

resolve the program crash when there is no package name in package.json

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

some icons don't work well in dark theme.
image
image

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Update the most icons. except java for dark themes.

}
const outputDir = path.join(
baseDir,
selectedEmitter.emitterKind,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

please put the output folder under tsp-output as default. the "server", "client" is too general which user may already use in his project...

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@RodgeFu We need consistent the output folder structure as the toDoApp. Arch will discuss the folder structure, and update accordingly when toDoApp folder structure finalized.

if (npmInstallResult.exitCode !== 0) {
logger.error(
`Error occurred when installing packages.`,
[`${npmInstallResult.stderr}`],
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

got following error when trying upgrade lib and generating client java. in the error, it mentions resolving "undefined@undefined", please double check...
image

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

same as issue #5385.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

no, i mean this line. is the "undefined@undefined" expected?
image

Copy link
Contributor Author

@chunyu3 chunyu3 Jan 3, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

undefined@undefined does not refer to the variable of our code. It is reported by npm referring to its own variables.
Yes, it is expected when npm install failure because of dependency conflict.

@chunyu3 chunyu3 requested a review from witemple-msft as a code owner January 9, 2025 16:00
}
}
},
"default": [
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@RodgeFu, looks like we are baking a list of known 1P emitters in the extension packages. We have discussed this being built-in template driven. I would also like to re-review design of the Generate Code flow. I have comments on what's listed in the design doc on this.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ide Issues for VS, VSCode, Monaco, etc.
Projects
None yet
7 participants