【问题标题】:Python gives NotImplementedError for posix grp functions on AIXPython 为 AIX 上的 posix grp 函数提供 NotImplementedError
【发布时间】:2012-02-27 23:01:07
【问题描述】:

我在使用 python 提取 tar 文件时发现了这个问题,使用 tarfile.extractall。该函数适用于其他操作系统,但在 AIX 上我收到来自 getgrnam 的错误。

这是一个非常简单的测试,只调用getgrnam

Jython 2.5.2 (Release_2_5_2:7206, Mar 2 2011, 23:12:06)
[IBM J9 VM (IBM Corporation)] on java1.5.0
Type "help", "copyright", "credits" or "license" for more information.
>>>
>>> import grp
>>>
>>> file = "test.txt"
>>>
>>> grp.getgrnam(file)
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/tmp/jython.jar/Lib/grp.py", line 67, in getgrnam
NotImplementedError: getgrnam unimplemented

知道为什么会发生这种情况以及可能的解决方案吗?

【问题讨论】:

    标签: python jython aix


    【解决方案1】:

    AIX 在 Jython 中不显示为 POSIX。

    【讨论】:

      猜你喜欢
      • 2013-06-09
      • 1970-01-01
      • 2021-08-12
      • 2017-05-12
      • 2018-05-15
      • 1970-01-01
      • 2018-10-12
      • 2022-01-22
      • 1970-01-01
      相关资源
      最近更新 更多