I would say either are good budget guns, but I'd be a bit careful about the Taurus.
First, I am not a Taurus basher. My first handgun was a Taurus 82. Around 20 or so years ago, there was only one dedicated Taurus forum. The admin/management long since drifted away so it was likely a matter of time before it disappeared (being "orphaned," it was likely whomever had paid for the bandwidth and URL would eventually let it lapse). So, back in the MSN Groups days, I started a fan group (Taurus Talk) so us Taurus fans would have a place to talk. Heck, I have had quite a few guns through my hands over the intervening years (some quite nice), and I still have three Taurus handguns (and two Taurus era Rossi revolvers). Two of the Taurus actually work, and one of the Rossi works properly all the time. I will probably be adding another 856 to my lineup soon now that MD is essentially shall issue under Bruen (I have a 2" 856UL, and I want a 3" Defender with night sights).
So, when I say be careful, it is not out of hate for the brand. Test it a little more thoroughly than you would another gun and keep a close eye on it possibly developing issues in the future. I won't automatically say to get something else since 2 Taurus G2 or G3s will run about the price of one Glock or S&W M&P (and your chances of getting two bad ones are pretty low). Just keep an eye out for trouble.
The Ruger should be a good gun. Overall, they are reliable (though I have had two duds- a P89 in the 90s was reliable but not accurate, a P345 was accurate but not reliable, but the overall reputation is good, and my LCP is great).
If you can go up on the budget, a Glock, S&W or similar will probably be better than both. If you can't, but want to broaden your options, I liked my Bersa Thunder .380 I had years ago, and their 9mms seem to be relatively well liked.