[Python] CSV test failures started after adding rows, likely due to an encoding issue [closed]

Discussão em 'Python' iniciado por Stack, Novembro 26, 2025.

  1. Stack

    Stack Membro Participativo

    I am working on a test where I provide a CSV file with some rows, run the code using that CSV, generate another CSV, and then compare the results. In one of the input files, I was using the £ sign, while in the comparison file I was using �. It was working fine before, but after adding more rows, it started failing, and now it’s reporting ´┐¢.

    The issue may be related to the default encoding used by the code editor, but I’m not sure what the exact problem is.

    write_to_s3 = (result_dataframe, s3):
    data_buffer = BytesIO()
    data_result.toPandas().to_csv(
    data_buffer,
    encoding='cp850',
    )

    Continue reading...

Compartilhe esta Página