"Region extends beyond the horizon" error depending on map width

I’m trying to create a map of North America using the Lambert Azimuthal projection. Using this one liner works and gives the image shown below:
gmt coast -R-140.0/-1.0/2.0/53.0r -JA-100.0/45.0/5i -Gblue -png test5

I want to produce a larger image, though. I’m using basically the same command (width is now 6i instead of 5i):
gmt coast -R-140.0/-1.0/2.0/53.0r -JA-100.0/45.0/6i -Gblue -png test6

But now I get this error messages:

coast [ERROR]: Rectangular region for azimuthal projection extends beyond the horizon
coast [ERROR]: Please select a region that is completely within the visible hemisphere
coast [ERROR]: General map projection error

I don’t understand how changing the scale of a map can lead to this kind of projection error.

To be sure that providing a different width in the command doesn’t change the plotted map region, I made maps for the widths 2i, 3i, 4i and 5i and resized them to the same pixel size. Overlaying those maps made it obvious that the plotted region did not change.

Some additional notes:

  1. I see the same behavior when using gmt grdimage:
    gmt grdimage @earth_relief_03m -R-145.0/-5.0/2.0/53.0r -JA-100.0/45.0/5i -png test-grd works, but the very same command with 6i doesn’t.
  2. When reducing the plotted area to -140.0/2.0/-10.0/53.0 I can create even huge maps. 30i was the largest I tried and it worked.
  3. Changing the projection center to anything reasonable within the map area did not help.

Version: GMT 6.4.0 on macOS Ventura 13.4

It is some sort of round-off. Will look when not so busy. Noticed that for your -R we can work around this test by changing the step:

gmt coast -R-140.0/-1.0/2.0/53.0+r -JA-100.0/45.0/30i -Gblue -png test6 --MAP_LINE_STEP=4p

We go around the rectangular border in map-line-step and gets the corresponding lon/lat and compute distance from origin. If over 90 then bam.

Wow, thank you, that’s extremely helpful! Using MAP_LINE_STEP removes the error.