Skip to content

Moving lib-tk to tkinter package #47088

Closed

Description

@gpolo
mannequin
BPO 2839
Nosy @brettcannon, @birkenfeld
Files
  • tkinter_package.py: creates tkinter package with renamed lib-tk files
  • tkinter_imports.diff: fix imports inside new tkinter package
  • tkinter_step2.diff
  • tkinter_doc_updates.diff: tkinter doc updates patch
  • rename_tkdocs.py
  • remove_libtk_path.diff
  • tkinter_modmerge.diff
  • tkinter_modmerge_py3k.diff
  • 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 = None
    closed_at = <Date 2008-05-20.07:27:21.718>
    created_at = <Date 2008-05-12.18:00:38.698>
    labels = ['library', 'release-blocker']
    title = 'Moving lib-tk to tkinter package'
    updated_at = <Date 2008-05-20.07:27:21.687>
    user = 'https://bugs.python.org/gpolo'

    bugs.python.org fields:

    activity = <Date 2008-05-20.07:27:21.687>
    actor = 'georg.brandl'
    assignee = 'none'
    closed = True
    closed_date = <Date 2008-05-20.07:27:21.718>
    closer = 'georg.brandl'
    components = ['Library (Lib)']
    creation = <Date 2008-05-12.18:00:38.698>
    creator = 'gpolo'
    dependencies = []
    files = ['10309', '10310', '10346', '10348', '10349', '10350', '10354', '10358']
    hgrepos = []
    issue_num = 2839
    keywords = ['patch']
    message_count = 12.0
    messages = ['66747', '66756', '66951', '66952', '66955', '66957', '66999', '67000', '67010', '67012', '67099', '67109']
    nosy_count = 3.0
    nosy_names = ['brett.cannon', 'georg.brandl', 'gpolo']
    pr_nums = []
    priority = 'release blocker'
    resolution = 'fixed'
    stage = None
    status = 'closed'
    superseder = None
    type = None
    url = 'https://bugs.python.org/issue2839'
    versions = ['Python 2.6', 'Python 3.0']

    Activity

    1. gpolo commented on May 12, 2008

      gpolomannequin
      MannequinAuthor

      I'm moving lib-tk to a tkinter package, I've sent a patch for this which
      can be found at bpo-2775 but I started wrong (did a patch against py3k
      directly).

    2. added
      stdlibStandard Library Python modules in the Lib/ directory
      on May 12, 2008
    3. gpolo commented on May 12, 2008

      gpolomannequin
      MannequinAuthor

      I've talked with Brett and we agreed on a plan slightly different from
      the one described in PEP-3108, which seems to be better for tkinter.

      The first step would be creating a tkinter package and then moving each
      file in lib-tk to this new directory, correcting imports and the case
      and renaming Tkinter.py to __init__.py so the directory is marked as a
      package.

      After this step I can proceed with more patches, including stub modules,
      tests in test_py3kwarn and continue with the rest of the plan.

      I'm attaching two files I've used to do this first step. One is a .py
      file, which will do the proper renamings and then there is a patch which
      should be applied to fix imports inside the tkinter package.

    4. gpolo commented on May 16, 2008

      gpolomannequin
      MannequinAuthor

      New patch, this one does the following:

      • Fix tkinter imports in idlelib, pydoc and Canvas (deprecated)
      • Creates stub modules for all old Tkinter modules, except tkFileDialog
        and tkSimpleDialog
      • Updates test_py3kwarn for all these renames

      What is missing now:

      • Merging tkSimpleDialog into tkinter.simpledialog and tkFileDialog into
        tkinter.filedialog, I believe this should be done using svn merge and
        then correct the result a bit.
      • Update docs
    5. birkenfeld commented on May 16, 2008

      @birkenfeld
      Member

      Committed step 2 patch as r63376.

    6. gpolo commented on May 16, 2008

      gpolomannequin
      MannequinAuthor

      Patching for updating the docs added.

      I've also added a script that should be executed after the patch is
      applied, it will rename scrolledtext.rst to tkinter.scrolledtext.rst;
      tix.rst to tkinter.rst and turtle.rst to tkinter.turtle.rst.

    7. gpolo commented on May 16, 2008

      gpolomannequin
      MannequinAuthor

      After merging all these changes in py3k, lib-tk should be removed from
      sys.path there. Patch added for this.

      Note that the iss script at PC/VS7.1 should be regenerated

    8. gpolo commented on May 17, 2008

      gpolomannequin
      MannequinAuthor

      This new patch handles the merging of tkSimpleDialog into
      tkinter.simpledialog and tkFileDialog into
      tkinter.filedialog.

      After doing it, the old files may be removed from lib-tk:
      svn del Lib/lib-tk/tkSimpleDialog.py
      svn del Lib/lib-tk/tkFileDialog.py

      I will do the stub modules for these modules after the commit then, thanks.

    9. birkenfeld commented on May 17, 2008

      @birkenfeld
      Member

      Committed modmerge patch in r63408.

    10. gpolo commented on May 17, 2008

      gpolomannequin
      MannequinAuthor

      Patch added for handling the merging of tkSimpleDialog into
      tkinter.simpledialog and tkFileDialog into tkinter.filedialog, specific
      for py3k.

    11. birkenfeld commented on May 17, 2008

      @birkenfeld
      Member

      Handled Py3k branch in revs 63417 to 63423. Closing this issue.

    12. brettcannon commented on May 20, 2008

      @brettcannon
      Member

      The changes in 2.6 need to be reverted, leaving only a note in the docs.

    13. birkenfeld commented on May 20, 2008

      @birkenfeld
      Member

      Done in r63485-63491.

    14. 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

    No one assigned

      Labels

      release-blockerstdlibStandard Library Python modules in the Lib/ directory

      Projects

      No projects

        Milestone

        No milestone

        Relationships

        None yet

        Development

        No branches or pull requests

        Issue actions