KL-Py 0.7.4__tar.gz → 0.7.5__tar.gz
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.
- {kl_py-0.7.4 → kl_py-0.7.5}/PKG-INFO +1 -1
- {kl_py-0.7.4 → kl_py-0.7.5}/pyproject.toml +1 -1
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/KL_Py.py +29 -2
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/_translate.py +115 -30
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py.egg-info/PKG-INFO +1 -1
- {kl_py-0.7.4 → kl_py-0.7.5}/LICENSE +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/README.md +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/setup.cfg +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/FreeSimpleGUI/__init__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/FreeSimpleGUI/_utils.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/FreeSimpleGUI/elements/__init__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/FreeSimpleGUI/elements/base.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/FreeSimpleGUI/elements/button.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/FreeSimpleGUI/elements/calendar.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/FreeSimpleGUI/elements/canvas.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/FreeSimpleGUI/elements/checkbox.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/FreeSimpleGUI/elements/column.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/FreeSimpleGUI/elements/combo.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/FreeSimpleGUI/elements/error.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/FreeSimpleGUI/elements/frame.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/FreeSimpleGUI/elements/graph.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/FreeSimpleGUI/elements/helpers.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/FreeSimpleGUI/elements/image.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/FreeSimpleGUI/elements/input.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/FreeSimpleGUI/elements/list_box.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/FreeSimpleGUI/elements/menu.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/FreeSimpleGUI/elements/multiline.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/FreeSimpleGUI/elements/option_menu.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/FreeSimpleGUI/elements/pane.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/FreeSimpleGUI/elements/progress_bar.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/FreeSimpleGUI/elements/radio.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/FreeSimpleGUI/elements/separator.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/FreeSimpleGUI/elements/sizegrip.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/FreeSimpleGUI/elements/slider.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/FreeSimpleGUI/elements/spin.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/FreeSimpleGUI/elements/status_bar.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/FreeSimpleGUI/elements/stretch.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/FreeSimpleGUI/elements/tab.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/FreeSimpleGUI/elements/table.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/FreeSimpleGUI/elements/text.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/FreeSimpleGUI/elements/tree.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/FreeSimpleGUI/themes.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/FreeSimpleGUI/tray.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/FreeSimpleGUI/window.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/__init__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/_custom_pandas.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/_custom_sqlite.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/_custom_turtle.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/_error_classes.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/_filepaths.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/_klang_builtins.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/_web_translate.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/automl.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/dnd/__init__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/drag_and_drop/__init__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/export/__init__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/export/__main__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/export/config.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/export/dialogs.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/export/packaging.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/export/shims.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/export/ui.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/export/utils.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/export/validation.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/fa/__init__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/fsgdnd/__init__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/fsgui/__init__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/hindGui/__init__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/hindGui/_utils.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/hindGui/elements/base.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/hindGui/elements/button.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/hindGui/elements/calendar.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/hindGui/elements/canvas.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/hindGui/elements/center.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/hindGui/elements/checkbox.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/hindGui/elements/column.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/hindGui/elements/combo.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/hindGui/elements/error.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/hindGui/elements/frame.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/hindGui/elements/graph.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/hindGui/elements/helpers.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/hindGui/elements/image.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/hindGui/elements/input.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/hindGui/elements/list_box.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/hindGui/elements/menu.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/hindGui/elements/multiline.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/hindGui/elements/option_menu.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/hindGui/elements/pane.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/hindGui/elements/progress_bar.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/hindGui/elements/radio.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/hindGui/elements/separator.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/hindGui/elements/sizegrip.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/hindGui/elements/slider.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/hindGui/elements/spin.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/hindGui/elements/status_bar.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/hindGui/elements/stretch.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/hindGui/elements/tab.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/hindGui/elements/table.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/hindGui/elements/text.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/hindGui/elements/tree.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/hindGui/replace.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/hindGui/tray.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/hindGui/window.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/k2exe/__init__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/k2exe/__main__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/k2exe/config.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/k2exe/dialogs.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/k2exe/packaging.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/k2exe/shims.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/k2exe/ui.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/k2exe/utils.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/k2exe/validation.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/kexe/__init__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/kexe/__main__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/kexe/config.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/kexe/dialogs.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/kexe/packaging.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/kexe/shims.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/kexe/ui.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/kexe/utils.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/kexe/validation.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/kl2exe/__init__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/kl2exe/__main__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/kl2exe/config.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/kl2exe/dialogs.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/kl2exe/packaging.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/kl2exe/shims.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/kl2exe/ui.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/kl2exe/utils.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/kl2exe/validation.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/klang2exe/__init__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/klang2exe/__main__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/klang2exe/config.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/klang2exe/dialogs.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/klang2exe/packaging.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/klang2exe/shims.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/klang2exe/ui.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/klang2exe/utils.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/klang2exe/validation.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/klangexe/__init__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/klangexe/__main__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/klangexe/config.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/klangexe/dialogs.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/klangexe/packaging.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/klangexe/shims.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/klangexe/ui.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/klangexe/utils.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/klangexe/validation.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/klexe/__init__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/klexe/__main__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/klexe/config.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/klexe/dialogs.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/klexe/packaging.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/klexe/shims.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/klexe/ui.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/klexe/utils.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/klexe/validation.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/ml.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/np/__init__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/pd/__init__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/plt/__init__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/psgui/__init__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/px/__init__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/pyexe/__init__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/pyexe/__main__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/pyexe/config.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/pyexe/dialogs.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/pyexe/packaging.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/pyexe/shims.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/pyexe/ui.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/pyexe/utils.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/pyexe/validation.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/pysgdnd/__init__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/__init__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/__version__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/_internal_utils.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/adapters.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/api.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/auth.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/backports/zstd/__init__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/backports/zstd/__init__.pyi +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/backports/zstd/_cffi/__init__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/backports/zstd/_cffi/_blocks_output_buffer.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/backports/zstd/_cffi/_common.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/backports/zstd/_cffi/buffer.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/backports/zstd/_cffi/compressor.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/backports/zstd/_cffi/decompressor.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/backports/zstd/_cffi/zstddict.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/backports/zstd/_compat.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/backports/zstd/_shutil.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/backports/zstd/_streams.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/backports/zstd/_zstd.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/backports/zstd/_zstdfile.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/backports/zstd/py.typed +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/backports/zstd/tarfile.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/backports/zstd/tarfile.pyi +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/backports/zstd/zipfile/__init__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/backports/zstd/zipfile/__init__.pyi +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/backports/zstd/zipfile/__main__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/backports/zstd/zipfile/_path/__init__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/backports/zstd/zipfile/_path/__init__.pyi +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/backports/zstd/zipfile/_path/glob.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/backports/zstd/zipfile/_path/glob.pyi +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/certifi/__init__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/certifi/__main__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/certifi/core.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/certifi/py.typed +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/certs.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/charset_normalizer/__init__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/charset_normalizer/__main__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/charset_normalizer/api.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/charset_normalizer/cd.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/charset_normalizer/cli/__init__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/charset_normalizer/cli/__main__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/charset_normalizer/constant.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/charset_normalizer/legacy.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/charset_normalizer/md.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/charset_normalizer/models.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/charset_normalizer/py.typed +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/charset_normalizer/utils.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/charset_normalizer/version.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/compat.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/cookies.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/exceptions.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/help.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/hooks.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/idna/__init__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/idna/codec.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/idna/compat.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/idna/core.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/idna/idnadata.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/idna/intranges.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/idna/package_data.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/idna/py.typed +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/idna/uts46data.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/models.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/packages.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/sessions.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/simplejson/__init__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/simplejson/compat.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/simplejson/decoder.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/simplejson/encoder.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/simplejson/errors.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/simplejson/ordered_dict.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/simplejson/raw_json.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/simplejson/scanner.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/simplejson/tests/__init__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/simplejson/tests/_cibw_runner.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/simplejson/tests/_helpers.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/simplejson/tests/test_bigint_as_string.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/simplejson/tests/test_bitsize_int_as_string.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/simplejson/tests/test_check_circular.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/simplejson/tests/test_decimal.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/simplejson/tests/test_decode.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/simplejson/tests/test_default.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/simplejson/tests/test_dump.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/simplejson/tests/test_encode_basestring_ascii.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/simplejson/tests/test_encode_for_html.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/simplejson/tests/test_errors.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/simplejson/tests/test_fail.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/simplejson/tests/test_float.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/simplejson/tests/test_for_json.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/simplejson/tests/test_free_threading.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/simplejson/tests/test_indent.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/simplejson/tests/test_item_sort_key.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/simplejson/tests/test_iterable.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/simplejson/tests/test_namedtuple.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/simplejson/tests/test_pass1.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/simplejson/tests/test_pass2.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/simplejson/tests/test_pass3.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/simplejson/tests/test_raw_json.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/simplejson/tests/test_recursion.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/simplejson/tests/test_scanstring.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/simplejson/tests/test_separators.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/simplejson/tests/test_speedups.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/simplejson/tests/test_str_subclass.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/simplejson/tests/test_subclass.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/simplejson/tests/test_subinterpreters.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/simplejson/tests/test_tool.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/simplejson/tests/test_tuple.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/simplejson/tests/test_unicode.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/simplejson/tool.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/status_codes.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/structures.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/urllib3/__init__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/urllib3/_base_connection.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/urllib3/_collections.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/urllib3/_request_methods.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/urllib3/_version.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/urllib3/connection.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/urllib3/connectionpool.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/urllib3/contrib/__init__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/urllib3/contrib/emscripten/__init__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/urllib3/contrib/emscripten/connection.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/urllib3/contrib/emscripten/fetch.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/urllib3/contrib/emscripten/request.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/urllib3/contrib/emscripten/response.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/urllib3/contrib/pyopenssl.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/urllib3/contrib/socks.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/urllib3/exceptions.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/urllib3/fields.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/urllib3/filepost.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/urllib3/http2/__init__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/urllib3/http2/connection.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/urllib3/http2/probe.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/urllib3/poolmanager.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/urllib3/py.typed +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/urllib3/response.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/urllib3/util/__init__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/urllib3/util/connection.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/urllib3/util/proxy.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/urllib3/util/request.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/urllib3/util/response.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/urllib3/util/retry.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/urllib3/util/ssl_.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/urllib3/util/ssl_match_hostname.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/urllib3/util/ssltransport.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/urllib3/util/timeout.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/urllib3/util/url.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/urllib3/util/util.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/urllib3/util/wait.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/requests/utils.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/sb/__init__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/sk/__init__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/sns/__init__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/tc/__init__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/toexe/__init__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/toexe/__main__.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/toexe/config.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/toexe/dialogs.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/toexe/packaging.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/toexe/shims.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/toexe/ui.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/toexe/utils.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/toexe/validation.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py/when.py +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py.egg-info/SOURCES.txt +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py.egg-info/dependency_links.txt +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py.egg-info/requires.txt +0 -0
- {kl_py-0.7.4 → kl_py-0.7.5}/src/KL_Py.egg-info/top_level.txt +0 -0
|
@@ -34,8 +34,9 @@ ListLikeIterable =\
|
|
|
34
34
|
IterableList =\
|
|
35
35
|
list | tuple | set | frozenset
|
|
36
36
|
Akhri = Musalsal = musalsal = final = Final
|
|
37
|
-
Option = Optional
|
|
37
|
+
Option = optional = Optional
|
|
38
38
|
koi_na = None
|
|
39
|
+
null = none = None
|
|
39
40
|
KoiNa = type(None)
|
|
40
41
|
Kism = Class = Type = type
|
|
41
42
|
home_path_obj: Path = Path.home()
|
|
@@ -10785,4 +10786,30 @@ if __name__ == "__main__":
|
|
|
10785
10786
|
user = obj(name=f"Mike", age=51)
|
|
10786
10787
|
badlo(user, **{"name": f"Kyle"})
|
|
10787
10788
|
print(user)
|
|
10788
|
-
print(badlo([1, 5, 8], 2, 10, i=1))
|
|
10789
|
+
print(badlo([1, 5, 8], 2, 10, i=1))
|
|
10790
|
+
|
|
10791
|
+
user = obj(name = obj(first=f"Larry",
|
|
10792
|
+
last=f"Tyson"),
|
|
10793
|
+
age = 24,
|
|
10794
|
+
myset = set([3, 2, 1]))
|
|
10795
|
+
user2 = obj(name=obj(first=f"Benny",
|
|
10796
|
+
last=f"Hudson"),
|
|
10797
|
+
age=27)
|
|
10798
|
+
user3 = {
|
|
10799
|
+
"name": {
|
|
10800
|
+
"first": f"Kevin",
|
|
10801
|
+
"last": f"Bayport",
|
|
10802
|
+
},
|
|
10803
|
+
"age": 27,
|
|
10804
|
+
"city": obj({}),
|
|
10805
|
+
"key": f"value",
|
|
10806
|
+
"age": 35,
|
|
10807
|
+
}
|
|
10808
|
+
print(user.name.first == f"Larry")
|
|
10809
|
+
|
|
10810
|
+
amount = 4 + dedh
|
|
10811
|
+
discount = 10 / 100 * amount
|
|
10812
|
+
print(f"{discount = }")
|
|
10813
|
+
|
|
10814
|
+
print(user3)
|
|
10815
|
+
print(f"{kism(koi_na) == KoiNa = }")
|
|
@@ -173,7 +173,7 @@ def translate_for_jupyter(code: str) -> None:
|
|
|
173
173
|
r"(?:kaho|bolo?)": "print",
|
|
174
174
|
# match-case
|
|
175
175
|
r"(?:aga?r|hua)[_ ]*match(?! +(?:he|nahi|chot[aei]|bar[aei]|ba?ra?ba?r)\b(?= *[^\(]))(?= +[^\>\<\=\!\n\t\:]+\:)": "match",
|
|
176
|
-
r"(?<=(?<!\w) {
|
|
176
|
+
r"(?<=(?<!\w) {4})sath(?! +(?:open|khola|(?:[Ss][Qq][Ll]|[Dd][Bb])(?:(?:\.| +k[aeio] +)conn(?:ect)?)?|[A-Za-z_]\w*(?:\.| +k[aeio] +)conn(?:ect)?) *\()": "case",
|
|
177
177
|
# same keyword, different operations
|
|
178
178
|
# keep the sequence untouched
|
|
179
179
|
r"sath(?= +[A-Za-z_])": "with",
|
|
@@ -218,13 +218,13 @@ def translate_for_jupyter(code: str) -> None:
|
|
|
218
218
|
r"(?:hamesha|ja?bta?k)(?= *\:)": "while True",
|
|
219
219
|
r"har(?= *[A-Za-z_]\w*)": "for",
|
|
220
220
|
r"every": "for",
|
|
221
|
-
r"(?<=\S )(?:andar|(?:with)?in|under|da?rmya{0,2}n|b(?:i|ee)ch|hissa)(?=
|
|
221
|
+
r"(?<=\S )(?:andar|(?:with)?in|under|da?rmya{0,2}n|b(?:i|ee)ch|hissa)(?= +\S)": " in ",
|
|
222
222
|
# tests needed, but keep the " in " as-is
|
|
223
223
|
r"until(?= *\()": "in range",
|
|
224
224
|
r"(?:limit|da?rmya{0,2}n|b(?:et)?w(?:een)?)(?= *\()": "range",
|
|
225
225
|
r"next(?= [^ \(])": "yield",
|
|
226
|
-
r"(?<=(?<!\w) {
|
|
227
|
-
r"(?<=(?<!\w) {
|
|
226
|
+
r"(?<=(?<!\w) {4})ruko(?! *[^\n])": "break",
|
|
227
|
+
r"(?<=(?<!\w) {4})(?:ignore(?: +karo)?|agli[_ ]*ba{1,2}ri(?:[_ ]*ka)?[_ ]*int[ai]?za{1,2}r|chor(?:[_ ]*d)?o|chor(?:[_ ]*k[_ ]*)?e +chal(?:te[_ ]*rah)?o)(?! *[^\n])": "continue",
|
|
228
228
|
# ignore only translates to continue as long as it's indented
|
|
229
229
|
# and ISN'T followed by a (
|
|
230
230
|
# no messing around^
|
|
@@ -245,6 +245,7 @@ def translate_for_jupyter(code: str) -> None:
|
|
|
245
245
|
r"func": "Callable",
|
|
246
246
|
r"(?:(?:return|out|lota{1,2}(?:e|ya))[ _]*kare|gives|deta|lotae)(?:[ _]*(?:an?|ek))?(?= +[A-Za-z_])": "->",
|
|
247
247
|
r"Shayad(?= *\[[A-Za-z_])": "Union",
|
|
248
|
+
r"(?:[Cc]horne_layak|optional)": "Optional",
|
|
248
249
|
r"(?:is|he)_?func(?= *\()": "callable",
|
|
249
250
|
r"(?<=\:|(?<=\:|(?<=\:) ) )char|char(?= *[\(])": "Char",
|
|
250
251
|
# * both sides are needed
|
|
@@ -488,6 +489,31 @@ def translate_for_jupyter(code: str) -> None:
|
|
|
488
489
|
processed_templt = replace(processed_templt, r"(?<=\S )\bdiv\b(?= *[^\(\:\s])", "/")
|
|
489
490
|
processed_templt = replace(processed_templt, r"(?<=\S\.)\b_cl(?:as?)?s_?name\b", "__class__.__name__")
|
|
490
491
|
processed_templt = replace(processed_templt, r"(?<=\S\.)\b_cl(?:as?)?s\b", "__class__")
|
|
492
|
+
# DON'T edit
|
|
493
|
+
processed_templt = replace(
|
|
494
|
+
processed_templt,
|
|
495
|
+
r"(?<![\w\?\)\]])\?{1}(?![\w\.\(\[]|\?)",
|
|
496
|
+
"None"
|
|
497
|
+
)
|
|
498
|
+
# ? -> None
|
|
499
|
+
processed_templt = replace(
|
|
500
|
+
processed_templt,
|
|
501
|
+
r"(?:\.{3}|\bwagera\b)\s+(?:\*|\b(?:times|dafa|guna|marta?ba|jes[aei]|wagera)\b)\s+(?=\d)",
|
|
502
|
+
"* [None] * "
|
|
503
|
+
)
|
|
504
|
+
# ... * n -> *[None] * n
|
|
505
|
+
processed_templt = replace(
|
|
506
|
+
processed_templt,
|
|
507
|
+
r"\b(?:none|null|koi_na)\b",
|
|
508
|
+
"None"
|
|
509
|
+
)
|
|
510
|
+
# REMINDER:
|
|
511
|
+
# there's a difference between None, and NoneType
|
|
512
|
+
processed_templt = replace(
|
|
513
|
+
processed_templt,
|
|
514
|
+
r"\b(?:KoiNa)\b",
|
|
515
|
+
"NoneType"
|
|
516
|
+
)
|
|
491
517
|
# readable index access
|
|
492
518
|
# sequence MATTERS
|
|
493
519
|
# sequence is the only thing holding it together
|
|
@@ -497,7 +523,7 @@ def translate_for_jupyter(code: str) -> None:
|
|
|
497
523
|
processed_templt = replace(processed_templt, r"\[\.?b(?:a(?:a?d|ger)|ina)(?: +(?:pehl[ae]|shurwa{1,2}ti))? (?<start>\d+(?:[\+\-\*\/]*\d*)+)(?:st|nd|rd|h?l[ae]|th|th?[ae]|s?r[ae]|w[ae])?(?:,? +(?:\d+ +)?baad +(?<step>\w+(?:[\+\-\*\/]*\d*)+) *[ \/\-] *\w+(?:[\+\-\*\/]*\d*))?\]", "[$start::$step]")
|
|
498
524
|
processed_templt = replace(processed_templt, r"\[\.?(?<n>\d+(?:[\+\-\*\/]*\d*)+)(?:st|nd|rd|h?l[ae]|th|th?[ae]|s?r[ae]|w[ae])(?: se)? +(?:(?:l(?:e(?:ke|n(?:gth)?)|ambai)|size)(?: a{1,2}kh(?:ir|ri)(?: tak)?)?|a{1,2}kh(?:ir|ri)(?: tak)) *(?<stop>\-\d+)? *(?:tak *)?(?:,? +(?:\d+ +)?baad +(?<step>\w+(?:[\+\-\*\/]*\d*)+) *[ \/\-] *\w+(?:[\+\-\*\/]*\d*))?\]", "[$n-1:$stop:$step]")
|
|
499
525
|
processed_templt = replace(processed_templt, r"\[\.?b(?:ager|ina) +(?:last|akhri)(?:,? +(?:\d+ +)?baad +(?<step>\w+(?:[\+\-\*\/]*\d*)+) *[ \/\-] *\w+(?:[\+\-\*\/]*\d*))?\]", "[:-1:$step]")
|
|
500
|
-
processed_templt = replace(processed_templt, r"\[\.?b(?:ager|ina) +(?:last|akhri) (?<stop>\-?\d+(?:[\+\-\*\/]*\d*)+)(?:st|nd|rd|h?l[ae]|th|th?[ae]|s?r[ae]|w[ae])?(?:,? +(?:\d+ +)?baad +(?<step>\w+(?:[\+\-\*\/]*\d*)+) *[ \/\-] *\w+(?:[\+\-\*\/]*\d*))?\]", "[:-abs($stop):$step]")
|
|
526
|
+
processed_templt = replace(processed_templt, r"\[\.?b(?:ager|ina) +(?:last|akhri) +(?<stop>\-?\d+(?:[\+\-\*\/]*\d*)+)(?:st|nd|rd|h?l[ae]|th|th?[ae]|s?r[ae]|w[ae])?(?:,? +(?:\d+ +)?baad +(?<step>\w+(?:[\+\-\*\/]*\d*)+) *[ \/\-] *\w+(?:[\+\-\*\/]*\d*))?\]", "[:-abs($stop):$step]")
|
|
501
527
|
# reversing
|
|
502
528
|
processed_templt = replace(processed_templt, r"\[\.?(?:k[aeio]\:?[_ ])?(?:ula?t[ai]?|rev(?:er(?:se)?)?[dt]?)\]", "[::-1]")
|
|
503
529
|
while SEMICOLON_SUBINDEX_ACCESSOR_RE_COMPILED\
|
|
@@ -514,9 +540,9 @@ def translate_for_jupyter(code: str) -> None:
|
|
|
514
540
|
)
|
|
515
541
|
# number-based mid slicing (rather than index-based)
|
|
516
542
|
# comes before
|
|
517
|
-
processed_templt = replace(processed_templt, r"\[\.?(?:da?rmya{0,2}n|b(?:i|ee)ch)? *\:? *(?<start>\-?\d+)(?:st|nd|rd|h?l[ae]|th|th?[ae]|s?r[ae]|w[ae])(?:[,:~\-]| *(?:se|aur)?) *(?<stop>\-?\d+)(?:st|nd|rd|h?la|th|th?a|s?ra|wa)?(?:[, ]*(?:akhri +)?(?:chor[_ ]*k?e|b(?:ina|a?ge?r))(?: akhri)?)(?:,? +(?:\d+ +)?baad +(?<step>\w+(?:[\+\-\*\/]*\d*)+) *[ \/\-] *\w+(?:[\+\-\*\/]*\d*))?\]", "[$start-1 if $start > 0 else $start:$stop-1 if $stop > 0 else $stop:$step]")
|
|
543
|
+
processed_templt = replace(processed_templt, r"\[\.?(?:da?rmya{0,2}n|b(?:i|ee)ch)? *\:? *(?<start>\-?\d+)(?:st|nd|rd|h?l[ae]|th|th?[ae]|s?r[ae]|w[ae])(?:[,:~\-]| *(?:se|aur)?) *(?<stop>\-?\d+)(?:st|nd|rd|h?la|th|th?a|s?ra|wa)?(?:[, ]*(?:akhri +)?(?:chor[_ ]*k?e|b(?:ina|a?ge?r))(?: +akhri)?)(?:,? +(?:\d+ +)?baad +(?<step>\w+(?:[\+\-\*\/]*\d*)+) *[ \/\-] *\w+(?:[\+\-\*\/]*\d*))?\]", "[$start-1 if $start > 0 else $start:$stop-1 if $stop > 0 else $stop:$step]")
|
|
518
544
|
# comes after {similar, but different:}
|
|
519
|
-
processed_templt = replace(processed_templt, r"\[\.?(?:da?rmya{0,2}n|b(?:i|ee)ch)? *\:? *(?<start>\-?\d+)(?:st|nd|rd|h?l[ae]|th|th?[ae]|s?r[ae]|w[ae])(?:[,:~\-]| *(?:se|aur)?) *(?<stop>\-?\d+)(?:st|nd|rd|h?la|th|th?a|s?ra|wa)?(?:[, ]*(?:akhri +)?(?:rakhe|sha{1,2}mil|shuma{1,2}r|mila{1,2}k?e|(?:ke[_ ]*)?sath)(?: akhri)?)?(?:,? +(?:\d+ +)?baad +(?<step>\w+(?:[\+\-\*\/]*\d*)+) *[ \/\-] *\w+(?:[\+\-\*\/]*\d*))?\]", "[$start-1 if $start > 0 else $start:$stop:$step]")
|
|
545
|
+
processed_templt = replace(processed_templt, r"\[\.?(?:da?rmya{0,2}n|b(?:i|ee)ch)? *\:? *(?<start>\-?\d+)(?:st|nd|rd|h?l[ae]|th|th?[ae]|s?r[ae]|w[ae])(?:[,:~\-]| *(?:se|aur)?) *(?<stop>\-?\d+)(?:st|nd|rd|h?la|th|th?a|s?ra|wa)?(?:[, ]*(?:akhri +)?(?:rakhe|sha{1,2}mil|shuma{1,2}r|mila{1,2}k?e|(?:ke[_ ]*)?sath)(?: +akhri)?)?(?:,? +(?:\d+ +)?baad +(?<step>\w+(?:[\+\-\*\/]*\d*)+) *[ \/\-] *\w+(?:[\+\-\*\/]*\d*))?\]", "[$start-1 if $start > 0 else $start:$stop:$step]")
|
|
520
546
|
processed_templt = replace(processed_templt, r"\[\.?(?:(?:se|f(?:ir)?st|pehl(?:e|a))(?:[_ ]ke)?|shuru?(?:[_ ][smk]e|wa{1,2}ti)) *[\: ] *(?<stop>\d+)(?: tak)?(?:,? +(?:\d+ +)?baad +(?<step>\w+(?:[\+\-\*\/]*\d*)+) *[ \/\-] *\w+(?:[\+\-\*\/]*\d*))?\]", "[:$stop:$step]")
|
|
521
547
|
# ^ e.g. "hello world"[.first4] -> "hell"
|
|
522
548
|
processed_templt = replace(processed_templt, r"\[\.?(?:ba{1,2}d +)?(?:la?st|akhri|akhir)(?:[_ ]*[smk]e)? *[\: ] *(?<right_start>\d+)(?:,? +(?:\d+ +)?baad +(?<step>\w+(?:[\+\-\*\/]*\d*)+) *[ \/\-] *\w+(?:[\+\-\*\/]*\d*))?\]", "[-$right_start::$step]")
|
|
@@ -810,10 +836,10 @@ def translate_for_jupyter(code: str) -> None:
|
|
|
810
836
|
# comes after\/
|
|
811
837
|
processed_templt = replace(processed_templt, r"(?<![\w\"\']|(?<!\.)\.)(?:\.\. *(?<char>[\"\']\w[\"\']))(?:,? *(?:(?:\:\:|\.\.(?=(?:baad|har) ))(?:(?:baad|har) +)?|step|kadam|gap|ba{1,2}d|har(?= *\d+ *ke_ba{1,2}d)) *(?!(?:(?:(?:do[_ ]*no?t|no[nt]?|nahi)[_ ]*)?(?:rever(?:se|t)d?|ul(?:t[aie]|at))|(?:(?:(?:zabardasti|f(?:orce)?)[_ ]*)?(?:sha{1,2}mil|bager|(?:in|ex)cl(?:usive)?)(?:[_ ]*(?:akhri|last|end|stop))?)))(?<step_optional>(?:\d*\.?\w[\+\*\/]*)+)(?: *[\- ]? *\d*\.?\w)?(?: *ke[_ ]ba{1,2}d)?[ _\/\-]?\w*)?(?: ke[_ ]lie)?(?:(?:,|\.\.)? *(?=(?:(?:zabardasti|f(?:orce)?)[_ ]*)?(?:sha{1,2}mil|bager|(?:in|ex)cl(?:usive)?)))?(?<inclusive>(?:(?:zabardasti|f(?:orce)?)[_ ]*)?(?:sha{1,2}mil|bager|(?:in|ex)cl(?:usive)?)(?:[_ ]*(?:akhri|last|end|stop))?)?(?:(?:,|\.\.) *(?<reverse>(?:(?:do[_ ]*no?t|no[nt]?|nahi)[_ ]*)?(?:rever(?:se|t)d?|ul(?:t[aie]|at))))?", "rng($char, step=float('$step_optional' or '1'), inclusive=globals().get('$inclusive'.strip().replace(' ', '_').upper(), True), reverse=globals().get('$reverse'.strip().replace(' ', '_').upper(), False))")
|
|
812
838
|
# ...{dict} -> **{dict}
|
|
813
|
-
processed_templt = replace(processed_templt, r"(?<![\d]|(?<![
|
|
839
|
+
processed_templt = replace(processed_templt, r"(?<![\d]|(?<![,\=\(]) )\.{3,} *(?!\b(?:times|dafa|guna|marta?ba|jes[aei]|wagera)\b)(?<dict>\{|[_A-Za-z]\w*)", "**$dict")
|
|
814
840
|
# ..{list} -> *{list}
|
|
815
841
|
# sequence
|
|
816
|
-
processed_templt = replace(processed_templt, r"(?<![\.\d]|(?<![
|
|
842
|
+
processed_templt = replace(processed_templt, r"(?<![\.\d]|(?<![,\=\(]) )\.{2} *(?<list>[\[\{\(]|[_A-Za-z]\w*)", "*$list")
|
|
817
843
|
# handling mathematical operations
|
|
818
844
|
# SEQUENCE MATTERS
|
|
819
845
|
# power shorthand
|
|
@@ -1591,14 +1617,14 @@ def translate_for_jupyter(code: str) -> None:
|
|
|
1591
1617
|
# better
|
|
1592
1618
|
# handle increment
|
|
1593
1619
|
# comes before
|
|
1594
|
-
code = replace(code, r"(?<!\=|(?<=\=|(?<=\=|(?<=\=|(?<=\=|(?<=\=|(?<=\=)[\s\\])[\s\\])[\s\\])[\s\\])[\s\\])[\s\\])\b(?<varname>[A-Za-
|
|
1620
|
+
code = replace(code, r"(?<!\=|(?<=\=|(?<=\=|(?<=\=|(?<=\=|(?<=\=|(?<=\=)[\s\\])[\s\\])[\s\\])[\s\\])[\s\\])[\s\\])\b(?<varname>[A-Za-z_]\w*) +(?:me +(?<val>[\w\-\.]+(?:\([\w\-\.]*\))?)(?: +k[ao])? +(?:(?:barht?a?|da{1,2}l)(?:o|t?[aei] +(?:rah|ja|chal)[eo])|izafa)(?: +(?:hot[ai]?|karte)(?: +(?:rah|ja|chal)[eo]))?)\b$", "$varname += $val")
|
|
1595
1621
|
# after
|
|
1596
|
-
code = replace(code, r"(?<!\=|(?<=\=|(?<=\=|(?<=\=|(?<=\=|(?<=\=|(?<=\=)[\s\\])[\s\\])[\s\\])[\s\\])[\s\\])[\s\\])\b(?<varname>[A-Za-
|
|
1622
|
+
code = replace(code, r"(?<!\=|(?<=\=|(?<=\=|(?<=\=|(?<=\=|(?<=\=|(?<=\=)[\s\\])[\s\\])[\s\\])[\s\\])[\s\\])[\s\\])\b(?<varname>[A-Za-z_]\w*)(?:\+{2}|(?: +(?:me|k[ao]))? +(?:(?:barht?a?|da{1,2}l)(?:o|t?[aei] +(?:rah|ja|chal)[eo])|izafa)(?: +(?:hot[ai]?|karte)(?: +(?:rah|ja|chal)[eo]))?\b)$", "$varname += 1")
|
|
1597
1623
|
# handle decrement
|
|
1598
1624
|
# comes before
|
|
1599
|
-
code = replace(code, r"(?<!\=|(?<=\=|(?<=\=|(?<=\=|(?<=\=|(?<=\=|(?<=\=)[\s\\])[\s\\])[\s\\])[\s\\])[\s\\])[\s\\])\b(?<varname>[A-Za-
|
|
1625
|
+
code = replace(code, r"(?<!\=|(?<=\=|(?<=\=|(?<=\=|(?<=\=|(?<=\=|(?<=\=)[\s\\])[\s\\])[\s\\])[\s\\])[\s\\])[\s\\])\b(?<varname>[A-Za-z_]\w*) +(?:(?:me(?:[_ ]*se)?|se) +(?<val>[\w\-\.]+(?:\([\w\-\.]*\))?)(?: +k[aoi])? +(?:(?:ghat{1,2}a?|kam +ho|nika{1,2}l)(?:o|t?[aei] +(?:rah|ja|chal)[eo])|ghata|kami?)(?: +(?:hot[ai]?|karte)(?: +(?:rah|ja|chal)[eo]))?)\b$", "$varname -= $val")
|
|
1600
1626
|
# after
|
|
1601
|
-
code = replace(code, r"(?<!\=|(?<=\=|(?<=\=|(?<=\=|(?<=\=|(?<=\=|(?<=\=)[\s\\])[\s\\])[\s\\])[\s\\])[\s\\])[\s\\])\b(?<varname>[A-Za-
|
|
1627
|
+
code = replace(code, r"(?<!\=|(?<=\=|(?<=\=|(?<=\=|(?<=\=|(?<=\=|(?<=\=)[\s\\])[\s\\])[\s\\])[\s\\])[\s\\])[\s\\])\b(?<varname>[A-Za-z_]\w*)(?:\-{2}|(?: +(?:k[aoi]|me(?:[_ ]*se)?))? +(?:(?:ghat{1,2}a?|kam +ho|nika{1,2}l)(?:o|t?[aei] +(?:rah|ja|chal)[eo])|ghata|kami?)(?: +(?:hot[ai]?|karte)(?: +(?:rah|ja|chal)[eo]))?\b)$", "$varname -= 1")
|
|
1602
1628
|
# SEQUENCE MATTERS
|
|
1603
1629
|
# IT DOES!
|
|
1604
1630
|
# section for membership checks
|
|
@@ -1636,10 +1662,10 @@ def translate_for_jupyter(code: str) -> None:
|
|
|
1636
1662
|
# comes after\/
|
|
1637
1663
|
code = replace(code, r"(?<![\w\"\']|(?<!\.)\.)(?:\.\. *(?<char>[\"\']\w[\"\']))(?:,? *(?:(?:\:\:|\.\.(?=(?:baad|har) +))(?:(?:baad|har) +)?|step|kadam|gap|ba{1,2}d|har(?= *\d+ *ke_ba{1,2}d)) *(?!(?:(?:(?:do[_ ]*no?t|no[nt]?|nahi)[_ ]*)?(?:rever(?:se|t)d?|ul(?:t[aie]|at))|(?:(?:(?:zabardasti|f(?:orce)?)[_ ]*)?(?:sha{1,2}mil|bager|(?:in|ex)cl(?:usive)?)(?:[_ ]*(?:akhri|last|end|stop))?)))(?<step_optional>(?:\d*\.?\w[\+\*\/]*)+)(?: *[\- ]? *\d*\.?\w)?(?: *ke[_ ]ba{1,2}d)?[ _\/\-]?\w*)?(?: ke[_ ]lie)?(?:(?:,|\.\.)? *(?=(?:(?:zabardasti|f(?:orce)?)[_ ]*)?(?:sha{1,2}mil|bager|(?:in|ex)cl(?:usive)?)))?(?<inclusive>(?:(?:zabardasti|f(?:orce)?)[_ ]*)?(?:sha{1,2}mil|bager|(?:in|ex)cl(?:usive)?)(?:[_ ]*(?:akhri|last|end|stop))?)?(?:(?:,|\.\.) *(?<reverse>(?:(?:do[_ ]*no?t|no[nt]?|nahi)[_ ]*)?(?:rever(?:se|t)d?|ul(?:t[aie]|at))))?", "rng($char, step=float('$step_optional' or '1'), inclusive=globals().get('$inclusive'.strip().replace(' ', '_').upper(), True), reverse=globals().get('$reverse'.strip().replace(' ', '_').upper(), False))")
|
|
1638
1664
|
# ...{dict} -> **{dict}
|
|
1639
|
-
code = replace(code, r"(?<![\d]|(?<![
|
|
1665
|
+
code = replace(code, r"(?<![\d]|(?<![,\=\(]) )\.{3,} *(?!\b(?:times|dafa|guna|marta?ba|jes[aei]|wagera)\b)(?<dict>\{|[_A-Za-z]\w*)", "**$dict")
|
|
1640
1666
|
# ..{list} -> *{list}
|
|
1641
1667
|
# sequence
|
|
1642
|
-
code = replace(code, r"(?<![\.\d]|(?<![
|
|
1668
|
+
code = replace(code, r"(?<![\.\d]|(?<![,\=\(]) )\.{2} *(?<list>[\[\{\(]|[_A-Za-z]\w*)", "*$list")
|
|
1643
1669
|
# handling mathematical operations
|
|
1644
1670
|
# SEQUENCE MATTERS
|
|
1645
1671
|
code = replace(code, r"(?<!\w)(?<A>\-?\d*\.?(?:\w[\+\-\*\/]*)+) *\^ *(?<B>\-?\d*\.?(?:\w[\+\-\*\/]*)+)", "$A**$B")
|
|
@@ -1760,7 +1786,7 @@ def translate_for_jupyter(code: str) -> None:
|
|
|
1760
1786
|
# fc log: -> fc log():
|
|
1761
1787
|
code = replace(code, r"(?<![\=,\(]|(?<=[\=,\(]|(?<=[\=,\(]|(?<=[\=,\(]) ) ) )(?:\basync?|\${1,2}) *(?:f[cn]|how[_ ]*to|kese|act|def|(?:static|direct) *(?:me?th?o?d))\b(?= +[A-Za-z_])", "async def")
|
|
1762
1788
|
code = replace(code, r"(?<![\=,\(]|(?<=[\=,\(]|(?<=[\=,\(]|(?<=[\=,\(]) ) ) )\b(?:f[cn]|how[_ ]*to|kese|act|def|(?:static|direct) *(?:me?th?o?d)) +(?<funcname_followed_not_by_parens>[A-Za-z_]\w*)(?=(?<could_have_a_return_type>[^\(\)\:]+)?\:\n+(?: {4}|\t{1,}))", "def $funcname_followed_not_by_parens()")
|
|
1763
|
-
code = replace(code, r"(?<![\=,\(]|(?<=[\=,\(]|(?<=[\=,\(]|(?<=[\=,\(]) ) ) )\b(?:f[cn]|how[_ ]*to|kese|act|def|(?:static|direct) *(?:me?th?o?d)) +(?<funcname_regular>[A-Za-z_]\w*)\((?<params
|
|
1789
|
+
code = replace(code, r"(?<![\=,\(]|(?<=[\=,\(]|(?<=[\=,\(]|(?<=[\=,\(]) ) ) )\b(?:f[cn]|how[_ ]*to|kese|act|def|(?:static|direct) *(?:me?th?o?d)) +(?<funcname_regular>[A-Za-z_]\w*)\((?<params>[^\)]+)?\)(?=(?<could_have_a_return_type>[^\(\)\:]+)?\:(?:\n+(?: {4}|\t{1,}))?)", "def $funcname_regular($params)")
|
|
1764
1790
|
code = replace(code, r"\b(lambda) +lambda\b", "$1") # a bug fix
|
|
1765
1791
|
code = replace(code, r"@(redo|[Oo]ver(?:writ{1,2}e|rid{1,2}e)[sn]?|[Ee]xtends?|([Rr]e|[Nn]ot)_?[Ii]mplement(ed)?|dubara|nae_sire) ", "")
|
|
1766
1792
|
# sequence matters
|
|
@@ -2085,22 +2111,46 @@ def translate_for_jupyter(code: str) -> None:
|
|
|
2085
2111
|
code = replace(code, r"\b(?<varname>[_A-Za-z]\w*) +(expects|ume{0,2}d|chah(?:e|ta)|wants|mange|needs) +(?<type>[_A-Za-z\?][\w\[\]\.\|\?]*)", "$varname: $type")
|
|
2086
2112
|
# handling Optionality: default, and null cases
|
|
2087
2113
|
# <type>? means the type is optional
|
|
2088
|
-
code = replace(code, r"(
|
|
2114
|
+
code = replace(code, r"(?<=[^\(\s] )\bkwarg\b(?=[\s\\]*[,\)])", "= None")
|
|
2089
2115
|
# DON'T edit
|
|
2090
2116
|
code = replace(
|
|
2091
2117
|
code,
|
|
2092
|
-
r"(?<![\w
|
|
2118
|
+
r"(?<![\w\?\)\]])\?{1}(?![\w\.\(\[]|\?)",
|
|
2093
2119
|
"None"
|
|
2094
2120
|
)
|
|
2095
2121
|
# ? -> None
|
|
2096
2122
|
code = replace(
|
|
2097
2123
|
code,
|
|
2098
|
-
r"(?:\.{3}|\bwagera\b)
|
|
2124
|
+
r"(?:\.{3}|\bwagera\b)\s+(?:\*|\b(?:times|dafa|guna|marta?ba|jes[aei]|wagera)\b)\s+(?=\d)",
|
|
2099
2125
|
"* [None] * "
|
|
2100
2126
|
)
|
|
2101
2127
|
# ... * n -> *[None] * n
|
|
2102
|
-
code = replace(
|
|
2103
|
-
|
|
2128
|
+
code = replace(
|
|
2129
|
+
code,
|
|
2130
|
+
r"(?<!\w|(?<=\w) )\? *\( *(?<type>[A-Za-z_][\w,\|\?\[\] ]*) *\)",
|
|
2131
|
+
"Union[$type]"
|
|
2132
|
+
)
|
|
2133
|
+
code = replace(
|
|
2134
|
+
code,
|
|
2135
|
+
r"(?<!\w|(?<=\w) )\? *(?=\[ *[A-Za-z_]\w*)",
|
|
2136
|
+
"Iterable"
|
|
2137
|
+
)
|
|
2138
|
+
code = replace(
|
|
2139
|
+
code,
|
|
2140
|
+
r"= *\b[Oo]ptional\b(?=\s*[,\)])",
|
|
2141
|
+
"= None"
|
|
2142
|
+
)
|
|
2143
|
+
code = replace(
|
|
2144
|
+
code,
|
|
2145
|
+
r"(?<arg>[A-Za-z_][\w\[\],\.]*)(?:\?|[\s\\]+\b[Oo]ptional\b)(?=\s*[,\)])",
|
|
2146
|
+
"$arg = None"
|
|
2147
|
+
)
|
|
2148
|
+
code = replace(
|
|
2149
|
+
code,
|
|
2150
|
+
r"(?<type>[A-Za-z_][\w\[\],\.]*)(?:\?|[\s\\]+\b[Oo]ptional\b)(?!\.)",
|
|
2151
|
+
"$type|None"
|
|
2152
|
+
)
|
|
2153
|
+
code = replace(code, r"(?<=(?<!\w) {4})(?:sath|case) +(?:[\.\?]{3}|ba{1,2}ki|anja{1,2}n)(?=(?: +(?:if|agar) +[^\:]+)? *\:)", "case _")
|
|
2104
2154
|
# since the key-value replacement has already occured
|
|
2105
2155
|
# (scroll up a few lines)
|
|
2106
2156
|
# we need to catch bot sath|case
|
|
@@ -2119,7 +2169,7 @@ def translate_for_jupyter(code: str) -> None:
|
|
|
2119
2169
|
code = replace(code, r"\[\.?b(?:a(?:a?d|ger)|ina)(?: +(?:pehl[ae]|shurwa{1,2}ti))? (?<start>\d+(?:[\+\-\*\/]*\d*)+)(?:st|nd|rd|h?l[ae]|th|th?[ae]|s?r[ae]|w[ae])?(?:,? +(?:\d+ +)?baad +(?<step>\w+(?:[\+\-\*\/]*\d*)+) *[ \/\-] *\w+(?:[\+\-\*\/]*\d*))?\]", "[$start::$step]")
|
|
2120
2170
|
code = replace(code, r"\[\.?(?<n>\d+(?:[\+\-\*\/]*\d*)+)(?:st|nd|rd|h?l[ae]|th|th?[ae]|s?r[ae]|w[ae])(?: se)? +(?:(?:l(?:e(?:ke|n(?:gth)?)|ambai)|size)(?: a{1,2}kh(?:ir|ri)(?: tak)?)?|a{1,2}kh(?:ir|ri)(?: tak)) *(?<stop>\-\d+)? *(?:tak *)?(?:,? +(?:\d+ +)?baad +(?<step>\w+(?:[\+\-\*\/]*\d*)+) *[ \/\-] *\w+(?:[\+\-\*\/]*\d*))?\]", "[$n-1:$stop:$step]")
|
|
2121
2171
|
code = replace(code, r"\[\.?b(?:ager|ina) +(?:last|akhri)(?:,? +(?:\d+ +)?baad +(?<step>\w+(?:[\+\-\*\/]*\d*)+) *[ \/\-] *\w+(?:[\+\-\*\/]*\d*))?\]", "[:-1:$step]")
|
|
2122
|
-
code = replace(code, r"\[\.?b(?:ager|ina) +(?:last|akhri) (?<stop>\-?\d+(?:[\+\-\*\/]*\d*)+)(?:st|nd|rd|h?l[ae]|th|th?[ae]|s?r[ae]|w[ae])?(?:,? +(?:\d+ +)?baad +(?<step>\w+(?:[\+\-\*\/]*\d*)+) *[ \/\-] *\w+(?:[\+\-\*\/]*\d*))?\]", "[:-abs($stop):$step]")
|
|
2172
|
+
code = replace(code, r"\[\.?b(?:ager|ina) +(?:last|akhri) +(?<stop>\-?\d+(?:[\+\-\*\/]*\d*)+)(?:st|nd|rd|h?l[ae]|th|th?[ae]|s?r[ae]|w[ae])?(?:,? +(?:\d+ +)?baad +(?<step>\w+(?:[\+\-\*\/]*\d*)+) *[ \/\-] *\w+(?:[\+\-\*\/]*\d*))?\]", "[:-abs($stop):$step]")
|
|
2123
2173
|
# reversing
|
|
2124
2174
|
code = replace(code, r"\[\.?(?:k[aeio]\:?[_ ])?(?:ula?t[ai]?|rev(?:er(?:se)?)?[dt]?)\]", "[::-1]")
|
|
2125
2175
|
# semicolon-driven sub-index access
|
|
@@ -2155,19 +2205,19 @@ def translate_for_jupyter(code: str) -> None:
|
|
|
2155
2205
|
# ^ a fix for an extra space
|
|
2156
2206
|
# custom data types
|
|
2157
2207
|
# much needed
|
|
2158
|
-
code = replace(code, r"(?<varname>[A-Za-
|
|
2208
|
+
code = replace(code, r"(?<varname>[A-Za-z_]\w*) *\: *(?<typenumlist>num_?list) *\= *(?<array>\[(?:\-?\d*\.?\w+(?:, *)?)*\])", "$varname: numlist = numlist($array)")
|
|
2159
2209
|
# ^ specifically for numlists
|
|
2160
2210
|
# arr: numlist = [1, 2, 3]
|
|
2161
2211
|
# becomes ->
|
|
2162
2212
|
# arr: numlist = numlist([1, 2, 3])
|
|
2163
2213
|
code = replace(
|
|
2164
2214
|
code,
|
|
2165
|
-
r"(?<varname>[A-Za-
|
|
2215
|
+
r"(?<varname>[A-Za-z_]\w*) *\: *(?<typeintlist>int_?list) *\= *(?<array>\[(?:\-?\d*\.?\w+(?:, *)?)*\])",
|
|
2166
2216
|
"$varname: intlist = intlist($array)"
|
|
2167
2217
|
)
|
|
2168
2218
|
code = replace(
|
|
2169
2219
|
code,
|
|
2170
|
-
r"(?<varname>[A-Za-
|
|
2220
|
+
r"(?<varname>[A-Za-z_]\w*) *\: *(?<typefltlist>(fl(?:oa)?t|d(?:ou)?ble?)_?list) *\= *(?<array>\[(?:\-?\d*\.?\w+(?:, *)?)*\])",
|
|
2171
2221
|
"$varname: fltlist = fltlist($array)"
|
|
2172
2222
|
)
|
|
2173
2223
|
# \|/ SEQUENCE:
|
|
@@ -2210,25 +2260,25 @@ def translate_for_jupyter(code: str) -> None:
|
|
|
2210
2260
|
)
|
|
2211
2261
|
code = replace(
|
|
2212
2262
|
code,
|
|
2213
|
-
r"(?<varname>[A-Za-
|
|
2263
|
+
r"(?<varname>[A-Za-z_]\w*) *\: *(?<chartype>[Cc]har) *\= *(?![\"\(\{\[\)\}\]]\S*[ \n\t]\S*[\"\(\{\[\)\}\]])(?!\"{3})(?<data>[^, \n\t\(\)\{\}\[\]]+(?:\([^\)]*\))?)",
|
|
2214
2264
|
"$varname: Char = Char($data)"
|
|
2215
2265
|
)
|
|
2216
2266
|
# much needed
|
|
2217
2267
|
code = replace(
|
|
2218
2268
|
code,
|
|
2219
|
-
r"(?<varname>[A-Za-
|
|
2269
|
+
r"(?<varname>[A-Za-z_]\w*) *\: *(?<strtype>str|lafz|jumla) *\= *(?![\"\(\{\[\)\}\]]\S*[ \n\t]\S*[\"\(\{\[\)\}\]])(?!\"{3})(?<data>[^, \n\t\(\)\{\}\[\]]+(?:\([^\)]*\))?)",
|
|
2220
2270
|
"$varname: str = Str($data)"
|
|
2221
2271
|
)
|
|
2222
2272
|
# much needed
|
|
2223
2273
|
code = replace(
|
|
2224
2274
|
code,
|
|
2225
|
-
r"(?<varname>[A-Za-
|
|
2275
|
+
r"(?<varname>[A-Za-z_]\w*) *\: *(?<inttype>int) *\= *(?![\"\(\{\[\)\}\]]\S*[ \n\t]\S*[\"\(\{\[\)\}\]])(?!\"{3})(?<data>[^, \n\t\(\)\{\}\[\]]+(?:\([^\)]*\))?)",
|
|
2226
2276
|
"$varname: int = Int($data)"
|
|
2227
2277
|
)
|
|
2228
2278
|
# much needed
|
|
2229
2279
|
code = replace(
|
|
2230
2280
|
code,
|
|
2231
|
-
r"(?<varname>[A-Za-
|
|
2281
|
+
r"(?<varname>[A-Za-z_]\w*) *\: *(?<floattype>float|flt|double|dbl) *\= *(?![\"\(\{\[\)\}\]]\S*[ \n\t]\S*[\"\(\{\[\)\}\]])(?!\"{3})(?<data>[^, \n\t\(\)\{\}\[\]]+(?:\([^\)]*\))?)",
|
|
2232
2282
|
"$varname: float = Flt($data)"
|
|
2233
2283
|
)
|
|
2234
2284
|
# @JUPYTER SPECIFIC
|
|
@@ -2267,6 +2317,11 @@ def translate_for_jupyter(code: str) -> None:
|
|
|
2267
2317
|
r"\bk(?=\')",
|
|
2268
2318
|
"f"
|
|
2269
2319
|
)
|
|
2320
|
+
code = replace(
|
|
2321
|
+
code,
|
|
2322
|
+
r"\: +\b[Oo]ptional\b(?=\:)",
|
|
2323
|
+
""
|
|
2324
|
+
)
|
|
2270
2325
|
# bug fix
|
|
2271
2326
|
code = replace(
|
|
2272
2327
|
code,
|
|
@@ -4335,6 +4390,36 @@ howto _sum(x, y):
|
|
|
4335
4390
|
return x+y
|
|
4336
4391
|
|
|
4337
4392
|
bolo add(3, 2)
|
|
4393
|
+
|
|
4394
|
+
x = [1, 2, ... wagera 3]
|
|
4395
|
+
y = [... guna 20]
|
|
4396
|
+
|
|
4397
|
+
len1, len2 lie x ki lambai, y ki lambai
|
|
4398
|
+
age li 32 saal
|
|
4399
|
+
|
|
4400
|
+
test = han
|
|
4401
|
+
test2 = nahi
|
|
4402
|
+
|
|
4403
|
+
sath ???:
|
|
4404
|
+
|
|
4405
|
+
|
|
4406
|
+
kese add(
|
|
4407
|
+
x,
|
|
4408
|
+
y optional,
|
|
4409
|
+
z kism: chorne_layak[int] = ?
|
|
4410
|
+
) -> ?[str, int, float]:
|
|
4411
|
+
return [x, y, z]
|
|
4412
|
+
|
|
4413
|
+
kese total(.. args)\\
|
|
4414
|
+
lotae nr:
|
|
4415
|
+
_sum kism: nr = 0f
|
|
4416
|
+
har n, i darmyan sath_index(args) ke_lie:
|
|
4417
|
+
_sum me Flt(n) dalo
|
|
4418
|
+
agar _sum.is_integer():
|
|
4419
|
+
lotao int(_sum)
|
|
4420
|
+
lotao _sum
|
|
4421
|
+
|
|
4422
|
+
age sath 15
|
|
4338
4423
|
"""
|
|
4339
4424
|
)
|
|
4340
4425
|
)
|
|
@@ -4345,4 +4430,4 @@ bolo add(3, 2)
|
|
|
4345
4430
|
)
|
|
4346
4431
|
x = run("kism(koi_na)")
|
|
4347
4432
|
print(x)
|
|
4348
|
-
|
|
4433
|
+
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|