Skip to content

SimpleHTTPRequestHandler has hard coded index page list. #91219

Description

@myronww
mannequin
BPO 47063
Nosy @ethanfurman, @@myronww
PRs
  • bpo-47063 Add an index_pages default list and parameter to SimpleHTTPRequestHandler #31985
  • 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 2022-03-19.04:25:13.984>
    labels = ['type-feature', 'library', '3.11']
    title = 'SimpleHTTPRequestHandler has hard coded index page list.'
    updated_at = <Date 2022-03-21.14:36:32.938>
    user = 'https://github.com/myronww'

    bugs.python.org fields:

    activity = <Date 2022-03-21.14:36:32.938>
    actor = 'ethan.furman'
    assignee = 'none'
    closed = False
    closed_date = None
    closer = None
    components = ['Library (Lib)']
    creation = <Date 2022-03-19.04:25:13.984>
    creator = 'myronww'
    dependencies = []
    files = []
    hgrepos = []
    issue_num = 47063
    keywords = ['patch']
    message_count = 3.0
    messages = ['415534', '415535', '415683']
    nosy_count = 3.0
    nosy_names = ['ethan.furman', 'python-dev', 'myronww']
    pr_nums = ['31985']
    priority = 'normal'
    resolution = None
    stage = 'patch review'
    status = 'open'
    superseder = None
    type = 'enhancement'
    url = 'https://bugs.python.org/issue47063'
    versions = ['Python 3.11']

    Linked PRs

    Activity

    1. myronww commented on Mar 19, 2022

      myronwwmannequin
      MannequinAuthor

      SimpleHTTPRequestHandler has hard coded index page list in the send_head method. The fixed hard-coded list means that if you want to have a custom index page that is not named "index.htm" or "index.html" then you have to override the send_head method. There is alot of code in send_head so overriding it is not optimal just to have a custom indexer filename.

    2. added
      stdlibStandard Library Python modules in the Lib/ directory
      type-featureA feature request or enhancement
      on Mar 19, 2022
    3. myronww commented on Mar 19, 2022

      myronwwmannequin
      MannequinAuthor

      I am adding a Github PR for this issue.

    4. ethanfurman commented on Mar 21, 2022

      @ethanfurman
      Member

      index.htm[l] is pretty standard for the name of the index page. What's your use-case for wanting different names? Keep in mind that the word Simple is in the name for a reason.

    5. added
      3.11only security fixes
      and removed on Mar 21, 2022
    6. transferred this issue fromon Apr 10, 2022
    7. added a commit that references this issue on Jun 23, 2022
    8. ethanfurman commented on Jun 23, 2022

      @ethanfurman
      Member

      Committed into 3.12 code base.

    9. added
      3.12only security fixes
      and removed
      3.11only security fixes
      on Jun 23, 2022
    10. added a commit that references this issue on Jan 3, 2023
    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

      3.12only security fixesstdlibStandard Library Python modules in the Lib/ directorytype-featureA feature request or enhancement

      Projects

      No projects

        Milestone

        No milestone

        Relationships

        None yet

        Development

        No branches or pull requests

        Issue actions