Skip to content

Commit

Permalink
Support pyparsing version 3 (#907)
Browse files Browse the repository at this point in the history
* * Change pyparsing usage to be compatible with version 3

    upcaseTokens -> pyparsing_common.upcaseTokens

* Spec minimum pyparsing in the conda package

* syntax fix

Co-authored-by: AU <adam-urbanczyk@users.noreply.github.com>
  • Loading branch information
2 people authored and marcus7070 committed Oct 30, 2021
1 parent 9fe1a2b commit bc6bf9e
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions cadquery/selectors.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,13 +31,13 @@
geom_LUT_FACE,
)
from pyparsing import (
pyparsing_common,
Literal,
Word,
nums,
Optional,
Combine,
oneOf,
upcaseTokens,
CaselessLiteral,
Group,
infixNotation,
Expand Down Expand Up @@ -637,7 +637,7 @@ def _makeGrammar():
cqtype = oneOf(
set(geom_LUT_EDGE.values()) | set(geom_LUT_FACE.values()), caseless=True,
)
cqtype = cqtype.setParseAction(upcaseTokens)
cqtype = cqtype.setParseAction(pyparsing_common.upcaseTokens)

# type operator
type_op = Literal("%")
Expand Down
2 changes: 1 addition & 1 deletion conda/meta.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ requirements:
- python {{ environ.get('PYTHON_VERSION') }}
- ocp 7.5.2
- hdf5 1.10.6 *1114
- pyparsing 2.*
- pyparsing >=2.1.9
- ezdxf
- ipython
- typing_extensions
Expand Down
2 changes: 1 addition & 1 deletion environment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ dependencies:
- python>=3.6
- ipython
- ocp=7.5.1
- pyparsing
- pyparsing>=2.1.9
- sphinx=3.2.1
- sphinx_rtd_theme
- sphinx-autodoc-typehints
Expand Down

0 comments on commit bc6bf9e

Please sign in to comment.