Skip to content

Outroduction of rdflib-jsonld #1405

@ajnelson-nist

Description

@ajnelson-nist

Some time recently, code bases that import the rdflib-jsonld package started to break, due to a feature related to 2to3. Unfortunately, this has had a negative effect on Continuous Integration workflows for packages that (still) include rdflib-jsonld as a dependency. One issue was filed with good background on the matter, here (h/t to @Panaetius).

It was not clear that the rdflib-jsonld package had entered an archive state to those who were not interacting with the Github repository. There was no deprecation notice. Unfortunately, we now have a situation where all CI involving rdflib-jsonld in a package or the package's dependencies fails.

I would like to request the rdflib-jsonld package get one more release posted to PyPI, reducing the package to having two effects:
(1) Having a dependency on rdflib>=6.0.0, so any user of JSON-LD features will still have access to JSON-LD features.
(2) Causing a DeprecationWarning to be raised on import---or better yet, on pip installing. I don't know how to do the latter, but I know the former can be done with the warnings module. E.g., the __init__.py file currently contains:

"""
"""
__version__ = "0.6.0-dev"

It could instead contain:

"""
"""
__version__ = "0.6.0"
import warnings
warning.warn("The rdflib-jsonld package has been integrated into rdflib as of rdflib 6.0.0.  Please remove rdflib-jsonld from your project's dependencies.", DeprecationWarning)

or other appropriate text.

This would allow for a more graceful transition for the package maintainers and their downstream consumers that just needed to support JSON-LD reading.

I could see some discussion around whether it would also be appropriate to delete all other functionality from the rdflib-jsonld package. I'd argue, yes it would be appropriate, because anyone using deeper module features should be importing those features from where they're being maintained. For better or worse, those deeper module features are unavailable now because of the use_2to3 issue. Last, the use_2to3 issue is accidentally a good argument for reducing this package to a stub: risk of future deprecated features would be removed by removing other functionality and reducing setup.py.

To recap, I request rdflib-jsonld be unarchived just long enough for one further release on PyPI. That release should include a dependency on rdflib>=6.0.0. Its main __init__.py should raise a DeprecationWarning on import. If possible, a DeprecationWarning should be raised during pip install. All other functionality (other .py files, and complexity in setup.py) should be removed.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions