Black screen when I try to exit the screensaver

When I want to activate my app, after exits the screen saver, the password input interface is not displayed on Monterey.

I use apple script to exit screen saver: osascript -e 'tell application "ScreenSaverEngine" to quit'

What can I do to exit the screen saver and display the enter password screen?

thanks,

Black screen when I try to exit the screensaver
 
 
Q