faker-ruby/faker
75.7
Strong · 26 September 2026
20.6k
lines of production code
Ruby
primary language
4
measurements over time
What this system is
This system is the Faker library, a Ruby gem designed to generate realistic fake data for testing and development purposes. It provides a modular namespace structure with specialized generators for diverse domains including blockchain addresses, fictional book and movie franchises, video games, anime, sports statistics, and travel locations. The library supports multiple locales and includes utilities for unique value generation, thread safety, and performance benchmarking to ensure reliable data synthesis.
How it got here
2007–2015 — Faker 3.8 migration and modernization
11 changes.
The project underwent a major upgrade to Faker 3.8.0, restructuring the codebase into a modular namespace system and expanding data generation capabilities for internet, music, and other domains. This period also focused on modernizing the infrastructure by removing legacy build tools and website assets, updating development dependencies, and ensuring compatibility with newer Ruby versions through script and extension refactoring.
2018 — Expansion of domain-specific data generators
13 changes.
This period focused on significantly expanding the Faker library's coverage of niche domains, introducing new generators for video games, movies, anime, music, TV shows, creatures, and blockchain addresses. The work also included restructuring the default generator architecture for better maintainability and adding comprehensive test coverage for all new and reorganized modules.
2019–2021 — Expansion of domain-specific generators
12 changes.
This period focused on significantly expanding the library's coverage by adding new generators for diverse domains including books, sports, games, blockchain, and religion. The work involved implementing specific data sources for franchises like Dune and World of Warcraft, as well as regional data for Australia, while ensuring comprehensive test coverage for all new and existing modules.
2022–2026 — Travel module and performance tooling
5 changes.
This period focused on expanding the Faker library with new travel-related data generators for airports and train stations, complete with comprehensive test coverage. Additionally, the project introduced custom pre-push hooks for code quality enforcement and benchmark scripts to monitor generator performance and library load times.
Features
Add Bible data generation methods
Users can now generate random Bible-related content using the new Faker::Religion::Bible class, which provides methods to fetch random Bible characters, locations, and quotes.
lib/faker/religion · high confidence
Add Faker::Internet::HTTP for generating HTTP status codes
Users can now generate realistic HTTP status codes using the new \Faker::Internet::HTTP\ module. This addition provides a \status\_code\ method that returns random integers from standard HTTP categories (informational, successful, redirect, client error, server error) and allows filtering by specific groups via an optional keyword argument, facilitating more accurate network-related test data generation.
lib · high confidence
Add Faker::Locations::Australia for Australian location data
Users can now generate Australian-specific location data using the new Faker::Locations::Australia class. This class provides methods to produce random Australian locations (e.g., cities), Australian animals, and Australian states or territories, pulling data from the corresponding locale files.
lib/faker/locations · high confidence
Add fakerbot CLI entry point
A new executable script named 'faker' has been added to the bin directory. This Ruby script sets up the load path to include the local lib directory, serving as the entry point for the fakerbot tool.
bin · high confidence
Add pre-push hook example
A sample pre-push hook script (pre-push.sample) has been added to the custom-hooks directory. This script demonstrates how to automatically run Rubocop and tests via 'bundle exec rake' before a push is accepted, ensuring code quality checks pass before changes are shared.
custom-hooks · high confidence
Added airport and train station generators to the Travel module
Users can now generate random travel-related data through two new classes in the Faker::Travel namespace. The new Airport class provides methods to generate airport names and IATA codes, filtered by region (United States or European Union) and size (large, medium, or small). Additionally, the TrainStation class allows generation of train station names, supporting optional filtering by region (Germany, Spain, United Kingdom, United States) and type (metro or railway), with sensible defaults when arguments are omitted.
lib/faker/travel · high confidence
Added benchmark scripts for generator performance and library load time
New benchmark scripts have been added to measure the performance of Faker's data generation methods and the time required to load the library. The \benchmark/generators.rb\ script iterates through available Faker generators to report their execution speed using \benchmark/ips\, while \benchmark/require.rb\ measures the milliseconds taken to require the 'faker' gem. These tools allow users to track performance regressions or improvements in generation speed and startup time.
benchmark · high confidence
Expanded TV show data generators
The Faker library now includes dedicated generators for a wider range of TV shows, adding new classes such as Aqua Teen Hunger Force, Archer, Big Bang Theory, BoJack Horseman, Brooklyn Nine-Nine, Buffy the Vampire Slayer, Community, Final Space, Futurama, How I Met Your Mother, New Girl, Parks and Recreation, RuPaul's Drag Race, Suits, Supernatural, The Expanse, The Fresh Prince of Bel-Air, The IT Crowd, The Office, The Thick of It, and The Venture Bros. These additions provide access to show-specific content including characters, quotes, locations, episodes, and other unique attributes, allowing users to generate more diverse and specific fictional data.
_lib/faker/tv\shows · high confidence
Expanded game-specific data generators in Faker::Games
The \lib/faker/games\ directory now includes dedicated generators for a wide range of video games and tabletop RPGs, allowing users to produce context-specific fictional data. New and updated classes include \ClashOfClans\ (troops, ranks, buildings), \Control\ (characters, locations, Object of Power, quotes), \DnD\ (alignments, backgrounds, classes, monsters, weapons), \Dota\ (buildings, heroes, items, teams), \ElderScrolls\ (races, cities, creatures, dragons, weapons), \Fallout\ (characters, factions, locations), \FinalFantasyXIV\ (characters, jobs, races, data centers, zones), \HalfLife\ (characters, enemies, locations), \Heroes\ (names, specialties, classes, artifacts), \HeroesOfTheStorm\ (battlegrounds, classes, heroes, quotes), \LeagueOfLegends\ (champions, locations, quotes, summoner spells, masteries, ranks), \Minecraft\ (achievements, biomes, blocks, enchantments, game modes, items, mobs, status effects), \Myst\ (games, creatures, ages, characters, quotes), \Overwatch\ (heroes, locations, quotes), \Pokemon\ (names, locations, moves), \SonicTheHedgehog\ (characters, zones, games), \StreetFighter\ (characters, stages, quotes, moves), \SuperMario\ (characters, games, locations), \SuperSmashBros\ (fighters, stages), \Tarkov\ (locations, traders, items, weapons, bosses, factions, and specific trader quests), \Touhou\ (games, characters, locations, spell cards, songs), \WarhammerFantasy\ (heroes, quotes, locations, factions, creatures), \Witcher\ (characters, witchers, schools, locations, quotes, monsters, signs, potions, books), \WorldOfWarcraft\ (heroes, classes, races, quotes), and \Zelda\ (games, characters, locations, items).
lib/faker/games · high confidence
Expanded music generators for specific artists and genres
The Faker::Music module now includes dedicated generators for a wider range of musical acts and styles. Users can generate data for Hip Hop artists, groups, and subgenres; Bossa Nova artists and songs; and specific rock bands including The Grateful Dead, Pearl Jam, Phish, Prince, Rush, Smashing Pumpkins, and Umphrey's McGee, covering details such as musicians, albums, songs, and lyrics. Additionally, the Opera generator has been augmented to include titles by composers like Verdi, Rossini, Mozart, and Wagner, with options to filter by language or composer.
lib/faker/music · high confidence
Initial project scaffolding and configuration
The repository has been initialized with essential configuration files, including \.gitignore\ to exclude build artifacts and IDE metadata, \.rubocop.yml\ to enforce code style with a target Ruby version of 3.2, and \.yardopts\ for documentation generation. Documentation and contribution guidelines are now provided via \README.md\, \CHANGELOG.md\, \GENERATORS.md\, \CONTRIBUTING.md\, and \MAINTAINING.md\, while legacy files like \History.txt\, \Manifest.txt\, and \setup.rb\ have been removed.
(repo-wide) · high confidence
New Faker generators for movies and fantasy franchises
This update adds new data generators for several movie franchises and fantasy settings. Users can now generate content from Avatar, Back to the Future, The Departed, Ghostbusters, Hackers, Harry Potter, The Hitchhiker's Guide to the Galaxy, The Hobbit, How to Train Your Dragon, The Big Lebowski, The Princess Bride, Star Wars, The Room, Tron, and V for Vendetta. Additionally, a new Tolkien generator is available under the Fantasy namespace. These new classes provide methods to produce characters, quotes, locations, and other specific data points relevant to each franchise.
lib/faker/movies · high confidence
New Faker modules for Dune, Culture Series, and The Kingkiller Chronicle
Users can now generate fictional data from three new book franchises. The new \Faker::Books::Dune\ module provides characters, titles, planets, cities, quotes, and sayings. \Faker::Books::CultureSeries\ adds books, Civs, planets, and various ship-related data from Iain M. Banks' universe. Finally, \Faker::Books::TheKingkillerChronicle\ introduces books, characters, creatures, and locations from Patrick Rothfuss' series.
lib/faker/books · high confidence
New Faker::Creature namespace with animal, bird, cat, dog, and horse generators
Users can now generate random creature-related data through the new Faker::Creature namespace. This release adds specific generators for Animals (names), Birds (including common names, taxonomic orders, anatomy, colors, and adjectives), Cats (names, breeds, registries), Dogs (names, breeds, sounds, memes, age, gender, coat length, size), and Horses (names, breeds). These new methods allow for more specialized and realistic fake data generation in applications dealing with pet or wildlife themes.
lib/faker/creature · high confidence
New Faker::Quotes::Chiquito and Faker::Quotes::Rajnikanth generators
Users can now generate quotes from the Mexican comedian Chiquito (expressions, terms, jokes, sentences) and the Indian actor Rajnikanth (jokes) via the new Faker::Quotes::Chiquito and Faker::Quotes::Rajnikanth classes. This adds two new sources of character-specific quotes to the library, complementing the existing Faker::Quotes::Shakespeare generator.
lib/faker/quotes · high confidence
New Japanese media faker modules for Conan, Cowboy Bebop, Doraemon, Dragon Ball, Fullmetal Alchemist, Kamen Rider, Naruto, One Piece, Studio Ghibli, and Sword Art Online
This change adds a comprehensive set of new faker modules under the \Faker::JapaneseMedia\ namespace, allowing users to generate fictional data from popular anime and manga series. Specifically, it introduces \Conan\ (characters, gadgets, vehicles), \Cowboy Bebop\ (characters, episodes, songs, quotes), \Doraemon\ (characters, gadgets, locations), \Dragon Ball\ (characters, races, planets), \FullmetalAlchemistBrotherhood\ (characters, cities, countries), \KamenRider\ (riders, users, series, collectible devices, transformation devices with era filtering), \Naruto\ (characters, villages, eyes, demons), \OnePiece\ (characters, seas, islands, locations, quotes, akuma no mi), \StudioGhibli\ (characters, quotes, movies), and \SwordArtOnline\ (real names, game names, locations, items). These modules provide structured access to series-specific attributes via YAML-backed data files.
_lib/faker/japanese\media · high confidence
New blockchain address generators for Aeternity, Bitcoin, Ethereum, and Tezos
Users can now generate realistic fake data for four major blockchain networks. The new Faker::Blockchain::Aeternity class provides methods to create wallet addresses, transactions, contracts, and oracles. Faker::Blockchain::Bitcoin adds support for generating mainnet and testnet wallet addresses. Faker::Blockchain::Ethereum introduces a method for producing random Ethereum wallet addresses. Finally, Faker::Blockchain::Tezos expands the library with generators for account addresses, contracts, operations, blocks, signatures, and public/secret keys.
lib/faker/blockchain · high confidence
New helper modules for character processing, Base58 encoding, and generator infrastructure
This change introduces several new helper modules in lib/helpers. Char now supports transliterating Cyrillic text (Russian and Ukrainian) to ASCII for URL-safe strings and fixes umlaut handling. A new Base58 helper provides encoding functionality. The UniqueGenerator has been refactored to use thread-local storage for tracking unique values, improving thread safety and allowing explicit exclusion of values. A new Deprecator module enables safe renaming of generators with deprecation warnings. Additionally, a new PositionalGenerator class provides a high-level DSL for generating structured values like IDs or postal codes with dependencies between components.
lib/helpers · high confidence
New sports data generators for Basketball, Chess, Football, Mountaineering, and Volleyball
Users can now generate realistic sports-related data through new Faker::Sports sub-namespaces. The Basketball generator provides teams, players, coaches, and positions; Football adds teams, players, coaches, competitions, and positions; Volleyball includes teams, players, coaches, positions, and formations; Chess introduces players, federations, tournaments, ratings, openings, and titles; and Mountaineering adds mountaineer names. These additions expand the library's coverage of sports domains for testing and development.
lib/faker/sports · high confidence
Removals
Removal of legacy Hoe-based gem build configuration
The project has removed its legacy gem build infrastructure, specifically deleting \config/hoe.rb\ and \config/requirements.rb\. This eliminates the dependency on the \hoe\ and \newgem\ gems and removes the custom Rake task generation and RubyForge publishing logic that was previously handled by these configuration files.
config · high confidence
Removed legacy website assets
The website's legacy HTML pages (index.html, index.txt), styling (screen.css), and JavaScript (rounded\_corners\_lite.inc.js) have been removed. This eliminates the old Ruby-based site structure and its associated visual components, such as the rounded-corner effects and specific theme styling.
website · high confidence
Architecture
Faker default generators restructured into individual files
The \lib/faker/default\ directory has been reorganized so that each generator (such as Address, Bank, Barcode, Cannabis, and ChileRut) is now defined in its own dedicated file rather than being bundled together. This change improves code maintainability and allows users to load or reference specific generators more cleanly without pulling in the entire default suite.
lib/faker/default · high confidence
Behavioural changes
Faker library upgraded to version 3.8.0 with modularized namespace structure
The Faker library has been updated to version 3.8.0, introducing a significant structural change by replacing the previous flat file organization with a modular namespace system. This update adds dedicated loader files for new and existing categories including Blockchain, Books, Creature, Fantasy, Games, Japanese Media, Locations, Movies, Music, Quotes, Religion, Sports, Travel, and TV Shows, while removing the legacy standalone files for Address, Company, Name, and PhoneNumber. The Internet class has been substantially expanded with new capabilities such as private and link-local IPv4 address generation, customizable email local parts with separators, and a more robust password generator supporting minimum/maximum lengths, mixed case, and special characters. Additionally, the Music namespace now provides generators for musical keys, chords, instruments, bands, albums, and genres.
lib/faker · high confidence
Rake task suite restructured with new formatting and test defaults
The project's rake task suite has been reorganized to improve developer workflow and code consistency. A new \reformat\_locales\ task has been added to automatically reformat all locale YAML files into a standardized indentation format, and a new \test\ task is now the default rake target, simplifying the command to run the test suite. Conversely, legacy tasks for website generation, deployment, and environment detection have been removed as they are no longer part of the project's operational scope.
tasks · high confidence
Removal of Array\#at\_rand extension
The custom \Array\#at\_rand\ method, previously defined in \lib/extensions/array.rb\, has been removed. This method previously allowed selecting a random element from an array using \at\ and \rand\. Its removal aligns with the project's move to support newer Ruby versions (2.3+) and avoid deprecation warnings by relying on standard library methods like \Array\#sample\ or \Array\#choice\ instead of custom extensions.
lib/extensions · high confidence
Script modernization and Ruby 2.3 compatibility fixes
The scripts in the \script/\ directory have been updated to comply with modern Ruby standards and improve compatibility with Ruby 2.3. This includes adding \frozen\_string\_literal\ directives, replacing deprecated \Fixnum\ with \Integer\, and updating syntax to use \%i\ arrays and \cover?\ instead of \include?\. Additionally, file reading operations now use \File.read\ instead of \File.open\ blocks, and string interpolation is preferred over concatenation for requiring library paths.
script · high confidence
Test coverage
Added test coverage for new and existing game generators; Added test coverage for new sports generators; Added tests for Faker::Fantasy::Tolkien; Added tests for Faker::Locations::Australia; Added tests for Faker::Quotes sub-namespaces; Added tests for Faker::TvShows generators; Added tests for JapaneseMedia faker modules; Added tests for Travel airport and train station generators; Added tests for blockchain faker modules; Added tests for new and existing Faker::Books generators; Added tests for new and reorganized Music module generators; Added unit tests for creature sub-providers; Expanded test coverage for Faker library locales and features; Expanded test coverage for default Faker generators.
Dependencies
Update development dependencies and lockfile
The project's development environment has been updated with newer versions of key tooling and testing libraries. RuboCop is upgraded to 1.90.0, and its plugins (rubocop-minitest to 0.40.0, rubocop-rake to 0.7.1) are updated accordingly. Testing tools have also been bumped: Minitest to 6.0.6, test-unit to 3.7.8, and timecop to 0.9.11. Additional dependencies like pry (0.16.0), yard (0.9.45), and rdoc (8.0.0) are updated, and the Gemfile.lock is regenerated to reflect these changes.
(dependencies) · high confidence
Written by watchdog.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.
How this codebase got here
This is the PUBLIC form of this artifact. Findings are listed in full, but the details of SECURITY findings — which rule fired, in which file, on which line, and how to fix it — are deliberately withheld, and any secret-scanner results are excluded entirely. Where detail is absent here it was REMOVED FOR PUBLICATION; it is not missing from the analysis. The complete artifact is available from the repository owner.
Score
- CAI 53 → 76 (+22.2)
- Rubric changed (rubric-2026.08.15 → rubric-2026.09.15) — scores are not directly comparable.
Lenses
- Code Health 100 → 99 (-0.1)
- Architecture 96 → 100 (+4.3)
- Maturity 61 → 59 (-1.7)
- Readiness 30 → 90 (+59.5)
- Security 80 → 87 (+7.2)
Resolved (8)
- Coverage not measured — test suite did not build
- Dimension evaluation failed
- Duplicated block (5 lines × 2) (lib/helpers/char.rb)
- Duplicated block (6 lines × 2) (lib/helpers/char.rb)
- No exposed public API
- No tests found
- Test reliability not included
- The 'Usage' example shows only a single line (Faker::Name.name #=> ...) before being cut by the scanner. The full Usage block (and its corresponding Faker::<generator>.unique.exclude(...) section) is present in the outline, so it cannot be flagged as missing. (README.md)
New (24)
- Ambiguous naming for IBAN-related methods. iban generates an IBAN, while iban_country_code is unclear: does it return the country code part of an IBAN, or does it generate a random country code for IBAN generation? The naming convention does not clearly distinguish between 'generating an IBAN' and 'extracting/generating a country code'.
- Concentrated knowledge decay
- Duplicate credit card functionality across Faker.Finance and Faker.Business. Faker.Finance provides a comprehensive credit_card method, while Faker.Business provides fragmented methods (credit_card_number, credit_card_type, etc.). This splits the domain logic unnecessarily.
- Duplicate functionality across namespaces. Faker.Code and Faker.Barcode both expose methods to generate ISBNs and EANs. This forces users to choose between two identical capabilities based on arbitrary namespace grouping rather than functional difference.
- Duplicated block (105 lines × 2) (lib/faker/default/compass.rb)
- Duplicated block (105 lines × 8) (lib/faker/default/cannabis.rb)
- Duplicated block (118 lines × 4) (lib/faker/default/cannabis.rb)
- Duplicated block (118 lines × 4) (lib/faker/default/food.rb)
- Duplicated block (16 lines × 2) (lib/faker/movies/star_wars.rb)
- Duplicated block (5 lines × 2) (lib/helpers/char.rb)
- Duplicated block (66 lines × 2) (lib/faker/books/dune.rb)
- Duplicated block (92 lines × 12) (lib/faker/default/cannabis.rb)
- Further sole-owners (lower concentration)
- Inconsistent naming for code lookup operations. country_by_code and country_name_to_code are explicit lookup methods, while country_code and country_code_long are ambiguous (do they return a random code, or look up a specific one?). Additionally, country_code likely duplicates the intent of country_code_long or country_by_code depending on implementation, creating confusion about which method to use for a specific code format.
- Medium: security finding (details withheld)
- Most significant orphaned file (lib/faker/default/company.rb)
- Most significant orphaned file (lib/faker/internet.rb)
- Off-boarding risk: anonymized user #1
- Outdated: rubocop
- Outdated: simplecov
- …and 4 more
Changes since last survey
- 4 commits — 3 feature/other, 1 fixes
By area
- .github/workflows — 2 commits
- (root) — 1 commit
- test/faker — 1 commit
Notable commits
- fix: Fix: test_faker_bird unit test apostrophe (#3312)
- change: Bump actions/checkout from 7.0.0 to 7.0.1 (#3310)
- change: Bump ruby/setup-ruby from 1.316.0 to 1.321.0 (#3315)
- change: deps: update dependencies (#3321)
Written by watchdog.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.
Survey your own repository
faker-ruby/faker 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 26 September 2026 at a pinned commit. It is not a live figure and does not change until the project is measured again.
- Measured at commit c8a881b9f00fd7b591dcfa5506a0179e6fd52036 — the exact code this score is about.
- Scored under rubric-2026.09.15 — the same rubric and the same method as every other entry in this index.
- Measured by watchdog.canine.dev using codehealth-analyzer preprod-d0929f7ac71f.