tebelorg / RPA-Python

Python package for doing RPA
Apache License 2.0
4.87k stars 663 forks source link

Incorrect pathing when accessing TagUI - pending checks and more details #421

Closed ETFruitNinja closed 2 years ago

ETFruitNinja commented 2 years ago

Hello, somewhat new coder here trying to make a program with RPA. I am unable to initialize the RPA Python. I am using Visual Studio Code. I have installed RPA, but when I try and run r.init() I get this message:

The system cannot find the path specified.
[RPA][ERROR] - following happens when starting TagUI...

The following command is executed to start TagUI -
"C:\Users\yehje\AppData\Roaming/tagui/src/tagui" rpa_python chrome

It leads to following output when starting TagUI -
The system cannot find the path specified.

[RPA][ERROR] - unknown error encountered
False

Notice that the command that is used to start TagUI is a mix of Windows and Linux formats. It worked on my brother's computer, and we are both on Windows. Is there a way to get it to execute the right path?

Thanks!

kensoh commented 2 years ago

Interesting.. this typically should be handled correctly by Windows. Can you try below and let me know how it goes?

  1. Try opening command prompt, then run the following line (copy and paste)

    "C:\Users\yehje\AppData\Roaming/tagui/src/tagui"
  2. Try running from within Python / Jupyter notebook the following line

    import os
    os.system('"C:\\Users\\yehje\\AppData\\Roaming/tagui/src/tagui"')
kensoh commented 2 years ago

Closing for time being until further inputs or similar issues being raised

BowTiedSwan commented 1 year ago

Hi, getting the same error running RPA on Windows 10, if I try to run "C:\Users\username\AppData\Roaming\tagui\src\tagui" rpa_python chrome I get:

At line:1 char:50
+ "C:\Users\username\AppData\Roaming\tagui\src\tagui" rpa_python chrome
+                                                  ~~~~~~~~~~
Unexpected token 'rpa_python' in expression or statement.
    + CategoryInfo          : ParserError: (:) [], ParentContainsErrorRecordException
    + FullyQualifiedErrorId : UnexpectedToken

When trying to run the example provided:

r.init()
r.url('https://www.google.com')
r.type('//*[@name="q"]', 'decentralisation[enter]')
print(r.read('result-stats'))
r.snap('page', 'results.png')
r.close()

I get:

[RPA][ERROR] - following happens when starting TagUI...

The following command is executed to start TagUI -
"C:\Users\username\AppData\Roaming/tagui/src/tagui" rpa_python chrome

It leads to following output when starting TagUI -

[RPA][ERROR] - unknown error encountered
[RPA][ERROR] - use init() before using url()
[RPA][ERROR] - use init() before using type()
[RPA][ERROR] - use init() before using read()

[RPA][ERROR] - use init() before using snap()
[RPA][ERROR] - use init() before using close()
False
kensoh commented 1 year ago

Hi @BowTiedSwan what happens if you do the following:

  1. open windows command prompt
  2. create an empty file rpa_python
  3. copy paste the following and enter "C:\Users\username\AppData\Roaming\tagui\src\tagui" rpa_python chrome
  4. try again with the following and enter "C:\Users\username\AppData\Roaming/tagui/src/tagui" rpa_python chrome

Above is trying to get more details on what is the root error. I haven't come across the "Unexpected token 'rpa_python' in expression or statement." error before that you've shared above.

divisa-developer commented 8 months ago

Hi, I had the same issue described above. It prompted a window informing MSVCR110.dll was not found. I'll try to install the resdistributables that should install said dll and update if it solves the issue.

UPDATE: The problem was solved by installing x86 version of 2012 Visual Studio Redistributables. My System is x64 so maybe that was the problem. Is there a way to circumvent this or should I just install the x86 version redistributables for every machine I plan to use this on?