Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Cannot select asset container #7262

Closed
zsoltjanes opened this issue Dec 21, 2022 · 6 comments · Fixed by #8349
Closed

Cannot select asset container #7262

zsoltjanes opened this issue Dec 21, 2022 · 6 comments · Fixed by #8349

Comments

@zsoltjanes
Copy link
Contributor

Bug description

After a fresh Statamic install I want to make a blueprint with assets and in Container I can not select existing containers.
Screenshot_5

How to reproduce

Just install a new fresh Statamic site and try to make a blueprint with asset.

Logs

No response

Environment

Environment
Application Name: Statamic
Laravel Version: 9.45.0   
PHP Version: 8.1.0        
Composer Version: 2.5.0   
Config: NOT CACHED
Events: NOT CACHED
Routes: NOT CACHED
Views: CACHED

Drivers
Broadcasting: log
Cache: statamic
Database: mysql
Logs: stack / single
Mail: smtp
Queue: sync
Session: file

Statamic
Addons: 0
Antlers: regex
Stache Watcher: Enabled
Static Caching: Disabled
Version: 3.3.62 Solo

Installation

Fresh statamic/statamic site via CLI

Antlers Parser

None

Additional details

No response

@justkidding96
Copy link
Contributor

@duncanmcclean After seeing the error in the provided image, I realized that this is the same error I also have. See #7263 I think this error caused by this line of code:

$config = json_decode(mb_convert_encoding(base64_decode($request->config), 'UTF-8', mb_list_encodings()), true);

When debugging this line of code while removing mb_convert_encoding it is working now. So like this:

$config = json_decode(base64_decode($request->config), true);

@zsoltjanes
Copy link
Contributor Author

Yep, the $config is null, if I remove the mb_convert_encoding and the mb_list_encodings part its working well.

@justkidding96
Copy link
Contributor

@jasonvarga Can you please look into it? I experience this problem on multiple sites now.

@justkidding96
Copy link
Contributor

justkidding96 commented Dec 23, 2022

@jasonvarga I Searched in the repo why some people has this issue. Turn out it related to PHP 8.1.0 see: #6823 (comment) for reference. I've created a pull request for this issue specific see here: #7269

@zsoltjanes
Copy link
Contributor Author

You can modify the yml manually so it will be a workaround till this bug is not fixed.

@zsoltjanes
Copy link
Contributor Author

Since it's still a problem for me, I look deeper into it. I found this: php/php-src#7898
It's an issue in PHP 8.1.1 version.

# for free to join this conversation on GitHub. Already have an account? # to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants