Commit Graph

226 Commits (master)
 

Author SHA1 Message Date
seebye 5995be053c archiving 1 year ago
seebye 52855b2493 remove author name 1 year ago
seebye 0745998c0d bug fixes + concurrent X11 threads
This commit updates the author.
It also contains the following changes:
- initializes Xlib support for concurrent threads
- fix minor device number calculation for large values
- fix crash if there are multiple pty slave folders

fix minor device number calculation for large values

Unfortunately the extraction of the minor device number from the tty_nr
was wrong.
The man page of procfs states that 'The minor device number is contained
[in the tty_nr] in the combination of bits 31 to 20 and 7 to 0' but it did not state
that you need to shift the bits together.
So I just missed that step.
This commit adds the correct placement of the bits to the calculation of the minor device number.

fix crash if there are multiple pty slave folders

If a system uses multiple pty slave folders it is possible that while
searching for the pty file a FileNotFoundError is raised which crashs
the program. In this case the correct behavior would be to look for the
pty file in the next folder. So this commit ignores the
FileNotFoundError for the call of the stat function.
1 year ago
seebye 3780b8155e Support the pull request policy by using github actions.
pragmatic bash code to close pull requests from forks
3 years ago
seebye 31463ec815 Build wheels for releases by using github actions.
pragmatic bash code to build and add wheels to releases
3 years ago
seebye 24cb0a7be1 adjustments to support gcc10
Gcc changed its default behaviour in version 10.
-fno-common is now used by default instead of -fcommon.
Therefore the usage of the extern keyword is required.
3 years ago
seebye 07a79980de fix copy & paste error
While copying the entry of the property screen_width to create the
entry of the property screen_height it was forgotten
to rename the function Display_get_screen_width to
Display_get_screen_height.
3 years ago
seebye 6c6a795438
Merge pull request #146 from seebye/drop-python-xlib
drop python-xlib
3 years ago
seebye 11aad51903 drop python-xlib
Python-xlib misses some essential features like shm support.
This is why the Xshm module was written,
but this leads to redundant dependencies.
So this commit removes python-xlib as dependency.

During the translation of the code the determination of the pid of a
window was also improved.
The XRes extension is now used to determine the pid of a window.
3 years ago
seebye f5414aa201 fix safe sending signals (spelling mistake)
os.pidfile_open should be os.pidfd_open.
This was not noticed as the linux kernel this software is tested on does
not support the required syscalls.
os.pidfile was replaced by os.open
as os.pidfd_open requires at least linux 5.3 and
signal.pidfd_send_signal requires at least linux 5.1.

see also 7483451577
3 years ago
seebye e3ea6d651f unicode author name
The author was spelled by using ascii characters only.
We no longer insist it to be written in ascii characters only.
3 years ago
seebye 9872c4fbaa
warn about patches in third party packages 3 years ago
seebye 08fb245467 release new version 3 years ago
seebye 3078a19f6d
warn not to use simple parser
Simple parser was only intended for quick test and not for beeing used in production.  
So add a warning not to use it.
3 years ago
seebye 761f134d22
Merge pull request #133 from seebye/determining-pty
pty determining by using the tty_nr
3 years ago
seebye 83a0e9937d pty determining by using the tty_nr
In some situations some programs like zsh are replacing their file
descriptors temporarily.
E.g. zsh replaces (at least on my system) stdout with a pipe on using widgets
(these changes are reverted after finishing using the widget)
So by now the tty_nr is used to figure out the pseudo tty of the
terminal emulator.

Also this change contains the removal of psutil.
The process information is gathered now by using the proc file system.
Reasons:
- the only os supported by this program is linux
- only the function to retrieve the ppid of a process was used
3 years ago
seebye 2f061d25ba release new version 3 years ago
seebye de92cf4a3c
Merge pull request #128 from seebye/python39-asyncio-removal
fix python39 lack of backwards compatibility
3 years ago
seebye aa8de598e8 fix python39 lack of backwards compatibility
In python3.9 asyncio.Task.all_task() and asyncio.Task.current_task() were removed.
See: https://docs.python.org/3/whatsnew/3.9.html#removed
They advise to use asyncio.all_task() and asyncio.current_task()
instead.
At the time of this commit python3.6 is still used by 10% of the users
(counted by the reported python version of the downloads).
So we need to reduce the readability by adding redundant try except
blocks.
3 years ago
seebye 5f63b0c203 release new version 3 years ago
seebye 2aa5c0ea3b use threads for image decoding by default 4 years ago
seebye 9a3ef352a5
Merge pull request #121 from seebye/version-command
Version command
4 years ago
seebye fea8b102bb add version command 4 years ago
seebye e25252d38b move project metadata to __init__ 4 years ago
seebye a1f5b7175b
Create pull_request_template.md 4 years ago
seebye 5d5a99d12f
Merge pull request #119 from seebye/orphans
fix process orphans
4 years ago
seebye f28eea72a4 fix uncatched exception in finalisation of canvas process
If the canvas process exited unexpectly os.getpgid will throw an
ProcessLookupError,
so we need to catch it.
4 years ago
seebye 98c93c739c send SIGUSR1 signals only to ueberzug processes 4 years ago
seebye ff5ff632ba fix process orphans
In some situations worker processes turned into orphans.
To fix this (1.) a new session is created for the canvas process and
it's killed by its pgid if it won't exit within a second
(if it's told to do so).
(2.) Also the missing shutdown call for the ProcessPoolExecutor was added.
4 years ago
seebye 7df7f182aa deprecate bash library 4 years ago
seebye 38766f6d27
Merge pull request #109 from seebye/python-requirements
update the minimum required python version
4 years ago
seebye d49b546a19 update the minimum required python version 4 years ago
seebye 19f252e022 publish version 18.1.6 4 years ago
seebye 5441ddbf4d fix stderr suppression 4 years ago
seebye d86eeb303b
Merge pull request #90 from seebye/embed-terminal
fix font size for embed pty
4 years ago
seebye dcca045837 fix font size for embed pty 4 years ago
seebye fba87ea81b
Merge pull request #85 from seebye/limit-resolution-of-stored-images
loading images: convert L,P mode PNGs to RGBA PNGs
4 years ago
seebye 23a2230357 loading images: convert L,P mode PNGs to RGBA PNGs
L,P PNGs with transparency will be converted to RGBA PNGs
to surpress the following warning (pillow):
Palette images with Transparency expressed in bytes should be
converted to RGBA images
4 years ago
seebye 6f488070a8
Merge pull request #83 from seebye/limit-resolution-of-stored-images
store big images in a lower resolution
4 years ago
seebye ea6d514a9d store big images in a lower resolution
There are common sizes in which images are
likely to be displayed in.
(smaller or equal to the screen size)
If images reach a specific resolution the
principle of spatial locality doesn't apply anymore
to resize operations to common sizes
(e.g. 6000x6000 to 300x300).
So to reduce cache misses and therefore avoid
a worse performance images are stored by default up to a size
which is about the same as the screen size.
Images will be fully loaded if it's required by their
image scaler or if they should be displayed with a size
which is bigger than the screen size.
4 years ago
seebye 5b22fee38f adjust used displays 4 years ago
seebye 52b0b5e5b8 Fix race condition between creating a window and drawing on it
Reason:
Xshm is used to draw on windows (via original Xlib / c extension).
So there are at least two connections to the X11 server.
-> Race condition between drawing on windows (Xlib)
   and creating them (python-Xlib)
4 years ago
seebye 68e9ec23d6
Merge pull request #79 from seebye/attrs-min-version
specify required min. version of attrs
4 years ago
seebye 21ff229de0 specify required min. version of attrs 4 years ago
seebye a8ac9c345c bugfix: division by zero if only width or only height specified 5 years ago
seebye 45d225b4a8 switch back to pillow due to user complains
switch back to pillow due to user complains
and their inability of using the search function
5 years ago
seebye d1618b30c7 mention urwid library 5 years ago
seebye 75c3ca2761 remove magic number 5 years ago
seebye db97f24378 workaround: pillow restores images received from another process wrongly
Sometimes pillow restores pngs as webp
(or at least it reports png to be webp)
Using a function on these objects lead to a crash.
It can be fixed by using less data (info & palette removed)
to restore an image.
5 years ago
seebye e27fa0edae add option to disable automatic command transmission 5 years ago