Skip to content

:hedgehog: PostHog is the leading platform for building self-driving products. Our developer tools – AI observability, analytics, session replay, flags, experiments, error tracking, logs, and more – capture all the context agents need to diagnose problems, uncover opportunities, and ship fixes. Steer it all from Slack, web, desktop, or the MCP.

chore(workflows): remove feature flag gates for wait-until-event and recurring-schedules (#69900)

Daniel Marchuk681d4076f440
diff --git a/frontend/src/lib/constants.tsx b/frontend/src/lib/constants.tsx
index 993c83f018bc..4a29c8fff6b4 100644
--- a/frontend/src/lib/constants.tsx
+++ b/frontend/src/lib/constants.tsx
@@ -532,13 +532,8 @@ export const FEATURE_FLAGS = {
WEB_ANALYTICS_TILE_SKELETONS: 'web-analytics-tile-skeletons', // owner: @jordanm-posthog #team-web-analytics
WEB_ANALYTICS_TILE_TOGGLES: 'web-analytics-tile-toggles', // owner: @lricoy #team-web-analytics
WEB_ANALYTICS_TOOLTIP_COMPARISON_LABELS: 'web-analytics-tooltip-comparison-labels', // owner: @lricoy #team-web-analytics
- WORKFLOWS_BATCH_TRIGGERS: 'workflows-batch-triggers', // owner: #team-workflows
- WORKFLOWS_ENGAGEMENT_EVENTS: 'workflows-engagement-events', // owner: #team-workflows
WORKFLOWS_INTERNAL_EVENT_FILTERS: 'workflows-internal-event-filters', // owner: @haven #team-workflows
- WORKFLOWS_PERSON_TIMEZONE: 'workflows-person-timezone', // owner: #team-workflows
WORKFLOWS_PUSH_NOTIFICATIONS: 'workflows-push-notifications', // owner: @Odin #team-workflows
- WORKFLOWS_RECURRING_SCHEDULES: 'workflows-recurring-schedules', // owner: #team-workflows
- WORKFLOWS_WAIT_UNTIL_EVENT: 'workflows-wait-until-event', // owner: #team-workflows
XAA_AUTHENTICATION: 'xaa-authentication', // owner: @reecejones #team-platform-features
} as const
export type FeatureFlagLookupKey = keyof typeof FEATURE_FLAGS
diff --git a/frontend/src/scenes/settings/SettingsMap.tsx b/frontend/src/scenes/settings/SettingsMap.tsx
index 7dda4db16fcf..681ab6ef8bcf 100644
--- a/frontend/src/scenes/settings/SettingsMap.tsx
+++ b/frontend/src/scenes/settings/SettingsMap.tsx
@@ -1275,7 +1275,6 @@ export const SETTINGS_MAP: SettingSection[] = [
id: 'environment-workflows',
title: 'Workflows',
group: 'Products',
- flag: 'WORKFLOWS_ENGAGEMENT_EVENTS',
settings: [
{
id: 'workflows-engagement-events',
diff --git a/products/workflows/frontend/Workflows/hogflows/steps/StepTrigger.tsx b/products/workflows/frontend/Workflows/hogflows/steps/StepTrigger.tsx
index 8c7b8e521697..3c02596499c3 100644
--- a/products/workflows/frontend/Workflows/hogflows/steps/StepTrigger.tsx
+++ b/products/workflows/frontend/Workflows/hogflows/steps/StepTrigger.tsx
@@ -1,6 +1,5 @@
import { Node } from '@xyflow/react'
import { useActions, useValues } from 'kea'
-import posthog from 'posthog-js'
import { useMemo, useState } from 'react'
import {
@@ -10,7 +9,6 @@ import {
IconInfo,
IconLeave,
IconPeople,
- IconPlusSmall,
IconTarget,
IconWarning,
IconWebhooks,
@@ -23,16 +21,13 @@ import {
LemonInput,
LemonLabel,
LemonSelect,
- LemonTag,
Spinner,
Tooltip,
- lemonToast,
} from '@posthog/lemon-ui'
import { CodeSnippet } from 'lib/components/CodeSnippet'
import { PropertyFilters } from 'lib/components/PropertyFilters/PropertyFilters'
import { TaxonomicFilterGroupType } from 'lib/components/TaxonomicFilter/types'
-import { FEATURE_FLAGS } from 'lib/constants'
import { IconAdsClick } from 'lib/lemon-ui/icons'
import { LemonField } from 'lib/lemon-ui/LemonField'
import { LemonRadio } from 'lib/lemon-ui/LemonRadio'
@@ -781,9 +776,7 @@ function FrequencySection(): JSX.Element {
function ConversionGoalSection(): JSX.Element {
const { setWorkflowValue } = useActions(workflowLogic)
const { workflow } = useValues(workflowLogic)
- const { featureFlags } = useValues(featureFlagLogic)
- const waitUntilEventEnabled = !!featureFlags[FEATURE_FLAGS.WORKFLOWS_WAIT_UNTIL_EVENT]
const conversionEventFilters = workflow.conversion?.events?.[0]?.filters ?? {}
return (
@@ -820,35 +813,19 @@ function ConversionGoalSection(): JSX.Element {
</div>
<div className="flex flex-col gap-1 items-start w-full">
- <LemonLabel>
- Detect conversion from events
- {!waitUntilEventEnabled && <LemonTag>Coming soon</LemonTag>}
- </LemonLabel>
- {waitUntilEventEnabled ? (
- <HogFlowEventFilters
- filtersKey="workflow-conversion-events"
- filters={conversionEventFilters}
- setFilters={(newFilters) =>
- setWorkflowValue('conversion', {
- ...workflow.conversion,
- events: newFilters ? [{ filters: newFilters }] : undefined,
- })
- }
- typeKey="workflow-conversion-event"
- buttonCopy="Add event"
- />
- ) : (
- <LemonButton
- type="secondary"
- icon={<IconPlusSmall />}
- onClick={() => {
- posthog.capture('workflows workflow event conversion clicked')
- lemonToast.info('Event targeting coming soon!')
- }}
- >
- Add event conversion
- </LemonButton>
- )}
+ <LemonLabel>Detect conversion from events</LemonLabel>
+ <HogFlowEventFilters
+ filtersKey="workflow-conversion-events"
+ filters={conversionEventFilters}
+ setFilters={(newFilters) =>
+ setWorkflowValue('conversion', {
+ ...workflow.conversion,
+ events: newFilters ? [{ filters: newFilters }] : undefined,
+ })
+ }
+ typeKey="workflow-conversion-event"
+ buttonCopy="Add event"
+ />
</div>
</div>
</div>
diff --git a/products/workflows/frontend/Workflows/hogflows/steps/StepWaitUntilCondition.tsx b/products/workflows/frontend/Workflows/hogflows/steps/StepWaitUntilCondition.tsx
index 83d624c06144..8ba367b54a5d 100644
--- a/products/workflows/frontend/Workflows/hogflows/steps/StepWaitUntilCondition.tsx
+++ b/products/workflows/frontend/Workflows/hogflows/steps/StepWaitUntilCondition.tsx
@@ -1,12 +1,10 @@
import { Node } from '@xyflow/react'
-import { useActions, useValues } from 'kea'
+import { useActions } from 'kea'
import { IconCursor, IconPerson } from '@posthog/icons'
import { LemonDivider, LemonLabel } from '@posthog/lemon-ui'
-import { FEATURE_FLAGS } from 'lib/constants'
import { LemonInput } from 'lib/lemon-ui/LemonInput'
-import { featureFlagLogic } from 'lib/logic/featureFlagLogic'
import { workflowLogic } from '../../workflowLogic'
import { HogFlowEventFilters, HogFlowPropertyFilters } from '../filters/HogFlowFilters'
@@ -24,9 +22,6 @@ export function StepWaitUntilConditionConfiguration({
const { condition, events, max_wait_duration } = action.config
const { partialSetWorkflowActionConfig } = useActions(workflowLogic)
- const { featureFlags } = useValues(featureFlagLogic)
-
- const waitUntilEventEnabled = !!featureFlags[FEATURE_FLAGS.WORKFLOWS_WAIT_UNTIL_EVENT]
const { localName: localConditionName, handleNameChange } = useDebouncedNameInput(condition, (updatedCondition) =>
partialSetWorkflowActionConfig(action.id, { condition: updatedCondition })
@@ -38,52 +33,42 @@ export function StepWaitUntilConditionConfiguration({
<>
<StepSchemaErrors />
- {waitUntilEventEnabled && (
- <>
- <div className="flex flex-col gap-3">
- <span className="flex gap-1">
- <IconCursor className="text-lg" />
- <span className="text-md font-semibold">Events to wait for</span>
- </span>
- <span className="text-xs text-muted">
- The workflow continues on the matched path when any of these events fire.
- </span>
- <HogFlowEventFilters
- filtersKey={`wait-until-events-${action.id}`}
- filters={eventFilters}
- setFilters={(newFilters) =>
- partialSetWorkflowActionConfig(action.id, {
- events: newFilters ? [{ filters: newFilters }] : undefined,
- })
- }
- typeKey="workflow-wait-until-event"
- buttonCopy="Add event"
- excludeGroupProperties
- />
- </div>
+ <div className="flex flex-col gap-3">
+ <span className="flex gap-1">
+ <IconCursor className="text-lg" />
+ <span className="text-md font-semibold">Events to wait for</span>
+ </span>
+ <span className="text-xs text-muted">
+ The workflow continues on the matched path when any of these events fire.
+ </span>
+ <HogFlowEventFilters
+ filtersKey={`wait-until-events-${action.id}`}
+ filters={eventFilters}
+ setFilters={(newFilters) =>
+ partialSetWorkflowActionConfig(action.id, {
+ events: newFilters ? [{ filters: newFilters }] : undefined,
+ })
+ }
+ typeKey="workflow-wait-until-event"
+ buttonCopy="Add event"
+ excludeGroupProperties
+ />
+ </div>
- <div className="flex items-center gap-4 my-2">
- <div className="flex-1 border-t border-border" />
- <span className="text-xs text-tertiary uppercase tracking-wide">or</span>
- <div className="flex-1 border-t border-border" />
- </div>
- </>
- )}
+ <div className="flex items-center gap-4 my-2">
+ <div className="flex-1 border-t border-border" />
+ <span className="text-xs text-tertiary uppercase tracking-wide">or</span>
+ <div className="flex-1 border-t border-border" />
+ </div>
<div className="flex flex-col gap-3">
- {waitUntilEventEnabled ? (
- <>
- <span className="flex gap-1">
- <IconPerson className="text-lg" />
- <span className="text-md font-semibold">Property conditions</span>
- </span>
- <span className="text-xs text-muted">
- The workflow continues when the person matches these properties.
- </span>
- </>
- ) : (
- <LemonLabel>Conditions to wait for</LemonLabel>
- )}
+ <span className="flex gap-1">
+ <IconPerson className="text-lg" />
+ <span className="text-md font-semibold">Property conditions</span>
+ </span>
+ <span className="text-xs text-muted">
+ The workflow continues when the person matches these properties.
+ </span>
<LemonInput
value={localConditionName || ''}
onChange={handleNameChange}
diff --git a/products/workflows/frontend/Workflows/hogflows/steps/StepWaitUntilTimeWindow.tsx b/products/workflows/frontend/Workflows/hogflows/steps/StepWaitUntilTimeWindow.tsx
index 599196377ebc..aa9325af3bbf 100644
--- a/products/workflows/frontend/Workflows/hogflows/steps/StepWaitUntilTimeWindow.tsx
+++ b/products/workflows/frontend/Workflows/hogflows/steps/StepWaitUntilTimeWindow.tsx
@@ -3,8 +3,6 @@ import { useActions, useValues } from 'kea'
import { LemonDivider, LemonInputSelect, LemonLabel, LemonSelect, LemonSwitch } from '@posthog/lemon-ui'
-import { FEATURE_FLAGS } from 'lib/constants'
-import { featureFlagLogic } from 'lib/logic/featureFlagLogic'
import { timeZoneLabel } from 'lib/utils/timezones'
import { preflightLogic } from 'scenes/PreflightCheck/preflightLogic'
import { teamLogic } from 'scenes/teamLogic'
@@ -98,9 +96,6 @@ export function StepWaitUntilTimeWindowConfiguration({ node }: { node: Node<Wait
)
const { preflight } = useValues(preflightLogic)
const { currentTeam } = useValues(teamLogic)
- const { featureFlags } = useValues(featureFlagLogic)
-
- const showPersonTimezone = !!featureFlags[FEATURE_FLAGS.WORKFLOWS_PERSON_TIMEZONE]
const timezoneOptions = Object.entries(preflight?.available_timezones || {}).map(([tz, offset]) => ({
key: tz,
@@ -172,7 +167,6 @@ export function StepWaitUntilTimeWindowConfiguration({ node }: { node: Node<Wait
onTimezoneChange={handleTimezoneChange}
onUsePersonTimezoneChange={handleUsePersonTimezoneChange}
onFallbackTimezoneChange={handleFallbackTimezoneChange}
- showPersonTimezoneOption={showPersonTimezone}
/>
</div>
</>
@@ -270,7 +264,6 @@ function TimezoneConfiguration({
onTimezoneChange,
onUsePersonTimezoneChange,
onFallbackTimezoneChange,
- showPersonTimezoneOption,
}: {
timezone: string | null
usePersonTimezone?: boolean
@@ -280,22 +273,19 @@ function TimezoneConfiguration({
onTimezoneChange: (timezone: string[]) => void
onUsePersonTimezoneChange: (checked: boolean) => void
onFallbackTimezoneChange: (timezone: string[]) => void
- showPersonTimezoneOption: boolean
}): JSX.Element {
return (
<div className="flex flex-col gap-3">
- {showPersonTimezoneOption && (
- <LemonSwitch
- checked={usePersonTimezone ?? false}
- onChange={onUsePersonTimezoneChange}
- label="Use person's timezone"
- bordered
- tooltip="Requires the GeoIP transformation to be enabled in Data pipelines → Transformations."
- data-attr="use-person-timezone-switch"
- />
- )}
+ <LemonSwitch
+ checked={usePersonTimezone ?? false}
+ onChange={onUsePersonTimezoneChange}
+ label="Use person's timezone"
+ bordered
+ tooltip="Requires the GeoIP transformation to be enabled in Data pipelines → Transformations."
+ data-attr="use-person-timezone-switch"
+ />
- {showPersonTimezoneOption && usePersonTimezone ? (
+ {usePersonTimezone ? (
<div>
<LemonLabel>Fallback timezone</LemonLabel>
<p className="text-xs text-muted mb-2">
diff --git a/products/workflows/frontend/Workflows/hogflows/steps/components/HogFlowFunctionConfiguration.tsx b/products/workflows/frontend/Workflows/hogflows/steps/components/HogFlowFunctionConfiguration.tsx
index b86b8bf3b250..96acf37746d3 100644
--- a/products/workflows/frontend/Workflows/hogflows/steps/components/HogFlowFunctionConfiguration.tsx
+++ b/products/workflows/frontend/Workflows/hogflows/steps/components/HogFlowFunctionConfiguration.tsx
@@ -6,8 +6,6 @@ import { IconCheck } from '@posthog/icons'
import { LemonBanner, LemonButton, Link, Spinner } from '@posthog/lemon-ui'
import { CyclotronJobInputs } from 'lib/components/CyclotronJob/CyclotronJobInputs'
-import { FEATURE_FLAGS } from 'lib/constants'
-import { featureFlagLogic } from 'lib/logic/featureFlagLogic'
import { templateToConfiguration } from 'scenes/hog-functions/configuration/hogFunctionConfigurationLogic'
import { teamLogic } from 'scenes/teamLogic'
import { urls } from 'scenes/urls'
@@ -37,11 +35,9 @@ export function HogFlowFunctionConfiguration({
const { workflow, hogFunctionTemplatesById, hogFunctionTemplatesByIdLoading } = useValues(workflowLogic)
const { currentTeam, currentTeamLoading } = useValues(teamLogic)
const { updateCurrentTeam } = useActions(teamLogic)
- const { featureFlags } = useValues(featureFlagLogic)
const template = hogFunctionTemplatesById[templateId]
const isEmailStep = templateId === 'template-email'
- const engagementEventsAvailable = !!featureFlags[FEATURE_FLAGS.WORKFLOWS_ENGAGEMENT_EVENTS]
const engagementEventsEnabled = !!currentTeam?.workflows_config?.capture_workflows_engagement_events
useEffect(() => {
// oxlint-disable-next-line exhaustive-deps
@@ -140,7 +136,7 @@ export function HogFlowFunctionConfiguration({
sampleGlobalsWithInputs={sampleGlobals}
onInputChange={(key, value) => setInputs({ ...inputs, [key]: value })}
/>
- {isEmailStep && engagementEventsAvailable ? (
+ {isEmailStep ? (
engagementEventsEnabled ? (
<div className="flex items-center gap-1.5 mt-2 text-xs text-muted-alt">
<IconCheck className="text-success text-base" />