Workperiod not closing

Hello everybody

Everything was working fine until last night when i try to close the workperiod m getting this error:

Workperiod is still open…

Probably a transaction document is wrong or something is missing. Can you show the error log?

From where i can get the log?

Documents\SambaPOS5\log.txt

Scroll to bottom of it and give us the last few logs for that day.

[Exception Info 1]

Top-level Exception
Type: System.NullReferenceException
Message: Object reference not set to an instance of an object.
Source: Samba.Services
Stack Trace: at Samba.Services.Implementations.CacheService.<>c__DisplayClass217_0.b__0(Recipe x) in C:\Users\vehbi\Source\Repos\sambapos-v5-pro\Samba.Services\Implementations\CacheService.cs:line 835
at System.Linq.Enumerable.Single[TSource](IEnumerable1 source, Func2 predicate)
at Samba.Services.Implementations.CacheService.GetRecipe(String portionName, Int32 menuItemId) in C:\Users\vehbi\Source\Repos\sambapos-v5-pro\Samba.Services\Implementations\CacheService.cs:line 835
at Samba.Services.Implementations.InventoryModule.ConsumptionBuilder.UpdateConsumption(PeriodicConsumption pc, Int32 warehouseId, IEnumerable1 tickets, IList1 recipes) in C:\Users\vehbi\Source\Repos\sambapos-v5-pro\Samba.Services\Implementations\InventoryModule\ConsumptionBuilder.cs:line 136
at Samba.Services.Implementations.InventoryModule.ConsumptionBuilder.BuildPeriodicConsumption() in C:\Users\vehbi\Source\Repos\sambapos-v5-pro\Samba.Services\Implementations\InventoryModule\ConsumptionBuilder.cs:line 68
at Samba.Services.Implementations.InventoryModule.InventoryService.DoWorkPeriodEnd(WorkPeriod currentWorkPeriod, WorkPeriod previousWorkPeriod) in C:\Users\vehbi\Source\Repos\sambapos-v5-pro\Samba.Services\Implementations\InventoryModule\InventoryService.cs:line 191
at Samba.Services.Implementations.InventoryModule.InventoryWorkperiodProcessor.ProcessWorkPeriodEnd(WorkPeriod currentWorkPeriod, WorkPeriod previousWorkperiod) in C:\Users\vehbi\Source\Repos\sambapos-v5-pro\Samba.Services\Implementations\InventoryModule\InventoryWorkperiodProcessor.cs:line 25
at Samba.Presentation.Services.Implementations.WorkPeriodModule.WorkperiodClient.StopWorkPeriod(String description)

looks like you have a recipe missing or you deleted something the recipe uses but it was consumed in that work period.

That is not all of the error. Can you paste the rest of it?

[Exception Info 1]

Top-level Exception
Type: System.NullReferenceException
Message: Object reference not set to an instance of an object.
Source: Samba.Services
Stack Trace: at Samba.Services.Implementations.CacheService.<>c__DisplayClass217_0.b__0(Recipe x) in C:\Users\vehbi\Source\Repos\sambapos-v5-pro\Samba.Services\Implementations\CacheService.cs:line 835
at System.Linq.Enumerable.Single[TSource](IEnumerable1 source, Func2 predicate)
at Samba.Services.Implementations.CacheService.GetRecipe(String portionName, Int32 menuItemId) in C:\Users\vehbi\Source\Repos\sambapos-v5-pro\Samba.Services\Implementations\CacheService.cs:line 835
at Samba.Services.Implementations.InventoryModule.ConsumptionBuilder.UpdateConsumption(PeriodicConsumption pc, Int32 warehouseId, IEnumerable1 tickets, IList1 recipes) in C:\Users\vehbi\Source\Repos\sambapos-v5-pro\Samba.Services\Implementations\InventoryModule\ConsumptionBuilder.cs:line 136
at Samba.Services.Implementations.InventoryModule.ConsumptionBuilder.BuildPeriodicConsumption() in C:\Users\vehbi\Source\Repos\sambapos-v5-pro\Samba.Services\Implementations\InventoryModule\ConsumptionBuilder.cs:line 68
at Samba.Services.Implementations.InventoryModule.InventoryService.DoWorkPeriodEnd(WorkPeriod currentWorkPeriod, WorkPeriod previousWorkPeriod) in C:\Users\vehbi\Source\Repos\sambapos-v5-pro\Samba.Services\Implementations\InventoryModule\InventoryService.cs:line 191
at Samba.Services.Implementations.InventoryModule.InventoryWorkperiodProcessor.ProcessWorkPeriodEnd(WorkPeriod currentWorkPeriod, WorkPeriod previousWorkperiod) in C:\Users\vehbi\Source\Repos\sambapos-v5-pro\Samba.Services\Implementations\InventoryModule\InventoryWorkperiodProcessor.cs:line 25
at Samba.Presentation.Services.Implementations.WorkPeriodModule.WorkperiodClient.StopWorkPeriod(String description)


[Assembly Info]

mscorlib, Version=4.0.0.0
PresentationFramework, Version=4.0.0.0
PresentationCore, Version=4.0.0.0
System, Version=4.0.0.0
WindowsBase, Version=4.0.0.0
Samba.Services, Version=1.0.0.0
System.ComponentModel.Composition, Version=4.0.0.0
System.Configuration, Version=4.0.0.0
System.Xaml, Version=4.0.0.0
Microsoft.Practices.Prism.MefExtensions, Version=4.0.0.0
Samba.Presentation.Services, Version=1.0.0.0
Samba.Presentation.Common, Version=1.0.0.0
Samba.Domain, Version=1.0.0.0
Microsoft.Practices.Prism, Version=4.0.0.0
System.Core, Version=4.0.0.0
Samba.Infrastructure, Version=1.0.0.0
DevExpress.Data.v16.2, Version=16.2.6.0
DevExpress.Xpf.Core.v16.2, Version=16.2.6.0
Microsoft.Practices.ServiceLocation, Version=1.0.0.0
Samba.Localization, Version=1.0.0.0
Samba.Persistance, Version=1.0.0.0
FastButton, Version=1.0.0.0


[System Info]

Operating System
-Microsoft Windows 10 Pro
–CodeSet = 1252
–CSDVersion =
–CurrentTimeZone = -240
–FreePhysicalMemory = 1602156
–OSArchitecture = 64-bit
–OSLanguage = 1033
–ServicePackMajorVersion = 0
–ServicePackMinorVersion = 0
–Version = 10.0.17134

Machine
-SERVER
–Manufacturer = MSI
–Model = MS-7850
–TotalPhysicalMemory = 4158509056
–UserName = SERVER\Server


######################### E N D #########################

But how can i exactly find that recipe because it have thousands of it.

It could be something to do with a Portion name as well.

Did you delete any Portion names? Or rename any?

But how can we find out? Which one have the problem?

Look through tickets for that day see if you can spot it

It have a girl who do data entry but it would be waste of time to ask she.

How can i find it here?

Any suggestions to find the problem?

But I think it is a waste of everyone else’s time on here if you don’t know what was done and expect we are mind readers.

You don’t know what happened, you don’t want to find out, you want us to guess… just restore yesterday’s backup and accept that someone messed something up, learn from the mistake.

What’s wrong with people here??
I am a reseller for samba and they are my customer, so i dont know what they did. Now about the girl, she dont know about samba at all and what did you think that as a reseller i didnt tried to investigate them for the problem if they did any???
I didnt use any kind of words that somebody solve my problem and read anybody minds. But i ask i there any way to suspect the problem where exactly it is because it have too much items.

No there is not an easy way to find where it is. Ask them what they changed yesterday. And warn them not to do it again. I’d also charge them to fix it.

To be fair @Faisal based on your previous discussions on the forum that would have been most peoples conclusions.

The error in log is not specific enough for anyone to tell you an exect product/inventory recipe etc. Sugestions are to where to start are being offered…

Here is the issue, you have a history on the forum for asking questions and not wanting to do any investigation yourself, expecting everyone here to help you. You are a reseller, as a reseller, you should have a basic knowledge of how to deal with issues.

I am a reseller, JTRTech is a reseller, kendash is a reseller - I don’t have these issues with my customers and I’d take a guess the other 2 I mentioned don’t either. I provide training to my clients, I explain how everything works, I explain they should always make a backup before they mess around with things. If a client is paying me for support, if they asked such question first thing is “what did you do?” “I don’t know” is not an acceptable response, I have faith on the SambaPOS software that if something does not work it is very likely the client did something (and I have enough knowledge to know when something might be a bug and report it). I also will not spend lots of time trying to work out what they did - if it isn’t obvious and they don’t know what they did, sorry this is what a backup is for, accept your losses and restore from the backup, be more careful next time… :wink:

Please don’t take offense from my response, I am merely pointing out fact, if you want to be a good reseller you really need to spend time and learn more about SambaPOS. You have to teach your clients good practises and also protect yourself from blame.