Skip to content
This repository has been archived by the owner on Nov 2, 2018. It is now read-only.

Commit

Permalink
Merge branch 'master' into offline-signing
Browse files Browse the repository at this point in the history
  • Loading branch information
lukechampine committed May 14, 2018
2 parents c1c14d7 + f4678bf commit 4732acc
Show file tree
Hide file tree
Showing 170 changed files with 6,056 additions and 1,565 deletions.
11 changes: 9 additions & 2 deletions CHANGELOG.md
@@ -1,16 +1,23 @@
Version History
---------------

May 2018:

v1.3.3 (patch release)
- Add Streaming API endpoints
- Faster contract formation
- Improved wallet scaling

March 2018:

v1.3.2 (minor release)
v1.3.2 (patch release)
- Improve renter throughput and stability
- Reduce host I/O when idle
- Add /tpool/confirmed endpoint

December 2017:

v1.3.1 (minor release)
v1.3.1 (patch release)
- Add new efficient, reliable contract format
- Faster and smoother file repairs
- Fix difficulty adjustment hardfork
Expand Down
15 changes: 7 additions & 8 deletions Makefile
Expand Up @@ -91,7 +91,7 @@ release-race:
# clean removes all directories that get automatically created during
# development.
clean:
rm -rf release doc/whitepaper.aux doc/whitepaper.log doc/whitepaper.pdf
rm -rf cover doc/whitepaper.aux doc/whitepaper.log doc/whitepaper.pdf release

test:
go test -short -tags='debug testing netgo' -timeout=5s $(pkgs) -run=$(run)
Expand All @@ -108,13 +108,12 @@ test-mem:
bench: clean fmt
go test -tags='debug testing netgo' -timeout=500s -run=XXX -bench=$(run) $(pkgs)
cover: clean
@mkdir -p cover/modules
@mkdir -p cover/modules/renter
@mkdir -p cover/modules/host
@for package in $(pkgs); do \
go test -tags='testing debug' -timeout=500s -covermode=atomic -coverprofile=cover/$$package.out ./$$package -run=$(run) \
&& go tool cover -html=cover/$$package.out -o=cover/$$package.html \
&& rm cover/$$package.out ; \
@mkdir -p cover
@for package in $(pkgs); do \
mkdir -p `dirname cover/$$package` \
&& go test -tags='testing debug netgo' -timeout=500s -covermode=atomic -coverprofile=cover/$$package.out ./$$package -run=$(run) \
&& go tool cover -html=cover/$$package.out -o=cover/$$package.html \
&& rm cover/$$package.out ; \
done

# whitepaper builds the whitepaper from whitepaper.tex. pdflatex has to be
Expand Down
2 changes: 1 addition & 1 deletion README.md
@@ -1,4 +1,4 @@
# [![Sia Logo](http://sia.tech/img/svg/sia-green-logo.svg)](http://sia.tech) v1.3.2 (Capricorn)
# [![Sia Logo](http://sia.tech/img/svg/sia-green-logo.svg)](http://sia.tech) v1.3.3 (Capricorn)

[![Build Status](https://travis-ci.org/NebulousLabs/Sia.svg?branch=master)](https://travis-ci.org/NebulousLabs/Sia)
[![GoDoc](https://godoc.org/github.com/NebulousLabs/Sia?status.svg)](https://godoc.org/github.com/NebulousLabs/Sia)
Expand Down
2 changes: 1 addition & 1 deletion build/version.go
Expand Up @@ -14,7 +14,7 @@ const (
MaxEncodedVersionLength = 100

// Version is the current version of siad.
Version = "1.3.2"
Version = "1.3.3"
)

// IsVersion returns whether str is a valid version number.
Expand Down
4 changes: 1 addition & 3 deletions cmd/siac/consensuscmd.go
Expand Up @@ -6,7 +6,6 @@ import (

"github.com/spf13/cobra"

"github.com/NebulousLabs/Sia/node/api"
"github.com/NebulousLabs/Sia/types"
)

Expand All @@ -22,8 +21,7 @@ var (
// consensuscmd is the handler for the command `siac consensus`.
// Prints the current state of consensus.
func consensuscmd() {
var cg api.ConsensusGET
err := getAPI("/consensus", &cg)
cg, err := httpClient.ConsensusGet()
if err != nil {
die("Could not get current consensus state:", err)
}
Expand Down
19 changes: 5 additions & 14 deletions cmd/siac/daemoncmd.go
Expand Up @@ -4,7 +4,6 @@ import (
"fmt"

"github.com/NebulousLabs/Sia/build"
"github.com/NebulousLabs/Sia/node/api"
"github.com/spf13/cobra"
)

Expand Down Expand Up @@ -38,11 +37,6 @@ var (
}
)

type updateInfo struct {
Available bool `json:"available"`
Version string `json:"version"`
}

// version prints the version of siac and siad.
func versioncmd() {
fmt.Println("Sia Client")
Expand All @@ -51,8 +45,7 @@ func versioncmd() {
fmt.Println("\tGit Revision " + build.GitRevision)
fmt.Println("\tBuild Time " + build.BuildTime)
}
var dvg api.DaemonVersionGet
err := getAPI("/daemon/version", &dvg)
dvg, err := httpClient.DaemonVersionGet()
if err != nil {
fmt.Println("Could not get daemon version:", err)
return
Expand All @@ -68,16 +61,15 @@ func versioncmd() {
// stopcmd is the handler for the command `siac stop`.
// Stops the daemon.
func stopcmd() {
err := get("/daemon/stop")
err := httpClient.DaemonStopGet()
if err != nil {
die("Could not stop daemon:", err)
}
fmt.Println("Sia daemon stopped.")
}

func updatecmd() {
var update updateInfo
err := getAPI("/daemon/update", &update)
update, err := httpClient.DaemonUpdateGet()
if err != nil {
fmt.Println("Could not check for update:", err)
return
Expand All @@ -87,7 +79,7 @@ func updatecmd() {
return
}

err = post("/daemon/update", "")
err = httpClient.DaemonUpdatePost()
if err != nil {
fmt.Println("Could not apply update:", err)
return
Expand All @@ -96,8 +88,7 @@ func updatecmd() {
}

func updatecheckcmd() {
var update updateInfo
err := getAPI("/daemon/update", &update)
update, err := httpClient.DaemonUpdateGet()
if err != nil {
fmt.Println("Could not check for update:", err)
return
Expand Down
4 changes: 1 addition & 3 deletions cmd/siac/export.go
Expand Up @@ -5,7 +5,6 @@ import (
"fmt"
"os"

"github.com/NebulousLabs/Sia/node/api"
"github.com/NebulousLabs/Sia/types"

"github.com/spf13/cobra"
Expand All @@ -31,8 +30,7 @@ var (
// renterexportcontracttxnscmd is the handler for the command `siac renter export contract-txns`.
// Exports the current contract set to JSON.
func renterexportcontracttxnscmd(destination string) {
var cs api.RenterContracts
err := getAPI("/renter/contracts", &cs)
cs, err := httpClient.RenterContractsGet()
if err != nil {
die("Could not retrieve contracts:", err)
}
Expand Down
16 changes: 6 additions & 10 deletions cmd/siac/gatewaycmd.go
Expand Up @@ -5,9 +5,8 @@ import (
"os"
"text/tabwriter"

"github.com/NebulousLabs/Sia/modules"
"github.com/spf13/cobra"

"github.com/NebulousLabs/Sia/node/api"
)

var (
Expand Down Expand Up @@ -50,7 +49,7 @@ var (
// gatewayconnectcmd is the handler for the command `siac gateway add [address]`.
// Adds a new peer to the peer list.
func gatewayconnectcmd(addr string) {
err := post("/gateway/connect/"+addr, "")
err := httpClient.GatewayConnectPost(modules.NetAddress(addr))
if err != nil {
die("Could not add peer:", err)
}
Expand All @@ -60,7 +59,7 @@ func gatewayconnectcmd(addr string) {
// gatewaydisconnectcmd is the handler for the command `siac gateway remove [address]`.
// Removes a peer from the peer list.
func gatewaydisconnectcmd(addr string) {
err := post("/gateway/disconnect/"+addr, "")
err := httpClient.GatewayDisconnectPost(modules.NetAddress(addr))
if err != nil {
die("Could not remove peer:", err)
}
Expand All @@ -70,8 +69,7 @@ func gatewaydisconnectcmd(addr string) {
// gatewayaddresscmd is the handler for the command `siac gateway address`.
// Prints the gateway's network address.
func gatewayaddresscmd() {
var info api.GatewayGET
err := getAPI("/gateway", &info)
info, err := httpClient.GatewayGet()
if err != nil {
die("Could not get gateway address:", err)
}
Expand All @@ -81,8 +79,7 @@ func gatewayaddresscmd() {
// gatewaycmd is the handler for the command `siac gateway`.
// Prints the gateway's network address and number of peers.
func gatewaycmd() {
var info api.GatewayGET
err := getAPI("/gateway", &info)
info, err := httpClient.GatewayGet()
if err != nil {
die("Could not get gateway address:", err)
}
Expand All @@ -93,8 +90,7 @@ func gatewaycmd() {
// gatewaylistcmd is the handler for the command `siac gateway list`.
// Prints a list of all peers.
func gatewaylistcmd() {
var info api.GatewayGET
err := getAPI("/gateway", &info)
info, err := httpClient.GatewayGet()
if err != nil {
die("Could not get peer list:", err)
}
Expand Down

0 comments on commit 4732acc

Please sign in to comment.