[#856] move geth subpackages to root level (#1007)

This commit is contained in:
Adrià Cidre 2018-06-08 13:29:50 +02:00 committed by GitHub
parent 8ce6efc749
commit d5be8c525d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
151 changed files with 172 additions and 172 deletions

View File

@ -1,7 +1,7 @@
{ {
"Exclude": [ "Exclude": [
".*_mock.go", ".*_mock.go",
"geth/jail/doc.go", "jail/doc.go",
".*Errors unhandled.*fmt.Fprint.*gasv2.*" ".*Errors unhandled.*fmt.Fprint.*gasv2.*"
], ],
"Skip": ["helpers", "static"], "Skip": ["helpers", "static"],

View File

@ -13,7 +13,7 @@ CGO_CFLAGS=-I/$(JAVA_HOME)/include -I/$(JAVA_HOME)/include/darwin
GOBIN=$(dir $(realpath $(firstword $(MAKEFILE_LIST))))build/bin GOBIN=$(dir $(realpath $(firstword $(MAKEFILE_LIST))))build/bin
GIT_COMMIT := $(shell git rev-parse --short HEAD) GIT_COMMIT := $(shell git rev-parse --short HEAD)
BUILD_FLAGS ?= $(shell echo "-ldflags '-X main.buildStamp=`date -u '+%Y-%m-%d.%H:%M:%S'` -X github.com/status-im/status-go/geth/params.VersionMeta=$(GIT_COMMIT)'") BUILD_FLAGS ?= $(shell echo "-ldflags '-X main.buildStamp=`date -u '+%Y-%m-%d.%H:%M:%S'` -X github.com/status-im/status-go/params.VersionMeta=$(GIT_COMMIT)'")
GO ?= latest GO ?= latest
XGOVERSION ?= 1.10.x XGOVERSION ?= 1.10.x
@ -130,10 +130,10 @@ mock-install: ##@other Install mocking tools
go get -u github.com/golang/mock/mockgen go get -u github.com/golang/mock/mockgen
mock: ##@other Regenerate mocks mock: ##@other Regenerate mocks
mockgen -package=fcm -destination=geth/notifications/push/fcm/client_mock.go -source=geth/notifications/push/fcm/client.go mockgen -package=fcm -destination=notifications/push/fcm/client_mock.go -source=notifications/push/fcm/client.go
mockgen -package=fake -destination=geth/transactions/fake/mock.go -source=geth/transactions/fake/txservice.go mockgen -package=fake -destination=transactions/fake/mock.go -source=transactions/fake/txservice.go
mockgen -package=account -destination=geth/account/accounts_mock.go -source=geth/account/accounts.go mockgen -package=account -destination=account/accounts_mock.go -source=account/accounts.go
mockgen -package=jail -destination=geth/jail/cell_mock.go -source=geth/jail/cell.go mockgen -package=jail -destination=jail/cell_mock.go -source=jail/cell.go
mockgen -package=status -destination=services/status/account_mock.go -source=services/status/service.go mockgen -package=status -destination=services/status/account_mock.go -source=services/status/service.go
docker-test: ##@tests Run tests in a docker container with golang. docker-test: ##@tests Run tests in a docker container with golang.

View File

@ -85,7 +85,7 @@ If you have problems running tests on public network we suggest reading [e2e gui
If you want to launch specific test, for instance `RPCSendTransactions`, use the following command: If you want to launch specific test, for instance `RPCSendTransactions`, use the following command:
```shell ```shell
go test -v ./geth/api/ -testify.m ^RPCSendTransaction$ go test -v ./api/ -testify.m ^RPCSendTransaction$
``` ```
Note `-testify.m` as [testify/suite](https://godoc.org/github.com/stretchr/testify/suite) is used to group individual tests. Note `-testify.m` as [testify/suite](https://godoc.org/github.com/stretchr/testify/suite) is used to group individual tests.

View File

@ -1,5 +1,5 @@
// Code generated by MockGen. DO NOT EDIT. // Code generated by MockGen. DO NOT EDIT.
// Source: geth/account/accounts.go // Source: account/accounts.go
// Package account is a generated GoMock package. // Package account is a generated GoMock package.
package account package account

View File

@ -7,12 +7,12 @@ import (
"github.com/ethereum/go-ethereum/accounts/keystore" "github.com/ethereum/go-ethereum/accounts/keystore"
gethcommon "github.com/ethereum/go-ethereum/common" gethcommon "github.com/ethereum/go-ethereum/common"
"github.com/ethereum/go-ethereum/log" "github.com/ethereum/go-ethereum/log"
"github.com/status-im/status-go/geth/account" "github.com/status-im/status-go/account"
"github.com/status-im/status-go/geth/jail" "github.com/status-im/status-go/jail"
"github.com/status-im/status-go/geth/node" "github.com/status-im/status-go/node"
"github.com/status-im/status-go/geth/params" "github.com/status-im/status-go/params"
"github.com/status-im/status-go/geth/transactions"
"github.com/status-im/status-go/sign" "github.com/status-im/status-go/sign"
"github.com/status-im/status-go/transactions"
) )
// StatusAPI provides API to access Status related functionality. // StatusAPI provides API to access Status related functionality.
@ -31,7 +31,7 @@ func NewStatusAPI() *StatusAPI {
func NewStatusAPIWithBackend(b *StatusBackend) *StatusAPI { func NewStatusAPIWithBackend(b *StatusBackend) *StatusAPI {
return &StatusAPI{ return &StatusAPI{
b: b, b: b,
log: log.New("package", "status-go/geth/api.StatusAPI"), log: log.New("package", "status-go/api.StatusAPI"),
} }
} }

View File

@ -12,17 +12,17 @@ import (
fcmlib "github.com/NaySoftware/go-fcm" fcmlib "github.com/NaySoftware/go-fcm"
"github.com/status-im/status-go/geth/account" "github.com/status-im/status-go/account"
"github.com/status-im/status-go/geth/jail" "github.com/status-im/status-go/jail"
"github.com/status-im/status-go/geth/node" "github.com/status-im/status-go/node"
"github.com/status-im/status-go/geth/notifications/push/fcm" "github.com/status-im/status-go/notifications/push/fcm"
"github.com/status-im/status-go/geth/params" "github.com/status-im/status-go/params"
"github.com/status-im/status-go/geth/rpc" "github.com/status-im/status-go/rpc"
"github.com/status-im/status-go/geth/transactions"
"github.com/status-im/status-go/services/personal" "github.com/status-im/status-go/services/personal"
"github.com/status-im/status-go/services/rpcfilters" "github.com/status-im/status-go/services/rpcfilters"
"github.com/status-im/status-go/sign" "github.com/status-im/status-go/sign"
"github.com/status-im/status-go/signal" "github.com/status-im/status-go/signal"
"github.com/status-im/status-go/transactions"
) )
const ( const (
@ -71,7 +71,7 @@ func NewStatusBackend() *StatusBackend {
transactor: transactor, transactor: transactor,
personalAPI: personalAPI, personalAPI: personalAPI,
newNotification: notificationManager, newNotification: notificationManager,
log: log.New("package", "status-go/geth/api.StatusBackend"), log: log.New("package", "status-go/api.StatusBackend"),
} }
} }

View File

@ -8,8 +8,8 @@ import (
"testing" "testing"
"github.com/ethereum/go-ethereum/common/hexutil" "github.com/ethereum/go-ethereum/common/hexutil"
"github.com/status-im/status-go/geth/node" "github.com/status-im/status-go/node"
"github.com/status-im/status-go/geth/params" "github.com/status-im/status-go/params"
"github.com/stretchr/testify/assert" "github.com/stretchr/testify/assert"
"github.com/stretchr/testify/require" "github.com/stretchr/testify/require"
) )

View File

@ -9,8 +9,8 @@ import (
"strconv" "strconv"
"strings" "strings"
"github.com/status-im/status-go/geth/api" "github.com/status-im/status-go/api"
"github.com/status-im/status-go/geth/params" "github.com/status-im/status-go/params"
) )
// command contains the result of a parsed command line and // command contains the result of a parsed command line and

View File

@ -7,7 +7,7 @@ import (
"reflect" "reflect"
"github.com/ethereum/go-ethereum/log" "github.com/ethereum/go-ethereum/log"
"github.com/status-im/status-go/geth/api" "github.com/status-im/status-go/api"
) )
const ( const (

View File

@ -11,9 +11,9 @@ import (
"sync" "sync"
"testing" "testing"
"github.com/status-im/status-go/api"
"github.com/status-im/status-go/cmd/statusd/debug" "github.com/status-im/status-go/cmd/statusd/debug"
"github.com/status-im/status-go/geth/api" "github.com/status-im/status-go/params"
"github.com/status-im/status-go/geth/params"
"github.com/stretchr/testify/assert" "github.com/stretchr/testify/assert"
) )

View File

@ -4,7 +4,7 @@ import (
"fmt" "fmt"
"testing" "testing"
"github.com/status-im/status-go/geth/params" "github.com/status-im/status-go/params"
"github.com/stretchr/testify/require" "github.com/stretchr/testify/require"
) )

View File

@ -15,12 +15,12 @@ import (
"github.com/ethereum/go-ethereum/log" "github.com/ethereum/go-ethereum/log"
"github.com/ethereum/go-ethereum/p2p/discv5" "github.com/ethereum/go-ethereum/p2p/discv5"
"github.com/status-im/status-go/api"
"github.com/status-im/status-go/cmd/statusd/debug" "github.com/status-im/status-go/cmd/statusd/debug"
"github.com/status-im/status-go/cmd/statusd/topics" "github.com/status-im/status-go/cmd/statusd/topics"
"github.com/status-im/status-go/geth/api"
"github.com/status-im/status-go/geth/node"
"github.com/status-im/status-go/geth/params"
nodemetrics "github.com/status-im/status-go/metrics/node" nodemetrics "github.com/status-im/status-go/metrics/node"
"github.com/status-im/status-go/node"
"github.com/status-im/status-go/params"
"github.com/status-im/status-go/profiling" "github.com/status-im/status-go/profiling"
) )

View File

@ -4,7 +4,7 @@ import (
"context" "context"
"time" "time"
"github.com/status-im/status-go/geth/node" "github.com/status-im/status-go/node"
) )
func createContextFromTimeout(timeout int) (context.Context, context.CancelFunc) { func createContextFromTimeout(timeout int) (context.Context, context.CancelFunc) {

View File

@ -6,7 +6,7 @@ import (
"strings" "strings"
"github.com/ethereum/go-ethereum/p2p/discv5" "github.com/ethereum/go-ethereum/p2p/discv5"
"github.com/status-im/status-go/geth/params" "github.com/status-im/status-go/params"
) )
// TopicFlag used to parse discv5 topics. // TopicFlag used to parse discv5 topics.

View File

@ -3,7 +3,7 @@ package topics
import ( import (
"testing" "testing"
"github.com/status-im/status-go/geth/params" "github.com/status-im/status-go/params"
"github.com/stretchr/testify/assert" "github.com/stretchr/testify/assert"
) )

View File

@ -6,7 +6,7 @@ import (
"fmt" "fmt"
"io/ioutil" "io/ioutil"
"github.com/status-im/status-go/geth/params" "github.com/status-im/status-go/params"
) )
// whisperConfig creates node configuration object from flags // whisperConfig creates node configuration object from flags

View File

@ -1,9 +1,9 @@
# jail [![GoDoc](https://godoc.org/github.com/status-im/status-go/geth/jail?status.png)](https://godoc.org/github.com/status-im/status-go/geth/jail) # jail [![GoDoc](https://godoc.org/github.com/status-im/status-go/jail?status.png)](https://godoc.org/github.com/status-im/status-go/jail)
jail - jailed environment for executing JS code. jail - jailed environment for executing JS code.
Download: Download:
```shell ```shell
go get github.com/status-im/status-go/geth/jail go get github.com/status-im/status-go/jail
``` ```
* * * * * *
@ -47,7 +47,7 @@ wrappers around Otto VM functions of the same name. `Run` accepts raw JS strings
Default Otto VM interpreter doesn't support setTimeout() / setInterval() JS functions, Default Otto VM interpreter doesn't support setTimeout() / setInterval() JS functions,
because they're not part of ECMA-262 spec, but properties of the window object in browser. because they're not part of ECMA-262 spec, but properties of the window object in browser.
We add support for them using own implementation of Event Loop, heavily based on [ottoext package](https://github.com/deoxxa/ottoext). See loop/fetch/promise packages under [jail/internal/](https://github.com/status-im/status-go/tree/develop/geth/jail/internal). We add support for them using own implementation of Event Loop, heavily based on [ottoext package](https://github.com/deoxxa/ottoext). See loop/fetch/promise packages under [jail/internal/](https://github.com/status-im/status-go/tree/develop/jail/internal).
Each cell starts a new loop in a separate goroutine, registers functions for setTimeout / setInterval calls and associate them with this loop. All JS code executed as callback to setTimeout/setInterval will be handled by this loop. Each cell starts a new loop in a separate goroutine, registers functions for setTimeout / setInterval calls and associate them with this loop. All JS code executed as callback to setTimeout/setInterval will be handled by this loop.

View File

@ -6,11 +6,11 @@ import (
"time" "time"
"github.com/robertkrimen/otto" "github.com/robertkrimen/otto"
"github.com/status-im/status-go/geth/jail/internal/fetch" "github.com/status-im/status-go/jail/internal/fetch"
"github.com/status-im/status-go/geth/jail/internal/loop" "github.com/status-im/status-go/jail/internal/loop"
"github.com/status-im/status-go/geth/jail/internal/loop/looptask" "github.com/status-im/status-go/jail/internal/loop/looptask"
"github.com/status-im/status-go/geth/jail/internal/timers" "github.com/status-im/status-go/jail/internal/timers"
"github.com/status-im/status-go/geth/jail/internal/vm" "github.com/status-im/status-go/jail/internal/vm"
) )
const timeout = 5 * time.Second const timeout = 5 * time.Second

View File

@ -1,5 +1,5 @@
// Code generated by MockGen. DO NOT EDIT. // Code generated by MockGen. DO NOT EDIT.
// Source: geth/jail/cell.go // Source: jail/cell.go
// Package jail is a generated GoMock package. // Package jail is a generated GoMock package.
package jail package jail

View File

@ -8,7 +8,7 @@ import (
"testing" "testing"
"github.com/robertkrimen/otto" "github.com/robertkrimen/otto"
"github.com/status-im/status-go/geth/jail/console" "github.com/status-im/status-go/jail/console"
"github.com/status-im/status-go/signal" "github.com/status-im/status-go/signal"
"github.com/stretchr/testify/suite" "github.com/stretchr/testify/suite"
) )

View File

@ -1,5 +1,5 @@
/* /*
jail - jailed environment for executing JS code. Package jail - jailed environment for executing JS code.
Package jail implements "jailed" environment for executing arbitrary Package jail implements "jailed" environment for executing arbitrary
JavaScript code using Otto JS interpreter (https://github.com/robertkrimen/otto). JavaScript code using Otto JS interpreter (https://github.com/robertkrimen/otto).
@ -37,7 +37,7 @@ wrappers around Otto VM functions of the same name. `Run` accepts raw JS strings
Default Otto VM interpreter doesn't support setTimeout() / setInterval() JS functions, Default Otto VM interpreter doesn't support setTimeout() / setInterval() JS functions,
because they're not part of ECMA-262 spec, but properties of the window object in browser. because they're not part of ECMA-262 spec, but properties of the window object in browser.
We add support for them using own implementation of Event Loop, heavily based on [ottoext package](https://github.com/deoxxa/ottoext). See loop/fetch/promise packages under [jail/internal/](https://github.com/status-im/status-go/tree/develop/geth/jail/internal). We add support for them using own implementation of Event Loop, heavily based on [ottoext package](https://github.com/deoxxa/ottoext). See loop/fetch/promise packages under [jail/internal/](https://github.com/status-im/status-go/tree/develop/jail/internal).
Each cell starts a new loop in a separate goroutine, registers functions for setTimeout / setInterval calls and associate them with this loop. All JS code executed as callback to setTimeout/setInterval will be handled by this loop. Each cell starts a new loop in a separate goroutine, registers functions for setTimeout / setInterval calls and associate them with this loop. All JS code executed as callback to setTimeout/setInterval will be handled by this loop.

View File

@ -4,7 +4,7 @@ import (
"os" "os"
"github.com/robertkrimen/otto" "github.com/robertkrimen/otto"
"github.com/status-im/status-go/geth/jail/console" "github.com/status-im/status-go/jail/console"
"github.com/status-im/status-go/signal" "github.com/status-im/status-go/signal"
) )

View File

@ -12,8 +12,8 @@ import (
"sync/atomic" "sync/atomic"
gethrpc "github.com/ethereum/go-ethereum/rpc" gethrpc "github.com/ethereum/go-ethereum/rpc"
"github.com/status-im/status-go/geth/params" "github.com/status-im/status-go/params"
"github.com/status-im/status-go/geth/rpc" "github.com/status-im/status-go/rpc"
"github.com/status-im/status-go/signal" "github.com/status-im/status-go/signal"
"github.com/stretchr/testify/suite" "github.com/stretchr/testify/suite"
) )

View File

@ -3,7 +3,7 @@ ottoext
Originally based on [github.com/deoxxa/ottoext](https://github.com/deoxxa/ottoext) Originally based on [github.com/deoxxa/ottoext](https://github.com/deoxxa/ottoext)
[![GoDoc](https://godoc.org/github.com/status-im/status-go/geth/jail/ottoext?status.svg)](https://godoc.org/github.com/status-im/status-go/geth/jail/ottoext) [![GoDoc](https://godoc.org/github.com/status-im/status-go/jail/ottoext?status.svg)](https://godoc.org/github.com/status-im/status-go/jail/ottoext)
Overview Overview
-------- --------

View File

@ -11,9 +11,9 @@ import (
"github.com/robertkrimen/otto" "github.com/robertkrimen/otto"
"github.com/status-im/status-go/geth/jail/internal/loop" "github.com/status-im/status-go/jail/internal/loop"
"github.com/status-im/status-go/geth/jail/internal/promise" "github.com/status-im/status-go/jail/internal/promise"
"github.com/status-im/status-go/geth/jail/internal/vm" "github.com/status-im/status-go/jail/internal/vm"
) )
func mustValue(v otto.Value, err error) otto.Value { func mustValue(v otto.Value, err error) otto.Value {

View File

@ -9,9 +9,9 @@ import (
"github.com/robertkrimen/otto" "github.com/robertkrimen/otto"
"github.com/status-im/status-go/geth/jail/internal/fetch" "github.com/status-im/status-go/jail/internal/fetch"
"github.com/status-im/status-go/geth/jail/internal/loop" "github.com/status-im/status-go/jail/internal/loop"
"github.com/status-im/status-go/geth/jail/internal/vm" "github.com/status-im/status-go/jail/internal/vm"
"github.com/stretchr/testify/suite" "github.com/stretchr/testify/suite"
) )

View File

@ -6,7 +6,7 @@ import (
"sync" "sync"
"sync/atomic" "sync/atomic"
"github.com/status-im/status-go/geth/jail/internal/vm" "github.com/status-im/status-go/jail/internal/vm"
) )
// ErrClosed represents the error returned when we try to add or ready // ErrClosed represents the error returned when we try to add or ready

View File

@ -6,7 +6,7 @@ import (
"testing" "testing"
"time" "time"
"github.com/status-im/status-go/geth/jail/internal/vm" "github.com/status-im/status-go/jail/internal/vm"
"github.com/stretchr/testify/suite" "github.com/stretchr/testify/suite"
) )

View File

@ -4,8 +4,8 @@ import (
"errors" "errors"
"github.com/robertkrimen/otto" "github.com/robertkrimen/otto"
"github.com/status-im/status-go/geth/jail/internal/loop" "github.com/status-im/status-go/jail/internal/loop"
"github.com/status-im/status-go/geth/jail/internal/vm" "github.com/status-im/status-go/jail/internal/vm"
) )
// IdleTask is designed to sit in a loop and keep it active, without doing any // IdleTask is designed to sit in a loop and keep it active, without doing any

View File

@ -1,9 +1,9 @@
package promise package promise
import ( import (
"github.com/status-im/status-go/geth/jail/internal/loop" "github.com/status-im/status-go/jail/internal/loop"
"github.com/status-im/status-go/geth/jail/internal/timers" "github.com/status-im/status-go/jail/internal/timers"
"github.com/status-im/status-go/geth/jail/internal/vm" "github.com/status-im/status-go/jail/internal/vm"
) )
//Define jail promise //Define jail promise

View File

@ -7,9 +7,9 @@ import (
"github.com/stretchr/testify/suite" "github.com/stretchr/testify/suite"
"github.com/status-im/status-go/geth/jail/internal/loop" "github.com/status-im/status-go/jail/internal/loop"
"github.com/status-im/status-go/geth/jail/internal/promise" "github.com/status-im/status-go/jail/internal/promise"
"github.com/status-im/status-go/geth/jail/internal/vm" "github.com/status-im/status-go/jail/internal/vm"
) )
func (s *PromiseSuite) TestResolve() { func (s *PromiseSuite) TestResolve() {

View File

@ -4,8 +4,8 @@ import (
"time" "time"
"github.com/robertkrimen/otto" "github.com/robertkrimen/otto"
"github.com/status-im/status-go/geth/jail/internal/loop" "github.com/status-im/status-go/jail/internal/loop"
"github.com/status-im/status-go/geth/jail/internal/vm" "github.com/status-im/status-go/jail/internal/vm"
) )
type timerTask struct { type timerTask struct {

View File

@ -5,8 +5,8 @@ import (
"github.com/robertkrimen/otto" "github.com/robertkrimen/otto"
"github.com/status-im/status-go/geth/jail/internal/loop" "github.com/status-im/status-go/jail/internal/loop"
"github.com/status-im/status-go/geth/jail/internal/vm" "github.com/status-im/status-go/jail/internal/vm"
) )
// Define jail timers // Define jail timers

View File

@ -5,9 +5,9 @@ import (
"testing" "testing"
"time" "time"
"github.com/status-im/status-go/geth/jail/internal/loop" "github.com/status-im/status-go/jail/internal/loop"
"github.com/status-im/status-go/geth/jail/internal/timers" "github.com/status-im/status-go/jail/internal/timers"
"github.com/status-im/status-go/geth/jail/internal/vm" "github.com/status-im/status-go/jail/internal/vm"
"github.com/stretchr/testify/suite" "github.com/stretchr/testify/suite"
) )

View File

@ -9,7 +9,7 @@ import (
"github.com/robertkrimen/otto" "github.com/robertkrimen/otto"
web3js "github.com/status-im/go-web3js" web3js "github.com/status-im/go-web3js"
"github.com/status-im/status-go/geth/rpc" "github.com/status-im/status-go/rpc"
) )
const ( const (

View File

@ -5,7 +5,7 @@ import (
"testing" "testing"
"github.com/robertkrimen/otto" "github.com/robertkrimen/otto"
"github.com/status-im/status-go/geth/rpc" "github.com/status-im/status-go/rpc"
"github.com/stretchr/testify/suite" "github.com/stretchr/testify/suite"
) )

View File

@ -8,8 +8,8 @@ import (
"github.com/NaySoftware/go-fcm" "github.com/NaySoftware/go-fcm"
"github.com/ethereum/go-ethereum/log" "github.com/ethereum/go-ethereum/log"
"github.com/status-im/status-go/geth/params"
"github.com/status-im/status-go/logutils" "github.com/status-im/status-go/logutils"
"github.com/status-im/status-go/params"
"github.com/status-im/status-go/profiling" "github.com/status-im/status-go/profiling"
"github.com/status-im/status-go/sign" "github.com/status-im/status-go/sign"
"gopkg.in/go-playground/validator.v9" "gopkg.in/go-playground/validator.v9"

View File

@ -31,13 +31,13 @@ import (
gethparams "github.com/ethereum/go-ethereum/params" gethparams "github.com/ethereum/go-ethereum/params"
"github.com/stretchr/testify/require" "github.com/stretchr/testify/require"
"github.com/status-im/status-go/geth/account" "github.com/status-im/status-go/account"
"github.com/status-im/status-go/geth/params" "github.com/status-im/status-go/params"
"github.com/status-im/status-go/geth/transactions"
"github.com/status-im/status-go/sign" "github.com/status-im/status-go/sign"
"github.com/status-im/status-go/signal" "github.com/status-im/status-go/signal"
"github.com/status-im/status-go/static" "github.com/status-im/status-go/static"
. "github.com/status-im/status-go/t/utils" //nolint: golint . "github.com/status-im/status-go/t/utils" //nolint: golint
"github.com/status-im/status-go/transactions"
) )
const initJS = ` const initJS = `

View File

@ -1,6 +1,6 @@
package main package main
import "github.com/status-im/status-go/geth/api" import "github.com/status-im/status-go/api"
var statusAPI = api.NewStatusAPI() var statusAPI = api.NewStatusAPI()

View File

@ -29,7 +29,7 @@ import (
"github.com/ethereum/go-ethereum/metrics" "github.com/ethereum/go-ethereum/metrics"
"github.com/ethereum/go-ethereum/rlp" "github.com/ethereum/go-ethereum/rlp"
whisper "github.com/ethereum/go-ethereum/whisper/whisperv6" whisper "github.com/ethereum/go-ethereum/whisper/whisperv6"
"github.com/status-im/status-go/geth/params" "github.com/status-im/status-go/params"
"github.com/syndtr/goleveldb/leveldb" "github.com/syndtr/goleveldb/leveldb"
"github.com/syndtr/goleveldb/leveldb/util" "github.com/syndtr/goleveldb/leveldb/util"
) )

View File

@ -29,7 +29,7 @@ import (
"github.com/ethereum/go-ethereum/crypto" "github.com/ethereum/go-ethereum/crypto"
"github.com/ethereum/go-ethereum/rlp" "github.com/ethereum/go-ethereum/rlp"
whisper "github.com/ethereum/go-ethereum/whisper/whisperv6" whisper "github.com/ethereum/go-ethereum/whisper/whisperv6"
"github.com/status-im/status-go/geth/params" "github.com/status-im/status-go/params"
"github.com/stretchr/testify/suite" "github.com/stretchr/testify/suite"
) )

View File

@ -20,9 +20,9 @@ import (
"github.com/ethereum/go-ethereum/p2p/discv5" "github.com/ethereum/go-ethereum/p2p/discv5"
"github.com/ethereum/go-ethereum/p2p/nat" "github.com/ethereum/go-ethereum/p2p/nat"
whisper "github.com/ethereum/go-ethereum/whisper/whisperv6" whisper "github.com/ethereum/go-ethereum/whisper/whisperv6"
"github.com/status-im/status-go/geth/params"
"github.com/status-im/status-go/mailserver" "github.com/status-im/status-go/mailserver"
shhmetrics "github.com/status-im/status-go/metrics/whisper" shhmetrics "github.com/status-im/status-go/metrics/whisper"
"github.com/status-im/status-go/params"
"github.com/status-im/status-go/services/personal" "github.com/status-im/status-go/services/personal"
"github.com/status-im/status-go/services/shhext" "github.com/status-im/status-go/services/shhext"
"github.com/status-im/status-go/services/status" "github.com/status-im/status-go/services/status"
@ -40,7 +40,7 @@ var (
) )
// All general log messages in this package should be routed through this logger. // All general log messages in this package should be routed through this logger.
var logger = log.New("package", "status-go/geth/node") var logger = log.New("package", "status-go/node")
// MakeNode create a geth node entity // MakeNode create a geth node entity
func MakeNode(config *params.NodeConfig, db *leveldb.DB) (*node.Node, error) { func MakeNode(config *params.NodeConfig, db *leveldb.DB) (*node.Node, error) {

View File

@ -5,7 +5,7 @@ import (
whisper "github.com/ethereum/go-ethereum/whisper/whisperv6" whisper "github.com/ethereum/go-ethereum/whisper/whisperv6"
"github.com/status-im/status-go/geth/params" "github.com/status-im/status-go/params"
"github.com/stretchr/testify/require" "github.com/stretchr/testify/require"
) )

View File

@ -18,10 +18,10 @@ import (
whisper "github.com/ethereum/go-ethereum/whisper/whisperv6" whisper "github.com/ethereum/go-ethereum/whisper/whisperv6"
"github.com/syndtr/goleveldb/leveldb" "github.com/syndtr/goleveldb/leveldb"
"github.com/status-im/status-go/geth/db" "github.com/status-im/status-go/db"
"github.com/status-im/status-go/geth/params" "github.com/status-im/status-go/params"
"github.com/status-im/status-go/geth/peers" "github.com/status-im/status-go/peers"
"github.com/status-im/status-go/geth/rpc" "github.com/status-im/status-go/rpc"
"github.com/status-im/status-go/services/status" "github.com/status-im/status-go/services/status"
) )
@ -57,7 +57,7 @@ type StatusNode struct {
// New makes new instance of StatusNode. // New makes new instance of StatusNode.
func New() *StatusNode { func New() *StatusNode {
return &StatusNode{ return &StatusNode{
log: log.New("package", "status-go/geth/node.StatusNode"), log: log.New("package", "status-go/node.StatusNode"),
} }
} }

View File

@ -10,8 +10,8 @@ import (
"github.com/ethereum/go-ethereum/p2p" "github.com/ethereum/go-ethereum/p2p"
"github.com/ethereum/go-ethereum/rpc" "github.com/ethereum/go-ethereum/rpc"
"github.com/status-im/status-go/geth/node" "github.com/status-im/status-go/node"
"github.com/status-im/status-go/geth/params" "github.com/status-im/status-go/params"
) )
type TestServiceAPI struct{} type TestServiceAPI struct{}

View File

@ -16,7 +16,7 @@ import (
"github.com/ethereum/go-ethereum/p2p/discover" "github.com/ethereum/go-ethereum/p2p/discover"
whisper "github.com/ethereum/go-ethereum/whisper/whisperv6" whisper "github.com/ethereum/go-ethereum/whisper/whisperv6"
"github.com/status-im/status-go/geth/params" "github.com/status-im/status-go/params"
"github.com/stretchr/testify/require" "github.com/stretchr/testify/require"
) )

View File

@ -1,5 +1,5 @@
// Code generated by MockGen. DO NOT EDIT. // Code generated by MockGen. DO NOT EDIT.
// Source: geth/notifications/push/fcm/client.go // Source: notifications/push/fcm/client.go
// Package fcm is a generated GoMock package. // Package fcm is a generated GoMock package.
package fcm package fcm

View File

@ -332,7 +332,7 @@ func NewNodeConfig(dataDir string, clstrCfgFile string, networkID uint64) (*Node
MaxPeers: MaxPeers, MaxPeers: MaxPeers,
MaxPendingPeers: MaxPendingPeers, MaxPendingPeers: MaxPendingPeers,
IPCFile: IPCFile, IPCFile: IPCFile,
log: log.New("package", "status-go/geth/params.NodeConfig"), log: log.New("package", "status-go/params.NodeConfig"),
LogFile: LogFile, LogFile: LogFile,
LogLevel: LogLevel, LogLevel: LogLevel,
LogToStderr: LogToStderr, LogToStderr: LogToStderr,

View File

@ -13,7 +13,7 @@ import (
"github.com/ethereum/go-ethereum/core" "github.com/ethereum/go-ethereum/core"
gethparams "github.com/ethereum/go-ethereum/params" gethparams "github.com/ethereum/go-ethereum/params"
"github.com/status-im/status-go/geth/params" "github.com/status-im/status-go/params"
"github.com/stretchr/testify/require" "github.com/stretchr/testify/require"
) )

View File

@ -16,7 +16,7 @@ const (
) )
// VersionMeta is metadata to append to the version string // VersionMeta is metadata to append to the version string
var VersionMeta string // rely on linker: -ldflags -X github.com/status-im/status-go/geth/params.VersionMeta" var VersionMeta string // rely on linker: -ldflags -X github.com/status-im/status-go/params.VersionMeta"
// Version exposes string representation of program version. // Version exposes string representation of program version.
var Version = fmt.Sprintf("%d.%d.%d-%s", VersionMajor, VersionMinor, VersionPatch, VersionMeta) var Version = fmt.Sprintf("%d.%d.%d-%s", VersionMajor, VersionMinor, VersionPatch, VersionMeta)

View File

@ -3,7 +3,7 @@ package peers
import ( import (
"github.com/ethereum/go-ethereum/log" "github.com/ethereum/go-ethereum/log"
"github.com/ethereum/go-ethereum/p2p/discv5" "github.com/ethereum/go-ethereum/p2p/discv5"
"github.com/status-im/status-go/geth/db" "github.com/status-im/status-go/db"
"github.com/syndtr/goleveldb/leveldb" "github.com/syndtr/goleveldb/leveldb"
"github.com/syndtr/goleveldb/leveldb/util" "github.com/syndtr/goleveldb/leveldb/util"
) )

View File

@ -12,7 +12,7 @@ import (
"github.com/ethereum/go-ethereum/p2p/discover" "github.com/ethereum/go-ethereum/p2p/discover"
"github.com/ethereum/go-ethereum/p2p/discv5" "github.com/ethereum/go-ethereum/p2p/discv5"
"github.com/status-im/status-go/geth/params" "github.com/status-im/status-go/params"
"github.com/status-im/status-go/signal" "github.com/status-im/status-go/signal"
) )

View File

@ -17,7 +17,7 @@ import (
"github.com/stretchr/testify/require" "github.com/stretchr/testify/require"
"github.com/stretchr/testify/suite" "github.com/stretchr/testify/suite"
"github.com/status-im/status-go/geth/params" "github.com/status-im/status-go/params"
"github.com/status-im/status-go/signal" "github.com/status-im/status-go/signal"
// to access logs in the test with `-log` flag // to access logs in the test with `-log` flag

Some files were not shown because too many files have changed in this diff Show More