### Summary

In the file `lib/ansible/plugins/action/__init__.py` there’s a link to document _Understanding privilege escalation: become_. The link has an anchor that refers to the section _Risks of becoming an unprivileged user_. However, there is an error in the code that makes the URL incorrect.

The correct URL is: https://docs.ansible.com/ansible-core/2.15/playbook_guide/playbooks_privilege_escalation.html#risks-of-becoming-an-unprivileged-user

The URL that is displayed to the user is: https://docs.ansible.com/ansible-core/2.15/playbook_guide/playbooks_privilege_escalation.html#risks-of-becoming-an-unprivileged-user#risks-of-becoming-an-unprivileged-user

The error is that the anchor part of the URL gets repeated.

### Suggested solution

`become_link` is currently defined like this:

`become_link = get_versioned_doclink('playbook_guide/playbooks_privilege_escalation.html#risks-of-becoming-an-unprivileged-user')`

One option could be to instead define it like this:

`become_link = get_versioned_doclink('playbook_guide/playbooks_privilege_escalation.html')`

I believe this would work since the anchor part (currently) gets added when `become_link` is referenced.

Another solution could be to omit the anchor part when referencing `become_link`. Example:

```
display.warning(
    'Using world-readable permissions for temporary files Ansible '
    'needs to create when becoming an unprivileged user. This may '
    'be insecure. For information on securing this, see %s'
    % become_link)
```

### Issue Type

Bug Report

### Component Name

lib

### Ansible Version

```console
$ ansible --version
ansible [core 2.15.3]
  config file = None
  configured module search path = ['/Users/carl.winback/.ansible/plugins/modules', '/usr/share/ansible/plugins/modules']
  ansible python module location = /opt/homebrew/Cellar/ansible/8.3.0/libexec/lib/python3.11/site-packages/ansible
  ansible collection location = /Users/carl.winback/.ansible/collections:/usr/share/ansible/collections
  executable location = /opt/homebrew/bin/ansible
  python version = 3.11.5 (main, Aug 24 2023, 15:09:45) [Clang 14.0.3 (clang-1403.0.22.14.1)] (/opt/homebrew/Cellar/ansible/8.3.0/libexec/bin/python)
  jinja version = 3.1.2
  libyaml = True
```


### Configuration

```console
# if using a version older than ansible-core 2.12 you should omit the '-t all'
$ ansible-config dump --only-changed -t all
CONFIG_FILE() = None
EDITOR(env: EDITOR) = emacsclient
```


### OS / Environment

macOS Ventura 13.5.1

### Steps to Reproduce

<!--- Paste example playbooks or commands between quotes below -->
```
- name: foo
  ansible.builtin.shell: echo "hello"
  become: yes
  become_user: johndoe
```


### Expected Results

I expected the documentation link to look like this: https://docs.ansible.com/ansible-core/2.15/playbook_guide/playbooks_privilege_escalation.html#risks-of-becoming-an-unprivileged-user

### Actual Results

```console
fatal: [foo.example.com]: FAILED! => {"msg": "Failed to set permissions on the temporary files Ansible needs to create when becoming an unprivileged user (rc: 1, err: chmod: invalid mode: ‘A+user:johndoe:rx:allow’\nTry 'chmod --help' for more information.\n}). For information on working around this, see https://docs.ansible.com/ansible-core/2.15/playbook_guide/playbooks_privilege_escalation.html#risks-of-becoming-an-unprivileged-user#risks-of-becoming-an-unprivileged-user"}
```


### Code of Conduct

- [X] I agree to follow the Ansible Code of Conduct
from __future__ import (absolute_import, division, print_function)
__metaclass__ = type
import base64
import json
import os
import random
import re
import shlex
import stat
import tempfile
from abc import ABC, abstractmethod
from collections.abc import Sequence
from ansible import constants as C
from ansible.errors import AnsibleError, AnsibleConnectionFailure, AnsibleActionSkip, AnsibleActionFail, AnsibleAuthenticationFailure
from ansible.executor.module_common import modify_module
from ansible.executor.interpreter_discovery import discover_interpreter, InterpreterDiscoveryRequiredError
from ansible.module_utils.common.arg_spec import ArgumentSpecValidator
from ansible.module_utils.errors import UnsupportedError
from ansible.module_utils.json_utils import _filter_non_json_lines
from ansible.module_utils.six import binary_type, string_types, text_type
from ansible.module_utils.common.text.converters import to_bytes, to_native, to_text
from ansible.parsing.utils.jsonify import jsonify
from ansible.release import __version__
from ansible.utils.collection_loader import resource_from_fqcr
from ansible.utils.display import Display