radboy 0.0.589__py3-none-any.whl → 0.0.591__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of radboy might be problematic. Click here for more details.

radboy/DB/Prompt.py CHANGED
@@ -2342,6 +2342,16 @@ CMD's are not final until ended with {Fore.magenta}{hw_delim}{Style.reset}""")
2342
2342
  elif cmd.lower() in ['b','back']:
2343
2343
  lastTime=db.detectGetOrSet("PromptLastDTasFloat",datetime.now().timestamp(),setValue=True)
2344
2344
  return
2345
+ elif cmd.lower() in ['fakephone','fake phone']:
2346
+ phn=db.PhakePhone().phonenumber
2347
+ print(phn)
2348
+ returnable=Control(func=FormBuilderMkText,ptext="Return this number as input?",helpText="yes or no",data="boolean")
2349
+ if returnable is None:
2350
+ continue
2351
+ elif returnable in ['d',False]:
2352
+ continue
2353
+ else:
2354
+ return func(phn,data)
2345
2355
  elif cmd.lower() in ['h','help']:
2346
2356
  llo_modes=["dlu.cr","Prompt.lsbld","esu","t.[mksl||qsl||set Shelf||set Display]"]
2347
2357
  extra=f'''{Fore.orange_red_1}Dimension Fields {Fore.light_steel_blue}are fields that tell how much space the product is going to take up using the the product itself as the unit of measure
Binary file
radboy/DB/db.py CHANGED
@@ -49,7 +49,7 @@ from barcode.writer import ImageWriter
49
49
  import hashlib
50
50
  import base64
51
51
  from decimal import Decimal as TDecimal,getcontext
52
-
52
+ from radboy.DB.types import *
53
53
  getcontext().prec=4
54
54
 
55
55
  import scipy
@@ -59,101 +59,6 @@ def invalidRepeaters():
59
59
  mp.extend([f'{im}'*i for i in range(os.get_terminal_size().columns)])
60
60
  return mp
61
61
 
62
- class decc(TDecimal):
63
- ''' defines a decimal of 'cf\''''
64
- def __new__(self,value,cf=3):
65
- '''you can set the floating precision of a value in curly braces {value:.3f} by doing {value:{three}f} where three is he variable containting the value 3
66
- used for precision
67
-
68
- value=1.234
69
- cf=2
70
- result=1.23
71
- for the below assignment.
72
-
73
- value=f"{value:.{cf}f}"
74
- print(value)
75
- '''
76
-
77
- value=f"{value:.{cf}f}"
78
- return super().__new__(self,value)
79
-
80
- class dec3(TDecimal):
81
- ''' defines a decimal of .3f'''
82
- def __new__(self,value):
83
- value=f"{value:.3f}"
84
- return super().__new__(self,value)
85
-
86
- class dec2(TDecimal):
87
- ''' defines a decimal of .2f'''
88
- def __new__(self,value):
89
- value=f"{value:.3f}"
90
- return super().__new__(self,value)
91
-
92
- class dec1(TDecimal):
93
- ''' defines a decimal of .1f'''
94
- def __new__(self,value):
95
- value=f"{value:.3f}"
96
- return super().__new__(self,value)
97
-
98
-
99
- class stre(str):
100
- '''String Extended to include operators for some useful functionality.'''
101
- def __invert__(self):
102
- '''Generate a 512 Hex Digest for self'''
103
- hl=hashlib.sha512()
104
- hl.update(self.encode())
105
- return str(hl.hexdigest())
106
-
107
- def __sub__(self,other):
108
- '''remove this many characters from the string, where a positive removes from the right and a negative removes from the left'''
109
- if isinstance(other,int) or isinstance(other,float):
110
- #print(other<0)
111
- if other < 0:
112
- return self[:other]
113
- elif other > 0:
114
- m=[self[i:i+1] for i in range(0,len(self),int(1))]
115
- for i in range(0,other):
116
- popped=m.pop(0)
117
- return ''.join(m)
118
- else:
119
- raise NotImplemented
120
-
121
- def __truediv__(self,other):
122
- '''return a list broken into chunks of other'''
123
- if isinstance(other,int) or isinstance(other,float):
124
- return [self[i:i+other] for i in range(0,len(self),int(other))]
125
- else:
126
- raise NotImplemented
127
-
128
- def __mod__(self,other):
129
- #return the number of chunks
130
- if isinstance(other,int) or isinstance(other,float):
131
-
132
- return len([self[i:i+other] for i in range(0,len(self),int(other))])
133
- else:
134
- raise NotImplemented
135
-
136
- def __floordiv__(self,other):
137
- '''reverse of __truediv__'''
138
- if isinstance(other,int) or isinstance(other,float):
139
-
140
- return [ii for ii in reversed([self[i:i+other] for i in range(0,len(self),int(other))])]
141
-
142
- else:
143
- raise NotImplemented
144
-
145
- def __pow__(self,other):
146
- '''generate a random string from self of length other.'''
147
-
148
- if isinstance(other,int) or isinstance(other,float):
149
-
150
- src=[self[i:i+1] for i in range(0,len(self),int(1))]
151
- end=''.join(random.choices(src,k=int(abs(other))))[:int(abs(other))]
152
- while (len(end) < other) or (len(end) > other):
153
- end=''.join(random.choices(src,k=int(abs(other))))[:int(abs(other))]
154
- return end
155
- else:
156
- raise NotImplemented
157
62
 
158
63
  import builtins
159
64
  builtins.stre=stre
@@ -5738,3 +5643,41 @@ except Exception as e:
5738
5643
  Occurances.__table__.drop(ENGINE)
5739
5644
  Occurances.metadata.create_all(ENGINE)
5740
5645
 
5646
+ class PhakePhone(stre):
5647
+ def __new__(self,*args,**kwargs):
5648
+ self.phonenumber=self.randomPhonenumber()
5649
+ return self
5650
+
5651
+ def randomPhonenumber():
5652
+ extensions=[' x',' Ext. ',',',' ext ']
5653
+ ext=''
5654
+ try:
5655
+ ext=''.join([stre(string.digits)[random.randint(0,len(string.digits))] for z in range(random.randint(0,5))])
5656
+ f=extensions[random.randint(0,len(extensions))]
5657
+ if len(ext) > 0:
5658
+ ext=f"{f}{ext}"
5659
+ else:
5660
+ ext=''
5661
+ except Exception as e:
5662
+ ext=''
5663
+
5664
+ try:
5665
+ p1=''.join([stre(string.digits)[random.randint(0,len(string.digits))] for z in range(1)])
5666
+ if len(p1) > 0:
5667
+ p1=f"+{p1} "
5668
+ else:
5669
+ p1=''
5670
+ except Exception as e:
5671
+ p1=''
5672
+
5673
+ if len(p1) > 0:
5674
+ p2=''.join([stre(string.digits)[random.randint(0,len(string.digits)-1)] for z in range(3)])
5675
+ p2=f"({p2}) "
5676
+ else:
5677
+ p2=''.join([stre(string.digits)[random.randint(0,len(string.digits)-1)] for z in range(3)])
5678
+ p2=f"{p2}-"
5679
+ p3=''.join([stre(string.digits)[random.randint(0,len(string.digits)-1)] for z in range(3)])
5680
+ p4=''.join([stre(string.digits)[random.randint(0,len(string.digits)-1)] for z in range(4)])
5681
+
5682
+ phonenumber=f"""{p1}{p2}{p3}-{p4}{ext}"""
5683
+ return phonenumber
radboy/DB/types.py ADDED
@@ -0,0 +1,98 @@
1
+ from decimal import Decimal as TDecimal,getcontext
2
+ import string,random
3
+ class decc(TDecimal):
4
+ ''' defines a decimal of 'cf\''''
5
+ def __new__(self,value,cf=3):
6
+ '''you can set the floating precision of a value in curly braces {value:.3f} by doing {value:{three}f} where three is he variable containting the value 3
7
+ used for precision
8
+
9
+ value=1.234
10
+ cf=2
11
+ result=1.23
12
+ for the below assignment.
13
+
14
+ value=f"{value:.{cf}f}"
15
+ print(value)
16
+ '''
17
+
18
+ value=f"{value:.{cf}f}"
19
+ return super().__new__(self,value)
20
+
21
+ class dec3(TDecimal):
22
+ ''' defines a decimal of .3f'''
23
+ def __new__(self,value):
24
+ value=f"{value:.3f}"
25
+ return super().__new__(self,value)
26
+
27
+ class dec2(TDecimal):
28
+ ''' defines a decimal of .2f'''
29
+ def __new__(self,value):
30
+ value=f"{value:.3f}"
31
+ return super().__new__(self,value)
32
+
33
+ class dec1(TDecimal):
34
+ ''' defines a decimal of .1f'''
35
+ def __new__(self,value):
36
+ value=f"{value:.3f}"
37
+ return super().__new__(self,value)
38
+
39
+
40
+ class stre(str):
41
+ '''String Extended to include operators for some useful functionality.'''
42
+ def __invert__(self):
43
+ '''Generate a 512 Hex Digest for self'''
44
+ hl=hashlib.sha512()
45
+ hl.update(self.encode())
46
+ return str(hl.hexdigest())
47
+
48
+ def __sub__(self,other):
49
+ '''remove this many characters from the string, where a positive removes from the right and a negative removes from the left'''
50
+ if isinstance(other,int) or isinstance(other,float):
51
+ #print(other<0)
52
+ if other < 0:
53
+ return self[:other]
54
+ elif other > 0:
55
+ m=[self[i:i+1] for i in range(0,len(self),int(1))]
56
+ for i in range(0,other):
57
+ popped=m.pop(0)
58
+ return ''.join(m)
59
+ else:
60
+ raise NotImplemented
61
+
62
+ def __truediv__(self,other):
63
+ '''return a list broken into chunks of other'''
64
+ if isinstance(other,int) or isinstance(other,float):
65
+ return [self[i:i+other] for i in range(0,len(self),int(other))]
66
+ else:
67
+ raise NotImplemented
68
+
69
+ def __mod__(self,other):
70
+ #return the number of chunks
71
+ if isinstance(other,int) or isinstance(other,float):
72
+
73
+ return len([self[i:i+other] for i in range(0,len(self),int(other))])
74
+ else:
75
+ raise NotImplemented
76
+
77
+ def __floordiv__(self,other):
78
+ '''reverse of __truediv__'''
79
+ if isinstance(other,int) or isinstance(other,float):
80
+
81
+ return [ii for ii in reversed([self[i:i+other] for i in range(0,len(self),int(other))])]
82
+
83
+ else:
84
+ raise NotImplemented
85
+
86
+ def __pow__(self,other):
87
+ '''generate a random string from self of length other.'''
88
+
89
+ if isinstance(other,int) or isinstance(other,float):
90
+
91
+ src=[self[i:i+1] for i in range(0,len(self),int(1))]
92
+ end=''.join(random.choices(src,k=int(abs(other))))[:int(abs(other))]
93
+ while (len(end) < other) or (len(end) > other):
94
+ end=''.join(random.choices(src,k=int(abs(other))))[:int(abs(other))]
95
+ return end
96
+ else:
97
+ raise NotImplemented
98
+
radboy/__init__.py CHANGED
@@ -1 +1 @@
1
- VERSION='0.0.589'
1
+ VERSION='0.0.591'
Binary file
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: radboy
3
- Version: 0.0.589
3
+ Version: 0.0.591
4
4
  Summary: A Retail Calculator for Android/Linux
5
5
  Author: Carl Joseph Hirner III
6
6
  Author-email: Carl Hirner III <k.j.hirner.wisdom@gmail.com>
@@ -5,7 +5,7 @@ radboy/Holidays.txt,sha256=y-JZPihh5iaWKxMIHNXD39yVuVmf1vMs4FdNDcg0f1Y,3114
5
5
  radboy/InventoryGlossary.txt,sha256=018-Yqca6DFb10jPdkUY-5qhkRlQN1k3rxoTaERQ-LA,91008
6
6
  radboy/RecordMyCodes.py,sha256=Lt2reA6xchq3U7Y08DvkrHboZ25i1ts7X2E9gSIwcVg,41101
7
7
  radboy/Run.py,sha256=JUoCTHnzQBv7n8PB2_i93ANdAC_iW__RkAge8esCnk4,76
8
- radboy/__init__.py,sha256=I5WZuI64-SMy8ujrPJs8h7kBAp1jxuo3JPeoYgsFwQ0,17
8
+ radboy/__init__.py,sha256=iX8MG9tBTjo1SaYndj-xi8u8bP2nK1ksSvfHUG6i5VU,17
9
9
  radboy/api_key,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
10
10
  radboy/case-export-2024-05-14-13-10-00.672971.xlsx,sha256=Wd592d_VLFmfUI9KKKSVjNwjV91euc1T7ATyvwvUhlg,5431
11
11
  radboy/case-export-2024-05-14-13-13-22.540614.xlsx,sha256=OnGrhmScHfGp_mVaWW-LNMsqrQgyZDpiU3wV-2s3U5Q,5556
@@ -86,19 +86,20 @@ radboy/DB/ExerciseTracker.py,sha256=OS9i8jGIZPj-6m1bB0-eKNHQ6vf2iv_AYPEc0s4bkBM,
86
86
  radboy/DB/PayDay.py,sha256=H2kPGvBCDkMOz7lbxQhYtUt_oAInpxi37Q6MFrah98I,8710
87
87
  radboy/DB/PayModels.py,sha256=hjwWxP7PL33hmfzQl5YTf0HqzaMxXJxFknPdxFJXJc8,3499
88
88
  radboy/DB/PrintLogging.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
89
- radboy/DB/Prompt.py,sha256=JbPDqo51Zn3e2ed95BF1Mz3GXOf5QomCa_ADH5yGEEs,171935
89
+ radboy/DB/Prompt.py,sha256=kanBNzIZzd0Xlyr0sBQXdJsFp2eZ7tdSEgzm1ZWnAjk,172491
90
90
  radboy/DB/RandomStringUtil.py,sha256=eZCpR907WStgfbk4Evcghjv9hOkUDXH-iMXIq0-kXq8,24386
91
91
  radboy/DB/ResetTools.py,sha256=RbI-Ua7UlsN0S9qLqtEkTWvzyTZ6R-hHR3CW4NHlUPE,6660
92
92
  radboy/DB/SMLabelImporter.py,sha256=eUoBDxVUUEKGL2g_PwkASM67ZB7FmXtSnn4bCagskhY,4013
93
93
  radboy/DB/__init__.py,sha256=JiigA9B7GalP7YuRdcwyGDu5PDSBahoi0lLjtScxlN8,49
94
94
  radboy/DB/blankDataFile.py,sha256=YX_05Usi71UpDkZN9UTMYwUipbTndTAtEgqzBEga0kE,9285
95
95
  radboy/DB/config.py,sha256=bvu43dUl1_yO3Zq3gsLuenGUgJSiS3S9Cs6ppFEvZbg,239
96
- radboy/DB/db.py,sha256=OQRj5Ma11o413Fhnz8zfaKTC-8kwylOuDFdLMFJMs-4,256509
96
+ radboy/DB/db.py,sha256=YBmdo2dcovos6POsw3nNHRtt1t_y_3PwrV9Nh_j1Xy8,254771
97
97
  radboy/DB/glossary_db.py,sha256=1_qxeEpjjEtpWB_eDjsgJisimLv7OBm75MuqM-Lt6zg,28218
98
98
  radboy/DB/masterLookup.py,sha256=DBaM2uscG3_X5dek49wjdnOzhrjWhKgvOEz_umdz0mY,4566
99
99
  radboy/DB/msg.txt,sha256=YxWed6A6tuP1djJ5QPS2Rz3ING4TKKf8kUiCCPtzHXE,7937
100
100
  radboy/DB/renderText2Png.py,sha256=PWnTicLTfOPg9UlQYia3wMpjM9rh7MIyDVsmcsDRUBo,5678
101
101
  radboy/DB/testClass.py,sha256=t3zT1gbvReUncnPY8R9JUfKXQ5UEB2wmQx8DNeds0hI,310
102
+ radboy/DB/types.py,sha256=BjlUUgbvlB7QoZMzsET0Myj8_z4OGUlW5--Rl-lCszs,3258
102
103
  radboy/DB/__pycache__/DatePicker.cpython-311.pyc,sha256=VMJnJ7scb4VHMQi1HDZCF67KVYfb9m-fZK96IAoJzTQ,19676
103
104
  radboy/DB/__pycache__/DatePicker.cpython-312.pyc,sha256=cc5XWJ6Sbtcg0xWPz3SOP93VceIqr1pH42kjkLl5iYs,30294
104
105
  radboy/DB/__pycache__/DatePicker.cpython-313.pyc,sha256=jV__j5ER1oshsenGPynR0UNHWMI7VStgyw73-iLKxzg,33993
@@ -110,7 +111,7 @@ radboy/DB/__pycache__/FormBuilder.cpython-312.pyc,sha256=p1o-5SMRL8OXP_XQ5liUpf-
110
111
  radboy/DB/__pycache__/PrintLogging.cpython-312.pyc,sha256=pIAFqTi6OiQQORSc-oMH1zAbsdH7sY1TifxrN_QOvnU,148
111
112
  radboy/DB/__pycache__/Prompt.cpython-311.pyc,sha256=P2uPRpeqfLFtxieZ0JHBG3X_HZzWUCsFSLb_fpRqky0,6407
112
113
  radboy/DB/__pycache__/Prompt.cpython-312.pyc,sha256=6CcQ1gE2hcz3cKPjo4f6d7xNM2PTDnl8NzQG0Pme5BE,142886
113
- radboy/DB/__pycache__/Prompt.cpython-313.pyc,sha256=EEoEbgxWDcbIQV0sw884TyGpzHItzTincTIkhPYGjvo,256438
114
+ radboy/DB/__pycache__/Prompt.cpython-313.pyc,sha256=ZkuJvVxFfkqcBOh41eZl7FllvX_0Y7mwuRdV8A7fPAE,256865
114
115
  radboy/DB/__pycache__/RandomStringUtil.cpython-312.pyc,sha256=TrbEY89MuLmNlvoo5d8vOE6Dyshh5_EMlTZvk8MDVN4,48597
115
116
  radboy/DB/__pycache__/RandomStringUtil.cpython-313.pyc,sha256=MCcgVwV2Y-9rAY2FVaJZCKcou3HDX70EZudoiCigT0o,49217
116
117
  radboy/DB/__pycache__/ResetTools.cpython-311.pyc,sha256=4Vyc57iAAF0yRPjjglnVKovnTn8OoFIi6Zok3Wpj_YM,9292
@@ -128,7 +129,7 @@ radboy/DB/__pycache__/config.cpython-312.pyc,sha256=Qo7E6MHrF6yqvKgepNFyCoekZXiv
128
129
  radboy/DB/__pycache__/config.cpython-313.pyc,sha256=_8wCIg_3jhyJjxnExD2Sm6aY-uZTw036p7Ki5znL7dc,376
129
130
  radboy/DB/__pycache__/db.cpython-311.pyc,sha256=rNgigyBd0D-cg1JxKAS8t0B_k0IEJivgVlRaZE10Xis,210105
130
131
  radboy/DB/__pycache__/db.cpython-312.pyc,sha256=ANDJPC0RoavbmSKFxG15vC7B4rEGyVt7xRJt7XGY3OA,334609
131
- radboy/DB/__pycache__/db.cpython-313.pyc,sha256=7rrkdLvbMQLTrB5rioKk1h2NSLYA_aodLAymZ4xsRgI,404123
132
+ radboy/DB/__pycache__/db.cpython-313.pyc,sha256=7lRTDErah6dcVNn8sfdxY9ZNV66d4spF-k7m9ppSc_o,401608
132
133
  radboy/DB/__pycache__/glossary_db.cpython-312.pyc,sha256=8UL-29cKqtKovx0BANm6kzKKteef1BW_2qF3wumzst4,36023
133
134
  radboy/DB/__pycache__/glossary_db.cpython-313.pyc,sha256=Ke9bkvllGv5CK0JdT9DRvQ3MOdrXxoYv7TVLNkqLux0,36582
134
135
  radboy/DB/__pycache__/masterLookup.cpython-312.pyc,sha256=bQiOkmMwwHgcO18tYSWGQ-YUff4GQlKVhBMp1GoWAqY,6324
@@ -399,7 +400,7 @@ radboy/__pycache__/Run.cpython-311.pyc,sha256=G_UEfMtkLRjR6ZpGA_BJzGenuaCcP469Y9
399
400
  radboy/__pycache__/Run.cpython-312.pyc,sha256=v4xolc3mHyla991XhpYBUbBHYT0bnJ1gE-lkFoQ4GFA,241
400
401
  radboy/__pycache__/__init__.cpython-311.pyc,sha256=R-DVbUioMOW-Fnaq7FpT5F1a5p0q3b_RW-HpLRArCAY,242
401
402
  radboy/__pycache__/__init__.cpython-312.pyc,sha256=FsFzLXOlTK8_7ixoPZzakkR8Wibt-DvXLFh-oG2QlPw,164
402
- radboy/__pycache__/__init__.cpython-313.pyc,sha256=7qUKXjHf4XCazIjw2OejHez_lo-oAdYnyioww4V_iRM,165
403
+ radboy/__pycache__/__init__.cpython-313.pyc,sha256=PSEyVkLDbL5GiU1xCgY_1AjExRYzG81Y5Cw8F0zm-yI,165
403
404
  radboy/__pycache__/__init__.cpython-39.pyc,sha256=D48T6x6FUeKPfubo0sdS_ZUut3FmBvPMP7qT6rYBZzU,275
404
405
  radboy/__pycache__/possibleCode.cpython-311.pyc,sha256=zFiHyzqD8gUnIWu4vtyMYIBposiRQqaRXfcT_fOl4rU,20882
405
406
  radboy/__pycache__/possibleCode.cpython-312.pyc,sha256=tk_CO-AcsO3YZj5j6vEsw3g37UmEzWc5YgeWEoJEUg4,27922
@@ -427,7 +428,7 @@ radboy/tkGui/Images/__pycache__/__init__.cpython-311.pyc,sha256=tXBYpqbOlZ24B1BI
427
428
  radboy/tkGui/__pycache__/BeginnersLuck.cpython-311.pyc,sha256=xLQOnV1wuqHGaub16mPX0dDMGU9ryCeLtNz5e517_GE,3004
428
429
  radboy/tkGui/__pycache__/Review.cpython-311.pyc,sha256=wKq24iM6Xe2OampgZ7-8U6Nvmgs2y-qWOrGwtWhc75k,4047
429
430
  radboy/tkGui/__pycache__/__init__.cpython-311.pyc,sha256=BX7DBn5qbvKTvlrKOP5gzTBPBTeTgSMjBW6EMl7N8e0,230
430
- radboy-0.0.589.dist-info/METADATA,sha256=e79vk85RlCVNZIoac92F-BU_spa3ongIXxFVDFO-s_0,1662
431
- radboy-0.0.589.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
432
- radboy-0.0.589.dist-info/top_level.txt,sha256=mlM0RWMUxGo1YHnlLmYrHOgGdK4XNRpr7nMFD5lR56c,7
433
- radboy-0.0.589.dist-info/RECORD,,
431
+ radboy-0.0.591.dist-info/METADATA,sha256=Sv7F5FDS3o9JuG-IczzlGUGNkxH8Ppz2LaCFob40ebA,1662
432
+ radboy-0.0.591.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
433
+ radboy-0.0.591.dist-info/top_level.txt,sha256=mlM0RWMUxGo1YHnlLmYrHOgGdK4XNRpr7nMFD5lR56c,7
434
+ radboy-0.0.591.dist-info/RECORD,,