Description of problem:
After fixing that the Devfile samples could not be loaded on Safari (only), it looks like they couldn't be loaded at all / or on other browsers.
The reason was that the browsers caches an redirect from /api/devfile/samples (frontend code) to /api/devfile/samples/ (backend code). The PR https://github.com/openshift/console/pull/10464 to fix https://bugzilla.redhat.com/show_bug.cgi?id=2023356 changed all code to /api/devfile/samples but the browsers keep their redirect. So that the fix works when the user clears their cache or uses another cluster (URL) but has issues after updating locally. We could also expect that the users will have issues after updating from 4.9 to 4.10 with this solution.
I believe the easiest solution is to switch all URLs to /api/devfile/samples/ (old backend code) instead.
Version-Release number of selected component (if applicable):
Only if the user uses an older version first (before https://github.com/openshift/console/pull/10464 was merged) and then switches to the latest version.
Steps to Reproduce:
1. Test with an old version first (before 22th Nov 2021)
2. Open developer perspective and open Add > Samples
3. Switch your console to the latest master
4. Open developer perspective and open Add > Samples again
The Devfile samples could not be loaded. After cleaning the browser cache it works fine.
The Devfile samples could be loaded also when the browser has a redirect in its cache.
You can open the browser network inspector to check if the API calls contain any redirect.
Verified on 4.10.0-0.nightly-2021-12-16-185411 with Safari 15.1 on macOS 12.0.1.
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.
For information on the advisory (Moderate: OpenShift Container Platform 4.10.3 security update), and where to find the updated
files, follow the link below.
If the solution does not work for you, open a new bug report.