Skip to content

Binding <Control-space> fails #45313

Closed
Closed

Description

@aligrudi
mannequin
BPO 1774736
Nosy @loewis
Superseder
  • bpo-1028: Tkinter binding involving Control-spacebar raises unicode error
  • Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.

    Show more details

    GitHub fields:

    assignee = 'https://github.com/loewis'
    closed_at = <Date 2007-09-10.21:28:35.969>
    created_at = <Date 2007-08-15.14:34:06.000>
    labels = ['expert-tkinter']
    title = 'Binding <Control-space> fails'
    updated_at = <Date 2008-01-06.22:29:46.719>
    user = 'https://bugs.python.org/aligrudi'

    bugs.python.org fields:

    activity = <Date 2008-01-06.22:29:46.719>
    actor = 'admin'
    assignee = 'loewis'
    closed = True
    closed_date = <Date 2007-09-10.21:28:35.969>
    closer = 'loewis'
    components = ['Tkinter']
    creation = <Date 2007-08-15.14:34:06.000>
    creator = 'aligrudi'
    dependencies = []
    files = []
    hgrepos = []
    issue_num = 1774736
    keywords = []
    message_count = 2.0
    messages = ['32644', '55792']
    nosy_count = 2.0
    nosy_names = ['loewis', 'aligrudi']
    pr_nums = []
    priority = 'normal'
    resolution = 'duplicate'
    stage = None
    status = 'closed'
    superseder = '1028'
    type = None
    url = 'https://bugs.python.org/issue1774736'
    versions = ['Python 3.0']

    Activity

    1. aligrudi commented on Aug 15, 2007

      aligrudimannequin
      MannequinAuthor

      In py3k branch r57057, when I run::

        import Tkinter
      
        tk = Tkinter.Tk()
        text = Tkinter.Text(tk)
      
        def callback(event=None):
            return
      
        text.bind('<Control-space>', callback)
        text.pack()
        text.focus_set()
        tk.mainloop()

      when I press C-space I get this exception::

        Traceback (most recent call last):
          File "spacefailure.py", line 13, in <module>
            tk.mainloop()
          File "/usr/local/lib/python3.0/lib-tk/Tkinter.py",  line 1022, in mainloop
            self.tk.mainloop(n)
        UnicodeDecodeError: 'utf8' codec can't decode bytes in position 0-1: illegal encoding

      The strange thing about it is that other bindings work
      as expected.

      I'm running on ubuntu feisty.

    2. aligrudi commented on Sep 10, 2007

      aligrudimannequin
      MannequinAuthor

      The same as bpo-1028. Fixed in r57450.

    3. transferred this issue fromon Apr 10, 2022
    Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

    Metadata

    Metadata

    Assignees

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions