Skip to content

AVRO-4350: [JavaScript] Remove underscore dependency - #3974

Open
svozza wants to merge 1 commit into
apache:mainfrom
svozza:AVRO-4350-remove-underscore
Open

AVRO-4350: [JavaScript] Remove underscore dependency#3974
svozza wants to merge 1 commit into
apache:mainfrom
svozza:AVRO-4350-remove-underscore

Conversation

@svozza

@svozza svozza commented Aug 27, 2026

Copy link
Copy Markdown
Contributor

What is the purpose of the change

AVRO-4350

Follow-up to #3970, which restored Underscore to fix broken clean installations of avro-js.

This removes the Underscore usage from the deprecated validator by replacing collection operations with native JavaScript APIs and using the existing util.isDeepStrictEqual API for structural comparisons.

The legacy Nodeunit validator tests have been moved into the main Mocha suite. Obsolete Nodeunit and Grunt test infrastructure has also been removed.

Verifying this change

Added coverage for the deprecated validator, including:

  • Primitive, record, enum, array, map, union, and protocol validation
  • Boxed primitive and special number behavior
  • Equivalent and conflicting repeated named records
  • Deeply nested repeated record definitions
  • Equivalent and conflicting repeated named enums
  • Null-safe protocol validation

Verified with:

  • ./build.sh test: 414 tests passed
  • npm run lint
  • A clean npm ci with Underscore absent
  • Packaging the modified source, installing the resulting tarball in a clean project, and successfully requiring avro-js

Documentation

  • Does this pull request introduce a new feature? no
  • If yes, how is the feature documented? not applicable

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

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant