diff --git a/assignment.py b/assignment.py index b9fdc93b2..e1229041e 100644 --- a/assignment.py +++ b/assignment.py @@ -1,3 +1,3 @@ -(*FIRST, ) = [1, 2, 3] -(*FIRST, ) = [1, 2, 3] -*FIRST, a, b = [1, 2, 3] +(*FIRST,) = [1, 2, 3] +(*FIRST,) = [1, 2, 3] +*FIRST, a, b = [1, 2, 3] diff --git a/demo_code.py b/demo_code.py index aba08a363..6a5c5e9e0 100644 --- a/demo_code.py +++ b/demo_code.py @@ -1,10 +1,10 @@ -import random -import sys as sys +import collections import os -import subprocess -import ssl import pprint -import collections +import random +import ssl +import subprocess +import sys as sys import this @@ -17,10 +17,10 @@ class BaseNumberGenerator: """Declare a method -- `get_number`.""" def __init__(self): - self.limits = (1, 10) + self.limits = (1, 10) def get_number(self, min_max): - raise NotImplementedError + raise NotImplementedError def smethod(): """static method-to-be""" diff --git a/foo.py b/foo.py index 40df53dbf..12c42d83a 100644 --- a/foo.py +++ b/foo.py @@ -1,6 +1,7 @@ -import os import logging -nums = [ i for i in range(10)] +import os + +nums = [i for i in range(10)] a = 1 b = 2 @@ -9,35 +10,42 @@ breakpoint() print(b, nums) + def baz(a=[]): - return 0 + return 0 + def aaa(a=[]): - return 1 + return 1 def foo(b=[]): - return 1 + return 1 + def bar(a): - return 1 + return 1 + import os + filename = os.tmpnam() -with open(filename, 'w') as f: - pass +with open(filename, "w") as f: + pass + def boom(a=[]): - breakpoint() - filename = os.tmpnam() - breakpoint() - return filename + breakpoint() + filename = os.tmpnam() + breakpoint() + return filename + def another_test_method(): - f = open("/tmp/.deepsource.toml", "r") - f.write("config file.") - f.close() - print('abc') - -filename = os.tmpnam() + f = open("/tmp/.deepsource.toml", "r") + f.write("config file.") + f.close() + print("abc") + +filename = os.tmpnam() diff --git a/miscellaneous.py b/miscellaneous.py index 1e8f1564b..7c82c2a27 100644 --- a/miscellaneous.py +++ b/miscellaneous.py @@ -1,4 +1,4 @@ -from utils import get_next, render_to_frontend, render_bg +from utils import get_next, render_bg, render_to_frontend class Orange: diff --git a/security.py b/security.py index b8b179b51..0030bdf9e 100644 --- a/security.py +++ b/security.py @@ -1,4 +1,5 @@ import sqlite3 + import requests diff --git a/tests/test_code.py b/tests/test_code.py index ee6cfbf13..c78b30768 100644 --- a/tests/test_code.py +++ b/tests/test_code.py @@ -1,4 +1,5 @@ import unittest + from demo_code import RandomNumberGenerator