-
Notifications
You must be signed in to change notification settings - Fork 15
Open
Labels
Description
Version
pulpcore: 3.87.0
pulp_maven: 0.11.0
pulp-cli-maven 0.4.0
Running in Kubernetes through helm deployment
Describe the bug
Running: pulp maven repository content list --repository maven-releases triggers a internal server error 500
(pulp) √ ~ > pulp maven repository content list --repository maven-releases 14:17:29
Error:
<!doctype html>
<html lang="en">
<head>
<title>Server Error (500)</title>
</head>
<body>
<h1>Server Error (500)</h1><p></p>
</body>
</html>
(pulp) 1 ~ >
('pulp [52b9469ab4de4cc19ddaeeffa34b6d98]: ::ffff:10.42.0.122 - admin [03/Sep/2025:11:59:50 +0000] "GET /pulp/api/v3/repositories/maven/maven/?name=maven-releases&offset=0&limit=1 HTTP/1.0" 200 625 "-" "Pulp-CLI/0.35.0"',)
pulp [52b9469ab4de4cc19ddaeeffa34b6d98]: django.request:ERROR: Internal Server Error: /pulp/api/v3/repositories/maven/maven/01990f68-d33d-7fd5-b289-aa63c9b7942e/versions/9/
Traceback (most recent call last):
File "/usr/local/lib/python3.11/site-packages/django/core/handlers/exception.py", line 55, in inner
response = get_response(request)
^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/django/core/handlers/base.py", line 197, in _get_response
response = wrapped_callback(request, *callback_args, **callback_kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/django/views/decorators/csrf.py", line 56, in wrapper_view
return view_func(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/rest_framework/viewsets.py", line 125, in view
return self.dispatch(request, *args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/rest_framework/views.py", line 515, in dispatch
response = self.handle_exception(exc)
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/rest_framework/views.py", line 475, in handle_exception
self.raise_uncaught_exception(exc)
File "/usr/local/lib/python3.11/site-packages/rest_framework/views.py", line 486, in raise_uncaught_exception
raise exc
File "/usr/local/lib/python3.11/site-packages/rest_framework/views.py", line 512, in dispatch
response = handler(request, *args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/rest_framework/mixins.py", line 56, in retrieve
return Response(serializer.data)
^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/rest_framework/serializers.py", line 573, in data
ret = super().data
^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/rest_framework/serializers.py", line 251, in data
self._data = self.to_representation(self.instance)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/rest_framework/serializers.py", line 540, in to_representation
ret[field.field_name] = field.to_representation(attribute)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/pulpcore/app/serializers/repository.py", line 449, in to_representation
"href": count_detail.get_content_href(request=request),
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/pulpcore/app/models/repository.py", line 1407, in get_content_href
ctype_view = get_view_name_for_model(ctype_model, "list")
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/pulpcore/app/util.py", line 302, in get_view_name_for_model
viewset = get_viewset_for_model(model_obj)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/site-packages/pulpcore/app/util.py", line 276, in get_viewset_for_model
raise LookupError("Could not determine ViewSet base name for model {}".format(model_class))
LookupError: Could not determine ViewSet base name for model <class 'pulp_maven.app.models.MavenMetadata'>
To Reproduce
Steps to reproduce the behavior:
pulp maven repository create --name maven-releases
pulp maven distribution create --name maven-releases --repository maven-releases --base-path maven-releases
mvn deploy:deploy-file -DgroupId=com.acme -DartifactId=imageio-ext-test-data -Dversion=1.4.15 -Dpackaging=jar -Dfile=imageio-ext-test-data-1.4.15.jar -DrepositoryId=pulp-releases -Durl=https://$URL/pulp/maven/maven-releases
pulp maven repository content list --repository maven-releases
Expected behavior
Guess a listing of packages?
Additional context
https://$URL/pulp/api/v3/content/maven/artifact/ shows a list of packages in the browser