It’s not a risk-free trade. Borrowing yen and buying dollars is effectively shorting the yen (relative to the US dollar). The investors who did this before made money because the yen dropped, but maybe they will want to take profits, which would tend to strengthen the yen.
Borrowing yen now to buy dollars is sort of like shorting a stock when the price already dropped. The interest rate difference makes it a cheaper bet, but it’s still a bet and could go bad if the yen strengthens.
In the early 1980s, a couple of Australian banks took advantage of very low Swiss interest rates to offer a series of apparently cheap loans to small businesses and farmers, with the catch being that the loans were of course denominated in Swiss francs.
Within a few years, those borrowers (whose income was naturally denominated in Australian dollars) got a very painful lesson in that risk, when the exchange rate between the Australian dollar and the Swiss franc moved significantly, putting them very much underwater on those loans.
(This became known as the "Swiss loans affair", with allegations that the banks in question had in many cases not adequately informed the borrowers of the risk).
Borrowing yen now to buy dollars is sort of like shorting a stock when the price already dropped. The interest rate difference makes it a cheaper bet, but it’s still a bet and could go bad if the yen strengthens.