Kirby builder: Cannot use a scalar value as an array

I tried to integrate the kirby-builder plugin, but during page creation it gives my this error

Cannot use a scalar value as an array

Any advice for this issue?

Could you please provide more information? Where does the error appear, in the Panel or on the frontend?

Panel: please post blueprint
Frontend: please post code

Is there a stack trace for the error?

Also, which versions of builder and Kirby?

I used the given example from the builder repo. The error appears in the backend when I try to create a page.

title: Builder
icon: 📝
preset: page

fields:
  mybuilder:
  label: Page Builder
  type: builder
  columns: 1
  max: 10
  fieldsets:
    quote:
      label: Quote
      preview:
        snippet: blocks/quote
        css: /assets/css/blocks/quote.css
      fields:
        text:
          label: Quote Text
          type: textarea
        citation:
          label: Citation
          type: text
    bodytext:
      label: Text
      tabs:
        content:
          label: Content
          icon: edit
          fields:
            text:
              label: text
              type: textarea
        style:
          label: Style
          icon: cog
          fields:
            fontfamily:
              label: Font
              type: select
              options:
                helvetica: Helvetica
                comicsans: Comic Sans
            fontsize:
              label: Font Size
              type: number
    events:
      label: Events
      preview:
        snippet: blocks/events
        css: /assets/css/blocks/events.css
      fields:
        eventlist:
          type: builder
          label: Event List
          columns: 2
          fieldsets:
            event:
              label: Event
              fields:
                title:
                  label: Title
                  type: text
                text:
                  label: Description
                  type: textarea
                date:
                  label: Date
                  type: date
    calltoaction:
      extends: blocks/calltoaction

Looks like it’s caused by these two settings:

columns: 1
max: 10

You are right. The page can be created when I remove those lines.
Thank you for your help :slight_smile:

It’s not really a solution but a workaround. Not sure if that’s a bug in the plugin or somewhere else.

I’m opening an issue for the builder. Maybe the author knows what has happened.

I just saw an error like this yesterday when editing blueprints. I found my error.
But, perhaps a more descriptive error message would help.