Skip to content
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

LIU 189 Expose PyFuncApp #86

Merged
merged 6 commits into from
Dec 9, 2021
Merged

LIU 189 Expose PyFuncApp #86

merged 6 commits into from
Dec 9, 2021

Conversation

calgray
Copy link
Collaborator

@calgray calgray commented Dec 6, 2021

Here I've exposed PyFuncApp, SCPApp, CRCStreamApp, SocketListenerApp daliuge apps such that they will be generated into the default daliuge apps palette (LIU-189, LIU-190, LIU-191, LIU-192 respectively)

Some components I had to modify to get a basic demo graph running for each:
PyFuncApp: Converted app to new component style and added a flag to replace pickling with ast/repr python literals. function_defaults parameter doesn't quite make sense in the component as it only works for kwargs determined at runtime but I've left it be to avoid rewriting unit tests. The fuction argument mapping I'd expected to map port name to function keyword but since in the example the ports and keywords have an order the dict values don't seem to matter. Example of a runnable graph below.

image


def initialize(self, **kwargs):
object_id = self.uid
if len(self.uid) != 20:
object_id = np.random.bytes(20)
if self.object_id is None:
if not self.object_id:
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 noticed an issue with plasma where an empty string id didn't trigger using the object id. Truthy logic will treat empty string and None as False.

@coveralls
Copy link

coveralls commented Dec 6, 2021

Coverage Status

Coverage decreased (-0.02%) to 78.314% when pulling 9cf8add on liu-189 into baea9b8 on master.

Copy link
Contributor

@awicenec awicenec left a comment

Choose a reason for hiding this comment

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

Very nice, indeed. Thanks Callan.

@awicenec awicenec merged commit 7fa67ff into master Dec 9, 2021
@awicenec awicenec deleted the liu-189 branch December 9, 2021 02:14
awicenec added a commit that referenced this pull request May 19, 2022
LIU 189 Expose PyFuncApp
pritchardn pushed a commit that referenced this pull request May 20, 2022
LIU 189 Expose PyFuncApp
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.

None yet

3 participants