diff-match-patch icon indicating copy to clipboard operation
diff-match-patch copied to clipboard

pypi release out of date

Open nikolas opened this issue 7 years ago • 20 comments
trafficstars

Hi, The version of diff-match-patch on pypi is pretty out of date (2012-2013): https://pypi.org/project/diff-match-patch/

Do you have the ability to update this?

nikolas avatar May 31 '18 17:05 nikolas

Nope, never heard of that website before. Sorry.

NeilFraser avatar May 31 '18 22:05 NeilFraser

pypi.org is the standard repository for Python libraries. You can find it linked from the top bar on https://www.python.org/ (it used to be pypi.python.org, that now redirects to pypi.org).

pypi.org is used by all the standard Python tools for packaging and installation (e.g. pip) - see the Python Packaging User Guide. So obviously it would be good if the Python diff-match-patch packages could be put there.

For this reason, quite a few years ago I packaged diff-match-patch for pypi - here - https://pypi.org/project/diff-match-patch/

Seeing as this project now seems to be active again, if the google/diff-match-patch team would like to take over packaging, I'd be very happy for them to do so, and give access to be able to push new releases to pypi.org. The setup.py file I wrote would be a good starting point: https://bitbucket.org/spookylukey/diff-match-patch/src/default/setup.py

This would make more sense than me doing it. Could we re-open this ticket?

spookylukey avatar Jun 01 '18 19:06 spookylukey

@NeilFraser You must be joking

HWiese1980 avatar Jun 19 '18 05:06 HWiese1980

I'm not trying to be disrespectful, but hosting websites have a disturbingly short half-life. During the course of Diff Match Patch's life so far, we've seen the appearance and/or disappearance of PyPI, pip, PyPM, Py3k, npm, code.google.com, SourceForge, GitHub, Closure, Yarn, Bower, Ender, and dozens more. Nearly all my time on this project is devoted to trying to keep the current functionality from degrading as the languages we support and their respective environments shift over time.

If PyPI appears to be stable and healthy, I'll add it to the list of maintenance tasks.

NeilFraser avatar Jun 19 '18 06:06 NeilFraser

PyPI is indeed stable and healthy. It has been around since shortly after 2002 (I can’t find the exact year/date) and has been the canonical Python package index for some time now.

It was recently was redesigned and moved from a python.org sub domain which may make it seem less familiar. It is now much better 😀

d0ugal avatar Jun 19 '18 07:06 d0ugal

During the course of Diff Match Patch's life so far, we've seen the appearance and/or disappearance of PyPI, [...]

As far as I know PyPi actually predates diff-match-patch by a couple of years (going by the date 2006 in the readme).

lithammer avatar Jun 19 '18 07:06 lithammer

It would be very helpful to at least add setup.py to the repository, so it could be easily installed with pip

miszczu avatar Jun 19 '18 10:06 miszczu

@spookylukey

Maybe you should just repackage the new version and upload it? Or at least make all necessary changes to setup.py yourself and open a PR? Regardless of the fact that pypi is very old and very mainstream, it's still another hurdle for the author to jump through when updating this code and maybe he has no interest (this isn't a minor factor given the different languages supported in this repo).

ApproximateIdentity avatar Jun 19 '18 12:06 ApproximateIdentity

@ApproximateIdentity

I'm very happy to upload a new version myself, or preferably to give PyPI permissions to someone who wants to take this on (I no longer actually use the library myself). I'm not going to submit a PR for a setup.py that won't be used or maintained, if @NeilFraser doesn't want to take that on (and that's fine) there is no point doing so.

However, before releasing to PyPI we'd need some clear idea of how versioning is going to work going forward. There used to be regular releases (when it was on code.google.com), using a date based timestamp as the version number. I'm unable to work out what the current version number is, or how it should be determined, if an actual release has been done etc.

spookylukey avatar Jun 20 '18 09:06 spookylukey

I'm not trying to be disrespectful...

@NeilFraser Nope. You're being disrespectful and unhelpful too.

dvf avatar Jun 20 '18 12:06 dvf

Unfortunately, Python packing isn't wonderfully straightforward, so perhaps @NeilFraser there's someone at Google who could lend you a hand? I know the Google Cloud team does a good job with getting their stuff onto PyPI (here's one example. And PyPI is indeed the place to be for Python packages; I was pretty surprised when I saw only the old unofficial package from @spookylukey.

anseljh avatar Aug 09 '18 01:08 anseljh

Since I haven't seen any traction on this, and adding a proper setup.py is not tenable IMO given the directory structure in this repo, I created a new package dmp that repackages diff-match-patch for Python with proper structure, metadata, CI, etc. It also provides seamless support for both py2 and py3 use cases from the same package. The top level import is just dmp, to prevent collision with already-installed versions of diff_match_patch, but is otherwise available for use today with the same API.

PyPI link: https://pypi.org/project/dmp/ Repo: https://github.com/jreese/dmp

I'm open to suggestions on how to integrate this back into diff-match-patch, or in merging it into the existing diff-match-patch package on PyPI – feel free to open issues or PRs on the dmp repo as appropriate.

amyreese avatar Nov 07 '18 20:11 amyreese

@jreese - AFAICS what you have done is equivalent to what I had already done in my version, which is hosted here - https://bitbucket.org/spookylukey/diff-match-patch/src I suspect most people using diff-match-patch are using this version I packaged for PyPI.

If you want to take over maintenance of this package, I'm very happy to give you PyPI permissions. The only discussion on this ticket was if Google wanted to take ownership of this package, which it seems like they don't. So, instead of making a new package on PyPI you can take ownership of the existing one. Feel free to use GitHub etc., maintain and package however you want, there is no need to maintain continuity with the existing bitbucket repo in any way, but a new PyPI name doesn't seem to achieve anything, I think?

spookylukey avatar Nov 08 '18 11:11 spookylukey

@spookylukey that works for me. I created the new repo/package name just to get something working when I needed it for other projects, but would be more than happy to take over maintenance of the existing package instead. I'm "jreese" on pypi.org.

amyreese avatar Nov 10 '18 01:11 amyreese

@jreese OK great, I've added you as an "Owner", I am no longer needed for anything on this project now. I'm assuming you do not need/want the repo on Bitbucket, please confirm this and I will delete it / make it point to the new repo. Please confirm what the name of that repo will be. For myself, I've usually found it best to create a new organisation for every new library/project I work on, in the knowledge that I often want to stop being maintainer at some point, and then it is easier to add collaborators and involves less link-churn if it is part of a non-personal organisation.

spookylukey avatar Nov 11 '18 06:11 spookylukey

I created https://github.com/diff-match-patch-python/diff-match-patch and pushed my existing module there. I'll update it with the original module name and match the existing versioning scheme. Cheers!

amyreese avatar Nov 12 '18 00:11 amyreese

@jreese Any chance of a new PyPI release to pick up the likes of ffe7c7be61a0? I'd have asked over on your new repo but I could not see where to open an issue (maybe I need some covid19 spectacles?).

ShaheedHaque avatar Jul 10 '20 10:07 ShaheedHaque

@ShaheedHaque I'll try to get merge and get a new release out tonight or tomorrow. Looks like I turned issues off by accident when I meant to turn off the wiki 😅 so feel free to request new releases there in the future. Cheers!

amyreese avatar Jul 10 '20 18:07 amyreese

Thanks. Perhaps after that this issue can be closed...

ShaheedHaque avatar Jul 10 '20 21:07 ShaheedHaque

@jreese Thanks for the new release, I can confirm the warnings I reported are gone.

ShaheedHaque avatar Jul 21 '20 08:07 ShaheedHaque