mirror of
https://github.com/denoland/deno.git
synced 2025-01-21 21:50:00 -05:00
fix(lsp): use CliLockfile (#24387)
The build broke in https://github.com/denoland/deno/pull/24365.
This commit is contained in:
parent
38a6be2e8e
commit
b0cd43b5f3
1 changed files with 3 additions and 4 deletions
|
@ -3,6 +3,7 @@
|
||||||
use crate::args::create_default_npmrc;
|
use crate::args::create_default_npmrc;
|
||||||
use crate::args::package_json;
|
use crate::args::package_json;
|
||||||
use crate::args::CacheSetting;
|
use crate::args::CacheSetting;
|
||||||
|
use crate::args::CliLockfile;
|
||||||
use crate::graph_util::CliJsrUrlProvider;
|
use crate::graph_util::CliJsrUrlProvider;
|
||||||
use crate::http_util::HttpClientProvider;
|
use crate::http_util::HttpClientProvider;
|
||||||
use crate::lsp::config::Config;
|
use crate::lsp::config::Config;
|
||||||
|
@ -26,12 +27,10 @@ use dashmap::DashMap;
|
||||||
use deno_ast::MediaType;
|
use deno_ast::MediaType;
|
||||||
use deno_cache_dir::HttpCache;
|
use deno_cache_dir::HttpCache;
|
||||||
use deno_core::error::AnyError;
|
use deno_core::error::AnyError;
|
||||||
use deno_core::parking_lot::Mutex;
|
|
||||||
use deno_core::url::Url;
|
use deno_core::url::Url;
|
||||||
use deno_graph::source::Resolver;
|
use deno_graph::source::Resolver;
|
||||||
use deno_graph::GraphImport;
|
use deno_graph::GraphImport;
|
||||||
use deno_graph::ModuleSpecifier;
|
use deno_graph::ModuleSpecifier;
|
||||||
use deno_lockfile::Lockfile;
|
|
||||||
use deno_npm::NpmSystemInfo;
|
use deno_npm::NpmSystemInfo;
|
||||||
use deno_runtime::deno_fs;
|
use deno_runtime::deno_fs;
|
||||||
use deno_runtime::deno_node::NodeResolution;
|
use deno_runtime::deno_node::NodeResolution;
|
||||||
|
@ -110,7 +109,7 @@ impl LspScopeResolver {
|
||||||
)));
|
)));
|
||||||
let redirect_resolver = Some(Arc::new(RedirectResolver::new(
|
let redirect_resolver = Some(Arc::new(RedirectResolver::new(
|
||||||
cache.for_specifier(config_data.map(|d| &d.scope)),
|
cache.for_specifier(config_data.map(|d| &d.scope)),
|
||||||
config_data.and_then(|d| d.lockfile.as_deref()),
|
config_data.and_then(|d| d.lockfile.clone()),
|
||||||
)));
|
)));
|
||||||
let npm_graph_resolver = graph_resolver.create_graph_npm_resolver();
|
let npm_graph_resolver = graph_resolver.create_graph_npm_resolver();
|
||||||
let graph_imports = config_data
|
let graph_imports = config_data
|
||||||
|
@ -552,7 +551,7 @@ impl std::fmt::Debug for RedirectResolver {
|
||||||
impl RedirectResolver {
|
impl RedirectResolver {
|
||||||
fn new(
|
fn new(
|
||||||
cache: Arc<dyn HttpCache>,
|
cache: Arc<dyn HttpCache>,
|
||||||
lockfile: Option<&Mutex<Lockfile>>,
|
lockfile: Option<Arc<CliLockfile>>,
|
||||||
) -> Self {
|
) -> Self {
|
||||||
let entries = DashMap::new();
|
let entries = DashMap::new();
|
||||||
if let Some(lockfile) = lockfile {
|
if let Some(lockfile) = lockfile {
|
||||||
|
|
Loading…
Add table
Reference in a new issue