Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Put-window gnome extension #75889

Closed
chkno opened this issue Dec 18, 2019 · 3 comments
Closed

Put-window gnome extension #75889

chkno opened this issue Dec 18, 2019 · 3 comments
Labels
0.kind: packaging request Request for a new package to be added 2.status: stale https://github.com/NixOS/nixpkgs/blob/master/.github/STALE-BOT.md 6.topic: GNOME GNOME desktop environment and its underlying platform

Comments

@chkno
Copy link
Member

chkno commented Dec 18, 2019

Project description
Put-window gnome extension

Metadata

Here's my attempt in overlay form:

self: super: {

  gnomeExtensions = super.gnomeExtensions // {
    put-window = super.stdenv.mkDerivation rec {
      pname = "gnome-shell-extension-put-window";
      version = "26";

      src = super.fetchFromGitHub {
        owner = "negesti";
        repo = "gnome-shell-extensions-negesti";
        rev = "v${version}";
        sha256 = "0a67k096dl0j3q4hkq6n6354mzqd3mkia3zvw2bp0q79hgg6750l";
      };

      uuid = "[email protected]";

      nativeBuildInputs = [
        self.glib
      ];

      postUnpack = ''
        rm source/schemas/gschemas.compiled
        sed -i "1iimports.gi.GIRepository.Repository.prepend_search_path('${self.libwnck3}/lib/girepository-1.0');" source/extension.js source/prefs.js
      '';

      buildPhase = "make -C schemas";

      installPhase = ''
        mkdir -p $out/share/gnome-shell/extensions/${uuid}
        cp -r * schemas $out/share/gnome-shell/extensions/${uuid}
      '';

      meta = with super.stdenv.lib; {
        description = "An gnome-shell extension that makes window movement a lot easier";
        license = licenses.gpl3Plus;
        maintainers = with maintainers; [ chkno ];
        homepage = https://github.com/negesti/gnome-shell-extensions-negesti;
      };
    };
  };
}

The trouble is that it crashes (SEGV).

Steps to Reproduce the crash

  1. Go to Move Focus tab in this extension's settings.
  2. Click an action, such as "Move the window focus up". It turns blue.
  3. Click the keyboard shortcut in the Modify column. It is replaced by "New accelerator..." while it waits for the new keyboard shortcut.
  4. Press a new keyboard shortcut, such as <Alt><Shift>f.

Expected Behavior

This becomes the new keyboard shortcut.

Current Behavior

The extension settings window closes. These log messages appear in journalctl:

kernel: .gnome-shell-ex[27784]: segfault at 10 ip 00007fc40450cfc0 sp 00007fff2ebe3cc8 error 4 in libgio-2.0.so.0.6000.7[7fc404465000+f6000]
kernel: Code: 15 d6 16 07 00 48 8d 35 1e 1b 07 00 31 db 48 8d 3d 11 25 05 00 e8 40 9e f5 ff 48 83 c4 08 48 89 d8 5b 5d 41 5c 41 5d c3 66 90 <48> 8b 47 10 c3 66 66 2e 0f 1f 84 00 00 00 00 00 48>
systemd[1]: Started Process Core Dump (PID 27920/UID 0).
systemd-coredump[27921]: Process 27784 (.gnome-shell-ex) of user 1000 dumped core.
systemd[1]: [email protected]: Succeeded.

Backtrace:

$ coredumpctl debug
        Signal: 11 (SEGV)
  Command Line: /run/current-system/sw/bin/gnome-shell-extension-prefs [email protected]
    Executable: /nix/store/f4vcsf0rxh2ar6smfq048ja34vh0a06j-gnome-shell-3.32.2/bin/.gnome-shell-extension-prefs-wrapped
       Message: Process 12841 (.gnome-shell-ex) of user 1000 dumped core.

GNU gdb (GDB) 8.3
Program terminated with signal SIGSEGV, Segmentation fault.
(gdb) bt
#0  g_settings_schema_get_path () from libgio-2.0.so.0
#1  g_settings_constructed () from libgio-2.0.so.0
#2  g_object_new_internal () from libgobject-2.0.so.0
#3  g_object_new_with_properties () from libgobject-2.0.so.0
#4  ?? () from libgjs.so.0
#5  ?? () from libgjs.so.0
#6  js::InternalCallOrConstruct(JSContext*, JS::CallArgs const&, js::MaybeConstruct) () from libmozjs-60.so
#7  js::Call(JSContext*, JS::Handle<JS::Value>, JS::Handle<JS::Value>, js::AnyInvokeArgs const&, JS::MutableHandle<JS::Value>) () from libmozjs-60.so
#8  JS_CallFunctionValue(JSContext*, JS::Handle<JSObject*>, JS::Handle<JS::Value>, JS::HandleValueArray const&, JS::MutableHandle<JS::Value>) () from libmozjs-60.so
#9  ?? () from libgjs.so.0
#10 ?? () from libgjs.so.0
#11 ?? () from libgjs.so.0
#12 InternalConstruct(JSContext*, js::AnyConstructArgs const&) () from libmozjs-60.so
#13 Interpret(JSContext*, js::RunState&) () from libmozjs-60.so
#14 js::RunScript(JSContext*, js::RunState&) () from libmozjs-60.so
#15 js::InternalCallOrConstruct(JSContext*, JS::CallArgs const&, js::MaybeConstruct) () from libmozjs-60.so
#16 js::Call(JSContext*, JS::Handle<JS::Value>, JS::Handle<JS::Value>, js::AnyInvokeArgs const&, JS::MutableHandle<JS::Value>) () from libmozjs-60.so
#17 JS_CallFunction(JSContext*, JS::Handle<JSObject*>, JS::Handle<JSFunction*>, JS::HandleValueArray const&, JS::MutableHandle<JS::Value>) () from libmozjs-60.so
#18 gjs_closure_invoke () from libgjs.so.0
#19 ?? () from libgjs.so.0
#20 g_closure_invoke () from libgobject-2.0.so.0
#21 signal_emit_unlocked_R () from libgobject-2.0.so.0
#22 g_signal_emit_valist () from libgobject-2.0.so.0
#23 g_signal_emit () from libgobject-2.0.so.0
#24 gtk_cell_editable_event_box_key_press_event () from libgtk-3.so.0
#25 _gtk_marshal_BOOLEAN__BOXEDv () from libgtk-3.so.0
#26 _g_closure_invoke_va () from libgobject-2.0.so.0
#27 g_signal_emit_valist () from libgobject-2.0.so.0
#28 g_signal_emit () from libgobject-2.0.so.0
#29 gtk_widget_event_internal () from libgtk-3.so.0
#30 propagate_event () from libgtk-3.so.0
#31 gtk_main_do_event () from libgtk-3.so.0
#32 _gdk_event_emit () from libgdk-3.so.0
#33 gdk_event_source_dispatch () from libgdk-3.so.0
#34 g_main_context_dispatch () from libglib-2.0.so.0
#35 g_main_context_iterate.isra () from libglib-2.0.so.0
#36 g_main_context_iteration () from libglib-2.0.so.0
#37 g_application_run () from libgio-2.0.so.0
#38 ffi_call_unix64 () from libffi.so.6
#39 ffi_call () from libffi.so.6
#40 ?? () from libgjs.so.0
#41 ?? () from libgjs.so.0
#42 js::InternalCallOrConstruct(JSContext*, JS::CallArgs const&, js::MaybeConstruct) () from libmozjs-60.so
#43 Interpret(JSContext*, js::RunState&) () from libmozjs-60.so
#44 js::RunScript(JSContext*, js::RunState&) () from libmozjs-60.so
#45 js::Execute(JSContext*, JS::Handle<JSScript*>, JSObject&, JS::Value*) () from libmozjs-60.so
#46 Evaluate(JSContext*, js::ScopeKind, JS::Handle<JSObject*>, JS::ReadOnlyCompileOptions const&, JS::SourceBufferHolder&, JS::MutableHandle<JS::Value>) () from libmozjs-60.so
#47 JS::Evaluate(JSContext*, JS::AutoVector<JSObject*>&, JS::ReadOnlyCompileOptions const&, JS::SourceBufferHolder&, JS::MutableHandle<JS::Value>) () from libmozjs-60.so
#48 ?? () from libgjs.so.0
#49 ?? () from libgjs.so.0
#50 gjs_context_eval () from libgjs.so.0
#51 main ()

call (void) gjs_dumpstack() from the instructions for getting a JS backtrace yielded no output.

Your Environment

  • gnome-shell version: 3.32.2
  • distribution: NixOS 19.09.
@chkno chkno added the 0.kind: packaging request Request for a new package to be added label Dec 18, 2019
@veprbl veprbl added the 6.topic: GNOME GNOME desktop environment and its underlying platform label Dec 18, 2019
@stale
Copy link

stale bot commented Jun 21, 2020

Thank you for your contributions.

This has been automatically marked as stale because it has had no activity for 180 days.

If this is still important to you, we ask that you leave a comment below. Your comment can be as simple as "still important to me". This lets people see that at least one person still cares about this. Someone will have to do this at most twice a year if there is no other activity.

Here are suggestions that might help resolve this more quickly:

  1. Search for maintainers and people that previously touched the related code and @ mention them in a comment.
  2. Ask on the NixOS Discourse.
  3. Ask on the #nixos channel on irc.freenode.net.

@stale stale bot added the 2.status: stale https://github.com/NixOS/nixpkgs/blob/master/.github/STALE-BOT.md label Jun 21, 2020
@chkno
Copy link
Member Author

chkno commented Jun 10, 2021

The how-to-package-this-gnome-extension? spirit of this issue is obsoleted by #118232, which packaged all the gnome extensions as published in the Gnome extension database rather than building them from sources.

@chkno chkno closed this as completed Jun 10, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
0.kind: packaging request Request for a new package to be added 2.status: stale https://github.com/NixOS/nixpkgs/blob/master/.github/STALE-BOT.md 6.topic: GNOME GNOME desktop environment and its underlying platform
Projects
None yet
Development

No branches or pull requests

3 participants