marshmallow-code / marshmallow-code/flask-marshmallow
TypeError: Schema.__init__() got an unexpected keyword argument 'include_data'
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 887
- Forks
- 65
- Avg merge
- 7h 25m
- Merged PRs (30d)
- 3
Description
Can't create any schemas at all.
```python
class Price(db.Model):
id = db.Column(db.Integer, primary_key=True)
name = db.Column(db.String(128), index=True)
class PriceSchema(ma.SQLAlchemyAutoSchema):
class Meta:
model = Price
```
This raises the following error:
```
TypeError: Schema.__init__() got an unexpected keyword argument 'include_data'
```
Have also tried with `ma.SQLAlchemySchema`.
Installed:
flask version : 2.0.1
flask_marshmallow version : 0.14.0
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing the error with the provided Price model and PriceSchema examples using SQLAlchemyAutoSchema and SQLAlchemy. Check the installed Flask-Marshmallow and Marshmallow integration entry points for how schema initialization handles include_data. Done means both schema classes can be instantiated without the unexpected-keyword TypeError.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- flask, python, sqlalchemy
- Domain
- api, backend, databases
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 38/100