Skip to content

Commit

Permalink
Fix json server startup
Browse files Browse the repository at this point in the history
  • Loading branch information
kaisalmen committed Oct 11, 2023
1 parent fe747da commit f104fd7
Show file tree
Hide file tree
Showing 9 changed files with 23 additions and 20 deletions.
14 changes: 7 additions & 7 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion packages/client/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "monaco-languageclient",
"version": "6.5.3-next.0",
"version": "6.5.3-next.2",
"description": "Monaco Language client implementation",
"author": {
"name": "TypeFox GmbH",
Expand Down
4 changes: 2 additions & 2 deletions packages/examples/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "monaco-languageclient-examples",
"version": "6.5.3-next.0",
"version": "6.5.3-next.2",
"description": "Monaco Language client examples",
"author": {
"name": "TypeFox GmbH",
Expand Down Expand Up @@ -56,7 +56,7 @@
"langium": "~2.0.2",
"langium-statemachine-dsl": "~2.0.0",
"monaco-editor-workers": "~0.43.0",
"monaco-languageclient": "~6.5.3-next.0",
"monaco-languageclient": "~6.5.3-next.2",
"pyright": "~1.1.330",
"react": "~18.2.0",
"react-dom": "~18.2.0",
Expand Down
2 changes: 1 addition & 1 deletion packages/examples/src/common/server-commons.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,11 @@ import { Message, InitializeRequest, InitializeParams } from 'vscode-languageser
export const launchLanguageServer = (serverName: string, socket: IWebSocket, baseDir: string, relativeDir: string) => {
// start the language server as an external process
const ls = resolve(baseDir, relativeDir);
const serverConnection = createServerProcess(serverName, 'node', [ls, '--stdio']);

const reader = new WebSocketMessageReader(socket);
const writer = new WebSocketMessageWriter(socket);
const socketConnection = createConnection(reader, writer, () => socket.dispose());
const serverConnection = createServerProcess(serverName, 'node', [ls, '--stdio']);
if (serverConnection) {
forward(socketConnection, serverConnection, message => {
if (Message.isRequest(message)) {
Expand Down
9 changes: 6 additions & 3 deletions packages/examples/src/json/server/json-server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -257,6 +257,9 @@ export class JsonServer {
}
}

const connection = createConnection(ProposedFeatures.all);
const ls = new JsonServer(connection);
ls.start();
const scriptExec = process.argv[2];
if (scriptExec === '--stdio') {
const connection = createConnection(ProposedFeatures.all);
const ls = new JsonServer(connection);
ls.start();
}
2 changes: 1 addition & 1 deletion packages/verify/pnpm/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"version": "0.0.0",
"private": "true",
"dependencies": {
"monaco-languageclient": "~6.5.3-next.0",
"monaco-languageclient": "~6.5.3-next.2",
"monaco-editor": "~0.43.0",
"vscode": "npm:@codingame/monaco-vscode-api@>=1.82.5-next.0 <1.83.0"
},
Expand Down
4 changes: 2 additions & 2 deletions packages/verify/vite/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@
"type": "module",
"dependencies": {
"monaco-editor-workers": "~0.43.0",
"monaco-languageclient": "~6.5.3-next.0",
"monaco-languageclient-examples": "~6.5.3-next.0",
"monaco-languageclient": "~6.5.3-next.2",
"monaco-languageclient-examples": "~6.5.3-next.2",
"vscode-ws-jsonrpc": "~3.0.0"
},
"devDependencies": {
Expand Down
4 changes: 2 additions & 2 deletions packages/verify/webpack/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@
"type": "module",
"dependencies": {
"monaco-editor-workers": "~0.43.0",
"monaco-languageclient": "~6.5.3-next.0",
"monaco-languageclient-examples": "~6.5.3-next.0",
"monaco-languageclient": "~6.5.3-next.2",
"monaco-languageclient-examples": "~6.5.3-next.2",
"vscode-ws-jsonrpc": "~3.0.0"
},
"devDependencies": {
Expand Down
2 changes: 1 addition & 1 deletion packages/verify/yarn/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"version": "0.0.0",
"private": "true",
"dependencies": {
"monaco-languageclient": "~6.5.3-next.0"
"monaco-languageclient": "~6.5.3-next.2"
},
"devDependencies": {
"shx": "~0.3.4"
Expand Down

0 comments on commit f104fd7

Please sign in to comment.