Skip to content

feat: explicit names for meetecho recordings#8062

Merged
rjsparks merged 3 commits into
ietf-tools:mainfrom
rjsparks:meetecho_recording_name
Oct 21, 2024
Merged

feat: explicit names for meetecho recordings#8062
rjsparks merged 3 commits into
ietf-tools:mainfrom
rjsparks:meetecho_recording_name

Conversation

@rjsparks

@rjsparks rjsparks commented Oct 21, 2024

Copy link
Copy Markdown
Member

fixes #3454

@rjsparks

rjsparks commented Oct 21, 2024

Copy link
Copy Markdown
Member Author

This gets us a step closer to not providing links when recordings don't exist. (see #7888)
Once we know we can expect explicit names (at some point in the future) we can change the functions to not return a link when there's no name given.

@jennifer-richards jennifer-richards left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Couple small nits.

I wonder if it'd make sense to simply make this the .../recording URL endpoint instead of specializing it. The structure of the payload would lend itself to other metadata relatively transparently. OTOH maybe it's better to plan on retiring this endpoint when that happens rather than mutating its behavior.

Comment thread ietf/api/tests.py
self.assertContains(r, "Restricted to role: Recording Manager", status_code=403)

r = self.client.post(url, {"apikey": apikey.hash()})
self.assertContains(r, "Too long since last regular login", status_code=400)

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If we don't already, we ought to cover features like this in a unit test of the require_api_key() decorator and trust that. (Not actually asking for a change here unless you're enthusiastic about it, just pointing it out.)

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I felt the lack-of-reuse pain, but didn't pursue it as I think we might want to rework all of these to use DRF going forward maybe?

Comment thread ietf/api/urls.py Outdated
# Let Meetecho set session video URLs
url(r'^meeting/session/video/url$', meeting_views.api_set_session_video_url),
# Let Meetecho tell us the name of its recordings
url(r'meeting/session/recordingname$', meeting_views.api_set_meetecho_recording_name),

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Need a ^ at the start.

Maybe make it ^meeting/session/recording-name to better match recording_name in the model (and kebab-case that we've used in other URLs, like doc/draft-aliases/ at line 27)

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

will get the ^.
I can kebob case it, but I don't think we have consistency there.

Comment thread ietf/meeting/models.py Outdated
name = self.meetecho_recording_name
if name is None or name.strip() == "":
name = self._session_recording_url_label()
if url_formatter.strip()!="" and name is not None:

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

style nit: spacing around !=

@rjsparks

Copy link
Copy Markdown
Member Author

we may need to use (build on top of) the recording url endpoint for non-meetecho generated youtube videos (e.g. those for MOQ right now).

@codecov

codecov Bot commented Oct 21, 2024

Copy link
Copy Markdown

Codecov Report

Attention: Patch coverage is 97.05882% with 1 line in your changes missing coverage. Please review.

Project coverage is 88.89%. Comparing base (c7f6bde) to head (e6c53bd).
Report is 123 commits behind head on main.

Files with missing lines Patch % Lines
ietf/meeting/models.py 90.90% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #8062      +/-   ##
==========================================
+ Coverage   88.78%   88.89%   +0.10%     
==========================================
  Files         296      304       +8     
  Lines       41320    41345      +25     
==========================================
+ Hits        36687    36754      +67     
+ Misses       4633     4591      -42     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@rjsparks rjsparks merged commit 8881010 into ietf-tools:main Oct 21, 2024
@rjsparks rjsparks deleted the meetecho_recording_name branch October 21, 2024 21:45
@github-actions github-actions Bot locked as resolved and limited conversation to collaborators Oct 26, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Build API to capture URLs to Meetecho hosted video recordings for a Session

2 participants