Flipper 1.4.0

Dearest feature flagger,

I come today bearing a big one. 1.4.0 is here and it's got some real goodies. Let's get into it.

Time-Based Expressions

Let's lead with the fire on this one. You can now schedule features to turn on or off at specific times using expressions. No cron jobs. No custom code. Just Flipper:

# Enable between two dates
Flipper.enable :holiday_sale, Flipper.all(
  Flipper.now.gte(Flipper.time(start_time)),
  Flipper.now.lt(Flipper.time(end_time))
)

# Expire a feature after a deadline
Flipper.enable :beta_preview, 
  Flipper.now.lt(Flipper.time(deadline.iso8601))

Works with Unix timestamps and ISO8601 strings. Everything normalizes to UTC so you don't have to think about it.

Feature Dependencies

Feature flags can now depend on other feature flags. I'm really excited about this one. It unlocks migration patterns and coordinated rollouts that used to require orchestration code outside of Flipper:

# Only enable new checkout after old checkout is disabled
Flipper.enable :new_checkout,
  Flipper.feature_disabled(:old_checkout)

# Advanced search requires the search beta
Flipper.enable :advanced_search,
  Flipper.feature_enabled(:search_beta)

Circular dependencies are detected and handled gracefully (they evaluate to false), so you won't accidentally infinite loop yourself into oblivion.

Migrate to Cloud

This has been on my list for a while. You can now push your entire local feature set to Flipper Cloud without manually recreating anything. One command and you're done:

flipper cloud migrate

That opens the migration URL in your browser. If you've already got a Cloud environment, you can push directly:

flipper cloud push

There's also a new card on the settings page in the UI showing how many features are ready to migrate. Payloads are gzip compressed, so even if you've got hundreds of features it moves quick.

When you hit the button, we stash your features for you while you sign up. Once you're done confirming your email, they are all there, right in Cloud.

Smarter Syncing

A bunch of work went into making Cloud sync more resilient. This stuff isn't glamorous but it matters:

  • Always poll as fallback — even with webhooks configured, Flipper now polls at a longer interval as a safety net. Webhooks
    can be missed. Polling ensures you're never out of date.
  • ETag support — conditional requests on get_all mean 304 Not Modified responses when nothing changed. Less bandwidth, less
    server load.
  • Server-controlled polling — Cloud can now send headers to throttle or shut down misbehaving clients without a code
    deploy.
  • Sync bypasses ActorLimit — if Cloud has more actors than your local limit, sync no longer fails. Limits still apply for your changes. This one was giving some folks real headaches (fixes #951).

Adapter Stack Debugging

Ever stare at your adapter config wondering what's actually wrapping what? Now you can see:

Flipper.adapter_stack
# => "memoizable -> failover(primary: redis, secondary: memory)"

Simple but surprisingly useful when you're debugging why something isn't behaving right.

Serialization Fix

If you were using ActiveSupportCacheStore with a database adapter, you may have hit TypeError: can't dump Proc when caching get_all results. The database adapters were using Hash.new { default } which includes an un-serializable Proc. Fixed across ActiveRecord, Sequel, and Mongo.

The Rest

  • Dalli meta protocol — flipper-dalli now uses Dalli's meta protocol instead of the deprecated binary protocol. No more deprecation warnings.
  • UI sanitization — feature descriptions with <a> tags are now sanitized in the list view. Prevents broken nested links and potential XSS.
  • Disable confirmation — fixed the confirmation dialog trigger for the disable button.
  • Automated releases — this is the first release published through GitHub Actions with RubyGems trusted publishing. No more
    manual OTP prompts. All 12 gems built and published atomically. More secure, less me fumbling around.

Upgrade

bundle update flipper

Everything is backward compatible. I hope you find these useful. More to come.

Sincerely,
Nunes