Commit Graph

3594 Commits

Author SHA1 Message Date
Stephen Moore
e841922ffd Fix ArgumentOutOfRangeException scanning AudioBooks
AudioResolver.ResolveMultipleAudio method can attempt to access the first item in a List without checking if the list is empty which throws an ArgumentOutOfRangeException and stops the 'Scan Library' process.
2021-04-17 17:21:40 +01:00
BaronGreenback
bc1cc2d04a Remove unused using directives 2021-04-17 11:37:55 +01:00
Cody Robibero
b63f615fd4
Enable nullability for ServerDiscoveryInfo (#5804) 2021-04-15 15:39:59 +02:00
Bond_009
8045a488ce Fix possible ArgumentNullException
```
  Error Message:
   System.ArgumentNullException : Value cannot be null. (Parameter 'source')
  Stack Trace:
     at System.Linq.ThrowHelper.ThrowArgumentNullException(ExceptionArgument argument)
   at System.Linq.Enumerable.Select[TSource,TResult](IEnumerable`1 source, Func`2 selector)
   at Emby.Server.Implementations.Library.LibraryManager.ResolveItem(ItemResolveArgs args, IItemResolver[] resolvers) in /home/vsts/work/1/s/Emby.Server.Implementations/Library/LibraryManager.cs:line 475
   at Emby.Server.Implementations.Library.LibraryManager.ResolvePath(FileSystemMetadata fileInfo, IDirectoryService directoryService, IItemResolver[] resolvers, Folder parent, String collectionType, LibraryOptions libraryOptions) in /home/vsts/work/1/s/Emby.Server.Implementations/Library/LibraryManager.cs:line 618
   at Emby.Server.Implementations.Library.LibraryManager.ResolvePath(FileSystemMetadata fileInfo, Folder parent) in /home/vsts/work/1/s/Emby.Server.Implementations/Library/LibraryManager.cs:line 536
   at Emby.Server.Implementations.Library.LibraryManager.GetUserRootFolder() in /home/vsts/work/1/s/Emby.Server.Implementations/Library/LibraryManager.cs:line 812
   at Emby.Server.Implementations.Library.LibraryManager.GetCollectionFolders(BaseItem item) in /home/vsts/work/1/s/Emby.Server.Implementations/Library/LibraryManager.cs:line 2080
   at Emby.Server.Implementations.Library.LibraryManager.GetLibraryOptions(BaseItem item) in /home/vsts/work/1/s/Emby.Server.Implementations/Library/LibraryManager.cs:line 2116
   at MediaBrowser.Providers.Manager.ProviderManager.SaveMetadata(BaseItem item, ItemUpdateType updateType, IEnumerable`1 savers) in /home/vsts/work/1/s/MediaBrowser.Providers/Manager/ProviderManager.cs:line 672
   at MediaBrowser.Providers.Manager.ProviderManager.SaveMetadata(BaseItem item, ItemUpdateType updateType) in /home/vsts/work/1/s/MediaBrowser.Providers/Manager/ProviderManager.cs:line 655
   at Emby.Server.Implementations.Library.LibraryManager.RunMetadataSavers(BaseItem item, ItemUpdateType updateReason) in /home/vsts/work/1/s/Emby.Server.Implementations/Library/LibraryManager.cs:line 2017
   at Emby.Server.Implementations.Library.LibraryManager.UpdateItemsAsync(IReadOnlyList`1 items, BaseItem parent, ItemUpdateType updateReason, CancellationToken cancellationToken) in /home/vsts/work/1/s/Emby.Server.Implementations/Library/LibraryManager.cs:line 1975
   at Emby.Server.Implementations.Library.LibraryManager.CreateRootFolder() in /home/vsts/work/1/s/Emby.Server.Implementations/Library/LibraryManager.cs:line 775
   at Emby.Server.Implementations.Library.LibraryManager.get_RootFolder() in /home/vsts/work/1/s/Emby.Server.Implementations/Library/LibraryManager.cs:line 180
   at Emby.Server.Implementations.IO.LibraryMonitor.Start() in /home/vsts/work/1/s/Emby.Server.Implementations/IO/LibraryMonitor.cs:line 135
   at Emby.Server.Implementations.IO.LibraryMonitorStartup.RunAsync() in /home/vsts/work/1/s/Emby.Server.Implementations/IO/LibraryMonitorStartup.cs:line 26
   at Emby.Server.Implementations.ApplicationHost.StartEntryPoints(IEnumerable`1 entryPoints, Boolean isBeforeStartup)+MoveNext() in /home/vsts/work/1/s/Emby.Server.Implementations/ApplicationHost.cs:line 518
   at System.Threading.Tasks.Task.WhenAll(IEnumerable`1 tasks)
   at Emby.Server.Implementations.ApplicationHost.RunStartupTasksAsync(CancellationToken cancellationToken) in /home/vsts/work/1/s/Emby.Server.Implementations/ApplicationHost.cs:line 502
   at Jellyfin.Server.Integration.Tests.JellyfinApplicationFactory.CreateServer(IWebHostBuilder builder) in /home/vsts/work/1/s/tests/Jellyfin.Server.Integration.Tests/JellyfinApplicationFactory.cs:line 101
   at Microsoft.AspNetCore.Mvc.Testing.WebApplicationFactory`1.EnsureServer()
   at Microsoft.AspNetCore.Mvc.Testing.WebApplicationFactory`1.CreateDefaultClient(DelegatingHandler[] handlers)
   at Microsoft.AspNetCore.Mvc.Testing.WebApplicationFactory`1.CreateDefaultClient(Uri baseAddress, DelegatingHandler[] handlers)
   at Microsoft.AspNetCore.Mvc.Testing.WebApplicationFactory`1.CreateClient(WebApplicationFactoryClientOptions options)
   at Microsoft.AspNetCore.Mvc.Testing.WebApplicationFactory`1.CreateClient()
   at Jellyfin.Server.Integration.Tests.Controllers.ActivityLogControllerTests.ActivityLog_GetEntries_Ok() in /home/vsts/work/1/s/tests/Jellyfin.Server.Integration.Tests/Controllers/ActivityLogControllerTests.cs:line 21
--- End of stack trace from previous location ---
```
2021-04-12 22:01:35 +02:00
Bond-009
b94218849c
Merge pull request #5784 from Bond-009/racecondition
Fix random failing of tests
2021-04-12 15:47:37 +02:00
Bond_009
a4ffc7a813 Fix random failing of tests
Fully initialize the configuration manager at the init stage

```
Failed Jellyfin.Server.Integration.Tests.Controllers.ActivityLogControllerTests.ActivityLog_GetEntries_Ok [2 s]
  Error Message:
   MediaBrowser.Common.Extensions.ResourceNotFoundException : Configuration with key metadata not found.
  Stack Trace:
     at Emby.Server.Implementations.AppBase.BaseConfigurationManager.<>c__DisplayClass43_0.<GetConfiguration>b__0(String k) in D:\a\1\s\Emby.Server.Implementations\AppBase\BaseConfigurationManager.cs:line 309
   at System.Collections.Concurrent.ConcurrentDictionary`2.GetOrAdd(TKey key, Func`2 valueFactory)
   at Emby.Server.Implementations.AppBase.BaseConfigurationManager.GetConfiguration(String key) in D:\a\1\s\Emby.Server.Implementations\AppBase\BaseConfigurationManager.cs:line 300
   at MediaBrowser.Common.Configuration.ConfigurationManagerExtensions.GetConfiguration[T](IConfigurationManager manager, String key) in D:\a\1\s\MediaBrowser.Common\Configuration\IConfigurationManager.cs:line 88
   at MediaBrowser.Controller.Library.MetadataConfigurationExtensions.GetMetadataConfiguration(IConfigurationManager config) in D:\a\1\s\MediaBrowser.Controller\Library\MetadataConfigurationStore.cs:line 28
   at Emby.Server.Implementations.Library.ResolverHelper.SetDateCreated(BaseItem item, IFileSystem fileSystem, FileSystemMetadata info) in D:\a\1\s\Emby.Server.Implementations\Library\ResolverHelper.cs:line 159
   at Emby.Server.Implementations.Library.ResolverHelper.EnsureDates(IFileSystem fileSystem, BaseItem item, ItemResolveArgs args) in D:\a\1\s\Emby.Server.Implementations\Library\ResolverHelper.cs:line 153
   at Emby.Server.Implementations.Library.ResolverHelper.SetInitialItemValues(BaseItem item, ItemResolveArgs args, IFileSystem fileSystem, ILibraryManager libraryManager) in D:\a\1\s\Emby.Server.Implementations\Library\ResolverHelper.cs:line 81
   at Emby.Server.Implementations.Library.LibraryManager.ResolveItem(ItemResolveArgs args, IItemResolver[] resolvers) in D:\a\1\s\Emby.Server.Implementations\Library\LibraryManager.cs:line 480
   at Emby.Server.Implementations.Library.LibraryManager.ResolvePath(FileSystemMetadata fileInfo, IDirectoryService directoryService, IItemResolver[] resolvers, Folder parent, String collectionType, LibraryOptions libraryOptions) in D:\a\1\s\Emby.Server.Implementations\Library\LibraryManager.cs:line 618
   at Emby.Server.Implementations.Library.LibraryManager.ResolvePath(FileSystemMetadata fileInfo, Folder parent) in D:\a\1\s\Emby.Server.Implementations\Library\LibraryManager.cs:line 536
   at Emby.Server.Implementations.Library.LibraryManager.CreateRootFolder() in D:\a\1\s\Emby.Server.Implementations\Library\LibraryManager.cs:line 732
   at Emby.Server.Implementations.Library.LibraryManager.get_RootFolder() in D:\a\1\s\Emby.Server.Implementations\Library\LibraryManager.cs:line 180
   at Emby.Server.Implementations.IO.LibraryMonitor.Start() in D:\a\1\s\Emby.Server.Implementations\IO\LibraryMonitor.cs:line 135
   at Emby.Server.Implementations.IO.LibraryMonitorStartup.RunAsync() in D:\a\1\s\Emby.Server.Implementations\IO\LibraryMonitorStartup.cs:line 26
   at Emby.Server.Implementations.ApplicationHost.StartEntryPoints(IEnumerable`1 entryPoints, Boolean isBeforeStartup)+MoveNext() in D:\a\1\s\Emby.Server.Implementations\ApplicationHost.cs:line 541
   at System.Threading.Tasks.Task.WhenAll(IEnumerable`1 tasks)
   at Emby.Server.Implementations.ApplicationHost.RunStartupTasksAsync(CancellationToken cancellationToken) in D:\a\1\s\Emby.Server.Implementations\ApplicationHost.cs:line 525
   at Jellyfin.Server.Integration.Tests.JellyfinApplicationFactory.CreateServer(IWebHostBuilder builder) in D:\a\1\s\tests\Jellyfin.Server.Integration.Tests\JellyfinApplicationFactory.cs:line 101
   at Microsoft.AspNetCore.Mvc.Testing.WebApplicationFactory`1.EnsureServer()
   at Microsoft.AspNetCore.Mvc.Testing.WebApplicationFactory`1.CreateDefaultClient(DelegatingHandler[] handlers)
   at Microsoft.AspNetCore.Mvc.Testing.WebApplicationFactory`1.CreateDefaultClient(Uri baseAddress, DelegatingHandler[] handlers)
   at Microsoft.AspNetCore.Mvc.Testing.WebApplicationFactory`1.CreateClient(WebApplicationFactoryClientOptions options)
   at Microsoft.AspNetCore.Mvc.Testing.WebApplicationFactory`1.CreateClient()
   at Jellyfin.Server.Integration.Tests.Controllers.ActivityLogControllerTests.ActivityLog_GetEntries_Ok() in D:\a\1\s\tests\Jellyfin.Server.Integration.Tests\Controllers\ActivityLogControllerTests.cs:line 21
--- End of stack trace from previous location ---

```
2021-04-12 00:28:17 +02:00
Joshua M. Boniface
cd0daa7985
Merge pull request #5748 from cvium/playlist-audio-type
Set mediatype to Audio for playlists in a music library
2021-04-11 13:28:49 -04:00
Bond-009
240e67d485
Merge pull request #5747 from cvium/more-convertimage-fixes
Catch IOException and include stack trace when saving images
2021-04-11 00:58:49 +02:00
Bond-009
f4654aaeb1
Merge pull request #5766 from cvium/fix-scheduledtaskworker
Use sync Serialize when writing scheduled tasks to disk
2021-04-11 00:38:44 +02:00
cvium
42bcf171d9 Use sync Serialize when writing scheduled tasks to disk 2021-04-10 23:54:35 +02:00
Bond-009
62117a6c12
Merge pull request #5746 from cvium/dangling-symlinks 2021-04-10 23:18:55 +02:00
Bond-009
9d548c62ba
Merge pull request #5258 from Smith00101010/next-up-specials-fix 2021-04-10 01:38:57 +02:00
Claus Vium
f99237cf9b
Update Emby.Server.Implementations/IO/ManagedFileSystem.cs
Co-authored-by: Cody Robibero <cody@robibe.ro>
2021-04-10 00:16:37 +02:00
cvium
ef527df28f Set mediatype to Audio for playlists in a music library 2021-04-10 00:06:48 +02:00
cvium
f2cba352e5 catch ioexception and include stack trace 2021-04-09 23:30:07 +02:00
Claus Vium
1a92d94e92
Merge pull request #5712 from BaronGreenback/5700 2021-04-09 23:06:40 +02:00
Claus Vium
d532e95410
Merge pull request #5734 from jellyfin/fix-isplayed-itemvalues
move IsPlayed to outerquery
2021-04-09 23:05:43 +02:00
cvium
1a3352003d don't die on dangling symlinks 2021-04-09 23:02:36 +02:00
Claus Vium
a21b2714e7
fetching images should not kill the scanner 2021-04-09 12:03:56 +02:00
Claus Vium
db530e61f5
move IsPlayed to outerquery
IsPlayed is a column in UserDatas and does not belong in the inner query. None of the other UserDatas columns are in the innerquery.
2021-04-09 11:32:19 +02:00
BaronGreenback
b645bb20de
Update Emby.Server.Implementations/Updates/InstallationManager.cs
Co-authored-by: Cody Robibero <cody@robibe.ro>
2021-04-08 14:38:25 +01:00
Bond-009
631df8c560
Merge pull request #5520 from Bond-009/hdhomerun2 2021-04-08 00:27:58 +02:00
BaronGreenback
65f880be32 Keep plugin status after update. 2021-04-06 20:59:47 +01:00
Bond_009
95327b842e Enable NetAnalyzers for more projects 2021-04-06 20:02:06 +02:00
cvium
14d0acf285 add simple auth handling to websocketmanager 2021-04-05 15:12:47 +02:00
Bond-009
959a09bdb0
Merge pull request #5676 from Bond-009/useless 2021-04-03 02:00:03 +02:00
Bond-009
ec0ef1530c
Merge pull request #5602 from Ullmie02/IP-string-IP 2021-04-03 00:32:43 +02:00
Bond-009
a0258618ac
Update Emby.Server.Implementations/Library/Resolvers/TV/SeriesResolver.cs
Co-authored-by: Claus Vium <cvium@users.noreply.github.com>
2021-04-01 21:24:34 +02:00
Bond_009
c533b20496 Remove ManagedFileSystem.IsRootPath
`Path.IsPathRooted` should be used instead
2021-04-01 19:39:00 +02:00
Bond_009
aa76957338 Remove useless code 2021-04-01 19:16:00 +02:00
Bond-009
b49d50e634
Merge pull request #5467 from Ullmie02/nfo-fixes 2021-03-30 15:35:56 +02:00
David
78f7fdeacc Rename methods and optimize allocations 2021-03-26 17:16:29 +01:00
Bond-009
6946e58ca4
Merge pull request #5614 from jellyfin/Bond-009-patch-2 2021-03-25 23:55:54 +01:00
MrTimscampi
5bb7d99b48 Remove DVDs from files exempt from chapter image extraction 2021-03-25 13:16:09 +01:00
Bond-009
6d0b2ed080
Merge pull request #5579 from cocool97/master 2021-03-25 01:45:43 +01:00
Bond-009
16011d96a0
Merge pull request #5321 from Ullmie02/nfo-thumb 2021-03-25 01:10:37 +01:00
Bond-009
066c19a26b
Fix possible null ref exception 2021-03-24 21:06:03 +01:00
David
19e4ef82dd Remove conversion from IPAddress to string to IPAddress 2021-03-23 17:16:10 +01:00
Kenneth SB
4637bbc723 Translated using Weblate (Danish)
Translation: Jellyfin/Jellyfin
Translate-URL: https://translate.jellyfin.org/projects/jellyfin/jellyfin-core/da/
2021-03-22 13:34:36 -04:00
Joshua M. Boniface
890a490776
Merge pull request #5532 from cvium/fix_episode_extras_questionmark 2021-03-21 15:13:56 -04:00
LIAUD
32853ca244 Add 'group-title' channel parsing 2021-03-20 20:15:19 +01:00
andrewthemeow
9857c21717 Translated using Weblate (Lithuanian)
Translation: Jellyfin/Jellyfin
Translate-URL: https://translate.jellyfin.org/projects/jellyfin/jellyfin-core/lt/
2021-03-19 02:50:08 -04:00
Vitorvlv
37aa3e8735 Translated using Weblate (Portuguese (Brazil))
Translation: Jellyfin/Jellyfin
Translate-URL: https://translate.jellyfin.org/projects/jellyfin/jellyfin-core/pt_BR/
2021-03-16 23:19:43 -04:00
David
14cbd22fbe Use Helper Methods for provider url parsing 2021-03-16 21:45:12 +01:00
Alyssa Ross
e14311ca8b Translated using Weblate (Esperanto)
Translation: Jellyfin/Jellyfin
Translate-URL: https://translate.jellyfin.org/projects/jellyfin/jellyfin-core/eo/
2021-03-16 15:19:34 -04:00
cvium
025e351f61 add unit tests 2021-03-15 08:25:20 +01:00
cvium
ab0cff8556 do not resolve episode-like files if they are in extras folders 2021-03-14 19:56:45 +01:00
Patrick Barron
e5380c653b Merge branch 'master' into ef-cleanup
# Conflicts:
#	Jellyfin.Data/Entities/Libraries/MediaFileStream.cs
#	Jellyfin.Data/Jellyfin.Data.csproj
2021-03-14 10:19:35 -04:00
Claus Vium
bd70f56218
Merge pull request #5324 from danieladov/master
Fix duplicated movies when group movies into collections is enabled
2021-03-14 13:37:00 +01:00
Bond_009
a8ed753f6c FxCop -> Net Analyzers (part 2) 2021-03-13 22:33:28 +01:00