Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: python-xlib/python-xlib
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: master
Choose a base ref
...
head repository: selkies-project/python-xlib
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: master
Choose a head ref
  • 2 commits
  • 2 files changed
  • 2 contributors

Commits on May 1, 2024

  1. randr: inherit XError in error classes (#1)

    Commit c87624d ('Add Randr error classes and register them during
    init') introduces three new error classes to xrandr, but makes them
    inherit from Exception.
    
    Let all error classes in randr inherit from Xerror, like all other code
    expects.
    
    Fixes the traceback
    
    ```
    ...
      File "/tmp/python-env/lib/python3.8/site-packages/Xlib/display.py", line 182, in sync
        self.get_pointer_control()
      File "/tmp/python-env/lib/python3.8/site-packages/Xlib/display.py", line 833, in get_pointer_control
        return request.GetPointerControl(display = self.display)
      File "/tmp/python-env/lib/python3.8/site-packages/Xlib/protocol/rq.py", line 1369, in __init__
        self.reply()
      File "/tmp/python-env/lib/python3.8/site-packages/Xlib/protocol/rq.py", line 1381, in reply
        self._display.send_and_recv(request = self._serial)
      File "/tmp/python-env/lib/python3.8/site-packages/Xlib/protocol/display.py", line 612, in send_and_recv
        gotreq = self.parse_response(request)
      File "/tmp/python-env/lib/python3.8/site-packages/Xlib/protocol/display.py", line 719, in parse_response
        gotreq = self.parse_error_response(request) or gotreq
      File "/tmp/python-env/lib/python3.8/site-packages/Xlib/protocol/display.py", line 745, in parse_error_response
        req = self.get_waiting_request(e.sequence_number)
    AttributeError: 'BadRRModeError' object has no attribute 'sequence_number'
    ```
    
    fixes #241
    
    Co-authored-by: Frans Klaver <[email protected]>
    ehfd and fransklaver authored May 1, 2024

    Verified

    This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
    Copy the full SHA
    1f68858 View commit details

Commits on Mar 23, 2025

  1. Fix package build

    ehfd committed Mar 23, 2025
    Copy the full SHA
    583fe2e View commit details
Showing with 4 additions and 4 deletions.
  1. +4 −3 Xlib/ext/randr.py
  2. +0 −1 setup.py
7 changes: 4 additions & 3 deletions Xlib/ext/randr.py
Original file line number Diff line number Diff line change
@@ -36,6 +36,7 @@

from Xlib import X
from Xlib.protocol import rq
from Xlib.error import XError

extname = 'RANDR'

@@ -123,11 +124,11 @@
BadRRMode = 2

# Error classes #
class BadRROutputError(Exception): pass
class BadRROutputError(XError): pass

class BadRRCrtcError(Exception): pass
class BadRRCrtcError(XError): pass

class BadRRModeError(Exception): pass
class BadRRModeError(XError): pass

# Data Structures #

1 change: 0 additions & 1 deletion setup.py
Original file line number Diff line number Diff line change
@@ -11,7 +11,6 @@

setup(
install_requires=['six>=1.10.0'],
setup_requires=['setuptools-scm'],
packages=[
'Xlib',
'Xlib.ext',