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

Improve positioning of compiler error messaging info #47126

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

Conversation

@futurGH
Copy link

@futurGH futurGH commented Dec 13, 2021

Fixes #45717.

This PR improves the formatting of compiler error messages for better legibility as described in the referenced issue.

Two concerns that are worth noting with this PR;

  • Moving the error next to the file means that the error code doesn't show in, for example, the "file not found" error message. Not that it's all that necessary with clear and detailed error messages in that case in particular, but there are most likely others I'm not aware of.

  • With errors that contain multiple code spans, the message for subsequent locations is moved above the code itself, which means that some error messages might need to be subtly changed. For example, in this comment, the period at the end of the "was also declared" messages is changed to a colon.

@orta
Copy link
Member

@orta orta commented Jan 7, 2022

@typescript-bot pack this

@typescript-bot
Copy link
Collaborator

@typescript-bot typescript-bot commented Jan 7, 2022

Heya @orta, I've started to run the tarball bundle task on this PR at 9b7609e. You can monitor the build here.

@typescript-bot
Copy link
Collaborator

@typescript-bot typescript-bot commented Jan 7, 2022

Hey @orta, I've packed this into an installable tgz. You can install it for testing by referencing it in your package.json like so:

{
    "devDependencies": {
        "typescript": "https://typescript.visualstudio.com/cf7ac146-d525-443c-b23c-0d58337efebc/_apis/build/builds/116968/artifacts?artifactName=tgz&fileId=D7390F631624357E61106F56C0DFE46F2446FF0360F4E0A032D8F0039C505BC302&fileName=/typescript-4.6.0-insiders.20220107.tgz"
    }
}

and then running npm install.


There is also a playground for this build and an npm module you can use via "typescript": "npm:@typescript-deploys/pr-build@4.6.0-pr-47126-2".;

@orta
Copy link
Member

@orta orta commented Jan 7, 2022

@typescript-bot pack this

@typescript-bot
Copy link
Collaborator

@typescript-bot typescript-bot commented Jan 7, 2022

Heya @orta, I've started to run the tarball bundle task on this PR at af57462. You can monitor the build here.

@typescript-bot
Copy link
Collaborator

@typescript-bot typescript-bot commented Jan 7, 2022

Hey @orta, I've packed this into an installable tgz. You can install it for testing by referencing it in your package.json like so:

{
    "devDependencies": {
        "typescript": "https://typescript.visualstudio.com/cf7ac146-d525-443c-b23c-0d58337efebc/_apis/build/builds/116996/artifacts?artifactName=tgz&fileId=360FE3C8678C9FEDDF215F61D45CAB595608986576EB0A3E5B08DDBE050ED39702&fileName=/typescript-4.6.0-insiders.20220107.tgz"
    }
}

and then running npm install.


There is also a playground for this build and an npm module you can use via "typescript": "npm:@typescript-deploys/pr-build@4.6.0-pr-47126-5".;

@orta orta force-pushed the compiler-format branch from af57462 to f585f87 Jan 7, 2022
@orta
Copy link
Member

@orta orta commented Jan 7, 2022

@typescript-bot pack this

@typescript-bot
Copy link
Collaborator

@typescript-bot typescript-bot commented Jan 7, 2022

Heya @orta, I've started to run the tarball bundle task on this PR at f585f87. You can monitor the build here.

@typescript-bot
Copy link
Collaborator

@typescript-bot typescript-bot commented Jan 7, 2022

Hey @orta, I've packed this into an installable tgz. You can install it for testing by referencing it in your package.json like so:

{
    "devDependencies": {
        "typescript": "https://typescript.visualstudio.com/cf7ac146-d525-443c-b23c-0d58337efebc/_apis/build/builds/117000/artifacts?artifactName=tgz&fileId=8865AFF015DC29F56C3E9E7BBF2F49D5F8DF045D4C486E000A5465310B53746102&fileName=/typescript-4.6.0-insiders.20220107.tgz"
    }
}

and then running npm install.


There is also a playground for this build and an npm module you can use via "typescript": "npm:@typescript-deploys/pr-build@4.6.0-pr-47126-8".;

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

3 participants