Subject: | Recommend rename distribution to Text::File::Parser (or similar) |
Date: | Fri, 7 Sep 2018 18:12:39 -0400 |
To: | bug-textfileparser [...] rt.cpan.org |
From: | James E Keenan <jkeenan [...] pobox.com> |
Balaji Ramasubramanian,
My attention was recently called to
https://metacpan.org/release/TextFileParser, which appears to be your
first release to CPAN. Thank you very much for writing this
distribution. Welcome to CPAN.
I would, however, like to point out some things about your release that
may discourage other users from using it. Fortunately, these things are
correctable -- and I hope you will undertake such corrections.
#####
First, by naming your module "TextFileParser" rather than, say,
Text::File::Parser, you have committed the faux pas of needlessly
generating a new top-level namespace on CPAN. CPAN distributions are
generally named following a convention where the top-level namespace
refers to a large class of computing problems; the lower-level parts of
the namespace get more specific. If a CPAN distribution has as its
focus a problem which falls into a large, well-known class of computing
problems, then it ought not to create a new top-level namespace; rather,
it should start at the top-level and proceed downward.
Concretely, this means that a distribution whose purpose is the parsing
of text files should be placed in the top-level namespace "Text".
Suppose that the purpose of your distribution were to parse a particular
type of plain-text file known as "Gamma" files. Then you would probably
want to name your module something like:
Text::Parse::Gamma
You would *not* want to create a new distribution called:
TextParseGamma
Anyone coming across "TextParseGamma" would immediately spot that as
being the work of someone unfamiliar with the conventions of CPAN and
the worldwide Perl community. That would be an impediment to getting
other people to use your code -- which, after all, is the purpose of CPAN.
#####
Second, when documenting CPAN modules (much like when doing academic
research or filing a patent application), it is important to discuss
prior art in the subject area and why a new CPAN module is needed. In
your case -- the parsing of CSV files -- there are two CPAN
distributions which have been in development and widespread production
use for more than twenty years:
https://metacpan.org/pod/Text::CSV
and its XS variant
https://metacpan.org/pod/Text::CSV_XS
Those distributions are well maintained and well respected, as evidence
by the fact that other CPAN contributors have built other CPAN
distributions dependent upon them. (For example, I have written
https://metacpan.org/pod/Text::CSV::Hashify).
Now, this being Perl, There Is More Than One Way to Do It(TM), so fresh
approaches to computing problems are always welcome. But if you're
going to push some code to CPAN that is focused on a problem which other
people have already addressed, at the very least you must discuss that
prior art, provide links to those distributions and suggest why someone
would use your distribution instead of those others.
#####
My hunch is that, like many first-time CPAN contributors, you have not
thoroughly understood what CPAN users expect out of new distributions.
Don't worry, you're not alone in this. I made the same or similar
mistakes when I started contributing to CPAN. Nonetheless, I recommend
the following:
* Read these two documents which are part of the Perl 5 core distribution:
** perldoc perlnewmod
** perldoc perlmodlib
... available at your command-line or perldoc.perl.org. These documents
are aimed at helping you avoid the most typical missteps by new CPAN
authors. Review what you have done so far in the light of the guidance
they provide, and revise accordingly.
* Subscribe to the 'module-authors' mailing list at lists.perl.org.
(Also available via news interface as 'perl.module-authors' from the
nntp.perl.org server.) This is not a high-volume mailing list, but it
is the place where you should go to get feedback on (a) the naming of
CPAN distributions and (b) where your ideas stand in relation to prior
art. Once you have revised your distribution in the light of having
read 'perlnewmod' and 'perlmodlib', you would do well to post on the
'module-authors' list about your module before re-uploading to CPAN.
* Should you choose to revise the name of your CPAN distribution so as
to use a more conventional top-level namespace like 'Text' (rather than
'TextFileParser'), once you have used the PAUSE interface to upload your
new distribution you would simply click on the 'Delete Files' link and
schedule your releases under the 'TextFileParser' namespace for deletion
-- or, more precisely, for removal to http://backpan.perl.org/authors/id/.
Once again, thanks for contributing to CPAN and the worldwide Perl
community. I hope the suggestions I've made will enable you to make
more and improved contributions in the future.
Thank you very much.
James E Keenan
CPAN ID: JKEENAN