Since pwgen is supposed to be in the oss repo,
I wonder if there is something amiss on your machine, it’s one thing for the package not found, it’s another thing not to even be able to find the package… and this is aside from your having a problem updating your oss-update repo.
One gotcha you might have is that prior to 15.1, you may have disabled your install source (which would also have been your original oss repo) but never enabled your online oss (you almost absolutely need this if you disable your original install source). With 15.1, this little maneuver is done automatically.
Post your repository list with URLs so your repos can be checked and verified. You should see minimally 4 enabled repos… oss, oss-update, non-oss, non-oss-update
zypper lr -d
Then forcibly try to refresh your repos, if any fail you should see a reason for the failure like a bad network connection, bad location, etc
If the above succeed, then your problems likely resolved on their own and you should now be able to search for pwgen, the following is from the command line instead of using YaST (no difference which you choose)
zypper se pwgen
And, if your system can find a package, then you should be able to install it