easycoder 250123.1__py2.py3-none-any.whl → 250126.1__py2.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 easycoder might be problematic. Click here for more details.
- easycoder/__init__.py +1 -1
- easycoder/ec_core.py +20 -10
- {easycoder-250123.1.dist-info → easycoder-250126.1.dist-info}/METADATA +2 -2
- {easycoder-250123.1.dist-info → easycoder-250126.1.dist-info}/RECORD +7 -7
- {easycoder-250123.1.dist-info → easycoder-250126.1.dist-info}/WHEEL +1 -1
- {easycoder-250123.1.dist-info → easycoder-250126.1.dist-info}/LICENSE +0 -0
- {easycoder-250123.1.dist-info → easycoder-250126.1.dist-info}/entry_points.txt +0 -0
easycoder/__init__.py
CHANGED
easycoder/ec_core.py
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import json, math, hashlib, threading, os, subprocess, sys, requests, time, numbers, base64
|
|
1
|
+
import json, math, hashlib, threading, os, subprocess, sys, requests, time, numbers, base64, binascii
|
|
2
2
|
from psutil import Process
|
|
3
3
|
from datetime import datetime, timezone
|
|
4
4
|
from random import randrange
|
|
@@ -484,7 +484,6 @@ class Core(Handler):
|
|
|
484
484
|
except:
|
|
485
485
|
pass
|
|
486
486
|
RuntimeError(self.program, f'There is no label "{label}"')
|
|
487
|
-
return None
|
|
488
487
|
|
|
489
488
|
def r_gotoPC(self, command):
|
|
490
489
|
return command['goto']
|
|
@@ -499,12 +498,14 @@ class Core(Handler):
|
|
|
499
498
|
|
|
500
499
|
def r_gosub(self, command):
|
|
501
500
|
label = command['gosub'] + ':'
|
|
502
|
-
|
|
503
|
-
|
|
504
|
-
|
|
505
|
-
|
|
506
|
-
|
|
507
|
-
|
|
501
|
+
try:
|
|
502
|
+
address = self.symbols[label]
|
|
503
|
+
if address != None:
|
|
504
|
+
self.stack.append(self.nextPC())
|
|
505
|
+
return address
|
|
506
|
+
except:
|
|
507
|
+
pass
|
|
508
|
+
RuntimeError(self.program, f'There is no label "{label}"')
|
|
508
509
|
|
|
509
510
|
# if <condition> <action> [else <action>]
|
|
510
511
|
def k_if(self, command):
|
|
@@ -1001,9 +1002,10 @@ class Core(Handler):
|
|
|
1001
1002
|
value = self.getRuntimeValue(command['value'])
|
|
1002
1003
|
program = command['program']
|
|
1003
1004
|
code = program.code[program.pc]
|
|
1004
|
-
lino = code['lino'] + 1
|
|
1005
|
+
lino = str(code['lino'] + 1)
|
|
1006
|
+
while len(lino) < 5: lino = f' {lino}'
|
|
1005
1007
|
if value == None: value = '<empty>'
|
|
1006
|
-
if 'log' in command: print(f'{datetime.now().time()}:
|
|
1008
|
+
if 'log' in command: print(f'{datetime.now().time()}:{lino}-> {value}')
|
|
1007
1009
|
else: print(value)
|
|
1008
1010
|
return self.nextPC()
|
|
1009
1011
|
|
|
@@ -1987,6 +1989,10 @@ class Core(Handler):
|
|
|
1987
1989
|
value['type'] = 'text'
|
|
1988
1990
|
if self.encoding == 'utf-8':
|
|
1989
1991
|
value['content'] = content.decode('utf-8')
|
|
1992
|
+
elif self.encoding == 'hex':
|
|
1993
|
+
b = content.encode('utf-8')
|
|
1994
|
+
mb = binascii.unhexlify(b)
|
|
1995
|
+
value['content'] = mb.decode('utf-8')
|
|
1990
1996
|
elif self.encoding == 'base64':
|
|
1991
1997
|
base64_bytes = content.encode('ascii')
|
|
1992
1998
|
message_bytes = base64.b64decode(base64_bytes)
|
|
@@ -2030,6 +2036,10 @@ class Core(Handler):
|
|
|
2030
2036
|
value['type'] = 'text'
|
|
2031
2037
|
if self.encoding == 'utf-8':
|
|
2032
2038
|
value['content'] = content.encode('utf-8')
|
|
2039
|
+
elif self.encoding == 'hex':
|
|
2040
|
+
b = content.encode('utf-8')
|
|
2041
|
+
mb = binascii.hexlify(b)
|
|
2042
|
+
value['content'] = mb.decode('utf-8')
|
|
2033
2043
|
elif self.encoding == 'base64':
|
|
2034
2044
|
data_bytes = content.encode('ascii')
|
|
2035
2045
|
base64_bytes = base64.b64encode(data_bytes)
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
Metadata-Version: 2.
|
|
1
|
+
Metadata-Version: 2.3
|
|
2
2
|
Name: easycoder
|
|
3
|
-
Version:
|
|
3
|
+
Version: 250126.1
|
|
4
4
|
Summary: Rapid scripting in English
|
|
5
5
|
Keywords: compiler,scripting,prototyping,programming,coding,python,low code,hypertalk,computer language,learn to code
|
|
6
6
|
Author-email: Graham Trott <gtanyware@gmail.com>
|
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
easycoder/README.md,sha256=PYqOc_SkIGiFbyCNs90y7JqoqWe4aO1xYIW-6bOnFKU,573
|
|
2
|
-
easycoder/__init__.py,sha256=
|
|
2
|
+
easycoder/__init__.py,sha256=7blwInEm57sQkA8ubHAOO5NaWltFnOaWw8hAAN-7rEw,262
|
|
3
3
|
easycoder/ec_classes.py,sha256=xnWBNak8oKydkFoxHLlq9wo3lIsB3aMnTDrqbtCfoWo,1512
|
|
4
4
|
easycoder/ec_compiler.py,sha256=dFJEA_uOhD-HeSiAdBzmmA6q3LHThUVoJpSETanmSHs,4800
|
|
5
5
|
easycoder/ec_condition.py,sha256=WSbONo4zs2sX1icOVpscZDFSCAEFmTsquoc2RGcLx_k,763
|
|
6
|
-
easycoder/ec_core.py,sha256=
|
|
6
|
+
easycoder/ec_core.py,sha256=ORrMf2TlsAxETK-5Of-zrSCHX517nVHtThI7ew9ts0o,87416
|
|
7
7
|
easycoder/ec_graphics.py,sha256=KbLbhNDr-DjKKy8RbkzpBogvz30FXFOsmQUJxFcBg4E,23718
|
|
8
8
|
easycoder/ec_gutils.py,sha256=cREktnAoHd_1t_fDgrnQ1F60n_TzFTGvoXJeWc_LJo4,5068
|
|
9
9
|
easycoder/ec_handler.py,sha256=IJvxcrJJSR53d6DS_8H5qPHKhp9y5-GV4WXAjhZxu_o,2250
|
|
10
10
|
easycoder/ec_program.py,sha256=R8zMukA-pfRsOpcy9WqTw7fE_190dQfrMt2la23Yrs4,9904
|
|
11
11
|
easycoder/ec_timestamp.py,sha256=_3QFJPzIWZ9Rzk3SQOQJ-gwmvB07pg78k23SPntoZtY,288
|
|
12
12
|
easycoder/ec_value.py,sha256=zgDJTJhIg3yOvmnnKIfccIizmIhGbtvL_ghLTL1T5fg,2516
|
|
13
|
-
easycoder-
|
|
14
|
-
easycoder-
|
|
15
|
-
easycoder-
|
|
16
|
-
easycoder-
|
|
17
|
-
easycoder-
|
|
13
|
+
easycoder-250126.1.dist-info/entry_points.txt,sha256=JXAZbenl0TnsIft2FcGJbJ-4qoztVu2FuT8PFmWFexM,44
|
|
14
|
+
easycoder-250126.1.dist-info/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
|
|
15
|
+
easycoder-250126.1.dist-info/WHEEL,sha256=ssQ84EZ5gH1pCOujd3iW7HClo_O_aDaClUbX4B8bjKY,100
|
|
16
|
+
easycoder-250126.1.dist-info/METADATA,sha256=9Tbknq92pjycV1Lp3HYqrXldtHsRVOxVYif_KKeqRAQ,6162
|
|
17
|
+
easycoder-250126.1.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|