<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_span(self, request=None):
 """ Returns the span tracing `request`, or the current request if `request==None`. If there is no such span, get_span returns None. @param request the request to get the span from """

        if request is None and stack.top:
            request = stack.top.request

        scope = self._current_scopes.get(request, None)
        return None if scope is None else scope.span