Cherrypick de los commits 34cf15e6fd8cda76b8e31ca624b9028d4508865a y 7a186c57d65b00b925bec8ddbba33cea8f7782d3