RuntimeError: You must setup() the GPIO channel first

C
The line that reads
    if GPIO.input(23 == False):
Should be
	if GPIO.input(23) == False:
Source

Also in C: