Script not work in cloudflare/netlify/localhost but work in github pages why?

Github page url: https://flixmu.github.io/json/genre
Cloudflare page url: https://flixmu-github-io.pages.dev/json/genre

{% assign alldocs = site.series | <additional filtering and sorting> %}
{% assign grouptag =  alldocs | map: 'tags' | join: ','  | split: ','  | group_by: tag %}
{%- for tag in grouptag -%}
    <h1>{{- tag.name -}} - {{tag.size}}</h1>
	{%- for document in alldocs -%}
    	{% if document.tags contains tag.name %}
        	 <a href="{{ document.url }}"><p>{{- document.title -}}</p></a>
		 {% endif %}
    {%- endfor -%}
{%- endfor -%}

================By Genre=================
{% assign alldocs = site.series | <additional filtering and sorting> %}
{% assign grouptag =  alldocs | map: 'genre' | join: ','  | split: ','  | group_by: genre %}
{%- for genre in grouptag -%}
    <h1>{{- genre.name -}} - {{genre.size}}</h1>
	{%- for document in alldocs -%}
    	{% if document.genre contains genre.name %}
        	 <a href="{{ document.url }}"><p>{{- document.title -}}</p></a>
		 {% endif %}
    {%- endfor -%}
{%- endfor -%}
================By Studio=================
{% assign alldocs = site.series | <additional filtering and sorting> %}
{% assign grouptag =  alldocs | map: 'studio' | join: ','  | split: ','  | group_by: studio %}
{%- for studio in grouptag -%}
    <h1>{{- studio.name -}} - {{studio.size}}</h1>
	{%- for document in alldocs -%}
    	{% if document.studio contains studio.name %}
        	 <a href="{{ document.url }}"><p>{{- document.title -}}</p></a>
		 {% endif %}
    {%- endfor -%}
{%- endfor -%}

Have you deployed identical code to all environments?

Did you use Jekyll 3.9 in your Gemfile to match GH Pages?

Add some logging to see what is going on for missing attributes

{%- for tag in grouptag -%}
  {{ tag | inspect }}
{% endfor %}

You can also add to config and run locally to force an error on missing attributes