No need for JOIN LATERAL
(or do you really just want to use it?); try
UPDATE gps
SET stop_id = (
SELECT stop_id
FROM stops
ORDER BY gps.geom <-> stops.geom
LIMIT 1
);
No need for JOIN LATERAL
(or do you really just want to use it?); try
UPDATE gps
SET stop_id = (
SELECT stop_id
FROM stops
ORDER BY gps.geom <-> stops.geom
LIMIT 1
);