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

[Python2Cpg] Could you support "lineNumberEnd" for more extended node types like "Call"? #4504

Open
hzlujunyi opened this issue Apr 30, 2024 · 0 comments

Comments

@hzlujunyi
Copy link

When I process python Cpg, I found that node types like "Call" seems to only provide property "lineNumber" (w/o "lineNumberEnd"). However, for code in python, it is common that a statement are written in multiple lines.

I tried to use property "code" to locate the end line, but unfortunately it seems that the content in "code" has been processed by Joern and thus it is different from the raw source code lines.

I noticed that for library like ast in python, it provides a easy way to achieve the start and end for these lines by property "end_lineno".

I'm wondering why do we not provide these, or maybe there are some other alternative ways I missed?

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

1 participant