From: "T.V Raman" <raman@google.com>
To: Stefan Monnier <monnier@iro.umontreal.ca>
Cc: Ergus <spacibba@aol.com>, emacs-devel@gnu.org
Subject: Re: Supported/Bundled CSV support?
Date: Tue, 15 Mar 2022 08:27:23 -0700 [thread overview]
Message-ID: <p911qz3me1w.fsf@google.com> (raw)
In-Reply-To: <jwvr173p8sv.fsf-monnier+emacs@gnu.org> (Stefan Monnier's message of "Tue, 15 Mar 2022 10:57:57 -0400")
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain; charset=gb18030, Size: 2513 bytes --]
Stefan Monnier <monnier@iro.umontreal.ca> writes:
Yes, you are correct.
There are modules like pcsv.el and similarly named ones from the past
that do an approximate job -- when I looked into this approx 20 years
ago, I also ended up writing one of my own within Emacspeak --- in my
experience each of these hand-rolled csv parsers are differently broken
in their own way -- including the one in emacspeak, since as as I
pointed out in my earlier message, parsing various variants of CSV is
surprizingly hard.
>> I think having built-in CSV support that abstracts away the various
>> details of parsing the various CSV variants will allow the emacs Dev
>> community to focus on user solutions e.g.:
>>
>> A. Seamless data import/export
>> B. Support the processing of larger amounts of data via org-table and the like
>> C. Json support vastly sped up modules like lsp and eglot; I'd expect
>> the same once we cross the chasm with respect to making CSV support
>> a built-in detail that elisp developers can take for granted.
>
> You might be right, but if so you're talking about a very different kind
> of "CSV support" than the kind I'm familiar with (which is the support
> to manually edit/browse a human-generated CSV file, as offered by
> `csv-mode`). You seem to be talking about code to efficiently parse
> a whole CSV file into a Lisp representation (list of lists or better) or
> to generate a CSV-formatted string from such Lisp representation.
>
> Is that right? In that case, indeed `csv-mode` is of no
> help, basically.
>
>
> Stefan
>
>
>>> Just an idea/question:
>>>
>>> With the new Lars package vtable may be possible to support CSV or add
>>> a package over it?
>>>
>>> I agree it is a bit annoying to depend of an external package for such
>>> a simple format and maybe the implementation may be simpler than
>>> expected as the format it pretty simple in general.
>>>
>>> WDYT?
>>>
>>> On March 14, 2022 11:30:43 PM GMT+01:00, Stefan Monnier
>>> <monnier@iro.umontreal.ca> wrote:
>>>
>>> Languages like Python work around this with a csv module that
>>> comes
>>> bundled; Emacs has a couple of modules out on elpa/melpa all of which
>>> look old.
>>>
>>> Don't know about Melpa, but in (Non)GNU ELPA, I can only find one such
>>> package and it dates back to Dec 2021.
>>>
>>> Stefan
>
--
Thanks,
--Raman(I Search, I Find, I Misplace, I Research)
7©4 Id: kg:/m/0285kf1 0Ü8
next prev parent reply other threads:[~2022-03-15 15:27 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-03-14 22:15 Supported/Bundled CSV support? T.V Raman
2022-03-14 22:30 ` Stefan Monnier
2022-03-15 7:36 ` Ergus
2022-03-15 14:05 ` T.V Raman
2022-03-15 14:57 ` Stefan Monnier
2022-03-15 15:27 ` T.V Raman [this message]
2022-03-16 13:43 ` Joost
2022-03-16 14:46 ` T.V Raman
2022-03-16 18:49 ` Stefan Monnier
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=p911qz3me1w.fsf@google.com \
--to=raman@google.com \
--cc=emacs-devel@gnu.org \
--cc=monnier@iro.umontreal.ca \
--cc=spacibba@aol.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).