flagpole icon indicating copy to clipboard operation
flagpole copied to clipboard

Random image suite failures

Open johnsickels opened this issue 4 years ago • 3 comments
trafficstars

We see the sporadic failure:

Screen Shot 2021-09-20 at 12 30 33 PM

But a rerun, or a manual check to the image is fine.

My suspicion is somewhere around how much of the image loads:

An image scenario will load only the first 512 bytes of the image, which includes the meta data that we need to assert things like height and width.

johnsickels avatar Sep 20 '21 16:09 johnsickels

The first 512 bytes of the image is where the metadata lives. So that's why we only need to load 512. Would have to investigate what is being returned, although it looks like it's not getting anything

jasonbyrne avatar Oct 06 '21 00:10 jasonbyrne

We started to log the response if the mime type is not what we expect and are getting this:

  _httpResponse: HttpResponse {
    body: '',
    json: {
      width: 0,
      height: 0,
      type: '',
      mimeType: '',
      length: 60633,
      url: 'https://dx5a7fcdm93g5.cloudfront.net/streams/12276/images/tiles_320x180_1634576402431_1634580002431_0011.jpg',
      mime: ''
    },
    statusCode: 200,
    statusMessage: '',
    headers: {
      'content-type': 'image/jpeg',
      'content-length': '60633',
      connection: 'close',
      date: 'Mon, 18 Oct 2021 19:15:11 GMT',
      'last-modified': 'Mon, 18 Oct 2021 19:05:04 GMT',
      'x-amz-expiration': 'expiry-date="Thu, 18 Nov 2021 00:00:00 GMT", rule-id="Expire30"',
      etag: '"121d2b37a032af45748bb40c103da5a5"',
      'x-amz-version-id': 't_721UtRrxPJLI7iP34_UNIyuRYrixPL',
      'accept-ranges': 'bytes',
      server: 'AmazonS3',
      'x-cache': 'Hit from cloudfront',
      via: '1.1 0bca35acf826729de8b75fb344bf9f45.cloudfront.net (CloudFront)',
      'x-amz-cf-pop': 'MIA3-C3',
      'x-amz-cf-id': 'c9PTajhg0Ve78E1wUCXnK9dN-zdS6CJQrt9KfAazrI3Q1EHe551mFw=='
    },
    cookies: {},
    trailers: {},
    url: 'https://dx5a7fcdm93g5.cloudfront.net/streams/12276/images/tiles_320x180_1634576402431_1634580002431_0011.jpg',
    method: ''
  },

johnsickels avatar Oct 18 '21 19:10 johnsickels

The library we use does not support .jpg. I'm struggling to find an example gallery that does not use .jpg

johnsickels avatar Oct 19 '21 14:10 johnsickels