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

Sparkasse compatibility #29

Open
saddy001 opened this issue Nov 22, 2020 · 3 comments
Open

Sparkasse compatibility #29

saddy001 opened this issue Nov 22, 2020 · 3 comments

Comments

@saddy001
Copy link

I had to do the following modifications to make it compatible with Sparkasse:

xml = re.sub(r'<PmtInfId>.+</PmtInfId>', '<PmtInfId>NOTPROVIDED</PmtInfId>', xml)
xml = re.sub(r'.+<PmtTpInf>[\S\n ]+?</PmtTpInf>\n', '', xml)
xml = re.sub(r'.+<CdtrAgt>[\S\n ]+?</CdtrAgt>\n', '', xml)
xml = re.sub(r'.+<BtchBookg>[\S\n ]+?</BtchBookg>\n', '', xml)

Maybe these could be options for python-sepaxml.

@raphaelm
Copy link
Owner

raphaelm commented Jan 8, 2021

Sorry for the late reply.

We're not going to add some arbitrary regexes, but if there's a way we can fix this structurally, we are happy to. Can you tell me which PAIN version you used and whether you tried with debits or transfers?

@saddy001
Copy link
Author

saddy001 commented Jan 9, 2021

We're not going to add some arbitrary regexes

Sure, that was also my request.

but if there's a way we can fix this structurally

Here are the changes from above:

  1. Replace PmtInfId data with "NOTPROVIDED"
  2. Remove PmtTpInf tag
  3. Remove CdtrAgt tag
  4. Remove BtchBookg tag

Can you tell me which PAIN version you used and whether you tried with debits or transfers?

pain.001.001.03

@guettli
Copy link
Contributor

guettli commented Apr 3, 2021

I had to do the following modifications to make it compatible with Sparkasse:

xml = re.sub(r'<PmtInfId>.+</PmtInfId>', '<PmtInfId>NOTPROVIDED</PmtInfId>', xml)
xml = re.sub(r'.+<PmtTpInf>[\S\n ]+?</PmtTpInf>\n', '', xml)
xml = re.sub(r'.+<CdtrAgt>[\S\n ]+?</CdtrAgt>\n', '', xml)
xml = re.sub(r'.+<BtchBookg>[\S\n ]+?</BtchBookg>\n', '', xml)

Maybe these could be options for python-sepaxml.

The regex [\S\n ] looks broken. \S means non-space. I guess you mean \s

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

3 participants