-
Notifications
You must be signed in to change notification settings - Fork 559
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
Outroduction of rdflib-jsonld #1405
Comments
Tagging @nicholascar , as the one who posted the archiving notice. Would this be feasible? |
Thank you for opening this issue 🙏
I think most code currently using rdflib_jsonld looks something like
i.e. registering the Parser and/or Serializer from rdflib_jsonld. To make a transition package such as you proposed functional, I think it'd at least need to import/expose Another thing to consider is that setuptools supports all versions of python3 and RDFLib now is python >= 3.7. So for anyone using Python 3.6 (which I think is still ~30-40% last I checked) or lower, this solution wouldn't work. They might be able to pin setuptools and keep working with the old version, though that's not always the case, as setuptools often is an external dependency or in cases as outlined below. For our project it wouldn't matter, I just wonder if there could be a solution that keeps old code with properly pinned dependencies for As a bit of an aside on how we're currently affected, in our case it's a bit more tragic than CI failing. We provide interactive environments to users to do analysis in, and as part of that we have Docker images with our application installed using |
Un-archiving is easy - I can just click the button for that one, so I'll do that now.
I think we can manage that in the next few days.
Do you perhaps mean "a dependency on rdflib<=6.0.0", i.e. versions of rdflib less than 6.0.0?
Yes I can do this. |
Re: @Panaetius On Python 3.6 - I personally think it is fine to encourage people to transition away from 3.6, as 3.6 is reaching end of life in around 3.5 months. I haven't heard of Re: @nicholascar |
Well I don't know how others use it, I just know that's how we used it in the past and also what I found in OWL-RL https://github.com/RDFLib/OWL-RL/blob/master/owlrl/__init__.py#L197-L205 so I assumed that's how everyone uses it.
I completely agree, we discontinued support for 3.6 in our project last week for the same reason. When we did that I did some analysis against pypi to check which versions of python were used to download some popular datascience packages in the last month and it was 10-38% of people still using 3.6, depending on the package. So still a sizable portion of users. So I just wanted to mention it so there is a discussion on that 😄
We try to support reproducibility in science, so it's important to us that old stuff works indefinitely. But it's really hard to actually offer that and this (pipx) was a new, interesting way that broke things that we hadn't encountered before. We're working on a solution in our stack, just wanted to say there might be cases where pinning setuptools isn't possible. Mostly I'm trying to think of a solution that could keep old user projects on our platform working, but I think it's a bit beside the discussion here, sorry. |
Many projects cannot easily migrate to the next Python version. It might sometimes take years. Here are some statistics about use of various Python versions: Python version share over time |
OK, so I think it's sensible to keep this package working so people who can't upgrade can pin to rdflib 5.0.0 + rdflib-jsonld, just as some can pin to rdflib 5.0.0 for Python 2.7! It's correct that you don't need to also manually register JSON-LD parsers/serializers if installing rdflib-jsonld but there are a couple of tricks there and I cen't remember them all (of course I'm trying to forget them after merging in rdflib-jsonld into rdflib 6.0.0!). Perhaps a tombstoning pypi for rdflib-jsonld really is sensible. As promised before, I'll try and look into this. Any help appreciated! OWL-RL needs care too. I have planned for a couple of years now, to try and update it but haven't found a specific motivator. I'd like to see it:
I also want to check RL status: there appear to be rules commented out. Is it actually doing completely what RL profile says it should? |
The OWL-RL matters could probably use separate tickets for discussion on its repository. It at least looks like your first point on it using the latest rdflib is already raised here. For I think it would be reasonable to include the deprecation warning on importing the top module. That would notify users that features have migrated, and so should their code. It might be a bit more discussion to do the other things I'd suggested, as I hadn't appreciated the preservation angles of Python 3.6 as fully. So, there might be two "Tombstone" releases. I'll file the PRs to start the first. |
The resolution of setuptools 2769 made any package using `use_2to3` to fail its build. This patch removes the flag, in support of outroducing rdflib-jsonld. References: * pypa/setuptools#2769 * RDFLib/rdflib#1405 Reported-by: Ralf Grubenmann <ralf.grubenmann@sdsc.ethz.ch> Signed-off-by: Alex Nelson <alexander.nelson@nist.gov>
The resolution of setuptools 2769 made any package using `use_2to3` to fail its build. This patch removes the flag, in support of outroducing rdflib-jsonld. The test suite is showing other follow-on patches will be necessary to fix matters 2to3 had been quietly fixing along the way. References: * pypa/setuptools#2769 * RDFLib/rdflib#1405 Reported-by: Ralf Grubenmann <ralf.grubenmann@sdsc.ethz.ch>
The resolution of setuptools 2769 made any package using `use_2to3` to fail its build. This patch removes the flag, in support of outroducing rdflib-jsonld. The test suite is showing other follow-on patches will be necessary to fix matters 2to3 had been quietly fixing along the way. However, this first patch does restore a working call to `pip install .` with up-to-date setuptools. References: * pypa/setuptools#2769 * RDFLib/rdflib#1405 Reported-by: Ralf Grubenmann <ralf.grubenmann@sdsc.ethz.ch>
This patch establishes the baseline state of unit tests passing. Unit test results: 5 tests report a FAIL status, all related to JSON-LD compaction. I suggest that these tests are out of scope of the mission of restoring builds functioning, related to removing the use_2to3 flag. References: * RDFLib/rdflib#1405 Signed-off-by: Alex Nelson <alexander.nelson@nist.gov>
The resolution of setuptools 2769 made any package using `use_2to3` to fail its build. This patch removes the flag, in support of outroducing rdflib-jsonld. The test suite is showing other follow-on patches will be necessary to fix matters 2to3 had been quietly fixing along the way. However, this first patch does restore a working call to `pip install .` with up-to-date setuptools. Unit test results: This causes only the same five tests as were previously failing to fail. setuptools versions tested: * 41.2.0 * 58.0.4 References: * pypa/setuptools#2769 * RDFLib/rdflib#1405 Reported-by: Ralf Grubenmann <ralf.grubenmann@sdsc.ethz.ch> Signed-off-by: Alex Nelson <alexander.nelson@nist.gov>
The message provided in this patch is a first draft and invited for revision by a project maintainer. The context manager is to contain the effect of `warnings.simplefilter()`, prevent an import of `rdflib-jsonld` from introducing unexpected behaviors from other applications using the `warnings` module. References: * RDFLib/rdflib#1405 * https://docs.python.org/3/library/warnings.html#temporarily-suppressing-warnings Signed-off-by: Alex Nelson <alexander.nelson@nist.gov>
@nicholascar , PR 105 and PR 106 are ready for your review. Together, they meet the goals of restoring CI, preserving Feedback or patches re welcome on how to raise a |
@ajnelson-nist I've merged those PRs but, I remember now, I don't actually have management permissions for rdflib-jsonld on PyPI so I will ask @niklasl who does to either make a release, 0.6.0, or to give me permissions to do so. |
Actually I do have permissions, a 0.6.0 release is there now: https://pypi.org/project/rdflib-jsonld/ Please let me know if there are any more issues and we can always make a 0.6.1... |
@nicholascar , thank you for posting the release. CI works again in my community. I realized I may have accidentally expanded the dependency scope in PR 105. I removed the pin this package had on I think my other suggestions - ultimately pinning to |
PR 107 filed. @nicholascar , it is fine with me if you would like to close this Issue. |
Sure, I think this would be fine. Perhaps give it a couple of months? Or would you prefer me to make this next release straight away? I've already merged in your PR and pushed a new release to PyPI to include it: https://pypi.org/project/rdflib-jsonld/0.6.1/ |
To be clear here, starting with current (pre-release) versions of rdflib>=6.0.0, json-ld will be handled with RDFlib alone? |
I don't have an authoritative reply for Jamie, but my understanding is yes, that has been so since July. Re: @nicholascar (*): Apparently, one piece of functionality was lost for at least one user, which has been restored since rdflib 6.0.0 but has not been released. So, maybe the pin should be |
OK, I have expected to have to make an rdflib 6.0.1 release to fix a bunch of things that were broken in the major 6.0.0 release and we have a bunch of updates ready to go, so I'll make that release next (day or two) and then we can pin |
OK, rdflib 6.0.1 is out as of last night. Trying to wrap up rdflib-jsonld now. |
rdflib-jsonld 0.6.2 with all functionality removed is now released: https://pypi.org/project/rdflib-jsonld/0.6.2/ Please let me know if there are further problems by opening a new issue. |
The resolution of setuptools 2769 made any package using `use_2to3` to fail its build. This patch removes the flag, in support of outroducing rdflib-jsonld. The test suite is showing other follow-on patches will be necessary to fix matters 2to3 had been quietly fixing along the way. However, this first patch does restore a working call to `pip install .` with up-to-date setuptools. Unit test results: This causes only the same five tests as were previously failing to fail. setuptools versions tested: * 41.2.0 * 58.0.4 References: * pypa/setuptools#2769 * RDFLib/rdflib#1405 Reported-by: Ralf Grubenmann <ralf.grubenmann@sdsc.ethz.ch> Signed-off-by: Alex Nelson <alexander.nelson@nist.gov>
Some time recently, code bases that import the
rdflib-jsonld
package started to break, due to a feature related to2to3
. Unfortunately, this has had a negative effect on Continuous Integration workflows for packages that (still) includerdflib-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 involvingrdflib-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 onimport
---or better yet, onpip install
ing. I don't know how to do the latter, but I know the former can be done with thewarnings
module. E.g., the__init__.py
file currently contains:It could instead contain:
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 theuse_2to3
issue. Last, theuse_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 reducingsetup.py
.To recap, I request
rdflib-jsonld
be unarchived just long enough for one further release on PyPI. That release should include a dependency onrdflib>=6.0.0
. Its main__init__.py
should raise aDeprecationWarning
on import. If possible, aDeprecationWarning
should be raised duringpip install
. All other functionality (other.py
files, and complexity insetup.py
) should be removed.The text was updated successfully, but these errors were encountered: