Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Dibs 202 posts 991 karma points
    Nov 11, 2022 @ 18:22
    Dibs
    0

    Import Fail: Could not convert string to boolean: 0 Path 'Default', line 2, pos....

    Hi uSync team

    I am using Umbraco v8.17.2 with uSync v8.9.1.0 After an import, i get the error

    Import Fail: Could not convert string to boolean: 0 Path 'Default', line 2, pos....

    on all checkbox DataTypes.

    This is after i download my source code and build and go through fresh install to a local .sdf database

    Any assistance would be great to resolve this issue

    Thanks Dibs

  • Kevin Jump 2310 posts 14695 karma points MVP 7x c-trib
    Nov 11, 2022 @ 18:32
    Kevin Jump
    0

    Hi,

    I can't find any specific fixes for that exact thing, but you should upgrade uSync to the highest version on v8 (v8.11.2) and see if that fixes it.

    even if it doesn't it might give a better error message and give a pointer as to where we can look.

  • Dibs 202 posts 991 karma points
    Nov 14, 2022 @ 09:15
    Dibs
    0

    Hi Kevin

    Thanks for reply back I have update uSync to v8.11.2, but still the same error after import : (

    Dibs

  • Dibs 202 posts 991 karma points
    Nov 14, 2022 @ 14:45
    Dibs
    0

    Hi Kevin

    After enabling debug logging the following warning level entries are in the logs:-

    @MessageTemplate : No Handler with {alias} has been loaded alias : contentHandler SourceContext : uSync8.BackOfficeSyncHandlers.SyncHandlerFactory

    various entries for the above with alias replaced with contentTemplateHandler, dictionaryHandler, domainHandler, mediaHandler

    Does the above help in anyway to resolve my issue ?

    Also, looking back i had upgraded from uSync v8.3.0 to v8.9.1

    Dibs

  • Kevin Jump 2310 posts 14695 karma points MVP 7x c-trib
    Nov 14, 2022 @ 17:30
    Kevin Jump
    0

    Hi Dibs

    Couple of questions:

    • Where are you seeing this error?
      • is it during the import
      • when you go to the checkbox list in settings ?
      • or is it when you look at it in content?

    I have done a few checks locally and I can't reproduce. 😔

    What does the checkbox file you are importing look like ? e.g. The file in the datatypes folder ?

  • Dibs 202 posts 991 karma points
    Nov 14, 2022 @ 17:48
    Dibs
    0

    Hi Kevin

    Further troubleshooting steps included reverting to original uSync version 8.3.0. this reulted in usync not displayed in backoffice.

    Upgrade to latest veriosn 8.11.2, resulted in no change.

    So, my next step was to look at the config files for a checkbox type and compare them with latest version of a checkbox config file.

    I found that my files are :-

    <?xml version="1.0" encoding="utf-8"?>
    <DataType Key="92897bc6-a5f3-4ffe-ae27-f2e7e33dda49" Alias="True/false" Level="1">
      <Info>
        <Name>True/false</Name>
        <EditorAlias>Umbraco.TrueFalse</EditorAlias>
        <DatabaseType>Integer</DatabaseType>
      </Info>
      <Config><![CDATA[{
      "Default": null,
      "Label": null
    }]]></Config>
    </DataType>
    

    Latest files are

    <?xml version="1.0" encoding="utf-8"?>
    <DataType Key="c11dee08-55a1-48eb-981f-63f8f0460c16" Alias="Umbraco Properties - Umbraco Navi Hide - Checkbox" Level="1">
      <Info>
        <Name>Umbraco Properties - Umbraco Navi Hide - Checkbox</Name>
        <EditorAlias>Umbraco.TrueFalse</EditorAlias>
        <DatabaseType>Integer</DatabaseType>
      </Info>
      <Config><![CDATA[{
      "Default": false,
      "ShowLabels": false,
      "LabelOn": null,
      "LabelOff": null
    }]]></Config>
    </DataType>
    

    I edited the files replacing the original two key/value pair with four key/pair values within the <![CDATA[{ }]]>

    When i ran import it worked. This leads me to think it was an its an Umbraco upgrade that has changed the checkbox property editor from checkbox to toggle, as usync config files append toggle in the filename instead of checkbox.

    Is the above editing to uSync dataType.config files ok to do ?

    Hopefully above makes sense and enlighten more information on my issue

    Dibs

  • Kevin Jump 2310 posts 14695 karma points MVP 7x c-trib
    Nov 14, 2022 @ 18:50
    Kevin Jump
    0

    Yeah

    it looks like that was a breaking change in v8.8.0. #8477

    A proper hard one two, not sure if there is a way for us to maintain full backwards compatibility (e.g., have uSync 8.11.2 work on 8.0.0 which it currently does) and fix this.

    editing the files is fine and a possible fix, we might introduce a health check to move from a to b as that won't break existing code, but it's a bit of a pain 😟

  • Kevin Jump 2310 posts 14695 karma points MVP 7x c-trib
    Nov 14, 2022 @ 20:21
    Kevin Jump
    100

    Reflection to the rescue. https://github.com/KevinJump/uSync/issues/436

    there is a nightly build with this fix in if you need it (although i suspect you have fixed it by editing the files?)

    https://dev.azure.com/jumoo/Public/_artifacts/feed/nightly/NuGet/uSync/overview/8.11.3-build.20221114.8

    Kevin

  • Dibs 202 posts 991 karma points
    Nov 15, 2022 @ 10:01
    Dibs
    0

    Cheers Kevin

    For now i'll keep ma source code to make use of v8.9.1.0 and edit the files, to get the client requirements out.

    Then look at upgrading uSync to 8.11.3 : )

    Thanks for assistance Dibs

Please Sign in or register to post replies

Write your reply to:

Draft