Dirty hack to fix manage.py invocation.

CAS_ATTRIBUTE_CALLBACK gets decided during envs processing when everything is loading. It is, unfortunately, before UserProfile can be properly imported. I can wrap the import statement into try/except, but I suspect that won't get it to properly evaluate. If I put the import statement inside the function itself, it won't get evaluated before the actual login happens, when everything should be ok to run.

Hacking this in properly will probably need some deeper thinking.