Skip to content

False positive Antlers logging #13996

@edalzell

Description

@edalzell

Bug description

On one site we have 2 fields that consistently produce debug error messages:

[2026-02-18 11:56:45] production.DEBUG: Cannot render an array variable as a string: {{ view_all_link }} {"line":8,"file":"/home/forge/alaskapac.org/resources/views/livewire/centertix-events.antlers.html"} 
[2026-02-18 11:56:46] production.DEBUG: Cannot render an array variable as a string: {{ heading }} {"line":7,"file":"/home/forge/alaskapac.org/resources/views/livewire/centertix-events.antlers.html"} 

view_all_link is a Link field and heading is a Select field.

I believe the issue comes from this code in NodeProcessor.php:

if ($this->isInterpolationProcessor == false && $this->isLoopable($value) && $node->isClosedBy == null) {
            if ($this->shouldReportArrayToStringWarning()) {
                $varName = $node->name->getContent();
                Log::debug("Cannot render an array variable as a string: {{ {$varName} }}", $this->getErrorLogContext($node));
            }

I believe that the Link and Select field return true from isLoopable and therefore an error is logged even though nothing is actually wrong.

How to reproduce

Can't reproduce this locally, sorry.

Logs

[2026-02-18 11:49:08] production.DEBUG: Cannot render an array variable as a string: {{ view_all_link }} {"line":14,"file":"/home/forge/alaskapac.org/resources/views/livewire/centertix-events.antlers.html"} 
[2026-02-18 11:54:14] production.DEBUG: Cannot render an array variable as a string: {{ view_all_link }} {"line":14,"file":"/home/forge/alaskapac.org/resources/views/livewire/centertix-events.antlers.html"} 
[2026-02-18 11:56:44] production.DEBUG: Cannot render an array variable as a string: {{ view_all_link }} {"line":8,"file":"/home/forge/alaskapac.org/resources/views/livewire/centertix-events.antlers.html"} 
[2026-02-18 11:56:45] production.DEBUG: Cannot render an array variable as a string: {{ view_all_link }} {"line":8,"file":"/home/forge/alaskapac.org/resources/views/livewire/centertix-events.antlers.html"} 
[2026-02-18 11:56:46] production.DEBUG: Cannot render an array variable as a string: {{ heading }} {"line":7,"file":"/home/forge/alaskapac.org/resources/views/livewire/centertix-events.antlers.html"}

Environment

Environment
Application Name: Alaska PAC
Laravel Version: 11.48.0
PHP Version: 8.3.30
Composer Version: 2.9.3
Environment: local
Debug Mode: ENABLED
URL: alaskapac.test
Maintenance Mode: OFF
Timezone: America/Los_Angeles
Locale: en

Cache
Config: NOT CACHED
Events: NOT CACHED
Routes: NOT CACHED
Views: CACHED

Drivers
Broadcasting: null
Cache: redis
Database: mysql
Logs: stack / daily
Mail: smtp
Queue: redis
Session: file

Livewire
Livewire: v3.7.10

Statamic
Addons: 12
Sites: 2 (AlaskaPAC, CenterTix)
Stache Watcher: Enabled
Static Caching: Disabled
Version: 5.73.9 PRO

Statamic Addons
aryehraber/statamic-captcha: 1.16.0
edalzell/forma: 3.1.2
jacksleight/statamic-bard-mutator: 2.3.1
jacksleight/statamic-distill: 1.1.1
jonassiewertsen/statamic-external-link: 1.9.0
marcorieser/statamic-livewire: 4.5.3
statamic-rad-pack/typesense: 2.4.0
statamic/seo-pro: 6.11.7
transformstudios/events: 5.8.3
transformstudios/front: 3.1.2
transformstudios/review: 5.2.0
transformstudios/simple: 5.41.2

Installation

Fresh statamic/statamic site via CLI

Additional details

No response

Metadata

Metadata

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions