Non-Image file attachments fail to upload in Resources Workspace
search cancel

Non-Image file attachments fail to upload in Resources Workspace

book

Article ID: 405479

calendar_today

Updated On:

Products

Clarity PPM On Premise Clarity PPM SaaS Clarity FedRAMP

Issue/Introduction

Users are currently unable to upload non-image file types as attachments within the Clarity New User Experience (UX) Resources Workspace. The system improperly restricts allowed file extensions for attachments to image-only formats (PNG, JPEG, JPG, JPE, and GIF), leading to upload failures for any other file type.

Steps to Reproduce:

  1. Prerequisite: Setup an attachment field on resource object and enable it for API access
  2. Login to clarity new UX > navigate to Resources workspace > Resource tab or any other tab like Role or Teams
  3. Add the attachment field to the grid and attempt to upload a non-image file such text, PDF, etc.

Expected Results: The non-image file attachment should be uploaded successfully

Actual Results: The upload fails, and the user receives an error message similar to: "Could not upload file [file name]". The system prevents the upload due to the unsupported file extension. Below errors are seen in browser trace and app ca logs 

errorCode:'api.messageInvalidFileExtension'
errorMessage: 'The action could not be completed because of the list of files that are not allowed: FILE_NAME.txt. The accepted file extensions are: png,jpeg,jpg,jpe,gif.'Status '400'
ppm.rest Invalid File Extension: Allowed attach Extensions are: png,jpeg,jpg,jpe,gif : Input file is: FILE_NAME.txt
com.ca.ppm.rest.exception.BadRequestException: The action could not be completed because of the list of files that are not allowed: FILE_NAME.txt. The accepted file extensions are: png,jpeg,jpg,jpe,gif.
at com.ca.platform.osf.object.rest.validator.PersonalizationImageValidator.validatePostRequest(PersonalizationImageValidator.java:84)
at com.ca.platform.osf.object.rest.validator.ODFAttachmentValidator.validatePostRequest(ODFAttachmentValidator.java:105)

Environment

Clarity 16.3.2, 16.3.3

Cause

DE173799

Resolution

This issue is fixed in:

  • Clarity 16.3.3.2 (16.3.3 Patch 2)
  • Clarity 16.4.0