##### SUMMARY
See https://github.com/ansible/ansible/blob/88d8cf8197c53edd3bcdcd21429eb4c2bfbf0f6a/lib/ansible/module_utils/basic.py#L699-L706

##### ISSUE TYPE
- Bug Report

##### COMPONENT NAME
lib/ansible/module_utils/basic.py

##### ANSIBLE VERSION
```paste below
2.9
devel
```

version = None
        try:
            if (node.func.attrname == 'deprecated' and 'display' in _get_expr_name(node) or
                    node.func.attrname == 'deprecate' and 'module' in _get_expr_name(node)):
                if node.keywords:
                    for keyword in node.keywords:
                        if len(node.keywords) == 1 and keyword.arg is None:
                            
                            return
                        if keyword.arg == 'version':
                            if isinstance(keyword.value.value, astroid.Name):
                                
                                return
                            version = keyword.value.value
                if not version:
                    try:
                        version = node.args[1].value
                    except IndexError:
                        self.add_message('ansible-deprecated-no-version', node=node)
                        return
                try:
                    if ANSIBLE_VERSION >= LooseVersion(str(version)):
                        self.add_message('ansible-deprecated-version', node=node, args=(version,))
                except ValueError:
                    self.add_message('ansible-invalid-deprecated-version', node=node, args=(version,))
        except AttributeError:
            
            pass
def register(linter):