Skip to content

py39: remove deprecation note for xml.etree.cElementTree #84246

Closed as not planned

Description

@freddrake
BPO 40065
Nosy @freddrake, @taleinat, @tiran, @serhiy-storchaka, @DahlitzFlorian, @Zheaoli, @idomic, @caje731, @iritkatriel

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 = None
created_at = <Date 2020-03-25.19:09:39.026>
labels = ['easy', '3.9', 'docs']
title = 'py39: remove deprecation note for xml.etree.cElementTree'
updated_at = <Date 2022-03-22.15:27:54.687>
user = 'https://github.com/freddrake'

bugs.python.org fields:

activity = <Date 2022-03-22.15:27:54.687>
actor = 'iritkatriel'
assignee = 'docs@python'
closed = False
closed_date = None
closer = None
components = ['Documentation']
creation = <Date 2020-03-25.19:09:39.026>
creator = 'fdrake'
dependencies = []
files = []
hgrepos = []
issue_num = 40065
keywords = ['easy']
message_count = 18.0
messages = ['365016', '365073', '365076', '365078', '365079', '365084', '366240', '369474', '369480', '369487', '370822', '370995', '370998', '370999', '371001', '371005', '371960', '415788']
nosy_count = 10.0
nosy_names = ['fdrake', 'taleinat', 'christian.heimes', 'docs@python', 'serhiy.storchaka', 'DahlitzFlorian', 'Manjusaka', 'Ido Michael', 'cajetan.rodrigues', 'iritkatriel']
pr_nums = []
priority = 'normal'
resolution = None
stage = None
status = 'open'
superseder = None
type = None
url = 'https://bugs.python.org/issue40065'
versions = ['Python 3.9']

Activity

  1. freddrake commented on Mar 25, 2020

    @freddrake
    MemberAuthor

    Since xml.etree.cElementTree does not exist in Python 3.9, the statement that it's deprecated should be removed from the documentation.

  2. Zheaoli commented on Mar 26, 2020

    Zheaolimannequin
    Mannequin

    I will clean this

    This issue looks like the same with https://bugs.python.org/issue40064

  3. freddrake commented on Mar 26, 2020

    @freddrake
    MemberAuthor

    Same core problem (module removed with insufficient document update), but a different action is needed for 3.8 and 3.9.

    When I started testing an application with 3.9 and found one of the dependencies broken because it was relying directly on xml.etree.cElementTree, I had to dig into the history to determine that it was removed intentionally. Updated documentation would have helped.

    I did file an issue on the dependency as well:
    boto/botocore#2002

  4. serhiy-storchaka commented on Mar 26, 2020

    @serhiy-storchaka
    Member

    Thank you for catching this Fred. I am surprised that some code uses xml.etree.cElementTree without falling back to xml.etree.ElementTree. In Python 3 you can just use xml.etree.ElementTree, in Python 2 you have to fallback to the Python implementation because the C implementation was optional.

  5. serhiy-storchaka commented on Mar 26, 2020

    @serhiy-storchaka
    Member

    The common idiom is

    try:
    import xml.etree.cElementTree as ET
    except ImportError:
    import xml.etree.ElementTree as ET

  6. freddrake commented on Mar 26, 2020

    @freddrake
    MemberAuthor

    The Python 2.7 documentation was not clear that xml.etree.cElementTree was optional, so users who didn't dive into the implementation or build process could easily not have known unless someone with a more limited installation used their code.

  7. caje731 commented on Apr 12, 2020

    caje731mannequin
    Mannequin

    For the record, I submitted a fix to the dependent:

    boto/botocore#2015

  8. 2 remaining items

  9. Zheaoli commented on May 21, 2020

    Zheaolimannequin
    Mannequin

    I'm working on it. I will make a PR today.

  10. idomic commented on Jun 6, 2020

    idomicmannequin
    Mannequin

    Tal, is there a decision to this debate or can I just move the dep. warning?

  11. taleinat commented on Jun 8, 2020

    @taleinat
    Contributor

    AFAICT from following the discussion, the decision is to hold off on a few deprecations which were causing most of the breakage. However, this does not appear to include xml.etree.cElementTree. Since that has currently been removed in the 3.9 branch, we should indeed fix the docs accordingly.

    (Note that previous versions' docs, especially 3.8, should also be updated in this regard, as per the other issue Fred opened about this, bpo-40064.)

  12. taleinat commented on Jun 8, 2020

    @taleinat
    Contributor

    (Also, please note that the "master" branch is now for version 3.10; PRs for version 3.9 should be based on the "3.9" branch, and the pull request made for that branch too.)

  13. taleinat commented on Jun 8, 2020

    @taleinat
    Contributor

    (My mistake! This should be done from/against the master branch, and then back-ported to 3.9, as usual.)

  14. tiran commented on Jun 8, 2020

    @tiran
    Member

    No, please don't change the docs yet. I want to re-introduce the cElementTree and go through a proper deprecation phase.

  15. taleinat commented on Jun 8, 2020

    @taleinat
    Contributor

    Ah, thanks for the update Christian, I must have misunderstood your intentions.

    So should the deprecation note be removed in the "master" branch for 3.10?

  16. idomic commented on Jun 20, 2020

    idomicmannequin
    Mannequin

    Thanks Tal.

    Yes, I also got the impression we want to clean this, sorry Christian.

    Please let me know how to follow up on this.

  17. iritkatriel commented on Mar 22, 2022

    @iritkatriel
    Member

    We are currently debating to bring the module back and warn users that it will be removed in 3.10.

    Doesn't look like it was removed in 3.10. Was this an oversight?

  18. transferred this issue fromon Apr 10, 2022
  19. jacobtylerwalls commented on May 16, 2022

    @jacobtylerwalls
    Contributor

    Doesn't look like it was removed in 3.10. Was this an oversight?

    From #80724 (comment) there seems to be no consensus for either removing the module or adding real deprecation warnings. I did end up following the suggestion in #80724 (comment) and got pylint to emit a deprecated-module warning: pylint-dev/pylint#5863.

  20. mblahay commented on Apr 24, 2023

    @mblahay
    Contributor

    Does this issue require additional research or can it be closed?

  21. jacobtylerwalls commented on Oct 29, 2024

    @jacobtylerwalls
    Contributor

    I think it can be closed. The issue is premised on the removal of cElementTree, but that removal was reverted in #20117.

    If there is a plan to resolve the diverging views summarized in #80724 (comment), I think it would be best done on a new issue.

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

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions