Skip to content
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

[weibo] No date #829

Closed
rEnr3n opened this issue Jun 14, 2020 · 6 comments
Closed

[weibo] No date #829

rEnr3n opened this issue Jun 14, 2020 · 6 comments

Comments

@rEnr3n
Copy link

rEnr3n commented Jun 14, 2020

$ gallery-dl --version
1.14.1
$ gallery-dl -K https://m.weibo.cn/status/4149641023062898 | grep -i date

Please add date for weibo.

@iamleot
Copy link
Contributor

iamleot commented Jun 14, 2020

Isn't there a created_at?

@rEnr3n
Copy link
Author

rEnr3n commented Jun 14, 2020

I can't format it like {date:%Y-%m-%dT%H:%M:%SZ}.

@iamleot
Copy link
Contributor

iamleot commented Jun 14, 2020

That's probably because it is not parsed and it is handled just as a string.

It is probably pretty easy to adapt though if you would like to try that! Please give a look to e.g. text.parse_datetime() usage in gallery_dl/extractor/twitter.py extractor.

@mikf
Copy link
Owner

mikf commented Jun 16, 2020

I've added a date field to the status object where currently most of the metadata lives.
You'd have to do {status[date]:%Y-%m-%dT%H:%M:%SZ} to access it.

I'm thinking of moving everything from said status object into the base level and maybe make it more like Twitter's metadata. Would that be OK, given that it would invalidate you and others filename format strings?

@rEnr3n
Copy link
Author

rEnr3n commented Jun 17, 2020

You'd have to do {status[date]:%Y-%m-%dT%H:%M:%SZ} to access it.

I only see this under filename keywords. Please add it under directory keywords as well.

I'm thinking of moving everything from said status object into the base level and maybe make it more like Twitter's metadata. Would that be OK, given that it would invalidate you and others filename format strings?

I'm fine with it. I guess there should be deprecation warnings regarding changing of keywords in general. That's a different issue.

mikf added a commit that referenced this issue Jun 18, 2020
@mikf
Copy link
Owner

mikf commented Jun 18, 2020

I've left the metadata structure as it was, and there is now also a date field for directory names (still status[date] for filenames).

@mikf mikf closed this as completed Jun 18, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants