kgiszewski / Machina

6 stars 1 forks source link

Crashes on larger sites #2

Open nickh364 opened 5 years ago

nickh364 commented 5 years ago

I am getting the error below. This has worked great on our smaller sites but I am getting this error on one of our larger sites. Do you know of any way to get around this?

umbraco> machina-mmp -p:1 PERSISTING Migrating Media Picker properties to UDI... Error running the current deliverable 'machina-mmp' System.ArgumentOutOfRangeException: The console buffer size must not be less than the current size and position of the console window, nor greater than or equal to Int16.MaxValue. Parameter name: height Actual value was 80270. at System.Console.SetBufferSize(Int32 width, Int32 height) at Machina.Migrations.MigrationHelper.SetBufferSize(Int32 contentLength) at Machina.Migrations.MediaPickerMigration.d4.MoveNext() --- End of stack trace from previous location where exception was thrown --- at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at Chauffeur.Host.UmbracoHost.d14.MoveNext()

nickh364 commented 5 years ago

I also tried to limit it by doc type with the command below but that only takes it down to 73115.

machina-mmp -p:1 -f:podcastEpisode

kgiszewski commented 5 years ago

System.ArgumentOutOfRangeException: The console buffer size must not be less than the current size and position of the console window, nor greater than or equal to Int16.MaxValue.

Looks like some fiddling with the output may fix this. Quite surprised anyone is using this of course ;)

teajaysee commented 5 years ago

Hi, I am getting the same issue .. could you explain what "some fiddling with the output may fix this" means if pos? I'm using the program to prepare my v7 site to upgrade to v8. been upgrading continuously for 5 years so quite a few obsolete property editors! thanks

kgiszewski commented 5 years ago

I'm thinking if you comment out some of the Console.Write methods, it'll not go to the console and not overflow it.

kgiszewski commented 5 years ago

Might look at adjusting this too: https://github.com/kgiszewski/Machina/blob/e28d39c97af0064c4cd9808e5bd6752f012c0690/src/Machina/Migrations/MigrationHelper.cs#L42

nickh364 commented 5 years ago

Thanks for the reply. I will try that when I get a chance. This has been really helpful moving all our sites to Umbraco 8.

CimplexAB commented 4 years ago

@nickh364 @kgiszewski Did you solve this Nick? I'm having the same issue with the buffer size. My value is 190965. I tried to comment out some of the Console.Write methods but it didn't help

kgiszewski commented 4 years ago

@CimplexAB You might just try setting the buffer to Int.Max32:

https://github.com/kgiszewski/Machina/blob/e28d39c97af0064c4cd9808e5bd6752f012c0690/src/Machina/Migrations/MigrationHelper.cs#L42

CimplexAB commented 4 years ago

@kgiszewski Awesome, thanks for the reply. I tried but it didn't seem to work, but i just commented it out, compiled then it worked.