Fork pull requests normally run with a read-only token and without repository secrets. That prevents untrusted changes from simply printing a publishing credential. pull_request_target runs in a different, privileged context and requires careful separation from untrusted checkout and execution. Don't use it as a shortcut when a fork test can't access a secret. Keep ordinary validation unprivileged and place publication behind trusted code and the appropriate review boundary.
The browser runner evaluates a bounded model of the workflow. It doesn't start a hosted machine, contact GitHub or execute arbitrary shell programs. Use the event and run details to check the result. Saving valid YAML alone doesn't prove that the intended job ran.
Fork pull requests normally receive a read-only token and no repository secrets. Don't switch to pull_request_target and execute untrusted code merely to obtain credentials.