Skip to content
Toggle navigation
Toggle navigation
This project
Loading...
Sign in
Luciano Barletta
/
Pruebas-RTO
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Network
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Network
Compare
Branches
Tags
Commit db067e56
authored
2023-10-03 10:51:01 -0300
by
Juan Pablo dure
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
migro a subproceso
1 parent
f4670ac4
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
7 deletions
fosadiaria.py
fosadiaria.py
View file @
db067e5
from
datetime
import
datetime
from
datetime
import
datetime
from
time
import
sleep
from
time
import
sleep
import
os
import
os
,
subprocess
from
configuracion
import
*
from
configuracion
import
*
import
pandas
as
pd
import
pandas
as
pd
...
@@ -69,12 +69,15 @@ class FosaDiaria():
...
@@ -69,12 +69,15 @@ class FosaDiaria():
def
_BuscarExcelDescargado
(
self
,
tmp
):
def
_BuscarExcelDescargado
(
self
,
tmp
):
rta
=
False
rta
=
False
cmd
=
f
"""ls {self.CarpetaDescarga} -ls |grep {self.cabezaera}| grep xls | grep -v crdownload &>{tmp}"""
cmd
=
f
"""ls {self.CarpetaDescarga} -ls |grep {self.cabezaera}| grep xls | grep -v crdownload"""
.
split
(
" "
)
os
.
system
(
cmd
)
rte
=
subprocess
.
check_output
(
cmd
)
#os.system(cmd)
print
(
cmd
)
print
(
cmd
)
sleep
(
0.1
)
print
(
rte
)
file1
=
open
(
tmp
,
'r'
)
Lines
=
str
(
rte
)
.
split
(
"
\n
"
)
Lines
=
file1
.
readlines
()
#sleep(0.1)
#file1 = open(tmp, 'r')
#Lines = file1.readlines()
for
line
in
Lines
:
for
line
in
Lines
:
der
=
str
(
line
)
.
split
(
" "
)
der
=
str
(
line
)
.
split
(
" "
)
#print(1,type(line),type(der))
#print(1,type(line),type(der))
...
@@ -83,7 +86,7 @@ class FosaDiaria():
...
@@ -83,7 +86,7 @@ class FosaDiaria():
#print(3,line,der,der[-1],archivo)
#print(3,line,der,der[-1],archivo)
print
(
archivo
)
print
(
archivo
)
rta
=
archivo
rta
=
archivo
file1
.
close
()
#
file1.close()
os
.
system
(
f
"""rm {tmp}"""
)
os
.
system
(
f
"""rm {tmp}"""
)
return
rta
return
rta
...
...
Write
Preview
Styling with
Markdown
is supported
Attach a file
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to post a comment