CodeVetter · Repo Unpack · Feature catalog
rails/rails
User-facing surface area is the rails CLI, the generators that stamp a new app, the Rack endpoints mounted by the framework itself, and the adapter-backed subsystems for jobs, cable, storage, mail, and passwords. Generated apps load framework defaults for the version they were created with and, unless skipped, depend on Solid Cache, Solid Queue, Solid Cable, Thruster, and Kamal. Guides and bug-report templates are part of the product, not side docs.
- Command classes under railties/lib/rails/commands include about, application, boot, console, credentials, dbconsole, destroy, dev, devcontainer, encrypted, generate, help, initializers, middleware, new, notes, plugin, query, rake, restart, routes, runner, secret, server, stats, test, unused_routes, and version.
- ServerCommand#perform requires APP_PATH, chdirs to Rails.application.root, and starts Rails::Server. Defaults are port 3000, pid tmp/pids/server.pid, config.ru, and recommended Rack handler puma; supported handler names include cgi, webrick, scgi, thin, puma, unicorn, falcon, fastcgi, and lsws. Host defaults to localhost in development and 0.0.0.0 otherwise.
- The app generator template Gemfile.tt includes solid_cache, solid_queue, and solid_cable, adds thruster unless skip_thruster, and adds kamal unless skip_kamal. The root Gemfile mirrors those gems for framework tests, with kamal >= 2.1.0 and thruster require: false.
- Generated config/application.rb calls config.load_defaults with the generator's config_target_version, or Rails::VERSION::STRING.to_f for dummy apps. A new_framework_defaults_8_2.rb.tt initializer tells upgraders to uncomment flags and then set load_defaults to 8.2.
- CredentialsCommand implements edit, show, diff, and fetch. edit opens the decrypted YAML in $VISUAL or $EDITOR, writing config/credentials/<env>.yml.enc and a sibling .key when an environment is specified. fetch walks a dotted YAML path.
- RunnerCommand#perform boots the app and either evals stdin, Kernel.loads a .rb file, or evals the argument string in TOPLEVEL_BINDING, optionally inside the Rails executor.
- Rails::HealthController#show renders HTML or JSON status up with 200, and rescue_from(Exception) renders status down with 500. The controller comment states the endpoint does not check the database or Redis and that new apps route it at /up via rails/health#show.
- In development, Finisher#add_internal_routes prepends /rails/info/properties, /rails/info/routes, /rails/info/notes, /rails/info, and a Chrome DevTools well-known path, and appends GET / to rails/welcome#index. WelcomeController skips forgery protection and renders without a layout.
- Action Mailbox draws unauthenticated-looking ingress routes under /rails/action_mailbox for Postmark, Relay, Sendgrid, Mandrill (HEAD health check plus POST), and Mailgun (mime). A conductor UI under rails/conductor/action_mailbox exposes inbound email index, create, reroute, and incinerate.
- Active Storage routes, under ActiveStorage.routes_prefix, serve blob redirect and proxy, representation redirect and proxy, disk GET and PUT, and POST /direct_uploads when draw_direct_upload_route is set. Signed ids are the public identifier.
- ActionCable.server memoizes ActionCable::Server::Base. The internal protocol table uses message types welcome, disconnect, ping, confirm_subscription, and reject_subscription, default mount path /cable, and protocols actioncable-v1-json and actioncable-unsupported. Redis and PostgreSQL subscription adapters are not eager-loaded.
- Active Job's default queue adapter is :async. QueueAdapters.lookup constantizes the camelized name plus Adapter. Built-ins are async, inline, and test; optional backends are backburner, delayed_job, queue_classic, resque, and sneakers. The file states new adapter pull requests are not accepted.
- ActiveRecord::Encryption::EncryptableRecord#encrypts declares encrypted attributes with deterministic, downcase, ignore_case, previous schemes, and compression options. ActiveModel::SecurePassword.register_algorithm ships :bcrypt and :argon2; has_secure_password defaults to BCryptPassword when algorithm is nil. The root Gemfile loads bcrypt and argon2 with require: false so Active Model does not depend on those native gems.
- Rails::Generators.invoke finds classes whose files end in _generator.rb under rails/generators or generators, trying base:name, name:context, name:name, rails:name, and configured fallbacks. Hidden namespaces include app, plugin, encrypted_file, encryption_key_file, master_key, credentials, and db:system:change.
- Guides source lives in guides/source (getting_started.md covers app layout, REST, and Kamal deploy). Bug reports are expected to start from guides/bug_report_templates for Active Record, migrations, Action View, Active Job, Active Storage, Action Mailer, Action Mailbox, Action Pack, or the generic template.