### Summary

Upgraded from Ansible 3.4/core 2.10 to 4.3 and core 2.11. Get an error that says `ERROR! Unexpected Exception, this is probably a bug: 'float' object has no attribute 'startswith'` when running ansible-galaxy with a git repository in it. 

Tested against 

### Issue Type

Bug Report

### Component Name

galaxy

### Ansible Version

```console
ansible [core 2.11.2]
  config file = /var/lib/buildkite-agent/.ansible.cfg
  configured module search path = ['/var/lib/buildkite-agent/.ansible/plugins/modules', '/usr/share/ansible/plugins/modules']
  ansible python module location = /var/lib/buildkite-agent/.local/lib/python3.8/site-packages/ansible
  ansible collection location = /var/lib/buildkite-agent/.ansible/collections:/usr/share/ansible/collections
  executable location = /usr/local/bin/ansible
  python version = 3.8.0 (default, Feb 25 2021, 22:10:10) [GCC 8.4.0]
  jinja version = 2.10
  libyaml = False
```


### Configuration

```console
$ ansible-config dump --only-changed
DEFAULT_ASK_PASS(/var/lib/buildkite-agent/.ansible.cfg) = False
DEFAULT_LOCAL_TMP(/var/lib/buildkite-agent/.ansible.cfg) = /tmp/ansible/tmp/ansible-local-10804znovzlh6
```


### OS / Environment

Ubuntu 18.04, with python upgraded to 3.8.0 and ansible installed via pip

### Steps to Reproduce

<!--- Paste example playbooks or commands between quotes below -->
```yaml (paste below)
collections:
# With just the collection name
- community.aws
- name: git@github.com:VoiceThread/ansible-collection-buildkite.git
  type: git
  version: "0.7"
```

Note that I tested with ansible 4.2 and 4.3, which are all that I could install via pip. 

It appears that despite quoting the version 0.7, that string was turned into a float in some portion of the code. 

### Expected Results

I expected the AWS community and our custom buildkite collection to be installed. 

### Actual Results

```console
buildkite-agent@buildkite-agent-tools3208:~/builds/buildkite-agent-tools3208-1/voicethread-llc/ami-bakery/buildkite_agent_frontend$ansible-galaxy -vvv install -r ./requirements.yml
[DEPRECATION WARNING]: Setting verbosity before the arg sub command is deprecated, set the verbosity after the sub command. This feature will be removed from
ansible-core in version 2.13. Deprecation warnings can be disabled by setting deprecation_warnings=False in ansible.cfg.
ansible-galaxy [core 2.11.2]
  config file = /var/lib/buildkite-agent/.ansible.cfg
  configured module search path = ['/var/lib/buildkite-agent/.ansible/plugins/modules', '/usr/share/ansible/plugins/modules']
  ansible python module location = /var/lib/buildkite-agent/.local/lib/python3.8/site-packages/ansible
  ansible collection location = /var/lib/buildkite-agent/.ansible/collections:/usr/share/ansible/collections
  executable location = /usr/local/bin/ansible-galaxy
  python version = 3.8.0 (default, Feb 25 2021, 22:10:10) [GCC 8.4.0]
  jinja version = 2.10
  libyaml = False
Using /var/lib/buildkite-agent/.ansible.cfg as config file
Reading requirement file at '/var/lib/buildkite-agent/builds/buildkite-agent-tools3208-1/voicethread-llc/ami-bakery/buildkite_agent_frontend/requirements.yml'
Cloning into '/tmp/ansible/tmp/ansible-local-10652xjwcbw9q/tmphvi5md99/ansible-collection-buildkitek95mgz7r'...
remote: Enumerating objects: 215, done.
remote: Counting objects: 100% (215/215), done.
remote: Compressing objects: 100% (160/160), done.
remote: Total 215 (delta 73), reused 176 (delta 42), pack-reused 0
Receiving objects: 100% (215/215), 28.94 KiB | 14.47 MiB/s, done.
Resolving deltas: 100% (73/73), done.
Your branch is up to date with 'origin/main'.
Starting galaxy collection install process
Process install dependency map
Opened /var/lib/buildkite-agent/.ansible/galaxy_token
ERROR! Unexpected Exception, this is probably a bug: 'float' object has no attribute 'startswith'
the full traceback was:

Traceback (most recent call last):
  File "/usr/local/bin/ansible-galaxy", line 135, in <module>
    exit_code = cli.run()
  File "/var/lib/buildkite-agent/.local/lib/python3.8/site-packages/ansible/cli/galaxy.py", line 552, in run
    return context.CLIARGS['func']()
  File "/var/lib/buildkite-agent/.local/lib/python3.8/site-packages/ansible/cli/galaxy.py", line 75, in method_wrapper
    return wrapped_method(*args, **kwargs)
  File "/var/lib/buildkite-agent/.local/lib/python3.8/site-packages/ansible/cli/galaxy.py", line 1186, in execute_install
    self._execute_install_collection(
  File "/var/lib/buildkite-agent/.local/lib/python3.8/site-packages/ansible/cli/galaxy.py", line 1213, in _execute_install_collection
    install_collections(
  File "/var/lib/buildkite-agent/.local/lib/python3.8/site-packages/ansible/galaxy/collection/__init__.py", line 511, in install_collections
    dependency_map = _resolve_depenency_map(
  File "/var/lib/buildkite-agent/.local/lib/python3.8/site-packages/ansible/galaxy/collection/__init__.py", line 1328, in _resolve_depenency_map
    return collection_dep_resolver.resolve(
  File "/usr/local/lib/python3.8/dist-packages/resolvelib/resolvers.py", line 453, in resolve
    state = resolution.resolve(requirements, max_rounds=max_rounds)
  File "/usr/local/lib/python3.8/dist-packages/resolvelib/resolvers.py", line 347, in resolve
    failure_causes = self._attempt_to_pin_criterion(name, criterion)
  File "/usr/local/lib/python3.8/dist-packages/resolvelib/resolvers.py", line 216, in _attempt_to_pin_criterion
    satisfied = all(
  File "/usr/local/lib/python3.8/dist-packages/resolvelib/resolvers.py", line 217, in <genexpr>
    self._p.is_satisfied_by(r, candidate)
  File "/var/lib/buildkite-agent/.local/lib/python3.8/site-packages/ansible/galaxy/dependency_resolution/providers.py", line 280, in is_satisfied_by
    requirement.ver.startswith('<') or
AttributeError: 'float' object has no attribute 'startswith'
```


### Code of Conduct

- [X] I agree to follow the Ansible Code of Conduct
b_file_path = to_bytes(os.path.join(to_text(b_path), filename), errors='surrogate_or_strict')
    if not os.path.isfile(b_file_path):
        actual_hash = None
    else:
        with open(b_file_path, mode='rb') as file_object:
            actual_hash = _consume_file(file_object)
    if expected_hash != actual_hash:
        error_queue.append(ModifiedContent(filename=filename, expected=expected_hash, installed=actual_hash))
def _build_files_manifest(b_collection_path, namespace, name, ignore_patterns):
    
    
    
    b_ignore_patterns = [
        b'MANIFEST.json',
        b'FILES.json',
        b'galaxy.yml',
        b'galaxy.yaml',
        b'.git',
        b'*.pyc',
        b'*.retry',
        b'tests/output',  
        to_bytes('{0}-{1}-*.tar.gz'.format(namespace, name)),