PostHog / PostHog/posthog-ruby

Add feature flag evaluation context parity

Open
#188 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement feature/flags
Dominant language
Ruby
Stars
36
Forks
34
Avg merge
1d 13h
Merged PRs (30d)
18

Description

Summary

Add missing feature flag evaluation context parity to the Ruby SDK.

Specs

  • sdk-specs/openspec/specs/get-feature-flag/spec.md
  • sdk-specs/openspec/specs/is-feature-enabled/spec.md
  • sdk-specs/openspec/specs/local-feature-flag-evaluator/spec.md

Current evidence

The SDK audit found that flag APIs lack device_id; legacy/bulk APIs also lack some newer context options.

Expected behavior

  • Allow passing device_id through relevant feature flag evaluation APIs.
  • Use device_id in local/remote evaluation where required by the flag definition/evaluation context.
  • Bring legacy and bulk flag APIs closer to the canonical server-side context options where applicable.
  • Add tests for remote request body propagation and local evaluation bucketing/context behavior.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Read sdk-specs/openspec/specs/get-feature-flag/spec.md, is-feature-enabled/spec.md, and local-feature-flag-evaluator/spec.md first, then trace the corresponding Ruby SDK APIs. Done means device_id and applicable context options reach remote requests and local evaluation, with tests covering request-body propagation, bucketing, and context behavior.

Written by the indexing model from the issue text.

Assessment

Tech stack
ruby
Domain
api, testing
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
48/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.