mirror of
https://github.com/cosmos/cosmjs.git
synced 2025-03-10 21:49:15 +00:00
Merge branch '0.28'
This commit is contained in:
commit
70e0549ed7
@ -53,6 +53,12 @@ and this project adheres to
|
|||||||
[#1168]: https://github.com/cosmos/cosmjs/pull/1168
|
[#1168]: https://github.com/cosmos/cosmjs/pull/1168
|
||||||
[#1133]: https://github.com/cosmos/cosmjs/issues/1133
|
[#1133]: https://github.com/cosmos/cosmjs/issues/1133
|
||||||
|
|
||||||
|
## [0.28.11] - 2022-07-13
|
||||||
|
|
||||||
|
### Fixed
|
||||||
|
|
||||||
|
- @cosmjs/faucet: Fix cooldown value from 86 seconds to 24 hours.
|
||||||
|
|
||||||
## [0.28.10] - 2022-06-29
|
## [0.28.10] - 2022-06-29
|
||||||
|
|
||||||
### Fixed
|
### Fixed
|
||||||
@ -978,7 +984,8 @@ CHANGELOG entries missing. Please see [the diff][0.24.1].
|
|||||||
`FeeTable`. @cosmjs/cosmwasm has its own `FeeTable` with those properties.
|
`FeeTable`. @cosmjs/cosmwasm has its own `FeeTable` with those properties.
|
||||||
- @cosmjs/sdk38: Rename package to @cosmjs/launchpad.
|
- @cosmjs/sdk38: Rename package to @cosmjs/launchpad.
|
||||||
|
|
||||||
[unreleased]: https://github.com/cosmos/cosmjs/compare/v0.28.10...HEAD
|
[unreleased]: https://github.com/cosmos/cosmjs/compare/v0.28.11...HEAD
|
||||||
|
[0.28.11]: https://github.com/cosmos/cosmjs/compare/v0.28.10...v0.28.11
|
||||||
[0.28.10]: https://github.com/cosmos/cosmjs/compare/v0.28.9...v0.28.10
|
[0.28.10]: https://github.com/cosmos/cosmjs/compare/v0.28.9...v0.28.10
|
||||||
[0.28.9]: https://github.com/cosmos/cosmjs/compare/v0.28.8...v0.28.9
|
[0.28.9]: https://github.com/cosmos/cosmjs/compare/v0.28.8...v0.28.9
|
||||||
[0.28.8]: https://github.com/cosmos/cosmjs/compare/v0.28.7...v0.28.8
|
[0.28.8]: https://github.com/cosmos/cosmjs/compare/v0.28.7...v0.28.8
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@cosmjs/amino",
|
"name": "@cosmjs/amino",
|
||||||
"version": "0.28.10",
|
"version": "0.28.11",
|
||||||
"description": "Helpers for Amino based signing.",
|
"description": "Helpers for Amino based signing.",
|
||||||
"contributors": [
|
"contributors": [
|
||||||
"Simon Warta <webmaster128@users.noreply.github.com>"
|
"Simon Warta <webmaster128@users.noreply.github.com>"
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@cosmjs/cli",
|
"name": "@cosmjs/cli",
|
||||||
"version": "0.28.10",
|
"version": "0.28.11",
|
||||||
"description": "Command line interface",
|
"description": "Command line interface",
|
||||||
"contributors": [
|
"contributors": [
|
||||||
"IOV SAS <admin@iov.one>",
|
"IOV SAS <admin@iov.one>",
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@cosmjs/cosmwasm-stargate",
|
"name": "@cosmjs/cosmwasm-stargate",
|
||||||
"version": "0.28.10",
|
"version": "0.28.11",
|
||||||
"description": "CosmWasm SDK",
|
"description": "CosmWasm SDK",
|
||||||
"contributors": [
|
"contributors": [
|
||||||
"Will Clark <willclarktech@users.noreply.github.com>"
|
"Will Clark <willclarktech@users.noreply.github.com>"
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@cosmjs/crypto",
|
"name": "@cosmjs/crypto",
|
||||||
"version": "0.28.10",
|
"version": "0.28.11",
|
||||||
"description": "Cryptography resources for blockchain projects",
|
"description": "Cryptography resources for blockchain projects",
|
||||||
"contributors": [
|
"contributors": [
|
||||||
"IOV SAS <admin@iov.one>",
|
"IOV SAS <admin@iov.one>",
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@cosmjs/encoding",
|
"name": "@cosmjs/encoding",
|
||||||
"version": "0.28.10",
|
"version": "0.28.11",
|
||||||
"description": "Encoding helpers for blockchain projects",
|
"description": "Encoding helpers for blockchain projects",
|
||||||
"contributors": [
|
"contributors": [
|
||||||
"IOV SAS <admin@iov.one>"
|
"IOV SAS <admin@iov.one>"
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@cosmjs/faucet-client",
|
"name": "@cosmjs/faucet-client",
|
||||||
"version": "0.28.10",
|
"version": "0.28.11",
|
||||||
"description": "The faucet client",
|
"description": "The faucet client",
|
||||||
"contributors": [
|
"contributors": [
|
||||||
"Will Clark <willclarktech@users.noreply.github.com>"
|
"Will Clark <willclarktech@users.noreply.github.com>"
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@cosmjs/faucet",
|
"name": "@cosmjs/faucet",
|
||||||
"version": "0.28.10",
|
"version": "0.28.11",
|
||||||
"description": "The faucet",
|
"description": "The faucet",
|
||||||
"contributors": [
|
"contributors": [
|
||||||
"Ethan Frey <ethanfrey@users.noreply.github.com>",
|
"Ethan Frey <ethanfrey@users.noreply.github.com>",
|
||||||
|
@ -67,10 +67,11 @@ export class Webserver {
|
|||||||
|
|
||||||
const entry = this.addressCounter.get(address);
|
const entry = this.addressCounter.get(address);
|
||||||
if (entry !== undefined) {
|
if (entry !== undefined) {
|
||||||
if (entry.getTime() + 24 * 3600 > Date.now()) {
|
const cooldownMs = constants.cooldown * 3600 * 1000;
|
||||||
|
if (entry.getTime() + cooldownMs > Date.now()) {
|
||||||
throw new HttpError(
|
throw new HttpError(
|
||||||
405,
|
405,
|
||||||
"Too many request from the same address. Blocked to prevent draining. Please wait 24h and try it again!",
|
`Too many request for the same address. Blocked to prevent draining. Please wait ${constants.cooldown}h and try it again!`,
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -17,3 +17,4 @@ export const pathPattern = process.env.FAUCET_PATH_PATTERN || "m/44'/118'/0'/0/a
|
|||||||
export const tokenConfig: TokenConfiguration = {
|
export const tokenConfig: TokenConfiguration = {
|
||||||
bankTokens: parseBankTokens(process.env.FAUCET_TOKENS || "ucosm, ustake"),
|
bankTokens: parseBankTokens(process.env.FAUCET_TOKENS || "ucosm, ustake"),
|
||||||
};
|
};
|
||||||
|
export const cooldown = 24; // hours
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@cosmjs/json-rpc",
|
"name": "@cosmjs/json-rpc",
|
||||||
"version": "0.28.10",
|
"version": "0.28.11",
|
||||||
"description": "Framework for implementing a JSON-RPC 2.0 API",
|
"description": "Framework for implementing a JSON-RPC 2.0 API",
|
||||||
"contributors": [
|
"contributors": [
|
||||||
"IOV SAS <admin@iov.one>",
|
"IOV SAS <admin@iov.one>",
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@cosmjs/ledger-amino",
|
"name": "@cosmjs/ledger-amino",
|
||||||
"version": "0.28.10",
|
"version": "0.28.11",
|
||||||
"description": "A library for signing Amino-encoded transactions using Ledger devices",
|
"description": "A library for signing Amino-encoded transactions using Ledger devices",
|
||||||
"contributors": [
|
"contributors": [
|
||||||
"Will Clark <willclarktech@users.noreply.github.com>"
|
"Will Clark <willclarktech@users.noreply.github.com>"
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@cosmjs/math",
|
"name": "@cosmjs/math",
|
||||||
"version": "0.28.10",
|
"version": "0.28.11",
|
||||||
"description": "Math helpers for blockchain projects",
|
"description": "Math helpers for blockchain projects",
|
||||||
"contributors": [
|
"contributors": [
|
||||||
"IOV SAS <admin@iov.one>"
|
"IOV SAS <admin@iov.one>"
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@cosmjs/proto-signing",
|
"name": "@cosmjs/proto-signing",
|
||||||
"version": "0.28.10",
|
"version": "0.28.11",
|
||||||
"description": "Utilities for protobuf based signing (Cosmos SDK 0.40+)",
|
"description": "Utilities for protobuf based signing (Cosmos SDK 0.40+)",
|
||||||
"contributors": [
|
"contributors": [
|
||||||
"Will Clark <willclarktech@users.noreply.github.com>",
|
"Will Clark <willclarktech@users.noreply.github.com>",
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@cosmjs/socket",
|
"name": "@cosmjs/socket",
|
||||||
"version": "0.28.10",
|
"version": "0.28.11",
|
||||||
"description": "Utility functions for working with WebSockets",
|
"description": "Utility functions for working with WebSockets",
|
||||||
"contributors": [
|
"contributors": [
|
||||||
"IOV SAS <admin@iov.one>",
|
"IOV SAS <admin@iov.one>",
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@cosmjs/stargate",
|
"name": "@cosmjs/stargate",
|
||||||
"version": "0.28.10",
|
"version": "0.28.11",
|
||||||
"description": "Utilities for Cosmos SDK 0.40",
|
"description": "Utilities for Cosmos SDK 0.40",
|
||||||
"contributors": [
|
"contributors": [
|
||||||
"Simon Warta <webmaster128@users.noreply.github.com>"
|
"Simon Warta <webmaster128@users.noreply.github.com>"
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@cosmjs/stream",
|
"name": "@cosmjs/stream",
|
||||||
"version": "0.28.10",
|
"version": "0.28.11",
|
||||||
"description": "Utility functions for producing and consuming streams",
|
"description": "Utility functions for producing and consuming streams",
|
||||||
"contributors": [
|
"contributors": [
|
||||||
"IOV SAS <admin@iov.one>",
|
"IOV SAS <admin@iov.one>",
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@cosmjs/tendermint-rpc",
|
"name": "@cosmjs/tendermint-rpc",
|
||||||
"version": "0.28.10",
|
"version": "0.28.11",
|
||||||
"description": "Tendermint RPC clients",
|
"description": "Tendermint RPC clients",
|
||||||
"contributors": [
|
"contributors": [
|
||||||
"IOV SAS <admin@iov.one>",
|
"IOV SAS <admin@iov.one>",
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "@cosmjs/utils",
|
"name": "@cosmjs/utils",
|
||||||
"version": "0.28.10",
|
"version": "0.28.11",
|
||||||
"description": "Utility tools, primarily for testing code",
|
"description": "Utility tools, primarily for testing code",
|
||||||
"contributors": [
|
"contributors": [
|
||||||
"IOV SAS <admin@iov.one>"
|
"IOV SAS <admin@iov.one>"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user