client-web
client-web copied to clipboard
BUG: hubCommunity, challengeCommunity and opportunityCommunity requests are executed twice
Describe the bug
When user navigates to Hub, Challenge or Opportunity page, hubCommunity
, communityChallenge
and communityOpportunity
requests are executed twice
To Reproduce Steps to reproduce the behavior:
- Go to https://dev.alkem.io/
- Authenticate with GA
- Open browser network tool
- Click on hub "UN Sustainable Development Goals" - hubCommunity request is executed twice
- Open challenge "02 Zero Hunger" - challengeCommunity request is executed twice
- Open opportunity "Rural Development" - opportunityCommunity request is executed twice
Expected behavior The requests are executed only ones
Closing the bug as this is expected behaviour when combining Apollo query and React context. The query that is doubled is not heavy on data and doesn't exhausting our resources.
This will be fixed by removing the community context which requires more time than estimated.
@alstojanovic this should not be closed but rather blocked as it cannot be fixed until we remove the community context. Also I would challenge that the community query is "light" - certainly not on some of the bigger hubs such as hub.alkem.io/digicampus.
@techsmyth this issue will be solved only by removing community context which is already deprecated. That constitutes as a technical depth and is a bit more work and can potentially break other things. I closed the bug but I was going to open a separate card for tackling this. I'm ok with having this in blocked state, as a reminder for the issue, but the tech debt card would also serve as a reminder so then there is no point having the bug card anymore.
I'm ok either way. We can both open a tech debt card and have the bug in blocked state or whatever is best process wise.