databend icon indicating copy to clipboard operation
databend copied to clipboard

Test `CsvFileFormatParams` instead of `FileFormatParam`

Open drmingdrmer opened this issue 2 years ago • 3 comments


src/meta/proto-conv/tests/it/v075_csv_format_params.rs line 56 at r1 (raw file):

        })
    };
    common::test_load_old(func_name!(), file_format_params_v75.as_slice(), 0, want())?;

FileFormatParams is an enum that does not have version information init(ver and min_reader_ver). Instead of testing decoding FileFormatParam, CsvFileFormatParams is the one should be tested. It contains version information and can be used independently.

Contrastly, FileFormatParam can only be used as part of another protobuf message and should never used alone for the lack of version information and compatibility can not be checked.

Originally posted by @drmingdrmer in https://github.com/datafuselabs/databend/pull/14329#pullrequestreview-1822449681

drmingdrmer avatar Jan 16 '24 02:01 drmingdrmer

This is not fixed IMO.

drmingdrmer avatar Jan 18 '24 06:01 drmingdrmer

Does this PR https://github.com/datafuselabs/databend/pull/14335 needs revert?

bohutang avatar Jan 18 '24 06:01 bohutang

Does this PR #14335 needs revert?

No, #14335 fixed a few other issues, but not this one.

drmingdrmer avatar Jan 18 '24 06:01 drmingdrmer