-
Notifications
You must be signed in to change notification settings - Fork 14
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
[Unitary hack] Improve docstrings in "Task/braket.py" #975
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #975 +/- ##
=======================================
Coverage 89.90% 89.90%
=======================================
Files 110 110
Lines 8131 8131
=======================================
Hits 7310 7310
Misses 821 821 ☔ View full report in Codecov by Sentry. |
ValueError: If the task is already submitted and force is False. | ||
|
||
Example: | ||
>>> backend = BraketBackend(...) # Create a backend instance |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This won't be rendered correctly by mkdocs markdown. You need to wrap them with markdown code blocks.
|
||
Example: | ||
>>> backend = BraketBackend(...) # Create a backend instance | ||
>>> task_ir = QuEraTaskSpecification(...) # Create a task specification |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
like my comment from the other PR, this is too vague on how you construct a specification, the task will be constructed from a submission, so you should first create a submission (a batch object) then return the task from the batch.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ref: https://github.com/QuEraComputing/bloqade-python/blob/main/src/bloqade/task/batch.py
and you can also check the corresponding tests to understand how this works
I think quite a few PRs are written in a similar fashion like this one, I'm a bit worried if you actually run any of the code to write the docstring. I'll wait til you finish one of them after actually play with the test to proceed. |
Fixes #957
Improve docstring, remove markdown errors