dvf / blockchain

A simple Blockchain in Python
MIT License
7.79k stars 2.74k forks source link

/transactions/new TypeError: argument of type 'NoneType' is not iterable #181

Open throwawat99 opened 4 years ago

throwawat99 commented 4 years ago

I keep getting the error in the title when using Postman, any ideas? I have followed and checked the instructions

jordge-bot commented 4 years ago

I got the same problem. anyone can help me? plz

sam-b0t commented 4 years ago

Maybe, you used a GET request where there should be a POST request?

MS-668 commented 4 years ago

Perhaps this will work, in Postman, click the choice "Body", choose "RAW", and at the right side of the choice "GraphQL", change the "Text" to "JSON"

dishaparekh213 commented 4 years ago

It still isn't working

aayushsaini commented 3 years ago

You guys must have been writing the body part for the POST request wrong in the postman. Try entering this inside the body section and then send the POST request

{
    "sender": "4a28aaa35a7f44d6aabbc6e55964688d",
    "receiver": "Home-Address",
    "amount": 2
}
rick12334 commented 3 years ago

LoL Hey sorry about that but I wasn’t paying no attention and start kidding about but that’s funny.

On Sun, Apr 4, 2021 at 8:31 AM Aayush Saini @.***> wrote:

You guys must have been writing the body part for the POST request wrong in the postman. Try entering this inside the body section and then send the POST request

{ "sender": "4a28aaa35a7f44d6aabbc6e55964688d", "receiver": "Home-Address", "amount": 2 }

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/dvf/blockchain/issues/181#issuecomment-813033672, or unsubscribe https://github.com/notifications/unsubscribe-auth/AMPM5DUJ4JLKE7L6DNP67IDTHBS4BANCNFSM4NXRWCJQ .

-- Impossible

RemmyLee commented 3 years ago

Perhaps this will work, in Postman, click the choice "Body", choose "RAW", and at the right side of the choice "GraphQL", change the "Text" to "JSON"

This is the correct solution.