-
Notifications
You must be signed in to change notification settings - Fork 44
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
Addition of comment export functionality (per video, as JSON, format example see in comment). #13
Comments
As implemented here: |
I can see the value in having this functionality and is similarly something I have in my youtube-geofind web tool. This should be fairly simple to implement. I'll definitely look into adding this somehow. |
I'm fairly close to finishing this though there are some caveats about the right behavior and wonder what you were expecting. I have two export modes, flattened (comments and replies on the same level like they appear in the app) and condensed (how they would appear from that example/site and on the YouTube site, where replies are in a list as part of a parent comment). Flattened mode is great and easy haha. Searching for "Comments and Replies" in YCS with default/no filters is how that site works and exporting results in condensed mode should result in almost the same thing. However, you can't have condensed mode when you are searching "Comments Only" and "Replies Only", they would always have to be flattened. You could only export in condensed mode when searching both "Comments and Replies" because you kinda need both haha. There is also the situation of a filtered query
|
Hey Matthew,
great, thanks so much for your efforts! If it's too much work to integrate
the condensed mode, just stay with flattened, no problem. As long as you
have all comments in the export it shouldn't matter too much. I did notice
that on YouTube comments get omitted if you don't sort by newest, if those
end up in the export that would be great of course. I don't really care
about filtering for export, I just want all comments/replies in there, so I
can save them next to the video file. Sure it's n2h, but don't kill too
many of your brain cells with it. :D Just do it however you feel is most
beneficial without being too complicated to implement. ;-)
…On Tue, Jun 25, 2019, 03:05 Matthew Wright ***@***.***> wrote:
I'm fairly close to finishing this though there are some caveats about the
right behavior and wonder what you were expecting. I have two export modes,
flattened (comments and replies on the same level like they appear in the
app) and condensed (how they would appear from that example/site and on the
YouTube site, where replies are in a list as part of a parent comment).
Flattened mode is great and easy haha.
Searching for "Comments and Replies" in YCS with default/no filters is how
that site works and exporting results in condensed mode should result in
almost the same thing.
However, you can't have condensed mode when you are searching "Comments
Only" and "Replies Only", they would always have to be flattened. You could
only export in condensed mode when searching both "Comments and Replies"
because you kinda need both haha.
There is also the situation of a filtered query
- A reply when the parent comment filtered out, leave at base level or
omit from export file?
- A parent comment with some or all replies filtered out, only show
filtered ones if they fit the query? Show all replies regardless of query
filters (similar to how 'view thread' works in app)?
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#13?email_source=notifications&email_token=AIMV2B5ZEIBPIJARHLJNDJTP4FVPLA5CNFSM4HPUFFLKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGODYOUZJY#issuecomment-505236647>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AIMV2B5SSLWDW473DGYIHRLP4FVPLANCNFSM4HPUFFLA>
.
|
What if I we're to only allow condensed mode in ideal conditions which would satisfy what you've described is what you want?
I'll note that currently condensed mode is also slower than flattened as it has to process comment threads (grab all comments in the thread) as they appear in the results list per video. The folder structure when exporting will look like the following:
Following this structure, the generated export folder |
Sorry if I missed something; but could the channel ID also be included (which left the comment) along with the channel ID which uploaded the video please? |
Yup, those fields are included per |
Sounds awesome!
…On Thu, Jun 27, 2019, 01:47 Matthew Wright ***@***.***> wrote:
What if I we're to only allow condensed mode in ideal conditions which
would satisfy what you've described is what you want?
- Only condensed mode is available when "Comments and Replies" is used
and Name Like & Text Like are empty?
- Otherwise, flattened mode.
I'll note that currently condensed mode is also slower than flattened as
it has to process comment threads (grab all comments in the thread) as they
appear in the results list per video.
The folder structure when exporting will look like the following:
folder-where-ycs-is-located/
youtube-comment-suite.jar
{other files...}
exports/
{yyyy.MM.dd hh.mm.ss}/
searchSettings.json
videoId-meta.json
videoId-comments.json
Following this structure, the generated export folder {yyyy.MM.dd
hh.mm.ss}/ will have the date and time that the export button was pressed
e.g. 2019.06.26 19.44.12/. The file searchSettings.json will give some
context for what your Search Comments tab options were when exporing. All
comments will be exported per-video as you've suggested in the format of
videoId-meta.json describing the details of the video (id, title,
description, published date, etc.) and videoId-comments which will be an
array of all comments either in the condensed or flattened format.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#13?email_source=notifications&email_token=AIMV2BZHUOMOKWLS6X2TJFDP4P52FA5CNFSM4HPUFFLKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGODYVDZ3I#issuecomment-506084589>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AIMV2BYWUBBFDBNYLS2WVDLP4P52FANCNFSM4HPUFFLA>
.
|
This has been mostly implemented in 073be22 on the replace-ytapi branch. Behaves as described in previous comments. There is still some testing and tweaking to do but it will be in the next release. |
Is it possible for there to be a function to export all comments as a CSV or excel please? |
The text was updated successfully, but these errors were encountered: