Error using to_documents method on a dataset

Summary

The user is encountering an error Document is not fully defined when using the to_documents method on a dataset in pyAirbyte. They are seeking guidance on how to resolve this issue.


Question

Hello Everyone, I am having some issues with using the to_documents method on a dataset. here is my code

    "source-github",
    config={
        "repositories": ["airbytehq/pyAirbyte"],
        "credentials": {
            "personal_access_token": ab.get_secret("ACCESS_KEY")

        }
    },
    streams=["issues"],
)

source.check()
#source.select_all_streams()
read_result=source.read()



first_record = next((record for record in read_result["issues"]))

print(first_record)
# Print the fields list, followed by the first full record.
#print(list(first_record.keys()))

docs = list(read_result["issues"].to_documents(
    title_property="title",
    content_properties=["body"],
    metadata_properties=["state", "url", "number"],
    render_metadata=True
))```
and here is the error message
```    raise PydanticUserError(self._error_message, code=self._code)
pydantic.errors.PydanticUserError: `Document` is not fully defined; you should define `datetime`, then call `Document.model_rebuild()`.```
Can someone please point me in the right direction if am missing anything.
Thanks

<br>

---

This topic has been created from a Slack thread to give it more visibility.
It will be on Read-Only mode here. [Click here](https://airbytehq.slack.com/archives/C021JANJ6TY/p1729188807173199) if you want 
to access the original thread.

[Join the conversation on Slack](https://slack.airbyte.com)

<sub>
["to-documents-method", "pyairbyte", "error", "document", "model-rebuild"]
</sub>