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

Fix reading from recording-attachments response #87

Merged
merged 7 commits into from
Aug 31, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion foxglove_data_platform/client.py
Original file line number Diff line number Diff line change
Expand Up @@ -773,7 +773,6 @@ def get_attachments(
{
"id": i["id"],
"recording_id": i["recordingId"],
"device": i["device"],
"site_id": i["siteId"],
"name": i["name"],
"media_type": i["mediaType"],
Expand Down
9 changes: 1 addition & 8 deletions tests/test_attachments.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,6 @@

@responses.activate
def test_get_attachments():
device_id = fake.uuid4()
device_name = fake.name()
attachment_id = fake.uuid4()
recording_id = fake.uuid4()
path = fake.file_name(extension="txt")
Expand All @@ -25,12 +23,11 @@ def test_get_attachments():

responses.add(
responses.GET,
api_url(f"/v1/recording-attachments"),
api_url("/v1/recording-attachments"),
json=[
{
"id": attachment_id,
"recordingId": recording_id,
"device": {"id": device_id, "name": device_name},
"siteId": site_id,
"name": path,
"mediaType": media_type,
Expand All @@ -53,10 +50,6 @@ def test_get_attachments():
"recording_id": recording_id,
"site_id": site_id,
"name": path,
"device": {
"id": device_id,
"name": device_name,
},
"media_type": media_type,
"size": size,
"crc": crc,
Expand Down