# adzap/validates_timeliness

Date and time validation plugin for ActiveModel and Rails.  Supports multiple ORMs and allows custom date/time formats.

Repository: https://github.com/adzap/validates_timeliness
Canonical: https://ross.abutalabs.com/products/validates_timeliness
Language: Ruby
License: MIT
License Family: permissive
Topics: validation, rails, activerecord, activemodel
Last push: 2025-12-06T07:49:02+00:00

## Health v2 (maintenance only)
Score: 57/100 (v2, computed 2026-09-03T02:20:16.233290+00:00)
- activity 55, release rhythm 35, longevity 100
- inputs: {"age_days": 6613, "days_push": 270, "days_rel": null, "gap_med": null, "n_releases_24m": 0}
- flags: no_releases
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 1616, forks 233 (observed 2026-08-28T04:05:11.881802+00:00)

## What it is
A Ruby gem providing complete date, time, and datetime validation for Rails and ActiveModel, supporting multiple ORMs and custom date/time formats via the timeliness parser. It handles timezones, type casting, I18n error messages, and fixes Rails date/time select issues.

## Use cases
- validate date of birth is at least 18 years ago in a Rails model
- validate a datetime field falls between business hours
- restrict a booking date to today or later
- validate a time attribute is before another attribute
- add custom date/time format parsing to Rails validations
- validate dates and times with I18n error messages

## When to choose
- you need thorough date/time/datetime validation beyond Rails' built-in validates_inclusion_of hacks
- you need before/after/between restrictions with dynamic values like lambdas or method symbols
- you need timezone-aware type casting of validated values
- you use ActiveRecord, Mongoid, or other ORMs with ActiveModel

## When to avoid
- you only need simple presence validation on date fields
- you are not using Rails or ActiveModel
- you need JavaScript or client-side date validation instead of server-side

## Facets
- artifact type: library
- maturity: active
- function: form-handling, date-time, orm, middleware
- domain: web-development, backend, developer-tools
- platform: ruby
- tags: activerecord, activemodel, date-validation, time-validation, i18n, timezone-handling, rails

## Member repositories
- adzap/validates_timeliness (main) score 57

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:05:11.881802+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-30T03:49:59.701764+00:00, confidence not recorded.
  - readme: https://github.com/adzap/validates_timeliness (fetched 2026-08-28T04:05:11.881802+00:00, sha 7b72c2467a37)
- Data as of 2026-08-30T08:39:29.467469+00:00.
