Exam 200-901 Question id=6290 Application Deployment and Security

Refer to the exhibit.

$ diff -u5 fish.py cat.py --- fish.py 2020-01-02 09:41:02.840000000 +0100 +++ cat.py 2020-01-02 09:41:06.8859999800 +0100 @@ -160,11 +160,12 @@ @single_request_timeout.setter def single_request_timeout(self, value): """The timeout (seconds) for a single HTTP REST API request.""" check_type(value, int, optional=True) - assert value is None or value > 0 + if value is not None and value <= 0: + raise ValueError ("single request_timeout must be positive integer") self._single _request_timeout = value @property def wait_on_rate_limit(self) """Automatic rate-limit handling.

The output of a unified diff when comparing two versions of a Python script is shown. Which two "single_request_timeout()" functions are defined in fish.py and cat.py? (Choose two.)

A. file: cat.py @single_request_timeout.setter def single_request_timeout(self, value): """The timeout (seconds) for a single HTTP REST API request.""" check_type(value, int, optional=True) assert value is None or value > 0 if value is not None and value <= 0: raise ValueError("single_request_timeout must be positive integer") self._single_request_timeout = value
B. file: fish.py @single_request_timeout.setter def single_request_timeout(self, value): """The timeout (seconds) for a single HTTP REST API request.""" check_type(value, int, optional=True) assert value is None or value > 0 self._single_request_timeout = value
C. file: cat.py @single_request_timeout.setter def single_request_timeout(self, value): """The timeout (seconds) for a single HTTP REST API request.""" check_type(value, int, optional=True) if value is not None and value <= 0: raise ValueError("single_request_timeout must be positive integer") self._single_request_timeout = value
D. file: fish.py @single_request_timeout.setter def single_request_timeout(self, value): """The timeout (seconds) for a single HTTP REST API request.""" check_type(value, int, optional=True) self._single_request_timeout = value
E. file: cat.py @single_request_timeout.setter def single_request_timeout(self, value): """The timeout (seconds) for a single HTTP REST API request.""" check_type(value, int, optional=True) if value is not None and value <= 0: raise ValueError("single_request_timeout must be positive integer") self._single_request_timeout = value

WARNING

the answers are mixed, do not specify in the comment number or the letter of the answer
please write answer#A instead A, answer#B instead B...
Subject:

only logged users can write comments