On Tue, 24 May 2022 at 23:03, <mguin...@gmail.com> wrote: > > seek() and tell() works with opaque values, called cookies. > This is close to low level details, but it is not pythonic. > (Non-pythonic and non-portable behaviour) > Currently feeding seek() with wrong values could lead to unexpected behaviour. > There should be a safer abstraction to these two basic functions. > > More details in the issue: > https://github.com/python/cpython/issues/93101#issue-1244996658
Definitely not. Being able to rewind a text file to a known location is incredibly useful, and hiding these methods would be a net negative for the language. You haven't answered the questions on that issue, so I won't touch the part where you want magic to happen until you've explained that part. ChrisA _______________________________________________ Python-ideas mailing list -- python-ideas@python.org To unsubscribe send an email to python-ideas-le...@python.org https://mail.python.org/mailman3/lists/python-ideas.python.org/ Message archived at https://mail.python.org/archives/list/python-ideas@python.org/message/ACUNYYUUCD2J7QJ7RJLFVM7BNIJ75Z5D/ Code of Conduct: http://python.org/psf/codeofconduct/