Comments (9)
Sure, I think that should be possible as long as we don't require the webserver plugin
from glances.
I understand that you would like to avoid using Pydantic. But currently the Webserver dependency (fastapi) would require it.
Could you please list the platform which you use and currently don't have pydantic binaries?
Btw rust being required to build rust is totally normal in the compiler world? Even gcc and clang are Self-hosting compilers.
I don't really understand your security concern. But I get that it's going to be a pain to build when no binaries are available.
from glances.
@RazCrimson Thank you for responding! Rust does not build on older macOS (all powerpc, some older x86), I think it does not build for powerpc on OpenBSD as well (perhaps even on FreeBSD for ppc 32-bit). I am pretty sure there are other non-mainstream platforms where Rust does not build.
P. S. Both gcc and clang can be built with other C/C++ compilers, they do not require themselves to build.
from glances.
@RazCrimson It will be sufficient to add a configure option to disable Pydantic and whatever needs it. I.e. nothing will change by default, but at the same time we could unbreak the package for Rustless systems.
from glances.
@RazCrimson That would be awesome!
from glances.
The default "pip install glances" do not install the Webserver requirements.
Pydantic should be installed only if you use "pip install glances[web]" or "pip install glances[all]".
from glances.
So we have to move pydantic from requirements.txt to requirements-webui.txt ?
from glances.
Yea, but I think there was some pydantic import that was failing.
We'll probably have to fix that and check if everything works right.
from glances.
I tried to remove pydantic
from requirements in the portfile, it installed, but does not run:
36-173% glances
Traceback (most recent call last):
File "/opt/local/bin/glances", line 8, in <module>
sys.exit(main())
^^^^^^
File "/opt/local/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packages/glances/__init__.py", line 184, in main
start(config=core.get_config(), args=core.get_args())
File "/opt/local/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packages/glances/__init__.py", line 94, in start
from glances.standalone import GlancesStandalone as GlancesMode
File "/opt/local/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packages/glances/standalone.py", line 20, in <module>
from glances.outputs.glances_curses import GlancesCursesStandalone
File "/opt/local/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packages/glances/outputs/glances_curses.py", line 18, in <module>
from glances.events_list import glances_events
File "/opt/local/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packages/glances/events_list.py", line 14, in <module>
from pydantic import RootModel
ModuleNotFoundError: No module named 'pydantic'
It looks like MacPorts does not specifically configure it in some way: https://github.com/macports/macports-ports/blob/master/sysutils/glances/Portfile
Requirement for pydantic
was added in macports/macports-ports@fddf466
from glances.
Related Issues (20)
- Update the Grafana dashboard HOT 1
- GET /1272f6e9e8f9d6bfd6de.png results in 404 HOT 6
- Glances Web in Ubuntu 22.04 resulting in FastAPI error HOT 3
- docker latest still pulling 4.0.2 after 4.0.3 release HOT 7
- Add version of Glances on the page HOT 3
- SensorType change in REST API breaks compatibility in 4.0.4 HOT 8
- Retire ujson for being in maintenance mode HOT 4
- cpu_hz_current not available on NetBSD HOT 3
- Home Assistant add-on doesn't work with 4.0 HOT 2
- No GPU info on Web View HOT 2
- [WIP] FastAPI import error. Glances cannot start in web server mode HOT 2
- FR:LVM support
- Add support for automatically hiding network interfaces that are down or that don't have any IP addresses HOT 2
- Reduce code complexity
- When Glances is installed via venv, default configuration file is not used HOT 1
- Unknown instance unknown? HOT 4
- arm64_v8The container status is not displayed HOT 1
- Give a try to Reflex to replace de WebUI by a pure Python implementation
- Incorrect memory usage?
- Make CORS option configurable HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from glances.