chrisjbillington / git-nautilus-icons

A nautilus Python extension to overlay icons on files in git repositories
BSD 2-Clause "Simplified" License
43 stars 4 forks source link

key.png does not have green check #12

Closed nicolas-raoul closed 5 years ago

nicolas-raoul commented 5 years ago

Steps to reproduce:

  1. Install per the README instructions
  2. Kill then open Nautilus and browse the git_nautilus_icons folder itself
  3. Expected: key.png has a green mark like all other files (I have not modified anything). Actually: No green mark.

screenshot from 2019-02-18 11-11-37

I tried twice. Up-to-date Ubuntu 2018.04.1 LTS with Nautilus 3.26.4

nicolas-raoul commented 5 years ago

I set DEBUG to True and here is the log:

$ nautilus
sys:1: PyGIWarning: Nautilus was imported without specifying a version first. Use gi.require_version('Nautilus', '3.0') before import to ensure that the right version gets loaded.
Nautilus-Share-Message: 11:20:54.472: Called "net usershare info" but it failed: Failed to execute child process “net” (No such file or directory)
worker: git status loop: triggered
directory_status: /home/nico
repo status: /home/nico/git_nautilus_icons
parent: timeout
worker sending 0 processed files
parent: got response: STILL_WORKING
directory_status: /home/nico
parent: timeout
worker sending 0 processed files
parent: got response: STILL_WORKING
repo status: /home/nico/git_nautilus_icons
adding to ready set: /home/nico/git_nautilus_icons
worker: git status loop: triggered
parent: timeout
worker sending 1 processed files
parent: got response: ALL_DONE
adding icon for file: /home/nico/git_nautilus_icons
worker: git status loop: triggered
directory_status: /home/nico/git_nautilus_icons
repo status: /home/nico/git_nautilus_icons
parent: timeout
worker sending 0 processed files
parent: got response: STILL_WORKING
adding to ready set: /home/nico/git_nautilus_icons/key.png
adding to ready set: /home/nico/git_nautilus_icons/icons
adding to ready set: /home/nico/git_nautilus_icons/LICENSE
adding to ready set: /home/nico/git_nautilus_icons/git-nautilus-icons.py
adding to ready set: /home/nico/git_nautilus_icons/icon_testing_dir
adding to ready set: /home/nico/git_nautilus_icons/README.md
parent: timeout
worker sending 6 processed files
parent: got response: ALL_DONE
adding icon for file: /home/nico/git_nautilus_icons/git-nautilus-icons.py
adding icon for file: /home/nico/git_nautilus_icons/key.png
adding icon for file: /home/nico/git_nautilus_icons/README.md
adding icon for file: /home/nico/git_nautilus_icons/icon_testing_dir
adding icon for file: /home/nico/git_nautilus_icons/icons
adding icon for file: /home/nico/git_nautilus_icons/LICENSE
chrisjbillington commented 5 years ago

Thanks! I can reproduce this when I set nautilus to show file previews (I previously had it set to not show previews, in which case I don't observe the bug). Interestingly, I have another image file in the same repo (an untracked one) that gets an icon just fine when it is previewed:

image

I also get this warning from Nautilus:

(nautilus:16430): GdkPixbuf-CRITICAL **: 21:28:23.094: gdk_pixbuf_composite: assertion 'dest_x >= 0 && dest_x + dest_width <= dest->width' failed

Which sounds like maybe Nautilus is doing some incorrect pixel math, perhaps triggered by key.png's extreme aspect ratio.

I think I'll report this as a bug against Nautilus, since it looks like the extension is probably not doing anything wrong.

nicolas-raoul commented 5 years ago

Another one: screenshot from 2019-02-18 11-43-51

nicolas-raoul commented 5 years ago

A few other ones. Unfortunately most of my files are images lol screenshot from 2019-02-18 11-48-46 screenshot from 2019-02-18 11-49-16 screenshot from 2019-02-18 11-48-58

chrisjbillington commented 5 years ago

Thanks! This is more evidence that it affects image files with a high aspect ratio.

I've reported the bug upstream here, and suspect there's not much that I can do in this extension unless it is fixed in Nautilus. Will wait to see what Nautilus devs say about the bug report in case I've misunderstood something.

nicolas-raoul commented 5 years ago

Nice bug report! I guess you could create an GitHub label called upstream to mark issues like this one, where resolution requires upstream progress? Thanks!

chrisjbillington commented 5 years ago

Patch submitted upstream

chrisjbillington commented 5 years ago

Patch was merged and released in nautilus 3.32.2

image