我使用Python 2.7创建了一个Anaconda环境,但是当我从该环境中启动spyder时,它从Python 3.6(我的Anaconda安装的默认设置)开始。我已经确认只在命令行运行@Override
public void onTextChanged(CharSequence charSequence, int i, int i1, int i2) {
Log.i(TAG, "Search text: " + charSequence);
List<AllAttendance> list = new ArrayList<>();
//filter from all List
if (rbtnAll.isChecked())
list = filter(mAttendanceList, charSequence);
else if (rbtnPending.isChecked())
list = filter(mPendingAttendanceList, charSequence);
setAdapterData(list);
rvAttendance.scrollToPosition(0);
}
private List<AllAttendance> filter(List<AllAttendance> mAttendanceList, CharSequence charSequence) {
String text = String.valueOf(charSequence);
text = text.toLowerCase();
List<AllAttendance> filteredList = new ArrayList<>();
for (AllAttendance attendance : mAttendanceList){
if (attendance.getMandalName().toLowerCase().contains(text) || attendance.getSabhaName().toLowerCase().contains(text) || attendance.getSabhaDate().toLowerCase().contains(text))
filteredList.add(attendance);
}
return filteredList;
}
使用预期版本(环境激活时为2.7,否则为3.6)。
Spyder不应该使用当前活跃的anaconda环境的python吗?
或者......如何设置启用此行为?
答案 0 :(得分:0)
根据我上面的评论:
使用命令 JsStore.isDbExist(dbName,function(isExist)