rust-windowing / glutin

A low-level library for OpenGL context creation
Apache License 2.0
1.98k stars 476 forks source link

GL Context Creation failed error on Archlinux/X11 #1007

Closed ishanjain28 closed 6 years ago

ishanjain28 commented 6 years ago

This issue occured when I was using Alacritty but this is more of a glutin error than alacritty, So, I am creating this issue here.

Arch Linux Linux y50 4.15.13-1-ARCH #1 SMP PREEMPT Sun Mar 25 11:27:57 UTC 2018 x86_64 GNU/Linux X11

I have the following applications open.

  1. 2 firefox windows, Each with 50+ tabs.
  2. Music playing on spotify
  3. Telegram/Thunderbird.
  4. 3 Alacritty windows working normally without any problems what so ever!

Then, I close all alacritty windows, and after a moment I press the short cut keys to start alacritty and nothing happens, So, I open xterm, And run the alacritty command, And it prints this error and doesn't starts anymore.

This has happened before and every single time, It's the applications that use OpenGL that refuse to start.

I tried running couple more opengl projects that were using glium, which just like alacritty uses glutin to create window, All of them print this error and exit.

Backtrace

Finished release [optimized] target(s) in 0.0 secs
Running `target/release/conway-game-of-life`
thread 'main' panicked at 'called `Result::unwrap()` on an `Err` value: GlutinCreationError(OsError("GL context creation failed"))', libcore/result.rs:945:5
stack backtrace:
   0: std::sys::unix::backtrace::tracing::imp::unwind_backtrace
             at libstd/sys/unix/backtrace/tracing/gcc_s.rs:49
   1: std::sys_common::backtrace::_print
             at libstd/sys_common/backtrace.rs:71
   2: std::panicking::default_hook::{{closure}}
             at libstd/sys_common/backtrace.rs:59
             at libstd/panicking.rs:380
   3: std::panicking::default_hook
             at libstd/panicking.rs:396
   4: std::panicking::rust_panic_with_hook
             at libstd/panicking.rs:576
   5: std::panicking::begin_panic
             at libstd/panicking.rs:537
   6: std::panicking::begin_panic_fmt
             at libstd/panicking.rs:521
   7: rust_begin_unwind
             at libstd/panicking.rs:497
   8: core::panicking::panic_fmt
             at libcore/panicking.rs:71
   9: core::result::unwrap_failed
  10: conway_game_of_life::main
  11: std::rt::lang_start::{{closure}}
  12: std::panicking::try::do_call
             at libstd/rt.rs:59
             at libstd/panicking.rs:479
  13: __rust_maybe_catch_panic
             at libpanic_unwind/lib.rs:102
  14: std::rt::lang_start_internal
             at libstd/panicking.rs:458
             at libstd/panic.rs:358
             at libstd/rt.rs:58
  15: main
  16: __libc_start_main
  17: _start
ishanjain28 commented 6 years ago

Since, This is happening with every OpenGL application, I also asked this on Arch linux forum.

https://bbs.archlinux.org/viewtopic.php?pid=1776862#p1776862

One of the replies there give the reason which makes sense. So, This is not a problem in glutin and as such, I'll close this issue. Apologies for the trouble.