Skip to content

3.6.1rc1 adds the current directory to sys.path when running a subdirectory's __main__.py; previous versions did not #73909

@nedbat

Description

@nedbat
BPO 29723
Nosy @ncoghlan, @nedbat, @ned-deily, @ericsnowcurrently, @eryksun, @zooba
PRs
  • WIP: bpo-29723: Set sys.path[0] correctly for importer-as-main #571
  • bpo-29723: Consistently configure sys.path[0] #575
  • [3.6] bpo-29723: Consistently configure sys.path[0] #636
  • bpo-29723: Add missing NEWS entry #638
  • 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/ncoghlan'
    closed_at = <Date 2017-03-12.11:38:57.611>
    created_at = <Date 2017-03-05.13:31:48.921>
    labels = ['type-bug', '3.7', 'release-blocker']
    title = "3.6.1rc1 adds the current directory to sys.path when running a subdirectory's __main__.py; previous versions did not"
    updated_at = <Date 2018-01-16.07:08:50.064>
    user = 'https://github.com/nedbat'

    bugs.python.org fields:

    activity = <Date 2018-01-16.07:08:50.064>
    actor = 'serhiy.storchaka'
    assignee = 'ncoghlan'
    closed = True
    closed_date = <Date 2017-03-12.11:38:57.611>
    closer = 'ncoghlan'
    components = []
    creation = <Date 2017-03-05.13:31:48.921>
    creator = 'nedbat'
    dependencies = []
    files = []
    hgrepos = []
    issue_num = 29723
    keywords = []
    message_count = 26.0
    messages = ['289009', '289011', '289044', '289046', '289049', '289053', '289117', '289122', '289201', '289208', '289214', '289215', '289237', '289254', '289269', '289271', '289275', '289276', '289384', '289493', '289495', '289500', '290119', '290202', '290204', '290207']
    nosy_count = 6.0
    nosy_names = ['ncoghlan', 'nedbat', 'ned.deily', 'eric.snow', 'eryksun', 'steve.dower']
    pr_nums = ['571', '575', '636', '638']
    priority = 'release blocker'
    resolution = 'fixed'
    stage = 'resolved'
    status = 'closed'
    superseder = None
    type = 'behavior'
    url = 'https://bugs.python.org/issue29723'
    versions = ['Python 3.6', 'Python 3.7']

    Metadata

    Metadata

    Assignees

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions