Skip to content

[Python] Switch default and deprecate use_legacy_dataset=True in ParquetDataset #32067

Closed

Description

@asfimport

The ParquetDataset() constructor itself still defaults to use_legacy_dataset=True (although using specific attributes or keywords related to that will raise a warning). So a next step will be to actually deprecate passing that and switching the default, and then only afterwards we can remove the code.

Reporter: Joris Van den Bossche / @jorisvandenbossche
Assignee: Joris Van den Bossche / @jorisvandenbossche

PRs and other links:

Note: This issue was originally created as ARROW-16728. Please see the migration documentation for further details.

Activity

  1. asfimport commented on Aug 31, 2022

    @asfimport
    Author

    Raúl Cumplido / @raulcd:
    @jorisvandenbossche was your idea for this one to be done on two different releases?
    First - DeprecationWarning and switch default to use_legacy_dataset=False

    Second - Remove possibility of using use_legacy_dataset=True

  2. asfimport commented on Sep 6, 2022

    @asfimport
    Author

    Joris Van den Bossche / @jorisvandenbossche:
    Yes, indeed (but so the two first items together in one release (switching default + deprecating the option, and then only in a later release actually remove the option).

    We should certainly do that first step in 10.0

  3. asfimport commented on Dec 23, 2022

    @asfimport
    Author

    Joris Van den Bossche / @jorisvandenbossche:
    Issue resolved by pull request 14052
    #14052

  4. added this to the 11.0.0 milestone on Jan 11, 2023
  5. 0x26res commented on Feb 3, 2023

    @0x26res
    Contributor

    Now that this change is effective in 11.0, we get this warning when loading data with use_legacy_dataset=True.

    FutureWarning: Passing 'use_legacy_dataset=True' to get the legacy behaviour is deprecated as of pyarrow 11.0.0, and the legacy implementation will be removed in a future version.
    

    I'm in the process of migrating to use_legacy_dataset=False, but was wondering what differences to expect between the 2 implementations. Is this documented somewhere?

    I have noticed one significant difference in behaviour. The legacy implementation would complain if the parquet schema are heterogeneous. The new implementation will try to convert all files to the schema of the first file it found (or the schema argument when provided).

    Are there other differences to expect?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Type

No type

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions