Skip to content

Openverse is a search engine for openly-licensed media. This monorepo includes all application code.

Fix issue due to `page_query_param` not being a string (#723)

Dhruv Bhanushalia76a6de6a2ef
diff --git a/.github/workflows/ci_cd.yml b/.github/workflows/ci_cd.yml
index 5676ab79e..46d7d5f24 100644
--- a/.github/workflows/ci_cd.yml
+++ b/.github/workflows/ci_cd.yml
@@ -142,6 +142,10 @@ jobs:
- name: Start API, ingest and index test data
run: just init
+ - name: Smoke test ReDoc site
+ run: |
+ curl --fail 'http://localhost:8000/v1/?format=openapi'
+
- name: Run API tests
run: just api-test
diff --git a/api/catalog/custom_auto_schema.py b/api/catalog/custom_auto_schema.py
index 6e3b13b03..6cdbc94f4 100644
--- a/api/catalog/custom_auto_schema.py
+++ b/api/catalog/custom_auto_schema.py
@@ -4,6 +4,14 @@ from drf_yasg.utils import filter_none, force_real_str
class CustomAutoSchema(SwaggerAutoSchema):
+ def get_pagination_parameters(self):
+ """
+ Since the pagination params are a part of the ``MediaSearchRequestSerializer``,
+ they need not be added again as pagination params.
+ """
+
+ return []
+
def get_operation(self, operation_keys=None):
operation_keys = operation_keys or self.operation_keys