Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Pipeline Upload filesize limit #2874

Merged

Conversation

andrewballantyne
Copy link
Member

@andrewballantyne andrewballantyne commented Jun 3, 2024

https://issues.redhat.com/browse/RHOAIENG-4189

Description

If bytes exceed 1 megabyte, prevent it client side -- the default on the fastify server is 1 mb -- we may want to find a better way to configure this in the long run.

Screenshot 2024-06-03 at 4 10 55 PM
Screenshot 2024-06-03 at 4 11 02 PM

How Has This Been Tested?

Using Pipelines, upload a Pipeline & select a file larger than 1 megabyte (with a .yaml extenstion)

Test Impact

Tests added to verify the error shows when a too large of a file is uploaded.

Request review criteria:

Self checklist (all need to be checked):

  • The developer has manually tested the changes and verified that the changes work
  • Commits have been squashed into descriptive, self-contained units of work (e.g. 'WIP' and 'Implements feedback' style messages have been removed)
  • Testing instructions have been added in the PR body (for PRs involving changes that are not immediately obvious).
  • The developer has added tests or explained why testing cannot be added (unit or cypress tests for related changes)

If you have UI changes:

  • Included any necessary screenshots or gifs if it was a UI change.
  • Included tags to the UX team if it was a UI/UX change (find relevant UX in the SMEs section).

After the PR is posted & before it merges:

  • The developer has tested their solution on a cluster by using the image produced by the PR to main

cc @yannnz

Copy link

codecov bot commented Jun 3, 2024

Codecov Report

Attention: Patch coverage is 96.00000% with 1 line in your changes missing coverage. Please review.

Project coverage is 78.19%. Comparing base (20d32e9) to head (95b3410).
Report is 4 commits behind head on main.

Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main    #2874      +/-   ##
==========================================
+ Coverage   78.14%   78.19%   +0.04%     
==========================================
  Files        1101     1101              
  Lines       23421    23438      +17     
  Branches     5902     5907       +5     
==========================================
+ Hits        18303    18327      +24     
+ Misses       5118     5111       -7     
Files Coverage Δ
...ts/pipelines/content/import/PipelineFileUpload.tsx 96.55% <96.00%> (+21.55%) ⬆️

... and 2 files with indirect coverage changes


Continue to review full report in Codecov by Sentry.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 20d32e9...95b3410. Read the comment docs.

Copy link
Contributor

@jeff-phillips-18 jeff-phillips-18 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/lgtm

Copy link
Contributor

openshift-ci bot commented Jun 4, 2024

[APPROVALNOTIFIER] This PR is APPROVED

Approval requirements bypassed by manually added approval.

This pull-request has been approved by: jeff-phillips-18

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@openshift-merge-bot openshift-merge-bot bot merged commit 7aa7178 into opendatahub-io:main Jun 4, 2024
8 checks passed
@andrewballantyne andrewballantyne deleted the add-filesize-limit branch June 26, 2024 18:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants