test_field_overflow()¶
Documentation for tests/frontier/validation/test_transaction_rlp.py::test_field_overflow@49633827.
Generate fixtures for these test cases for Amsterdam with:
fill -v tests/frontier/validation/test_transaction_rlp.py::test_field_overflow --fork Amsterdam
Encode one integer field as a 33-byte value (2**256), exceeding the 256-bit width of the field. The spec decodes the nonce as a 256-bit scalar as well; its 64-bit bound is a validation rule (EIP-2681), not a decoding one, and clients that store the nonce in 64 bits reject the oversized encoding all the same.
The gas limit and gas price are unbounded scalars in the spec, so oversized values there are not a decoding error and are rejected only in block context. The signature v is also a bounded 256-bit field, but has no field-specific decoding exception, so its oversized encoding is not covered here.
Source code in tests/frontier/validation/test_transaction_rlp.py
263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 | |
Parametrized Test Cases¶
This test generates 4 parametrized test cases across 16 forks.