Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

php xcat update升级后出错,不知怎么弄 #824

Closed
6 tasks
zzisk opened this issue Sep 30, 2019 · 9 comments
Closed
6 tasks

php xcat update升级后出错,不知怎么弄 #824

zzisk opened this issue Sep 30, 2019 · 9 comments

Comments

@zzisk
Copy link

zzisk commented Sep 30, 2019

我确认我已经阅读了 (使用 "x" 选择)

我确认我做到了 (使用 "x" 选择)

我正在申请 (使用 "x" 选择)

  • 反馈一个 bug
  • 申请添加新的特性或功能或者好的想法

使用的是宝塔web面板6.9.9 php7.2 mysql 5.7.26 以下为报错内容
Fatal error: Uncaught InvalidArgumentException: Unsupported driver [] in /www/wwwroot/re/vendor/illuminate/database/Connectors/ConnectionFactory.php:226 Stack trace: #0 /www/wwwroot/re/vendor/illuminate/database/Connectors/ConnectionFactory.php(64): Illuminate\Database\Connectors\ConnectionFactory->createConnection(NULL, Object(Closure), NULL, '', Array) #1 /www/wwwroot/re/vendor/illuminate/database/Connectors/ConnectionFactory.php(49): Illuminate\Database\Connectors\ConnectionFactory->createSingleConnection(Array) #2 /www/wwwroot/re/vendor/illuminate/database/DatabaseManager.php(176): Illuminate\Database\Connectors\ConnectionFactory->make(Array, 'default') #3 /www/wwwroot/re/vendor/illuminate/database/DatabaseManager.php(68): Illuminate\Database\DatabaseManager->makeConnection('default') #4 /www/wwwroot/re/app/Services/Boot.php(37): Illuminate\Database\DatabaseManager->connection('default') #5 /www/wwwroot/re/bootstrap.php(28): App\Services\Boot::bootDb() #6 /www/wwwroot/re/public/index.php(7): require('/www/wwwroot/re.. in /www/wwwroot/re/vendor/illuminate/database/Connectors/ConnectionFactory.php on line 226

@Anankke
Copy link
Owner

Anankke commented Sep 30, 2019

这个东西已经爆炸了(悲)

@zzisk
Copy link
Author

zzisk commented Oct 1, 2019

恢复再次升级,同样的错误,没法升级了吗

Fetching origin
remote: Enumerating objects: 353, done.
remote: Counting objects: 100% (353/353), done.
remote: Compressing objects: 100% (3/3), done.
remote: Total 802 (delta 350), reused 350 (delta 350), pack-reused 449
Receiving objects: 100% (802/802), 332.59 KiB | 0 bytes/s, done.
Resolving deltas: 100% (536/536), completed with 127 local objects.
From https://github.com/Anankke/SSPanel-Uim
ee5adec..576e9e5 dev -> origin/dev
5e589dd..3913d09 feat/api -> origin/feat/api
e827700..f9284e6 master -> origin/master

  • [new branch] tutorial-to-markdown -> origin/tutorial-to-markdown
  • [new tag] 2019.07 -> 2019.07
  • [new tag] 2019Sep -> 2019Sep
  • [new tag] v3.0.0 -> v3.0.0
  • [new tag] 2019.08 -> 2019.08
    root@instance-re:/www/wwwroot/re# git reset --hard origin/master
    HEAD is now at f9284e6 September update
    root@instance-re:/www/wwwroot/re# git pull
    Auto-merging config/routes.php
    Merge made by the 'recursive' strategy.
    README.md | 6 +-
    app/Controllers/AdminController.php | 27 ++++++
    app/Controllers/Client/ClientApiController.php | 8 +-
    app/Models/User.php | 102 +++++++++++++++++----
    app/Services/Config.php | 15 +---
    composer.json | 76 +++++++---------
    config/.config.example.php | 400 +++++++++++++++++++++++++++++++++++++++++-----------------------------------------
    config/routes.php | 3 +-
    resources/views/material/admin/code/index.tpl | 7 ++
    resources/views/material/admin/invite.tpl | 54 ++++++++++-
    resources/views/material/admin/user/index.tpl | 5 +-
    resources/views/material/user/disable.tpl | 5 +-
    resources/views/material/user/index.tpl | 33 -------
    resources/views/material/user/main.tpl | 5 +-
    resources/views/material/user/nodeinfo.tpl | 11 +++
    test/config.php | 392 ++++++++++++++++++++++++++++++++++++++++----------------------------------------
    16 files changed, 630 insertions(+), 519 deletions(-)
    root@instance-re:/www/wwwroot/re# php xcat update
    PHP Fatal error: Uncaught InvalidArgumentException: Unsupported driver [] in /www/wwwroot/re/vendor/illuminate/database/Connectors/ConnectionFactory.php:226
    Stack trace:
    #0 /www/wwwroot/re/vendor/illuminate/database/Connectors/ConnectionFactory.php(64): Illuminate\Database\Connectors\ConnectionFactory->createConnection(NULL, Object(Closure), NULL, '', Array)
    加入易付通支付 #1 /www/wwwroot/re/vendor/illuminate/database/Connectors/ConnectionFactory.php(49): Illuminate\Database\Connectors\ConnectionFactory->createSingleConnection(Array)
    更新订阅失效的Cloudflare具体配置 #2 /www/wwwroot/re/vendor/illuminate/database/DatabaseManager.php(176): Illuminate\Database\Connectors\ConnectionFactory->make(Array, 'default')
    为何是不是圆角 #3 /www/wwwroot/re/vendor/illuminate/database/DatabaseManager.php(68): Illuminate\Database\DatabaseManager->makeConnection('default')
    单端口多用户配置出问题 #4 /www/wwwroot/re/app/Services/Boot.php(37): Illuminate\Database\DatabaseManager->connection('default')
    请问,用户界面右下角的按钮是啥?如何删除? #5 /www/wwwroot/re/bootstrap.php(28): App\Services\Boot::bootDb()
    小bug修复 #6 /www/wwwroot/re/xcat(4): require('/www/wwwroot/re...')
    Dev #7 {main in /www/wwwroot/re/vendor/illuminate/database/Connectors/ConnectionFactory.php on line 226

Fatal error: Uncaught InvalidArgumentException: Unsupported driver [] in /www/wwwroot/re/vendor/illuminate/database/Connectors/ConnectionFactory.php:226
Stack trace:
#0 /www/wwwroot/re/vendor/illuminate/database/Connectors/ConnectionFactory.php(64): Illuminate\Database\Connectors\ConnectionFactory->createConnection(NULL, Object(Closure), NULL, '', Array)
#1 /www/wwwroot/re/vendor/illuminate/database/Connectors/ConnectionFactory.php(49): Illuminate\Database\Connectors\ConnectionFactory->createSingleConnection(Array)
#2 /www/wwwroot/re/vendor/illuminate/database/DatabaseManager.php(176): Illuminate\Database\Connectors\ConnectionFactory->make(Array, 'default')
#3 /www/wwwroot/re/vendor/illuminate/database/DatabaseManager.php(68): Illuminate\Database\DatabaseManager->makeConnection('default')
#4 /www/wwwroot/re/app/Services/Boot.php(37): Illuminate\Database\DatabaseManager->connection('default')
#5 /www/wwwroot/re/bootstrap.php(28): App\Services\Boot::bootDb()
#6 /www/wwwroot/re/xcat(4): require('/www/wwwroot/re...')
#7 {main in /www/wwwroot/re/vendor/illuminate/database/Connectors/ConnectionFactory.php on line 226

@regendsoh
Copy link
Contributor

@muyuqiyan 请协助试试看ssh入服务器,在SSP目录下运行以下command

rm -rf composer.phar composer.lock composer.json 
wget https://raw.githubusercontent.com/Anankke/SSPanel-Uim/dev/composer.json -O composer.json
wget https://getcomposer.org/installer -O composer.phar
php composer.phar
php composer.phar install

不保证可行,但是看起来是dependency版本不一样的关系导致的问题
运行后请反馈可行性

@zzisk
Copy link
Author

zzisk commented Oct 3, 2019

运行后结果为
cakephp/utility suggests installing lib-ICU (To use Text::transliterate() or Text::slug()) cakephp/core suggests installing cakephp/event (To use PluginApplicationInterface or plugin applications.) cakephp/core suggests installing cakephp/cache (To use Configure::store() and restore().) Writing lock file Generating autoload files Carbon 1 is deprecated, see how to migrate to Carbon 2. https://carbon.nesbot.com/docs/#api-carbon-2 You can run './vendor/bin/upgrade-carbon' to get help in updating carbon and other frameworks and libraries that depend on it.
然后升级同样的错误,再次运行给出的代码后
Loading composer repositories with package information Updating dependencies (including require-dev) Nothing to install or update Writing lock file Generating autoload files Carbon 1 is deprecated, see how to migrate to Carbon 2. https://carbon.nesbot.com/docs/#api-carbon-2 You can run './vendor/bin/upgrade-carbon' to get help in updating carbon and other frameworks and libraries that depend on it.
再运行./vendor/bin/upgrade-carbon 后
`Loading composer repositories with package information
Updating dependencies (including require-dev)
Nothing to install or update
Writing lock file
Generating autoload files
Carbon 1 is deprecated, see how to migrate to Carbon 2.
https://carbon.nesbot.com/docs/#api-carbon-2
You can run './vendor/bin/upgrade-carbon' to get help in updating carbon and other frameworks and libraries that depend on it.
root@instance-re:/www/wwwroot/re# ./vendor/bin/upgrade-carbon
PHP Warning: shell_exec() has been disabled for security reasons in /www/wwwroot/re/vendor/nesbot/carbon/bin/upgrade-carbon on line 23

Warning: shell_exec() has been disabled for security reasons in /www/wwwroot/re/vendor/nesbot/carbon/bin/upgrade-carbon on line 23
PHP Fatal error: Uncaught Error: Class 'Composer\Composer' not found in /www/wwwroot/re/vendor/nesbot/carbon/src/Carbon/Upgrade.php:131
Stack trace:
#0 /www/wwwroot/re/vendor/nesbot/carbon/bin/upgrade-carbon(28): Carbon\Upgrade::upgrade()
#1 {main}
thrown in /www/wwwroot/re/vendor/nesbot/carbon/src/Carbon/Upgrade.php on line 131

Fatal error: Uncaught Error: Class 'Composer\Composer' not found in /www/wwwroot/re/vendor/nesbot/carbon/src/Carbon/Upgrade.php:131
Stack trace:
#0 /www/wwwroot/re/vendor/nesbot/carbon/bin/upgrade-carbon(28): Carbon\Upgrade::upgrade()
#1 {main}
thrown in /www/wwwroot/re/vendor/nesbot/carbon/src/Carbon/Upgrade.php on line 131
`

@regendsoh
Copy link
Contributor

PHP 那边禁用函数你没允许 shell_exec()

@zzisk
Copy link
Author

zzisk commented Oct 3, 2019

PHP 那边禁用函数你没允许 shell_exec()

`Loading composer repositories with package information
Updating dependencies (including require-dev)
Nothing to install or update
Generating autoload files
Loading composer repositories with package information
Updating dependencies (including require-dev)
Package operations: 0 installs, 0 updates, 13 removals

  • Removing symfony/service-contracts (v1.1.6)
  • Removing symfony/process (v4.3.4)
  • Removing symfony/polyfill-php73 (v1.12.0)
  • Removing symfony/filesystem (v4.3.4)
  • Removing symfony/console (v4.3.4)
  • Removing seld/phar-utils (1.0.1)
  • Removing seld/jsonlint (1.7.1)
  • Removing justinrainbow/json-schema (5.2.8)
  • Removing composer/xdebug-handler (1.3.3)
  • Removing composer/spdx-licenses (1.5.2)
  • Removing composer/semver (1.5.0)
  • Removing composer/composer (1.9.0)
  • Removing composer/ca-bundle (1.2.4)
    Writing lock file
    Generating autoload files
    `
    网页报错没变

@regendsoh
Copy link
Contributor

Telegram私聊我你teamviewer ID和密码
https://t.me/regendsoh

@Incisakura
Copy link
Contributor

I recommend you to create a mirror site for the manual upgrade test.
git pull, then debug by yourself.
But remember to replace System_Config by _ENV in config or add $_ENV = $System_Config; to the end of config if you want to upgrade after commit 91b2bf2 in the dev branch.

Issue closed.

@zzisk
Copy link
Author

zzisk commented Oct 3, 2019

Telegram私聊我你teamviewer ID和密码
https://t.me/regendsoh

目前tg不能发消息 在解锁

I recommend you to create a mirror site for the manual upgrade test.
git pull, then debug by yourself.
But remember to replace System_Config by _ENV in config or add $_ENV = $System_Config; to the end of config if you want to upgrade after commit 91b2bf2 in the dev branch.

Issue closed.

感谢大佬

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

No branches or pull requests

5 participants