You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
Although I managed to understand and solve the intersphinx problems with the indentation of the docstrings (see #1743 ). I still can't get the reason why we get linking warnings for the following 3 docstrings if we import the library:
docstring of import_export.resources.Resource.get_instance:1: WARNING: unknown document: 'api_instance_loaders' docstring of import_export.resources.Resource.import_data:1: WARNING: unknown document: 'import_workflow' docstring of import_export.resources.Resource.import_row:1: WARNING: unknown document: 'import_workflow'
I have not found a solution at the moment, so I am opening an issue for it. Perhaps someone else is more familiar with the correct Intersphinx syntax for this. In the additional context, I have also described a workaround for overwriting the affected functions so that the warning no longer occurs.
To Reproduce
Steps to reproduce the behavior:
Set up another Python project
Import a django-import-export to one of your files
Set up your documentation with Intersphinx to extend your documentation with additional information from other Sphinx documentation
The warnings described above appear
Versions
Django Import Export: [3.3.6]
Python [3.11]
Django [3.4]
Expected behavior
Sphinx should be able to read the docstrings from the documentation
Additional context
As a workaround to avoid these warnings, the affected functions and modules can be overwritten locally and the docstrings adapted accordingly. Sphinx then uses the local docstrings and does not retrieve any further information via Intersphinx. Example:
def get_instance(self, instance_loader, row):
"""
If all 'import_id_fields' are present in the dataset, calls
the InstanceLoader. Otherwise, returns `None`.
"""
return super().get_instance(instance_loader, row)
However, this feels like a very dirty workaround and I hope we can solve this upstream.
The text was updated successfully, but these errors were encountered:
Describe the bug
Although I managed to understand and solve the intersphinx problems with the indentation of the docstrings (see #1743 ). I still can't get the reason why we get linking warnings for the following 3 docstrings if we import the library:
docstring of import_export.resources.Resource.get_instance:1: WARNING: unknown document: 'api_instance_loaders'
docstring of import_export.resources.Resource.import_data:1: WARNING: unknown document: 'import_workflow'
docstring of import_export.resources.Resource.import_row:1: WARNING: unknown document: 'import_workflow'
I have not found a solution at the moment, so I am opening an issue for it. Perhaps someone else is more familiar with the correct Intersphinx syntax for this. In the additional context, I have also described a workaround for overwriting the affected functions so that the warning no longer occurs.
To Reproduce
Steps to reproduce the behavior:
Versions
Expected behavior
Sphinx should be able to read the docstrings from the documentation
Additional context
As a workaround to avoid these warnings, the affected functions and modules can be overwritten locally and the docstrings adapted accordingly. Sphinx then uses the local docstrings and does not retrieve any further information via Intersphinx. Example:
However, this feels like a very dirty workaround and I hope we can solve this upstream.
The text was updated successfully, but these errors were encountered: