@blazetrails/mysql2
The MySQL client, mirroring Ruby's mysql2 gem
| Measure | Value |
|---|---|
| Rails counterpart | mysql2 0.5.6 |
| API methods matched | 100% (19 of 19) |
| Rails tests matched | 100% (214 of 214) (62 permanent) |
| Ruby files ported | 4 |
| Ruby files unported | 0 |
| Measured at | fe89b44726 |
Gaps by file
No gaps recorded for this package.
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.
| Tag | PERMANENT | CONVERGEABLE | none |
|---|---|---|---|
@noRailsEquivalent | 5 | 0 | 0 |
@internal | 0 | 0 | 19 |
Permanently skipped tests
Runtime facts Node does not expose (8)
- should not leave dangling connections after garbage collection
- should not close connections when running in a child process
- should describe the thread holding the active query
- should run signal handlers while waiting for a response
- should handle Timeouts without leaving the connection hanging if reconnect is true
- threaded queries should be supported
- should not overflow the thread stack
- should not overflow the thread stack
No section cited (15)
- cannot be disabled
- should detect closed connection on query read error
- should not allow another query to be sent without fetching a result first
- should timeout if we wait longer than :read_timeout
- #socket should return a Fixnum (file descriptor from C)
- should be impervious to connection-corrupting timeouts in #execute
- should close the connection when an exception is raised
- should respond to #socket
- #socket should raise as it's not supported
- should respond to #info
- should raise a TypeError exception when it doesn't wrap a result set
- should raise an exception without a block
- should handle bignum but in int64_t
- should prepare Time values with microseconds
- should handle as a decimal binding a BigDecimal
A String has no encoding tag either (16)
- should carry over the original string's encoding
- should return a internal encoding string if Encoding.default_internal is set
- should be tagged as ascii
- should be tagged as ascii
- should default to the connection's encoding if Encoding.default_internal is nil
- should respond to #encoding
- returns error messages as UTF-8 by default
- should default to the connection's encoding if Encoding.default_internal is nil
- should default to the connection's encoding if Encoding.default_internal is nil
- should default to binary if Encoding.default_internal is nil
- should default to binary if Encoding.default_internal is nil
- should be able to retrieve utf8 field names correctly
- should default to the connection's encoding if Encoding.default_internal is nil
- should default to the connection's encoding if Encoding.default_internal is nil
- should default to binary if Encoding.default_internal is nil
- should default to binary if Encoding.default_internal is nil
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.
A String has no encoding tag either
str.encoding, force_encoding and String#b read or change a per-object encoding. A JS string has none, and trails adds none: the carrier that would hold it is the carrier this section rejects. ruby-compat tags a Uint8Array only. A Rails body that branches on a String's encoding ports the UTF-8 arm, and a test asserting str.encoding is permanently unportable for that assertion.
Runtime facts Node does not expose
Each of these is a Ruby or C-library fact with no Node source. They are ratified here so no port re-derives them.