-
Notifications
You must be signed in to change notification settings - Fork 1
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
Documentation for how to use the extension is unclear #6
Comments
Hi - this extension should be active immediately. Here are some troubleshooting steps you can try:
Example docstringsdef from_line(cls: Type[_EntityT], line: str, **kwargs: Any) -> _EntityT:
"""Create a new instance from the given line.
Lines passed into this element must start with the appropriate
card identifier; trailing whitespace is allowed.
If any bad data is encountered, a
:class:`~py2dm.errors.FormatError` should be raised by the
implementation.
:param line: The line to parse.
:type line: :class:`str`
:return: An instance as described by the provided `line`.
:rtype: :class:`Entity`
"""
def __init__(self, id_: int, x: float, y: float, z: float) -> None:
r"""Create a new node.
.. seealso::
You can also create new nodes directly through the
:meth:`py2dm.Writer.node` method.
:param id\_: The unique D of the node.
:type id\_: :class:`int`
:param x: X position of the node.
:type x: :class:`float`
:param y: Y position of the node.
:type y: :class:`float`
:param z: Z position of the node.
:type z: :class:`float`
"""
if x == float('nan') or y == float('nan') or z == float('nan'):
raise ValueError(f'Invalid node position: ({x}, {y}, {z})')
self.id: int = id_
"""Unique identifier of the node.
:type: :class:`int`
""" |
Thank you for the tip to disable extensions. I figured out the culprit: https://marketplace.visualstudio.com/items?itemName=tht13.python Not sure why I had this extension in the first place -- it is very old and not used by anyone anymore. I've disabled and removed it. Must have been an artifact of installing the wrong python extension a long time ago. Sphinx highlighting looks great now!! |
Hi I just installed this extension, but I don't know how to enable Sphinx Highlight. I am using the Pylance language Server.
The text was updated successfully, but these errors were encountered: