Unable to update XBackBone
System Info
- PHP Version: 8.0.7
- XBackBone Version: 3.3.5
- Webserver: [Apache/Nginx/...] Apache
- Database backend: [SQLite/Mysql/...] sqlite
Describe the bug A clear and concise description of what the bug is.
Cannot update XBackBone due to "Cannot contact GitHub API. Try again."
Not sure if this is a me issue (not sure how to check/troubleshoot) or if it's an issue with something else
To Reproduce Steps to reproduce the behavior:
- have my setup above
- go to updates
- try updating
- See error (and cry)
Expected behavior XBackBone upgrades to whatever the latest version is
Screenshots
https://voided.dev/cdn/POWA6/zALopoyE74.png
Logs where can i find these?
Help appreciated. Even if I have to update everything manually (somehow) some help with that would be much appreciated as well. :)
System Info
- PHP Version: 8.0.7
- XBackBone Version: 3.3.5
- Webserver: [Apache/Nginx/...] Apache
- Database backend: [SQLite/Mysql/...] sqlite
Describe the bug A clear and concise description of what the bug is.
Cannot update XBackBone due to "Cannot contact GitHub API. Try again."
Not sure if this is a me issue (not sure how to check/troubleshoot) or if it's an issue with something else
To Reproduce Steps to reproduce the behavior:
- have my setup above
- go to updates
- try updating
- See error (and cry)
Expected behavior XBackBone upgrades to whatever the latest version is
Screenshots
https://voided.dev/cdn/POWA6/zALopoyE74.png
Logs where can i find these?
Help appreciated. Even if I have to update everything manually (somehow) some help with that would be much appreciated as well. :)
I was able to fix my issue by manually upgrading but I still can't upgrade with the built in upgrade function and it's frustrating. Not sure how to fix.
If you perform this curl from your host the request is successful?
curl -A "XBackBone-App" -H "Accept: application/vnd.github.v3+json" https://api.github.com/repos/SergiX44/XBackBone/releases
If you perform this curl from your host the request is successful?
curl -A "XBackBone-App" -H "Accept: application/vnd.github.v3+json" https://api.github.com/repos/SergiX44/XBackBone/releases
Yeah it prints the json file to the console i think. Also, for some reason the themes are not loading now and i'm stuck with the light theme.
Mm probably there is an issue for your php installation to contact external http resources
<?php
$opts = [
'http' => [
'method' => 'GET',
'header' => [
'User-Agent: XBackBone-App',
'Accept: application/vnd.github.v3+json',
],
],
];
$data = file_get_contents('https://api.github.com/repos/SergiX44/XBackBone/releases', false, stream_context_create($opts));
echo $data;
Can you try to run this script?
Mm probably there is an issue for your php installation to contact external http resources
<?php $opts = [ 'http' => [ 'method' => 'GET', 'header' => [ 'User-Agent: XBackBone-App', 'Accept: application/vnd.github.v3+json', ], ], ]; $data = file_get_contents('https://api.github.com/repos/SergiX44/XBackBone/releases', false, stream_context_create($opts)); echo $data;Can you try to run this script?
No output.
Check that your php installation ~has php-stream~(should be part of the phpcore now) and allow_url_fopen enabled https://www.php.net/manual/en/filesystem.configuration.php#ini.allow-url-fopen
allow_url_fopn is enabled
same issue php 7.3
There is something that blocks access to external urls from php, is not an xbackbone bug. This is the same script as before with some error logging forced:
<?php
ini_set('display_errors', 1);
ini_set('display_startup_errors', 1);
error_reporting(E_ALL);
$opts = [
'http' => [
'method' => 'GET',
'header' => [
'User-Agent: XBackBone-App',
'Accept: application/vnd.github.v3+json',
],
],
];
$data = file_get_contents('https://api.github.com/repos/SergiX44/XBackBone/releases', false, stream_context_create($opts));
var_dump($data);
Should print something like string (... some the the json you can get from the curl command i posted before:
string(96877) "[{"url":"https://api.github.com/repos/SergiX44/XBackBone/releases/47757778","assets_url":"https://api.github.com/repos/SergiX44/XBackBone/releases/47757778/assets","upload_url":"https://uploads.github.com/repos/SergiX44/XBackBone/releases/47757778/assets{?name,label}","html_url":"https://github.com/SergiX44/XBackBone/releases/tag/3.4.1","id":47757778,"author":{"login":"SergiX44","id":4172890,"node_id":"MDQ6VXNlcjQxNzI4OTA=","avatar_url":"https://avatars.githubusercontent.com/u/4172890?v=4","gravatar_id":"","...
If you perform this curl from your host the request is successful?
curl -A "XBackBone-App" -H "Accept: application/vnd.github.v3+json" https://api.github.com/repos/SergiX44/XBackBone/releases
Fixed it. I had to uncomment extension=openssl in my php.ini config. Updates work now and themes are loading too. Thank you for your help, I was able to get a more descriptive error about something HTTPS related that helped me pinpoint the problem. Love your work, have a good one!
worked for me too however "extension=openssl" wasn't already there so instead of uncommenting it i had to manually add it, make sure you restart your php after as well
edit:
actually this didn't fix it, in my cpanel i had to switch from "ea-php" to "alt-php" which then used my php selector settings rather than default php settings where allow_url_fopen was enabled
