Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
N
nebula
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
exchain
nebula
Commits
c6e58a5c
Unverified
Commit
c6e58a5c
authored
Jun 10, 2022
by
Matthew Slipper
Committed by
GitHub
Jun 10, 2022
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #2756 from ethereum-optimism/develop
Develop -> Master
parents
e2a3fa47
050859fd
Changes
9
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
53 additions
and
10 deletions
+53
-10
brown-parrots-type.md
.changeset/brown-parrots-type.md
+5
-0
eighty-countries-develop.md
.changeset/eighty-countries-develop.md
+5
-0
weak-needles-jam.md
.changeset/weak-needles-jam.md
+5
-0
config.yml
.circleci/config.yml
+2
-1
.semgrepignore
.semgrepignore
+1
-1
Makefile
Makefile
+6
-0
system_test.go
op-e2e/system_test.go
+3
-1
base-service-v2.ts
packages/common-ts/src/base-service/base-service-v2.ts
+23
-7
driver.go
teleportr/drivers/disburser/driver.go
+3
-0
No files found.
.changeset/brown-parrots-type.md
0 → 100644
View file @
c6e58a5c
---
'
@eth-optimism/teleportr'
:
patch
---
Fix panic
.changeset/eighty-countries-develop.md
0 → 100644
View file @
c6e58a5c
---
'
@eth-optimism/common-ts'
:
patch
---
Log server messages to logger instead of stdout
.changeset/weak-needles-jam.md
0 → 100644
View file @
c6e58a5c
---
'
@eth-optimism/common-ts'
:
patch
---
Include default options in metadata metric
.circleci/config.yml
View file @
c6e58a5c
...
@@ -508,18 +508,19 @@ jobs:
...
@@ -508,18 +508,19 @@ jobs:
SEMGREP_BASELINE_REF
:
<< parameters.diff_branch >>
SEMGREP_BASELINE_REF
:
<< parameters.diff_branch >>
SEMGREP_REPO_URL
:
<< pipeline.project.git_url >>
SEMGREP_REPO_URL
:
<< pipeline.project.git_url >>
SEMGREP_BRANCH
:
<< pipeline.git.branch >>
SEMGREP_BRANCH
:
<< pipeline.git.branch >>
SEMGREP_COMMIT
:
<< pipeline.git.revision >>
# Change job timeout (default is 1800 seconds; set to 0 to disable)
# Change job timeout (default is 1800 seconds; set to 0 to disable)
SEMGREP_TIMEOUT
:
3000
SEMGREP_TIMEOUT
:
3000
docker
:
docker
:
-
image
:
returntocorp/semgrep
-
image
:
returntocorp/semgrep
resource_class
:
xlarge
steps
:
steps
:
-
checkout
-
checkout
-
run
:
-
run
:
name
:
"
Set
environment
variables"
# for PR comments and in-app hyperlinks to findings
name
:
"
Set
environment
variables"
# for PR comments and in-app hyperlinks to findings
command
:
|
command
:
|
echo 'export SEMGREP_COMMIT=$CIRCLE_SHA1' >> $BASH_ENV
echo 'export SEMGREP_PR_ID=${CIRCLE_PULL_REQUEST##*/}' >> $BASH_ENV
echo 'export SEMGREP_PR_ID=${CIRCLE_PULL_REQUEST##*/}' >> $BASH_ENV
echo 'export SEMGREP_JOB_URL=$CIRCLE_BUILD_URL' >> $BASH_ENV
echo 'export SEMGREP_JOB_URL=$CIRCLE_BUILD_URL' >> $BASH_ENV
echo 'export SEMGREP_REPO_NAME=$CIRCLE_PROJECT_USERNAME/$CIRCLE_PROJECT_REPONAME' >> $BASH_ENV
echo 'export SEMGREP_REPO_NAME=$CIRCLE_PROJECT_USERNAME/$CIRCLE_PROJECT_REPONAME' >> $BASH_ENV
...
...
.semgrepignore
View file @
c6e58a5c
...
@@ -20,4 +20,4 @@ tests/
...
@@ -20,4 +20,4 @@ tests/
l2geth/
l2geth/
packages/*/node_modules
packages/*/node_modules
packages/*/test
packages/*/test
\ No newline at end of file
Makefile
View file @
c6e58a5c
...
@@ -77,6 +77,12 @@ test-integration:
...
@@ -77,6 +77,12 @@ test-integration:
./packages/contracts-bedrock/deployments/devnetL1
./packages/contracts-bedrock/deployments/devnetL1
.PHONY
:
test-integration
.PHONY
:
test-integration
# Remove the baseline-commit to generate a base reading & show all issues
semgrep
:
$
(
eval
DEV_REF :
=
$(
shell
git rev-parse develop
)
)
SEMGREP_REPO_NAME
=
ethereum-optimism/optimism semgrep ci
--baseline-commit
=
$(DEV_REF)
.PHONY
:
semgrep
devnet-genesis
:
devnet-genesis
:
bash ./ops-bedrock/devnet-genesis.sh
bash ./ops-bedrock/devnet-genesis.sh
.PHONY
:
devnet-genesis
.PHONY
:
devnet-genesis
op-e2e/system_test.go
View file @
c6e58a5c
...
@@ -170,6 +170,8 @@ func TestL2OutputSubmitter(t *testing.T) {
...
@@ -170,6 +170,8 @@ func TestL2OutputSubmitter(t *testing.T) {
// Wait for batch submitter to update L2 output oracle.
// Wait for batch submitter to update L2 output oracle.
timeoutCh
:=
time
.
After
(
15
*
time
.
Second
)
timeoutCh
:=
time
.
After
(
15
*
time
.
Second
)
ticker
:=
time
.
NewTicker
(
1
*
time
.
Second
)
defer
ticker
.
Stop
()
for
{
for
{
l2ooTimestamp
,
err
:=
l2OutputOracle
.
LatestBlockTimestamp
(
&
bind
.
CallOpts
{})
l2ooTimestamp
,
err
:=
l2OutputOracle
.
LatestBlockTimestamp
(
&
bind
.
CallOpts
{})
require
.
Nil
(
t
,
err
)
require
.
Nil
(
t
,
err
)
...
@@ -205,7 +207,7 @@ func TestL2OutputSubmitter(t *testing.T) {
...
@@ -205,7 +207,7 @@ func TestL2OutputSubmitter(t *testing.T) {
select
{
select
{
case
<-
timeoutCh
:
case
<-
timeoutCh
:
t
.
Fatalf
(
"State root oracle not updated"
)
t
.
Fatalf
(
"State root oracle not updated"
)
case
<-
ti
me
.
After
(
time
.
Second
)
:
case
<-
ti
cker
.
C
:
}
}
}
}
...
...
packages/common-ts/src/base-service/base-service-v2.ts
View file @
c6e58a5c
...
@@ -155,11 +155,7 @@ export abstract class BaseServiceV2<
...
@@ -155,11 +155,7 @@ export abstract class BaseServiceV2<
this
.
loop
=
params
.
loop
!==
undefined
?
params
.
loop
:
true
this
.
loop
=
params
.
loop
!==
undefined
?
params
.
loop
:
true
this
.
state
=
{}
as
TServiceState
this
.
state
=
{}
as
TServiceState
// Add default options to options spec.
const
stdOptionsSpec
:
OptionsSpec
<
StandardOptions
>
=
{
;(
params
.
optionsSpec
as
any
)
=
{
...(
params
.
optionsSpec
||
{}),
// Users cannot set these options.
loopIntervalMs
:
{
loopIntervalMs
:
{
validator
:
validators
.
num
,
validator
:
validators
.
num
,
desc
:
'
Loop interval in milliseconds
'
,
desc
:
'
Loop interval in milliseconds
'
,
...
@@ -177,6 +173,12 @@ export abstract class BaseServiceV2<
...
@@ -177,6 +173,12 @@ export abstract class BaseServiceV2<
},
},
}
}
// Add default options to options spec.
;(
params
.
optionsSpec
as
any
)
=
{
...(
params
.
optionsSpec
||
{}),
...
stdOptionsSpec
,
}
// List of options that can safely be logged.
// List of options that can safely be logged.
const
publicOptionNames
=
Object
.
entries
(
params
.
optionsSpec
)
const
publicOptionNames
=
Object
.
entries
(
params
.
optionsSpec
)
.
filter
(([,
spec
])
=>
{
.
filter
(([,
spec
])
=>
{
...
@@ -348,7 +350,11 @@ export abstract class BaseServiceV2<
...
@@ -348,7 +350,11 @@ export abstract class BaseServiceV2<
name
:
params
.
name
,
name
:
params
.
name
,
version
:
params
.
version
,
version
:
params
.
version
,
...
publicOptionNames
.
reduce
((
acc
,
key
)
=>
{
...
publicOptionNames
.
reduce
((
acc
,
key
)
=>
{
acc
[
key
]
=
config
.
str
(
key
)
if
(
key
in
stdOptionsSpec
)
{
acc
[
key
]
=
this
.
options
[
key
].
toString
()
}
else
{
acc
[
key
]
=
config
.
str
(
key
)
}
return
acc
return
acc
},
{}),
},
{}),
},
},
...
@@ -375,7 +381,17 @@ export abstract class BaseServiceV2<
...
@@ -375,7 +381,17 @@ export abstract class BaseServiceV2<
app
.
use
(
bodyParser
.
urlencoded
({
extended
:
true
}))
app
.
use
(
bodyParser
.
urlencoded
({
extended
:
true
}))
// Logging.
// Logging.
app
.
use
(
morgan
(
'
short
'
))
app
.
use
(
morgan
(
'
short
'
,
{
stream
:
{
write
:
(
str
:
string
)
=>
{
this
.
logger
.
info
(
`server log`
,
{
log
:
str
,
})
},
},
})
)
// Metrics.
// Metrics.
// Will expose a /metrics endpoint by default.
// Will expose a /metrics endpoint by default.
...
...
teleportr/drivers/disburser/driver.go
View file @
c6e58a5c
...
@@ -352,6 +352,9 @@ func (d *Driver) SendTransaction(
...
@@ -352,6 +352,9 @@ func (d *Driver) SendTransaction(
subCtx
,
cancel
:=
context
.
WithTimeout
(
ctx
,
10
*
time
.
Second
)
subCtx
,
cancel
:=
context
.
WithTimeout
(
ctx
,
10
*
time
.
Second
)
defer
cancel
()
defer
cancel
()
err
:=
d
.
cfg
.
L2Client
.
SendTransaction
(
subCtx
,
tx
)
err
:=
d
.
cfg
.
L2Client
.
SendTransaction
(
subCtx
,
tx
)
if
err
==
nil
{
return
err
}
if
!
IsRetryableError
(
err
)
{
if
!
IsRetryableError
(
err
)
{
d
.
metrics
.
FailedTXSubmissions
.
WithLabelValues
(
"permanent"
)
.
Inc
()
d
.
metrics
.
FailedTXSubmissions
.
WithLabelValues
(
"permanent"
)
.
Inc
()
return
backoff
.
Permanent
(
err
)
return
backoff
.
Permanent
(
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