-
Notifications
You must be signed in to change notification settings - Fork 263
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
显示不正常. 查看源码报错 #215
Comments
使用的是 php8.2.14 |
感谢反馈,应该是有某个权限不足导致无法读取某内容然后出现未预料情况就报错了。 |
PHP 8.3.9 也这样。
Line 119: |
看起来像 /proc 目录没权限读取。 |
照葫芦画瓢写了个简单脚本测试下:
没有报错可以返回结果:
|
这段代码放到 PHP 7.4 / PHP 8.3 两个不同环境测试:
7.4 没事,8.3 第 10 行 另外,这段代码好像只能针对 x86 的 CPU,我看 ARM 类的 ARM:
|
https://github.com/kmvan/x-prober/blob/dev/dist/prober.php 试试debug版本,看看具体的错误位置。 |
好像就是 PHP 8+ 的问题,参考下面:
symfony/symfony#45179 (comment) 按照上面把 trim 那改成类似 |
trim() 函数里面只能是 string 类型,看样子里面的值变成了 null 类型,就报错了。 |
是啊,你看 ARM CPU 的信息,单核总共才8行,那个 |
确实,等候我更新下。 |
CPU 型号显示那,针对 ARM CPU 估计也得另作处理,缓存没法获取,型号 |
https://github.com/kmvan/x-prober/blob/dev/dist/prober.php 目前开发版会报错吗?如果无报错的话,后续更新应该可以显示具体型号。 |
不报错了,CPU 显示内容如下: |
可以贴一下 |
这个是 Phicomm N1:
|
这个是 Oracle 甲骨文 ARM VPS 的
|
实际上这个信息里面,可能有用的只有
这两个?你认为还有什么信息有用?在探针里面显示的信息。 |
Flags 建议显示。 |
安排。最后可以贴一下 Oracle 那款 vps 的 |
|
更新8.18版了 |
-- | Warning: Undefined array key 1 in /www/wwwroot/x.php on line 48
|
| Deprecated: trim(): Passing null to parameter #1 ($string) of type string is deprecated in /www/wwwroot/x.php on line 48
| |
The text was updated successfully, but these errors were encountered: