Skip to content

Conversation

jiisanda
Copy link

@jiisanda jiisanda commented Jun 11, 2025

Issue and Discussion: #1000

Update

  • Adding a DelimiterType StrEnum in utils.py.
  • Adding a text_to_column method in Worksheet class... something like this...
    @cast_to_a1_notation
    def text_to_column(
        self,
        source_range: str,
        delimiter_type: DelimiterType = DelimiterType.comma,
        custom_delimiter: Optional[str] = None,
    ) -> JSONResponse:

Usage for csv will be like...

worksheet.text_to_column("A1:A4", DelimiterType.comma)

@alifeee @lavigne958 its ready for review... let me know if you have any feedback...

@jiisanda jiisanda marked this pull request as draft June 11, 2025 21:32
@jiisanda jiisanda marked this pull request as ready for review June 22, 2025 15:16
@alifeee
Copy link
Collaborator

alifeee commented Jun 26, 2025

thanks for this change ! it looks very well crafted ;]

as for these tests which fail, I believe all tests in worksheet_test.py initialise a spreadsheet object (here), so unless this fixture is turned off for the tests, they will need API access, and therefore a VCR cassette

https://github.com/jiisanda/gspread/blob/4292e133a108d1d93c5471ab006b796e943da3f0/tests/worksheet_test.py#L2110-L2113

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants