Skip to content
This repository was archived by the owner on Mar 12, 2020. It is now read-only.
This repository was archived by the owner on Mar 12, 2020. It is now read-only.

ciri: can't send transaction message from c-iota-workshop (send_hello) #1439

@bernardoaraujor

Description

@bernardoaraujor

Describe the bug
The first example of c-iota-workshop (hello_world), which just prints out info about the server, runs fine with cIRI:

$ ./bazel-bin/examples/hello_world -h bernardoaraujor.ydns.eu -p 14265
appName cIRI-mainnet 
appVersion 0.1.0-alpha 
latestMilestone UNVTSIKMIQRVWVXUBTAIXVYIVNHYLFPFKZXQSGDOVKANMKCLSWFDIHVPWGNDBNGNTQMNBWX99KGJA9999 
latestMilestoneIndex 1189733
milestoneStratIndex 0
neighbors 1 
packetsQueueSize 0 
time 1569601997498
tips 2 
transactionsToRequest 7

However the second example (send_hello) doesn't work.

Here's the source code. I forked from iota-community to add CLI parameters instead of hardcoded hostname and port: https://github.com/bernardoaraujor/c-iota-workshop/blob/master/examples/e02_send_hello.c

Here's the behaviour when I execute it:

bernardo@bernardo-UX51VZA:~/dev/c-iota-workshop$ ./bazel-bin/examples/send_hello -h bernardoaraujor.ydns.eu -p 14265
send transfer HTTP service error
Transaction failed with error code: 1156
bernardo@bernardo-UX51VZA:~/dev/c-iota-workshop$ ./bazel-bin/examples/send_hello -h bernardoaraujor.ydns.eu -p 14265
send transfer IRI response:
Transaction failed with error code: 1095

And here's the error message on cIRI logs (from error 1156... error 1095 didn't show anything):

2019-09-27 18:50:24:       api_http:    ERR: cIRI HTTP API currently does not support parsing such large requests.

To Reproduce
Steps to reproduce the behavior:

  1. Clone https://github.com/bernardoaraujor/c-iota-workshop
  2. Build examples $ bazel build ...
  3. Execute send_hello example: $ ./bazel-bin/examples/send_hello -h 51.158.64.80 -p 14265
  4. Check cIRI logs.

Expected behavior
When I point to an IRI full node, I get this response:

$ ./bazel-bin/examples/send_hello -h 185.244.195.45 -p 14265
send transfer OK
bundle hash: ZRKWZLHQSWJKDV9YBGBQZHRXFTPMOLTBBYXQCDJGSAFCJTKFSVSK9AGLVKXXQJYRGAYXGILNCBSWRSSGC
Transaction was sent.

Which is confirmed at:
https://thetangle.org/address/TOKLOARHKXQCVPPVVIPIJGLUTLTKFHYGMBBLOXJFYGSARLOTYFFSDZNYCOBOCNPGRMJWZCQBNOROUCE9G

Additional context
Philipp Blum (@citrullin) and I will make a presentation of IOTA on the upcoming Yocto Project Summit 2019. We want to do a live demo based on cIRI and the examples from c-iota-workshop. The presentation is scheduled for November 1st. It would be great to have all 6 examples working with cIRI until then.

Metadata

Metadata

Labels

No labels
No labels

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions