Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
home:edogawa
howdy
howdy-configparser.patch
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File howdy-configparser.patch of Package howdy
diff -up howdy-2.6.1/src/pam.py.orig howdy-2.6.1/src/pam.py --- howdy-2.6.1/src/pam.py.orig 2023-09-28 14:26:24.034824526 +0200 +++ howdy-2.6.1/src/pam.py 2023-09-28 14:26:48.168527768 +0200 @@ -6,11 +6,17 @@ import os import glob import syslog -# pam-python is running python 2, so we use the old module here -import ConfigParser - +import sys +# The config parser is named in python2 as ConfigParser but in python3 as configparser +# and here is a workaround for this. +if sys.version_info[0] == 2: + import ConfigParser + config = ConfigParser.ConfigParser() +else: + import configparser + config = configparser.ConfigParser() + # Read config from disk -config = ConfigParser.ConfigParser() config.read(os.path.dirname(os.path.abspath(__file__)) + "/config.ini")
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor