writethedocs / www

The main website for Write the Docs.
http://www.writethedocs.org
Other
1.33k stars 511 forks source link

Automatically ish insert video ids into session data file #1965

Closed plaindocs closed 1 year ago

plaindocs commented 1 year ago

I noodled on this one early jetlagged morning, it could certainly be improved, and certainly took me longer than doing it by hand.

I found we've got a lot of old and not working scripts, no yaml dumping utility. :shrug:

@mxsasha would you mind taking a look and seeing if you think it's worth improving.


:books: Documentation preview :books:: https://writethedocs-www--1965.org.readthedocs.build/

mxsasha commented 1 year ago

I like it! This always takes me more time than I'd like. Using the Levenshtein distance for matching is a great idea. One additional safeguard could be to check that all youtube ID's are unique. Can use a bit of cleanup for sure.

plaindocs commented 1 year ago

Thanks @mxsasha

We've already got that safeguard in the main site code I think? So it's probs not worth adding twice?

Would you like to be more specific about cleanup? Or do you mean the rest of our code. :-D

mxsasha commented 1 year ago

Would you like to be more specific about cleanup? Or do you mean the rest of our code. :-D

This is what I had in mind: https://github.com/writethedocs/www/pull/1965/commits/4eb6cacb2ef04563635f0dd9619cd451db7bbc68

plaindocs commented 1 year ago

Would you like to be more specific about cleanup? Or do you mean the rest of our code. :-D

This is what I had in mind: 4eb6cac

Thanks @mxsasha ! Easier to do than to explain I reckon. :-D

plaindocs commented 1 year ago

OK, I fixed the merge, generated the files. Would you rereview (just double check it looks ship shape)

plaindocs commented 1 year ago

What the hell, did this really just add the same ID to every talk?

mxsasha commented 1 year ago

We've already got that safeguard in the main site code I think? So it's probs not worth adding twice?

What the hell, did this really just add the same ID to every talk?

🤔🤔🤔

plaindocs commented 1 year ago

[8b5d3e3](/writethedocs/www/pull/1965/commits/8b5d3e32806d7ec90712bce67879693a054698e9)

Yeah, if you look at 8b5d3e3 before I fixed it now it just added the same ID to every talk. :man_facepalming: