Add version to pdf.js file in webpack builds
What does this MR do and why?
This MR backports the changes from !168419 (merged) to 17-4-stable-ee
.
pdf.js
was upgraded in 17.4
, and we discovered that a cached version of assets/webpack/pdfjs/pdf.worker.min.js
can be served, causing PDF rendering issues.
This backport ensures that PDF rendering works as expected for self-managed instances.
MR acceptance checklist
Please evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.
Screenshots or screen recordings
Screenshots are required for UI changes, and strongly recommended for all other merge requests.
How to set up and validate locally
- follow the instructions to run the app in webpack
- run
yarn run clean
to remove the existingpubic/assets
files - run
yarn webpack
, new pdfjs files should be copied underpublic/assets/webpack/pdfjs/3.11.174
- viewing pdf files should work as expected
note, i am not 100% sure if there is a way to see the files being copied, besides running yarn webpack
, which triggers the copy plugin. the source tab in the browser only shows the public output path. however, webpack only runs in gdk for me withOUT the public assets folder. so after the first 3 steps, the public asset needs to be removed to make sure webpack is working again.
Related to #491716 (closed)
Merge request reports
Activity
changed milestone to %17.5
assigned to @ms.mondrian
added pipelinetier-1 label
- Resolved by Vitaly Slobodin
2 Warnings This merge request changed files with disabled eslint rules. Please consider fixing them. The e2e:test-on-omnibus-ee
job needs to succeed or have approval from a Software Engineer in Test.
Read the "QA e2e:test-on-omnibus-ee" section for more details.1 Message CHANGELOG missing: If this merge request needs a changelog entry, add the
Changelog
trailer to the commit message you want to add to the changelog.If this merge request doesn't need a CHANGELOG entry, feel free to ignore this message.
Disabled eslint rules
The following files have disabled
eslint
rules. Please consider fixing them:vite.config.js
Run the following command for more details
node_modules/.bin/eslint --report-unused-disable-directives --no-inline-config \ 'vite.config.js'
Reviewer roulette
Category Reviewer Maintainer frontend @kkloss
(UTC+2, 6 hours ahead of author)@vitallium
(UTC+2, 6 hours ahead of author)Please refer to documentation page for guidance on how you can benefit from the Reviewer Roulette, or use the GitLab Review Workload Dashboard to find other available reviewers.
QA
e2e:test-on-omnibus-ee
@ms.mondrian, the
e2e:test-on-omnibus
job must complete before merging this merge request.*If there are failures on the
e2e:test-on-omnibus
pipeline, ping your team's associated Software Engineer in Test (SET) to confirm the failures are unrelated to the merge request. If there's no SET assigned, ask for assistance on the#test-platform
Slack channel.If needed, you can retry the
danger-review
job that generated this comment.Generated by
Danger Edited by ****
requested review from @kkloss
E2E Test Result Summary
allure-report-publisher
generated test report!e2e-test-on-omnibus:
test report for 2152d84b expand test summary
+---------------------------------------------------------------------+ | suites summary | +----------------+--------+--------+---------+-------+-------+--------+ | | passed | failed | skipped | flaky | total | result | +----------------+--------+--------+---------+-------+-------+--------+ | Systems | 7 | 0 | 0 | 1 | 7 | ✅ | | Data Stores | 46 | 0 | 11 | 0 | 57 | ✅ | | Govern | 108 | 0 | 5 | 0 | 113 | ✅ | | Verify | 51 | 0 | 15 | 0 | 66 | ✅ | | Manage | 27 | 0 | 18 | 6 | 45 | ✅ | | Monitor | 12 | 0 | 13 | 0 | 25 | ✅ | | Analytics | 3 | 0 | 0 | 0 | 3 | ✅ | | Create | 552 | 1 | 72 | 1 | 625 | ❌ | | Fulfillment | 4 | 0 | 7 | 0 | 11 | ✅ | | GitLab Metrics | 2 | 0 | 1 | 0 | 3 | ✅ | | Package | 31 | 0 | 14 | 0 | 45 | ✅ | | Configure | 1 | 0 | 3 | 0 | 4 | ✅ | | Secure | 4 | 0 | 2 | 0 | 6 | ✅ | | Plan | 82 | 0 | 9 | 0 | 91 | ✅ | | Ai-powered | 1 | 0 | 2 | 1 | 3 | ✅ | | Release | 5 | 0 | 1 | 0 | 6 | ✅ | | ModelOps | 0 | 0 | 1 | 0 | 1 | ➖ | | Growth | 0 | 0 | 2 | 0 | 2 | ➖ | +----------------+--------+--------+---------+-------+-------+--------+ | Total | 936 | 1 | 176 | 9 | 1113 | ❌ | +----------------+--------+--------+---------+-------+-------+--------+
e2e-test-on-gdk:
test report for 2152d84b expand test summary
+------------------------------------------------------------------+ | suites summary | +-------------+--------+--------+---------+-------+-------+--------+ | | passed | failed | skipped | flaky | total | result | +-------------+--------+--------+---------+-------+-------+--------+ | Plan | 74 | 0 | 1 | 0 | 75 | ✅ | | Govern | 72 | 0 | 0 | 0 | 72 | ✅ | | Create | 128 | 0 | 16 | 0 | 144 | ✅ | | Verify | 46 | 0 | 2 | 0 | 48 | ✅ | | Data Stores | 33 | 0 | 1 | 0 | 34 | ✅ | | Manage | 1 | 0 | 1 | 0 | 2 | ✅ | | Package | 20 | 0 | 12 | 0 | 32 | ✅ | | Secure | 4 | 0 | 0 | 0 | 4 | ✅ | | Monitor | 8 | 0 | 0 | 0 | 8 | ✅ | | Release | 5 | 0 | 0 | 0 | 5 | ✅ | | Fulfillment | 2 | 0 | 0 | 0 | 2 | ✅ | | Analytics | 2 | 0 | 0 | 0 | 2 | ✅ | +-------------+--------+--------+---------+-------+-------+--------+ | Total | 395 | 0 | 33 | 0 | 428 | ✅ | +-------------+--------+--------+---------+-------+-------+--------+
Edited by ****removed automation:ml automation:ml wrong labels
requested review from @vitallium
added pipeline:mr-approved label
added pipelinetier-3 pipeline:run-e2e-omnibus-once labels and removed pipelinetier-1 label
Before you set this MR to auto-merge
This merge request will progress on pipeline tiers until it reaches the last tier: pipelinetier-3. We will trigger a new pipeline for each transition to a higher tier.
Before you set this MR to auto-merge, please check the following:
- You are the last maintainer of this merge request
- The latest pipeline for this merge request is pipelinetier-3 (You can find which tier it is in the pipeline name)
- This pipeline is recent enough (created in the last 8 hours)
If all the criteria above apply, please set auto-merge for this merge request.
See pipeline tiers and merging a merge request for more details.
- Resolved by Vitaly Slobodin
@kkloss
, thanks for approving this merge request.This is the first time the merge request has been approved. Please ensure the
e2e:test-on-omnibus-ee
job has succeeded. If there is a failure, a Software Engineer in Test (SET) needs to confirm the failures are unrelated to the merge request. If there's no SET assigned to this team, ask for assistance on the#test-platform
Slack channel.
removed review request for @kkloss
removed pipeline:run-e2e-omnibus-once label
started a merge train