Closed cgiacofei closed 1 month ago
Adding the column to the CustomReports schema in database.py seems to be all that's needed to fix the error.
class CustomReports(BaseModel, table=True):
__tablename__ = "custom_reports"
...
include_current: Optional[int] = Field(default=None, sa_column=Column("include_current", Integer))
Hello @cgiacofei , thanks for your report, I think I missed this columns because my local docker version was still running an older version of Actual. I added a patch at https://github.com/bvanelli/actualpy/pull/42
I added a test to prevent the model from not being updated in the future, and it complains on the latest version that the column was missing:
I merged https://github.com/bvanelli/actualpy/pull/42 and you can now install from git.
I would like to do some further testing before generating a new version, feel free to reopen the issue if you still have issues after installing the newest version.
Checks
Reproducible example
Log output
Issue description
Attempting to perform budget backup using the example given in repo as a test. An object of class Actual is not able to be created due to the repo schema not including the new
include_current
field in custom reports.Expected behavior
The budget should load.
Installed versions