Skip to content

Commit 6ea3599

Browse files
authored
Don't exit script when c extension detected
1 parent 95e5b02 commit 6ea3599

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

ensure_pure_cbor2.sh

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ CBOR2_VERSION=$(cat .cbor2_version)
1616
echo "Found cbor2 version: $CBOR2_VERSION"
1717

1818
echo "Checking cbor2 implementation..."
19+
set +e
1920
$PYTHON -c "
2021
import cbor2, inspect, sys
2122
decoder_path = inspect.getfile(cbor2.CBORDecoder)
@@ -24,6 +25,7 @@ print(f'Implementation path: {decoder_path}')
2425
print(f'Using C extension: {using_c_ext}')
2526
sys.exit(1 if using_c_ext else 0)
2627
"
28+
set -e
2729

2830
if [ $? -ne 0 ]; then
2931
echo "Reinstalling cbor2 with pure Python implementation..."
@@ -35,4 +37,4 @@ else
3537
fi
3638

3739
# Clean up
38-
rm -f .cbor2_version
40+
rm -f .cbor2_version

0 commit comments

Comments
 (0)