fix a bug that slow crash when there is not proxy config
add build function