Had this problem a couple of years ago and ended up replacing the whole wheel! Now it's started again on healthy wheel with new hub plus new cassette/chain/rings. Really doing my head in now as it means no riding once again.
Set rear mech up from scratch plus fiddled with all screws and barrel etc. Can't get it to work whatever I do.