Can someone explain what the risks are of taking a job like this?
In broad terms, a grant-funded position means there is money allocated for X years to fund you. Usually, grants aren't terminated abruptly, although the current US administration is doing so. However, without executive interference, these grants don't usually evaporate without warning.
That is, when you are hired, you'll likely be told that there are two years on this grant, and there should be a long horizon. No competent PI would hide the date the grant ends from you.
What kinds of questions should one ask in order to find out more about the risk?
Nowadays: Have grants in this area been terminated recently?
In normal times:
Who is the funder?
How long does this position have funding for? What happens to the position when that funding runs out? Will this grant be renewed?
What happens to the position if the funder decreases the award or cuts the grant entirely, are there alternative sources of funds to complete the project?
After this project is over, could I possibly continue on new grants? Are there internal funding opportunities to stay past the funded period?
It is not rude to ask about funding, people understand that you need money to live.