Skip to content

bug: KeyError: 'scale' upon compilation of script #27

@AgentM12

Description

@AgentM12

I encounter the following error when running the compile.py:

Compiler encountered unexpected error during compilation:
Traceback (most recent call last):
  File "D:\Dev\Minecraft\CBScript\cbscript\cbscript.py", line 70, in try_to_compile
    success = self.compile_all()
  File "D:\Dev\Minecraft\CBScript\cbscript\cbscript.py", line 106, in compile_all
    global_environment.set_dollarid('global_scale', parsed['scale'])
KeyError: 'scale'

This can be resolved by defining the scale 1 in your cbscript. I don't know what this scale is used for, so it might be a good idea to give it an implicit default value of 1 (or whatever is the most sensible default) rather than failing the compilation.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions