Bug in MRP-Buy generation

There appears to be a bug when trying to generate an MRP-Buy list on line 1021 in /Schema/Result/Part.pm. The string concatenation looks like it’s being interpreted as arithmetic addition and the $location variable is not wrapped in quotes. Should be changed to something like $q = "$q and location = ‘$location’ ".

Throwing a 500 error, btw.

@aioannidis

Thanks for reaching out about this issue. Can you give us access to your environment and send over a link or the end of the link you are looking at?

Thanks,

Cetec ERP Support

I have re-enabled VPN access to the server (please let me know when you’re done so I can disable). You will have to select a location other than “All” to trigger the bug (due to that if statement on line 1020). End of the link is:

/pquote/assisted_purchasing?show_more=1&bom_only=none

@aioannidis

I am unfortunately still not able to get into your environment. Is there something else you can do there? I am not able to access it.

Thanks,

Cetec ERP Support

Not sure what else I can do. The VPN shows as up and it has an IP address. How are you trying to access it?

Please note that we now force https via our internal certificate authority. So since you don’t have our CA cert, you may just have to accept the https connection blindly. I’ve found that works best using Firefox.

@aioannidis

Thank you for that info. We had it that it needed to be http in our notes so we were able to get in.

I will continue looking into this.

Thanks,

Cetec ERP Support

@aioannidis

This was something that has been fixed already. It is in the latest fix. I’m not sure when you normally get updates but the next update you should have this fixed.

Thanks,

Cetec ERP Support

Looks like the update script runs Tuesdays and Fridays, so I assume it should have been fixed today? Cron shows that it runs at 1:30 AM on Tuesdays and Fridays.

@aioannidis

Check back tomorrow and if this issue still hasn’t been resolved please let us know. I would have assumed it would have been fixed today but just to be sure it doesn’t happen later today.

Thanks,

Cetec ERP Support

Hi @aioannidis,
We wanted to check in and see if this issue had been resolved for you (are you still getting that error?).

Additionally, we wanted to let you know that the forums may not be the best place to discuss specific parts of Cetec’s code, or processes that are scheduled to run on your resident server.

If you’d like to talk to one of our engineers we can definitely set you up with some dedicated billable time to do that, otherwise we would recommend that you frame future posts around the behavior as it shows it the system. For example, “I get an error on the __________ page when I __________. The error says ________” is definitely something we can deal with here.

Please do let us know if you’re still seeing the same error that you mentioned previously here.

Thanks!

We are still seeing the same error.

@aioannidis At what point are you seeing the error? Is it as soon as the page loads after you click the link in from the navigation bar? Is it after you click submit, and if so can you share a screenshot of the filters you’re using (guessing based on the original comment that you’re at least filtering by location?)? Also can you confirm if this is happening for every user or just some users, when trying to run the report using the same options?

Thanks!

Filters being applied are:

  1. Source Type = ROP
  2. Location = Anything other than “All”
  3. Action Type = Need To Buy Only

500 error occurs after clicking “Submit” for all users. Error only occurs when setting location to anything other than “All” - all other filter selections don’t appear to matter in reproducing.

Excellent, thank you for the thorough testing there.
We’re going to review this issue, and possibly escalate to our engineering team. We will follow up with you about it once we’ve got more information.

@aioannidis We weren’t able to reproduce this issue in any of our testing environments, which confirmed for us that the issue was limited to your server.
Our engineers were able to go in and look, and confirmed that the root issue had already been fixed in a patch about a week ago.
It’s unclear why the automated deploy process didn’t run as expected on your server since then, however they were able to go in and deploy that patch manually, and you should be all set here without that error.
Thanks for bringing this to our attention, and please let us know if you have any other problems in the future.
Cetec