|
From: Marc T. <mar...@gm...> - 2008-06-20 01:25:44
|
Hi all - I hope this is not a horribly stupid question... I'm setting up my configspec thusly: > tmpStr = """[Current] > npiXMLFile = string(default="npiMap.XML") > InHist = string_list(default=None) > OutHist = string_list(default=None) > Submitter = string(default=None) > Carrier = string(default=None) > MainSize = tuple() > MainPos = tuple() > SummarySize = tuple() > SummaryPos = tuple() > ConfirmSuccess = boolean(default=True) > CvtCarrier = boolean(default=False) > KeepLicense = boolean(default=False) > KeepInsID = boolean(default=False) > KeepTaxID = boolean(default=True) > KeepUxIN = boolean(default=True) > KeepFacID = boolean(default=False) > UseSecID = boolean(default=False) > FixSSN = boolean(default=True) > DNtoDQ = boolean(default=False) > [JobProfiles] > [[__many__]] > Submitter = string(default=" ") > Carrier = string(default=" ") > CvtCarrier = boolean(default=False) > KeepLicense = boolean(default=False) > KeepInsID = boolean(default=False) > KeepTaxID = boolean(default=True) > KeepUxIN = boolean(default=True) > KeepFacID = boolean(default=False) > UseSecID = boolean(default=False) > FixSSN = boolean(default=True) > DNtoDQ = boolean(default=False) > InFile = string(default="") > OutFile = string(default="") > """ > cfgSpec = StringIO.StringIO(tmpStr) > cfgFile = ConfigObj(cfgFileName, > configspec=cfgSpec, raise_errors=True, write_empty_values = > True, > create_empty=True, indent_type=' ', list_values = True) > vtor = Validator() > and validating it thusly: > test = cfgFile.validate(vtor, copy=True) > cfgFile.write() > My actual ini file looks like so: > [Current] > npiXMLFile = file:///E:/ultrahld/npiMap.xml > Submitter = 1234567 > Carrier = ColoradoMedicare > ConfirmSuccess = True > KeepLicense = False > KeepInsID = False > KeepTaxID = True > KeepUxIN = False > KeepFacID = False > UseSecID = True > FixSSN = True > DNtoDQ = False > InHist = E:\ultrahld\MCARE06.837, E:\ultrahld\MCARE04.837, > E:\bbs\out.837 > OutHist = E:\bbs\out.837, E:\bbs\MCAL03.NPI > CvtCarrier = True > [JobProfiles] > [[Bogus]] > Submitter = 8675309 > Carrier = NHIC > CvtCarrier = False > KeepLicense = False > KeepInsID = False > KeepTaxID = True > KeepUxIN = True > KeepFacID = False > UseSecID = False > FixSSN = True > DNtoDQ = False > InFile = E:\ultrahld\MCARE04.837 > OutFile = E:\bbs\out.837 > [[ReallyBogus]] > Submitter = 345678 > Carrier = NHIC > CvtCarrier = False > KeepLicense = False > KeepInsID = False > KeepTaxID = True > KeepUxIN = True > KeepFacID = False > UseSecID = False > FixSSN = True > DNtoDQ = False > InFile = E:\ultrahld\MCARE03.837 > OutFile = E:\bbs\out.837 > If I cut the file short after [JobProfiles], all is well, but if I include [[Bogus]] or [[ReallyBogus]] the validation blows up with the following: Traceback (most recent call last): > File "E:\fsrPy\FSR-X12\fsr_x12.pyw", line 538, in <module> > main() > File "E:\fsrPy\FSR-X12\fsr_x12.pyw", line 530, in main > test = Global.cfgFile.validate(Global.vtor, copy=True) > File "c:\python25\lib\site-packages\configobj.py", line 2301, in validate > copy=copy, section=section[entry]) > File "c:\python25\lib\site-packages\configobj.py", line 2297, in validate > section.comments[entry] = section._cs_section_comments[entry] > KeyError: 'Bogus' > Script terminated. > I was poking around adding pprint() statements in configobj.py, and the problem seems to be that when "__many__" occurs in the configspec, no entries are created in section._cs_section_comments - which of course they wouldn't be, because we don't know what the subsection names are yet. I'm not actually using comments, and probably never will, so I suppose I could just rip out all of that... but there must be a better way, and I can't possibly be the only one who's run into this. However, I haven't seen it mentioned in the list archives, so I suspect I'm doing something wrong. What should I do? Windows XP Pro SP3 Python 2.5.1 wxPython 2.8.7.1 ConfigObj 4 -- www.fsrtechnologies.com |
|
From: Marc T. <mar...@gm...> - 2008-06-20 03:21:47
|
On Thu, Jun 19, 2008 at 6:25 PM, Marc Tompkins <mar...@gm...> wrote: > > ConfigObj 4 > Sorry, forgot to fill in the rest before hitting send... ConfigObj 4.5.2 -- www.fsrtechnologies.com |
|
From: Michael F. <fuz...@vo...> - 2008-06-22 05:23:23
|
Hello Marc, I'll have to look at this - I can't see the problem and it may be a bug. Michael Marc Tompkins wrote: > Hi all - > > I hope this is not a horribly stupid question... > > I'm setting up my configspec thusly: > > > tmpStr = """[Current] > npiXMLFile = string(default="npiMap.XML") > InHist = string_list(default=None) > OutHist = string_list(default=None) > Submitter = string(default=None) > Carrier = string(default=None) > MainSize = tuple() > MainPos = tuple() > SummarySize = tuple() > SummaryPos = tuple() > ConfirmSuccess = boolean(default=True) > CvtCarrier = boolean(default=False) > KeepLicense = boolean(default=False) > KeepInsID = boolean(default=False) > KeepTaxID = boolean(default=True) > KeepUxIN = boolean(default=True) > KeepFacID = boolean(default=False) > UseSecID = boolean(default=False) > FixSSN = boolean(default=True) > DNtoDQ = boolean(default=False) > [JobProfiles] > [[__many__]] > Submitter = string(default=" ") > Carrier = string(default=" ") > CvtCarrier = boolean(default=False) > KeepLicense = boolean(default=False) > KeepInsID = boolean(default=False) > KeepTaxID = boolean(default=True) > KeepUxIN = boolean(default=True) > KeepFacID = boolean(default=False) > UseSecID = boolean(default=False) > FixSSN = boolean(default=True) > DNtoDQ = boolean(default=False) > InFile = string(default="") > OutFile = string(default="") > """ > cfgSpec = StringIO.StringIO(tmpStr) > cfgFile = ConfigObj(cfgFileName, > configspec=cfgSpec, raise_errors=True, > write_empty_values = True, > create_empty=True, indent_type=' ', list_values > = True) > vtor = Validator() > > > and validating it thusly: > > test = cfgFile.validate(vtor, copy=True) > cfgFile.write() > > > My actual ini file looks like so: > > [Current] > npiXMLFile = file:///E:/ultrahld/npiMap.xml > Submitter = 1234567 > Carrier = ColoradoMedicare > ConfirmSuccess = True > KeepLicense = False > KeepInsID = False > KeepTaxID = True > KeepUxIN = False > KeepFacID = False > UseSecID = True > FixSSN = True > DNtoDQ = False > InHist = E:\ultrahld\MCARE06.837, E:\ultrahld\MCARE04.837, > E:\bbs\out.837 > OutHist = E:\bbs\out.837, E:\bbs\MCAL03.NPI > CvtCarrier = True > [JobProfiles] > [[Bogus]] > Submitter = 8675309 > Carrier = NHIC > CvtCarrier = False > KeepLicense = False > KeepInsID = False > KeepTaxID = True > KeepUxIN = True > KeepFacID = False > UseSecID = False > FixSSN = True > DNtoDQ = False > InFile = E:\ultrahld\MCARE04.837 > OutFile = E:\bbs\out.837 > [[ReallyBogus]] > Submitter = 345678 > Carrier = NHIC > CvtCarrier = False > KeepLicense = False > KeepInsID = False > KeepTaxID = True > KeepUxIN = True > KeepFacID = False > UseSecID = False > FixSSN = True > DNtoDQ = False > InFile = E:\ultrahld\MCARE03.837 > OutFile = E:\bbs\out.837 > > > If I cut the file short after [JobProfiles], all is well, but if I > include [[Bogus]] or [[ReallyBogus]] the validation blows up with the > following: > Traceback (most recent call last): > > File "E:\fsrPy\FSR-X12\fsr_x12.pyw", line 538, in <module> > main() > File "E:\fsrPy\FSR-X12\fsr_x12.pyw", line 530, in main > test = Global.cfgFile.validate(Global.vtor, copy=True) > File "c:\python25\lib\site-packages\configobj.py", line 2301, in > validate > copy=copy, section=section[entry]) > File "c:\python25\lib\site-packages\configobj.py", line 2297, in > validate > section.comments[entry] = section._cs_section_comments[entry] > KeyError: 'Bogus' > Script terminated. > > > I was poking around adding pprint() statements in configobj.py, and > the problem seems to be that when "__many__" occurs in the configspec, > no entries are created in section._cs_section_comments - which of > course they wouldn't be, because we don't know what the subsection > names are yet. > > I'm not actually using comments, and probably never will, so I suppose > I could just rip out all of that... but there must be a better way, > and I can't possibly be the only one who's run into this. However, I > haven't seen it mentioned in the list archives, so I suspect I'm doing > something wrong. What should I do? > > Windows XP Pro SP3 > Python 2.5.1 > wxPython 2.8.7.1 <http://2.8.7.1> > ConfigObj 4 > > -- > www.fsrtechnologies.com <http://www.fsrtechnologies.com> > ------------------------------------------------------------------------ > > ------------------------------------------------------------------------- > Check out the new SourceForge.net Marketplace. > It's the best place to buy or sell services for > just about anything Open Source. > http://sourceforge.net/services/buy/index.php > ------------------------------------------------------------------------ > > _______________________________________________ > Configobj-develop mailing list > Con...@li... > https://lists.sourceforge.net/lists/listinfo/configobj-develop > -- http://www.ironpythoninaction.com/ http://www.theotherdelia.co.uk/ http://www.voidspace.org.uk/ http://www.ironpython.info/ http://www.resolverhacks.net/ |
|
From: Michael F. <fuz...@vo...> - 2008-06-22 11:18:33
|
Hello Marc, I'll have to look at this - I can't see the problem and it may be a bug. Michael Marc Tompkins wrote: > Hi all - > > I hope this is not a horribly stupid question... > > I'm setting up my configspec thusly: > > > tmpStr = """[Current] > npiXMLFile = string(default="npiMap.XML") > InHist = string_list(default=None) > OutHist = string_list(default=None) > Submitter = string(default=None) > Carrier = string(default=None) > MainSize = tuple() > MainPos = tuple() > SummarySize = tuple() > SummaryPos = tuple() > ConfirmSuccess = boolean(default=True) > CvtCarrier = boolean(default=False) > KeepLicense = boolean(default=False) > KeepInsID = boolean(default=False) > KeepTaxID = boolean(default=True) > KeepUxIN = boolean(default=True) > KeepFacID = boolean(default=False) > UseSecID = boolean(default=False) > FixSSN = boolean(default=True) > DNtoDQ = boolean(default=False) > [JobProfiles] > [[__many__]] > Submitter = string(default=" ") > Carrier = string(default=" ") > CvtCarrier = boolean(default=False) > KeepLicense = boolean(default=False) > KeepInsID = boolean(default=False) > KeepTaxID = boolean(default=True) > KeepUxIN = boolean(default=True) > KeepFacID = boolean(default=False) > UseSecID = boolean(default=False) > FixSSN = boolean(default=True) > DNtoDQ = boolean(default=False) > InFile = string(default="") > OutFile = string(default="") > """ > cfgSpec = StringIO.StringIO(tmpStr) > cfgFile = ConfigObj(cfgFileName, > configspec=cfgSpec, raise_errors=True, > write_empty_values = True, > create_empty=True, indent_type=' ', list_values > = True) > vtor = Validator() > > > and validating it thusly: > > test = cfgFile.validate(vtor, copy=True) > cfgFile.write() > > > My actual ini file looks like so: > > [Current] > npiXMLFile = file:///E:/ultrahld/npiMap.xml > Submitter = 1234567 > Carrier = ColoradoMedicare > ConfirmSuccess = True > KeepLicense = False > KeepInsID = False > KeepTaxID = True > KeepUxIN = False > KeepFacID = False > UseSecID = True > FixSSN = True > DNtoDQ = False > InHist = E:\ultrahld\MCARE06.837, E:\ultrahld\MCARE04.837, > E:\bbs\out.837 > OutHist = E:\bbs\out.837, E:\bbs\MCAL03.NPI > CvtCarrier = True > [JobProfiles] > [[Bogus]] > Submitter = 8675309 > Carrier = NHIC > CvtCarrier = False > KeepLicense = False > KeepInsID = False > KeepTaxID = True > KeepUxIN = True > KeepFacID = False > UseSecID = False > FixSSN = True > DNtoDQ = False > InFile = E:\ultrahld\MCARE04.837 > OutFile = E:\bbs\out.837 > [[ReallyBogus]] > Submitter = 345678 > Carrier = NHIC > CvtCarrier = False > KeepLicense = False > KeepInsID = False > KeepTaxID = True > KeepUxIN = True > KeepFacID = False > UseSecID = False > FixSSN = True > DNtoDQ = False > InFile = E:\ultrahld\MCARE03.837 > OutFile = E:\bbs\out.837 > > > If I cut the file short after [JobProfiles], all is well, but if I > include [[Bogus]] or [[ReallyBogus]] the validation blows up with the > following: > Traceback (most recent call last): > > File "E:\fsrPy\FSR-X12\fsr_x12.pyw", line 538, in <module> > main() > File "E:\fsrPy\FSR-X12\fsr_x12.pyw", line 530, in main > test = Global.cfgFile.validate(Global.vtor, copy=True) > File "c:\python25\lib\site-packages\configobj.py", line 2301, in > validate > copy=copy, section=section[entry]) > File "c:\python25\lib\site-packages\configobj.py", line 2297, in > validate > section.comments[entry] = section._cs_section_comments[entry] > KeyError: 'Bogus' > Script terminated. > > > I was poking around adding pprint() statements in configobj.py, and > the problem seems to be that when "__many__" occurs in the configspec, > no entries are created in section._cs_section_comments - which of > course they wouldn't be, because we don't know what the subsection > names are yet. > > I'm not actually using comments, and probably never will, so I suppose > I could just rip out all of that... but there must be a better way, > and I can't possibly be the only one who's run into this. However, I > haven't seen it mentioned in the list archives, so I suspect I'm doing > something wrong. What should I do? > > Windows XP Pro SP3 > Python 2.5.1 > wxPython 2.8.7.1 <http://2.8.7.1> > ConfigObj 4 > > -- > www.fsrtechnologies.com <http://www.fsrtechnologies.com> > ------------------------------------------------------------------------ > > ------------------------------------------------------------------------- > Check out the new SourceForge.net Marketplace. > It's the best place to buy or sell services for > just about anything Open Source. > http://sourceforge.net/services/buy/index.php > ------------------------------------------------------------------------ > > _______________________________________________ > Configobj-develop mailing list > Con...@li... > https://lists.sourceforge.net/lists/listinfo/configobj-develop > -- http://www.ironpythoninaction.com/ http://www.theotherdelia.co.uk/ http://www.voidspace.org.uk/ http://www.ironpython.info/ http://www.resolverhacks.net/ |
|
From: Michael F. <fuz...@vo...> - 2008-06-22 19:13:02
|
Marc Tompkins wrote: > Hi all - > > I hope this is not a horribly stupid question... Hello Marc, Your problem only occurs if 'copy=True' is set in the call to validate. This implies to me that it is a real bug. I'm looking at it now. Michael Foord > > I'm setting up my configspec thusly: > > > tmpStr = """[Current] > npiXMLFile = string(default="npiMap.XML") > InHist = string_list(default=None) > OutHist = string_list(default=None) > Submitter = string(default=None) > Carrier = string(default=None) > MainSize = tuple() > MainPos = tuple() > SummarySize = tuple() > SummaryPos = tuple() > ConfirmSuccess = boolean(default=True) > CvtCarrier = boolean(default=False) > KeepLicense = boolean(default=False) > KeepInsID = boolean(default=False) > KeepTaxID = boolean(default=True) > KeepUxIN = boolean(default=True) > KeepFacID = boolean(default=False) > UseSecID = boolean(default=False) > FixSSN = boolean(default=True) > DNtoDQ = boolean(default=False) > [JobProfiles] > [[__many__]] > Submitter = string(default=" ") > Carrier = string(default=" ") > CvtCarrier = boolean(default=False) > KeepLicense = boolean(default=False) > KeepInsID = boolean(default=False) > KeepTaxID = boolean(default=True) > KeepUxIN = boolean(default=True) > KeepFacID = boolean(default=False) > UseSecID = boolean(default=False) > FixSSN = boolean(default=True) > DNtoDQ = boolean(default=False) > InFile = string(default="") > OutFile = string(default="") > """ > cfgSpec = StringIO.StringIO(tmpStr) > cfgFile = ConfigObj(cfgFileName, > configspec=cfgSpec, raise_errors=True, > write_empty_values = True, > create_empty=True, indent_type=' ', list_values > = True) > vtor = Validator() > > > and validating it thusly: > > test = cfgFile.validate(vtor, copy=True) > cfgFile.write() > > > My actual ini file looks like so: > > [Current] > npiXMLFile = file:///E:/ultrahld/npiMap.xml > Submitter = 1234567 > Carrier = ColoradoMedicare > ConfirmSuccess = True > KeepLicense = False > KeepInsID = False > KeepTaxID = True > KeepUxIN = False > KeepFacID = False > UseSecID = True > FixSSN = True > DNtoDQ = False > InHist = E:\ultrahld\MCARE06.837, E:\ultrahld\MCARE04.837, > E:\bbs\out.837 > OutHist = E:\bbs\out.837, E:\bbs\MCAL03.NPI > CvtCarrier = True > [JobProfiles] > [[Bogus]] > Submitter = 8675309 > Carrier = NHIC > CvtCarrier = False > KeepLicense = False > KeepInsID = False > KeepTaxID = True > KeepUxIN = True > KeepFacID = False > UseSecID = False > FixSSN = True > DNtoDQ = False > InFile = E:\ultrahld\MCARE04.837 > OutFile = E:\bbs\out.837 > [[ReallyBogus]] > Submitter = 345678 > Carrier = NHIC > CvtCarrier = False > KeepLicense = False > KeepInsID = False > KeepTaxID = True > KeepUxIN = True > KeepFacID = False > UseSecID = False > FixSSN = True > DNtoDQ = False > InFile = E:\ultrahld\MCARE03.837 > OutFile = E:\bbs\out.837 > > > If I cut the file short after [JobProfiles], all is well, but if I > include [[Bogus]] or [[ReallyBogus]] the validation blows up with the > following: > Traceback (most recent call last): > > File "E:\fsrPy\FSR-X12\fsr_x12.pyw", line 538, in <module> > main() > File "E:\fsrPy\FSR-X12\fsr_x12.pyw", line 530, in main > test = Global.cfgFile.validate(Global.vtor, copy=True) > File "c:\python25\lib\site-packages\configobj.py", line 2301, in > validate > copy=copy, section=section[entry]) > File "c:\python25\lib\site-packages\configobj.py", line 2297, in > validate > section.comments[entry] = section._cs_section_comments[entry] > KeyError: 'Bogus' > Script terminated. > > > I was poking around adding pprint() statements in configobj.py, and > the problem seems to be that when "__many__" occurs in the configspec, > no entries are created in section._cs_section_comments - which of > course they wouldn't be, because we don't know what the subsection > names are yet. > > I'm not actually using comments, and probably never will, so I suppose > I could just rip out all of that... but there must be a better way, > and I can't possibly be the only one who's run into this. However, I > haven't seen it mentioned in the list archives, so I suspect I'm doing > something wrong. What should I do? > > Windows XP Pro SP3 > Python 2.5.1 > wxPython 2.8.7.1 <http://2.8.7.1> > ConfigObj 4 > > -- > www.fsrtechnologies.com <http://www.fsrtechnologies.com> > ------------------------------------------------------------------------ > > ------------------------------------------------------------------------- > Check out the new SourceForge.net Marketplace. > It's the best place to buy or sell services for > just about anything Open Source. > http://sourceforge.net/services/buy/index.php > ------------------------------------------------------------------------ > > _______________________________________________ > Configobj-develop mailing list > Con...@li... > https://lists.sourceforge.net/lists/listinfo/configobj-develop > -- http://www.ironpythoninaction.com/ http://www.voidspace.org.uk/ http://www.trypython.org/ http://www.ironpython.info/ http://www.theotherdelia.co.uk/ http://www.resolverhacks.net/ |
|
From: Marc T. <mar...@gm...> - 2008-06-22 19:23:05
|
On Sun, Jun 22, 2008 at 12:12 PM, Michael Foord <fuz...@vo...> wrote: > Hello Marc, > > Your problem only occurs if 'copy=True' is set in the call to validate. > This implies to me that it is a real bug. > > I'm looking at it now. > > Thank you Fuzzyman! -- www.fsrtechnologies.com |
|
From: Michael F. <fuz...@vo...> - 2008-06-22 19:34:04
|
Marc Tompkins wrote: > On Sun, Jun 22, 2008 at 12:12 PM, Michael Foord > <fuz...@vo... <mailto:fuz...@vo...>> wrote: > > Hello Marc, > > Your problem only occurs if 'copy=True' is set in the call to > validate. > This implies to me that it is a real bug. > > I'm looking at it now. > > > Thank you Fuzzyman! I think I have a fix, but I need to write a proper test for it. All the best, Michael Foord > > -- > www.fsrtechnologies.com <http://www.fsrtechnologies.com> > ------------------------------------------------------------------------ > > ------------------------------------------------------------------------- > Check out the new SourceForge.net Marketplace. > It's the best place to buy or sell services for > just about anything Open Source. > http://sourceforge.net/services/buy/index.php > ------------------------------------------------------------------------ > > _______________________________________________ > Configobj-develop mailing list > Con...@li... > https://lists.sourceforge.net/lists/listinfo/configobj-develop > -- http://www.ironpythoninaction.com/ http://www.voidspace.org.uk/ http://www.trypython.org/ http://www.ironpython.info/ http://www.theotherdelia.co.uk/ http://www.resolverhacks.net/ |
|
From: Michael F. <fuz...@vo...> - 2008-06-22 19:48:08
|
Hello Marc, There is a fixed version now in subversion - I'd be grateful if you could try it and report any issues you have. I have one more problem to investigate that was reported a while ago. Michael Marc Tompkins wrote: > Hi all - > > I hope this is not a horribly stupid question... > > I'm setting up my configspec thusly: > > > tmpStr = """[Current] > npiXMLFile = string(default="npiMap.XML") > InHist = string_list(default=None) > OutHist = string_list(default=None) > Submitter = string(default=None) > Carrier = string(default=None) > MainSize = tuple() > MainPos = tuple() > SummarySize = tuple() > SummaryPos = tuple() > ConfirmSuccess = boolean(default=True) > CvtCarrier = boolean(default=False) > KeepLicense = boolean(default=False) > KeepInsID = boolean(default=False) > KeepTaxID = boolean(default=True) > KeepUxIN = boolean(default=True) > KeepFacID = boolean(default=False) > UseSecID = boolean(default=False) > FixSSN = boolean(default=True) > DNtoDQ = boolean(default=False) > [JobProfiles] > [[__many__]] > Submitter = string(default=" ") > Carrier = string(default=" ") > CvtCarrier = boolean(default=False) > KeepLicense = boolean(default=False) > KeepInsID = boolean(default=False) > KeepTaxID = boolean(default=True) > KeepUxIN = boolean(default=True) > KeepFacID = boolean(default=False) > UseSecID = boolean(default=False) > FixSSN = boolean(default=True) > DNtoDQ = boolean(default=False) > InFile = string(default="") > OutFile = string(default="") > """ > cfgSpec = StringIO.StringIO(tmpStr) > cfgFile = ConfigObj(cfgFileName, > configspec=cfgSpec, raise_errors=True, > write_empty_values = True, > create_empty=True, indent_type=' ', list_values > = True) > vtor = Validator() > > > and validating it thusly: > > test = cfgFile.validate(vtor, copy=True) > cfgFile.write() > > > My actual ini file looks like so: > > [Current] > npiXMLFile = file:///E:/ultrahld/npiMap.xml > Submitter = 1234567 > Carrier = ColoradoMedicare > ConfirmSuccess = True > KeepLicense = False > KeepInsID = False > KeepTaxID = True > KeepUxIN = False > KeepFacID = False > UseSecID = True > FixSSN = True > DNtoDQ = False > InHist = E:\ultrahld\MCARE06.837, E:\ultrahld\MCARE04.837, > E:\bbs\out.837 > OutHist = E:\bbs\out.837, E:\bbs\MCAL03.NPI > CvtCarrier = True > [JobProfiles] > [[Bogus]] > Submitter = 8675309 > Carrier = NHIC > CvtCarrier = False > KeepLicense = False > KeepInsID = False > KeepTaxID = True > KeepUxIN = True > KeepFacID = False > UseSecID = False > FixSSN = True > DNtoDQ = False > InFile = E:\ultrahld\MCARE04.837 > OutFile = E:\bbs\out.837 > [[ReallyBogus]] > Submitter = 345678 > Carrier = NHIC > CvtCarrier = False > KeepLicense = False > KeepInsID = False > KeepTaxID = True > KeepUxIN = True > KeepFacID = False > UseSecID = False > FixSSN = True > DNtoDQ = False > InFile = E:\ultrahld\MCARE03.837 > OutFile = E:\bbs\out.837 > > > If I cut the file short after [JobProfiles], all is well, but if I > include [[Bogus]] or [[ReallyBogus]] the validation blows up with the > following: > Traceback (most recent call last): > > File "E:\fsrPy\FSR-X12\fsr_x12.pyw", line 538, in <module> > main() > File "E:\fsrPy\FSR-X12\fsr_x12.pyw", line 530, in main > test = Global.cfgFile.validate(Global.vtor, copy=True) > File "c:\python25\lib\site-packages\configobj.py", line 2301, in > validate > copy=copy, section=section[entry]) > File "c:\python25\lib\site-packages\configobj.py", line 2297, in > validate > section.comments[entry] = section._cs_section_comments[entry] > KeyError: 'Bogus' > Script terminated. > > > I was poking around adding pprint() statements in configobj.py, and > the problem seems to be that when "__many__" occurs in the configspec, > no entries are created in section._cs_section_comments - which of > course they wouldn't be, because we don't know what the subsection > names are yet. > > I'm not actually using comments, and probably never will, so I suppose > I could just rip out all of that... but there must be a better way, > and I can't possibly be the only one who's run into this. However, I > haven't seen it mentioned in the list archives, so I suspect I'm doing > something wrong. What should I do? > > Windows XP Pro SP3 > Python 2.5.1 > wxPython 2.8.7.1 <http://2.8.7.1> > ConfigObj 4 > > -- > www.fsrtechnologies.com <http://www.fsrtechnologies.com> > ------------------------------------------------------------------------ > > ------------------------------------------------------------------------- > Check out the new SourceForge.net Marketplace. > It's the best place to buy or sell services for > just about anything Open Source. > http://sourceforge.net/services/buy/index.php > ------------------------------------------------------------------------ > > _______________________________________________ > Configobj-develop mailing list > Con...@li... > https://lists.sourceforge.net/lists/listinfo/configobj-develop > -- http://www.ironpythoninaction.com/ http://www.voidspace.org.uk/ http://www.trypython.org/ http://www.ironpython.info/ http://www.theotherdelia.co.uk/ http://www.resolverhacks.net/ |
|
From: Marc T. <mar...@gm...> - 2008-06-22 23:07:56
|
On Sun, Jun 22, 2008 at 12:47 PM, Michael Foord <fuz...@vo...> wrote: > Hello Marc, > > There is a fixed version now in subversion - I'd be grateful if you > could try it and report any issues you have. > > I have one more problem to investigate that was reported a while ago. > > Michael > Sorry for the delay - I generally use bazaar, not SVN, and had uninstalled Tortoise 'cause I hated it; I installed RapidSVN this time. I tried to import your repository but got stopped by a username/password prompt (for future reference, what SHOULD I enter there?) I gave up and just downloaded configobj.py from Revision 88: /trunk/pythonutilsand, so far, it looks great! I see the change you made, replacing two dictionary lookups with get/defaults. Very clever! Unfortunately, you've removed my excuse for procrastination: now I actually have to write the code that adds/edits/deletes job profiles. Dagnabbit, there went the weekend... Ah well, my users will be happy anyway. Thank you! -- www.fsrtechnologies.com |
|
From: Michael F. <fuz...@vo...> - 2008-06-24 20:21:27
|
Marc Tompkins wrote: > On Sun, Jun 22, 2008 at 12:47 PM, Michael Foord > <fuz...@vo... <mailto:fuz...@vo...>> wrote: > > Hello Marc, > > There is a fixed version now in subversion - I'd be grateful if you > could try it and report any issues you have. > > I have one more problem to investigate that was reported a while ago. > > Michael > > > Sorry for the delay - I generally use bazaar, not SVN, and had > uninstalled Tortoise 'cause I hated it; I installed RapidSVN this > time. I tried to import your repository but got stopped by a > username/password prompt (for future reference, what SHOULD I enter > there?) > If you checkout from the following URL you won't need to authenticate: http://svn.pythonutils.python-hosting.com/ Glad the change worked for you, I'll bush out a bugfix release soon. Michael Foord -- http://www.ironpythoninaction.com/ http://www.voidspace.org.uk/ http://www.trypython.org/ http://www.ironpython.info/ http://www.theotherdelia.co.uk/ http://www.resolverhacks.net/ |
|
From: Marc T. <mar...@gm...> - 2008-06-24 20:30:21
|
On Tue, Jun 24, 2008 at 1:20 PM, Michael Foord <fuz...@vo...> wrote: > > If you checkout from the following URL you won't need to authenticate: > I feel dumb - I was trying to use the "Import" item on the RapidSVN repository menu. Using the same URL under "Checkout" does, indeed, work just fine. Meanwhile, the new version continues to be golden for me. Thank you again. -- www.fsrtechnologies.com |