Skip to content

Conversation

@coderamaster
Copy link

Description

Fixed deprecation warning in test utilities by replacing delimitedList with DelimitedList.

Problem

The test utilities use delimitedList from pyparsing, which is deprecated in newer versions. This causes deprecation warnings when running tests:

pyparsing.warnings.PyparsingDeprecationWarning: 'delimitedList' deprecated - use 'DelimitedList'

Solution

  • Updated import in tests/unitutil/cxml.py to use DelimitedList instead of delimitedList.
  • Replaced two usages of delimitedList() with DelimitedList() in the grammar function.

Changes Made

  • Updated import statement (line 18).
  • Replaced delimitedList(attr_def) with DelimitedList(attr_def) (line 246).
  • Replaced delimitedList(node) with DelimitedList(node) (line 263).

Testing

  • Code changes verified.
  • No syntax errors.
  • Functionality preserved (DelimitedList is the direct replacement).

Checklist

  • Code follows project style guidelines.
  • Changes are minimal and focused.
  • No breaking changes.
  • PR description is clear.

- Updated import to use DelimitedList instead of delimitedList
- Replaced delimitedList() calls with DelimitedList() in grammar()
- Fixes pyparsing deprecation warning in test utilities
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.

1 participant