Skip to content

Commit

Permalink
Ignore a few pylint warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
aatle committed Dec 1, 2024
1 parent f235432 commit a71dfb5
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions src_py/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -328,18 +328,20 @@ def lazy_import(name):
try:
if numpy_missing:
# Always fails here. Need the error message for MissingModule.reason
import numpy
import numpy # pylint: disable=ungrouped-imports
# Check that module dependencies are not missing, or get error message
import pygame.pixelcopy
import pygame.pixelcopy # pylint: disable=ungrouped-imports
except (ImportError, OSError):
surfarray = MissingModule("surfarray", urgent=0)
else:
surfarray = lazy_import("surfarray")

try:
if numpy_missing:
import numpy
import pygame.mixer
# Always fails here. Need the error message for MissingModule.reason
import numpy # pylint: disable=ungrouped-imports
# Check that module dependencies are not missing, or get error message
import pygame.mixer # pylint: disable=ungrouped-imports
except (ImportError, OSError):
sndarray = MissingModule("sndarray", urgent=0)
else:
Expand Down

0 comments on commit a71dfb5

Please sign in to comment.