Skip to content

Add a execution_status method for the SyclEventRaw class - #522

Merged
oleksandr-pavlyk merged 1 commit into
IntelPython:refactor/SyclEventfrom
vlad-perevezentsev:cython_getstatus
Aug 13, 2021
Merged

oleksandr-pavlyk merged 1 commit into
IntelPython:refactor/SyclEventfrom
vlad-perevezentsev:cython_getstatus

Conversation

@vlad-perevezentsev

Copy link
Copy Markdown
Collaborator

This PR adds the execution_status method which returns the value of the 'event_status_type' enumeration.

Comment thread dpctl/_sycl_event.pyx
&_event_capsule_deleter
)

def execution_status(self):

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Perhaps this should be a read-only property.

In [2]: dpctl.SyclEventRaw().execution_status
Out[2]: <function SyclEventRaw.execution_status>

In [3]: dpctl.SyclEventRaw().execution_status()
Out[3]: <event_status_type.complete: 4>

So one would use In[2] rather than In[3].

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Suggested change
def execution_status(self):
@property
def execution_status(self):

@oleksandr-pavlyk
oleksandr-pavlyk merged commit 9343ca3 into IntelPython:refactor/SyclEvent Aug 13, 2021
vlad-perevezentsev added a commit to vlad-perevezentsev/dpctl that referenced this pull request Aug 23, 2021
@vlad-perevezentsev
vlad-perevezentsev deleted the cython_getstatus branch June 20, 2023 10:54
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