Skip to content

Conversation

@lizlooney
Copy link
Collaborator

Also, a lot of clean up. I'm sorry this PR is so big.

In common_storage, added Event type.

In editor, added getEventsFromWorkspace function.

In mrc_call_python_funcction:
Added addFireEventBlocks and createFireEventBlock functions. Replace classMethodDefBlockId and componentBlockId with otherBlockId. Replace mrcClassMethodDefBlockId and componentBlockId with otherBlockId. Make renameMethodCallers and mutateMethodCallers work for fire event blocks. Added function getComponentsFromRobot. Removed mrcComponents. Make fire event block use a field called 'EVENT' instead of 'FUNC'.

In mrc_component, added getComponent function.

In mrc_class_method_def:
Remove mrcMethod. Added function getMethod.
Added mrcFuncName which is set during python code generation. Pass commonStorage.Method (instead of ClassMethodDefExtraState) to mutateMethodCallers.

In mrc_event:
Added mrcNameFieldValidator and getEvent functions. Call mutateMethodCallers and renameMethodCallers user changes parameters or name.

In mrc_mechanism_component_holder, added getEvents function.

In event_category, call editor.getEventsFromWorkspace and addFireEventBlocks instead of using the mrc_event and mrc_call_python_function implementation details here.

In editor, added getEventsFromWorkspace function.

In mrc_call_python_funcction:
Added addFireEventBlocks and createFireEventBlock functions.
Replace classMethodDefBlockId and componentBlockId with otherBlockId.
Replace mrcClassMethodDefBlockId and componentBlockId with otherBlockId.
Make renameMethodCallers and mutateMethodCallers work for fire event blocks.
Added function getComponentsFromRobot. Removed mrcComponents.
Make fire event block use a field called 'EVENT' instead of 'FUNC'.

In mrc_component, added getComponent function.

In mrc_class_method_def:
Remove mrcMethod. Added function getMethod.
Added mrcFuncName which is set during python code generation.
Pass commonStorage.Method (instead of ClassMethodDefExtraState) to mutateMethodCallers.

In mrc_event:
Added mrcNameFieldValidator and getEvent functions.
Call mutateMethodCallers and renameMethodCallers user changes parameters or name.

In mrc_mechanism_component_holder, added getEvents function.

In event_category, call editor.getEventsFromWorkspace and addFireEventBlocks instead of using the mrc_event and mrc_call_python_function implementation details here.
@lizlooney lizlooney requested a review from alan412 July 17, 2025 07:40
Copy link
Collaborator

@alan412 alan412 left a comment

Choose a reason for hiding this comment

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

I need some github training on how to add a commit to your PR. This has some typescript errors. Here is a commit that fixes them: 2b5d717

@lizlooney lizlooney requested a review from alan412 July 18, 2025 01:06
Copy link
Collaborator

@alan412 alan412 left a comment

Choose a reason for hiding this comment

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

LGTM

@alan412 alan412 merged commit 7df5010 into wpilibsuite:main Jul 18, 2025
1 check passed
@lizlooney lizlooney deleted the pr_more_cleanup branch July 18, 2025 01:10
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.

2 participants