fix race condition on kompiled directory

@andreistefanescu please review