Skip to content

Commit

Permalink
Fix wrong module name in example code
Browse files Browse the repository at this point in the history
  • Loading branch information
DetachHead authored Feb 14, 2024
1 parent 20e3ec9 commit 2bc89d3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ pyright allows invalid imports such as this:
```
```py
# ./module_name/bar.py:
import foo # wrong! should be `import modulename.foo` or `from modulename import foo`
import foo # wrong! should be `import module_name.foo` or `from module_name import foo`
```

this may look correct at first glance, and will work when running `bar.py` directly as a script, but when it's imported as a module, it will crash:
Expand Down

0 comments on commit 2bc89d3

Please sign in to comment.