• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

mozilla-releng / balrog / #5214

16 Feb 2026 01:14AM UTC coverage: 16.352% (-73.5%) from 89.9%
#5214

Pull #3672

circleci

renovate-bot
chore(deps): lock file maintenance (pep621)
Pull Request #3672: chore(deps): lock file maintenance (pep621)

267 of 2546 branches covered (10.49%)

Branch coverage included in aggregate %.

1169 of 6236 relevant lines covered (18.75%)

0.19 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

16.67
/src/auslib/web/admin/views/problem.py
1
import json
1✔
2

3
from flask import Response
1✔
4

5

6
def problem(status, title, detail, type=None, instance=None, headers=None, ext=None):
1✔
7
    """
8
    Returns a `Problem Details <https://tools.ietf.org/html/draft-ietf-appsawg-http-problem-00>`_ error response.
9

10
    Method is an exact copy of connexion.problem method except the returned Response
11
    object is of type flask.Response) instead of ConnexionResponse.
12

13
    Reason: using connexion.problem results in TypeError: 'ConnexionResponse' object is not callable,
14
    sporadically in some APIs. Hence using flask.Response.
15

16
    :param status: The HTTP status code generated by the origin server for this occurrence of the problem.
17
    :type status: int
18
    :param title: A short, human-readable summary of the problem type.  It SHOULD NOT change from occurrence to
19
                  occurrence of the problem, except for purposes of localisation.
20
    :type title: str
21
    :param detail: An human readable explanation specific to this occurrence of the problem.
22
    :type detail: str
23
    :param type: An absolute URI that identifies the problem type.  When dereferenced, it SHOULD provide human-readable
24
                 documentation for the problem type (e.g., using HTML).  When this member is not present its value is
25
                 assumed to be "about:blank".
26
    :type: type: str
27
    :param instance: An absolute URI that identifies the specific occurrence of the problem.  It may or may not yield
28
                     further information if dereferenced.
29
    :type instance: str
30
    :param headers: HTTP headers to include in the response
31
    :type headers: dict | None
32
    :param ext: Extension members to include in the body
33
    :type ext: dict | None
34
    :return: error response
35
    :rtype: Response
36
    """
37
    if not type:
×
38
        type = "about:blank"
×
39

40
    problem_response = {"type": type, "title": title, "detail": detail, "status": status}
×
41
    if instance:
×
42
        problem_response["instance"] = instance
×
43
    if ext:
×
44
        problem_response.update(ext)
×
45

46
    mimetype = content_type = "application/json"
×
47
    return Response(response=json.dumps(problem_response), status=status, mimetype=mimetype, content_type=content_type, headers=headers)
×
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc