Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
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
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
65c4e95e
Commit
65c4e95e
authored
Dec 17, 2020
by
pburdette
Committed by
Stan Hu
Jan 05, 2021
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Poll if tab is not visible
Continually poll for job trace if tab is not visible in the FE.
parent
2810dfd7
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
0 additions
and
11 deletions
+0
-11
app/assets/javascripts/jobs/store/actions.js
app/assets/javascripts/jobs/store/actions.js
+0
-9
app/assets/javascripts/jobs/store/mutations.js
app/assets/javascripts/jobs/store/mutations.js
+0
-1
spec/frontend/jobs/store/mutations_spec.js
spec/frontend/jobs/store/mutations_spec.js
+0
-1
No files found.
app/assets/javascripts/jobs/store/actions.js
View file @
65c4e95e
...
...
@@ -40,7 +40,6 @@ export const toggleSidebar = ({ dispatch, state }) => {
};
let
eTagPoll
;
let
isTraceReadyForRender
;
export
const
clearEtagPoll
=
()
=>
{
eTagPoll
=
null
;
...
...
@@ -82,15 +81,9 @@ export const fetchJob = ({ state, dispatch }) => {
Visibility
.
change
(()
=>
{
if
(
!
Visibility
.
hidden
())
{
// This check is needed to ensure the loading icon
// is not shown for a finished job during a visibility change
if
(
!
isTraceReadyForRender
)
{
dispatch
(
'
startPollingTrace
'
);
}
dispatch
(
'
restartPolling
'
);
}
else
{
dispatch
(
'
stopPolling
'
);
dispatch
(
'
stopPollingTrace
'
);
}
});
};
...
...
@@ -171,8 +164,6 @@ export const fetchTrace = ({ dispatch, state }) =>
params
:
{
state
:
state
.
traceState
},
})
.
then
(({
data
})
=>
{
isTraceReadyForRender
=
data
.
complete
;
dispatch
(
'
toggleScrollisInBottom
'
,
isScrolledToBottom
());
dispatch
(
'
receiveTraceSuccess
'
,
data
);
...
...
app/assets/javascripts/jobs/store/mutations.js
View file @
65c4e95e
...
...
@@ -49,7 +49,6 @@ export default {
[
types
.
SET_TRACE_TIMEOUT
](
state
,
id
)
{
state
.
traceTimeout
=
id
;
state
.
isTraceComplete
=
false
;
},
/**
...
...
spec/frontend/jobs/store/mutations_spec.js
View file @
65c4e95e
...
...
@@ -153,7 +153,6 @@ describe('Jobs Store Mutations', () => {
mutations
[
types
.
SET_TRACE_TIMEOUT
](
stateCopy
,
id
);
expect
(
stateCopy
.
traceTimeout
).
toEqual
(
id
);
expect
(
stateCopy
.
isTraceComplete
).
toBe
(
false
);
});
});
...
...
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