<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def get_pull_request_number(task, source_env_prefix):
 """Get what Github pull request created the graph. Args: obj (ChainOfTrust or LinkOfTrust):
 the trust object to inspect source_env_prefix (str):
 The environment variable prefix that is used to get repository information. Returns: int: the pull request number. None: if not defined for this task. """

    pull_request = _extract_from_env_in_payload(task, source_env_prefix + '_PULL_REQUEST_NUMBER')
    if pull_request is not None:
        pull_request = int(pull_request)
    return pull_request