Created attachment 1712330 [details]
Description of problem:
Normal user have a project, and on the project overview page, there is "Resource Quotas" card at the bottom, after create a quota for the project, check the project overview again, the "Resource Quotas" card disappears.
Version-Release number of selected component (if applicable):
Steps to Reproduce:
1.Normal user have a project, check the project overview page.
2.Create a quota for the project by cluster admin.
$ oc create quota myquota1 --hard=cpu=1,requests.memory=1G,limits.cpu=2,limits.memory=2G,pods=2,services=3 -n prozyp1
3.Check the project overview page again.
1. There is "Resource Quotas" card at the bottom,
2. Quota is added to the project.
3. The "Resource Quotas" card disappears from project overview page.
3. The "Resource Quotas" card should not disappear, and quota chart should show up.
Created attachment 1712331 [details]
I'm not seeing this? I'm on master (pulled the latest and ran yarn install, etc.). I'll try a different cluster.
Created attachment 1712431 [details]
Screenshot of populated resource quota
Are there other steps that need to be taken to recreate this? I just tried this again on a shared cluster with 4.6.0-0.nightly-2020-08-24-062015, and I'm seeing the resource quota section populate just fine.
It looks to me like the browser couldn't connect to the server based on what I see in the console. Are you sure you had a good network connection and the server was still available?
Moving to WORKSFORME since we can't reproduce.
@ralpert, are you login with a normal user or a cluster admin when checking resource quota on project overview page? The issue occurs with normal user. Cluster admin user could see resource quota.
Still could reproduce the bug。And normal user login console, the console response becomes very slow, many errors in F12 console. Cluster admin user has no this issue.
Created attachment 1712461 [details]
Created attachment 1712651 [details]
Normal user view empty project overview page gets thousands of error
When a normal user goes to an empty project Overview page, we can see thousands of error thrown and console can not give any response
I'm not sure if they're the same issue
for the behavior in comment 8, I didn't create resourcequota at all
I logged in as a normal user and don't see this behavior. The page loads properly, and resource quotas appear when they are created. I'm testing 4.6.0-0.nightly-2020-08-02-134243. See screenshots. The user `test` has no special privileges.
All users should be able to list consolelinks for instance, and I see errors for those. I think this might be something in your environment. I can't reproduce.
Is there any chance you're trying to access a project where the user doesn't have `edit` or `view` access? Can you try a different cluster?
Created attachment 1712732 [details]
Working project page with normal user
I realize now the cluster from comment #11 is pretty old. I'm going to stand up a newer cluster to test the latest.
I'm able to reproduce the consolelinks problem, regression from https://github.com/openshift/console/pull/6180. Reopening and assigning to Robb to investigate.
The bug was the result of an issue with the useK8sWatchResource hook, which Rastislav fixed with https://github.com/openshift/console/pull/6456.
Checked on 4.6 cluster with payload 4.6.0-0.nightly-2020-08-31-012413.
Now normal user login console, the project overview page could load resource quota card with existing quota charts successfully, and the console response becomes fast now.
The bug is fixed.