Skip to content

Commit

Permalink
chore: rename groups to issues (#26511)
Browse files Browse the repository at this point in the history
  • Loading branch information
daibhin authored Nov 29, 2024
1 parent 58c8789 commit 6eea995
Show file tree
Hide file tree
Showing 9 changed files with 26 additions and 26 deletions.
2 changes: 1 addition & 1 deletion frontend/src/scenes/appScenes.ts
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ export const appScenes: Record<Scene, () => any> = {
[Scene.EarlyAccessFeature]: () => import('./early-access-features/EarlyAccessFeature'),
[Scene.ErrorTracking]: () => import('./error-tracking/ErrorTrackingScene'),
[Scene.ErrorTrackingConfiguration]: () => import('./error-tracking/ErrorTrackingConfigurationScene'),
[Scene.ErrorTrackingGroup]: () => import('./error-tracking/ErrorTrackingGroupScene'),
[Scene.ErrorTrackingIssue]: () => import('./error-tracking/ErrorTrackingIssueScene'),
[Scene.Surveys]: () => import('./surveys/Surveys'),
[Scene.Survey]: () => import('./surveys/Survey'),
[Scene.CustomCss]: () => import('./themes/CustomCssScene'),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,14 +10,14 @@ import { ErrorTrackingIssue } from '~/queries/schema'

import { AssigneeSelect } from './AssigneeSelect'
import ErrorTrackingFilters from './ErrorTrackingFilters'
import { errorTrackingGroupSceneLogic } from './errorTrackingGroupSceneLogic'
import { errorTrackingIssueSceneLogic } from './errorTrackingIssueSceneLogic'
import { OverviewTab } from './groups/OverviewTab'
import { SymbolSetUploadModal } from './SymbolSetUploadModal'

export const scene: SceneExport = {
component: ErrorTrackingGroupScene,
logic: errorTrackingGroupSceneLogic,
paramsToProps: ({ params: { id } }): (typeof errorTrackingGroupSceneLogic)['props'] => ({ id }),
component: ErrorTrackingIssueScene,
logic: errorTrackingIssueSceneLogic,
paramsToProps: ({ params: { id } }): (typeof errorTrackingIssueSceneLogic)['props'] => ({ id }),
}

const STATUS_LABEL: Record<ErrorTrackingIssue['status'], string> = {
Expand All @@ -27,9 +27,9 @@ const STATUS_LABEL: Record<ErrorTrackingIssue['status'], string> = {
pending_release: 'Pending release',
}

export function ErrorTrackingGroupScene(): JSX.Element {
const { issue, issueLoading, hasGroupActions } = useValues(errorTrackingGroupSceneLogic)
const { updateIssue, loadIssue } = useActions(errorTrackingGroupSceneLogic)
export function ErrorTrackingIssueScene(): JSX.Element {
const { issue, issueLoading, hasGroupActions } = useValues(errorTrackingIssueSceneLogic)
const { updateIssue, loadIssue } = useActions(errorTrackingIssueSceneLogic)

useEffect(() => {
// don't like doing this but scene logics do not unmount after being loaded
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import { urls } from 'scenes/urls'
import { ErrorTrackingIssue } from '~/queries/schema'
import { Breadcrumb } from '~/types'

import type { errorTrackingGroupSceneLogicType } from './errorTrackingGroupSceneLogicType'
import type { errorTrackingIssueSceneLogicType } from './errorTrackingIssueSceneLogicType'
import { errorTrackingLogic } from './errorTrackingLogic'
import { errorTrackingIssueEventsQuery, errorTrackingIssueQuery } from './queries'

Expand All @@ -25,7 +25,7 @@ export interface ErrorTrackingEvent {
}
}

export interface ErrorTrackingGroupSceneLogicProps {
export interface ErrorTrackingIssueSceneLogicProps {
id: ErrorTrackingIssue['id']
}

Expand All @@ -34,9 +34,9 @@ export enum IssueTab {
Breakdowns = 'breakdowns',
}

export const errorTrackingGroupSceneLogic = kea<errorTrackingGroupSceneLogicType>([
path((key) => ['scenes', 'error-tracking', 'errorTrackingGroupSceneLogic', key]),
props({} as ErrorTrackingGroupSceneLogicProps),
export const errorTrackingIssueSceneLogic = kea<errorTrackingIssueSceneLogicType>([
path((key) => ['scenes', 'error-tracking', 'errorTrackingIssueSceneLogic', key]),
props({} as ErrorTrackingIssueSceneLogicProps),
key((props) => props.id),

connect({
Expand Down Expand Up @@ -142,7 +142,7 @@ export const errorTrackingGroupSceneLogic = kea<errorTrackingGroupSceneLogicType
path: urls.errorTracking(),
},
{
key: [Scene.ErrorTrackingGroup, exceptionType],
key: [Scene.ErrorTrackingIssue, exceptionType],
name: exceptionType,
},
]
Expand Down
4 changes: 2 additions & 2 deletions frontend/src/scenes/error-tracking/groups/BreakdownsTab.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import { useState } from 'react'
import { Query } from '~/queries/Query/Query'

import { errorTrackingLogic } from '../errorTrackingLogic'
import { errorTrackingGroupBreakdownQuery } from '../queries'
import { errorTrackingIssueBreakdownQuery } from '../queries'

const gridColumnsMap = {
small: 'grid-cols-1',
Expand Down Expand Up @@ -70,7 +70,7 @@ const BreakdownGroup = ({ group }: { group: BreakdownGroup }): JSX.Element => {
)}
</div>
<Query
query={errorTrackingGroupBreakdownQuery({
query={errorTrackingIssueBreakdownQuery({
breakdownProperty: selectedProperty,
dateRange: dateRange,
filterTestAccounts: filterTestAccounts,
Expand Down
6 changes: 3 additions & 3 deletions frontend/src/scenes/error-tracking/groups/OverviewTab.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,11 @@ import { dayjs } from 'lib/dayjs'
import { sessionPlayerModalLogic } from 'scenes/session-recordings/player/modal/sessionPlayerModalLogic'
import { PropertyIcons } from 'scenes/session-recordings/playlist/SessionRecordingPreview'

import { ErrorTrackingEvent, errorTrackingGroupSceneLogic } from '../errorTrackingGroupSceneLogic'
import { ErrorTrackingEvent, errorTrackingIssueSceneLogic } from '../errorTrackingIssueSceneLogic'

export const OverviewTab = (): JSX.Element => {
const { events, issueLoading, eventsLoading, activeEventUUID } = useValues(errorTrackingGroupSceneLogic)
const { loadEvents, setActiveEventUUID } = useActions(errorTrackingGroupSceneLogic)
const { events, issueLoading, eventsLoading, activeEventUUID } = useValues(errorTrackingIssueSceneLogic)
const { loadEvents, setActiveEventUUID } = useActions(errorTrackingIssueSceneLogic)

return (
<div className="ErrorTracking__issue">
Expand Down
2 changes: 1 addition & 1 deletion frontend/src/scenes/error-tracking/queries.ts
Original file line number Diff line number Diff line change
Expand Up @@ -180,7 +180,7 @@ export const errorTrackingIssueEventsQuery = ({
return query
}

export const errorTrackingGroupBreakdownQuery = ({
export const errorTrackingIssueBreakdownQuery = ({
breakdownProperty,
dateRange,
filterTestAccounts,
Expand Down
2 changes: 1 addition & 1 deletion frontend/src/scenes/sceneTypes.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ export enum Scene {
ErrorNetwork = '4xx',
ErrorProjectUnavailable = 'ProjectUnavailable',
ErrorTracking = 'ErrorTracking',
ErrorTrackingGroup = 'ErrorTrackingGroup',
ErrorTrackingIssue = 'ErrorTrackingIssue',
ErrorTrackingConfiguration = 'ErrorTrackingConfiguration',
Dashboards = 'Dashboards',
Dashboard = 'Dashboard',
Expand Down
6 changes: 3 additions & 3 deletions frontend/src/scenes/scenes.ts
Original file line number Diff line number Diff line change
Expand Up @@ -69,9 +69,9 @@ export const sceneConfigurations: Record<Scene, SceneConfig> = {
projectBased: true,
name: 'Error tracking configuration',
},
[Scene.ErrorTrackingGroup]: {
[Scene.ErrorTrackingIssue]: {
projectBased: true,
name: 'Error tracking group',
name: 'Error tracking issue',
},
[Scene.Insight]: {
projectBased: true,
Expand Down Expand Up @@ -559,7 +559,7 @@ export const routes: Record<string, Scene> = {
[urls.earlyAccessFeature(':id')]: Scene.EarlyAccessFeature,
[urls.errorTracking()]: Scene.ErrorTracking,
[urls.errorTrackingConfiguration()]: Scene.ErrorTrackingConfiguration,
[urls.errorTrackingIssue(':id')]: Scene.ErrorTrackingGroup,
[urls.errorTrackingIssue(':id')]: Scene.ErrorTrackingIssue,
[urls.surveys()]: Scene.Surveys,
[urls.survey(':id')]: Scene.Survey,
[urls.surveyTemplates()]: Scene.SurveyTemplates,
Expand Down
4 changes: 2 additions & 2 deletions posthog/models/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
from .element import Element
from .element_group import ElementGroup
from .entity import Entity
from .error_tracking import ErrorTrackingGroup, ErrorTrackingStackFrame, ErrorTrackingSymbolSet
from .error_tracking import ErrorTrackingIssue, ErrorTrackingStackFrame, ErrorTrackingSymbolSet
from .event.event import Event
from .event_buffer import EventBuffer
from .event_definition import EventDefinition
Expand Down Expand Up @@ -101,7 +101,7 @@
"Element",
"ElementGroup",
"Entity",
"ErrorTrackingGroup",
"ErrorTrackingIssue",
"ErrorTrackingStackFrame",
"ErrorTrackingSymbolSet",
"Event",
Expand Down

0 comments on commit 6eea995

Please sign in to comment.