opencaching / okapi

A common API for all National Opencaching.XX sites
22 stars 19 forks source link

OKAPI Method Error - MainMapAjax #613

Closed andrixnet closed 2 years ago

andrixnet commented 2 years ago

I receivr many error notifications like this:

OKAPI caught the following exception while executing API method request.
This is an error in OUR code and should be fixed. Please contact the
developer of the module that threw this error. Thanks!

===== ERROR MESSAGE =====
ErrorException:
imagettfbbox(): Problem doing text layout
=========================

--- Stack trace ---
#0 [internal function]: okapi\core\OkapiErrorHandler::handle()
#1 /serve/www/oc_us/oc/okapi/services/caches/map/TileRenderer.php(315): imagettfbbox()
#2 /serve/www/oc_us/oc/okapi/services/caches/map/TileRenderer.php(372): okapi\services\caches\map\TileRenderer::wordwrap()
#3 /serve/www/oc_us/oc/okapi/services/caches/map/TileRenderer.php(195): okapi\services\caches\map\TileRenderer->get_caption()
#4 /serve/www/oc_us/oc/okapi/services/caches/map/TileRenderer.php(92): okapi\services\caches\map\TileRenderer->draw_cache()
#5 /serve/www/oc_us/oc/okapi/services/caches/map/tile/WebService.php(243): okapi\services\caches\map\TileRenderer->render()
#6 [internal function]: okapi\services\caches\map\tile\WebService::call()
#7 /serve/www/oc_us/oc/okapi/core/OkapiServiceRunner.php(142): call_user_func()
#8 /serve/www/oc_us/oc/okapi/Facade.php(100): okapi\core\OkapiServiceRunner::call()
#9 /serve/www/oc_us/oc/src/Controllers/MainMapAjaxController.php(129): okapi\Facade::service_display()
#10 [internal function]: src\Controllers\MainMapAjaxController->getMapTile()
#11 /serve/www/oc_us/oc/src/Utils/Uri/SimpleRouter.php(151): call_user_func_array()
#12 /serve/www/oc_us/oc/public/index.php(8): src\Utils\Uri\SimpleRouter::run()
#13 {main}

--- OKAPI method called ---
/MainMapAjax/getMapTile/162/365/10/C9B7FF03-FBA4-1C12-9101-93CE91C2C152
?exIgnored
&exFound
&exTempUnavail
&exArchived
&rating=1-5|X
&size2=any

--- OKAPI version ---
1943 (f504b11300375ce86b156d4655cc36fc31084235)

--- Request headers ---
Host: www.opencaching.us
Accept: image/webp,image/png,image/svg+xml,image/*;q=0.8,video/*;q=0.8,*/*;q=0.5
Connection: keep-alive
Cookie: oc-userData=eyJsYW5nIjoiZW4iLCJsYXN0cXVlcnlpZCI6IjQzMTkwMjYiLCJOQ1NlYXJjaDMiOiIxIiwiTkNTZWFyY2g2IjoiMSIsIk5DU2VhcmNoNyI6IjEiLCJOQ1NlYXJjaDgiOiIxIiwiTkNTZWFyY2g5IjoiMSIsIk5DU2VhcmNoMTIiOiIxIiwiTkNTZWFyY2gxMyI6IjEiLCJOQ1NlYXJjaDE0IjoiMSIsIk5DU2VhcmNoMTUiOiIxIiwiTkNTZWFyY2gxNiI6IjEiLCJOQ1NlYXJjaDE3IjoiMSIsIk5yQ29sdW1uc1NvcnRTZWFyY2giOiItMSIsIk9yZGVyU29ydFNlYXJjaCI6Ik0iLCJEZWZDb2w0U2VhcmNoIjoiWSJ9; cookies_accepted=T; oc_auth=7303977f-2608-11ec-b729-005056aab698; PHPSESSID=qr3r021c6iki10p5vk8r66bsof
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_6) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/14.1.2 Safari/605.1.15
Accept-Language: en-us
Referer: https://www.opencaching.us/MainMap/fullscreen
Accept-Encoding: gzip, deflate, br

please help solving them

deg-pl commented 2 years ago

@andrixnet Check if you use latest version of libgd3.

deg-pl commented 2 years ago

@andrixnet There was an error in early 2.3.0 version of libgd3 - see https://github.com/libgd/libgd/issues/615 On OC PL and OC UK we have 2.3.0-2 version and all works OK. On OC PL we had the same problem in May 2020. First I done downgrade of libgd3 to version 2.2.5. Next (some months later) I upgraded to 2.3.0-2 and all works fine.

andrixnet commented 2 years ago

I upgraded OCRO, OCNL, OCUS to libgd-2.3.3. hope it will be fixed. Thank you.