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

Related endpoint error is still sent to Sentry #4009

Merged
merged 2 commits into from
Apr 8, 2024

Conversation

jeevikasirwani
Copy link
Contributor

@jeevikasirwani jeevikasirwani commented Apr 2, 2024

Fixes

Fixes #4006 by @obulat

Description

This PR removes the line that sends network error to sentry on related endpoint. This line was accidentally left in code in #3850.

Testing Instructions

First, try these instructions on main branch, and then re-run them in this branch.
On main, you should see the analytics and the sentry log in the browser console. Here, there should only be the analytics log, nothing should be logged for sentry.

  1. SetlogMockCalls in sentry config to true:
    logMockCalls: false,
  2. Run the app using just frontend/run dev
  3. Go to http://localhost:8443/search/?q=cat
  4. Set network throttling to slow 3G and click on the first image result
  5. Immediately set network throttling to offline. The related images shouldn't load, and you can see analytics and/or sentry logs in the browser console.

Checklist

  • My pull request has a descriptive title (not a vague title likeUpdate index.md).
  • My pull request targets the default branch of the repository (main) or a parent feature branch.
  • My commit messages follow best practices.
  • My code follows the established code style of the repository.
  • I added or updated tests for the changes I made (if applicable).
  • I added or updated documentation (if applicable).
  • I tried running the project locally and verified that there are no visible errors.
  • I ran the DAG documentation generator (if applicable).

Developer Certificate of Origin

Developer Certificate of Origin
Developer Certificate of Origin
Version 1.1

Copyright (C) 2004, 2006 The Linux Foundation and its contributors.
1 Letterman Drive
Suite D4700
San Francisco, CA, 94129

Everyone is permitted to copy and distribute verbatim copies of this
license document, but changing it is not allowed.


Developer's Certificate of Origin 1.1

By making a contribution to this project, I certify that:

(a) The contribution was created in whole or in part by me and I
    have the right to submit it under the open source license
    indicated in the file; or

(b) The contribution is based upon previous work that, to the best
    of my knowledge, is covered under an appropriate open source
    license and I have the right under that license to submit that
    work with modifications, whether created in whole or in part
    by me, under the same open source license (unless I am
    permitted to submit under a different license), as indicated
    in the file; or

(c) The contribution was provided directly to me by some other
    person who certified (a), (b) or (c) and I have not modified
    it.

(d) I understand and agree that this project and the contribution
    are public and that a record of the contribution (including all
    personal information I submit with it, including my sign-off) is
    maintained indefinitely and may be redistributed consistent with
    this project or the open source license(s) involved.

@jeevikasirwani jeevikasirwani requested a review from a team as a code owner April 2, 2024 12:49
@jeevikasirwani jeevikasirwani requested review from obulat and dhruvkb April 2, 2024 12:49
@openverse-bot openverse-bot added 🚦 status: awaiting triage Has not been triaged & therefore, not ready for work 🏷 status: label work required Needs proper labelling before it can be worked on labels Apr 2, 2024
Copy link
Contributor

@obulat obulat left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for your PR, @jeevikasirwani ! I added a suggestion inline to completely delete the line instead of commenting it out.

Could you please also fill in the PR description - without it the PR automations do not work.

frontend/src/stores/media/related-media.ts Outdated Show resolved Hide resolved
@openverse-bot openverse-bot added 🟨 priority: medium Not blocking but should be addressed soon 🛠 goal: fix Bug fix 💻 aspect: code Concerns the software code in the repository labels Apr 2, 2024
@obulat obulat added 🧱 stack: frontend Related to the Nuxt frontend and removed 🏷 status: label work required Needs proper labelling before it can be worked on 🚦 status: awaiting triage Has not been triaged & therefore, not ready for work labels Apr 2, 2024
Copy link
Contributor

@obulat obulat left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I added the PR description and testing instructions.

Thank you for your contribution, @jeevikasirwani !

@obulat obulat changed the title fix:Related endpoint error is still sent to Sentry #4006 Related endpoint error is still sent to Sentry #4006 Apr 8, 2024
@obulat obulat changed the title Related endpoint error is still sent to Sentry #4006 Related endpoint error is still sent to Sentry Apr 8, 2024
@obulat obulat requested a review from sarayourfriend April 8, 2024 16:18
Copy link
Collaborator

@sarayourfriend sarayourfriend left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thanks @jeevikasirwani 🙂

@sarayourfriend sarayourfriend merged commit 3cf0fdd into WordPress:main Apr 8, 2024
71 of 78 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
💻 aspect: code Concerns the software code in the repository 🛠 goal: fix Bug fix 🟨 priority: medium Not blocking but should be addressed soon 🧱 stack: frontend Related to the Nuxt frontend
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

Related endpoint error is still sent to Sentry
4 participants