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

Not having Google Analytics set up results in 404 request #2481

Open
J4bbi opened this issue Sep 7, 2023 · 1 comment
Open

Not having Google Analytics set up results in 404 request #2481

J4bbi opened this issue Sep 7, 2023 · 1 comment
Labels
bug component: statistics Google Analytics help wanted Needs a volunteer to claim to move forward

Comments

@J4bbi
Copy link
Contributor

J4bbi commented Sep 7, 2023

Describe the bug
If a repository is not set up to use Google Analytics, the backend responds with a 404 response. If a property hasn't been set (see REST contract for configuration properties).

To Reproduce
Steps to reproduce the behavior:

  1. Open up a repository landing page (or any page)
  2. Inspect the console

Expected behavior
The frontend should be able to gracefully establish if Google Analytics is disabled.

@J4bbi J4bbi added bug needs triage New issue needs triage and/or scheduling Google Analytics labels Sep 7, 2023
@tdonohue
Copy link
Member

tdonohue commented Sep 7, 2023

Would require fixing DSpace/DSpace#9014

Or, might be solved by a way to pull down all enabled backend configurations at once (GET /api/config/properties). In that scenario, there would be no need to call this endpoint for individual configs one-by-one, so this 404 response would be rare. But as we know that "findAll" style endpoint doesn't exist yet: https://github.com/DSpace/RestContract/blob/main/configuration.md#main-endpoint

Currently, this endpoint behaves "as designed". I agree though that a 404 response is misleading, as it implies a possible error. But, the intended meaning is simply that the backend configuration "doesn't exist" or isn't enabled/shared.

Overall, sites seeing this can safely ignore the 404. But, I do agree it'd be nice to provide a better response that is not as misleading.

@tdonohue tdonohue added help wanted Needs a volunteer to claim to move forward and removed needs triage New issue needs triage and/or scheduling labels May 1, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug component: statistics Google Analytics help wanted Needs a volunteer to claim to move forward
Projects
Status: 🙋 Needs Help / Unscheduled
Development

No branches or pull requests

2 participants