# Extension to provide python class autocompletes

**URL:** <https://forum.robotframework.org/t/extension-to-provide-python-class-autocompletes/7861>\
**Category:** Extensions\
**Created:** [2 October 2024 13:35 UTC](https://forum.robotframework.org/t/extension-to-provide-python-class-autocompletes/7861 "2024-10-02T13:35:03Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![wmtan01](https://avatars.discourse-cdn.com/v4/letter/w/c37758/32.png) [@wmtan01](https://forum.robotframework.org/u/wmtan01)\
**Post date:** [2 October 2024 13:35 UTC](https://forum.robotframework.org/t/extension-to-provide-python-class-autocompletes/7861/1 "2024-10-02T13:35:03Z")

</div>

Hi,

We use a lot of python in our robot framework code to complement it, a few instances we would use python is inline evaluation with ${{ }} which made logic easier to implement, another is we define our data models in python so they’re easier to extend and we write convenience methods on these classes. The problem we’re facing is that we don’t get autocomplete suggestions in .robot files.

As an example if we have a class Dog that has a bark() method, even if our variables in robot framework can contain an object of class Dog, when we use it for example with ${dog\_instance.bark()} the dog\_instance does not show an autocomplete for bark.

Another one is when I want to generated a uuid, I do ${{ uuid.uuid4() }} but the IDE doesn’t provide any autocomplete so what I end up doing is scripting things out in python first so I know the syntax. Now this one might be a bit trickier since the uuid is only imported during runtime 😃

For context we use VSCode for development, and RobotCode is our main extension. I was wondering if someone else have explored the possibility of having python auto complete in VSCode for .robot files?

---

<div class="post-metadata">

**Author:** ![daniel](https://dub1.discourse-cdn.com/flex005/user_avatar/forum.robotframework.org/daniel/32/1492_2.png) [@daniel](https://forum.robotframework.org/u/daniel)\
**Post date:** [2 October 2024 13:50 UTC](https://forum.robotframework.org/t/extension-to-provide-python-class-autocompletes/7861/2 "2024-10-02T13:50:07Z")

</div>

This is very difficult to implement with the way Robot works. These expressions are evaluated at runtime, have no typing, modules are loaded on demand, etc.

Feel free to submit an enhancement request at [RobotCode](https://github.com/robotcodedev/robotcode/issues) so we don’t forget about it, but I’m not sure how long it will take to implement something like this.
