Help fixing unknown issue with Nvidia drivers

So I have a laptop with and intel cpu and an nvidia graphics card. I have set up optimus-manager, and it seems to wok fine while using the intel iGPU, but I can’t seem to switch to the nvidia GPU without my screen going black. I do not use a display manager and am making sure to run both prime-switch and prime-offload at the appropriate times.

Some useful information:

The output to inxi -G is:

Graphics:  Device-1: Intel CometLake-U GT2 [UHD Graphics] driver: i915 v: kernel 
           Device-2: NVIDIA GP108M [GeForce MX250] driver: N/A 
           Device-3: Lite-On Integrated Camera type: USB driver: uvcvideo 
           Display: server: X .Org 1.20.11 driver: loaded: intel resolution: 1920x1080~60Hz 
           OpenGL: renderer: Mesa Intel UHD Graphics (CML GT2) v: 4.6 Mesa 21.1.2 

The output to mhwd -li is:

 Installed PCI configs:
                  NAME               VERSION          FREEDRIVER           TYPE
     video-modesetting            2020.01.13                true            PCI
           video-linux            2018.05.04                true            PCI
video-hybrid-intel-nvidia-prime            2020.11.30               false            PCI

I would appreciate any help in figuring out why this is happening, and I understand that I may not have provided adequate information, but please let me know what other things you need to know.

  1. What does prime-run nvidia-smi giva as output?
  2. What’s the output of glx-info | grep vendor give?

P.S. For the future, it’s better to include a full inxi --admin --verbosity=7 --filter --no-host --width instead of just the graphics, so we know what DE, kernel, … you have.