[Bug 2000013] Re: FTBFS: test failure

Lukas Märdian 2000013 at bugs.launchpad.net
Thu Jan 5 20:30:49 UTC 2023


Fixed via https://launchpad.net/ubuntu/+source/flask/2.2.2-2ubuntu1

** Changed in: flask-restful (Ubuntu)
       Status: New => Fix Released

-- 
You received this bug notification because you are a member of Ubuntu
OpenStack, which is subscribed to flask-restful in Ubuntu.
https://bugs.launchpad.net/bugs/2000013

Title:
  FTBFS: test failure

Status in flask-restful package in Ubuntu:
  Fix Released

Bug description:
  flask-restful 0.3.9-6 currently fails to build in Ubuntu Lunar due to test failures. The error message is the following:
  _________________ APITestCase.test_exception_header_forwarded __________________

  self = <tests.test_api.APITestCase
  testMethod=test_exception_header_forwarded>

      def test_exception_header_forwarded(self):
          """Test that HTTPException's headers are extended properly"""
          app = Flask(__name__)
          app.config['DEBUG'] = True
          api = flask_restful.Api(app)

          class NotModified(HTTPException):
              code = 304

              def __init__(self, etag, *args, **kwargs):
                  super(NotModified, self).__init__(*args, **kwargs)
                  self.etag = quote_etag(etag)

              def get_headers(self, *args, **kwargs):
                  """Get a list of headers."""
                  return [('ETag', self.etag)]

          class Foo1(flask_restful.Resource):
              def get(self):
                  flask_abort(304, etag='myETag')

          api.add_resource(Foo1, '/foo')
  >       app.aborter.mapping[304] = NotModified
  E       AttributeError: 'Flask' object has no attribute 'aborter'

  (https://launchpadlibrarian.net/639826021/buildlog_ubuntu-lunar-
  amd64.flask-restful_0.3.9-6_BUILDING.txt.gz for more details)

  Noticing that this issue did not happen when the package was updated
  in Debian, nor could I reproduce it on my Debian Sid system, I tried
  to find the delta between there and Ubuntu.

  The latest version of flask in Debian is 2.2.2-2, while Ubuntu Lunar
  has 2.0.3-1ubuntu1. Based on the error message it might be something
  has changed in the flask api in the mean time. When I manually
  installed the flask binary from Debian, the package built successfully
  so I believe this issue will be resolved once a newer version of flask
  is available in Ubuntu. (See also bug 2000014)

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/flask-restful/+bug/2000013/+subscriptions




More information about the Ubuntu-openstack-bugs mailing list