Comments (12)
Hi @mdubinko, thanks for properly opening this up.
From this formula, I understood Homebrew's proposed Archey version corresponds to this project.
I'd love seeing Archey 4 supporting macOS (maybe related to #69 too ?), I unfortunately don't have a proper setup to experiment those developments, and didn't want to abuse of Microsoft GitHub's CI in such conditions.
That being said, have you tried directly running a recent release of Archey 4 on your system ? Despite a wrong logo being displayed, I'd want to know whether it crashed, and if so, why !
Bye 👋
EDIT : Also see related #38.
from archey4.
Straight out of the box, I get
...
File "/usr/local/lib/python3.9/site-packages/archey/entries/cpu.py", line 48, in init
self.value = self._parse_lscpu_output()
File "/usr/local/lib/python3.9/site-packages/archey/entries/cpu.py", line 83, in _parse_lscpu_output
cpu_info = check_output('lscpu', env={'LANG': 'C'}, universal_newlines=True)
...
File "/usr/local/Cellar/[email protected]/3.9.2/Frameworks/Python.framework/Versions/3.9/lib/python3.9/subprocess.py", line 1823, in _execute_child
raise child_exception_type(errno_num, err_msg, err_filename)
FileNotFoundError: [Errno 2] No such file or directory: 'lscpu'
Alas, MacOS has neither /proc nor an lscpu binary. According to https://www.quora.com/Is-there-a-Mac-OS-equivalent-to-the-Linux-lscpu it looks like the near equivalent is
sysctl -n machdep.cpu.brand_string
Which locally returns
Intel(R) Core(TM) i7-4850HQ CPU @ 2.30GHz
So it seems like it would be more complicated to figure out cores/threads/etc. Would it be worth looking at how archey-osx does it, or would you prefer more of a cleanroom approach?
from archey4.
Thanks for you feedback, I'm actually already on it with the help of a friend. Expect a proper proposition within some days. Bye 🙇
from archey4.
Hey back @mdubinko. Would you be able to test latest develop
state (recently force-pushed, care with your fork) ?
git checkout develop
git pull
python3 -m archey
I had to adapt tests a bit, but now CI is all green.
I'm waiting for your feedback before anything else.
EDIT : Most of Archey-OSX has been ported, and (regular) BSDs should be supported too.
Bye 👋
from archey4.
My fork is basically abandoned at this point. :) I ran this straight from the develop branch on this repo.
% python3 -m archey (develop)archey4
WARNING: [sysctl]: Couldn't fetch temperature from CPU sensors (sysctl: unknown oid 'dev.cpu.0.temperature'). Please be sure to load the corresponding kernel driver beforehand (`kldload coretemp` for Intel or `kldload amdtemp` for AMD`).
User: micah
'c. Hostname: retina15.lan
,xNMM. Model: MacBookPro11.3
.OMMMMo Distro: Darwin 19.6.0 [x86_64]
OMMM0, Kernel: 19.6.0
.;loddo:' loolloddol;. Uptime: 7 days, 11 hours and 46 minutes
cKMMMMMMMMMMNWMMMMMMMMMM0: Processes: 584
.KMMMMMMMMMMMMMMMMMMMMMMMWd. WindowManager: Quartz Compositor
XMMMMMMMMMMMMMMMMMMMMMMMX. DesktopEnvironment: Aqua
MMMMMMMMMMMMMMMMMMMMMMMM: Shell: /bin/zsh
MMMMMMMMMMMMMMMMMMMMMMMM: Terminal: iTerm.app ██ ██ ██ ██ ██ ██ ██
MMMMMMMMMMMMMMMMMMMMMMMMX. Packages: 131
kMMMMMMMMMMMMMMMMMMMMMMMMWd. Temperature: Not detected
.XMMMMMMMMMMMMMMMMMMMMMMMMMMk CPU: 8 x Quad-Core Intel Core i7 @ 2.3 GHz
.XMMMMMMMMMMMMMMMMMMMMMMMMK. GPU: Intel Iris Pro
kMMMMMMMMMMMMMMMMMMMMMMd GPU: NVIDIA GeForce GT 750M
;KMMMMMMMWXXWMMMMMMMk. RAM: 1664 MiB / 16384 MiB
.cooc,. .,coo:. Disk: 4.5 TiB / 10.6 TiB
LanIP: fe80::1, 192.168.86.27
WanIP: (redacted) 😄
After iTerm.app the rectangular blocks are in fact color swatches.
Not sure if intended, but the "Disk" figure includes my network mounted backup drive.
from archey4.
My fork is basically abandoned at this point. :)
It was just in case 😌
Not sure if intended, but the "Disk" figure includes my network mounted backup drive.
Since #67 (IIRC), Disk
process them all, indeed.
2 possibilities :
- if you got a regular setup, we may blacklist your mount point from computations (we would need the
df -h
entry corresponding to your network drive) ; - if not (e.g. manually mounted under a local path), you may select specific disks (or even mount points) as configuration (check out
show_filesystems
option key). You may also splitDisk
in separate entries (combine_total
option key).
One more thing I also spotted in CI executions : I can't understand your Distro
entry output. Could you run python3 -c 'import platform; print(platform.mac_ver())'
for me please ?
Thanks for your feedback ! Bye 👋
EDIT : I don't know whether the sysctl
warning is relevant to write on macOS, do you have an idea about this ?
from archey4.
On my Catalina box: ('10.15.7', ('', '', ''), 'x86_64')
On my Big Sur box: ('10.16', ('', '', ''), 'x86_64')
Not sure how temp sensors work across different Macs, and I haven't closely inspected the new code yet. Though that error message mentions AMD and probably isn't even relevant for Mac...
from archey4.
Thanks again, please find an updated develop
(supposed to be) fixing those last two issues. 👋
EDIT : I opted for (apparently well-known) third-parties to gather temperature on macOS (iStats or OSX CPU Temp), without any error messages in case they are not installed so as to keep the detection fully-optional and a "clean" output out-of-the-box for iUsers. What do you think about that ?
from archey4.
All good on my side, I'm waiting for your feedback about last develop
changes before merging this on master
and drafting a v4.11.0 👌 Cheers
from archey4.
# python3 -m archey
Gave good output with no error messages. Temperature: Not detected
I ran # brew install osx-cpu-temp then tried again, and got:
...
File "/Users/micah/Developer/archey4/archey/__main__.py", line 137, in _entry_instantiator
return Entries[entry.pop('type')].value(
File "/Users/micah/Developer/archey4/archey/entries/temperature.py", line 37, in __init__
self._run_istats_or_osxcputemp()
File "/Users/micah/Developer/archey4/archey/entries/temperature.py", line 140, in _run_istats_or_osxcputemp
self._temps.append(float(osxcputemp_output.split()[0]))
ValueError: could not convert string to float: '57.0°C'
from archey4.
Thanks again for your feedback @mdubinko !
It appears lavoiesl/osx-cpu-temp#22 has not been released yet, so I got kidded by the upstream documentation. Anyway, I've just published a fix and will try to release a new version this WE. Bye 👋
from archey4.
Released today as v4.11.0, waiting for feedback from the community now. Bye 👋
from archey4.
Related Issues (20)
- [BUG] Can't get value of subfeature in0_input: Can't read HOT 3
- [BUG] ERROR: archey.test.entries.test_archey_packages (unittest.loader._FailedTest) HOT 5
- [BUG] archey4 can't handle filesystems with spaces HOT 3
- [BUG] [GPU] Avoid multiple `system_profiler` log display HOT 2
- [BUG] Uptime reported incorrectly on macOS HOT 2
- [BUG] in README HOT 1
- Temperature invalid on AMD platform HOT 5
- [FEATURE] Change the Color from the Output HOT 5
- [BUG] Very verbose GPU output HOT 5
- [BUG] On macOS, total disk size is reported incorrectly for APFS drives HOT 9
- [BUG]: In a WSL environment, Ubuntu is reported as Windows HOT 3
- [BUG] Nonfatal warning "WARNING: [root] One entry (misses or) uses an invalid `type` field ('command')." HOT 7
- [BUG] `CPU` not detected on Raspberry Pi 4 HOT 4
- [BUG] `logo_style` ignored from configuration HOT 3
- [Question] What do you means with "iStats" for Highly recommended packages on macOS ? HOT 2
- [BUG] `GPU` not detected on Raspberry Pi 4 HOT 33
- [BUG] uptime: /dev/ttys010: No such file or directory HOT 3
- [FEATURE] An option to disable link local IPv6 addresses (fe80::) in LAN IP output HOT 2
- [BUG] critical error on macOS today HOT 5
- [macOS] ASCII art and entries aren't colored HOT 10
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 archey4.