translate most modules to using print() as imported from __future__
[unfold.git] / portal / managementtabrequests.py
index 2c80e41..2ebc646 100644 (file)
@@ -1,3 +1,5 @@
+from __future__ import print_function
+
 from django.template                 import RequestContext
 from django.shortcuts                import render_to_response
 
@@ -47,7 +49,7 @@ class ManagementRequestsView (LoginRequiredView, ThemeView):
             sfa_platforms_query = Query().get('local:platform').filter_by('gateway_type', '==', 'sfa').select('platform_id', 'platform', 'auth_type')
             sfa_platforms = execute_query(self.request, sfa_platforms_query)
             for sfa_platform in sfa_platforms:
-                print "SFA PLATFORM > ", sfa_platform['platform']
+                print("SFA PLATFORM > ", sfa_platform['platform'])
                 if not 'auth_type' in sfa_platform:
                     continue
                 auth = sfa_platform['auth_type']
@@ -55,7 +57,7 @@ class ManagementRequestsView (LoginRequiredView, ThemeView):
                     all_authorities.append(auth)
                 platform_ids.append(sfa_platform['platform_id'])
 
-            print "W: Hardcoding platform myslice"
+            print("W: Hardcoding platform myslice")
             # There has been a tweak on how new platforms are referencing a
             # so-called 'myslice' platform for storing authentication tokens.
             # XXX This has to be removed in final versions.
@@ -102,7 +104,7 @@ class ManagementRequestsView (LoginRequiredView, ThemeView):
                 for pa in pi_authorities_tmp:
                     pi_authorities |= set(pa['pi_authorities'])
             except:
-                print 'No pi_authorities'
+                print('No pi_authorities')
 
             pi_credential_authorities = pi_authorities & credential_authorities
             pi_no_credential_authorities = pi_authorities - credential_authorities - credential_authorities_expired