I have an issue when trying to sign an invoice using .Net 8 SDK on a mac os and i think the same issue may occur on linux also, I can generate a new CSR and proceed to compliance check step, but when signing an invoice, I receive the following exception:
System.IO.FileNotFoundException: Could not find file ‘/Users/mdameer/RiderProjects/ZatcaDemo/EasyConnect/EasyConnect.Web/bin/Debug/net8.0/…....\Data\Rules\schematrons\20210819_ZATCA_E-invoice_Validation_Rules.xsl’.
After investigatig the source code of the SDK, I found that the ConfigurationManager might be the main cause of this issue due to static windows style paths:
This approach isn’t compatible with non-Windows platforms, any idea on how to solve this issue? or if anyone have experience with hosting the .Net 8 SDK on linux server?
Thanks for reaching out, Welcome to our community.
Can I Kindly ask you to answer these questions in order to ensure comprehensive support as usual:
1- What is the SDK version that you are using?
2- Did you check the signing documentation? If you don’t want to use our SDK tools?
3- Did you try to follow the steps mentioned in the Educational Library to ensure a successful onboarding and integrating with ZATCA.
For any further support, do not hesitate to reach out with the SP support via mail: sp_support@zatca.gov.sa.
I found the same problem when I run my application on ubuntu linux, and I agree with you that there is a problem in converting relative path to absolute path in Zatca.eInvoice.SDK library.
I also use relative path in my application to point the location of template files and onboarding info my relativePath works fine on both windows and ubuntu linux.