Skip to content

Commit 89f16b6

Browse files
committed
Highlight ModuleNotFoundError
1 parent 2bd426a commit 89f16b6

File tree

4 files changed

+5
-3
lines changed

4 files changed

+5
-3
lines changed

grammars/MagicPython.cson

+1-1
Original file line numberDiff line numberDiff line change
@@ -1704,7 +1704,7 @@ repository:
17041704
| Key | Lookup | Memory | Name | NotImplemented | OS | Overflow
17051705
| Reference | Runtime | Recursion | Syntax | System
17061706
| Tab | Type | UnboundLocal | Unicode(Encode|Decode|Translate)?
1707-
| Value | Windows | ZeroDivision
1707+
| Value | Windows | ZeroDivision | ModuleNotFound
17081708
) Error
17091709
|
17101710
((Pending)?Deprecation | Runtime | Syntax | User | Future | Import

grammars/MagicPython.tmLanguage

+1-1
Original file line numberDiff line numberDiff line change
@@ -2669,7 +2669,7 @@
26692669
| Key | Lookup | Memory | Name | NotImplemented | OS | Overflow
26702670
| Reference | Runtime | Recursion | Syntax | System
26712671
| Tab | Type | UnboundLocal | Unicode(Encode|Decode|Translate)?
2672-
| Value | Windows | ZeroDivision
2672+
| Value | Windows | ZeroDivision | ModuleNotFound
26732673
) Error
26742674
|
26752675
((Pending)?Deprecation | Runtime | Syntax | User | Future | Import

grammars/src/MagicPython.syntax.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1254,7 +1254,7 @@ repository:
12541254
| Key | Lookup | Memory | Name | NotImplemented | OS | Overflow
12551255
| Reference | Runtime | Recursion | Syntax | System
12561256
| Tab | Type | UnboundLocal | Unicode(Encode|Decode|Translate)?
1257-
| Value | Windows | ZeroDivision
1257+
| Value | Windows | ZeroDivision | ModuleNotFound
12581258
) Error
12591259
|
12601260
((Pending)?Deprecation | Runtime | Syntax | User | Future | Import

test/builtins/builtins1.py

+2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
AttributeError ConnectionAbortedError
22
PendingDeprecationWarning
3+
ModuleNotFoundError
34
SystemExit
45
NotImplemented True None False Ellipsis
56
Warning
@@ -12,6 +13,7 @@
1213
: source.python
1314
ConnectionAbortedError : source.python, support.type.exception.python
1415
PendingDeprecationWarning : source.python, support.type.exception.python
16+
ModuleNotFoundError : source.python, support.type.exception.python
1517
SystemExit : source.python, support.type.exception.python
1618
NotImplemented : constant.language.python, source.python
1719
: source.python

0 commit comments

Comments
 (0)