Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Turning on debug logging via ACTIONS_RUNNER_DEBUG is not reflected in runner.debug context #2353

Open
a-b opened this issue Jun 5, 2024 · 3 comments
Labels
kind/bug Something isn't working

Comments

@a-b
Copy link

a-b commented Jun 5, 2024

Bug report info

act version:            0.2.62
GOOS:                   darwin
GOARCH:                 amd64
NumCPU:                 16
Docker host:            DOCKER_HOST environment variable is not set
Sockets found:
	/var/run/docker.sock
	$HOME/.docker/run/docker.sock
Config files:           
	/Users/user/.actrc:
		-P ubuntu-latest=catthehacker/ubuntu:act-latest
		-P ubuntu-22.04=catthehacker/ubuntu:act-22.04
		-P ubuntu-20.04=catthehacker/ubuntu:act-20.04
		-P ubuntu-18.04=catthehacker/ubuntu:act-18.04
Build info:
	Go version:            go1.22.2
	Module path:           command-line-arguments
	Main version:          
	Main path:             
	Main checksum:         
	Build settings:
		-buildmode:           exe
		-compiler:            gc
		-ldflags:             -X main.version=0.2.62
		DefaultGODEBUG:       httplaxcontentlength=1,httpmuxgo121=1,tls10server=1,tlsrsakex=1,tlsunsafeekm=1
		CGO_ENABLED:          1
		CGO_CFLAGS:           
		CGO_CPPFLAGS:         
		CGO_CXXFLAGS:         
		CGO_LDFLAGS:          
		GOARCH:               amd64
		GOOS:                 darwin
		GOAMD64:              v1
Docker Engine:
	Engine version:        26.1.1
	Engine runtime:        runc
	Cgroup version:        2
	Cgroup driver:         cgroupfs
	Storage driver:        stargz
	Registry URI:          https://index.docker.io/v1/
	OS:                    Docker Desktop
	OS type:               linux
	OS version:            
	OS arch:               x86_64
	OS kernel:             6.6.26-linuxkit
	OS CPU:                16
	OS memory:             15990 MB
	Security options:
		name=seccomp,profile=unconfined
		name=cgroupns

Command used with act

act --env ACTIONS_RUNNER_DEBUG=true --workflows .github/workflows/test.yml

Describe issue

Per GHA enabling-debug-logging doc and runner-context runner's debug log status should be reflected via runner.debug expression. This behavior is not implemented in the current state of act.

Link to GitHub repository

No response

Workflow content

on:
  workflow_dispatch:
  push:
    branches: [ main ]

jobs:
  test-debug:
    name: Test Debug Workflow
    runs-on: ubuntu-latest
    steps:
      - name: Print expression details
        run: |
          echo "State of the runner.debug '${{ runner.debug }}'"
          env | grep ACTIONS_RUNNER_DEBUG

Relevant log output

| State of the runner.debug ''
| ACTIONS_RUNNER_DEBUG=true

Additional information

No response

@a-b a-b added the kind/bug Something isn't working label Jun 5, 2024
@a-b a-b changed the title Setting ACTIONS_RUNNER_DEBUG does not reflected in runner.debug Turning on debug logging via ACTIONS_RUNNER_DEBUG is not reflected in runner.debug context Jun 5, 2024
@ChristopherHX
Copy link
Contributor

IMHO, Note: --env ACTIONS_RUNNER_DEBUG=true should never work. Or show me in GitHub Actions that you can enable runner.debug via an env

I'm ok with --var ACTIONS_RUNNER_DEBUG=true or -s ACTIONS_RUNNER_DEBUG=true as a change request.

@ChristopherHX
Copy link
Contributor

Isn't ${{ runner.debug }} dependent on ACTIONS_STEP_DEBUG????

@a-b
Copy link
Author

a-b commented Jun 7, 2024

Isn't ${{ runner.debug }} dependent on ACTIONS_STEP_DEBUG????

Very likely; it still makes sense to implement runner.debug for ACTIONS_STEP_DEBUG.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants