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

Issue with Ucommerce after Upgrading to Sitefinity version 14 #61

Open
ViktorSarkozi opened this issue Nov 15, 2021 · 1 comment
Open

Comments

@ViktorSarkozi
Copy link

ViktorSarkozi commented Nov 15, 2021

Branch: ucommerce-integration14
Sitefinity version: 14.0.7721
Ucommerce version: 9.5.1.21265

Exception Message:

System.TypeInitializationException: The type initializer for 'Lucene.Net.Diagnostics.Debugging' threw an exception. ---> System.IO.FileNotFoundException: Could not load file or assembly 'Microsoft.Extensions.Configuration.Abstractions, Version=1.1.2.0, Culture=neutral, PublicKeyToken=adb9793829ddae60' or one of its dependencies. The system cannot find the file specified.
   at Lucene.Net.Util.Properties.GetProperty[T](String key, T defaultValue, Func`2 conversionFunction)
   at Lucene.Net.Util.Properties.GetPropertyAsBoolean(String key, Boolean defaultValue)
   at Lucene.Net.Util.SystemProperties.GetPropertyAsBoolean(String key, Boolean defaultValue)
   at Lucene.Net.Diagnostics.Debugging..cctor()
   --- End of inner exception stack trace ---
   at Lucene.Net.Store.BaseDirectory.SetLockFactory(LockFactory lockFactory)
   at Lucene.Net.Store.FSDirectory.SetLockFactory(LockFactory lockFactory)
   at Lucene.Net.Store.FSDirectory..ctor(DirectoryInfo path, LockFactory lockFactory)
   at Lucene.Net.Store.SimpleFSDirectory..ctor(DirectoryInfo path, LockFactory lockFactory)
   at Lucene.Net.Store.FSDirectory.Open(DirectoryInfo path, LockFactory lockFactory)
   at Lucene.Net.Store.FSDirectory.Open(String path)
   at Ucommerce.Search.Lucene.IndexLocation.get_SuggestionsDirectory()
   at Ucommerce.Search.Lucene.Indexes.IndexWriter.AddSuggestions(IEnumerable`1 batch, CultureInfo culture, IndexLocation location)
   at Ucommerce.Search.Lucene.Indexes.IndexWriter.UpsertBatchInternal(IEnumerable`1 batch, CultureInfo culture, IndexLocation indexLocation)
   at Ucommerce.Search.Lucene.Indexes.IndexWriter.UpsertBatch(IEnumerable`1 batch, CultureInfo culture)
   at Ucommerce.Search.Indexers.BatchIndexer.<>c__DisplayClass10_3.<UpsertInBatchesInternal>b__3(KeyValuePair`2 localizedItems)
   at System.Linq.Enumerable.<SelectManyIterator>d__17`2.MoveNext()
   at System.Linq.Enumerable.<SelectManyIterator>d__17`2.MoveNext()
   at System.Linq.Enumerable.<SelectManyIterator>d__17`2.MoveNext()
   at System.Linq.Enumerable.<SelectManyIterator>d__17`2.MoveNext()
   at System.Collections.Generic.List`1..ctor(IEnumerable`1 collection)
   at System.Linq.Enumerable.ToList[TSource](IEnumerable`1 source)
   at Ucommerce.Search.Indexers.BatchIndexer.UpsertInBatchesInternal(Type modelType, IEnumerable`1 ids)
   at Ucommerce.Search.Indexers.BatchIndexer.UpsertInBatches(Type modelType, IEnumerable`1 ids)
   at Ucommerce.Search.Lucene.Indexers.ScratchIndexer.<>c__DisplayClass20_0.<Index>b__2(IGrouping`2 t)
   at System.Linq.Enumerable.<SelectManyIterator>d__17`2.MoveNext()
   at System.Collections.Generic.List`1..ctor(IEnumerable`1 collection)
   at System.Linq.Enumerable.ToList[TSource](IEnumerable`1 source)
   at Ucommerce.Search.Lucene.Indexers.ScratchIndexer.<>c__DisplayClass20_0.<Index>b__0()
   at Ucommerce.Search.Lucene.SearchProvider.<>c__DisplayClass25_0.<WriteAndToggle>b__0()
   at Ucommerce.Search.Lucene.Toggle.FileBackedToggle.<>c__DisplayClass2_0.<WriteToInactiveAndToggle>b__0()
   at Ucommerce.Search.Lucene.Toggle.SimpleToggle.WriteToInactiveAndToggle(Action action)
   at Ucommerce.Search.Lucene.Toggle.FileBackedToggle.WriteToInactiveAndToggle(Action action)
   at Ucommerce.Search.Lucene.SearchProvider.WriteAndToggle(Func`1 action)
   at Ucommerce.Search.Lucene.Indexers.ScratchIndexer.Index()

Reproduction steps:

  • Scenario 0:

    1. Ucommerce module cannot be installed because (The type initializer for 'Lucene.Net.Diagnostics.Debugging' threw an exception.)
      image
  • Scenario 1:

    1. Go to Ucommerce/Settings/ within Sitefinity CMS dashboard.
    2. Try to Index up Ucommerce DB.
    3. It will result in error (System.TypeInitializationException: The type initializer for 'Lucene.Net.Diagnostics.Debugging' threw an exception)
  • Scenario 2:

    1. Try to add an item to your basket via calling storeapi/basket/add endpoint with correct SKU(for example: 19849) and any quantity.
    2. It will result in error (System.TypeInitializationException: The type initializer for 'Lucene.Net.Diagnostics.Debugging' threw an exception)
@gg3orgiev
Copy link
Contributor

Hi @ViktorSarkozi,

Apologies for the delayed response. We are aware of the issues you mentioned, as the ucommerce-integration14 branch is still in development and is not yet production ready. Currently the official branch to preview the Ucommerce integration with Sitefinity is ucommerce-integration

I will keep you updated. Thank you for the understanding.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants