Remove redundancies in miniedit; pass code check
This commit is contained in:
@@ -24,6 +24,7 @@ import sys
|
|||||||
from optparse import OptionParser
|
from optparse import OptionParser
|
||||||
from subprocess import call
|
from subprocess import call
|
||||||
|
|
||||||
|
# pylint: disable=import-error
|
||||||
if sys.version_info[0] == 2:
|
if sys.version_info[0] == 2:
|
||||||
from Tkinter import ( Frame, Label, LabelFrame, Entry, OptionMenu,
|
from Tkinter import ( Frame, Label, LabelFrame, Entry, OptionMenu,
|
||||||
Checkbutton, Menu, Toplevel, Button, BitmapImage,
|
Checkbutton, Menu, Toplevel, Button, BitmapImage,
|
||||||
@@ -32,11 +33,9 @@ if sys.version_info[0] == 2:
|
|||||||
CENTER, RIGHT, LEFT, BOTH, TRUE, FALSE )
|
CENTER, RIGHT, LEFT, BOTH, TRUE, FALSE )
|
||||||
from ttk import Notebook
|
from ttk import Notebook
|
||||||
from tkMessageBox import showerror
|
from tkMessageBox import showerror
|
||||||
from subprocess import call
|
|
||||||
import tkFont
|
import tkFont
|
||||||
import tkFileDialog
|
import tkFileDialog
|
||||||
import tkSimpleDialog
|
import tkSimpleDialog
|
||||||
import tkFileDialog
|
|
||||||
else:
|
else:
|
||||||
from tkinter import ( Frame, Label, LabelFrame, Entry, OptionMenu,
|
from tkinter import ( Frame, Label, LabelFrame, Entry, OptionMenu,
|
||||||
Checkbutton, Menu, Toplevel, Button, BitmapImage,
|
Checkbutton, Menu, Toplevel, Button, BitmapImage,
|
||||||
@@ -48,6 +47,7 @@ else:
|
|||||||
from tkinter import font as tkFont
|
from tkinter import font as tkFont
|
||||||
from tkinter import simpledialog as tkSimpleDialog
|
from tkinter import simpledialog as tkSimpleDialog
|
||||||
from tkinter import filedialog as tkFileDialog
|
from tkinter import filedialog as tkFileDialog
|
||||||
|
# pylint: enable=import-error
|
||||||
|
|
||||||
import re
|
import re
|
||||||
import json
|
import json
|
||||||
|
|||||||
+1
-1
@@ -89,7 +89,7 @@ class Node( object ):
|
|||||||
self.inNamespace = params.get( 'inNamespace', inNamespace )
|
self.inNamespace = params.get( 'inNamespace', inNamespace )
|
||||||
|
|
||||||
# Python 3 complains if we don't wait for shell exit
|
# Python 3 complains if we don't wait for shell exit
|
||||||
self.waitExited = params.get( 'waitExited', Python3 == True )
|
self.waitExited = params.get( 'waitExited', Python3 )
|
||||||
|
|
||||||
# Stash configuration parameters for future reference
|
# Stash configuration parameters for future reference
|
||||||
self.params = params
|
self.params = params
|
||||||
|
|||||||
Reference in New Issue
Block a user