-
Notifications
You must be signed in to change notification settings - Fork 33
Support for classes, class instances and methods #61
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
blauwefant
wants to merge
47
commits into
blockpy-edu:master
Choose a base branch
from
blauwefant:master
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…ration format to define them. Each library in the configuration can be displayed in the toolbox. Imports and variables (names and types) are now tracked to support showing more information in the blocks Added display of default parameters in call blocks as shadowed blocks. Introduced preferFullAttributeBlocks configuration setting. Switched from python.pythonGenerator.ORDER_* to using the newer python.Order.* Improved usage of parentheses by dynamically setting precedence order for attributes and calls.
Minor fix for newlines after imports
…ase scrubbing provides additional functionality
Separated out some library documentation into its own readme file. Upgraded Blockly to 12.2.0
…stom JavaScript function)
Improvement of import handling Various smaller bug fixes and cleanups
Improvement of import handling Various smaller bug fixes and cleanups
Implement argument shadowing of tuples
Contributor
Author
|
I am doing a lot of testing and refining, as more complexities pop up when testing with more extensive Python libraries. So more fixes and improvements are likely to come in. |
Added support for a custom field per type alias. Avoid some unwanted layout changes.
Made library metadata model available from blocks. Added support for Literal[...] type hints.
Fixed issue with parameter name aliases not updating correctly. Allow setting a colour as the module level.
Added proper parentheses for attributes. Upgraded Blockly to 12.3.1.
(Incorrectly ordered top level Names).
Make showing default function arguments as shadowed blocks configurable (showDefaultArguments) and set it to false by default (to revert to the previous behavior). Make scroll behavior configurable. Initial translation support (only for libraries for now). Add more variable type registrations. Various cleanups and fixes.
Add zoom option to configuration. Clean up resolving a type hint into a single class.
Fixed incorrect augmented assignment in non-simple cases.
…ing a function. Better support for full rgb colours. Fix variable creation to use custom blocks. Added some more library functions. Some bigger cleanups.
Synchronized attribute and call implementations.
More translation hook implementation.
Various library definition improvements.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Verified by manual testing and the already present (semi)automated tests.
I did remove the existing mechanisms to register modules and functions, as they overlapped with the new mechanism, which should also do everything the old one did.
There are some TODOs still in the code, as some more advanced features are not yet implemented fully, such as (block) support for *args and **kwargs. There should already be feature parity with the previous behavior though.
I hope the library configurations are clear and these changes fit with the direction of this project.
Best regards!