After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 752658 - XML empty <argsstring/> in python
XML empty <argsstring/> in python
Status: RESOLVED FIXED
Product: doxygen
Classification: Other
Component: general
1.8.11-GIT
Other Linux
: Normal normal
: ---
Assigned To: Dimitri van Heesch
Dimitri van Heesch
Depends on:
Blocks:
 
 
Reported: 2015-07-21 07:46 UTC by erez.oxman
Modified: 2015-07-26 11:11 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description erez.oxman 2015-07-21 07:46:59 UTC
Hi, 

I'm trying to document the python package https://github.com/simplejson/simplejson, and looking on the xml output.

In the majority of functions, it does correctly output the argsstring, but in some cases it does not.

For example:
1) simplejson.encoder.JSONEncoderForHTML.iterencode:

      <memberdef kind="function" id="classsimplejson_1_1encoder_1_1JSONEncoderForHTML_1af33783f5eb7f4662509c3e14025a106a" prot="public" static="no" const="no" explicit="no" inline="no" virt="non-virtual">
        <type>def</type>
        <definition>def simplejson.encoder.JSONEncoderForHTML.iterencode</definition>
        <argsstring/>
        <name>iterencode</name>
        <briefdescription>
        </briefdescription>
        <detaileddescription>
        </detaileddescription>
        <inbodydescription>
        </inbodydescription>
        <location file="simplejson/encoder.py" line="380" column="1" bodyfile="simplejson/encoder.py" bodystart="380" bodyend="388"/>
      </memberdef>

2) simplejson.ordered_dict.OrderedDict.fromkeys:

 <memberdef kind="function" id="classsimplejson_1_1ordered__dict_1_1OrderedDict_1a2167f66a1c59b2a89bbebab3d02e3353" prot="public" static="no" const="no" explicit="no" inline="no" virt="non-virtual">
        <type>def</type>
        <definition>def simplejson.ordered_dict.OrderedDict.fromkeys</definition>
        <argsstring/>
        <name>fromkeys</name>
        <briefdescription>
        </briefdescription>
        <detaileddescription>
        </detaileddescription>
        <inbodydescription>
        </inbodydescription>
        <location file="simplejson/ordered_dict.py" line="106" column="1" bodyfile="simplejson/ordered_dict.py" bodystart="106" bodyend="111"/>
      </memberdef>


I have seen it happening in other packages as well, but unfortunately can't find a logic when exactly this bug appears.

If you need any more info regarding this issue I'll be happy to provide.

Thanks.
Comment 1 albert 2015-07-25 15:46:25 UTC
Problem comes (checked for the 2 situations described) from the fact that the last argument has a default value, and the end of the list is not handled properly.

I've just pushed a proposed patch to github (pull request 371).
Comment 2 erez.oxman 2015-07-25 17:53:29 UTC
Thanks very much for the speedy fix.

I did report this issue a while ago as a follow up in ticket #739056:
https://bugzilla.gnome.org/show_bug.cgi?id=739056#c4
Status Reopened.

If you have a working setup, please check if this fixes #739056, and close it as well.

Thx again, I'll keep an eye open for more cases if I encounter them in the future.
Comment 3 erez.oxman 2015-07-25 20:49:20 UTC
In my setup, the latest git with changes you suggested to src/pyscanner.l , somehow the problems (1),(2) remain.

I'm not very fluent in git/github, so it might be the cause for that. When the pull request is merged, I'll retry.
Comment 4 albert 2015-07-26 08:26:30 UTC
(In reply to erez.oxman from comment #2)
> Thanks very much for the speedy fix.
> 
> I did report this issue a while ago as a follow up in ticket #739056:
> https://bugzilla.gnome.org/show_bug.cgi?id=739056#c4
> Status Reopened.
> 
> If you have a working setup, please check if this fixes #739056, and close
> it as well.
> 
> Thx again, I'll keep an eye open for more cases if I encounter them in the
> future.

Bug 739056 - Python xml - argsstring is empty, while HTML have arguments indeed looks to me that it is the same problem.
Comment 5 albert 2015-07-26 08:28:41 UTC
(In reply to erez.oxman from comment #3)
> In my setup, the latest git with changes you suggested to src/pyscanner.l ,
> somehow the problems (1),(2) remain.
> 
> I'm not very fluent in git/github, so it might be the cause for that. When
> the pull request is merged, I'll retry.

Strange that this does not work for you. Please test again and put a print statement into the pyscanner.l so you are sure that you use the right version.
Comment 6 Dimitri van Heesch 2015-07-26 10:06:33 UTC
I've merged the pull request 371. Let me know if it correctly solves the issue.
Comment 7 erez.oxman 2015-07-26 11:11:57 UTC
Everything works great now, bug solved. Thanks again for all the help.