Creating a bug report/issue
Required Information
- DietPi version |
9.11 RC2 master/MichaIng
- Distro version |
bookworm 0
- Kernel version |
Linux coriovallum 6.12.20+rpt-rpi-v8 #1 SMP PREEMPT Debian 1:6.12.20-1+rpt1~bpo12+1 (2025-03-19) aarch64 GNU/Linux
- SBC model |
RPi 4 Model B (aarch64) 4Gb
- Power supply used |
- SD card used |
Samsung Evo Endurance 128 Gb
Additional Information (if applicable)
- I replicated this issue on 2 other machines with DietPi 9.11RC2 (1x RPi4B/4Gb, 1x Intel x86 machine)
Steps to reproduce
- Open a bash shell into a non-root account
- Check that all works fine by giving some random commands
- Provide this command:
if [[ ]]; then echo true; else echo false; fi
- Observe error messages printed after each subsequent command
-bash: PROMPT_COMMAND: line 38: syntax error near unexpected token `-w'
-bash: PROMPT_COMMAND: line 38: `[[ -w '/tmp/dietpi-process.pid' ]] && rm -f /tmp/dietpi-process.pid &> /dev/null && echo -ne '\r\e[J'; '
- Log out, log in, repeat steps 2-4 to replicate the issue
- To stop seeing the issue within the same shell (without logging out), type any text and then interrupt with
CTRL-C before pressing the <Return key
Expected behaviour
- Command should return within the expected behavior of bash without any subsequent issues
Actual behaviour
- After each subsequent command, the error message (see below) is printed
- After waiting for some time, the error message is no longer printed after a command
Extra details
See this sequence:
pi@coriovallum:~$ echo hello
hello
pi@coriovallum:~$ echo this is a test
this is a test
pi@coriovallum:~$ if [[ ]]; then echo true; else echo false; fi
-bash: PROMPT_COMMAND: line 37: syntax error near unexpected token `-w'
-bash: PROMPT_COMMAND: line 37: `[[ -w '/tmp/dietpi-process.pid' ]] && rm -f /tmp/dietpi-process.pid &> /dev/null && echo -ne '\r\e[J'; '
pi@coriovallum:~$ echo hello
hello
-bash: PROMPT_COMMAND: line 38: syntax error near unexpected token `-w'
-bash: PROMPT_COMMAND: line 38: `[[ -w '/tmp/dietpi-process.pid' ]] && rm -f /tmp/dietpi-process.pid &> /dev/null && echo -ne '\r\e[J'; '
pi@coriovallum:~$ echo this is a test
this is a test
-bash: PROMPT_COMMAND: line 39: syntax error near unexpected token `-w'
-bash: PROMPT_COMMAND: line 39: `[[ -w '/tmp/dietpi-process.pid' ]] && rm -f /tmp/dietpi-process.pid &> /dev/null && echo -ne '\r\e[J'; '
pi@coriovallum:~$ some-random-text^C
pi@coriovallum:~$ echo hello this is a test
hello this is a test
pi@coriovallum:~$
Creating a bug report/issue
Required Information
9.11 RC2 master/MichaIngbookworm 0Linux coriovallum 6.12.20+rpt-rpi-v8 #1 SMP PREEMPT Debian 1:6.12.20-1+rpt1~bpo12+1 (2025-03-19) aarch64 GNU/LinuxRPi 4 Model B (aarch64) 4GbSamsung Evo Endurance 128 GbAdditional Information (if applicable)
Steps to reproduce
if [[ ]]; then echo true; else echo false; fiCTRL-Cbefore pressing the <ReturnkeyExpected behaviour
Actual behaviour
Extra details
See this sequence: