question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Cannot get manifest due to `System.FormatException: 'The format of value '' is invalid.'`

See original GitHub issue

Version

ver 6.3.0

Details

I am simply trying to follow the Readme.md file but I repeatedly get: System.FormatException: 'The format of value '' is invalid.'
as soon as I await youtube.Videos.Streams.GetManifestAsync(videoUrl).

What am I missing?

Steps to reproduce

Simply run the GetManifestAsync method and you will get the FormatException:

var youtube = new YoutubeClient();  
// Get stream manifest  
var videoUrl = "https://youtube.com/watch?v=u_yIGGhubZs";  
var streamManifest = await youtube.Videos.Streams.GetManifestAsync(videoUrl);

Issue Analytics

  • State:closed
  • Created 2 months ago
  • Comments:5 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
Tyrrrzcommented, Jul 23, 2023

When the fix will be available?

Now.

Out of my curiosity, what was the issue about?

It was attempting to insert empty cookie headers for some URLs.

1reaction
Tyrrrzcommented, Jul 23, 2023

Thanks, fixed

Read more comments on GitHub >

github_iconTop Results From Across the Web

Adding HttpClient headers generates a FormatException ...
I got around this exception (my FormatException caused by commas in the value) by setting the Authorization header in the following way:
Read more >
The format of value xxx is invalid · Issue #5046
I get the following exception when I run the code (I use Mac): The format of ... is invalid. ... System.FormatException: The format...
Read more >
[Solved] Httpclient authorization issue
Why HttpClient rejects that exact value with a FormatException, is because it is an invalid Authorization value: valid Authorization values ...
Read more >
Issues installing Workbench's VSIX (combined from multiple ...
VisualStudio.ExtensionManager.InvalidExtensionManifestException: Element 'Identity' has invalid value for attribute 'Version' —> System.
Read more >
Input string was not in a correct format error when importing ...
When you import a solution in Microsoft Dynamics 365, you receive an error that states input string was not in a correct format...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found