Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
erp5
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Labels
Merge Requests
7
Merge Requests
7
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Jobs
Commits
Open sidebar
Jérome Perrin
erp5
Commits
e8815a8f
Commit
e8815a8f
authored
Feb 17, 2024
by
Jérome Perrin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Thread.is_alive
parent
46515653
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
3 deletions
+3
-3
bt5/erp5_core_test/TestTemplateItem/portal_components/test.erp5.testSelectionTool.py
...lateItem/portal_components/test.erp5.testSelectionTool.py
+1
-1
product/ERP5/tests/erp5_url_checker.py
product/ERP5/tests/erp5_url_checker.py
+2
-2
No files found.
bt5/erp5_core_test/TestTemplateItem/portal_components/test.erp5.testSelectionTool.py
View file @
e8815a8f
...
@@ -248,7 +248,7 @@ class TestSelectionPersistence(unittest.TestCase):
...
@@ -248,7 +248,7 @@ class TestSelectionPersistence(unittest.TestCase):
t
=
Thread
(
target
=
thread_func
,
args
=
(
self
.
db
.
open
,))
t
=
Thread
(
target
=
thread_func
,
args
=
(
self
.
db
.
open
,))
t
.
start
()
t
.
start
()
t
.
join
(
60
)
t
.
join
(
60
)
self
.
assertFalse
(
t
.
is
A
live
())
self
.
assertFalse
(
t
.
is
_a
live
())
def
testSelectionParamConflictResolution
(
self
):
def
testSelectionParamConflictResolution
(
self
):
# same user edits the same selection with two different parameters
# same user edits the same selection with two different parameters
...
...
product/ERP5/tests/erp5_url_checker.py
View file @
e8815a8f
...
@@ -55,7 +55,7 @@ def main():
...
@@ -55,7 +55,7 @@ def main():
print
(
"thread: %i request: %i url: %s"
%
(
i
,
request_number
,
url
))
print
(
"thread: %i request: %i url: %s"
%
(
i
,
request_number
,
url
))
else
:
else
:
for
t
in
range
(
0
,
max_thread
):
for
t
in
range
(
0
,
max_thread
):
if
threads
[
t
].
is
A
live
()
==
0
:
if
threads
[
t
].
is
_a
live
()
==
0
:
url
=
'//user%i:user%i@localhost:9673%s?__ac_name=user%s&__ac_password=user%s'
%
\
url
=
'//user%i:user%i@localhost:9673%s?__ac_name=user%s&__ac_password=user%s'
%
\
(
t
,
t
,
list_url
[
i
][:
-
1
],
t
,
t
)
(
t
,
t
,
list_url
[
i
][:
-
1
],
t
,
t
)
threads
[
t
]
=
Thread
(
target
=
checker
[
t
].
CheckUrl
,
kwargs
=
{
'url'
:
url
})
threads
[
t
]
=
Thread
(
target
=
checker
[
t
].
CheckUrl
,
kwargs
=
{
'url'
:
url
})
...
@@ -142,7 +142,7 @@ class Checker(URLOpener):
...
@@ -142,7 +142,7 @@ class Checker(URLOpener):
try
:
try
:
thread
=
Thread
(
target
=
self
.
SearchUrl
,
args
=
(
url
,))
thread
=
Thread
(
target
=
self
.
SearchUrl
,
args
=
(
url
,))
thread
.
start
()
thread
.
start
()
while
thread
.
is
A
live
():
while
thread
.
is
_a
live
():
sleep
(
0.5
)
sleep
(
0.5
)
print
(
"Connection to %s went fine"
%
url
)
print
(
"Connection to %s went fine"
%
url
)
except
IOError
as
err
:
except
IOError
as
err
:
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
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 comment