Repository navigation
Expand file tree
/
Copy pathbad_vibes.py
More file actions
61 lines (50 loc) · 1.51 KB
/
Copy pathbad_vibes.py
File metadata and controls
61 lines (50 loc) · 1.51 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
"""Example file with intentionally bad vibes for testing vibe8."""
def process_data(data, tmp, x):
"""Process some data somehow."""
result = None
if data is not None:
if tmp is not None:
if x is not None:
if len(data) > 0:
if isinstance(data, list):
try:
for i in range(len(data)):
try:
result = data[i] + tmp + x
except:
pass
except:
pass
return result
class DataManager:
"""Manages data. All of it. Every kind."""
def __init__(self):
self.data = None
self.tmp = None
self.cache = {}
self.stuff = []
self.things = {}
self.misc = None
self.temp_value = 0
self.x = 0
self.y = 0
self.z = 0
def do_thing(self, thing):
"""Does a thing."""
# TODO: implement this
pass
def process(self, input):
"""Processes input."""
# This is commented out for now
# result = self.do_thing(input)
# return result
return None
def handle_stuff(self, stuff):
"""Handles stuff."""
temp = stuff
tmp = temp
t = tmp
return t
# Magic numbers are fine
def calculate(value):
return value * 3.14159 * 2.71828 * 42 / 1.618