File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11import ConnectionMgr from "@/managers/connectionmgr" ;
2+ import AppMgr , { EventType } from "@/managers/appmgr" ;
23import logger from "@/utils/logger" ;
4+ import i18n from "@/utils/i18n" ;
35import Joystick from '@/managers/joystickmgr' ;
46import TableMgr from '@/managers/tablemgr' ;
57
@@ -546,6 +548,12 @@ abstract class Connection {
546548 if ( result [ i ] . includes ( "[Errno" , 0 ) ) {
547549 this . runError = result [ i ] ;
548550 console . log ( "run time error: " + this . runError ) ;
551+ if ( this . runError . includes ( '[Errno 2] ENOENT' ) ) {
552+ AppMgr . getInstance ( ) . emit (
553+ EventType . EVENT_ALERT ,
554+ i18n . t ( 'program-not-saved-to-xrp' ) ,
555+ ) ;
556+ }
549557 }
550558 }
551559 }
@@ -654,7 +662,7 @@ abstract class Connection {
654662 this . startReaduntil ( ">>>" ) ;
655663 await this . writeToDevice ( "\r" + this . CTRL_CMD_KINTERRUPT ) ;
656664 result = await this . haltUntilRead ( 2 , 5 ) ; //this should be fast
657- if ( result != undefined ) {
665+ if ( result != undefined && result . length > 0 ) {
658666 gotToPrompt = true ;
659667 break ;
660668 }
Original file line number Diff line number Diff line change 158158 "update-lib-complete" : " The XRP library update process has completed successfully." ,
159159 "dashboard" : " Dashboard" ,
160160 "no-editor-run" : " Please select a tab with code before pressing Run." ,
161+ "program-not-saved-to-xrp" : " This program has not been saved to the XRP. Please save it to the XRP before running." ,
161162 "FilesystemStorage" : " XRP Filesystem: {{ capacity }} MB" ,
162163 "GoogleDriveStorage" : " Google Drive Filesystem" ,
163164 "sensors" : " Sensors" ,
Original file line number Diff line number Diff line change 156156 "update-lib-complete" : " El proceso de actualización de la biblioteca XRP se ha completado con éxito." ,
157157 "dashboard" : " Panel" ,
158158 "no-editor-run" : " Seleccione una pestaña con código antes de presionar Ejecutar." ,
159+ "program-not-saved-to-xrp" : " Este programa no se ha guardado en el XRP. Guárdelo en el XRP antes de ejecutarlo." ,
159160 "FilesystemStorage" : " Sistema de archivos XRP: {{ capacity }} MB" ,
160161 "GoogleDriveStorage" : " Sistema de archivos de Google Drive" ,
161162 "sensors" : " Sensores" ,
You can’t perform that action at this time.
0 commit comments