easycoder 250105.1__py2.py3-none-any.whl → 250106.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_compiler.py +1 -1
- easycoder/ec_core.py +0 -1
- easycoder/ec_graphics.py +11 -8
- easycoder/ec_screenspec.py +4 -7
- easycoder/ec_value.py +2 -2
- {easycoder-250105.1.dist-info → easycoder-250106.1.dist-info}/METADATA +2 -2
- easycoder-250106.1.dist-info/RECORD +19 -0
- easycoder-250105.1.dist-info/RECORD +0 -19
- {easycoder-250105.1.dist-info → easycoder-250106.1.dist-info}/LICENSE +0 -0
- {easycoder-250105.1.dist-info → easycoder-250106.1.dist-info}/WHEEL +0 -0
- {easycoder-250105.1.dist-info → easycoder-250106.1.dist-info}/entry_points.txt +0 -0
easycoder/__init__.py
CHANGED
easycoder/ec_compiler.py
CHANGED
|
@@ -102,7 +102,7 @@ class Compiler:
|
|
|
102
102
|
|
|
103
103
|
def showWarnings(self):
|
|
104
104
|
for warning in self.warnings:
|
|
105
|
-
print(f'Warning at line {self.getLino() + 1}
|
|
105
|
+
print(f'Warning at line {self.getLino() + 1} of {self.program.name}: {warning}')
|
|
106
106
|
|
|
107
107
|
def getSymbolRecord(self):
|
|
108
108
|
token = self.getToken()
|
easycoder/ec_core.py
CHANGED
easycoder/ec_graphics.py
CHANGED
|
@@ -36,7 +36,7 @@ class Graphics(Handler):
|
|
|
36
36
|
FatalError(self.program.compiler, f'There is no screen element with id \'{id}\'')
|
|
37
37
|
return -1
|
|
38
38
|
if element.getType() != keyword:
|
|
39
|
-
FatalError(self.program.compiler, f'Mismatched element type
|
|
39
|
+
FatalError(self.program.compiler, f'Mismatched element type: \'{element['type']}\' and \'{keyword}\'')
|
|
40
40
|
self.putSymbolValue(targetRecord, {'type': 'text', 'content': id})
|
|
41
41
|
return self.nextPC()
|
|
42
42
|
|
|
@@ -301,13 +301,22 @@ class Graphics(Handler):
|
|
|
301
301
|
# render {spec}
|
|
302
302
|
def k_render(self, command):
|
|
303
303
|
command['spec'] = self.nextValue()
|
|
304
|
+
command['parent'] = None
|
|
305
|
+
if self.peek() == 'in':
|
|
306
|
+
self.nextToken()
|
|
307
|
+
if self.nextIsSymbol():
|
|
308
|
+
command['parent'] = self.getSymbolRecord()['name']
|
|
304
309
|
self.add(command)
|
|
305
310
|
return True
|
|
306
311
|
|
|
307
312
|
def r_render(self, command):
|
|
313
|
+
spec = self.getRuntimeValue(command['spec'])
|
|
314
|
+
parent = command['parent']
|
|
315
|
+
if parent !=None:
|
|
316
|
+
parent = self.getVariable(command['parent'])
|
|
308
317
|
self.ui = self.renderer.getUI()
|
|
309
318
|
try:
|
|
310
|
-
ScreenSpec().render(
|
|
319
|
+
ScreenSpec().render(spec, parent, self.ui)
|
|
311
320
|
except Exception as e:
|
|
312
321
|
RuntimeError(self.program, e)
|
|
313
322
|
return self.nextPC()
|
|
@@ -316,12 +325,6 @@ class Graphics(Handler):
|
|
|
316
325
|
def k_run(self, command):
|
|
317
326
|
if self.nextIs('graphics'):
|
|
318
327
|
self.add(command)
|
|
319
|
-
cmd = {}
|
|
320
|
-
cmd['domain'] = 'graphics'
|
|
321
|
-
cmd['lino'] = command['lino'] + 1
|
|
322
|
-
cmd['keyword'] = 'getui'
|
|
323
|
-
cmd['debug'] = False
|
|
324
|
-
self.addCommand(cmd)
|
|
325
328
|
return True
|
|
326
329
|
return False
|
|
327
330
|
|
easycoder/ec_screenspec.py
CHANGED
|
@@ -61,17 +61,14 @@ class ScreenSpec():
|
|
|
61
61
|
self.createWidget(spec[widgets], parent)
|
|
62
62
|
|
|
63
63
|
# Render a graphic specification
|
|
64
|
-
def render(self, spec, ui):
|
|
64
|
+
def render(self, spec, parent, ui):
|
|
65
65
|
self.ui = ui
|
|
66
66
|
|
|
67
67
|
# If it'a string, process it
|
|
68
68
|
if isinstance(spec, str):
|
|
69
|
-
self.renderSpec(loads(spec),
|
|
69
|
+
self.renderSpec(loads(spec), parent)
|
|
70
70
|
|
|
71
71
|
# If it's a 'dict', extract the spec and the args
|
|
72
|
-
elif isinstance(spec, dict):
|
|
73
|
-
spec = loads(spec['spec'])
|
|
74
|
-
self.renderSpec(spec, None)
|
|
75
|
-
|
|
76
72
|
else:
|
|
77
|
-
|
|
73
|
+
self.renderSpec(spec, parent)
|
|
74
|
+
|
easycoder/ec_value.py
CHANGED
|
@@ -51,14 +51,14 @@ class Value:
|
|
|
51
51
|
if item != None:
|
|
52
52
|
return item
|
|
53
53
|
self.compiler.rewindTo(mark)
|
|
54
|
-
self.compiler.warning(f'I don\'t understand \'{token}\'')
|
|
54
|
+
# self.compiler.warning(f'I don\'t understand \'{token}\'')
|
|
55
55
|
return None
|
|
56
56
|
|
|
57
57
|
def compileValue(self):
|
|
58
58
|
token = self.getToken()
|
|
59
59
|
item = self.getItem()
|
|
60
60
|
if item == None:
|
|
61
|
-
|
|
61
|
+
self.compiler.warning(f'ec_value.compileValue: Cannot get the value of "{token}"')
|
|
62
62
|
return None
|
|
63
63
|
|
|
64
64
|
value = {}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.3
|
|
2
2
|
Name: easycoder
|
|
3
|
-
Version:
|
|
3
|
+
Version: 250106.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>
|
|
@@ -77,7 +77,7 @@ A couple of demo graphical scripts are included in the `scripts` directory:
|
|
|
77
77
|
|
|
78
78
|
- English-like syntax based on vocabulary rather than structure. Scripts can be read as English
|
|
79
79
|
- Comprehensive feature set
|
|
80
|
-
- Runs directly from source scripts
|
|
80
|
+
- Runs directly from source scripts. A fast compiler creates efficient intermediate code that runs immediately after compilation
|
|
81
81
|
- Low memory requirements
|
|
82
82
|
- Minimim dependency on other 3rd-party packages
|
|
83
83
|
- Built-in co-operative multitasking
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
easycoder/README.md,sha256=PYqOc_SkIGiFbyCNs90y7JqoqWe4aO1xYIW-6bOnFKU,573
|
|
2
|
+
easycoder/__init__.py,sha256=u2dEU1qq40I2Vup406FRLdBF3epWlAh8_eZTKN-_2gI,283
|
|
3
|
+
easycoder/ec.py,sha256=Nj5PRl8GsKjfGJKq0FOM1a7FeK3cN68CoIFg8lswQEg,221
|
|
4
|
+
easycoder/ec_classes.py,sha256=xnWBNak8oKydkFoxHLlq9wo3lIsB3aMnTDrqbtCfoWo,1512
|
|
5
|
+
easycoder/ec_compiler.py,sha256=f3zZRtbNsegBuRHTvTLK8BOdnuRq5p_p-1vtJYb-LiY,4800
|
|
6
|
+
easycoder/ec_condition.py,sha256=WSbONo4zs2sX1icOVpscZDFSCAEFmTsquoc2RGcLx_k,763
|
|
7
|
+
easycoder/ec_core.py,sha256=71rSNOwMrO0Ik1hdgTshOYRo2XVD0Br7gUZfCR7A0OA,86291
|
|
8
|
+
easycoder/ec_graphics.py,sha256=ez7wilpaVn8DlTcsy8kGE0RKl0_Gkl1qks8phtMNoLE,16568
|
|
9
|
+
easycoder/ec_handler.py,sha256=IJvxcrJJSR53d6DS_8H5qPHKhp9y5-GV4WXAjhZxu_o,2250
|
|
10
|
+
easycoder/ec_program.py,sha256=sdVPc1c8urLn5icov-NVyNkc78UR930ipDDONlZTge8,9831
|
|
11
|
+
easycoder/ec_renderer.py,sha256=oZ56OyJojQq-2ZPlVMFOrEyG_vj91D4yv9Nd5m92RQA,8031
|
|
12
|
+
easycoder/ec_screenspec.py,sha256=qNqhbP16gAi2cRUD3W0dpb8tTC4-N4mE2l6HtOG0vbc,2405
|
|
13
|
+
easycoder/ec_timestamp.py,sha256=_3QFJPzIWZ9Rzk3SQOQJ-gwmvB07pg78k23SPntoZtY,288
|
|
14
|
+
easycoder/ec_value.py,sha256=7yJovn24pPC3jrURSQyEvZ8m826fXiqxsCpSvxwNrfQ,2403
|
|
15
|
+
easycoder-250106.1.dist-info/entry_points.txt,sha256=JXAZbenl0TnsIft2FcGJbJ-4qoztVu2FuT8PFmWFexM,44
|
|
16
|
+
easycoder-250106.1.dist-info/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
|
|
17
|
+
easycoder-250106.1.dist-info/WHEEL,sha256=ssQ84EZ5gH1pCOujd3iW7HClo_O_aDaClUbX4B8bjKY,100
|
|
18
|
+
easycoder-250106.1.dist-info/METADATA,sha256=-a4_tzNu8_1LdkCoZ19WEsk84V-hafKP4VJvBGs_428,5817
|
|
19
|
+
easycoder-250106.1.dist-info/RECORD,,
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
easycoder/README.md,sha256=PYqOc_SkIGiFbyCNs90y7JqoqWe4aO1xYIW-6bOnFKU,573
|
|
2
|
-
easycoder/__init__.py,sha256=owNA7S9z8wlR3KRxJytrzPU-s4ngA04Xq8_EUinKwK8,283
|
|
3
|
-
easycoder/ec.py,sha256=Nj5PRl8GsKjfGJKq0FOM1a7FeK3cN68CoIFg8lswQEg,221
|
|
4
|
-
easycoder/ec_classes.py,sha256=xnWBNak8oKydkFoxHLlq9wo3lIsB3aMnTDrqbtCfoWo,1512
|
|
5
|
-
easycoder/ec_compiler.py,sha256=_xBh2L47mz_WOMYdruMYSHyyz2wfh7Hf28q559AWVSU,4781
|
|
6
|
-
easycoder/ec_condition.py,sha256=WSbONo4zs2sX1icOVpscZDFSCAEFmTsquoc2RGcLx_k,763
|
|
7
|
-
easycoder/ec_core.py,sha256=5woFkLx9divJomakFyeexmhqJeEPI1hUlzyB3MlAruI,86359
|
|
8
|
-
easycoder/ec_graphics.py,sha256=ylkdEOo04g8aOeY9xB1V9mf3aZWkoIUt-caXivuVje4,16427
|
|
9
|
-
easycoder/ec_handler.py,sha256=IJvxcrJJSR53d6DS_8H5qPHKhp9y5-GV4WXAjhZxu_o,2250
|
|
10
|
-
easycoder/ec_program.py,sha256=sdVPc1c8urLn5icov-NVyNkc78UR930ipDDONlZTge8,9831
|
|
11
|
-
easycoder/ec_renderer.py,sha256=oZ56OyJojQq-2ZPlVMFOrEyG_vj91D4yv9Nd5m92RQA,8031
|
|
12
|
-
easycoder/ec_screenspec.py,sha256=TeXgccfYoE--r7Rf9t9drV1V3fU-p-iBnZwtjHzIh8M,2524
|
|
13
|
-
easycoder/ec_timestamp.py,sha256=_3QFJPzIWZ9Rzk3SQOQJ-gwmvB07pg78k23SPntoZtY,288
|
|
14
|
-
easycoder/ec_value.py,sha256=KkSIxAum-bnb_qnaRgS1UiVUg_-khVPQrrEPiSXjQs4,2382
|
|
15
|
-
easycoder-250105.1.dist-info/entry_points.txt,sha256=JXAZbenl0TnsIft2FcGJbJ-4qoztVu2FuT8PFmWFexM,44
|
|
16
|
-
easycoder-250105.1.dist-info/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
|
|
17
|
-
easycoder-250105.1.dist-info/WHEEL,sha256=ssQ84EZ5gH1pCOujd3iW7HClo_O_aDaClUbX4B8bjKY,100
|
|
18
|
-
easycoder-250105.1.dist-info/METADATA,sha256=hm-vw2r4-nH5eaa8ouO0Qpdx9nyeNFK60iXwS41GDxg,5817
|
|
19
|
-
easycoder-250105.1.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|