<< Back to previous view

[CONTRIB-93] remove deprecations on master Created: 24/Aug/10  Updated: 03/Sep/10  Resolved: 03/Sep/10

Status: Closed
Project: Clojure-Contrib
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: Defect
Reporter: Anonymous Assignee: bpsm
Resolution: Completed Votes: 0
Labels: None


 Description   

I noticed the recent aborted attempt to remove the deprecated modules form clojure-contrib master. Since I was in need of some busy work, I decided to try and do it myself and clean up the breakage.

The attached patches don't remove everything that has been marked as deprecated, just the bits Stuart previously indicated by trying to remove them.

  • clojure.contrib.apply-macro
  • clojure.contrib.http-agent
  • clojure.contrib.http-connection
  • clojure.contrib.javadoc: which rewrote a :use in repl_utils.clj from c.c.javadoc.browse to c.java.browse.
  • clojure.contrib.properties: where private versions of as-str and as-properties were defined in c.c.sql internal.clj
  • clojure.contrib.test-is


 Comments   
Comment by Assembla Importer [ 03/Sep/10 8:52 PM ]

Converted from http://www.assembla.com/spaces/clojure/tickets/93
Attachments:
0001-remove-derecated-clojure.contrib.apply-macro.patch - https://www.assembla.com/spaces/clojure/documents/dFW7nWR6ir34gmeJe5cbLA/download/dFW7nWR6ir34gmeJe5cbLA
0002-remove-deprecated-clojure.contrib.http-agent.patch - https://www.assembla.com/spaces/clojure/documents/dFW9QaR6ir34gmeJe5cbLA/download/dFW9QaR6ir34gmeJe5cbLA
0003-remove-deprecated-clojure.contrib.http-connection.patch - https://www.assembla.com/spaces/clojure/documents/dFXab4R6ir34gmeJe5cbLA/download/dFXab4R6ir34gmeJe5cbLA
0004-remove-deprecated-clojure.contrib.properties.patch - https://www.assembla.com/spaces/clojure/documents/dFXcqIR6ir34gmeJe5cbLA/download/dFXcqIR6ir34gmeJe5cbLA
0005-remove-deprecated-clojure.contrib.javadoc.patch - https://www.assembla.com/spaces/clojure/documents/dFXeH2R6ir34gmeJe5cbLA/download/dFXeH2R6ir34gmeJe5cbLA
0007-remove-deprecated-clojure.contrib.test-is.patch - https://www.assembla.com/spaces/clojure/documents/dFXg04R6ir34gmeJe5cbLA/download/dFXg04R6ir34gmeJe5cbLA
0008-removed-c.c.shell-and-c.c.shell-out.patch - https://www.assembla.com/spaces/clojure/documents/ahtcAoR60r34W9eJe5cbCb/download/ahtcAoR60r34W9eJe5cbCb
remove-deprecated-clojure.contrib.io.patch - https://www.assembla.com/spaces/clojure/documents/bR5RKOSu0r36XVeJe5cbLA/download/bR5RKOSu0r36XVeJe5cbLA
0010-create-clojure.contrib.io-convenience-module.patch - https://www.assembla.com/spaces/clojure/documents/dxyjsaSHar37S6eJe5cbCb/download/dxyjsaSHar37S6eJe5cbCb
0011-remove-deprecated-clojure.contrib.str-utils.patch - https://www.assembla.com/spaces/clojure/documents/dEtFMSSRir35x5eJe5cbCb/download/dEtFMSSRir35x5eJe5cbCb
0013-remove-deprecated-clojure.contrib.string.patch - https://www.assembla.com/spaces/clojure/documents/dSD8sqSRir35nTeJe5cbLr/download/dSD8sqSRir35nTeJe5cbLr
0012-remove-deprecated-clojure.contrib.str-utils2.patch - https://www.assembla.com/spaces/clojure/documents/dSzxyYSRir35nTeJe5cbLr/download/dSzxyYSRir35nTeJe5cbLr
0014-removed-deprecated-clojure.contrib.duck-streams.patch - https://www.assembla.com/spaces/clojure/documents/cJIVlaSTur34OJeJe5cbLr/download/cJIVlaSTur34OJeJe5cbLr
0015-removed-deprecated-clojure.contrib.java-utils.patch - https://www.assembla.com/spaces/clojure/documents/cJNkS8STur34OJeJe5cbLr/download/cJNkS8STur34OJeJe5cbLr
0016-removed-deprecated-clojure.contrib.pprint.patch - https://www.assembla.com/spaces/clojure/documents/cJQGkcSTur34OJeJe5cbLr/download/cJQGkcSTur34OJeJe5cbLr
0017-removed-deprecated-source-get-source-apropos-from-cl.patch - https://www.assembla.com/spaces/clojure/documents/cJ5Kd4STur34OJeJe5cbLr/download/cJ5Kd4STur34OJeJe5cbLr
0018-removed-deprecated-clojure.contrib.seq-utils.patch - https://www.assembla.com/spaces/clojure/documents/cJ8-lqSTur34OJeJe5cbLr/download/cJ8-lqSTur34OJeJe5cbLr
0020-removed-deprecated-subset-superset-from-clojure.cont.patch - https://www.assembla.com/spaces/clojure/documents/da5unsSTur34OJeJe5cbLr/download/da5unsSTur34OJeJe5cbLr
0019-removed-9-deprecated-functions-from-clojure.contrib..patch - https://www.assembla.com/spaces/clojure/documents/daZ0rSSTur34OJeJe5cbLr/download/daZ0rSSTur34OJeJe5cbLr

Comment by Assembla Importer [ 03/Sep/10 8:52 PM ]

bpsm said: [file:ahtcAoR60r34W9eJe5cbCb]

Comment by Assembla Importer [ 03/Sep/10 8:52 PM ]

bpsm said: I'll submit further patches as I have time. Not being "in the loop", I can't be certain that we really want all the namespaces marked as deprecated gone before 1.3, but that's my operating assumption. (I'm attaching one patch per namespace so that the comitters can be selective.)

Comment by Assembla Importer [ 03/Sep/10 8:52 PM ]

bpsm said: [file:bR5RKOSu0r36XVeJe5cbLA]

Comment by Assembla Importer [ 03/Sep/10 8:52 PM ]

bpsm said: [file:dxyjsaSHar37S6eJe5cbCb]: proposed new c.c.io providing only what was not migrated to Clojure proper

Comment by Assembla Importer [ 03/Sep/10 8:52 PM ]

bpsm said: Proposal: when a namespace is partially promoted to Clojure proper, it might be good to provide a reduced version of the old namespace, providing just the functionality that was not promoted as an alternative to complete removal.

I've sketched out this idea as a patch: 0010-create-clojure.contrib.io-convenience-module.

I'm imagining something like:

  • most of clojure.contrib.io is promoted to clojure 1.2
  • clojure-contrib 1.2 deprecates, but does not remove clojure.contrib.io
  • clojure-contrib 1.3 provides a reduced version of clojure.contrib.io containing only non-deprecatd functionality not available elsewhere (i.e. in Clojure ��� 1.2).

This new clojure.contrib.io is not a strict subset of the old clojure.contrib.io, as some changes seemed sensible to harmonize with clojure.java.io's conventions. This means, it's not a drop-in replacement, but at least provides equivalents for anyone trying to get off the deprecated clojure.contrib.io.

One problem that's apparent with this proposal is that, since the 'new' io only becomes available in 1.3, there would be something of a "flag day" when switching from 1.2 to 1.3, but then there would be if 1.3 completely eliminated c.c.io as well – only it would be worse.

Comment by Assembla Importer [ 03/Sep/10 8:52 PM ]

stuart.sierra said: clojure.contrib.io is deprecated, period. It will be removed in the next release.

Comment by Assembla Importer [ 03/Sep/10 8:52 PM ]

bpsm said: Fine, so ignore patch 0010. That's why it's a "proposal".

Those moving their code off of c.c.io to c.j.io will just have to write their own versions of a subset of {file-str, write-lines, read-lines, pwd, with-out, with-in, to-byte-array, relative-path-string and delete-file-recursively}, or get these from a library outside of clojure-contrib. Am I understanding correctly?

Patch 0010 contains (in the comments) some tips for porting from deprecated c.c.io to c.j.io. It would make sense to gather that kind of information in some kind of a guide/faq about how to replace uses of deprecated c.c. namespaces promotion to core was not 1-to-1.

Comment by Assembla Importer [ 03/Sep/10 8:52 PM ]

bpsm said: ���replace uses of deprecated c.c. namespaces where promotion to core was not 1-to-1.

Comment by Assembla Importer [ 03/Sep/10 8:52 PM ]

bpsm said: [file:dEtFMSSRir35x5eJe5cbCb]

Comment by Assembla Importer [ 03/Sep/10 8:52 PM ]

bpsm said: [file:dSzxyYSRir35nTeJe5cbLr]

Comment by Assembla Importer [ 03/Sep/10 8:52 PM ]

bpsm said: [file:dSD8sqSRir35nTeJe5cbLr]

Comment by Assembla Importer [ 03/Sep/10 8:52 PM ]

bpsm said: [file:cJIVlaSTur34OJeJe5cbLr]

Comment by Assembla Importer [ 03/Sep/10 8:52 PM ]

bpsm said: [file:cJNkS8STur34OJeJe5cbLr]

Comment by Assembla Importer [ 03/Sep/10 8:52 PM ]

bpsm said: [file:cJQGkcSTur34OJeJe5cbLr]

Comment by Assembla Importer [ 03/Sep/10 8:52 PM ]

bpsm said: [file:cJ5Kd4STur34OJeJe5cbLr]

Comment by Assembla Importer [ 03/Sep/10 8:52 PM ]

bpsm said: [file:cJ8-lqSTur34OJeJe5cbLr]

Comment by Assembla Importer [ 03/Sep/10 8:52 PM ]

bpsm said: [file:daZ0rSSTur34OJeJe5cbLr]

Comment by Assembla Importer [ 03/Sep/10 8:52 PM ]

bpsm said: [file:da5unsSTur34OJeJe5cbLr]

Comment by Assembla Importer [ 03/Sep/10 8:52 PM ]

bpsm said: This task looks done to me. I can nothing further in clojure-contrib that's been deprecated. I've placed these patches on a branch on github for easy browsing.

Generated at Mon Nov 24 09:33:09 CST 2014 using JIRA 4.4#649-r158309.