@staticmethod
def apply_required_default(items, default):
    """Apply default value to first element of item if it's None.

        :argument items: List of tuples
        :type items: iterable
        :argument default: Value to use if none provided
        :type default: boolean

        :returns: List of tuples, with required default value applied
        :rtype: iterable of tuple

        >>> list(
        ...   OptionalPartList.apply_required_default(
        ...     [
        ...       ('<provided>', '<1>'),
        ...       (None, '<2>')
        ...     ],
        ...     default='<default>'
        ...   )
        ... )
        [('<provided>', '<1>'), ('<default>', '<2>')]

        """
    for required, args in items:
        if required is None:
            required = default
        yield required, args
