我有以下代码,该代码对于一套航空突击队来说运行正常,但对于
会引发以下错误import aerospike
import sys,traceback
import redis
import time
import json
import sys
def process_result((key, metadata, record)):
try:
print "key" //This is printing for working set
//Removed all other logic from here.
except:
print("Got errors in processing " + key[2])
columnNames = {0:'PK',1:'merchantInKey'}
client = aerospike.client(config).connect()
scan = client.scan('namespace', 'setname')
#print type(columnNames)
scan.select(**columnNames)
scan.foreach(process_result)
错误-
Segmentation fault (core dumped)
我不知道这种情况下怎么了。
更新
指定这样的字段,而不是上面的示例中的**columnNames
-
scan.select('PK','merchantInKey')