[bug] GLib-Critical: Operation not permitted
Describe the bug
The running app print in the console the message:
(process:21774): GLib-CRITICAL **: 12:12:24.158: Failed to set scheduler settings: Operation not permitted
Reproduction
In developer mode:
npm run tauri dev
Production app version:
npm run tauri build
- install deb in system and run by console for example
$ app_name
Expected behavior
Clear console output without critical communication.
Platform and versions
npm run tauri info:
> $ npm run tauri info > [email protected] tauri > tauri Environment › OS: Ubuntu 20.04 X64 › Node.js: 16.17.0 › npm: 8.15.0 › pnpm: Not installed! › yarn: Not installed! › rustup: 1.25.1 › rustc: 1.63.0 › cargo: 1.63.0 › Rust toolchain: stable-x86_64-unknown-linux-gnu Packages › @tauri-apps/cli [NPM]: 1.0.5 › @tauri-apps/api [NPM]: 1.0.2 › tauri [RUST]: 1.0.5, › tauri-build [RUST]: 1.0.4, › tao [RUST]: 0.12.2, › wry [RUST]: 0.19.0, App › build-type: bundle › CSP: unset › distDir: ../dist › devPath: http://localhost:3000/ › framework: React App directory structure ├─ src ├─ .git ├─ dist ├─ node_modules └─ src-tauri
Stack trace
No response
Additional context
Log:
$ npm run tauri dev
> [email protected] tauri
> tauri
Running BeforeDevCommand (`npm run dev`)
Warn Waiting for your frontend dev server to start on http://localhost:3000/...
> [email protected] dev
> vite
vite v2.9.15 dev server running at:
> Local: http://localhost:3000/
> Network: use `--host` to expose
ready in 444ms.
Info Watching /home/legion/github_project/guprod/src-tauri for changes...
Compiling app v0.15.0 (/home/legion/github_project/guprod/src-tauri)
Finished dev [unoptimized + debuginfo] target(s) in 15.95s
System name: "Ubuntu"
System OS version: "20.04"
System Host version: "legion"
System name: "Ubuntu"
System OS version: "20.04"
System Host version: "legion"
System name: "Ubuntu"
System OS version: "20.04"
System Host version: "legion"
(process:35652): GLib-CRITICAL **: 12:24:44.966: Failed to set scheduler settings: Operation not permitted
System name: "Ubuntu"
System OS version: "20.04"
System Host version: "legion"
(process:35657): GLib-CRITICAL **: 12:24:45.411: Failed to set scheduler settings: Operation not permitted
- Is this a new blank tauri project? Or did you change anything? In case you did change anything we'd need a reproduction example.
- Did you try upgrading your system dependencies? The only somewhat similar issues i found on the internet were all fixed in newer glib versions
- So far you're the very first one reporting this so if 2. doesn't fix it this probably won't be much fun 😅
@FabianLars Frontend is Vite React.js
- Isn't blank tauri project, I added splashscreen and some changes in tauri.conf :
{
"$schema": "../node_modules/@tauri-apps/cli/schema.json",
"build": {
"beforeBuildCommand": "npm run build",
"beforeDevCommand": "npm run dev",
"devPath": "http://localhost:3000",
"distDir": "../dist"
},
"package": {
"productName": "guprod",
"version": "0.15.0"
},
"tauri": {
"allowlist": {
"all": true
},
"bundle": {
"active": true,
"category": "DeveloperTool",
"copyright": "",
"deb": {
"depends": []
},
"externalBin": [],
"icon": [
"icons/32x32.png",
"icons/128x128.png",
"icons/[email protected]",
"icons/icon.icns",
"icons/icon.ico"
],
"identifier": "pl.guprod.pro",
"longDescription": "GUI app for working on server",
"macOS": {
"entitlements": null,
"exceptionDomain": "",
"frameworks": [],
"providerShortName": null,
"signingIdentity": null
},
"resources": [],
"shortDescription": "",
"targets": ["deb", "dmg", "msi"],
"windows": {
"certificateThumbprint": null,
"digestAlgorithm": "sha256",
"timestampUrl": ""
}
},
"security": {
"csp": null
},
"updater": {
"active": false
},
"windows": [
{
"label": "main",
"center": true,
"fullscreen": false,
"minWidth": 380,
"minHeight": 660,
"height": 640,
"resizable": true,
"title": "guprod",
"width": 1024,
"visible": false
},
{
"label": "splashscreen",
"center": true,
"width": 256,
"height": 256,
"url": "splashscreen.html",
"decorations": false,
"resizable": false
}
]
}
}
main.rs :
#![cfg_attr(
all(not(debug_assertions), target_os = "windows"),
windows_subsystem = "windows"
)]
use sysinfo::{System, SystemExt};
use tauri::{Manager};
use std::time::Duration;
#[tauri::command]
async fn close_splashscreen(window: tauri::Window){
if let Some(splashscreen) = window.get_window("splashscreen"){
let _two_sec = std::thread::sleep(Duration::new(2, 500_000_000));
splashscreen.close().unwrap();
}
window.get_window("main").unwrap().show().unwrap();
}
fn main() {
let context = tauri::generate_context!();
tauri::Builder::default()
.invoke_handler(tauri::generate_handler![close_splashscreen, base_information]) // Past here function or Object to send?
.run(context)
.expect("error while running tauri application");
}
#[tauri::command]
fn base_information(){
let mut sys = System::new_all();
sys.refresh_all();
println!("System name: {:?}", sys.name().as_ref().map(String::as_str).unwrap());
println!("System OS version: {:?}", sys.os_version().as_ref().map(String::as_str).unwrap());
println!("System Host version: {:?}", sys.host_name().as_ref().map(String::as_str).unwrap());
}
- I installed some non-installed (missing*) packages
- * - They don't help so I think it isn't required :)
- libgtk2.0-cil -> focal 2.12.40-3 amd64
- libc6-amd64-cross -> focal-updates,focal-updates 2.31-0ubuntu9.9cross1 all
Blank tauri project
I tried install empty vite react ts project to check and confirm if error is still occurs.
$ npm create tauri-app
$ npm i
debug:
$ npm run tauri dev
And Bug is still occurs. :(

Having the same issue on MacOS when creating blank projects using the vite option.
tauri.conf.json is generated with "devPath" set to port 3000, should be 5173
"build": {
.....
"devPath": "http://localhost:3000",
},
Getting the same error when I run Cinny.AppImage in Ubuntu 20.04.4 LTS.
Seeing the same error.
To reproduce:
cargo create-tauri-app --template svelte-ts # Choose pnpm / app name "demo"
cd demo/
pnpm i
pnpm tauri dev
env:
$ rustc --version
rustc 1.64.0 (a55dd71d5 2022-09-19)
$ pnpm -v
7.13.0
$ uname -a
Linux ryan-desktop-gpu 5.15.0-48-generic #54~20.04.1-Ubuntu SMP Thu Sep 1 16:17:26 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux
#stdout from `pnpm tauri dev`
...
Finished dev [unoptimized + debuginfo] target(s) in 1m 45s
(process:734023): GLib-CRITICAL **: 07:02:41.906: Failed to set scheduler settings: Operation not permitted
Going to close this because it only concerns Ubuntu 20.04, doesn't seem to actually cause any real issues, and most importantly, afaik is completely outside our control (= upstream issue in the system dependencies).
Thanks for the reports! ❤️
debian 11 have this tips
I encountered the exact same problem on Ubuntu 20.04. How did you solve it?