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
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Titouan Soulard
erp5
Commits
c3e944af
Commit
c3e944af
authored
Sep 08, 2011
by
Arnaud Fontaine
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Display timestamp in each log entry for erp5.util.testbrowser and erp5.util.benchmark
parent
4a128d7e
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
9 additions
and
7 deletions
+9
-7
erp5/util/benchmark/process.py
erp5/util/benchmark/process.py
+1
-3
erp5/util/benchmark/result.py
erp5/util/benchmark/result.py
+5
-3
erp5/util/testbrowser/browser.py
erp5/util/testbrowser/browser.py
+3
-1
No files found.
erp5/util/benchmark/process.py
View file @
c3e944af
...
...
@@ -152,7 +152,6 @@ class BenchmarkProcess(multiprocessing.Process):
_socket
=
socket
.
socket
def
_patched_socket
(
*
args
,
**
kwargs
):
new_socket
=
_socket
(
*
args
,
**
kwargs
)
self
.
_logger
.
debug
(
"source IP: %s"
%
self
.
_source_ip
)
new_socket
.
bind
((
self
.
_source_ip
,
0
))
return
new_socket
...
...
@@ -173,8 +172,7 @@ class BenchmarkProcess(multiprocessing.Process):
self
.
_browser
=
self
.
getBrowser
(
result_instance
.
log_file
)
while
self
.
_current_repeat
!=
(
self
.
_argument_namespace
.
repeat
+
1
):
self
.
_logger
.
info
(
"%s: Iteration: %d"
%
(
datetime
.
datetime
.
now
(),
self
.
_current_repeat
))
self
.
_logger
.
info
(
"Iteration: %d"
%
self
.
_current_repeat
)
self
.
runBenchmarkSuiteList
(
result
)
if
not
self
.
_current_repeat
%
RESULT_NUMBER_BEFORE_FLUSHING
:
...
...
erp5/util/benchmark/result.py
View file @
c3e944af
...
...
@@ -100,9 +100,11 @@ class BenchmarkResult(object):
@
property
def
logger
(
self
):
if
not
self
.
_logger
:
logging
.
basicConfig
(
stream
=
self
.
log_file
,
logging
.
basicConfig
(
stream
=
self
.
log_file
,
level
=
(
self
.
_argument_namespace
.
enable_debug
and
logging
.
DEBUG
or
logging
.
INFO
))
logging
.
DEBUG
or
logging
.
INFO
),
format
=
'%(asctime)s: %(levelname)s: %(message)s [%(name)s]'
)
self
.
_logger
=
logging
.
getLogger
(
'erp5.util.benchmark'
)
return
self
.
_logger
...
...
erp5/util/testbrowser/browser.py
View file @
c3e944af
...
...
@@ -172,7 +172,9 @@ class Browser(ExtendedTestBrowser):
# Only display WARNING message if debugging is not enabled
logging_level
=
is_debug
and
logging
.
DEBUG
or
logging
.
WARNING
stream
=
log_file
and
log_file
or
sys
.
stderr
logging
.
basicConfig
(
stream
=
stream
,
level
=
logging_level
)
logging
.
basicConfig
(
stream
=
stream
,
level
=
logging_level
,
format
=
'%(asctime)s: %(levelname)s: %(message)s [%(name)s]'
)
self
.
_logger
=
logging
.
getLogger
(
'erp5.util.testbrowser'
)
self
.
_is_legacy_listbox
=
is_legacy_listbox
...
...
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