Skip to content

@blazetrails/activestorage ​

File attachments for Trails models, mirroring the activestorage gem

MeasureValue
Rails counterpartactivestorage v8.0.5.2
API methods matched100% (700 of 700)
Rails tests matched77% (97 of 125) (3 permanent)
Ruby files ported69
Ruby files unported0
Measured atfe89b44726

Gaps by file ​

Ported files with Rails methods or tests still missing, largest gap first.

Ruby fileTypeScript fileMethods missingTests matched
service/disk_service.rbservice/disk-service.ts08 / 25
previewer/video_previewer.rbpreviewer/video-previewer.ts02 / 7
service/gcs_service.rbservice/gcs-service.ts014 / 17 (2 permanent)
analyzer/audio_analyzer.rbanalyzer/audio-analyzer.ts03 / 4
analyzer/image_analyzer/image_magick.rbanalyzer/image-analyzer/image-magick.ts05 / 6
analyzer/video_analyzer.rbanalyzer/video-analyzer.ts010 / 11

Missing methods ​

None recorded for this package.

Unported Ruby files ​

Every compared Ruby file has a TypeScript file.

Deviation receipts ​

JSDoc receipt tags in the package's source, by the receipt each carries.

TagPERMANENTCONVERGEABLEnone
@noRailsEquivalent1110
@missingRailsCall500
@missingRailsArgs600
@inventedArm2800
@internal00224

Permanently skipped tests ​

No section cited (2)
Ruby protocol methods with a different JS mechanism (3)

Ratified deviations ​

Each rule below is ratified in the repository's CLAUDE.md files. The first paragraph is quoted; the link opens the full section at this build's commit.

Ruby protocol methods with a different JS mechanism ​

Five Ruby protocol names are neither portable by name nor meaningless: JS has the capability, in a different place. Each is decided here, and each but hash / eql? is its own SKIP_GROUPS entry in scripts/parity/conventions.ts:

CLAUDE.md →

A variant's method names are camelCase (ImageProcessingTransformer) ​

supported_image_processing_methods holds Ruby's names, which are also the keys of a variant's transformation hash and the methods image_processing dispatches. trails' option keys are camelCase, so ActiveStorage.supportedImageProcessingMethods is the list in camelCase: validate_transformation's comparison stays exact (image_processing_transformer.rb:54), operations pushes [name, argument] as written (:45), and :38's "combine_options" is "combineOptions". A snake_case or hyphenated key is an unsupported method. process awaits ImageProcessing.loadPath[...] where Ruby's autoload loads inside const_get (vendor/image_processing/v1.14.0/lib/image_processing.rb:10-11), the shape of § "An adapter file is loaded by an awaited step", and carries @inventedArm loadPath — PERMANENT. Ruled by the operator on 2026-10-31.

packages/activestorage/CLAUDE.md →

method_missing definers in this package ​

Class-specific rules under root § "Ruby protocol methods with a different JS mechanism"; its cross-table rules and docs/method-missing-definers.md apply too.

packages/activestorage/CLAUDE.md →

A service URL is async (Service#url, url_for_direct_upload) ​

Rails' Service#url (vendor/rails/v8.0.5.2/activestorage/lib/active_storage/service.rb:134-143) and url_for_direct_upload are synchronous, because the Ruby SDKs sign in process. The JS SDKs do not: getSignedUrl in @aws-sdk/s3-request-presigner and File#getSignedUrl in @google-cloud/storage are async with no sync form, S3's endpoint and credential providers are async, and GCS IAM signing (gcs_service.rb:211-226) is a network call. So url and urlForDirectUpload are async on every service, Disk and Mirror included, and so are Blob#url, Blob#serviceUrlForDirectUpload, Variant#url and VariantWithRecord#url; every caller awaits. privateUrl / publicUrl may answer a promise. headersForDirectUpload stays sync: no service does I/O for it. There is no async_url twin, as § "A job's perform and enqueue are async" has none. Ruled in RFC 0215-activestorage-cloud-services, decision 5; this is a genuine language shortcoming, and a new instance is not a new decision to argue.

packages/activestorage/CLAUDE.md →

Source ​

packages/activestorage on GitHub →