There was an error compiling your contract: Experimental features are turned on. Do not use experimental features on live deployments.  --> Can't validate Origin smart-contract Registry.sol (that located on 'release' branch)

After using this tutorial
https://docs.blockscout.com/for-users/smart-contract-interaction/verifying-a-smart-contract
I  prepared smart-contract  from release branch
https://github.com/energywebfoundation/origin/blob/release/packages/traceability/issuer/contracts/Registry.sol
https://volta-explorer.energyweb.org/address/0x56c343e525A157DC5472D63E7D4Ca606F6F41C92/contract_verifications/new
and try to validate it,  but get error :
There was an error compiling your contract: Experimental features are turned on. Do not use experimental features on live deployments.
(I think that error happened because of line 2 in Registry.sol, that enabled experimental features : pragma experimental ABIEncoderV2;)

 Click here to see smart-contract that I try to validate

// File: @openzeppelin/contracts-ethereum-package/contracts/math/SafeMath.sol

pragma solidity ^0.5.0;

/**
* @dev Wrappers over Solidity's arithmetic operations with added overflow
* checks.
*
* Arithmetic operations in Solidity wrap on overflow. This can easily result
* in bugs, because programmers usually assume that an overflow raises an
* error, which is the standard behavior in high level programming languages.
* `SafeMath` restores this intuition by reverting the transaction when an
* operation overflows.
*
* Using this library instead of the unchecked operations eliminates an entire
* class of bugs, so it's recommended to use it always.
*/
library SafeMath {
  /**
   * @dev Returns the addition of two unsigned integers, reverting on
   * overflow.
   *
   * Counterpart to Solidity's `+` operator.
   *
   * Requirements:
   * - Addition cannot overflow.
   */
  function add(uint256 a, uint256 b) internal pure returns (uint256) {
      uint256 c = a + b;
      require(c >= a, "SafeMath: addition overflow");

      return c;
  }

  /**
   * @dev Returns the subtraction of two unsigned integers, reverting on
   * overflow (when the result is negative).
   *
   * Counterpart to Solidity's `-` operator.
   *
   * Requirements:
   * - Subtraction cannot overflow.
   */
  function sub(uint256 a, uint256 b) internal pure returns (uint256) {
      return sub(a, b, "SafeMath: subtraction overflow");
  }

  /**
   * @dev Returns the subtraction of two unsigned integers, reverting with custom message on
   * overflow (when the result is negative).
   *
   * Counterpart to Solidity's `-` operator.
   *
   * Requirements:
   * - Subtraction cannot overflow.
   *
   * _Available since v2.4.0._
   */
  function sub(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) {
      require(b <= a, errorMessage);
      uint256 c = a - b;

      return c;
  }

  /**
   * @dev Returns the multiplication of two unsigned integers, reverting on
   * overflow.
   *
   * Counterpart to Solidity's `*` operator.
   *
   * Requirements:
   * - Multiplication cannot overflow.
   */
  function mul(uint256 a, uint256 b) internal pure returns (uint256) {
      // Gas optimization: this is cheaper than requiring 'a' not being zero, but the
      // benefit is lost if 'b' is also tested.
      // See: https://github.com/OpenZeppelin/openzeppelin-contracts/pull/522
      if (a == 0) {
          return 0;
      }

      uint256 c = a * b;
      require(c / a == b, "SafeMath: multiplication overflow");

      return c;
  }

  /**
   * @dev Returns the integer division of two unsigned integers. Reverts on
   * division by zero. The result is rounded towards zero.
   *
   * Counterpart to Solidity's `/` operator. Note: this function uses a
   * `revert` opcode (which leaves remaining gas untouched) while Solidity
   * uses an invalid opcode to revert (consuming all remaining gas).
   *
   * Requirements:
   * - The divisor cannot be zero.
   */
  function div(uint256 a, uint256 b) internal pure returns (uint256) {
      return div(a, b, "SafeMath: division by zero");
  }

  /**
   * @dev Returns the integer division of two unsigned integers. Reverts with custom message on
   * division by zero. The result is rounded towards zero.
   *
   * Counterpart to Solidity's `/` operator. Note: this function uses a
   * `revert` opcode (which leaves remaining gas untouched) while Solidity
   * uses an invalid opcode to revert (consuming all remaining gas).
   *
   * Requirements:
   * - The divisor cannot be zero.
   *
   * _Available since v2.4.0._
   */
  function div(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) {
      // Solidity only automatically asserts when dividing by 0
      require(b > 0, errorMessage);
      uint256 c = a / b;
      // assert(a == b * c + a % b); // There is no case in which this doesn't hold

      return c;
  }

  /**
   * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo),
   * Reverts when dividing by zero.
   *
   * Counterpart to Solidity's `%` operator. This function uses a `revert`
   * opcode (which leaves remaining gas untouched) while Solidity uses an
   * invalid opcode to revert (consuming all remaining gas).
   *
   * Requirements:
   * - The divisor cannot be zero.
   */
  function mod(uint256 a, uint256 b) internal pure returns (uint256) {
      return mod(a, b, "SafeMath: modulo by zero");
  }

  /**
   * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo),
   * Reverts with custom message when dividing by zero.
   *
   * Counterpart to Solidity's `%` operator. This function uses a `revert`
   * opcode (which leaves remaining gas untouched) while Solidity uses an
   * invalid opcode to revert (consuming all remaining gas).
   *
   * Requirements:
   * - The divisor cannot be zero.
   *
   * _Available since v2.4.0._
   */
  function mod(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) {
      require(b != 0, errorMessage);
      return a % b;
  }
}

// File: @openzeppelin/upgrades/contracts/Initializable.sol

pragma solidity >=0.4.24;

/**
* @title Initializable
*
* @dev Helper contract to support initializer functions. To use it, replace
* the constructor with a function that has the `initializer` modifier.
* WARNING: Unlike constructors, initializer functions must be manually
* invoked. This applies both to deploying an Initializable contract, as well
* as extending an Initializable contract via inheritance.
* WARNING: When used with inheritance, manual care must be taken to not invoke
* a parent initializer twice, or ensure that all initializers are idempotent,
* because this is not dealt with automatically as with constructors.
*/
contract Initializable {

/**
 * @dev Indicates that the contract has been initialized.
 */
bool private initialized;

/**
 * @dev Indicates that the contract is in the process of being initialized.
 */
bool private initializing;

/**
 * @dev Modifier to use in the initializer function of a contract.
 */
modifier initializer() {
  require(initializing || isConstructor() || !initialized, "Contract instance has already been initialized");

  bool isTopLevelCall = !initializing;
  if (isTopLevelCall) {
    initializing = true;
    initialized = true;
  }

  _;

  if (isTopLevelCall) {
    initializing = false;
  }
}

/// @dev Returns true if and only if the function is running in the constructor
function isConstructor() private view returns (bool) {
  // extcodesize checks the size of the code stored in an address, and
  // address returns the current address. Since the code is still not
  // deployed when running a constructor, any checks on its code size will
  // yield zero, making it an effective way to detect if a contract is
  // under construction or not.
  address self = address(this);
  uint256 cs;
  assembly { cs := extcodesize(self) }
  return cs == 0;
}

// Reserved storage space to allow for layout changes in the future.
uint256[50] private ______gap;
}

// File: @openzeppelin/contracts-ethereum-package/contracts/introspection/IERC165.sol

pragma solidity ^0.5.0;

/**
* @dev Interface of the ERC165 standard, as defined in the
* https://eips.ethereum.org/EIPS/eip-165[EIP].
*
* Implementers can declare support of contract interfaces, which can then be
* queried by others ({ERC165Checker}).
*
* For an implementation, see {ERC165}.
*/
interface IERC165 {
  /**
   * @dev Returns true if this contract implements the interface defined by
   * `interfaceId`. See the corresponding
   * https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified[EIP section]
   * to learn more about how these ids are created.
   *
   * This function call must use less than 30 000 gas.
   */
  function supportsInterface(bytes4 interfaceId) external view returns (bool);
}

// File: @openzeppelin/contracts-ethereum-package/contracts/introspection/ERC165.sol

pragma solidity ^0.5.0;

/**
* @dev Implementation of the {IERC165} interface.
*
* Contracts may inherit from this and call {_registerInterface} to declare
* their support of an interface.
*/
contract ERC165 is Initializable, IERC165 {
  /*
   * bytes4(keccak256('supportsInterface(bytes4)')) == 0x01ffc9a7
   */
  bytes4 private constant _INTERFACE_ID_ERC165 = 0x01ffc9a7;

  /**
   * @dev Mapping of interface ids to whether or not it's supported.
   */
  mapping(bytes4 => bool) private _supportedInterfaces;

  function initialize() public initializer {
      // Derived contracts need only register support for their own interfaces,
      // we register support for ERC165 itself here
      _registerInterface(_INTERFACE_ID_ERC165);
  }

  /**
   * @dev See {IERC165-supportsInterface}.
   *
   * Time complexity O(1), guaranteed to always use less than 30 000 gas.
   */
  function supportsInterface(bytes4 interfaceId) public view returns (bool) {
      return _supportedInterfaces[interfaceId];
  }

  /**
   * @dev Registers the contract as an implementer of the interface defined by
   * `interfaceId`. Support of the actual ERC165 interface is automatic and
   * registering its interface id is not required.
   *
   * See {IERC165-supportsInterface}.
   *
   * Requirements:
   *
   * - `interfaceId` cannot be the ERC165 invalid interface (`0xffffffff`).
   */
  function _registerInterface(bytes4 interfaceId) internal {
      require(interfaceId != 0xffffffff, "ERC165: invalid interface id");
      _supportedInterfaces[interfaceId] = true;
  }

  uint256[50] private ______gap;
}

// File: contracts/ERC1155/Address.sol

pragma solidity ^0.5.0;

/**
* Utility library of inline functions on addresses
*/
library Address {

  /**
   * Returns whether the target address is a contract
   * @dev This function will return false if invoked during the constructor of a contract,
   * as the code is not actually created until after the constructor finishes.
   * @param account address of the account to check
   * @return whether the target address is a contract
   */
  function isContract(address account) internal view returns (bool) {
      uint256 size;
      // XXX Currently there is no better way to check if there is a contract in an address
      // than to check the size of the code at that address.
      // See https://ethereum.stackexchange.com/a/14016/36603
      // for more details about how this works.
      // TODO Check this again before the Serenity release, because all addresses will be
      // contracts then.
      // solium-disable-next-line security/no-inline-assembly
      assembly { size := extcodesize(account) }
      return size > 0;
  }

}

// File: contracts/ERC1155/Common.sol

pragma solidity ^0.5.0;

/**
  Note: Simple contract to use as base for const vals
*/
contract CommonConstants {

  bytes4 constant internal ERC1155_ACCEPTED = 0xf23a6e61; // bytes4(keccak256("onERC1155Received(address,address,uint256,uint256,bytes)"))
  bytes4 constant internal ERC1155_BATCH_ACCEPTED = 0xbc197c81; // bytes4(keccak256("onERC1155BatchReceived(address,address,uint256[],uint256[],bytes)"))
}

// File: contracts/ERC1155/IERC1155TokenReceiver.sol

pragma solidity ^0.5.0;

/**
  Note: The ERC-165 identifier for this interface is 0x4e2312e0.
*/
interface ERC1155TokenReceiver {
  /**
      @notice Handle the receipt of a single ERC1155 token type.
      @dev An ERC1155-compliant smart contract MUST call this function on the token recipient contract, at the end of a `safeTransferFrom` after the balance has been updated.
      This function MUST return `bytes4(keccak256("onERC1155Received(address,address,uint256,uint256,bytes)"))` (i.e. 0xf23a6e61) if it accepts the transfer.
      This function MUST revert if it rejects the transfer.
      Return of any other value than the prescribed keccak256 generated value MUST result in the transaction being reverted by the caller.
      @param _operator  The address which initiated the transfer (i.e. msg.sender)
      @param _from      The address which previously owned the token
      @param _id        The ID of the token being transferred
      @param _value     The amount of tokens being transferred
      @param _data      Additional data with no specified format
      @return           `bytes4(keccak256("onERC1155Received(address,address,uint256,uint256,bytes)"))`
  */
  function onERC1155Received(address _operator, address _from, uint256 _id, uint256 _value, bytes calldata _data) external returns(bytes4);

  /**
      @notice Handle the receipt of multiple ERC1155 token types.
      @dev An ERC1155-compliant smart contract MUST call this function on the token recipient contract, at the end of a `safeBatchTransferFrom` after the balances have been updated.
      This function MUST return `bytes4(keccak256("onERC1155BatchReceived(address,address,uint256[],uint256[],bytes)"))` (i.e. 0xbc197c81) if it accepts the transfer(s).
      This function MUST revert if it rejects the transfer(s).
      Return of any other value than the prescribed keccak256 generated value MUST result in the transaction being reverted by the caller.
      @param _operator  The address which initiated the batch transfer (i.e. msg.sender)
      @param _from      The address which previously owned the token
      @param _ids       An array containing ids of each token being transferred (order and length must match _values array)
      @param _values    An array containing amounts of each token being transferred (order and length must match _ids array)
      @param _data      Additional data with no specified format
      @return           `bytes4(keccak256("onERC1155BatchReceived(address,address,uint256[],uint256[],bytes)"))`
  */
  function onERC1155BatchReceived(address _operator, address _from, uint256[] calldata _ids, uint256[] calldata _values, bytes calldata _data) external returns(bytes4);
}

// File: contracts/ERC1155/IERC1155.sol

pragma solidity ^0.5.0;

/**
  @title ERC-1155 Multi Token Standard
  @dev See https://github.com/ethereum/EIPs/blob/master/EIPS/eip-1155.md
  Note: The ERC-165 identifier for this interface is 0xd9b67a26.
*/
interface IERC1155 /* is ERC165 */ {
  /**
      @dev Either `TransferSingle` or `TransferBatch` MUST emit when tokens are transferred, including zero value transfers as well as minting or burning (see "Safe Transfer Rules" section of the standard).
      The `_operator` argument MUST be msg.sender.
      The `_from` argument MUST be the address of the holder whose balance is decreased.
      The `_to` argument MUST be the address of the recipient whose balance is increased.
      The `_id` argument MUST be the token type being transferred.
      The `_value` argument MUST be the number of tokens the holder balance is decreased by and match what the recipient balance is increased by.
      When minting/creating tokens, the `_from` argument MUST be set to `0x0` (i.e. zero address).
      When burning/destroying tokens, the `_to` argument MUST be set to `0x0` (i.e. zero address).
  */
  event TransferSingle(address indexed _operator, address indexed _from, address indexed _to, uint256 _id, uint256 _value);

  /**
      @dev Either `TransferSingle` or `TransferBatch` MUST emit when tokens are transferred, including zero value transfers as well as minting or burning (see "Safe Transfer Rules" section of the standard).
      The `_operator` argument MUST be msg.sender.
      The `_from` argument MUST be the address of the holder whose balance is decreased.
      The `_to` argument MUST be the address of the recipient whose balance is increased.
      The `_ids` argument MUST be the list of tokens being transferred.
      The `_values` argument MUST be the list of number of tokens (matching the list and order of tokens specified in _ids) the holder balance is decreased by and match what the recipient balance is increased by.
      When minting/creating tokens, the `_from` argument MUST be set to `0x0` (i.e. zero address).
      When burning/destroying tokens, the `_to` argument MUST be set to `0x0` (i.e. zero address).
  */
  event TransferBatch(address indexed _operator, address indexed _from, address indexed _to, uint256[] _ids, uint256[] _values);

  /**
      @dev MUST emit when approval for a second party/operator address to manage all tokens for an owner address is enabled or disabled (absense of an event assumes disabled).
  */
  event ApprovalForAll(address indexed _owner, address indexed _operator, bool _approved);

  /**
      @dev MUST emit when the URI is updated for a token ID.
      URIs are defined in RFC 3986.
      The URI MUST point a JSON file that conforms to the "ERC-1155 Metadata URI JSON Schema".
  */
  event URI(string _value, uint256 indexed _id);

  /**
      @notice Transfers `_value` amount of an `_id` from the `_from` address to the `_to` address specified (with safety call).
      @dev Caller must be approved to manage the tokens being transferred out of the `_from` account (see "Approval" section of the standard).
      MUST revert if `_to` is the zero address.
      MUST revert if balance of holder for token `_id` is lower than the `_value` sent.
      MUST revert on any other error.
      MUST emit the `TransferSingle` event to reflect the balance change (see "Safe Transfer Rules" section of the standard).
      After the above conditions are met, this function MUST check if `_to` is a smart contract (e.g. code size > 0). If so, it MUST call `onERC1155Received` on `_to` and act appropriately (see "Safe Transfer Rules" section of the standard).
      @param _from    Source address
      @param _to      Target address
      @param _id      ID of the token type
      @param _value   Transfer amount
      @param _data    Additional data with no specified format, MUST be sent unaltered in call to `onERC1155Received` on `_to`
  */
  function safeTransferFrom(address _from, address _to, uint256 _id, uint256 _value, bytes calldata _data) external;

  /**
      @notice Transfers `_values` amount(s) of `_ids` from the `_from` address to the `_to` address specified (with safety call).
      @dev Caller must be approved to manage the tokens being transferred out of the `_from` account (see "Approval" section of the standard).
      MUST revert if `_to` is the zero address.
      MUST revert if length of `_ids` is not the same as length of `_values`.
      MUST revert if any of the balance(s) of the holder(s) for token(s) in `_ids` is lower than the respective amount(s) in `_values` sent to the recipient.
      MUST revert on any other error.
      MUST emit `TransferSingle` or `TransferBatch` event(s) such that all the balance changes are reflected (see "Safe Transfer Rules" section of the standard).
      Balance changes and events MUST follow the ordering of the arrays (_ids[0]/_values[0] before _ids[1]/_values[1], etc).
      After the above conditions for the transfer(s) in the batch are met, this function MUST check if `_to` is a smart contract (e.g. code size > 0). If so, it MUST call the relevant `ERC1155TokenReceiver` hook(s) on `_to` and act appropriately (see "Safe Transfer Rules" section of the standard).
      @param _from    Source address
      @param _to      Target address
      @param _ids     IDs of each token type (order and length must match _values array)
      @param _values  Transfer amounts per token type (order and length must match _ids array)
      @param _data    Additional data with no specified format, MUST be sent unaltered in call to the `ERC1155TokenReceiver` hook(s) on `_to`
  */
  function safeBatchTransferFrom(address _from, address _to, uint256[] calldata _ids, uint256[] calldata _values, bytes calldata _data) external;

  /**
      @notice Get the balance of an account's Tokens.
      @param _owner  The address of the token holder
      @param _id     ID of the Token
      @return        The _owner's balance of the Token type requested
   */
  function balanceOf(address _owner, uint256 _id) external view returns (uint256);

  /**
      @notice Get the balance of multiple account/token pairs
      @param _owners The addresses of the token holders
      @param _ids    ID of the Tokens
      @return        The _owner's balance of the Token types requested (i.e. balance for each (owner, id) pair)
   */
  function balanceOfBatch(address[] calldata _owners, uint256[] calldata _ids) external view returns (uint256[] memory);

  /**
      @notice Enable or disable approval for a third party ("operator") to manage all of the caller's tokens.
      @dev MUST emit the ApprovalForAll event on success.
      @param _operator  Address to add to the set of authorized operators
      @param _approved  True if the operator is approved, false to revoke approval
  */
  function setApprovalForAll(address _operator, bool _approved) external;

  /**
      @notice Queries the approval status of an operator for a given owner.
      @param _owner     The owner of the Tokens
      @param _operator  Address of authorized operator
      @return           True if the operator is approved, false if not
  */
  function isApprovedForAll(address _owner, address _operator) external view returns (bool);
}

// File: contracts/ERC1155/ERC1155.sol

pragma solidity ^0.5.0;

// A sample implementation of core ERC1155 function.
contract ERC1155 is IERC1155, ERC165, CommonConstants
{
  using SafeMath for uint256;
  using Address for address;

  // id => (owner => balance)
  mapping (uint256 => mapping(address => uint256)) internal balances;

  // owner => (operator => approved)
  mapping (address => mapping(address => bool)) internal operatorApproval;

/////////////////////////////////////////// ERC165 //////////////////////////////////////////////

  /*
      bytes4(keccak256('supportsInterface(bytes4)'));
  */
  bytes4 constant private INTERFACE_SIGNATURE_ERC165 = 0x01ffc9a7;

  /*
      bytes4(keccak256("safeTransferFrom(address,address,uint256,uint256,bytes)")) ^
      bytes4(keccak256("safeBatchTransferFrom(address,address,uint256[],uint256[],bytes)")) ^
      bytes4(keccak256("balanceOf(address,uint256)")) ^
      bytes4(keccak256("balanceOfBatch(address[],uint256[])")) ^
      bytes4(keccak256("setApprovalForAll(address,bool)")) ^
      bytes4(keccak256("isApprovedForAll(address,address)"));
  */
  bytes4 constant private INTERFACE_SIGNATURE_ERC1155 = 0xd9b67a26;

  function supportsInterface(bytes4 _interfaceId)
  public
  view
  returns (bool) {
       if (_interfaceId == INTERFACE_SIGNATURE_ERC165 ||
           _interfaceId == INTERFACE_SIGNATURE_ERC1155) {
          return true;
       }

       return false;
  }

/////////////////////////////////////////// ERC1155 //////////////////////////////////////////////

  /**
      @notice Transfers `_value` amount of an `_id` from the `_from` address to the `_to` address specified (with safety call).
      @dev Caller must be approved to manage the tokens being transferred out of the `_from` account (see "Approval" section of the standard).
      MUST revert if `_to` is the zero address.
      MUST revert if balance of holder for token `_id` is lower than the `_value` sent.
      MUST revert on any other error.
      MUST emit the `TransferSingle` event to reflect the balance change (see "Safe Transfer Rules" section of the standard).
      After the above conditions are met, this function MUST check if `_to` is a smart contract (e.g. code size > 0). If so, it MUST call `onERC1155Received` on `_to` and act appropriately (see "Safe Transfer Rules" section of the standard).
      @param _from    Source address
      @param _to      Target address
      @param _id      ID of the token type
      @param _value   Transfer amount
      @param _data    Additional data with no specified format, MUST be sent unaltered in call to `onERC1155Received` on `_to`
  */
  function safeTransferFrom(address _from, address _to, uint256 _id, uint256 _value, bytes memory _data) public {

      require(_to != address(0x0), "safeTransferFrom: _to must be non-zero.");
      require(_from == msg.sender || operatorApproval[_from][msg.sender] == true, "Need operator approval for 3rd party transfers.");
      require(balances[_id][_from] > 0, "safeTransferFrom: _from balance has to be higher than 0");

      // SafeMath will throw with insuficient funds _from
      // or if _id is not valid (balance will be 0)
      balances[_id][_from] = balances[_id][_from].sub(_value);
      balances[_id][_to] = _value.add(balances[_id][_to]);

      // MUST emit event
      emit TransferSingle(msg.sender, _from, _to, _id, _value);

      // Now that the balance is updated and the event was emitted,
      // call onERC1155Received if the destination is a contract.
      if (_to.isContract()) {
          _doSafeTransferAcceptanceCheck(msg.sender, _from, _to, _id, _value, _data);
      }
  }

  /**
      @notice Transfers `_values` amount(s) of `_ids` from the `_from` address to the `_to` address specified (with safety call).
      @dev Caller must be approved to manage the tokens being transferred out of the `_from` account (see "Approval" section of the standard).
      MUST revert if `_to` is the zero address.
      MUST revert if length of `_ids` is not the same as length of `_values`.
      MUST revert if any of the balance(s) of the holder(s) for token(s) in `_ids` is lower than the respective amount(s) in `_values` sent to the recipient.
      MUST revert on any other error.
      MUST emit `TransferSingle` or `TransferBatch` event(s) such that all the balance changes are reflected (see "Safe Transfer Rules" section of the standard).
      Balance changes and events MUST follow the ordering of the arrays (_ids[0]/_values[0] before _ids[1]/_values[1], etc).
      After the above conditions for the transfer(s) in the batch are met, this function MUST check if `_to` is a smart contract (e.g. code size > 0). If so, it MUST call the relevant `ERC1155TokenReceiver` hook(s) on `_to` and act appropriately (see "Safe Transfer Rules" section of the standard).
      @param _from    Source address
      @param _to      Target address
      @param _ids     IDs of each token type (order and length must match _values array)
      @param _values  Transfer amounts per token type (order and length must match _ids array)
      @param _data    Additional data with no specified format, MUST be sent unaltered in call to the `ERC1155TokenReceiver` hook(s) on `_to`
  */
  function safeBatchTransferFrom(address _from, address _to, uint256[] memory _ids, uint256[] memory _values, bytes memory _data) public {

      // MUST Throw on errors
      require(_to != address(0x0), "destination address must be non-zero.");
      require(_ids.length == _values.length, "_ids and _values array lenght must match.");
      require(_from == msg.sender || operatorApproval[_from][msg.sender] == true, "Need operator approval for 3rd party transfers.");

      for (uint256 i = 0; i < _ids.length; ++i) {
          uint256 id = _ids[i];
          uint256 value = _values[i];

          // SafeMath will throw with insuficient funds _from
          // or if _id is not valid (balance will be 0)
          balances[id][_from] = balances[id][_from].sub(value);
          balances[id][_to]   = value.add(balances[id][_to]);
      }

      // Note: instead of the below batch versions of event and acceptance check you MAY have emitted a TransferSingle
      // event and a subsequent call to _doSafeTransferAcceptanceCheck in above loop for each balance change instead.
      // Or emitted a TransferSingle event for each in the loop and then the single _doSafeBatchTransferAcceptanceCheck below.
      // However it is implemented the balance changes and events MUST match when a check (i.e. calling an external contract) is done.

      // MUST emit event
      emit TransferBatch(msg.sender, _from, _to, _ids, _values);

      // Now that the balances are updated and the events are emitted,
      // call onERC1155BatchReceived if the destination is a contract.
      if (_to.isContract()) {
          _doSafeBatchTransferAcceptanceCheck(msg.sender, _from, _to, _ids, _values, _data);
      }
  }

  /**
      @notice Get the balance of an account's Tokens.
      @param _owner  The address of the token holder
      @param _id     ID of the Token
      @return        The _owner's balance of the Token type requested
   */
  function balanceOf(address _owner, uint256 _id) external view returns (uint256) {
      // The balance of any account can be calculated from the Transfer events history.
      // However, since we need to keep the balances to validate transfer request,
      // there is no extra cost to also privide a querry function.
      return balances[_id][_owner];
  }

  /**
      @notice Get the balance of multiple account/token pairs
      @param _owners The addresses of the token holders
      @param _ids    ID of the Tokens
      @return        The _owner's balance of the Token types requested (i.e. balance for each (owner, id) pair)
   */
  function balanceOfBatch(address[] calldata _owners, uint256[] calldata _ids) external view returns (uint256[] memory) {

      require(_owners.length == _ids.length);

      uint256[] memory balances_ = new uint256[](_owners.length);

      for (uint256 i = 0; i < _owners.length; ++i) {
          balances_[i] = balances[_ids[i]][_owners[i]];
      }

      return balances_;
  }

  /**
      @notice Enable or disable approval for a third party ("operator") to manage all of the caller's tokens.
      @dev MUST emit the ApprovalForAll event on success.
      @param _operator  Address to add to the set of authorized operators
      @param _approved  True if the operator is approved, false to revoke approval
  */
  function setApprovalForAll(address _operator, bool _approved) external {
      operatorApproval[msg.sender][_operator] = _approved;
      emit ApprovalForAll(msg.sender, _operator, _approved);
  }

  /**
      @notice Queries the approval status of an operator for a given owner.
      @param _owner     The owner of the Tokens
      @param _operator  Address of authorized operator
      @return           True if the operator is approved, false if not
  */
  function isApprovedForAll(address _owner, address _operator) external view returns (bool) {
      return operatorApproval[_owner][_operator];
  }

/////////////////////////////////////////// Internal //////////////////////////////////////////////

  function _doSafeTransferAcceptanceCheck(address _operator, address _from, address _to, uint256 _id, uint256 _value, bytes memory _data) internal {

      // If this was a hybrid standards solution you would have to check ERC165(_to).supportsInterface(0x4e2312e0) here but as this is a pure implementation of an ERC-1155 token set as recommended by
      // the standard, it is not necessary. The below should revert in all failure cases i.e. _to isn't a receiver, or it is and either returns an unknown value or it reverts in the call to indicate non-acceptance.

      // Note: if the below reverts in the onERC1155Received function of the _to address you will have an undefined revert reason returned rather than the one in the require test.
      // If you want predictable revert reasons consider using low level _to.call() style instead so the revert does not bubble up and you can revert yourself on the ERC1155_ACCEPTED test.
      require(ERC1155TokenReceiver(_to).onERC1155Received(_operator, _from, _id, _value, _data) == ERC1155_ACCEPTED, "contract returned an unknown value from onERC1155Received");
  }

  function _doSafeBatchTransferAcceptanceCheck(address _operator, address _from, address _to, uint256[] memory _ids, uint256[] memory _values, bytes memory _data) internal {

      // If this was a hybrid standards solution you would have to check ERC165(_to).supportsInterface(0x4e2312e0) here but as this is a pure implementation of an ERC-1155 token set as recommended by
      // the standard, it is not necessary. The below should revert in all failure cases i.e. _to isn't a receiver, or it is and either returns an unknown value or it reverts in the call to indicate non-acceptance.

      // Note: if the below reverts in the onERC1155BatchReceived function of the _to address you will have an undefined revert reason returned rather than the one in the require test.
      // If you want predictable revert reasons consider using low level _to.call() style instead so the revert does not bubble up and you can revert yourself on the ERC1155_BATCH_ACCEPTED test.
      require(ERC1155TokenReceiver(_to).onERC1155BatchReceived(_operator, _from, _ids, _values, _data) == ERC1155_BATCH_ACCEPTED, "contract returned an unknown value from onERC1155BatchReceived");
  }
}

// File: contracts/ERC1155/ERC1155Mintable.sol

pragma solidity ^0.5.0;

/**
  @dev Mintable form of ERC1155
  Shows how easy it is to mint new items.
*/
contract ERC1155Mintable is ERC1155 {

  bytes4 constant private INTERFACE_SIGNATURE_URI = 0x0e89341c;

  // id => creators
  mapping (uint256 => address) public creators;

  // A nonce to ensure we have a unique id each time we mint.
  uint256 public nonce;

  modifier creatorOnly(uint256 _id) {
      require(creators[_id] == msg.sender);
      _;
  }

  function supportsInterface(bytes4 _interfaceId)
  public
  view
  returns (bool) {
      if (_interfaceId == INTERFACE_SIGNATURE_URI) {
          return true;
      } else {
          return super.supportsInterface(_interfaceId);
      }
  }

  // Creates a new token type and assigns _initialSupply to minter
  function create(uint256 _initialSupply, string calldata _uri, address creator) external returns(uint256 _id) {

      _id = ++nonce;
      creators[_id] = creator;
      balances[_id][creator] = _initialSupply;

      // require(balances[_id][creator] > 0, "balance not increased");

      // Transfer event with mint semantic
      emit TransferSingle(creator, address(0x0), creator, _id, _initialSupply);

      if (bytes(_uri).length > 0)
          emit URI(_uri, _id);
  }

  // Mint tokens. Assign directly to _to.
  function mint(uint256 _id, address _to, uint256 _quantity) external creatorOnly(_id) {

      // Grant the items to the caller
      balances[_id][_to] = _quantity.add(balances[_id][_to]);

      // Emit the Transfer/Mint event.
      // the 0x0 source address implies a mint
      // It will also provide the circulating supply info.
      emit TransferSingle(msg.sender, address(0x0), _to, _id, _quantity);

      if (_to.isContract()) {
          _doSafeTransferAcceptanceCheck(msg.sender, msg.sender, _to, _id, _quantity, '');
      }
  }

  function setURI(string calldata _uri, uint256 _id) external creatorOnly(_id) {
      emit URI(_uri, _id);
  }
}

// File: contracts/ERC1888/IERC1888.sol

pragma solidity ^0.5.6;
pragma experimental ABIEncoderV2;

interface ERC1888 {

  struct Certificate {
      int256 topic;
      address issuer; // msg.sender
      bytes validityData; // call data
      bytes data;
  }

  event IssuanceSingle(address indexed _issuer, int256 indexed _topic, uint256 _id);
  //event IssuanceBatch(address indexed _issuer, int256[] indexed _topics, uint256[] _ids);

  event ClaimSingle(address indexed _claimIssuer, address indexed _claimSubject, int256 indexed _topic, uint256 _id, uint256 _value, bytes _claimData);
  event ClaimBatch(address indexed _claimIssuer, address indexed _claimSubject, int256[] indexed _topics, uint256[] _ids, uint256[] _values, bytes[] _claimData);

  function issue(address _to, bytes calldata _validityData, int256 _topic, uint256 _value, bytes calldata _data) external returns (uint256);
  // function batchIssue(bytes[]   _data, uint256[]   _topics, uint256[]   _value, bytes32[]   _signatures) external returns(uint256[]);

  function safeTransferAndClaimFrom(address _from, address _to, uint256 _id, uint256 _value, bytes calldata _data, bytes calldata _claimData) external;
  function safeBatchTransferAndClaimFrom(address _from, address _to, uint256[] calldata _ids, uint256[] calldata _values, bytes calldata _data, bytes[] calldata _claimData) external;

  function getCertificate(uint256 _id) external view returns (address issuer, int256 topic, bytes memory validityCall, bytes memory data);
  function claimedBalanceOf(address _owner, uint256 _id) external view returns (uint256);
  // function claimedBalanceOfBatch(address[] calldata _owners, uint256[] calldata _ids) external view returns (uint256[] memory);
}

// File: contracts/Registry.sol

pragma solidity ^0.5.6;
pragma experimental ABIEncoderV2;

contract Registry is ERC1155Mintable, ERC1888 {

  mapping(uint256 => Certificate) public certificateStorage;
  mapping(uint256 => mapping(address => uint256)) public claimedBalances;

  // Array with all certificate ids, used for enumeration
  uint256[] private _allCertificates;
  // Mapping from certificate id to position in the allCertificates array
  mapping(uint256 => uint256) private _allCertificatesIndex;

  function issue(address _to, bytes calldata _validityData, int256 _topic, uint256 _value, bytes calldata _data) external returns (uint256 _id) {
  	_validate(msg.sender, _validityData);

  	_id = this.create(_value, "Certificate", msg.sender);

  	if (_value > 0) {
  		safeTransferFrom(msg.sender, _to, _id, _value, _data);
  	}

  	certificateStorage[_id] = Certificate({
  		topic: _topic,
  		issuer: msg.sender,
  		validityData: _validityData,
  		data: _data
  	});

  	_allCertificatesIndex[_id] = _allCertificates.length;
  	_allCertificates.push(_id);

  	emit IssuanceSingle(msg.sender, _topic, _id);
  }

  function safeTransferAndClaimFrom(
  	address _from,
  	address _to,
  	uint256 _id,
  	uint256 _value,
  	bytes calldata _data,
  	bytes calldata _claimData
  ) external {
  	Certificate memory cert = certificateStorage[_id];

  	_validate(cert.issuer,  cert.validityData);

      require(_to != address(0x0), "safeTransferAndClaimFrom: _to must be non-zero.");
      require(_from == msg.sender || operatorApproval[_from][msg.sender] == true, "safeTransferAndClaimFrom: Need operator approval for 3rd party claims.");
      require(balances[_id][_from] > 0, "safeTransferAndClaimFrom: _from balance has to be higher than 0");

  	if (_from != _to) {
  		safeTransferFrom(_from, _to, _id, _value, _data);
  	}

  	_burn(_to, _id, _value);

  	emit ClaimSingle(_from, _to, cert.topic, _id, _value, _claimData); //_claimSubject address ??
  }

  function safeBatchTransferAndClaimFrom(
  	address _from,
  	address _to,
  	uint256[] calldata _ids,
  	uint256[] calldata _values,
  	bytes calldata _data,
  	bytes[] calldata _claimData
  ) external {
  	uint numberOfClaims = _ids.length;

      require(_to != address(0x0), "safeBatchTransferAndClaimFrom: _to address must be non-zero.");
      require(_ids.length == _values.length, "safeBatchTransferAndClaimFrom: _ids and _values array length must match.");
      require(_from == msg.sender || operatorApproval[_from][msg.sender] == true, "safeBatchTransferAndClaimFrom: Need operator approval for 3rd party transfers.");

  	require(numberOfClaims > 0, "safeBatchTransferAndClaimFrom: at least one certificate has to be present.");
  	require(
  		_values.length == numberOfClaims && _claimData.length == numberOfClaims,
  		"safeBatchTransferAndClaimFrom: not all arrays are of the same length."
  	);

  	int256[] memory topics = new int256[](numberOfClaims);

  	for (uint256 i = 0; i < numberOfClaims; ++i) {
  		Certificate memory cert = certificateStorage[_ids[i]];
  		_validate(cert.issuer,  cert.validityData);
  		topics[i] = cert.topic;
  	}

  	if (_from != _to) {
  		safeBatchTransferFrom(_from, _to, _ids, _values, _data);
  	}

  	for (uint256 i = 0; i < numberOfClaims; ++i) {
  		_burn(_to, _ids[i], _values[i]);
  	}

  	emit ClaimBatch(_from, _to, topics, _ids, _values, _claimData);
  }

  function getCertificate(uint256 _id) external view returns (address issuer, int256 topic, bytes memory validityData, bytes memory data) {
  	require(_id <= totalSupply(), "getCertificate: _id out of bounds");

  	Certificate memory certificate = certificateStorage[_id];
  	return (certificate.issuer, certificate.topic, certificate.validityData, certificate.data);
  }

  function claimedBalanceOf(address _owner, uint256 _id) external view returns (uint256) {
  	return claimedBalances[_id][_owner];
  }

  function _burn(address _from, uint256 _id, uint256 _value) internal {
  	balances[_id][_from] = balances[_id][_from].sub(_value);
  	claimedBalances[_id][_from] = claimedBalances[_id][_from].add(_value);
  }

  function _validate(address _verifier, bytes memory _validityData) internal view {
  	if (_verifier.isContract()) {
  		(bool success, bytes memory result) = _verifier.staticcall(_validityData);

  		require(
  			success && abi.decode(result, (bool)),
  			"_validate(): Request/certificate invalid, please check with your issuer."
  		);
      }
  }

  /**
   * @dev Gets the total amount of certificates stored by the contract.
   * @return uint256 representing the total amount of certificates
   */
  function totalSupply() public view returns (uint256) {
      return _allCertificates.length;
  }

  function allCertificateIds() public view returns (uint256[] memory) {
  	return _allCertificates;
  }
}

Also, I try to fix this error in few different ways, but every time get new errors and no final luck.

Can I get any  advice about error that I get ?

(or may be there is some place where I can  found  smart-contract for release branch that is ready to  pass "verify & publish"  step ? )

P.S.

Also, I found release notes of Solidity 0.8  that inform about ABI coder v2 is activated by default.
 https://docs.soliditylang.org/en/v0.8.0/080-breaking-changes.html

But I can not use 0.8.x version of compiler due validation because of restriction from first line of code:

pragma solidity ^0.5.6;

 that is in  Registry.sol contract  on release branch.

(Looks like that compiler version that I can use is limited  up to  0.6.0)

also, If I try to change version of compiler - I get error There was an error compiling your contract: Source file requires different compiler version (current compiler is 0.8.4+commit.c7e474f2.Emscripten.clang) - note that nightly builds are considered to be strictly less than the released version

@andrii482 On the latest release branch, which is the latest stable release, we are using solc 0.5.6.
But on the latest master branch, we've updated to use solc 0.8.0.
Which branch are you working off?

I see your upgrade on master branch, but because of mentions of your team here:

and really "hot" work on your master branch we start using release branch code.

Makes sense. The problem here is that the explorer doesn't accept experimental features, and there's no way around it I think...
The only solution I see is to start using our latest smart contracts on the master branch.
We should release these soon to the release branch, but no ETAs yet.


Flame Blade recieving Odd Size bonus to damage

Changing from 1d6 to 3d6 for a size bonus.
Character is a halfling and is 'small' if that is relevant.

Reducing size further by reduce person ( i am now getting +2 size bonus to AC) reducing the flame blade damage to 2d6

Wow. You really get a size bonus when shrinked. Maybe that's an underflow, because the default damage is 0 (plus the overwrite values).
In any case, I set a flag that should prevent the weapon from scaling altogether.


Finish Fast Ride Feed/Form

Please do work for this task in a branch called issue-041.

draft of issue-041: Form populates data into Feed page. Feed page does not have a working "edit" nor does if have a working "submit" button for notes, as of yet... photos attached to project issue-041... merged to master...


GLPI version and compose Tag

Hi,
using "image: turgon37/glpi:nginx-72-9.5.3-latest" in compose file gives me a manifest error
using "image: turgon37/glpi:nginx-72-latest" will setup glpi 9.5.1
using "image: turgon37/glpi" will setup glpi 9.3.3
Is your image up to date on docker hub?

Thanks to you, I've found an issue introduced by my own publish code :)
I've added the missing "latest" tags on image and updated accordingly the Readme

That was quick!
Thanks, I’ll give it a shot tomorrow. I really like your approach of GLPI on docker, on paper it seems to be the best out there, thanks for your hard work


Iterate through noteOn's and get their lengths

Hi @melanchall ! Great lib, trying to use it in my project - I need a visual midi "player" and found that "getTimedEvents" works quite well for this purpose, however one piece of puzzle is missing - I need to know note length for every noteOn - this seems to only be available for generated objects from smf.Interaction, but not from loaded with midifile - is that correct? If so I think we should try to add this functionality. Otherwise please tell me how to do this, maybe it's very easy but I just didn't figure out.

Hi @f3flight ,
Thanks for using the library! The library has clear conception of "levels of abstraction". Smf namespace contains raw MIDI structures as they presented in a MIDI file, without any processing. Smf.Interaction provides high level objects which are useful for real tasks. So it is correct that there are only low level objects inside MidiFile.
Note On event hasn't length as well as all other events. You need to get corresponding Note Off event and take difference between times of both events as length of the note constructed from those events. You can take a look at CreateNotes private method of the NotesManager class which constructs notes from TimedEvent's.
So for every TimedEvent which wraps NoteOnEvent you need to find corresponding TimedEvent which wraps NoteOffEvent with the same note's number and channel as NoteOnEvent and take difference between times of timed events.
Probably I'll add some extension method like GetNoteOffEvent for NoteOnEvent or something like that. Thank you for idea and your question!

@f3flight Did you solve your problem?

Nope not yet, didn't touch. Well I have a code which does the trick when using MidiSharp lib, but wanted to switch to something esle bcz that guy didnt care about my pull request. You can check the only pull request in his github repo. Not the cleanest way to do things but worked ok.

https://github.com/stephentoub/MidiSharp/pull/5

First of all, it is wrong to add length to event. While it can be useful for some tasks it is conceptually wrong. MIDI event is just a point in time, event is momentary thing and has no length. From my practice when you start changing code to satisfy particulat task ignoring conceptions of subject domain, you'll encounter problems sooner or later with maintaining and changing of the codebase.
I can suggest you a solution that will keep things clear. First of all define some class that will attach length to TimedEvent:
public sealed class LengthedEvent
{
    public LengthedEvent(TimedEvent timedEvent)
    {
        TimedEvent = timedEvent;
    }

    public TimedEvent TimedEvent { get; }

    public long? Length { get; set; }
}

Now you can process TimedEvent's with this code:
public static IEnumerable<LengthedEvent> ProcessTimedEvents(IEnumerable<TimedEvent> timedEvents)
{
    var result = new List<LengthedEvent>();
    var noteOnTimedEvents = new List<TimedEvent>();

    foreach (var timedEvent in timedEvents)
    {
        var midiEvent = timedEvent.Event;
        if (midiEvent is NoteOnEvent)
        {
            noteOnTimedEvents.Add(timedEvent);
            result.Add(new LengthedEvent(timedEvent));
            continue;
        }

        var noteOffEvent = midiEvent as NoteOffEvent;
        if (noteOffEvent != null)
        {
            var channel = noteOffEvent.Channel;
            var noteNumber = noteOffEvent.NoteNumber;

            var noteOnTimedEvent = noteOnTimedEvents.FirstOrDefault(e => IsAppropriateNoteOnTimedEvent(e, channel, noteNumber));
            if (noteOnTimedEvent == null)
                continue;

            noteOnTimedEvents.Remove(noteOnTimedEvent);

            var lengthedEvent = result.FirstOrDefault(e => e.TimedEvent == noteOnTimedEvent);
            lengthedEvent.Length = timedEvent.Time - noteOnTimedEvent.Time;
            continue;
        }

        result.Add(new LengthedEvent(timedEvent));
    }

    return result;
}

ProcessTimedEvents will return original TimedEvent's without Note Off events and with Length set to some long value to all TimedEvent's that wrap NoteOnEvent. All other events will have Length set to null. So to get LengthedEvent's from a MIDI file you need to execute this code:
var midiFile = MidiFile.Read("Some MIDI file.mid");
var timedEvents = midiFile.GetTimedEvents();
var lengtehedEvents = ProcessTimedEvents(timedEvents);

Also note that DryWetMIDI provides a way to convert raw long value to another representations. For example, to get Length as minutes and seconds, write this:
TempoMap tempoMap = midiFile.GetTempoMap();
MetricTimeSpan metricLength = LengthConverter.ConvertTo<MetricTimeSpan>(lengthEvent.Length, lengthedEvent.TimedEvent.Time, tempoMap);

MetricTimeSpan has properties like Minutes and Seconds and also can be casted to standard TimeSpan. Visit Time and length Wiki page to learn more.

OK, I've added ExtractNotes method which is an extension method for IEnumerable<TimedEvent>. This method returns IEnumerable<ITimedObject> where an element can be either TimedEvent or Note. So all Note On/Note Off pairs will be returned as Note objects. All other events will be returned without processing.
Usage of the method:
IEnumerable<ITimedObject> timedObjects = midiFile.GetTimedEvents().ExtractNotes();

At now the method exist only in develop branch. Nearest release will have it.
@f3flight Any new on your task?

@melanchall thas good news, thank you!  If youre interested in some C# + Unity + VR programming for fun and self improvement - pm me (fb, vk, telegram - f3flight), i really need someone who will want to work together with me on this.

I've tested this, looks like there's a bug.
Midi attached. test.zip
Debug output from a test app: https://pastebin.com/TLN4LTVY
As you can see, at around "122214 Event at 155040: Note On [0] (46, 40)" it breaks and starts throwing in TimedEvent instead of Note.
The code of the test app:
        Stream stream = System.IO.FileStream("C:\\test.mid",System.IO.FileMode.Open,System.IO.FileAccess.Read);
        midiFile = MidiFile.Read(stream);
            IEnumerable<ITimedObject> timedObjectsAndNotes = midiFile.GetTimedEvents().ExtractNotes();
            TempoMap tmap = midiFile.GetTempoMap();
            foreach (ITimedObject x in timedObjectsAndNotes) {
                MetricTimeSpan t = x.TimeAs<MetricTimeSpan>(tmap);
                Debug.Write((t.TotalMicroseconds / 1000) + " " + x);
                Melanchall.DryWetMidi.Smf.Interaction.Note note = x as Melanchall.DryWetMidi.Smf.Interaction.Note;
                if (note != null) {
                    MetricTimeSpan l = note.LengthAs<MetricTimeSpan>(tmap);
                    Debug.Write(" " + note.NoteName + " " + note.Octave + " " + (l.TotalMicroseconds / 1000));
                }
                Debug.WriteLine("");
            }
            Debug.WriteLine("finished");

Another concern I have is that the absolute time in seconds is a bit off from what I got when working with this file via my own calculating functions...
Hm yes I checked with MidiEditor and it also shows a slightly longer time. drywetmidi gives 0:6:50:356 for the last event, MidiEditor shows 6.51.55 for the last NoteOn.
. So I'm pretty sure there's a small error accumulating in the algorithm. But that would be a separate issue.

@melanchall I checked with my older code, I get 410.3503 seconds which mostly matches your 6:50:356, just 6ms diff, maybe because I'm using float in my code. So there's no issue with time calc.
Let me know if you find why ExtractNotes fails midway through this midi file, I will try to check as well if I have time.

@melanchall I'm pretty sure the issue is due to lack of handling of some of these situations:

note is already ringing (double-on). Assuming a missing note off event...
note on event actually indicating note off
note is not ringing now (double-off). Ignoring.

basically in this particular file (and probably some others in the wild), there's a mess with noteOns, so I guess that's what breaks it. Looks like 2 is covered as the file pretty much has no noteoff events, but maybe 1 is still an issue.

@f3flight
Thanks for investigation! I'm a little busy so cannot handle the issue quickly :( As for special cases:

Yes, that can be a problem.
It's handled already on MidiFile.Read. _Note On_s with zero velocity are treated as _Note Off_s by default (that behavior can be adjusted via ReadingSettings), so there is no issues.
At now _Note Off_s without corresponding _Note On_s ignored. And... this is wrong and should be fixed. Such events should be returned as just TimedEvents.

The bug is critical so I'll look into it as soon as possible. Thank you again.

@f3flight I've found the bug and fixed it. Please take latest version and check ExtractNotes method. Thank you for pointing out to the issue.

@melanchall thanks I'll test! I recommend to put link to issue inside commit message, then it will be automatically shown in the thread. I'll put this for reference - https://github.com/melanchall/drywetmidi/commit/c8af797845b909b9ce4be578ea61e5128a80cfb8

Looks like it's fixed and works well! I'll close this issue.


Refactored Serial comms into state machine and handled a few extra error cases

big brother asks for code review, little brother refactors everything :P
Summary

Consolidated a bunch of the Serial state machine logic into a single enum. Documented the transitions.

I made it skip messages with empty payloads, not sure if that's what you wanted.

Using a callback that only gives the user access to the byte array for a short duration. This discourages people from reading it while it's invalid/partial. Also made the member variables private to further discourage this.
Consolidated send() implementations into a single function that the overloads call into. I find this pattern survives longer, and makes it easier to debug. It keeps the overloads "thin" and they can't diverge too much from each other.

Added input sanitization for null array
Avoid copying the String contents into a C-array by using .c_str() to get a pointer to the contents.
Up to you what you want to

Removed settings validity checking that didn't do anything. It was checking for a max value of 0b1111 but the size of the bitfield was only 4-bits anyways. C++ will simply truncate the bits if you try to assign a larger int type to this smaller one, so it's actually impossible to store larger than 0b1111 in this location. I've left the validity check function behind because I like the practice of explicit fault handling you've setup around it, and you should feel free to toss more checks into here as you change things.

Testing

[x] yolo
[x] I have no idea if it compiles
[x] merry xmas!

Merged with fixes to make it compile.


Fix fee check during transaction building

Background:
When ergo-ts does input selection, it checks if the transaction already has a box for the fee (and if it doesn't, it creates one for you)
Problem:
The check for whether or not the fee was already included doesn't check if the address itself is the fee address, but rather whether or not it's the constant fee object. Object comparison in JS does not do field-wise comparison and instead check if the object itself is the same reference.
Solution:
This new code properly checks the fee address is the same by comparing the address base58 content

@SebastienGllmt can you pleases add a test for this property - that fails before this PR and pass after it

@catena2w pushed a test. Notably, this line passes after my commit expect(tx.outputs).toHaveLength(3), but before it, it would fail (the fee address would end up being included twice in the final transaction, so there will be 4 outputs)


[FLINK-9674][tests] Replace hard-coded sleeps in QS E2E test

What is the purpose of the change
This PR replaces a hard-coded sleep in a QueryableState end-to-end test. The test was sleeping for 65 seconds after the TM was restarted, to wait until the restarted.
Instead we now first wait for the job restart procedure to kick in (using a new method to check for state transitions) and then waiting for the job to run.
Additionally

reduce heartbeat.timeout to speed up TM loss detection
fix common#wait_job_running returning true for scheduled jobs, we now pass the -r flag
simplify jar paths in QS test (now relative to END_TO_END_DIR)
change test-runner-common#cleanup to use existing common#clean_[log|stdout]_files functions

Verifying this change

manually verified

+1

@florianschmidt1994 I don't see the comment you're referring to :(
(Did you start a review, but wrote your comment separately? Then your review would still be in progress!)
The issues you identified are certainly valid, but I'm wondering if it really makes sense to invest time into this now.
There've been discussions about writing a python/java based framework for the tests (and I've already started tinkering on a java version); so any significant changes we make to the bash-scripts might be subsumed soon™.

(Did you start a review, but wrote your comment separately? Then your review would still be in progress!)

Yes :D I submitted it now

The issues you identified are certainly valid, but I'm wondering if it really makes sense to invest time into this now.
There've been discussions about writing a python/java based framework for the tests (and I've already started tinkering on a java version); so any significant changes we make to the bash-scripts might be subsumed soon™.

Alright, then let's leave it this way and we can still take care of it should we run into problems with this in the future

merging.


Fix ignored website.ipfs.io IPNS test case

The current implementation checks that it resolves to a specific CID but this is flaky if they happen to update their site. The test case includes a FIXME for ideas.

Closing this in favor of #83, this is no longer so good first issue.


Downloading from GET IPLAYER AUTOMATER Version 1.21.9<PHONE_NUMBER>1)

INFO: Loading proxy settings...
INFO: No proxy to load
INFO: Proxy load complete.
INFO: No proxy will be used
AppController: Starting Downloads
Downloading Show 1/1:
Downloading Coronation Street
INFO: Preparing Request for Auth Info
INFO: Requesting Metadata.
DEBUG: Metadata response status code: 200
INFO: Metadata processed.
DEBUG: youtube-dl args:["https://www.itv.com/hub/coronation-street/1a0694a10313", "-f", "mp4/best", "-o", "/Users/JamesHoskins/Desktop/BBC/Coronation Street/Coronation Street.s01e10313.30 Apr 2021.%(ext)s", "--verbose"]
DEBUG: youtube-dl environment: ["PYTHONPATH": "/Users/JamesHoskins/Desktop/Get iPlayer Automator.app/Contents/Resources", "PATH": "/Users/JamesHoskins/Desktop/Get iPlayer Automator.app/Contents/MacOS:/Users/JamesHoskins/Desktop/Get iPlayer Automator.app/Contents/Resources/get_iplayer/utils/bin:/usr/bin"]
[debug] System config: []
[debug] User config: []
[debug] Custom config: []
[debug] Command-line args: [u'https://www.itv.com/hub/coronation-street/1a0694a10313', u'-f', u'mp4/best', u'-o', u'/Users/JamesHoskins/Desktop/BBC/Coronation Street/Coronation Street.s01e10313.30 Apr 2021.%(ext)s', u'--verbose']
[debug] Encodings: locale US-ASCII, fs utf-8, out None, pref US-ASCII
[debug] youtube-dl version 2020.12.12
[debug] Python version 2.7.16 (CPython) - Darwin-17.7.0-x86_64-i386-64bit
[debug] exe versions: ffmpeg 4.3.2-tessus
[debug] Proxy map: {}
[debug] Using fake IP <IP_ADDRESS> (GB) as X-Forwarded-For.
[ITV] 1a0694a10313: Downloading webpage
[ITV] 1a0694a10313: Downloading JSON metadata
ERROR: Unable to download JSON metadata: HTTP Error 500: Internal Server Error (caused by HTTPError()); please report this issue on https://yt-dl.org/bug . Make sure you are using the latest version; type  youtube-dl -U  to update. Be sure to call youtube-dl with the --verbose flag and include its complete output.
File "/Users/JamesHoskins/Desktop/Get iPlayer Automator.app/Contents/Resources/youtube-dl/youtube_dl/extractor/common.py", line 632, in _request_webpage
return self._downloader.urlopen(url_or_request)
File "/Users/JamesHoskins/Desktop/Get iPlayer Automator.app/Contents/Resources/youtube-dl/youtube_dl/YoutubeDL.py", line 2248, in urlopen
return self._opener.open(req, timeout=self._socket_timeout)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 435, in open
response = meth(req, response)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 548, in http_response
'http', request, response, code, msg, hdrs)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 473, in error
return self._call_chain(*args)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 407, in _call_chain
result = func(*args)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 556, in http_error_default
raise HTTPError(req.get_full_url(), code, msg, hdrs, fp)
youtube-dl finished downloading
AppController: Downloads Finished

[debug] youtube-dl version 2020.12.12

Too old. You must update youtube-dl to the latest version first.
Or maybe you should ask https://github.com/Ascoware/get-iplayer-automator/issues

I have updated youtube-dl to the latest version and I still get the error, which issue is the a duplicate of as I can't find it.

the various recent issues opened about error 500 fetching the playlist JSON


Fix some tests and add a workflow configuration to run them on PRs

This is a first cut at fixing some of the tests, since none of them ran successfully when I cloned this repo. It’s also a follow-on to #39 and needs the commits from it to work. This is also incomplete; I’m not sure I’ll have time to keep working on it, but hopefully it’s a good start for someone else.
What I did so far:

Fixed the API tests in the server so that they run.

Changed a few things in the scripts so that errors are handled correctly instead of swallowed.
Added some error-checking/logging to the test utilities so I could see what was going wrong.
Ensure the database is disconnected correctly so tests don’t hang.
Use the correct users. The tests rely on a lot of users listed in the seeds, and several of those users were changed or removed in b465e776be3b2d0d884c3fed20bd630fdaa3610e. I’ve added them back, but hopefully with more obvious names that mark them as needed for tests. It doesn’t look like the seeds are meant to be used in production, but if they are being used in production, this change is not OK, and should not be merged as-is!

Fixed a lint warning that I think was also causing some test issues.
Added a workflow file to run tests and linters on GitHub actions.

Still to do:

[ ] Fix DB tests so they can run in a non-interactive environment (it always displays a password prompt right now).
[ ] Fix DB tests to use the same database as the API tests. (There is a different database name for two groups of tests; one is hardcoded and does not obey the .env file; I’m not sure what the history or reasoning was here, but it seems bad at first glance. Please LMK if this is for a good reason and shouldn’t change!)
[ ] Add credentials and configuration so the e-mail tests can run on GitHub Actions. I’m not sure I’m the right person to do this and don’t have whatever credentials are supposed to be used right now. Who does?

Other bits worth noting:

The client package has two test scripts (test:unit and test:e2e), but neither has actual tests behind them, so they just fail if you try and run them.
The server DB tests have their own set of seeds, which is a little complicated.
I added test users to the server seeds. I think this is OK since they don’t look like they’re meant to be used in production, but if we are using them in production, that’s not good.
Where possible, I like to use https://github.com/wearerequired/lint-action for linting, since it surfaces lint warnings and errors as check objects on the actual line they occur on in the files tab on PRs (it’s really nice!). That doesn’t work with all the extra magic vue-cli-service lint adds in the client package, though, so I didn’t use it here. Lint errors will still fail the build, but warnings won’t, so they’ll be easier to miss. Make sure you click the “details” link for the lint job, since there are already several warnings! https://github.com/usdigitalresponse/usdr-gost/runs/5281030868?check_suite_focus=true

Where possible, I like to use https://github.com/wearerequired/lint-action …that doesn’t work with all the extra magic vue-cli-service lint adds in the client package, though, so I didn’t use it here.

It looks like GitHub has added some extra magic to automatically detect these kind of warnings and add them, so this actually just works now! Nevermind this bullet point. :)

@mattbroussard can we close this one? We should be able to salvage the github ci workflow and readme changes.

This was originally meant as a bit of quick help for @cmroberts before she moved on. If it’s pretty hard to integrate at this point, definitely feel free to salvage what’s useful and close it!

Closing for now. Will pull out parts of it in separate PRs as we continue to improve the test coverage.


Latest version of NodeJs in Visual Studio Code

Hi Team,
I see latest versions of VSCode have old/ vulnerable version of Nodejs and is same being used in plugins like Remote SSH.
Can we get an option to use installed node instead to have control on the version?
https://code.visualstudio.com/updates/v1_78#_engineering
Thank You.

Updating to Node 18 will be done as part of https://github.com/microsoft/vscode/issues/184021


There should be online docs.

As a minimum it should be just a list of public types and function signatures generated by cargo doc.

Docs are now available here: https://docs.rs/mitochondria.


Cap control rod levels to be between 0 and 100

Simplified setRods to account for recent ER API changes.
Now the program will ensure that the rod level will always be from 0-100

Should fix issue #3

Pastebin updated


Fixing compression issue if content-range header is present

Don't compress body if content-range header is present
Set content-size header if it's present in the abstract headers

This should fix this issue:
https://github.com/microsoftgraph/msgraph-sdk-go-core/issues/295

@microsoft-github-policy-service agree

@andrueastman I updated the CHANGELOG. I hope I did this as it is intended to happen.


RpcContext Initial commit

Ⅰ. Describe what this PR did
Created RpcContextTest unit test which partly tests RpcContext class in order to improve test coverage
Ⅱ. Does this pull request fix one issue?
fixes #189
Ⅲ. Why don't you add test cases (unit test/integration test)?
Ⅳ. Describe how to verify it
Ⅴ. Special notes for reviews

Codecov Report

Merging #998 into develop will increase coverage by 0.38%.
The diff coverage is n/a.

@@              Coverage Diff              @@
##             develop     #998      +/-   ##
=============================================
+ Coverage      38.44%   38.82%   +0.38%
- Complexity      1046     1068      +22
=============================================
  Files            218      218
  Lines           8681     8681
  Branches        1078     1078
=============================================
+ Hits            3337     3370      +33
+ Misses          4924     4891      -33
  Partials         420      420

Impacted Files
Coverage Δ
Complexity Δ

...re/src/main/java/io/seata/core/rpc/RpcContext.java
38.82% <0%> (+38.82%)
22% <0%> (+22%)
:arrow_up:

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update aea407e...ac577f1. Read the comment docs.

@kaitithoma CI was failed,pls check.

@kaitithoma CI was failed,pls check.

we removed it for now because we couldn't solve the problem

it seems this PR contains many eclipse history files.pls remove them.

.metadata folder is only for eclipse.it should not be contained.

it seems this PR contains many eclipse history files.pls remove them.

We solved it. Thank you!

Thanks.i left some comments.

@kaitithoma you can install the P3C plugin to help you check the code style.please refer to here :https://github.com/seata/seata/blob/develop/CONTRIBUTING.md


Dependency to commons-logging

Do we need it? Can we exclude it from httpclient?

@lukasniemeier-zalando I have no idea, but I guess you have better expertise to decide :smile:

I am assigning the issue to @whiskeysierra as I'm arguing with him about it :wink:

I am proposing to do the following in the tokens pom.xml:
<dependency>
    <groupId>org.apache.httpcomponents</groupId>
    <artifactId>httpclient</artifactId>
    <version>x.x.x</version>
    <exclusions>
        <exclusion>
            <artifactId>commons-logging</artifactId>
            <groupId>commons-logging</groupId>
        </exclusion>
    </exclusions>
</dependency>

Then users of tokens need to either have commons-logging or something else (e.g. jcl-slf4j bridge jcl-over-slf4j) on the classpath. This way we allow higher flexibility for the users while not polluting the classpath. See also here.


Not all expressions are accepted

Hello,
Sorry to bother you on a holiday. I'm trying to use your package but it seems not all expressions are accepted. For the two following snippets, the former works, and the latter gets TypeError("Cannot convert expression to float"):
import sympy as sp
import SumOfSquares as sos

d, a = sp.symbols('d a')

p = a+d**2

prob = sos.SOSProblem()
prob.add_sos_constraint(p,[d])
A = prob.sym_to_var(a)
prob.set_objective('min',A)
prob.solve()
print(A.value)

Outputs correct answer of zero.
import sympy as sp
import SumOfSquares as sos

d, a = sp.symbols('d a')

p = (a+d**2)**2

prob = sos.SOSProblem()
prob.add_sos_constraint(p,[d])
A = prob.sym_to_var(a)
prob.set_objective('min',A)
prob.solve()
print(A.value)

  File "***\ipykernel_9940\1465085736.py", line 2, in <module>
    prob.add_sos_constraint(p,[d])

  File "***\anaconda3\lib\site-packages\SumOfSquares\SoS.py", line 78, in add_sos_constraint
    mono_to_coeffs = dict(zip(poly.monoms(), map(self.sp_to_picos, poly.coeffs())))

  File "***\anaconda3\lib\site-packages\SumOfSquares\SoS.py", line 51, in sp_to_picos
    return pic.Constant(float(expr))

  File "***\anaconda3\lib\site-packages\sympy\core\expr.py", line 351, in __float__
    raise TypeError("Cannot convert expression to float")

TypeError: Cannot convert expression to float

Defining p = a+d**2 and then defining p = p*p also throws the same error. It seems that this error is most common when attempting to use sympy arguments to functions from math or numpy packages but that should not be the case here.
Eventually I'm trying to work up to something this, but I am getting the error as before:
d1, d2, alpha = sp.symbols('d1 d2 alpha', commutative=True)
    d = sp.Matrix([[d1],[d2]])
    C = Dx.T*d
    C = C[0,0]
    B = (d.T*D2x*d + (alpha * d.T*d))/2
    B = B[0,0]
    A = (d1*(d.T*D3x[0,:,:].tomatrix()*d) + d2*(d.T*D3x[1,:,:].tomatrix()*d))/6
    A = A[0,0]

    p = B**2 - 4*A*C

    prob = SOSProblem()
    prob.add_sos_constraint(p,[d1, d2])
    Alpha = prob.sym_to_var(alpha)
    prob.set_objective('min',Alpha)
    prob.solve()
    print(Alpha.value)

Any idea what could be the problem? Thanks!

Ah I think the issue here is that SumOfSquares.py currently only support affine expressions as coefficients of polynomials, although it should also be possible to support PSD quadratic coefficients. It shouldn't be too hard for me to add this feature soon, but for now you can use the following "hack" to make the example work:
import sympy as sp
import SumOfSquares as sos
d, a, a2 = sp.symbols('d a a2')
p = d**4 + 2*a*d**2 + a2

prob = sos.SOSProblem()
prob.add_sos_constraint(p,[d])
A, A2 = prob.sym_to_var(a), prob.sym_to_var(a2)
prob.add_constraint(A**2 <= A2)
prob.set_objective('min', A2)
prob.solve()
print(A.value)

Ah that makes sense, I should have been able to see that. Thank you!


[ENH] wrap a PSD estimation method around scipy.signal.welch

wrap a PSD estimation method around scipy.signal.welch,
and write test for it,
(but there is no 'aeon.testing.data_generation' module
in the lastest version of aeon-neuro)

Any other comments?

I cannot find PCASeriesTransformer aeon/aeon/transformations/series/_pca.py in the init aeon/aeon/transformations/series/init.py.

I think it is wrong or not complete. We want PSD matrics to calculate Riemannian distance, but we got just a number from this implementation.


node setups wallet issue

Describe the bug
when installing node
cp .env.sample .env
After the sudo nano .env command, it didn't ask us to enter the wallet key and address, but it only wants the wallet key
the right one

the problem experienced

Steps to reproduce
this line should be written in the missing place manually
L2_SUGGESTED_FEE_RECIPIENT=wallet adress
Additional context
Additional context here.

feat(scope): description of feature

[optional scope]:
[optional body]
[optional footer(s)]

Can I use a different wallet for the SUGGESTED_FEE?
Example
L1_PROVER_PRIVATE_KEY= Wallet A
L2_SUGGESTED_FEE_RECIPIENT= Wallet B

no, it must be the same wallet address and key

Can I use a different wallet for the SUGGESTED_FEE?
Example L1_PROVER_PRIVATE_KEY= Wallet A L2_SUGGESTED_FEE_RECIPIENT= Wallet B

I believe the answer is yes u can :)


Build skips node_modules/pixi.js

Description
Some of the modules in node_modules are being compiled into vendor.js successfully, however, the contents of pixi.js are not, and I'm not sure how to force it.  There are no error messages, everything seems successful.
Expected behavior
The multitudinous contents of pixi.js should be packed in to vendor.js, or there is an error or warning telling me that it skipped the module for whatever reason.
Actual behavior
No pixi js :(
Environment

Brunch: ^2
Node: 4.6.1
NPM: 2.15.9
Operating system: Fedora 24

package.json contents
{
  "name": "brunch-app",
  "description": "Description",
  "author": "Your Name",
  "version": "0.1.0",
  "repository": {
    "type": "git",
    "url": ""
  },
  "scripts": {
    "start": "brunch watch --server",
    "build": "brunch build --production"
  },
  "dependencies": {
    "adaptive-quadratic-curve": "^1.0.2",
    "babel-brunch": "^6.0.6",
    "babel-preset-es2015": "^6.18.0",
    "babel-preset-es2016": "^6.16.0",
    "pixi.js": "^4.1.1"
  },
  "devDependencies": {
    "brunch": "^2.0.0",
    "javascript-brunch": "^2.0.0",
    "css-brunch": "^2.0.0",
    "uglify-js-brunch": "^2.0.0",
    "clean-css-brunch": "^2.0.0",
    "auto-reload-brunch": "^2.0.0"
  }
}

brunch config contents
// See http://brunch.io for documentation.
exports.files = {
  javascripts: {
      joinTo: {
          'app.js' : /app/,
          'vendor.js' : /^(?!app)/
      }
  },
  stylesheets: {joinTo: 'app.css'},
  templates: {joinTo: 'app.js'},
};

exports.plugins = {
    babel: {
        presets: ['es2015', 'es2016']
    }
};

Nevermind.  Brunch is smarter than I am.  I was waiting for it to appear in the vendor.js before I bothered to require() it.  However Brunch was waiting for me to require() it before it made it appear in vendor.js


Fix vdb_upload runtime error

Description

Add ControlMessage to the accepted_types for InferenceStage when in Python mode
fix import of CppTensorMemory
Set default value of ['rss'] for --source_type avoids issue where command line flag values are ignored.
Fix bug in overrides of config fixture which prevented parameterization on the use_cpp fixture.
fix type-o in config value stop_after_rec not stop_after_sec
Ensure a default int value for stop_after_rec to avoid schema validation error
Revert the default value for --vector_db_resource_name back to 'RSS', allowing the output of running this example to be used as the input for the RAG pipeline

Closes #1642
Closes #1645
By Submitting this PR I confirm:

I am familiar with the Contributing Guidelines.
When the PR is ready for review, new or existing tests cover these changes.
When the PR is ready for review, the documentation is up to date with these changes.

/merge


An issue about the Ceiling function

Description
As described in the document, qsharp uses 64 bits to store the variable of the type Int. Values range from  -9,223,372,036,854,775,808 to 9,223,372,036,854,775,807.  The function Ceiling receives a Double argument and returns the smallest integer greater than or equal to the argument. Obviously, the value<PHONE_NUMBER>85477580 is in the range of the type Int and the type Double，when passing<PHONE_NUMBER>85477580.0 to the function Ceiling, it returns<PHONE_NUMBER>85477632 instead of<PHONE_NUMBER>85477580. There seems to be a lack of accuracy. Is this a correct output of the function Ceiling?
Testcase
namespace NISLNameSpace {
	open Microsoft.Quantum.Intrinsic;
	open Microsoft.Quantum.Math;

	operation NISLOperation() : Unit {
	    Message($"{Ceiling(922337203685477580.0)}");
	}

	@EntryPoint()
	operation main() : Unit {
		NISLOperation();
	}
}

Output
922337203685477632

Expected Output
922337203685477580

Environment
Operating system: Windows 10
dotnet version: 3.1.414
QDK: 0.21.2111177148
Command
dotnet run

Thanks for reporting this issue @QuXing9. This issue stems from imprecision in the floating-point representation. The output is consistent with the IEEE specification for 64-bit floating points. Other languages will give the same output, e.g., in Python:
from math import ceil
print(ceil(922337203685477580.0))

outputs
922337203685477632


Add Input option to disable terminal start/stop

Fix for issue #115

Cool thanks, looks good. Will try to do a release this weekend.


Cannot find the Load Once option

When I followed the tutorial to open XivAlexander <IP_ADDRESS> with administrator privileges, I couldn't find the Load Once option in the tutorial

Oh,I know what happenen after reading a issue, this problem is solved.
Thanks.


[CheckpointExecutor] Add more debugging logs

@mwtian no this is just for actual debugging. Will still need to run RUST_LOG=sui=DEBUG. I could change some of these to info! but didn't wanna add too much spam. What are your thoughts?

We can leave them as they are and update when needed.


AttributeError: module 'torchaudio.io' has no attribute 'AudioEffector'

🐛 Describe the bug
``I tried to run your notebook from the tutorial AUDIO DATA AUGMENTATION (in the following link: https://pytorch.org/audio/main/tutorials/audio_data_augmentation_tutorial.html).
The notebook starts by importing and printing the current versions:
import torch
import torchaudio
import torchaudio.functional as F

print(torch.__version__)
print([torchaudio.__version__](https://docs.python.org/3/library/stdtypes.html#str))

Your output is as follows:
2.1.0.dev20230614
2.1.0.dev20230614

My output is different:
2.0.1+cu117
2.0.2+cu117

Later on, this line of code appears in the notebook:
effector = torchaudio.io.AudioEffector(effect=effect)

And I get the following error:
AttributeError: module 'torchaudio.io' has no attribute 'AudioEffector'

This is probably because of the different versions. I tried to install the latest version (Nightly) to colab from PyTorch (
https://pytorch.org/) using pip:
!pip3 install --pre torch torchvision torchaudio --index-url https://download.pytorch.org/whl/nightly/cu121

I didn't get any error, but when checking for the versions, they didn't change.
I also tried to install is like this:
!pip install torchaudio==2.1.0

But got this error:
ERROR: Could not find a version that satisfies the requirement torchaudio==2.1.0 (from versions: 0.11.0, 0.12.0, 0.12.1, 0.13.0, 0.13.1, 2.0.0, 2.0.1, 2.0.2)
ERROR: No matching distribution found for torchaudio==2.1.0

Is there a way to use the same version as in your example, so I can run your notebook and use the latest functions?
Versions
--2023-06-20 08:43:59--  https://raw.githubusercontent.com/pytorch/pytorch/main/torch/utils/collect_env.py
Resolving raw.githubusercontent.com (raw.githubusercontent.com)... <IP_ADDRESS>, <IP_ADDRESS>, <IP_ADDRESS>, ...
Connecting to raw.githubusercontent.com (raw.githubusercontent.com)|<IP_ADDRESS>|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 21676 (21K) [text/plain]
Saving to: ‘collect_env.py’

collect_env.py      100%[===================>]  21.17K  --.-KB/s    in 0.001s

2023-06-20 08:43:59 (14.7 MB/s) - ‘collect_env.py’ saved [21676/21676]

Collecting environment information...
PyTorch version: 2.0.1+cu118
Is debug build: False
CUDA used to build PyTorch: 11.8
ROCM used to build PyTorch: N/A

OS: Ubuntu 20.04.6 LTS (x86_64)
GCC version: (Ubuntu 9.4.0-1ubuntu1~20.04.1) 9.4.0
Clang version: 10.0.0-4ubuntu1
CMake version: version 3.25.2
Libc version: glibc-2.31

Python version: 3.10.12 (main, Jun  7 2023, 12:45:35) [GCC 9.4.0] (64-bit runtime)
Python platform: Linux-5.15.107+-x86_64-with-glibc2.31
Is CUDA available: False
CUDA runtime version: 11.8.89
CUDA_MODULE_LOADING set to: N/A
GPU models and configuration: Could not collect
Nvidia driver version: Could not collect
cuDNN version: Probably one of the following:
/usr/lib/x86_64-linux-gnu/libcudnn.so.8.9.0
/usr/lib/x86_64-linux-gnu/libcudnn_adv_infer.so.8.9.0
/usr/lib/x86_64-linux-gnu/libcudnn_adv_train.so.8.9.0
/usr/lib/x86_64-linux-gnu/libcudnn_cnn_infer.so.8.9.0
/usr/lib/x86_64-linux-gnu/libcudnn_cnn_train.so.8.9.0
/usr/lib/x86_64-linux-gnu/libcudnn_ops_infer.so.8.9.0
/usr/lib/x86_64-linux-gnu/libcudnn_ops_train.so.8.9.0
HIP runtime version: N/A
MIOpen runtime version: N/A
Is XNNPACK available: True

CPU:
Architecture:                    x86_64
CPU op-mode(s):                  32-bit, 64-bit
Byte Order:                      Little Endian
Address sizes:                   46 bits physical, 48 bits virtual
CPU(s):                          2
On-line CPU(s) list:             0,1
Thread(s) per core:              2
Core(s) per socket:              1
Socket(s):                       1
NUMA node(s):                    1
Vendor ID:                       GenuineIntel
CPU family:                      6
Model:                           79
Model name:                      Intel(R) Xeon(R) CPU @ 2.20GHz
Stepping:                        0
CPU MHz:                         2199.998
BogoMIPS:                        4399.99
Hypervisor vendor:               KVM
Virtualization type:             full
L1d cache:                       32 KiB
L1i cache:                       32 KiB
L2 cache:                        256 KiB
L3 cache:                        55 MiB
NUMA node0 CPU(s):               0,1
Vulnerability Itlb multihit:     Not affected
Vulnerability L1tf:              Mitigation; PTE Inversion
Vulnerability Mds:               Vulnerable; SMT Host state unknown
Vulnerability Meltdown:          Vulnerable
Vulnerability Mmio stale data:   Vulnerable
Vulnerability Retbleed:          Vulnerable
Vulnerability Spec store bypass: Vulnerable
Vulnerability Spectre v1:        Vulnerable: __user pointer sanitization and usercopy barriers only; no swapgs barriers
Vulnerability Spectre v2:        Vulnerable, IBPB: disabled, STIBP: disabled, PBRSB-eIBRS: Not affected
Vulnerability Srbds:             Not affected
Vulnerability Tsx async abort:   Vulnerable
Flags:                           fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush mmx fxsr sse sse2 ss ht syscall nx pdpe1gb rdtscp lm constant_tsc rep_good nopl xtopology nonstop_tsc cpuid tsc_known_freq pni pclmulqdq ssse3 fma cx16 pcid sse4_1 sse4_2 x2apic movbe popcnt aes xsave avx f16c rdrand hypervisor lahf_lm abm 3dnowprefetch invpcid_single ssbd ibrs ibpb stibp fsgsbase tsc_adjust bmi1 hle avx2 smep bmi2 erms invpcid rtm rdseed adx smap xsaveopt arat md_clear arch_capabilities

Versions of relevant libraries:
[pip3] numpy==1.22.4
[pip3] torch==2.0.1+cu118
[pip3] torchaudio==2.0.2+cu118
[pip3] torchdata==0.6.1
[pip3] torchsummary==1.5.1
[pip3] torchtext==0.15.2
[pip3] torchvision==0.15.2+cu118
[pip3] triton==2.0.0
[conda] Could not collect

I tried to run your notebook from the tutorial AUDIO DATA AUGMENTATION (in the following link: https://pytorch.org/audio/main/tutorials/audio_data_augmentation_tutorial.html).

You are looking at the tutorials in main branch, which expects nightly build. It uses features from nightly build, so the failure is expected.

I tried to install the latest version (Nightly) to colab from PyTorch (https://pytorch.org/) using pip:

In my experience, it works fine when I uninstall related packages first. e.g. pip uninstall torch torchaudio torchvision.

This issue is more about installation and not about codebase itself, so I will close this. stackoverflow is often more suitable for installation-related questions.


Fix audio length

Reference Issues/PRs
#39
What does this implement/fix? Explain your changes.
Below audio files have been looped to have length between 1.5s - 2.5s:

3.wav
4.wav
5.wav
6.wav
7.wav
8.wav
9.wav
10.wav
11.wav

It's now ready for your review @sepandhaghighi


fix to allow building on both Ubuntu 16.04 and 18.04.

As promised in https://github.com/mosra/magnum/issues/248, here is a PR that will allow builds to work for both Ubuntu 18.04 and 16.04. Note that some of the changes are also to allow the build to work correctly in Launchpad, as it builds from a clean chroot every time dependencies may not be available.

Merged in f43977665ecf43ac83f0bcb0f56ebcbb5cba6a06, thanks a lot! :)


Prevent selecting values that don't lie on a step

Description
This prevents the slider input "settling" on a value that doesn't lie on a step.
Related Issue
https://github.com/piitaya/lovelace-mushroom/issues/576
Motivation and Context
In my opinion, I don't believe the slider should show a value that is not represented by the entity. Going from 33% to 40% doesn't speed up the fan -- the value of 33% is sent to Home Assistant both times.
This behavior is most visible on fans, and admittedly I don't have other entity types that I can test this with. But I assume the same expectation exists for all stepped entities (fans, covers, etc.)
How Has This Been Tested
Given a fan with step size 33.3333:

Fan is initially off
User drags or tap position ~40%
Slider "snaps" to position 33% (fan is set to 33%, aka low) - this is expected, existing behavior in mushroom
User again drags or taps again to position ~40%, slider will not "snap back" to the 33% mark - this PR aims to fix that behavior

Types of changes

[X] 🐛 Bug fix (non-breaking change which fixes an issue)
[ ] 🚀 New feature (non-breaking change which adds functionality)
[ ] 🌎 Translation (addition or update a translation)
[ ] ⚠ Breaking change (fix or feature that would cause existing functionality to change)

Checklist

[X] My code follows the code style of this project.
[ ] My change requires a change to the documentation.
[ ] I have updated the documentation accordingly.
[X] I have tested the change locally.

With this change, we don't have a smooth slider isn't it ?

Ok, seems good to me 🙂


Redesigning protostar.toml 19 — Docs

Add docs for the configuration file v2. Move the content to a new page to improve cohesion.
Related #477

I think this piece of documentation is badly structured. In my opinion, docs should only focus on current state, so treat V2 as one and only valid format in main part of documentation. Migration path from V1 should only be mentioned in a subsection of Project initialization page

restructure


Adding Strucmotif and Chemical similarity search capabilities

Thanks @santiblaumann! Hope your year is starting off well!


Broken internet and DNS error after starting Fakenet

After starting fakenet, my internet in my Windows 7 VM went out with an error stating that there was a DNS error. I restarted my home router, but that's not working.  I tried to use a work around from another post with a command netsh interface ip set dns name="Ethernet" dhcp, but that didn't work. Any ideas will be greatly appreciated.

This is expected behavior. Fakenet will reconfigure DNS settings and intercept most/all traffic from the running host. You should run fakenet in dedicated virtual machines, likely in "Host-Only" mode, for analysis.

this killed my pc internet anyway to reverse it?


Reduce Cypress test flakiness

Signed-off-by: Mohammad Qureshi<EMAIL_ADDRESS>Description
The first test in the first suite being run by Cypress seems to sometimes fail on timeouts, even when the Dashboards endpoint has been verified to be reachable before tests start (this seems to be more frequent in the CIs, especially now that we're running so many). It's not ideal but this change adds retries to both specs to see if the retry can account for the flakiness to lead to more consistent runs.
Issues Resolved
[List any issues this PR will resolve]
Check List

[x] Commits are signed per the DCO using --signoff

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.

Codecov Report

Merging #574 (05f379a) into main (8c73802) will not change coverage.
The diff coverage is n/a.

@@            Coverage Diff            @@
##               main     #574   +/-   ##
=========================================
  Coverage     61.36%   61.36%
  Complexity      112      112
=========================================
  Files            73       73
  Lines          2472     2472
  Branches        265      265
=========================================
  Hits           1517     1517
  Misses          778      778
  Partials        177      177

Flag
Coverage Δ

opensearch-notifications
61.36% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

I'm sometimes seeing flaky CI failures on Mac unrelated to the written tests themselves.
One example is a timeout for the Cypress verification which seems to be related to this. The only proper solution here would be to upgrade to a newer version of Cypress where we can provide CYPRESS_VERIFY_TIMEOUT to override the default value. If I keep seeing Mac specific flaky issues, I'll probably remove it from the matrix for now until the CI failure noise can be reduced.

The retries have fixed the "loading page" flakiness issue for the first test in the suite, however, I'm still seeing test flakiness in failing to find elements in the tests sometimes (seems to be more frequent in Windows, could be because it's just slower):
1) Test edit senders
       edits ses sender region:
     AssertionError: Timed out retrying after 60000ms: Expected to find element: `2`, but never found it. Queried from element: [ <input#_selection_column_GmCZ6YQBwst8bUDIbd1F-checkbox.euiCheckbox__input>, 1 more... ]
      at Context.eval (http://localhost:5601/__cypress/tests?p=.cypress\integration\email_senders_and_groups.spec.js:250:65)

  2) Test delete senders
       deletes ses senders:
     AssertionError: Timed out retrying after 60000ms: Expected to find element: `input[placeholder="delete"]`, but never found it.
      at ensureExistence (http://localhost:5601/__cypress/runner/cypress_runner.js:162649:25)
      at $Cy.ensureElExistence (http://localhost:5601/__cypress/runner/cypress_runner.js:162667:12)
      at ensureExistence (http://localhost:5601/__cypress/runner/cypress_runner.js:151782:23)
      at onFailFn (http://localhost:5601/__cypress/runner/cypress_runner.js:151820:9)
      at tryCatcher (http://localhost:5601/__cypress/runner/cypress_runner.js:10765:23)
      at Promise._settlePromiseFromHandler (http://localhost:5601/__cypress/runner/cypress_runner.js:8700:31)
      at Promise._settlePromise (http://localhost:5601/__cypress/runner/cypress_runner.js:8757:18)
      at Promise._settlePromise0 (http://localhost:5601/__cypress/runner/cypress_runner.js:8802:10)
      at Promise._settlePromises (http://localhost:5601/__cypress/runner/cypress_runner.js:8878:18)
      at _drainQueueStep (http://localhost:5601/__cypress/runner/cypress_runner.js:5472:12)
      at _drainQueue (http://localhost:5601/__cypress/runner/cypress_runner.js:5465:9)
      at ../../node_modules/bluebird/js/release/async.js.Async._drainQueues (http://localhost:5601/__cypress/runner/cypress_runner.js:5481:5)
      at Async.drainQueues (http://localhost:5601/__cypress/runner/cypress_runner.js:5351:14)

  3) Test create, edit and delete recipient group
       opens email addresses popup:
     AssertionError: Timed out retrying after 60000ms: Expected to find content: '1 more' within the element: [ <a.euiLink.euiLink--subdued.euiBreadcrumb.osdBreadcrumbs>, 1 more... ] but never did.
      at Context.eval (http://localhost:5601/__cypress/tests?p=.cypress\integration\email_senders_and_groups.spec.js:347:24)

  4) Test create, edit and delete recipient group
       deletes recipient groups:
     AssertionError: Timed out retrying after 60000ms: Expected to find content: 'No recipient groups to display' but never did.
      at Context.eval (http://localhost:5601/__cypress/tests?p=.cypress\integration\email_senders_and_groups.spec.js:361:51)

We'll need to revisit this and see if the Cypress test can be updated to fetch these elements in more dependable ways.

For the time being, I'm removing MacOS from the test matrix and we'll revisit any existing Cypress test flakiness but will not block on getting the version bumps in after this change is backported.


Add Async-Profiler Testing Framework

Added async-profiler testing framework. Testing framework tested to pass for all combinations of: Corretto; 8, 11, 17, 21, (22 Nightly if available). OS; Alpine Linux, Amazon Linux, MacOS. CPU Architecture; Arm64, x64
Change aborted: Includes additions to Output object of methods for more convenient asserts and outputs.
New change: OAssert static class for more convenient assert and output logging

With the changes made by @roy-soumadipta, the test framework has been finally integrated. Thank you all!


memcached 1.5.6 suddenly stops processing connections (CLOSE_WAIT issue)

Hi,
I'd like to to report an issue with memcached 1.5.6 (Ubuntu 18.04.1).
memcached                             1.5.6-0ubuntu1
libevent-2.1-6:amd64               2.1.8-stable-4build1
Linux 4.15.0-39-generic
The same app was working fine on Ubuntu 16.04 and memcached 1.4.25-2ubuntu1.4.
The daemon works perfectly fine until it suddenly stops processing new connections. The TCP connection is established but the daemon does not respond to any commands including "stats". The connections eventually enter the CLOSE_WAIT state and accumulate until the connection limit is reached. Restarting the daemon is the only way to fix it.
The daemon runs on 2 servers and both of them experience the same problem. The problem arises suddenly and does not seem to be caused by heavy load.
I've attached a file with detailed info about the issue including a gdb dump with the state of all the threads and a strace of the process that is accepting the connection.
Please let me know if there is any info I could add to the bug report.
memcached-bug.txt
Best Regards,
Tomas Styblo

There were some stability bugs in 1.5.6 - any chance you could try running the latest version? (1.5.12)

The problem only arises on our production servers once in a few days so I can't experiment with it as much as I would like. We have downgraded memcached and libevent to the versions from 16.04 to make sure it is not caused by something else in the system. I'll wait two weeks and then we may try the latest release. But I haven't found this type of bug in the release notes.

Hey,
Giving this a ping. Any chance you were able to verify the latest version? I haven't been able to reproduce (and nobody else has submitted a stack trace) in the meantime.

One last poke! I'll close this out if I don't hear back in a few days.


Convert to Python 3

Yikes! This was a shocker. I'd expect this back in 2012, but not on the tail end of 2015.
Proposed paths:

Since this uses the Chromium dependency Gyp, which is no longer actively maintained by Google (who ignores this issue, migrate the back-end to GN, which is supported probably least ideal
Work with a python 3 compatible port, like this
Manually port Gyp as part of the greater nodejs environment (thus becoming the active maintainer). Probably most ideal

Why?

It's good practice
Python 3, released in 2008, is officially older than the amount of time Python2 has remaining -- which is now just a touch over 4 years. (And, let's be honest -- if you're butting up against the EOL, without at least a year for dependencies to get their stuff in line, you're doing it wrong).
Most major projects are Python 3 compatible nowadays -- this makes node-gyp That Legacy Project We Have To Support

I would love to help with Python-3 compatibility, if decided to do so.

Yeah, maybe a good idea, would make life easier for a lot of people. I have prior-art for switching based on Python versions, my main concern here is that since we'd be using a fork for people that have v3 installed there would be disparity between the code being executed, not just the runtime used (unless the v3 fork of gyp can be used with v2?).
The alternative path is a wholesale upgrade, including Node core, and moving to v3 being required, but that would be really painful and we may face bigger barriers getting a gyp fork into core.

lack of python3 is a huge pain, and only going to get worse as distros like Fedora and Ubuntu default to python3. What needs to happen for this to happen?

Upstream gyp would have to convert to python 3, which is unlikely to happen if this 6 year old bug report is anything to go by: https://bugs.chromium.org/p/gyp/issues/detail?id=36
I'll close the issue, it's a duplicate of #193.

Work with a python 3 compatible port, like this

For posterity, I think this is a good idea in general but the devil is in the details.  gyp files have a lot of python code in them that is executed verbatim (as python 2 code obviously.)