#102 Import koji in module level
Merged 6 years ago by ignatenkobrain. Opened 6 years ago by cqi.
cqi/odcs koji-py3  into  master

@@ -21,6 +21,7 @@ 

  #

  # Written by Jan Kaluza <jkaluza@redhat.com>

  

+ import koji

  import os

  import threading

  import shutil
@@ -139,8 +140,6 @@ 

      Creates and returns new koji_session based on the `conf.koji_profile`.

      """

  

-     # We import koji here, because it does not support python3

-     import koji

      koji_module = koji.get_profile_module(conf.koji_profile)

      session_opts = {}

      for key in ('krbservice', 'timeout', 'keepalive',

Koji now supports Python 3 and shared library koji is in separate
Python 3 package and be installable. So, from now on, it is safe to
import koji in module level instead of inside a method.

Fixes #88

Signed-off-by: Chenxiong Qi cqi@redhat.com

Pull-Request has been merged by ignatenkobrain

6 years ago