Skip to content

[AT-10] Add helpful errors / messaging around config files#897

Merged
JakeDawkins merged 14 commits intomasterfrom
trevor/config-helpful-messaging
Jan 30, 2019
Merged

[AT-10] Add helpful errors / messaging around config files#897
JakeDawkins merged 14 commits intomasterfrom
trevor/config-helpful-messaging

Conversation

@trevor-scheer
Copy link
Copy Markdown
Contributor

This PR adds new warning states and communication within the extension in order to help users resolve config issues more easily and know when there's a problem.

noconfig

Also included with this PR is a bit of a shift in how errors are handled. After speaking with James about it, we both agreed that this would be a scalable approach that will work well with clients consuming the language server or using its parts programmatically.

  • Internals of the language server should throw errors, as opposed to catching them and logging at any point.
  • The server itself should catch these errors at the top level and message them out via the connection, so they can be consumed by any client listening on that connection.
  • Clients using the language server parts programmatically should catch and handle these errors in an appropriate manner based on the requirements of the client.

@trevor-scheer trevor-scheer force-pushed the trevor/config-helpful-messaging branch from 0a7ce7f to 17a3c47 Compare January 22, 2019 20:12
Comment thread packages/vscode-apollo/src/extension.ts Outdated
Copy link
Copy Markdown
Contributor

@JakeDawkins JakeDawkins left a comment

Choose a reason for hiding this comment

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

Looks great overall! Just a could questions :)

Comment thread packages/apollo-language-server/src/project/client.ts Outdated
Comment thread packages/vscode-apollo/package.json
@JakeDawkins

This comment has been minimized.

@trevor-scheer trevor-scheer force-pushed the trevor/config-helpful-messaging branch from c15797b to 8baa4d5 Compare January 29, 2019 00:10
@trevor-scheer trevor-scheer changed the title Add helpful errors / messaging around config files [AT-10] Add helpful errors / messaging around config files Jan 29, 2019
@JakeDawkins JakeDawkins force-pushed the trevor/config-helpful-messaging branch from 8baa4d5 to 39ebe17 Compare January 30, 2019 15:46
@JakeDawkins
Copy link
Copy Markdown
Contributor

:yolo:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants