AirtestProject / AirtestProject/AirtestIDE

Airtest Custom Python Code - TypeError: cannot use a string pattern on a bytes-like object

Aperta
#877 1 commento 0 reazioni 0 assegnatari Vedi su GitHub
Lingua principale
Nessun dato sulla lingua
Stelle
236
Fork
40
Metriche di merge delle PR
Nessuna PR unita negli ultimi 30g

Descrizione

Hello Airtesters!)
When I use Custom Python Path I have a strange Issue -

I spent 1 day to solve this problem, but I did not find a solution.

I've been changing the environment.
I tried to pass the path to the file as a byte-object.
I decoded the picture into base64.

`TypeError: cannot use a string pattern on a bytes-like object
`
![image](https://user-images.githubusercontent.com/72766918/101734378-39f70d00-3ad1-11eb-8294-aff155b26f34.png)

I have this Issue, when i use this commands:

`swipe([0.5, 0.8], [0.5, 0.3])`
`touch(Template(r"tpl1607583450288.png", record_pos=(0.004, -0.476), resolution=(1080, 2280)),times=1, duration=0.01)`

But This command works Currectly:

`exists(Template(r"tpl1607585362450.png", record_pos=(0.003, -0.459), resolution=(1080, 2280)))`
`wait(Template(r"tpl1607585510451.png", record_pos=(0.004, 0.476), resolution=(1080, 2280)))`

https://youtu.be/bN1sB8lFJtw - Airtest Python Example

https://youtu.be/jZZKrX6YE3s - The Same Code with Custom Python Path - TypeError

https://pastebin.pl/view/e4d67c59 - Error Log

[TypeError.zip](https://github.com/AirtestProject/AirtestIDE/files/5670887/TypeError.zip)

I look forward to your help, pleas

Guida per i contributori

Nessuna guida per i contributori indicizzata per questo repository

Valutazione

Questa issue non è ancora stata valutata.

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.