Skip to content

Commit

Permalink
Tree-sitter: Respect verbosity defined in CODEQL_VERBOSITY
Browse files Browse the repository at this point in the history
  • Loading branch information
hvitved committed May 8, 2024
1 parent 1433ae4 commit abc186f
Show file tree
Hide file tree
Showing 8 changed files with 60 additions and 77 deletions.
1 change: 1 addition & 0 deletions ql/Cargo.lock

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

7 changes: 1 addition & 6 deletions ql/extractor/src/extractor.rs
Original file line number Diff line number Diff line change
Expand Up @@ -20,12 +20,7 @@ pub struct Options {
}

pub fn run(options: Options) -> std::io::Result<()> {
tracing_subscriber::fmt()
.with_target(false)
.without_time()
.with_level(true)
.with_env_filter(tracing_subscriber::EnvFilter::from_default_env())
.init();
codeql_extractor::extractor::set_tracing_level("ql");

let extractor = simple::Extractor {
prefix: "ql".to_string(),
Expand Down
7 changes: 1 addition & 6 deletions ql/extractor/src/generator.rs
Original file line number Diff line number Diff line change
Expand Up @@ -15,12 +15,7 @@ pub struct Options {
}

pub fn run(options: Options) -> std::io::Result<()> {
tracing_subscriber::fmt()
.with_target(false)
.without_time()
.with_level(true)
.with_env_filter(tracing_subscriber::EnvFilter::from_default_env())
.init();
codeql_extractor::extractor::set_tracing_level("ql");

let languages = vec![
Language {
Expand Down
25 changes: 13 additions & 12 deletions ruby/extractor/Cargo.lock

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

2 changes: 1 addition & 1 deletion ruby/extractor/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -34,4 +34,4 @@ lazy_static = "1.4.0"
# of lock-file update time, but `rules_rust` pins generates a bazel rule that unconditionally downloads `main`, which
# breaks build hermeticity. So, rev-pinning it is.
# See also https://github.com/bazelbuild/rules_rust/issues/2502.
codeql-extractor = { git = "https://github.com/github/codeql.git", rev = "cee6f003fd58c64916c629f7d8b27b870d6f78c5" }
codeql-extractor = { git = "https://github.com/github/codeql.git", rev = "1433ae458e59fd254215276706262572567cac9b" }
78 changes: 41 additions & 37 deletions ruby/extractor/cargo-bazel-lock.json

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

10 changes: 1 addition & 9 deletions ruby/extractor/src/extractor.rs
Original file line number Diff line number Diff line change
Expand Up @@ -25,15 +25,7 @@ pub struct Options {
}

pub fn run(options: Options) -> std::io::Result<()> {
tracing_subscriber::fmt()
.with_target(false)
.without_time()
.with_level(true)
.with_env_filter(
tracing_subscriber::EnvFilter::try_from_default_env()
.unwrap_or_else(|_| tracing_subscriber::EnvFilter::new("ruby_extractor=warn")),
)
.init();
extractor::set_tracing_level("ruby");
let diagnostics = diagnostics::DiagnosticLoggers::new("ruby");
let mut main_thread_logger = diagnostics.logger();
let num_threads = match codeql_extractor::options::num_threads() {
Expand Down
7 changes: 1 addition & 6 deletions ruby/extractor/src/generator.rs
Original file line number Diff line number Diff line change
Expand Up @@ -15,12 +15,7 @@ pub struct Options {
}

pub fn run(options: Options) -> std::io::Result<()> {
tracing_subscriber::fmt()
.with_target(false)
.without_time()
.with_level(true)
.with_env_filter(tracing_subscriber::EnvFilter::from_default_env())
.init();
codeql_extractor::extractor::set_tracing_level("ruby");

let languages = vec![
Language {
Expand Down

0 comments on commit abc186f

Please sign in to comment.