procore-oss/blueprinter
72.8
Strong · 6 November 2026
1.5k
lines of production code
Ruby
primary language
4
measurements over time
What this system is
Features
Add Rails generator for creating Blueprints
Users can now generate blueprint files for ActiveRecord models using the Rails generator. The generator creates a blueprint class in the specified directory (defaulting to app/blueprints) and supports options to manually specify fields and associations, auto-detect them from the model, customize the identifier, and control code formatting such as line wrapping and indentation.
lib/generators · high confidence
Configurable DateTime formatting via new formatter
A new DateTimeFormatter has been added to the formatters module, allowing date and time values to be formatted according to a configurable format string or a custom Proc. This change enables users to define how DateTime objects are serialized, with the format falling back to a global configuration if not specified per field, and raising an error for invalid inputs when a format is required.
lib/blueprinter/formatters · high confidence
Removals
Removal of Painted Rabbit version and task files
The version definition file (lib/painted\_rabbit/version.rb) and the rake task stub (lib/tasks/painted\_rabbit\_tasks.rake) for the Painted Rabbit component have been deleted. This removes the hardcoded version string '0.1.0' and the commented-out rake task structure from the library.
_lib/painted\rabbit, lib/tasks · high confidence
Behavioural changes
Blueprinter v1.3.0: New internal architecture and reflection API
Blueprinter has been updated to version 1.3.0, introducing a complete internal refactor of the serialization engine. The library now uses a dedicated \Association\ class and a thread-safe, cached \ViewCollection\ to manage field and transformer definitions, significantly reducing object allocations during rendering. A new public \Reflection\ API allows users to introspect blueprints, retrieving defined fields, associations, and their configurations. The rendering pipeline now supports extensions via a \pre\_render\ hook, allows passing dynamic options to nested associations, and enforces stricter validation for invalid blueprints and missing views.
lib/blueprinter · high confidence
Library renamed from PaintedRabbit to Blueprinter
The library has been renamed from PaintedRabbit to Blueprinter. The previous entry point \lib/painted\_rabbit.rb\ has been removed and replaced with \lib/blueprinter.rb\, which now serves as the main module. This change includes a new configuration system allowing users to set global options via \Blueprinter.configure\ and \Blueprinter.configuration\, and utilizes Ruby's \autoload\ mechanism for loading core components like \Base\, \Configuration\, and \Extension\.
lib · high confidence
Project rebrand to Blueprinter and test suite migration to RSpec
The library has been renamed from PaintedRabbit to Blueprinter, including updates to the gem title, documentation, and configuration files. The test framework has been migrated from Minitest to RSpec, evidenced by the new .rspec configuration, Rakefile tasks, and the relocation of the dummy application from test/dummy to spec/dummy. Additionally, RuboCop linting has been introduced with a specific configuration targeting Ruby 3.1.
(repo-wide) · high confidence
Refactor extraction logic into specialized extractor classes
The internal extraction mechanism has been restructured to use dedicated extractor classes (AutoExtractor, BlockExtractor, HashExtractor, PublicSendExtractor, and AssociationExtractor) instead of monolithic logic. This change improves how fields are resolved: HashExtractor handles hash access, PublicSendExtractor handles method calls, and BlockExtractor now correctly distinguishes between standard blocks and Symbol\#to\_proc syntax to prevent argument-passing errors. Additionally, AssociationExtractor now supports dynamic blueprint resolution via procs and allows setting default values for associations when the associated object is null.
lib/blueprinter/extractors · high confidence
Replaced test runner with IRB-based console
The bin/test script has been removed and replaced by a new bin/console entry point. This change shifts the primary interactive development tool from a Rails plugin test runner to a standard IRB session, providing a more flexible environment for debugging and experimentation.
bin · high confidence
Test coverage
1 commit adding/updating tests in spec; Added benchmark tests for Blueprinter performance; Added factory definitions for User and Vehicle models; Added integration tests for base blueprint rendering; Added shared integration tests for base rendering logic; Added test infrastructure and helpers for Blueprinter; Added tests for the Blueprinter generator; Added unit tests for core Blueprinter components; Removed legacy test suite and dummy Rails application scaffolding.
Dependencies
Blueprinter gem restructured with explicit dependency declarations and Ruby 3.1+ requirement
The Blueprinter gem (formerly Painted Rabbit) has been restructured to explicitly declare its dependencies in the Gemfile rather than relying solely on the gemspec. This change enforces a minimum Ruby version of 3.1, dropping support for older versions. The gem now officially supports OJ (\~\> 3.13) and Yajl-Ruby (\~\> 1.4) as serialization backends, while development dependencies have been updated to include RSpec 3.12, RSpec-Rails 8.0, FactoryBot 6.2, and RuboCop 1.44. The legacy Gemfile.lock and the old painted\_rabbit.gemspec have been removed as part of this cleanup.
(dependencies) · high confidence
Written by cca.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.
How this codebase got here
Score
- CAI 64 → 73 (+8.7)
- Rubric changed (rubric-2026.10.5 → rubric-2026.11.2) — scores are not directly comparable.
Lenses
- Code Health 76 → 76 (+0.0)
- Architecture 69 → 69 (+0.0)
- Maturity 53 → 74 (+21.3)
- Readiness 80 → 80 (+0.0)
- Security 87 → 82 (-5.2)
- Performance 80 → 80 (+0.0)
Resolved (4)
- Inconsistent naming and pluralization for exclusion operations. Base uses exclude (singular) and excludes (plural), while View uses exclude_field and exclude_fields. The verb form changes between the base class and the view class, and the pluralization strategy is inconsistent (exclude vs exclude_field).
- Inconsistent pluralization strategy for single vs multiple arguments. While providing both singular and plural methods is a common Ruby pattern (e.g., include vs includes), having both include_view and include_views on both Base and View creates API surface bloat. It is often cleaner to accept a single argument that can be a string or an array, rather than requiring two distinct method names.
- Off-boarding risk: anonymized user #1
- Redundant naming for configuration access. 'configuration' implies retrieval, while 'configure' often implies setting or a builder pattern. Without bodies, it is unclear if these are distinct (getter vs setter/builder) or duplicates. In many Ruby libraries, configure is the standard method for accessing/modifying a singleton configuration object.
New (1)
- Off-boarding risk: anonymized user #1
Changes since last survey
- 3 commits — 2 feature/other, 1 fixes
By area
- (root) — 2 commits
- spec/benchmarks — 1 commit
Notable commits
- fix: [Memoization Fix] fix: memoize field :if/:unless conditions (#608)
- change: docs: add codebase docs and agent guidance (#612)
- change: perf: add a render benchmark suite and run comparison (#622)
Written by cca.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.
Survey your own repository
procore-oss/blueprinter was measured the same way every project in this corpus was: the same rubric, at a pinned commit, with the result published in full. Point a surveyor at a repository you know and see whether you agree with it.
About this page
- The score is its most recent published measurement, taken on 6 November 2026 at a pinned commit. It is not a live figure and does not change until the project is measured again.
- Measured at commit 6029f0758d08d0f521309ce7c79dc44d5eea0201 — the exact code this score is about.
- Scored under rubric-2026.11.2 — the same rubric and the same method as every other entry in this index.
- Measured by Canine Code Analyzer (cca.canine.dev) using cca measure-2026.11.2+preprod-5c4e66d9318b.