Skip to content

Plugins - support plugin specific logging #15913

Closed
@egamma

Description

@egamma

The tslint language server plugin has to handle the situation that a tslint.json file cannot be read. The tslint API to get the configuration returns an exception in this case. There needs to be a way to show the exception to the user. The VS Code tslint extension shows this exception in the tslint output channel, see the screenshot below.

image

A plugin has access to the TS logger info.project.projectService.logger, but this log is intended for plugin authors to trace the execution of a plugin. It is not intended to be shown and understood by the end user.

What would be needed is an API that allows a plugin to send a log message event under a particular topic to the language server client. A client like VS Code can then append this message to a plugin specific output channel, in this case to the tslint channel.

// fyi @mjbvz

Metadata

Metadata

Assignees

No one assigned

    Labels

    DeclinedThe issue was declined as something which matches the TypeScript visionSuggestionAn idea for TypeScript

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions