Skip to content

Commit

Permalink
DEX-356 Release 1.0.1 (#20)
Browse files Browse the repository at this point in the history
* Fixed an incompatibility with Node;
* Exact NODE's version dependency;
  • Loading branch information
vsuharnikov authored and koloale committed Jul 23, 2019
1 parent a7d7446 commit 1c27430
Show file tree
Hide file tree
Showing 8 changed files with 11 additions and 11 deletions.
2 changes: 1 addition & 1 deletion build.sbt
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import sbt.internal.inc.ReflectUtilities

addCompilerPlugin("org.scalamacros" % "paradise" % "2.1.0" cross CrossVersion.full)

def nodeVersionTag: String = "v1.0.1"
def nodeVersionTag: String = "v1.0.2"

lazy val node = ProjectRef(uri(s"git://github.com/wavesplatform/Waves.git#$nodeVersionTag"), "node")

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package com.wavesplatform.it.sync.smartcontracts

import com.wavesplatform.api.http.TransactionNotAllowedByAccountScript
import com.wavesplatform.api.http.ApiError.TransactionNotAllowedByAccountScript
import com.wavesplatform.common.state.ByteStr
import com.wavesplatform.it.MatcherSuiteBase
import com.wavesplatform.it.api.SyncHttpApi._
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ package com.wavesplatform.it.sync.smartcontracts

import com.typesafe.config.{Config, ConfigFactory}
import com.wavesplatform.account.AddressScheme
import com.wavesplatform.api.http.TransactionNotAllowedByAssetScript
import com.wavesplatform.api.http.ApiError.TransactionNotAllowedByAssetScript
import com.wavesplatform.common.utils.EitherExt2
import com.wavesplatform.features.BlockchainFeatures
import com.wavesplatform.it.MatcherSuiteBase
Expand Down Expand Up @@ -207,7 +207,7 @@ object OrdersFromScriptedAssetTestSuite {
}

private val AllowAsset = mkAllowAsset(0)
private val AllowAssetId = AllowAsset.id().toString
private val AllowAssetId = AllowAsset.id().toString
private val AllowAsset2 = mkAllowAsset(1)
private val AllowAsset2Id = AllowAsset2.id().toString
private val AllowAsset3 = mkAllowAsset(1)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ case class MatcherApiRoute(assetPairBuilder: AssetPairBuilder,
private def withCancelRequest(f: CancelOrderRequest => Route): Route =
post {
entity(as[CancelOrderRequest]) { req =>
if (req.isSignatureValid()) f(req) else complete(CancelRequestInvalidSignature)
if (req.isSignatureValid()) f(req) else complete(InvalidSignature)
} ~ complete(StatusCodes.BadRequest)
} ~ complete(StatusCodes.MethodNotAllowed)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ case class BatchCancelCompleted(orders: Map[Order.Id, MatcherResponse])

case class OrderRejected(error: MatcherError) extends MatcherResponse(C.BadRequest, error)
case class OrderCancelRejected(error: MatcherError) extends MatcherResponse(C.BadRequest, error)
case object CancelRequestInvalidSignature extends MatcherResponse(C.BadRequest, error.RequestInvalidSignature)
case object InvalidSignature extends MatcherResponse(C.BadRequest, error.RequestInvalidSignature)
case class NotImplemented(error: MatcherError) extends MatcherResponse(C.NotImplemented, error)
case class OrderBookUnavailable(error: MatcherError) extends MatcherResponse(C.ServiceUnavailable, error)
case object DuringStart extends MatcherResponse(C.ServiceUnavailable, error.MatcherIsStarting)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ import com.wavesplatform.transaction.assets.IssueTransaction
import com.wavesplatform.transaction.assets.exchange.Order
import com.wavesplatform.transaction.lease.LeaseTransaction
import com.wavesplatform.transaction.smart.BlockchainContext
import com.wavesplatform.transaction.transfer.TransferTransaction
import com.wavesplatform.transaction.{Asset, Transaction, TransactionParser}
import com.wavesplatform.utils.CloseableIterator
import monix.eval.Coeval
Expand Down Expand Up @@ -120,6 +121,8 @@ object MatcherContext {
* @note Portfolios passed to `pf` only contain Waves and Leasing balances to improve performance */
override def collectLposPortfolios[A](pf: PartialFunction[(Address, Portfolio), A]): Map[Address, A] = kill("collectLposPortfolios")
override def invokeScriptResult(txId: TransactionId): Either[ValidationError, InvokeScriptResult] = kill("invokeScriptResult")

override def transferById(id: BlockId): Option[(Int, TransferTransaction)] = kill("transferById")
}

}
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ class MatcherApiRouteSpec extends RouteSpec("/matcher") with RequestGen with Pat
mkGet(route)(Base58.encode(publicKey), ts, ";;") ~> check {
status shouldBe StatusCodes.BadRequest
val message = (responseAs[JsValue] \ "message").as[JsString]
message.value shouldEqual "invalid signature"
message.value shouldEqual "The request has an invalid signature"
}
}

Expand Down
5 changes: 1 addition & 4 deletions project/ExtensionPackaging.scala
Original file line number Diff line number Diff line change
Expand Up @@ -51,10 +51,7 @@ object ExtensionPackaging extends AutoPlugin {
},
classpath := makeRelativeClasspathNames(classpathOrdering.value),
nodePackageName := s"waves${network.value.packageSuffix}",
debianPackageDependencies := Seq(
s"${nodePackageName.value} (>= ${nodeVersion.value})",
s"${nodePackageName.value} (<= ${mostSupportedVersion(nodeVersion.value)})"
),
debianPackageDependencies := Seq(s"${nodePackageName.value} (= ${nodeVersion.value})"),
// To write files to Waves NODE directory
linuxPackageMappings := getUniversalFolderMappings(
nodePackageName.value,
Expand Down

0 comments on commit 1c27430

Please sign in to comment.