fix json loads, dumps on ImportError exception