Skip to content

LimitOffsetPagination raises Type error if PAGE_SIZE not set #2667

Closed
@balsdorf

Description

@balsdorf

In 3.1.0 if you do not have PAGE_SIZE set you get a TypeError: unsupported operand type(s) for +: 'int' and 'NoneType'.

I believe a friendlier message would be useful in this case. I was going to submit a patch but was not sure exactly how you would like to handle this.

Exception Type: TypeError
Exception Value:
unsupported operand type(s) for +: 'int' and 'NoneType'
Exception Location: /work/virtual/skysql_upgrade/local/lib/python2.7/site-packages/rest_framework/pagination.py in paginate_queryset, line 396

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions