studio1902 / statamic-peak

Statamic Peak is an opinionated starter kit for all your Statamic sites.
GNU General Public License v3.0
581 stars 101 forks source link

Fresh Install results in blank page #315

Closed Jigsaw5279 closed 1 year ago

Jigsaw5279 commented 1 year ago

Describe the bug After installing peak through the latest statamic cli or by first installing statamic and then adding peak as a starter kit (clearing the site first), the page remains blank. The basic statamic installation works fine, but as soon as peak is involved no page is rendered. There is no error on the page or in the log, just an emtpy page output. CP works fine.

To Reproduce Steps to reproduce the behavior:

  1. Install Peak via statamic new my-site studio1902/statamic-peak or via php please starter-kit:install studio1902/statamic-peak into a fresh statamic installation
  2. Visit the homepage
  3. The output is completely empty (if I enable the debugbar, the javascript for that is returned, but the page remains blank)

Expected behavior Seeing the default content provided by peak

Additional context PHP Version: 8.1.16 [PHP Modules] apcu bcmath bz2 calendar Core ctype curl date dom exif FFI fileinfo filter ftp gd gettext hash iconv igbinary imagick intl json ldap libxml mbstring memcached msgpack mysqli mysqlnd openssl pcntl pcre PDO pdo_mysql pdo_pgsql pdo_sqlite pgsql Phar posix readline redis Reflection session shmop SimpleXML soap sockets sodium SPL sqlite3 standard sysvmsg sysvsem sysvshm tokenizer uploadprogress xml xmlreader xmlrpc xmlwriter xsl Zend OPcache zip zlib

[Zend Modules] Zend OPcache

composer.json

{
    "name": "statamic/statamic",
    "description": "Statamic",
    "keywords": [
        "statamic",
        "cms",
        "flat file",
        "laravel"
    ],
    "type": "project",
    "require": {
        "php": "^8.0",
        "fruitcake/laravel-cors": "^2.0.5",
        "guzzlehttp/guzzle": "^7.2",
        "laravel/framework": "^9.0",
        "laravel/sanctum": "^2.14",
        "laravel/tinker": "^2.7",
        "spatie/browsershot": "^3.57",
        "statamic/cms": "3.4.*",
        "studio1902/statamic-peak-browser-appearance": "^1.0",
        "studio1902/statamic-peak-commands": "^1.0",
        "studio1902/statamic-peak-seo": "^1.0",
        "studio1902/statamic-peak-tools": "^2.0"
    },
    "require-dev": {
        "barryvdh/laravel-debugbar": "^3.6",
        "fakerphp/faker": "^1.9.1",
        "laravel/sail": "^1.13",
        "mockery/mockery": "^1.4.4",
        "nunomaduro/collision": "^6.1",
        "phpunit/phpunit": "^9.5.10",
        "spatie/laravel-ignition": "^1.0"
    },
    "config": {
        "optimize-autoloader": true,
        "preferred-install": "dist",
        "sort-packages": true,
        "allow-plugins": {
            "composer/package-versions-deprecated": true,
            "pixelfear/composer-dist-plugin": true
        }
    },
    "extra": {
        "laravel": {
            "dont-discover": []
        }
    },
    "autoload": {
        "psr-4": {
            "App\\": "app/",
            "Database\\Factories\\": "database/factories/",
            "Database\\Seeders\\": "database/seeders/"
        }
    },
    "autoload-dev": {
        "psr-4": {
            "Tests\\": "tests/"
        }
    },
    "minimum-stability": "dev",
    "prefer-stable": true,
    "scripts": {
        "pre-update-cmd": [
            "Statamic\\Console\\Composer\\Scripts::preUpdateCmd"
        ],
        "post-autoload-dump": [
            "Illuminate\\Foundation\\ComposerScripts::postAutoloadDump",
            "@php artisan package:discover --ansi",
            "@php artisan statamic:install --ansi"
        ],
        "post-root-package-install": [
            "@php -r \"file_exists('.env') || copy('.env.example', '.env');\""
        ],
        "post-create-project-cmd": [
            "@php artisan key:generate --ansi"
        ],
        "post-update-cmd": [
            "@php artisan vendor:publish --tag=laravel-assets --ansi --force"
        ]
    }
}

composer info output

ajthinking/archetype                        v1.1.5    Programmatically edit PHP and Laravel files.
asm89/stack-cors                            v2.1.1    Cross-origin resource sharing library and stack middleware
barryvdh/laravel-debugbar                   v3.8.1    PHP Debugbar integration for Laravel
brick/math                                  0.11.0    Arbitrary-precision arithmetic library
composer/ca-bundle                          1.3.5     Lets you find a path to the system CA bundle, and includes a fallback to the Mozilla CA bundle.
composer/class-map-generator                1.0.0     Utilities to scan PHP code and generate class maps.
composer/composer                           2.5.5     Composer helps you declare, manage and install dependencies of PHP projects. It ensures you have the right stack everywhere.
composer/metadata-minifier                  1.0.0     Small utility library that handles metadata minification and expansion.
composer/pcre                               3.1.0     PCRE wrapping library that offers type-safe preg_* replacements.
composer/semver                             3.3.2     Semver library that offers utilities, version constraint parsing and validation.
composer/spdx-licenses                      1.5.7     SPDX licenses list and validation library.
composer/xdebug-handler                     3.0.3     Restarts a process without Xdebug.
dflydev/dot-access-data                     v3.0.2    Given a deep data structure, access data by dot notation.
doctrine/inflector                          2.0.6     PHP Doctrine Inflector is a small library that can perform string manipulations with regard to upper/lowercase and singular/plural forms of words.
doctrine/instantiator                       2.0.0     A small, lightweight utility to instantiate objects in PHP without invoking their constructors
doctrine/lexer                              3.0.0     PHP Doctrine Lexer parser library that can be used in Top-Down, Recursive Descent Parsers.
dragonmantank/cron-expression               v3.3.2    CRON for PHP: Calculate the next or previous run date and determine if a CRON expression is due
egulias/email-validator                     4.0.1     A library for validating emails against several RFCs
facade/ignition-contracts                   1.0.2     Solution contracts for Ignition
fakerphp/faker                              v1.21.0   Faker is a PHP library that generates fake data for you.
filp/whoops                                 2.15.2    php error handling for cool kids
fruitcake/laravel-cors                      v2.2.0    Adds CORS (Cross-Origin Resource Sharing) headers support in your Laravel application
fruitcake/php-cors                          v1.2.0    Cross-origin resource sharing library for the Symfony HttpFoundation
graham-campbell/result-type                 v1.1.1    An Implementation Of The Result Type
guzzlehttp/guzzle                           7.5.1     Guzzle is a PHP HTTP client library
guzzlehttp/promises                         1.5.2     Guzzle promises library
guzzlehttp/psr7                             2.5.0     PSR-7 message implementation that also provides common utility methods
guzzlehttp/uri-template                     v1.0.1    A polyfill class for uri_template of PHP
hamcrest/hamcrest-php                       v2.0.1    This is the PHP port of Hamcrest Matchers
intervention/image                          2.7.2     Image handling and manipulation library with support for Laravel integration
james-heinrich/getid3                       v1.9.22   PHP script that extracts useful information from popular multimedia file formats
justinrainbow/json-schema                   5.2.12    A library to validate a json schema.
laragraph/utils                             v1.6.0    Utilities for using GraphQL with Laravel
laravel/framework                           v9.52.7   The Laravel Framework.
laravel/helpers                             v1.6.0    Provides backwards compatibility for helpers in the latest Laravel release.
laravel/sail                                v1.21.5   Docker files for running a basic Laravel application.
laravel/sanctum                             v2.15.1   Laravel Sanctum provides a featherweight authentication system for SPAs and simple APIs.
laravel/serializable-closure                v1.3.0    Laravel Serializable Closure provides an easy and secure way to serialize closures in PHP.
laravel/tinker                              v2.8.1    Powerful REPL for the Laravel framework.
league/commonmark                           2.4.0     Highly-extensible PHP Markdown parser which fully supports the CommonMark spec and GitHub-Flavored Markdown (GFM)
league/config                               v1.2.0    Define configuration arrays with strict schemas and access values with dot notation
league/csv                                  9.9.0     CSV data manipulation made easy in PHP
league/flysystem                            3.15.1    File storage abstraction for PHP
league/flysystem-local                      3.15.0    Local filesystem adapter for Flysystem.
league/glide                                2.2.4     Wonderfully easy on-demand image manipulation library with an HTTP based API.
league/mime-type-detection                  1.11.0    Mime-type detection for Flysystem
maennchen/zipstream-php                     v2.4.0    ZipStream is a library for dynamically streaming dynamic zip files from PHP without writing to the disk at all on the server.
maximebf/debugbar                           v1.18.2   Debug bar in the browser for php application
michelf/php-smartypants                     1.8.1     PHP SmartyPants
mockery/mockery                             1.5.1     Mockery is a simple yet flexible PHP mock object framework
monolog/monolog                             2.9.1     Sends your logs to files, sockets, inboxes, databases and various web services
myclabs/deep-copy                           1.11.1    Create deep copies (clones) of your objects
myclabs/php-enum                            1.8.4     PHP Enum implementation
nesbot/carbon                               2.66.0    An API extension for DateTime that supports 281 different languages.
nette/schema                                v1.2.3    📐 Nette Schema: validating data structures against a given Schema.
nette/utils                                 v4.0.0    🛠  Nette Utils: lightweight utilities for string & array manipulation, image handling, safe JSON encoding/decoding, validation, slug or strong password generating etc.
nikic/php-parser                            v4.15.4   A PHP parser written in PHP
nunomaduro/collision                        v6.4.0    Cli error handling for console/command-line PHP applications.
nunomaduro/termwind                         v1.15.1   Its like Tailwind CSS, but for the console.
phar-io/manifest                            2.0.3     Component for reading phar.io manifest information from a PHP Archive (PHAR)
phar-io/version                             3.2.1     Library for handling version information and constraints
phpoption/phpoption                         1.9.1     Option Type for PHP
phpunit/php-code-coverage                   9.2.26    Library that provides collection, processing, and rendering functionality for PHP code coverage information.
phpunit/php-file-iterator                   3.0.6     FilterIterator implementation that filters files based on a list of suffixes.
phpunit/php-invoker                         3.1.1     Invoke callables with a timeout
phpunit/php-text-template                   2.0.4     Simple template engine.
phpunit/php-timer                           5.0.3     Utility class for timing
phpunit/phpunit                             9.6.7     The PHP Unit Testing framework.
pixelfear/composer-dist-plugin              v0.1.5    Downloads distributable assets to be used in packages so you don't have to commit them.
psr/container                               2.0.2     Common Container Interface (PHP FIG PSR-11)
psr/event-dispatcher                        1.0.0     Standard interfaces for event handling.
psr/http-client                             1.0.2     Common interface for HTTP clients
psr/http-factory                            1.0.2     Common interfaces for PSR-7 HTTP message factories
psr/http-message                            1.1       Common interface for HTTP messages
psr/log                                     3.0.0     Common interface for logging libraries
psr/simple-cache                            3.0.0     Common interfaces for simple caching
psy/psysh                                   v0.11.17  An interactive shell for modern PHP.
ralouphie/getallheaders                     3.0.3     A polyfill for getallheaders.
ramsey/collection                           2.0.0     A PHP library for representing and manipulating collections.
ramsey/uuid                                 4.7.4     A PHP library for generating and working with universally unique identifiers (UUIDs).
react/promise                               v2.10.0   A lightweight implementation of CommonJS Promises/A for PHP
rebing/graphql-laravel                      8.6.0     Laravel wrapper for PHP GraphQL
scrivo/highlight.php                        v9.18.1.9 Server side syntax highlighter that supports 185 languages. It's a PHP port of highlight.js
sebastian/cli-parser                        1.0.1     Library for parsing CLI options
sebastian/code-unit                         1.0.8     Collection of value objects that represent the PHP code units
sebastian/code-unit-reverse-lookup          2.0.3     Looks up which function or method a line of code belongs to
sebastian/comparator                        4.0.8     Provides the functionality to compare PHP values for equality
sebastian/complexity                        2.0.2     Library for calculating the complexity of PHP code units
sebastian/diff                              4.0.4     Diff implementation
sebastian/environment                       5.1.5     Provides functionality to handle HHVM/PHP environments
sebastian/exporter                          4.0.5     Provides the functionality to export PHP variables for visualization
sebastian/global-state                      5.0.5     Snapshotting of global state
sebastian/lines-of-code                     1.0.3     Library for counting the lines of code in PHP source code
sebastian/object-enumerator                 4.0.4     Traverses array structures and object graphs to enumerate all referenced objects
sebastian/object-reflector                  2.0.4     Allows reflection of object attributes, including inherited and non-public ones
sebastian/recursion-context                 4.0.5     Provides functionality to recursively process PHP variables
sebastian/resource-operations               3.0.3     Provides a list of PHP built-in functions that operate on resources
sebastian/type                              3.2.1     Collection of value objects that represent the types of the PHP type system
sebastian/version                           3.0.2     Library that helps with managing the version number of Git-hosted PHP projects
seld/jsonlint                               1.9.0     JSON Linter
seld/phar-utils                             1.2.1     PHAR file format utilities, for when PHP phars you up
seld/signal-handler                         2.0.1     Simple unix signal handler that silently fails where signals are not supported for easy cross-platform development
spatie/backtrace                            1.4.0     A better backtrace
spatie/blink                                1.2.0     Cache that expires in the blink of an eye
spatie/browsershot                          3.57.6    Convert a webpage to an image or pdf using headless Chrome
spatie/flare-client-php                     1.3.6     Send PHP errors to Flare
spatie/ignition                             1.7.0     A beautiful error page for PHP applications.
spatie/image                                2.2.6     Manipulate images with an expressive API
spatie/image-optimizer                      1.6.4     Easily optimize images using PHP
spatie/laravel-ignition                     1.6.4     A beautiful error page for Laravel applications.
spatie/shiki-php                            1.3.0     Highlight code using Shiki in PHP
spatie/temporary-directory                  2.1.2     Easily create, use and destroy temporary directories
statamic/cms                                v3.4.10   The Statamic CMS Core Package
statamic/stringy                            3.1.3     A string manipulation library with multibyte support, forked from @statamic
studio1902/statamic-peak-browser-appearance v1.0     
studio1902/statamic-peak-commands           v1.27    
studio1902/statamic-peak-seo                v1.7     
studio1902/statamic-peak-tools              v2.5     
symfony/console                             v6.2.10   Eases the creation of beautiful and testable command line interfaces
symfony/css-selector                        v6.2.7    Converts CSS selectors to XPath expressions
symfony/deprecation-contracts               v3.2.1    A generic function and convention to trigger deprecation notices
symfony/error-handler                       v6.2.10   Provides tools to manage errors and ease debugging PHP code
symfony/event-dispatcher                    v6.2.8    Provides tools that allow your application components to communicate with each other by dispatching events and listening to them
symfony/event-dispatcher-contracts          v3.2.1    Generic abstractions related to dispatching event
symfony/filesystem                          v6.2.10   Provides basic utilities for the filesystem
symfony/finder                              v6.2.7    Finds files and directories via an intuitive fluent interface
symfony/http-foundation                     v6.2.10   Defines an object-oriented layer for the HTTP specification
symfony/http-kernel                         v6.2.10   Provides a structured process for converting a Request into a Response
symfony/lock                                v5.4.22   Creates and manages locks, a mechanism to provide exclusive access to a shared resource
symfony/mailer                              v6.2.8    Helps sending emails
symfony/mime                                v6.2.10   Allows manipulating MIME messages
symfony/polyfill-ctype                      v1.27.0   Symfony polyfill for ctype functions
symfony/polyfill-intl-grapheme              v1.27.0   Symfony polyfill for intl's grapheme_* functions
symfony/polyfill-intl-idn                   v1.27.0   Symfony polyfill for intl's idn_to_ascii and idn_to_utf8 functions
symfony/polyfill-intl-normalizer            v1.27.0   Symfony polyfill for intl's Normalizer class and related functions
symfony/polyfill-mbstring                   v1.27.0   Symfony polyfill for the Mbstring extension
symfony/polyfill-php72                      v1.27.0   Symfony polyfill backporting some PHP 7.2+ features to lower PHP versions
symfony/polyfill-php73                      v1.27.0   Symfony polyfill backporting some PHP 7.3+ features to lower PHP versions
symfony/polyfill-php80                      v1.27.0   Symfony polyfill backporting some PHP 8.0+ features to lower PHP versions
symfony/polyfill-php81                      v1.27.0   Symfony polyfill backporting some PHP 8.1+ features to lower PHP versions
symfony/polyfill-uuid                       v1.27.0   Symfony polyfill for uuid functions
symfony/process                             v6.2.10   Executes commands in sub-processes
symfony/routing                             v6.2.8    Maps an HTTP request to a set of configuration variables
symfony/service-contracts                   v3.2.1    Generic abstractions related to writing services
symfony/string                              v6.2.8    Provides an object-oriented API to strings and deals with bytes, UTF-8 code points and grapheme clusters in a unified way
symfony/translation                         v6.2.8    Provides tools to internationalize your application
symfony/translation-contracts               v3.2.1    Generic abstractions related to translation
symfony/uid                                 v6.2.7    Provides an object-oriented API to generate and represent UIDs
symfony/var-dumper                          v6.2.10   Provides mechanisms for walking through any arbitrary PHP variable
symfony/var-exporter                        v6.2.10   Allows exporting any serializable PHP data structure to plain PHP code
symfony/yaml                                v6.2.10   Loads and dumps YAML files
thecodingmachine/safe                       v2.5.0    PHP core functions that throw exceptions instead of returning FALSE on error
theseer/tokenizer                           1.2.1     A small library for converting tokenized PHP source code into XML and potentially other formats
tijsverkoyen/css-to-inline-styles           2.2.6     CssToInlineStyles is a class that enables you to convert HTML-pages/files into HTML-pages/files with inline styles. This is very useful when you're sending emails.
ueberdosis/tiptap-php                       1.2.0     A PHP package to work with Tiptap output
vlucas/phpdotenv                            v5.5.0    Loads environment variables from `.env` to `getenv()`, `$_ENV` and `$_SERVER` automagically.
voku/portable-ascii                         2.0.1     Portable ASCII library - performance optimized (ascii) string functions for php.
webmozart/assert                            1.11.0    Assertions to validate method input/output with nice error messages.
webonyx/graphql-php                         v14.11.9  A PHP port of GraphQL reference implementation
wilderborn/partyline                        1.0.2     A Laravel 5 package to output to the console from outside of command classes

Just a few weeks ago I had Peak running in this setup just fine. Now I was starting a new project and it doesn't seem to work anymore

robdekort commented 1 year ago

This is a Statamic bug. If you roll back one version you should be good. https://github.com/statamic/cms/issues/8066

robdekort commented 1 year ago

There’s a fix and release out already for both v3 and v4 beta: https://github.com/statamic/cms/releases/tag/v3.4.11