codeql icon indicating copy to clipboard operation
codeql copied to clipboard

Python: Bottle Framework Support

Open Kwstubbs opened this issue 1 year ago • 2 comments
trafficstars

Add basic Bottle support

Kwstubbs avatar Sep 03 '24 21:09 Kwstubbs

@RasmusWL I've added more support for Bottle routes and I've added tests.

Kwstubbs avatar Sep 23 '24 22:09 Kwstubbs

@RasmusWL is travelling at the moment, so I will take this over for now. I am curious about the switch away from API nodes in https://github.com/github/codeql/pull/17370/commits/5d12f7bd30a87900e818f230189d6c6ee88b7d59, was it necessary to get the tests pass? It looks like you based this off of other models. This is absolutely fine, but let us double check that we are actually modelling the bottle framework.

yoff avatar Oct 14 '24 07:10 yoff

@yoff Hi, please let me know what you think of the changes. I'm trying to model every possible usage of bottle, so even though the documentation might not mention something, if I find it is used a lot in Github I have included them. Obviously it must run on the latest, currently v12.25 as LTS. Also, I'm not sure where I moved away from API nodes in 5d12f7bd3. Everything I have modeled here I have created a codebase/codeql database to ensure validity.

Kwstubbs avatar Oct 29 '24 22:10 Kwstubbs

Also, I'm not sure where I moved away from API nodes in 5d12f7bd3.

Sorry, that was a somewhat vague reference to a large diff. I meant the fields name and value inside the class HeaderWriteSubscript in the Headers module (see here).

yoff avatar Oct 30 '24 10:10 yoff

@yoff I was just copying from Werkzeug.qll as recommended by Rasmus on his first pass. The API nodes was working, as I was using these models in my research before PRing. ✅

Kwstubbs avatar Oct 30 '24 20:10 Kwstubbs

@yoff I was just copying from Werkzeug.qll as recommended by Rasmus on his first pass. The API nodes was working, as I was using these models in my research before PRing. ✅

In that case, it would be nicer to use the API nodes. They are cleaner and might match in a few more cases. I will not require it, though, it can be a clean-up of both situations later.

yoff avatar Oct 31 '24 10:10 yoff

@yoff just curious about the status of this PR. Are we just waiting on approval from @RasmusWL?

Kwstubbs avatar Nov 12 '24 22:11 Kwstubbs

@yoff just curious about the status of this PR. Are we just waiting on approval from @RasmusWL?

Sorry, this must have fallen through the cracks.

yoff avatar Nov 19 '24 14:11 yoff