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

bug(datasets): fix polars.CSVDataset Windows tests #959

Open
deepyaman opened this issue Dec 6, 2024 · 0 comments
Open

bug(datasets): fix polars.CSVDataset Windows tests #959

deepyaman opened this issue Dec 6, 2024 · 0 comments

Comments

@deepyaman
Copy link
Member

Description

#957 made CI run with Polars 1.x, but CSVDatasets doesn't seem to be working on Windows—the doctest and unit tests that call save are all failing.

Since #957 didn't really change this functionality (which is why I xfailed the tests to unblock), it's worth making sure this stuff actually works on Windows.

Steps to Reproduce

Try to follow the test or doctest logic on Windows.

Expected Result

Tell us what should happen.

Actual Result

From the CI:

    @wraps(save_func)
    def save(self: Self, data: _DI) -> None:
        if data is None:
            raise DatasetError("Saving 'None' to a 'Dataset' is not allowed")
    
        try:
            self._logger.debug("Saving %s", str(self))
            save_func(self, data)
        except (DatasetError, FileNotFoundError, NotADirectoryError):
            raise
        except Exception as exc:
            message = f"Failed while saving data to dataset {self!s}.\n{exc!s}"
>           raise DatasetError(message) from exc
E           kedro.io.core.DatasetError: Failed while saving data to dataset CSVDataset(filepath=C:/Users/runneradmin/AppData/Local/Temp/pytest-of-runneradmin/pytest-1/popen-gw1/test_versioning_existing_datas11/test.csv, load_args={'rechunk': True}, protocol=file, save_args={}).
E           file encoding is not UTF-8

(Doctest fails with the reloaded variable just not getting assigned, which may very well be related.)

Your Environment

Windows CI; see https://github.com/kedro-org/kedro-plugins/actions/runs/12187331556/job/34016095791

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

No branches or pull requests

2 participants