Setting up PWM on PA.3 of the STM32F091RC Nucleo board
Quite often on dev boards, some pins may be used by other functions on the board, such as a display, buttons, LEDs, etc. There are probably a bunch of solder bridges on the back of the board that serve to disconnect a pin on the microcontroller from the GPIO headers because when they are being used by something else on the board.

Take a look at the user manual and see if PA3 and PA4 are being used for some other function on the board. ST often includes the schematics for the dev board, and it should show the solder bridges on it as well.