Skip to content

fix(plugin-mongodb): emit only JSON-valid numeric literals#1813

Open
andiahmads wants to merge 2 commits into
TableProApp:mainfrom
andiahmads:fix/mongodb-extended-json-validity
Open

fix(plugin-mongodb): emit only JSON-valid numeric literals#1813
andiahmads wants to merge 2 commits into
TableProApp:mainfrom
andiahmads:fix/mongodb-extended-json-validity

Conversation

@andiahmads

Copy link
Copy Markdown
Contributor

Summary

MongoDB-generated filters and edit statements now only emit numeric literals when the value uses valid JSON number syntax. Values like .5, 1., +7, and 01 stay quoted, so generated find, insert, update, and delete JSON remains parseable and preserves string-looking values. Valid JSON numbers, including decimals and exponent notation, still emit unquoted.

Validation

  • xcodebuild -project TablePro.xcodeproj -scheme TablePro -skipPackagePluginValidation -only-testing:TableProTests/MongoDBQueryBuilderTests -only-testing:TableProTests/MongoDBStatementGeneratorTests CODE_SIGNING_ALLOWED=NO test
  • xcodebuild -project TablePro.xcodeproj -scheme TablePro -skipPackagePluginValidation -only-testing:TableProTests/MongoShellParserTests -only-testing:TableProTests/MongoDBExtendedJsonTests -only-testing:TableProTests/BsonDocumentFlattenerTests CODE_SIGNING_ALLOWED=NO test
  • swiftlint lint --strict
  • git diff --check

Compound Engineering
GPT-5

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex usage limits have been reached for code reviews. Please check with the admins of this repo to increase the limits by adding credits.
Credits must be used to enable repository wide code reviews.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants