Skip to content

Commit 1448df5

Browse files
feat(codecov): Hide TA feature (#109527)
Hide the Prevent TA feature
1 parent 4e71a22 commit 1448df5

File tree

5 files changed

+7
-121
lines changed

5 files changed

+7
-121
lines changed

knip.config.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,9 @@ const productionEntryPoints = [
1818
'static/app/components/core/quote/*.tsx',
1919
// Prevent exception until we build out coverage
2020
'static/app/components/prevent/virtualRenderers/**/*.{js,ts,tsx}',
21+
// Temporary Prevent TA exceptions until the code is removed
22+
'static/app/views/nav/secondary/sections/prevent/**/*.{js,ts,tsx}',
23+
'static/app/views/prevent/**/*.{js,ts,tsx}',
2124
// todo we currently keep all icons
2225
'static/app/icons/**/*.{js,ts,tsx}',
2326
// todo find out how chartcuterie works

static/app/router/routes.tsx

Lines changed: 0 additions & 37 deletions
Original file line numberDiff line numberDiff line change
@@ -2358,42 +2358,6 @@ function buildRoutes(): RouteObject[] {
23582358
children: exploreChildren,
23592359
};
23602360

2361-
const preventRoutes: SentryRouteObject = {
2362-
path: '/prevent/',
2363-
withOrgPath: true,
2364-
component: make(() => import('sentry/views/prevent/index')),
2365-
children: [
2366-
{
2367-
index: true,
2368-
redirectTo: 'tests/',
2369-
},
2370-
{
2371-
path: 'tests/',
2372-
component: make(() => import('sentry/views/prevent/tests/testsWrapper')),
2373-
children: [
2374-
{
2375-
index: true,
2376-
component: make(() => import('sentry/views/prevent/tests/tests')),
2377-
},
2378-
{
2379-
path: 'new/',
2380-
component: make(() => import('sentry/views/prevent/tests/onboarding')),
2381-
},
2382-
],
2383-
},
2384-
{
2385-
path: 'tokens/',
2386-
component: make(() => import('sentry/views/prevent/tokens/tokensWrapper')),
2387-
children: [
2388-
{
2389-
index: true,
2390-
component: make(() => import('sentry/views/prevent/tokens/tokens')),
2391-
},
2392-
],
2393-
},
2394-
],
2395-
};
2396-
23972361
const preprodChildren: SentryRouteObject[] = [
23982362
{
23992363
index: true,
@@ -2828,7 +2792,6 @@ function buildRoutes(): RouteObject[] {
28282792
issueRoutes,
28292793
alertRoutes,
28302794
monitorRoutes,
2831-
preventRoutes,
28322795
preprodRoutes,
28332796
pullRequestRoutes,
28342797
replayRoutes,

static/app/views/nav/primary/index.tsx

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,6 @@ import {
1717
IconSettings,
1818
IconSiren,
1919
} from 'sentry/icons';
20-
import type {Organization} from 'sentry/types/organization';
2120
import useOrganization from 'sentry/utils/useOrganization';
2221
import {getDefaultExploreRoute} from 'sentry/views/explore/utils';
2322
import {useNavContext} from 'sentry/views/nav/context';
@@ -69,11 +68,11 @@ function SidebarFooter({children}: {children: React.ReactNode}) {
6968
);
7069
}
7170

72-
function showPreventNav(organization: Organization) {
71+
function showPreventNav() {
7372
// only people with test analytics can see the prevent nav
7473
// Legacy Seer and New Seer orgs are getting a Seer Config Reminder icon, which
7574
// means that the only Prevent sub-nav item remaining is the Tests item.
76-
return organization.features.includes('prevent-test-analytics');
75+
return false;
7776
}
7877

7978
export function PrimaryNavigationItems() {
@@ -161,7 +160,7 @@ export function PrimaryNavigationItems() {
161160
</NavTourElement>
162161
</Feature>
163162

164-
{showPreventNav(organization) ? (
163+
{showPreventNav() ? (
165164
<Container position="relative" height="100%">
166165
<SidebarLink
167166
to={`/${prefix}/prevent/tests/`}

static/app/views/nav/secondary/secondaryNavContent.tsx

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,6 @@ import {ExploreSecondaryNav} from 'sentry/views/nav/secondary/sections/explore/e
77
import {InsightsSecondaryNav} from 'sentry/views/nav/secondary/sections/insights/insightsSecondaryNav';
88
import {IssuesSecondaryNav} from 'sentry/views/nav/secondary/sections/issues/issuesSecondaryNav';
99
import {MonitorsSecondaryNav} from 'sentry/views/nav/secondary/sections/monitors/monitorsSecondaryNav';
10-
import PreventSecondaryNav from 'sentry/views/nav/secondary/sections/prevent/preventSecondaryNav';
1110
import {SettingsSecondaryNav} from 'sentry/views/nav/secondary/sections/settings/settingsSecondaryNav';
1211
import {PrimaryNavGroup} from 'sentry/views/nav/types';
1312

@@ -24,7 +23,7 @@ export function SecondaryNavContent({group}: {group: PrimaryNavGroup}): ReactNod
2423
case PrimaryNavGroup.MONITORS:
2524
return <MonitorsSecondaryNav />;
2625
case PrimaryNavGroup.PREVENT:
27-
return <PreventSecondaryNav />;
26+
return null;
2827
case PrimaryNavGroup.SETTINGS:
2928
return <SettingsSecondaryNav />;
3029
case PrimaryNavGroup.ADMIN:

static/app/views/nav/secondary/sections/prevent/preventSecondaryNav.spec.tsx

Lines changed: 0 additions & 78 deletions
This file was deleted.

0 commit comments

Comments
 (0)