D7net
Home
Console
Upload
information
Create File
Create Folder
About
Tools
:
/
proc
/
thread-self
/
root
/
usr
/
lib
/
python3.6
/
site-packages
/
pyudev
/
Filename :
_compat.py
back
Copy
# -*- coding: utf-8 -*- # Copyright (C) 2011 Sebastian Wiesner <lunaryorn@gmail.com> # This library is free software; you can redistribute it and/or modify it # under the terms of the GNU Lesser General Public License as published by the # Free Software Foundation; either version 2.1 of the License, or (at your # option) any later version. # This library is distributed in the hope that it will be useful, but WITHOUT # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or # FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License # for more details. # You should have received a copy of the GNU Lesser General Public License # along with this library; if not, write to the Free Software Foundation, # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA """ pyudev._compat ============== Compatibility for Python versions, that lack certain functions. .. moduleauthor:: Sebastian Wiesner <lunaryorn@gmail.com> """ from __future__ import (print_function, division, unicode_literals, absolute_import) from subprocess import Popen, CalledProcessError, PIPE def check_output(command): """ Compatibility with :func:`subprocess.check_output` from Python 2.7 and upwards. """ proc = Popen(command, stdout=PIPE) output = proc.communicate()[0] if proc.returncode != 0: raise CalledProcessError(proc.returncode, command) return output
Name
Size
Last Modified
Owner
Permissions
Actions
__pycache__
Dir
July 28 2023 2:56:39
root
0755
_ctypeslib
Dir
July 28 2023 2:56:39
root
0755
_os
Dir
July 28 2023 2:56:39
root
0755
device
Dir
July 28 2023 2:56:39
root
0755
__init__.py
2.436
KB
April 29 2016 9:17:02
root
0644
_compat.py
1.434
KB
February 02 2016 4:19:29
root
0644
_qt_base.py
6.854
KB
July 21 2016 8:32:53
root
0644
_util.py
6.789
KB
April 29 2016 9:17:02
root
0644
core.py
13.112
KB
July 21 2016 8:32:53
root
0644
discover.py
11.238
KB
July 21 2016 8:32:53
root
0644
monitor.py
20.461
KB
July 21 2016 8:32:53
root
0644
version.py
1.075
KB
July 21 2016 8:32:53
root
0644
2017 © D7net | D704T team