Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support reading (text) files line by line #21

Closed
manoss96 opened this issue Mar 29, 2023 · 0 comments · Fixed by #23
Closed

Support reading (text) files line by line #21

manoss96 opened this issue Mar 29, 2023 · 0 comments · Fixed by #23
Assignees
Labels
enhancement New feature or request

Comments

@manoss96
Copy link
Owner

manoss96 commented Mar 29, 2023

Besides being able to read a file as raw bytes, provide a number of methods for reading a file as text. More specifically:

  • Add method read_text(encocing: str='utf-8') -> str so as to be able to read whole file as a single piece of text.
  • Add method read_lines(encoding: str='utf-8') -> Iterator[str] so as to be able to iterate over the file line-by-line.
@manoss96 manoss96 added the enhancement New feature or request label Mar 29, 2023
@manoss96 manoss96 self-assigned this Mar 29, 2023
@manoss96 manoss96 changed the title Support reading files as text Support reading (text) files line by line Apr 2, 2023
@manoss96 manoss96 linked a pull request Apr 2, 2023 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant