{"action":"created","issue":{"url":"https://api.github.com/repos/kamsar/Unicorn/issues/90","labels_url":"https://api.github.com/repos/kamsar/Unicorn/issues/90/labels{/name}","comments_url":"https://api.github.com/repos/kamsar/Unicorn/issues/90/comments","events_url":"https://api.github.com/repos/kamsar/Unicorn/issues/90/events","html_url":"https://github.com/kamsar/Unicorn/issues/90","id":119991348,"number":90,"title":"Error when field type Layout has a null value","user":{"login":"drachele","id":825135,"avatar_url":"https://avatars.githubusercontent.com/u/825135?v=3","gravatar_id":"","url":"https://api.github.com/users/drachele","html_url":"https://github.com/drachele","followers_url":"https://api.github.com/users/drachele/followers","following_url":"https://api.github.com/users/drachele/following{/other_user}","gists_url":"https://api.github.com/users/drachele/gists{/gist_id}","starred_url":"https://api.github.com/users/drachele/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/drachele/subscriptions","organizations_url":"https://api.github.com/users/drachele/orgs","repos_url":"https://api.github.com/users/drachele/repos","events_url":"https://api.github.com/users/drachele/events{/privacy}","received_events_url":"https://api.github.com/users/drachele/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/kamsar/Unicorn/labels/bug","name":"bug","color":"fc2929"},{"url":"https://api.github.com/repos/kamsar/Unicorn/labels/fix-pending","name":"fix-pending","color":"006b75"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":6,"created_at":"2015-12-02T17:14:12Z","updated_at":"2015-12-08T11:33:38Z","closed_at":null,"body":"Hi,\r\n\r\nWhen trying to sync our content, we are getting this error:\r\n\r\n    XmlException: Root element is missing.\r\n\r\nWe've tracked it down to fields in the .yml file of type ```Layout``` that have a null value, like so:\r\n\r\n    - ID: 04bf00db-f5fb-41f7-8ab7-22408372a981\r\n      # __Final Renderings\r\n      Type: Layout\r\n      Value:\r\n\r\nIf we remove this field from the .yml file, the sync runs without error.\r\n\r\nIs there is a fix or workaround for this?\r\n\r\nThanks."},"comment":{"url":"https://api.github.com/repos/kamsar/Unicorn/issues/comments/162856713","html_url":"https://github.com/kamsar/Unicorn/issues/90#issuecomment-162856713","issue_url":"https://api.github.com/repos/kamsar/Unicorn/issues/90","id":162856713,"user":{"login":"drachele","id":825135,"avatar_url":"https://avatars.githubusercontent.com/u/825135?v=3","gravatar_id":"","url":"https://api.github.com/users/drachele","html_url":"https://github.com/drachele","followers_url":"https://api.github.com/users/drachele/followers","following_url":"https://api.github.com/users/drachele/following{/other_user}","gists_url":"https://api.github.com/users/drachele/gists{/gist_id}","starred_url":"https://api.github.com/users/drachele/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/drachele/subscriptions","organizations_url":"https://api.github.com/users/drachele/orgs","repos_url":"https://api.github.com/users/drachele/repos","events_url":"https://api.github.com/users/drachele/events{/privacy}","received_events_url":"https://api.github.com/users/drachele/received_events","type":"User","site_admin":false},"created_at":"2015-12-08T11:33:38Z","updated_at":"2015-12-08T11:33:38Z","body":"Hi @kamsar,\r\n\r\nThat doesn't seem to have worked. Am now getting two errors for each item where the __Final Renderings field value is empty:\r\n\r\nINNER EXCEPTION\r\n<item path here> (5a9cadde-838a-4b98-8e66-85dcb21ea3d8) (Rainbow.Storage.Sc.Deserialization.DeserializationException)\r\nNo stack trace available.\r\nINNER EXCEPTION\r\nFailed to paste item: <item path here> (Rainbow.Storage.Sc.Deserialization.DeserializationException)\r\nat Rainbow.Storage.Sc.Deserialization.DefaultDeserializer.Deserialize(IItemData serializedItemData)\r\n   at Unicorn.Evaluators.NewItemOnlyEvaluator.EvaluateNewSerializedItem(IItemData newItemData)\r\n   at Unicorn.Loader.SerializationLoader.DoLoadItem(IItemData serializedItemData, IConsistencyChecker consistencyChecker)\r\n   at Unicorn.Loader.DeserializeFailureRetryer.RetryAll(ISourceDataStore sourceDataStore, Action`1 retrySingleItemAction, Action`1 retryTreeAction)\r\nINNER EXCEPTION\r\nObject reference not set to an instance of an object. (System.NullReferenceException)\r\nat Rainbow.Storage.Sc.Deserialization.DefaultDeserializer.PasteField(Item item, IItemFieldValue field, Boolean creatingNewItem)\r\n   at Rainbow.Storage.Sc.Deserialization.DefaultDeserializer.PasteVersion(Item item, IItemVersion serializedVersion, Boolean creatingNewItem, List`1 softErrors)\r\n   at Rainbow.Storage.Sc.Deserialization.DefaultDeserializer.PasteVersions(IItemData serializedItemData, Item targetItem, Boolean newItemWasCreated, List`1 softErrors)\r\n   at Rainbow.Storage.Sc.Deserialization.DefaultDeserializer.Deserialize(IItemData serializedItemData)"}}