Skip to content
This repository has been archived by the owner on Sep 30, 2024. It is now read-only.

web: remove integrations banners and corresponding pings #38715

Merged
merged 18 commits into from
Jul 14, 2022

Conversation

taras-yemets
Copy link
Contributor

@taras-yemets taras-yemets commented Jul 13, 2022

Closes https://github.com/sourcegraph/sourcegraph/issues/38625

Removes browser and IDE extensions banners from Sourcegraph website and corresponding pings.

Removed banners (screenshots in this comment):

  • Search results page
    • Browser extension, IDE, and signup banners
  • File page
    • Browser extension banner (and tooltip preceding it) shown when hovering on the 'View on the code host' link with a certain cadence
  • VSCode extension
    • Signup banner

Reverts changes introduced by the following PRs:

Test plan

  • ensure tests un CI pass
  • sg start web-standalone
  • Sourcegraph web
    • on search results page
      • reload it not less than five times and ensure that neither browser extension nor IDE extensions banner is shown
      • on sourcegraph.com: ensure you're not logged in and the signup banner is not visible (try multiple page reloads too)
    • on file page
      • hover on different code tokens not less than five times, then hover over View on the code host icon button and ensure that the browser extension popup is not shown (click should take you to the code host)
  • VSCode extension
    • search results view
      • on sourcegraph.com: ensure you're not logged in and the signup banner is not visible

App preview:

Check out the client app preview documentation to learn more.

@cla-bot cla-bot bot added the cla-signed label Jul 13, 2022
@taras-yemets
Copy link
Contributor Author

taras-yemets commented Jul 13, 2022

@vdavid,
given the scope of this PR, do you think that we can safely (manually) revert https://github.com/sourcegraph/sourcegraph/pull/29966? If so, we should probably also remove changes to client/web/src/site-admin/SiteAdminPingsPage.tsx (CTA usage data) introduced by https://github.com/sourcegraph/sourcegraph/pull/30400.

@vdavid
Copy link
Contributor

vdavid commented Jul 13, 2022

@taras-yemets The four PRs related to browser and IDE CTAs are:

I think all four of these can be manually reverted.

Note: There is a clear process for adding pings but none for removing them. As not sending data is not really a privacy concern, I'd say an RFC is not needed here. As long as all the tests pass, we're safe to remove the pings.

@taras-yemets
Copy link
Contributor Author

@vdavid, thanks a lot for the insight! Will check these PRs step by step.

@taras-yemets taras-yemets requested a review from a team July 14, 2022 09:03
@taras-yemets taras-yemets marked this pull request as ready for review July 14, 2022 09:03
@sourcegraph-bot
Copy link
Contributor

sourcegraph-bot commented Jul 14, 2022

Codenotify: Notifying subscribers in CODENOTIFY files for diff 268db33...3addad4.

Notify File(s)
@fkling client/web/src/search/helpers.tsx
client/web/src/search/results/StreamingSearchResults.tsx
@limitedmage client/web/src/search/helpers.tsx
client/web/src/search/results/StreamingSearchResults.tsx
@sourcegraph/delivery doc/admin/pings.md

@taras-yemets taras-yemets changed the title web: remove integrations banners web: remove integrations banners and corresponding pings Jul 14, 2022
@taras-yemets taras-yemets requested a review from vdavid July 14, 2022 09:45
@taras-yemets taras-yemets requested a review from a team July 14, 2022 10:09
Copy link
Contributor

@vdavid vdavid left a comment

Choose a reason for hiding this comment

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

The changes look good to me, they should be fine if CI tests pass!
I keep on forgetting how difficult experiments are mentally: if they succeed, your code stays, if they fail, your code is removed. But I’m happy that we’re doing it the right way and remove the commit once the experiment failed! Also, it’s nice to see such a big red commit. :)

@taras-yemets
Copy link
Contributor Author

Thanks a lot for your help, @vdavid!

@taras-yemets taras-yemets merged commit ed49042 into main Jul 14, 2022
@taras-yemets taras-yemets deleted the taras-yemets/remove-extensions-banners branch July 14, 2022 13:30
Copy link
Contributor

@limitedmage limitedmage left a comment

Choose a reason for hiding this comment

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

🎉
Some minor cleanup comments on the post-merge review.

Comment on lines -97 to -104
const [hasDismissedBrowserExtensionAlert, setHasDismissedBrowserExtensionAlert] = useTemporarySetting(
'cta.browserExtensionAlertDismissed',
false
)
const [hasDismissedIDEExtensionAlert, setHasDismissedIDEExtensionAlert] = useTemporarySetting(
'cta.ideExtensionAlertDismissed',
false
)
Copy link
Contributor

Choose a reason for hiding this comment

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

Can we remove these temporary settings keys from the schema if they're not used anymore?

Comment on lines -40 to -41
const [lastVSCodeDetection] = useTemporarySetting('integrations.vscode.lastDetectionTimestamp', 0)
const [lastJetBrainsDetection] = useTemporarySetting('integrations.jetbrains.lastDetectionTimestamp', 0)
Copy link
Contributor

Choose a reason for hiding this comment

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

Same comment here, should we remove these keys?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Thank you for your review, @limitedmage!

Given that we removed all IDE banners, I wonder if we still need <IdeExtensionTracker /> component?
What do you think @vdavid, @philipp-spiess?

Copy link
Contributor

Choose a reason for hiding this comment

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

Yes, as far as I know, only the CTAs used the IDE extension detection, so that code can go as well.

Copy link
Contributor

Choose a reason for hiding this comment

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

🔪

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Remove all banners for our features
5 participants