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

feat: Add Video Stream API #7360

Merged
merged 8 commits into from
Oct 28, 2020
Merged

feat: Add Video Stream API #7360

merged 8 commits into from
Oct 28, 2020

Conversation

iamareebjamal
Copy link
Member

@iamareebjamal iamareebjamal commented Oct 15, 2020

class VideoStream(db.Model):
"Video Stream or Room"

__tablename__ = 'video_streams'

Choose a reason for hiding this comment

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

Black would make changes.

def query(self, view_kwargs):
query_ = self.session.query(VideoStream)

if view_kwargs.get('room_id'):

Choose a reason for hiding this comment

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

Black would make changes.


class VideoStreamSchema(Schema):
class Meta:
type_ = 'video-stream'

Choose a reason for hiding this comment

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

Black would make changes.

@codecov
Copy link

codecov bot commented Oct 15, 2020

Codecov Report

Merging #7360 into development will increase coverage by 0.27%.
The diff coverage is 92.92%.

Impacted file tree graph

@@               Coverage Diff               @@
##           development    #7360      +/-   ##
===============================================
+ Coverage        64.23%   64.50%   +0.27%     
===============================================
  Files              259      262       +3     
  Lines            13130    13233     +103     
===============================================
+ Hits              8434     8536     +102     
- Misses            4696     4697       +1     
Impacted Files Coverage Δ
app/api/helpers/files.py 72.04% <ø> (-0.18%) ⬇️
app/settings/__init__.py 62.79% <ø> (-0.85%) ⬇️
app/api/video_stream.py 89.13% <89.13%> (ø)
app/models/video_stream.py 91.66% <91.66%> (ø)
app/api/microlocations.py 82.69% <100.00%> (+10.69%) ⬆️
app/api/routes.py 100.00% <100.00%> (ø)
app/api/schema/microlocations.py 100.00% <100.00%> (ø)
app/api/schema/video_stream.py 100.00% <100.00%> (ø)
app/models/microlocation.py 95.45% <100.00%> (+1.70%) ⬆️
app/api/speakers.py 68.86% <0.00%> (-0.07%) ⬇️
... and 8 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 11d5cd9...82a781d. Read the comment docs.


class MicrolocationSubVideoStreamFactory(MicrolocationFactoryBase):
event = factory.SubFactory(EventFactoryBasic)
video_stream = factory.SubFactory(VideoStreamFactoryBase)

Choose a reason for hiding this comment

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

redefinition of unused 'video_stream' from line 3

@@ -1,9 +1,11 @@
import factory

from app.models import video_stream

Choose a reason for hiding this comment

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

'app.models.video_stream' imported but unused

room = MicrolocationSubVideoStreamFactory(video_stream=stream)
session = SessionSubFactory(microlocation=room, event=room.event)
if user:
role, _ = get_or_create(Role, name='owner', title_name='Owner')

Choose a reason for hiding this comment

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

Black would make changes.

# decorators = (api.has_permission('is_admin', methods="POST"),)

def before_post(self, args, kwargs, data):
require_relationship(['rooms'], data)

Choose a reason for hiding this comment

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

Black would make changes.

@iamareebjamal iamareebjamal changed the title wip: Video Stream feat: Add Video Stream API Oct 28, 2020
@auto-label auto-label bot added the feature label Oct 28, 2020
@iamareebjamal iamareebjamal merged commit d3582cb into development Oct 28, 2020
@iamareebjamal iamareebjamal deleted the video-stream branch October 28, 2020 19:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
2 participants