Skip to content

Conversation

@NicolasWent
Copy link
Collaborator

This pull request aim is to remove blocks that can't be used:

A block "that can't be used", is a block that the sensor for it has been deleted. For example if you remove all the leds, then all the blocks that use led are deleted (in blockly and python).

We also needed to handle the case when the block is already in use in user's code. In that case:

In python

In python it was already handled: it says an error during execution saying that the function does not exists.

In blockly

In blockly, there is a message saying that the highlighted block is not allowed at the start of the execution.

This pull request also modify the message during the deletion of a sensor to say to the user that he has to remove all functions that use this sensor in his code.

mobydimk and others added 30 commits September 29, 2020 02:20
[QuickPi][Fr] Changed french block of fill
Copy link
Contributor

@mblockelet mblockelet left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Generally good changes, I just made a few comments which are mostly about making the code more generic (some parts are too specific to quick-pi) and also slightly simpler.

// Some data can be made accessible by the library through the context object
context.quickpi = {};

// we put that outside of the function #context.getConceptList because that is our only way to know the which sensor
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't understand why you took the list out ; you could just call context.getConceptList();.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I done this to prevent calls to getConceptList because I just need the fields that I have put outside.

Copy link
Contributor

@mblockelet mblockelet left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

@smadbe smadbe removed their request for review September 7, 2023 08:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

9 participants