Journeyman electrician's expression: it does not meet legal safety or load requirements for project and transplanted to mean someone who is mentally ill or just plain stupid. Example: Did you see what he did? His wiring ain't up to code.
HIS WIRING AIN'T UP TO CODE.
Meaning of HIS WIRING AIN'T UP TO CODE. in English
Slang English vocab. Английский сленговый словарь. 2012