Skip to content

Instantly share code, notes, and snippets.

-------------------------------------
Translated Report (Full Report Below)
-------------------------------------
Process: soh-macos [20308]
Path: /Applications/soh.app/Contents/Resources/soh-macos
Identifier: soh-macos
Version: ???
Code Type: ARM-64 (Native)
Parent Process: launchd [1]
Process: WindowServer [244]
Path: /System/Library/PrivateFrameworks/SkyLight.framework/Versions/A/Resources/WindowServer
Identifier: WindowServer
Version: 600.00 (340.26)
Code Type: X86-64 (Native)
Parent Process: launchd [1]
Responsible: WindowServer [244]
User ID: 88
Date/Time: 2019-06-21 16:35:53.157 -0600
[13:02:45] <jcm_> merry christmas all
[13:03:25] <jcm_> doing some hacking on some stuff. https://gist.github.com/jcm93/d4b44c06b0f20fdd6c14d1c0de15cd99
[13:04:23] <jcm_> i'm having trouble understanding why i'm getting a bad access exception when the content of the trackViewArrayController changes while this block is executing
[13:05:22] <jcm_> (the managedContext exists on a private queue)
[13:05:53] <jcm_> the specific error is `error: NULL _cd_rawData but the object is not being turned into a fault`
[13:06:40] <jcm_> oh, and the content of the trackViewArrayController are entities from that managedContext.
[13:09:51] <jcm_> the exception happens on lines 5 or 6; the creation of trackArray has always finished any time there's an exception
Thread 0 Crashed:: Dispatch queue: com.apple.main-thread
0 libswiftCore.dylib 0x000000010e9d5215 _swift_retain_(swift::HeapObject*) + 5
1 org.cocoapods.sReto 0x000000010e617da1 _TFC5sReto15TransferManager13startTransferfTSi12dataProviderFT5rangeVSC8_NSRange_CSo6NSData_CS_11OutTransfer + 81 (TransferManager.swift:75)
2 org.cocoapods.sReto 0x000000010e595644 _TFC5sReto10Connection4sendfCSo6NSDataT_ + 180 (Connection.swift:108)
3 jcm.minimalTunes 0x000000010e3d4a60 _TTSf4dg_g_d___TFC12minimalTunes9P2PServer19sendPeerLibraryNamefTC5sReto10RemotePeer10connectionCS1_10Connection_T_ + 624 (MaybeTheLastServerAttempt.swift:147)
4 jcm.minimalTunes 0x000000010e3d592a _TTSf4g_g_dg_g_n___TFC12minimalTunes9P2PServer12parseRequestfTC5sReto10RemotePeer10connectionCS1_10Connection8transferCS1_8Transfer11requestDictCSo12NSDictionary_T_ + 1802
5 jcm.minimalTunes 0x000000010e3d6b45 _TTSf4g_g_g_g_n___TFC12minimalTunes9P2PServer13parseTransferf
________ GraphDescription ________
AVAudioEngineGraph 0x6180001c03c0: initialized = 1, running = 1, number of nodes = 3
******** output chain ********
node 0x6180000ae7c0 {'auou' 'ahal' 'appl'}, 'I'
inputs = 1
(bus0) <- (bus0) 0x6000002dac50, {'aumx' 'mcmx' 'appl'}, [ 2 ch, 44100 Hz, 'lpcm' (0x00000029) 32-bit little-endian float, deinterleaved]
node 0x6000002dac50 {'aumx' 'mcmx' 'appl'}, 'I'
class JSONDictionary:
def __init__(self):
self.db_file = open("database.txt", 'w')
self.user_db = json.loads(self.db_file)
func insert(tracks: [Track], track: Track, isGreater: (a: Track, b: Track) -> Bool?) -> Int {
var high: Int = tracks.count - 1
var low: Int = 0
var index: Int
while (true) {
index = (high - low) / 2
if (high - low) < 2 {
return index
}
print(index)
<AVMetadataItem: 0x6080000003f0, identifier=itsk/%A9nam, keySpace=itsk, key class = __NSCFNumber, key=©nam, commonKey=title, extendedLanguageTag=(null), dataType=com.apple.metadata.datatype.UTF-8, time={INVALID}, duration={INVALID}, startDate=(null), extras={
dataType = 1;
dataTypeNamespace = "com.apple.itunes";
}, value=Tarpit (Dinosaur Jr.)>
<AVMetadataItem: 0x60800000c750, identifier=itsk/%A9ART, keySpace=itsk, key class = __NSCFNumber, key=©ART, commonKey=artist, extendedLanguageTag=(null), dataType=com.apple.metadata.datatype.UTF-8, time={INVALID}, duration={INVALID}, startDate=(null), extras={
dataType = 1;
dataTypeNamespace = "com.apple.itunes";
}, value=Doug Martsch>
<AVMetadataItem: 0x60800000c710, identifier=itsk/%A9alb, keySpace=itsk, key class = __NSCFNumber, key=©alb, commonKey=albumName, extendedLanguageTag=(null), dataType=com.apple.metadata.datatype.UTF-8, time={INVALID}, duration={INVALID}, startDate=(null), extras={
dataType = 1;
let artists = tracks!.map( {return $0.artist!} )
let unique_artists = Array(Set(artists))
for artist in unique_artists {
artist.addAlbumsObject(album!)
}
let names = selectedTracks!.map( { return $0.name! } )
let unique_names = Array(Set(names))