mirror of
https://github.com/joshuadavidthomas/django-language-server.git
synced 2025-09-12 21:36:55 +00:00
Get rid of all transport types and settle on Protobuf (#25)
* Get rid of all transport types and settle on Protobuf hope i don't regret this * Update Cargo.toml * Update agent.py
This commit is contained in:
parent
643a47953e
commit
0a6e975ca5
38 changed files with 1484 additions and 685 deletions
|
@ -1,5 +1,7 @@
|
|||
use clap::{Args, Parser, Subcommand};
|
||||
use djls_ipc::{PythonProcess, Transport};
|
||||
use djls_ipc::v1::*;
|
||||
use djls_ipc::{ProcessError, PythonProcess, TransportError};
|
||||
use std::ffi::OsStr;
|
||||
use std::time::Duration;
|
||||
|
||||
#[derive(Debug, Parser)]
|
||||
|
@ -41,8 +43,13 @@ async fn main() -> Result<(), Box<dyn std::error::Error>> {
|
|||
|
||||
match cli.command {
|
||||
Commands::Serve(opts) => {
|
||||
let python =
|
||||
PythonProcess::new("djls.lsp", Transport::Json, opts.health_check_interval())?;
|
||||
println!("Starting LSP server...");
|
||||
let python = PythonProcess::new::<Vec<&OsStr>, &OsStr>(
|
||||
"djls.agent",
|
||||
None,
|
||||
opts.health_check_interval(),
|
||||
)?;
|
||||
println!("LSP server started, beginning to serve...");
|
||||
djls_server::serve(python).await?
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue