Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Empty file extension on API search response #1450

@Enola-guy

Description

@Enola-guy

When I query GET "/searches/{search_id}/responses" I get this response:

FILE DATA {'username': 'toto', 'filename': 'My Beloved (Soulseek) [all flac]\\Labels\\Alt Fäger\\[B-MAJ100] Tom & Jerry - Things (2019)\\08. Bar & Foo - The Word Around.flac', 'file_path': 'My Beloved (Soulseek) [all flac]\\Labels\\Alt Fäger\\[B-MAJ100] Tom & Jerry - Things (2019)\\08. Bar & Foo - The Word Around.flac', 'file_size': 36413895, 'extension': '', 'bitrate': None, 'sample_rate': 44100, 'bit_depth': 16, 'duration': 354}

I tried to check slskd's source code to reproduce the bug with this line, I'm not familiar in C# so maybe it's not here at all..

// file /src/slskd/Shares/SoulseekFileFactory.cs
            var extension = Path.GetExtension(filename).TrimStart('.').ToLowerInvariant();

I got "flac" by running this line in a script so maybe it's a bug from the query to the db ? Let me know if you want help to investigate this LOW LOW LOW LOW priority bug.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions