Skip to content

Commit

Permalink
Second attempt at just renaming the file and seeing if that makes Pyt…
Browse files Browse the repository at this point in the history
…hon pick it up...
  • Loading branch information
TaylorSMarks committed Jul 14, 2021
1 parent 5a8004f commit 7c24322
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
4 changes: 2 additions & 2 deletions playsound.py
Original file line number Diff line number Diff line change
Expand Up @@ -62,8 +62,8 @@ def _playsoundOSX(sound, block = True):
print("playsound could not find a copy of AppKit - falling back to using macOS's system copy.")
import sys
if sys.version_info[0] > 2:
from shutil import rename
rename('_objc.cpython-38-darwin.so', '_objc.so')
from shutil import move
move('_objc.cpython-38-darwin.so', '_objc.so')
sys.path.append('/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/PyObjC')
from AppKit import NSSound

Expand Down
1 change: 0 additions & 1 deletion test.py
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,6 @@ def helper(self, file, approximateDuration, block = True):
self.assertTrue(approximateDuration - durationMarginLow <= duration <= approximateDuration + duratingMarginHigh, 'File "{}" took an unexpected amount of time: {}'.format(file.encode('utf-8'), duration))

testBlockingASCII_MP3 = lambda self: self.helper('Damonte.mp3', 1.1)
testBlockingAgain = lambda self: self.helper('Damonte.mp3', 1.1)
testBlockingASCII_WAV = lambda self: self.helper('Sound4.wav', 1.3)
testBlockingCYRIL_WAV = lambda self: self.helper(u'Буква_Я.wav', 1.6)
testBlockingSPACE_MP3 = lambda self: self.helper('Discovery - Go at throttle up (2).mp3', 2.3)
Expand Down

0 comments on commit 7c24322

Please sign in to comment.