RFE: provide hint if permissions do no allow any journal files to be opened
還沒有人認領這個 Issue。
評估
- 難度
- 3/5
- 預估耗時
- 1-2 天
- 新手友好度
- 35/100
- Issue 類型
- 功能
- 描述清晰度
- 基本清楚
- 活躍度
- 停滯
- 技術堆疊
- python
研究方向
Start with the Python systemd.journal.Reader() entry point and reproduce the CentOS permission case using this_boot(), log_level(), and get_next(). The change is complete when reading with no accessible journal files reports the insufficient-permissions condition instead of silently yielding empty results; the payload names no source file or test.
由索引模型根據 Issue 內容生成。
描述
Reading from journald without permission to do so should throw an exception but doesn't?
build:~$ cat /etc/os-release
NAME="CentOS Linux"
VERSION="7 (Core)"
ID="centos"
ID_LIKE="rhel fedora"
VERSION_ID="7"
PRETTY_NAME="CentOS Linux 7 (Core)"
ANSI_COLOR="0;31"
CPE_NAME="cpe:/o:centos:centos:7"
HOME_URL="https://www.centos.org/"
BUG_REPORT_URL="https://bugs.centos.org/"
CENTOS_MANTISBT_PROJECT="CentOS-7"
CENTOS_MANTISBT_PROJECT_VERSION="7"
REDHAT_SUPPORT_PRODUCT="centos"
REDHAT_SUPPORT_PRODUCT_VERSION="7"
build:~$
build:~$ groups
developers
build:~$
build:~$ journalctl --since "1 hour ago"
Hint: You are currently not seeing messages from other users and the system.
Users in the 'systemd-journal' group can see all messages. Pass -q to
turn off this notice.
No journal files were opened due to insufficient permissions.
build:~$
build:~$ python3.6
Python 3.6.3 (default, Jan 4 2018, 16:40:53)
[GCC 4.8.5 20150623 (Red Hat 4.8.5-16)] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>>
>>>
>>> from systemd import journal
>>> j = journal.Reader()
>>> j.this_boot()
>>> j.log_level(journal.LOG_DEBUG)
>>> j.get_next()
{}
>>> for entry in j:
... print(entry)
...
>>>
- 主要語言
- C
- 星號
- 524
- 分支
- 78
- PR 合併指標
- 30 天內沒有已合併 PR
環境準備
這個專案沒有提供開發容器、Dockerfile 或貢獻指南,環境需要你自己搭建:先看它的 README,通用步驟見我們的新手貢獻指南。
從這裡開始
- 先讀完整個 Issue,再讀專案的貢獻指南。
- 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
- Fork 儲存庫,在一個分支上完成修改。
- 送出 Pull Request,並在描述裡引用這個 Issue 編號。
systemd/python-systemd 的其他 Issue
-
難度 3/5 1-2 天 新手友好度 48/100
systemd/python-systemd#177 · 1 則留言 · 1 個 reaction ·
-
難度 3/5 1-2 天 新手友好度 42/100
systemd/python-systemd#169 · 1 則留言 ·
-
難度 4/5 3-5 天 新手友好度 48/100
systemd/python-systemd#167 · 19 則留言 ·
-
難度 5/5 一週以上 新手友好度 35/100
systemd/python-systemd#152 · 1 則留言 · 14 個 reaction ·
-
難度 4/5 3-5 天 新手友好度 45/100
systemd/python-systemd#146 · 2 則留言 ·
查看 systemd/python-systemd 的全部 Issue
相似的 Issue
-
難度 2/5 1-3 小時 新手友好度 65/100
dkfans/keeperfx#5415 · 1 則留言 ·
維護者通常 1 天內回覆
-
難度 2/5 1-3 小時 新手友好度 66/100
維護者通常 1 天內回覆
-
難度 2/5 1-3 小時 新手友好度 67/100
void-linux/void-runit#141 ·
-
難度 2/5 1-3 小時 新手友好度 72/100
ARM-software/sysarch-acs#600 ·
維護者通常 1 天內回覆
-
bug
難度 2/5 1-3 小時 新手友好度 78/100
維護者通常 1 天內回覆