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

Cannot find folder error when uploading and extracting a SyncPack #124

Closed
jimrowetpa opened this issue Jul 13, 2021 · 7 comments
Closed
Assignees
Labels
bug Something isn't working enhancement New feature or request release/8.10.3 Patch release

Comments

@jimrowetpa
Copy link

Describe the bug
when uploading a SyncPack it passes the validate step but freezes on the Items step. The following error is reported in the log. I have checked and the folder specified is present and has got folders and files in it - from the SyncPack.

Might be related to the fix for #117 released in v8.10.1 ?

System.IO.DirectoryNotFoundException: Cannot find folder [INSTALL-FOLDER]\App_Data\TEMP\uSync\exports\2f46d294-e353-4c69-85c0-ab6741e84230\r\n at uSync.Expansions.Core.Services.SyncPackService.ReportChanges(SyncPackRequest request)\r\n at uSync.Exporter.Services.SyncExporterService.Report(Guid id, SyncPackRequest request)\r\n at uSync.Exporter.Controllers.uSyncNuExporterApiController.ProcessExporterSteps(IList1 steps, ExporterRequest request)\r\n at lambda_method(Closure , Object , Object[] )\r\n at System.Web.Http.Controllers.ReflectedHttpActionDescriptor.ActionExecutor.<>c__DisplayClass6_2.<GetExecutor>b__2(Object instance, Object[] methodParameters)\r\n at System.Web.Http.Controllers.ReflectedHttpActionDescriptor.ExecuteAsync(HttpControllerContext controllerContext, IDictionary2 arguments, CancellationToken cancellationToken)\r\n--- End of stack trace from previous location where exception was thrown ---\r\n at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n at System.Web.Http.Controllers.ApiControllerActionInvoker.d__1.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n at System.Web.Http.Filters.ActionFilterAttribute.d__6.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n at System.Web.Http.Filters.ActionFilterAttribute.d__6.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n at System.Web.Http.Filters.ActionFilterAttribute.d__5.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n at System.Web.Http.Filters.ActionFilterAttribute.d__6.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n at System.Web.Http.Filters.ActionFilterAttribute.d__6.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n at System.Web.Http.Filters.ActionFilterAttribute.d__5.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n at System.Web.Http.Filters.ActionFilterAttribute.d__6.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n at System.Web.Http.Filters.ActionFilterAttribute.d__6.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n at System.Web.Http.Filters.ActionFilterAttribute.d__5.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n at System.Web.Http.Filters.ActionFilterAttribute.d__6.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n at System.Web.Http.Filters.ActionFilterAttribute.d__6.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n at System.Web.Http.Filters.ActionFilterAttribute.d__5.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n at System.Web.Http.Controllers.ActionFilterResult.d__5.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n at System.Web.Http.Filters.AuthorizationFilterAttribute.d__3.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n at System.Web.Http.Filters.AuthorizationFilterAttribute.d__3.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n at System.Web.Http.Filters.AuthorizationFilterAttribute.d__3.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n at System.Web.Http.Filters.AuthorizationFilterAttribute.d__3.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n at System.Web.Http.Controllers.ExceptionFilterResult.d__6.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n at System.Web.Http.Controllers.ExceptionFilterResult.d__6.MoveNext()\r\n--- End of stack trace from previous location where exception was thrown ---\r\n at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()\r\n at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)\r\n at System.Web.Http.Dispatcher.HttpControllerDispatcher.d__15.MoveNext()

Version (please complete the following information):

  • Umbraco Version: v8.14.0
  • uSync Version: v8.9.5
  • uSync.Complete Version: v8.10.2 (also checked on v8.10.1)

To Reproduce
Steps to reproduce the behavior:

  1. Create a SyncPack
  2. Navigate to settings/uSync8/dashboard/exporter
  3. Click import sync pack
  4. Upload file
  5. Popup window appears, validate is ticked. Items is green. Nothing further happens.

Expected behavior
SyncPack should be imported.

@KevinJump KevinJump self-assigned this Jul 13, 2021
@KevinJump
Copy link
Member

Hi - if possible can you send me a copy of the sync pack you are uploading (kevin@jumoo.co.uk). it might be something we are not picking up.

also if you can confirm you are not on a load balanced setup (on load balanced setup the servers can switch between requests - so the folder goes 'missing') - if you are on a load balanced setup usync should tell you on the main dashboard

@jimrowetpa
Copy link
Author

Hi Kevin, thanks for looking at this.

I've sent the sync pack over. We're not load balanced, it is two local copies.

The folder is being created where I would expect it (at the location in the stack trace). Inside that folder there is a uSync folder, and that then contains Content and Dictionary folders.

@KevinJump
Copy link
Member

KevinJump commented Jul 14, 2021

Hi,

I think this is because you might have the content and dictionary handlers disabled in the uSync8.config file (and we should show a way better error!)

you might understandably have turned content, media etc off on the default handlers if you dont want them syncing, but by default exporter uses the default handlers to to imports, and the code in this case doesn't find the handlers so isn't looking for the right folders so it complains (badly).

fix:

you can tell exporter to use its own handller setup so you don't have to turn content back on in the default setup.

in the uSync8.config file

add a new Handlers group to the HandlerSets setup

<Handlers Name="exporter">
    <Handler Alias="dataTypeHandler" Enabled="true" />
    <Handler Alias="languageHandler" Enabled="true" />
    <Handler Alias="macroHandler" Enabled="true" />
    <Handler Alias="mediaTypeHandler" Enabled="true" />
    <Handler Alias="memberTypeHandler" Enabled="false" />
    <Handler Alias="templateHandler" Enabled="true" />
    <Handler Alias="contentTypeHandler" Enabled="true" />
    <Handler Alias="contentHandler" Enabled="true" />
    <Handler Alias="contentTemplateHandler" Enabled="true" />
    <Handler Alias="dictionaryHandler" Enabled="true" />
    <Handler Alias="domainHandler" Enabled="true" />
    <Handler Alias="mediaHandler" Enabled="true" />
    <Handler Alias="memberGroupHandler" Enabled="true" />
    <Handler Alias="memberHandler" Enabled="true" />
    <Handler Alias="publicAccessHandler" Enabled="true" />
    <Handler Alias="userGroupHandler" Enabled="true" />
    <Handler Alias="userHandler" Enabled="true" />
    <Handler Alias="mediaFileHandler" Enabled="true" />
</Handlers>

Add the exporter settings to the default 'backoffice` node

<Exporter>
    <HandlerSet>exporter</HandlerSet>
</Exporter>

you will then need to restart the site (settings are not reloaded on a running site)

hopefully that will fix it , and we will look at making this error more intuitive. (in v9 the exporter handler thing is a default - as it would be breaking change to add it to v8)

@jimrowetpa
Copy link
Author

jimrowetpa commented Jul 14, 2021 via email

@KevinJump
Copy link
Member

hi, just leave this issue open, we will use it to track the change in the next release.

@jimrowetpa
Copy link
Author

jimrowetpa commented Jul 14, 2021 via email

@KevinJump KevinJump added enhancement New feature or request release/8.10.3 Patch release bug Something isn't working labels Jul 14, 2021
@KevinJump
Copy link
Member

update to errors in 8.10.3 release.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working enhancement New feature or request release/8.10.3 Patch release
Projects
None yet
Development

No branches or pull requests

2 participants