Skip to content

Added support for read_list()

Choose a tag to compare

@rsdoiel rsdoiel released this 06 May 21:03
· 64 commits to master since this release

In libdataset v0.0.59 a function was added to read a list of records from a dataset collection and return an array of records. If an error is encountered on retrieving the key list then an error message is returned as the second part of the tuple along with any successfully retrieved records. If all records are retrieved successfully then the second part of the tuple will be an empty string.

    from py_dataset import dataset
    records, err = dataset.read_list("test.ds", ["one", "two", "three"])
    if err != "":
         print(f"Found the following errors {err}")
    print(records)