Skip to content
This repository was archived by the owner on Dec 5, 2022. It is now read-only.

Commit 78ee826

Browse files
committed
fix flake8 issues and bump version
1 parent 237a471 commit 78ee826

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

nsenter/__init__.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,8 +26,10 @@ def nsfd(process, ns_type):
2626
Returns the namespace file descriptor for process (self or PID) and namespace type
2727
"""
2828
return Path('/proc') / str(process) / 'ns' / ns_type
29+
2930
nsfd.__annotations__ = {'process': str, 'ns_type': str, 'return': Path}
3031

32+
3133
class Namespace(object):
3234
def __init__(self, pid, ns_type):
3335
self.pid = pid
@@ -37,7 +39,7 @@ def __init__(self, pid, ns_type):
3739
self.target_fd = nsfd(pid, ns_type).open()
3840
self.target_fileno = self.target_fd.fileno()
3941

40-
__init__.__annotations__ = {'pid': str, 'ns_type': str}
42+
__init__.__annotations__ = {'pid': str, 'ns_type': str}
4143

4244
def __enter__(self):
4345
log.debug('Entering %s namespace %s', self.ns_type, self.pid)

setup.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ def read(fname):
1414
def setup_package():
1515
setuptools.setup(
1616
name='nsenter',
17-
version='0.1.4-2',
17+
version='0.1.5',
1818
url='https://github.com/zalando/python-nsenter',
1919
description='Enter kernel namespaces from Python',
2020
author='Henning Jacobs',

0 commit comments

Comments
 (0)