GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — Inconsistent documentation of tell/seek on textiobase/textiowrapper · Issue #82969 · python/cpython

Inconsistent documentation of tell/seek on textiobase/textiowrapper #82969

New issue
Copy link
New issue
Copy link
Closed as not planned
Closed as not planned
Inconsistent documentation of tell/seek on textiobase/textiowrapper#82969
Copy link
Labels
3.8 (EOL)end of lifeend of lifestdlibStandard Library Python modules in the Lib/ directoryStandard Library Python modules in the Lib/ directorytopic-IO

Description

qha
mannequin
opened on Nov 13, 2019
Issue body actions
BPO 38788
Nosy @terryjreedy, @qha

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 2019-11-13.14:36:28.180>
labels = ['3.8', 'library']
title = 'Inconsistent documentation of tell/seek on textiobase/textiowrapper'
updated_at = <Date 2019-11-15.20:28:43.659>
user = 'https://github.com/qha'

bugs.python.org fields:

activity = <Date 2019-11-15.20:28:43.659>
actor = 'terry.reedy'
assignee = 'none'
closed = False
closed_date = None
closer = None
components = ['Library (Lib)']
creation = <Date 2019-11-13.14:36:28.180>
creator = 'qha'
dependencies = []
files = []
hgrepos = []
issue_num = 38788
keywords = []
message_count = 1.0
messages = ['356534']
nosy_count = 2.0
nosy_names = ['terry.reedy', 'qha']
pr_nums = []
priority = 'normal'
resolution = None
stage = None
status = 'open'
superseder = None
type = None
url = 'https://bugs.python.org/issue38788'
versions = ['Python 3.8']

Activity

  1. qha commented on Nov 13, 2019

    @qha
    qhamannequin
    on Nov 13, 2019
    MannequinAuthor
    More actions

    The class hierarchy suggests the only tell/seek implementations one
    needs to look up are in iobase and those have the semantics i was
    expecting:
    https://docs.python.org/3.8/library/io.html#class-hierarchy

    Plowing on one might discover that there are separate implementations
    of tell/seek for textiobase whose documentation probably explains the
    unexpected values tell returns.

    The documentation for tell available from the help() command still
    reflects the semantics i was expecting.

    The documentation for seek available from the help() command still
    reflects the semantics i was expecting. It does however suggest that
    the first argument has been renamed from offset to cookie which the
    online documentation has not yet caught up to at:
    https://docs.python.org/3.8/library/io.html#io.TextIOBase.seek

    The documentation body for seek from the help() command still refers to
    offset though there is now no argument of that name.

    >>> help(fh.tell)
    Help on built-in function tell:

    tell() method of _io.TextIOWrapper instance
    Return current stream position.

    >>> help(fh.seek)
    Help on built-in function seek:

    seek(cookie, whence=0, /) method of _io.TextIOWrapper instance
    Change stream position.

    Change the stream position to the given byte offset. The offset is
    interpreted relative to the position indicated by whence.  Values
    for whence are:
    
    * 0 -- start of stream (the default); offset should be zero or positive
    * 1 -- current stream position; offset may be negative
    * 2 -- end of stream; offset is usually negative
    
    Return the new absolute position.
    
  2. qha
    added
    3.8 (EOL)end of lifeend of life
    stdlibStandard Library Python modules in the Lib/ directoryStandard Library Python modules in the Lib/ directory
    on Nov 13, 2019
  3. ezio-melotti
    transferred this issue fromon Apr 10, 2022
  4. serhiy-storchaka commented on Aug 14, 2023

    @serhiy-storchaka
    serhiy-storchaka
    on Aug 14, 2023
    Member
    More actions

    Closed as a duplicate of newer issue #107801 which has more activity.

    Reacted by Erlend E. Aasland
  5. serhiy-storchaka
    added
    topic-IO
    on Feb 7, 2024
  6. erlend-aasland commented on Oct 11, 2024

    @erlend-aasland
    erlend-aasland
    on Oct 11, 2024
    Contributor
    More actions

    Closed as a duplicate of newer issue #107801 which has more activity.

    +1

  7. erlend-aasland
    closed this as not plannedon Oct 11, 2024
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.8 (EOL)end of lifeend of lifestdlibStandard Library Python modules in the Lib/ directoryStandard Library Python modules in the Lib/ directorytopic-IO

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

      You are visitor 01402503 — GeezerVison does not store the pages you look up.
      Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.