<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:

def require(*reqs):
	'''Require tasks or files at runtime.'''
	for req in reqs:
		if type(req) is str:
			# does not exist and unknown generator
			if not os.path.exists(req) and req not in GENERATES:
				abort(LOCALE['abort_bad_file'].format(req))

			# exists but unknown generator
			if req not in GENERATES:
				return

			# exists and known generator
			if req in GENERATES:
				req = GENERATES[req]

		if req.valid is None:
			if len(req.args):
				abort(LOCALE['abort_bad_args'], req, len(req.args))

			req()

		if req.valid is False:
			abort(LOCALE['abort_bad_task'], req)