Hacktoberfest 2026: những issue maintainer đã đánh dấu cho tháng Mười, đang mở và phù hợp người mới. Xem issue Hacktoberfest

Scan does not check that ExpressionAttributeValues numbers are numbers

Đang mở
#545 0 bình luận 0 reaction 1 người được giao Xem trên GitHub

Maintainer thường phản hồi trong vòng 2 ngày

@LeeroyHannigan đang làm issue này rồi.

Từ ngày 25/10/2026.

  • #562 của @LeeroyHannigan — đang mở

Đánh giá

Issue này chưa được đánh giá.

Mô tả

What ExtendDB does

Scan does not check that the N values in ExpressionAttributeValues are numbers. Run on a release SQLite binary built from the fix for the same check on Query; the Scan path there is the same as on main (744ea291):

request ExtendDB
FilterExpression: "a = :n", :n = {"N": "bob"} 200, Count: 0
the same with :n an L, an M or an NS holding bob 200, Count: 0
:n = {"N": "1e200"}, a 39-digit number, or {"N": ""} 200, Count: 0
:n = {"N": "bob"} unused, FilterExpression: "a = :p" ValidationException Value provided in ExpressionAttributeValues unused in expressions: keys: {:n}
FilterExpression: "a = :n", :n = {"N": "bob"}, a table that does not exist ResourceNotFoundException
Limit: 0 with :n = {"N": "bob"} ValidationException 1 validation error detected: Value '0' at 'limit' failed to satisfy constraint: Member must have value greater than or equal to 1

What DynamoDB does

Measured 2026-10-24 at 21:06 UTC in us-east-1, admin principal, client retries off, each request twice with the same answer:

request DynamoDB
FilterExpression: "a = :n", :n = {"N": "bob"} ValidationException The parameter cannot be converted to a numeric value: bob
the same with :n an L, an M or an NS holding bob the same message
:n = {"N": "bob"} unused, FilterExpression: "a = :p" the same message
FilterExpression: "a = :n", :n = {"N": "bob"}, a table that does not exist the same message
:n = {"N": "1e200"} Number overflow. Attempting to store a number with magnitude larger than supported range
:n a 39-digit number Attempting to store more than 38 significant digits in a Number
:n = {"N": ""} The parameter cannot be converted to a numeric value:
Limit: 0 with :n = {"N": "bob"} ValidationException 1 validation error detected: Value at 'Limit' failed to satisfy constraint: Member must have value greater than or equal to 1

So the service checks every number in a Scan's ExpressionAttributeValues, nested ones included, after Limit and before the table lookup, whether or not an expression reads the value. Its Limit message names 'Limit' with no value.

Fix

Run the Query request-time number check (validate_expression_attribute_value_numbers in crates/engine/src/query_key_values.rs, once that change merges) on Scan too, after the Limit check and before the table lookup, and use the service's Limit text.

Ngôn ngữ chính
Rust
Star
517
Fork
60
Merge trung bình
2 ngày 23 giờ
Pull request đã merge (30 ngày)
25

Chuẩn bị môi trường

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của ExtendDB/extenddb

Tất cả issue của ExtendDB/extenddb

Issue tương tự

Thêm issue về Rust

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.