From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from atuin.qyliss.net (localhost [IPv6:::1]) by atuin.qyliss.net (Postfix) with ESMTP id 4438398C6; Thu, 26 Feb 2026 15:07:57 +0000 (UTC) Received: by atuin.qyliss.net (Postfix, from userid 993) id 161B39921; Thu, 26 Feb 2026 15:07:54 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 4.0.1 (2024-03-26) on atuin.qyliss.net X-Spam-Level: X-Spam-Status: No, score=-0.1 required=3.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,DMARC_MISSING,FILL_THIS_FORM,SPF_HELO_PASS autolearn=unavailable autolearn_force=no version=4.0.1 Received: from fout-a3-smtp.messagingengine.com (fout-a3-smtp.messagingengine.com [103.168.172.146]) by atuin.qyliss.net (Postfix) with ESMTPS id B644798B4 for ; Thu, 26 Feb 2026 15:07:51 +0000 (UTC) Received: from phl-compute-01.internal (phl-compute-01.internal [10.202.2.41]) by mailfout.phl.internal (Postfix) with ESMTP id 1AD2CEC056C for ; Thu, 26 Feb 2026 10:07:50 -0500 (EST) Received: from phl-frontend-04 ([10.202.2.163]) by phl-compute-01.internal (MEProxy); Thu, 26 Feb 2026 10:07:50 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=alyssa.is; h=cc :content-transfer-encoding:content-type:date:date:from:from :in-reply-to:message-id:mime-version:reply-to:subject:subject:to :to; s=fm2; t=1772118470; x=1772204870; bh=UKlw/hdKCHQPewKNfTaF6 7jy5MycDVIX2LbkHpzweq4=; b=SmUTkQDSdBhcLa2/cNg7h8AxvB0q1gl4dJ8Pr g+Xa2jVLW8B9H0OPCevqdOHG5D4sTlSZx3BXu0LV5ES0xmv1u7crw7r7CaGPUPGk BJNNZ1FpNh3zBU4eY+UpWKHyDr0n7fomWkTYqyzO4rtTk44fDnJLsKgEcJlAfP6l NawjtFYD62MRNZyYKhrFfqzZdi9zPcUNo8FQNQocj5BO3nC6aWnBHgDHk8wWPEk7 aMUd1KIH+DLIJRSWpPKYjtsDtOaKs0uMKXObeca0Oj59AnPE4agfOfh7Wekv/2Xg 9G4BCit18bmFLzeRNsqihJrWZNdW0EijA+q/uytdQyxwz55kQ== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:content-type :date:date:feedback-id:feedback-id:from:from:in-reply-to :message-id:mime-version:reply-to:subject:subject:to:to :x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s=fm3; t= 1772118470; x=1772204870; bh=UKlw/hdKCHQPewKNfTaF67jy5MycDVIX2Lb kHpzweq4=; b=ML43bxP9xnyqai9fWbtbvvPP6DDG6jI2kpuRnGZSqQr0QuhyfF4 M7Lz73VKjjGjcNFBEyxyId0KZDewr5xbOS5XCxjVOGCReJfWcNQ39UbhSX+Eqnru GvLGYm68oMmEla95PdRZ9xcP7GE8cZ4P43MSL7nxBmxDSBsY6IVWeWejCKK3/pHk jXiOhb5ftEARImRHGcZacy8AGfw55YwFvtHX1GY8BH9XI4zyKRItCnWdKKmn7nKb uoMSImKlkafYSxgEhYxsCela8NvwjNqnhsOKlY/UqyIWg9c1vhcK/wr2YqqPnhN7 mx2O5ju5a7db6QMVzHn/jE1/+0Mp0us0t0A== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeefgedrtddtgddvgeeifeeiucetufdoteggodetrf dotffvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfurfetoffkrfgpnffqhgenuceu rghilhhouhhtmecufedttdenucenucfjughrpefhvffufffkofgggfestdekredtredttd enucfhrhhomheptehlhihsshgrucftohhsshcuoehhihesrghlhihsshgrrdhisheqnecu ggftrfgrthhtvghrnhepleejtdeiffegveejuedvkeevieetkefgleeuleehfeduleekue ejffeikeeggfeinecuffhomhgrihhnpehgihhthhhusgdrtghomhenucevlhhushhtvghr ufhiiigvpedtnecurfgrrhgrmhepmhgrihhlfhhrohhmpehhihesrghlhihsshgrrdhish dpnhgspghrtghpthhtohepuddpmhhouggvpehsmhhtphhouhhtpdhrtghpthhtohepuggv vhgvlhesshhpvggtthhruhhmqdhoshdrohhrgh X-ME-Proxy: Feedback-ID: i12284293:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA for ; Thu, 26 Feb 2026 10:07:49 -0500 (EST) Received: by mbp.qyliss.net (Postfix, from userid 1000) id 0043675C4EA6; Thu, 26 Feb 2026 16:07:45 +0100 (CET) From: Alyssa Ross To: devel@spectrum-os.org Subject: [PATCH 1/2] tools/xdg-desktop-portal-spectrum-host: set up log Date: Thu, 26 Feb 2026 16:07:31 +0100 Message-ID: <20260226150732.150645-1-hi@alyssa.is> X-Mailer: git-send-email 2.52.0 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Message-ID-Hash: VD7DGEKVFQPMJGPAE5LMHQSCVB65VO7K X-Message-ID-Hash: VD7DGEKVFQPMJGPAE5LMHQSCVB65VO7K X-MailFrom: hi@alyssa.is X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; header-match-devel.spectrum-os.org-0; header-match-devel.spectrum-os.org-1; header-match-devel.spectrum-os.org-2; header-match-devel.spectrum-os.org-3; header-match-devel.spectrum-os.org-4; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header X-Mailman-Version: 3.3.9 Precedence: list List-Id: Patches and low-level development discussion Archived-At: <> List-Archive: <> List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: This will let us see logs from zbus. Signed-off-by: Alyssa Ross --- .../Cargo.lock | 76 +++++++++++++++++++ .../Cargo.toml | 8 +- .../src/main.rs | 5 ++ 3 files changed, 88 insertions(+), 1 deletion(-) diff --git a/tools/xdg-desktop-portal-spectrum-host/Cargo.lock b/tools/xdg-desktop-portal-spectrum-host/Cargo.lock index 75b5607..cb32e66 100644 --- a/tools/xdg-desktop-portal-spectrum-host/Cargo.lock +++ b/tools/xdg-desktop-portal-spectrum-host/Cargo.lock @@ -2,6 +2,15 @@ # It is not intended for manual editing. version = 4 +[[package]] +name = "aho-corasick" +version = "1.1.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ddd31a130427c27518df266943a5308ed92d4b226cc639f5a8f1002816174301" +dependencies = [ + "memchr", +] + [[package]] name = "async-broadcast" version = "0.7.2" @@ -475,6 +484,12 @@ dependencies = [ "thiserror", ] +[[package]] +name = "lazy_static" +version = "1.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bbd2bcb4c963f2ddae06a2efc7e9f3591312473c50c6685e1f298068316e66fe" + [[package]] name = "libc" version = "0.2.178" @@ -493,6 +508,15 @@ version = "0.8.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6373607a59f0be73a39b6fe456b8192fcc3585f602af20751600e974dd455e77" +[[package]] +name = "matchers" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d1525a2a28c7f4fa0fc98bb91ae755d1e2d1505079e05539e35bc876b5d65ae9" +dependencies = [ + "regex-automata", +] + [[package]] name = "memchr" version = "2.7.6" @@ -622,6 +646,23 @@ version = "5.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "69cdb34c158ceb288df11e18b4bd39de994f6657d83847bdffdbd7f346754b0f" +[[package]] +name = "regex-automata" +version = "0.4.13" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5276caf25ac86c8d810222b3dbb938e512c55c6831a10f3e6ed1c93b84041f1c" +dependencies = [ + "aho-corasick", + "memchr", + "regex-syntax", +] + +[[package]] +name = "regex-syntax" +version = "0.8.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7a2d987857b319362043e95f5353c0535c1f58eec5336fdfcf626430af7def58" + [[package]] name = "rustix" version = "1.1.2" @@ -682,6 +723,15 @@ dependencies = [ "syn", ] +[[package]] +name = "sharded-slab" +version = "0.1.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f40ca3c46823713e0d4209592e8d6e826aa57e928f09752619fc696c499637f6" +dependencies = [ + "lazy_static", +] + [[package]] name = "signal-hook-registry" version = "1.4.7" @@ -770,6 +820,15 @@ dependencies = [ "syn", ] +[[package]] +name = "thread_local" +version = "1.1.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f60246a4944f24f6e018aa17cdeffb7818b76356965d03b07d6a9886e8962185" +dependencies = [ + "cfg-if", +] + [[package]] name = "tinystr" version = "0.8.2" @@ -841,6 +900,21 @@ dependencies = [ "once_cell", ] +[[package]] +name = "tracing-subscriber" +version = "0.3.22" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2f30143827ddab0d256fd843b7a66d164e9f271cfa0dde49142c5ca0ca291f1e" +dependencies = [ + "matchers", + "once_cell", + "regex-automata", + "sharded-slab", + "thread_local", + "tracing", + "tracing-core", +] + [[package]] name = "uds_windows" version = "1.1.0" @@ -1009,6 +1083,8 @@ dependencies = [ "landlock", "percent-encoding", "rustix", + "tracing", + "tracing-subscriber", "url", "zbus", ] diff --git a/tools/xdg-desktop-portal-spectrum-host/Cargo.toml b/tools/xdg-desktop-portal-spectrum-host/Cargo.toml index 23cadf0..5dc0d99 100644 --- a/tools/xdg-desktop-portal-spectrum-host/Cargo.toml +++ b/tools/xdg-desktop-portal-spectrum-host/Cargo.toml @@ -1,5 +1,5 @@ # SPDX-License-Identifier: CC0-1.0 -# SPDX-FileCopyrightText: 2024 Alyssa Ross +# SPDX-FileCopyrightText: 2024-2025 Alyssa Ross [package] name = "xdg-desktop-portal-spectrum-host" @@ -13,5 +13,11 @@ futures-lite = "2.3.0" landlock = "0.4.4" percent-encoding = "2.3.1" rustix = "1.0" +tracing = "0.1.43" url = "2.5.0" zbus = "5.1.1" + +[dependencies.tracing-subscriber] +version = "0.3.22" +default-features = false +features = ["env-filter", "fmt"] diff --git a/tools/xdg-desktop-portal-spectrum-host/src/main.rs b/tools/xdg-desktop-portal-spectrum-host/src/main.rs index a867219..40b14b4 100644 --- a/tools/xdg-desktop-portal-spectrum-host/src/main.rs +++ b/tools/xdg-desktop-portal-spectrum-host/src/main.rs @@ -23,6 +23,7 @@ use landlock::{ ABI, Access, AccessFs, AccessNet, CompatLevel, Compatible, Ruleset, RulesetAttr, RulesetError, Scope, }; +use tracing_subscriber::EnvFilter; use zbus::{AuthMechanism, Connection, MessageStream, connection}; use file_chooser::FileChooser; @@ -236,6 +237,10 @@ fn read_argv() { fn run() -> Result<(), String> { set_up_landlock().map_err(|e| format!("setting up landlock: {e}"))?; + tracing_subscriber::fmt() + .with_env_filter(EnvFilter::from_default_env()) + .init(); + read_argv(); async_io::block_on(EXECUTOR.run(async { base-commit: 1a0d063dccf3465ffffda8312994d6066bc1a602 -- 2.52.0