Guerra had an 0-0 record with an 8.64 ERA in eight appearances with the Brewers this season. He was designated for assignment one day after he allowed five runs over 1 2/3 innings in a 12-5 loss to the Boston Red Sox.
The trade returns Guerra to the Rays, with whom he went 2-1 with a 3.38 ERA in 17 appearances last season.
Tampa Bay had traded Guerra to Milwaukee last November for what was announced at the time as a player to be named later. Milwaukee completed that trade by sending minor league pitcher Victor Castaneda to the Rays last month.
Guerra has a 3-1 career record with a 6.92 ERA and 36 strikeouts over 52 innings in 52 career appearances. He began his career with the San Diego Padres in 2019. The Rays acquired him from the Padres for cash in April 2022.