Skip to content

ImportOrganizer should not remove imports used in string type annotation #369

Done

Description

@lieryan

PEP-3107 type annotation can be specified as string, but rope does not currently recognize these as annotations.

Example code:

from foo import Baz

class C(object):

    var: 'Baz' = 1

Reorganizing import currently will remove from foo import Baz.

rope==0.19.0

Activity

  1. changed the title [-]ImportOrganizer should not remove types used in string type annotation[/-] [+]ImportOrganizer should not remove imports used in string type annotation[/+] on Sep 7, 2021
  2. added this to the 0.21.0 milestone on Sep 7, 2021
  3. modified the milestones: 0.21.x, 0.22.x on Sep 19, 2021
  4. modified the milestones: 0.22.x, 0.23.0, 0.24.0 on Nov 22, 2021
  5. modified the milestones: 1.1.0, 1.2.0 on May 20, 2022
  6. modified the milestones: 1.2.0, 1.3.0 on Jun 17, 2022
  7. modified the milestones: 1.3.0, 1.4.0 on Jul 12, 2022
  8. added
    bug
    on Oct 5, 2022
  9. modified the milestones: 1.4.0, 1.5.0 on Oct 21, 2022
  10. modified the milestones: 1.5.0, 1.6.0 on Nov 22, 2022
  11. modified the milestones: 1.6.0, 1.7.0 on Dec 15, 2022
  12. removed this from the 1.7.0 milestone on Jan 17, 2023
  13. moved this to 🆕 New in Kanbanon Jan 17, 2023
  14. moved this from 🆕 New to ✅ Done in Kanbanon Dec 3, 2026
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

    affected-version:0.19bugimport-organizer

    Type

    No type

    Projects

    • Status
      ✅ Done

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions