Info
Pull request
Testing and Issues
You can test this entry and submit issues during the testing period of the Blockchain Contest contest.
Entries with serious issues will not be able to win the contest, but even minor issues might be important for overall results.
Voting
Comments
I've implemented manual DNS scm, but created PR rather than archive, cause thought that there were options (chose what you prefer). Hope it's not crucial, my submission hadn't to affect to the contestants cause was done close to deadline
Community, you provide me a few minuses without verbal feedback. It makes me sad. Could you write down your thoughts please, don't be shy )) If telegram decides to disqualify me (hope not) I will be enough punished anyway for my inattention. From the community I expect to get engineering view on the submission and of course your comments
A bit of advertising
I was using TDD approach for developing the smart-contract and the most time I've spent on creating the tools for it. Now you may use compile/test scripts with unified options no matter with what smartcontract. It was a crucial thing because without this approach it is really difficult to see edge cases (форма освобождает).
I was using TDD approach for developing the smart-contract and the most time I've spent on creating the tools for it. Now you may use compile/test scripts with unified options no matter with what smartcontract. It was a crucial thing because without this approach it is really difficult to see edge cases (форма освобождает).
Why I've chosen bash as a wrapped script? First of all, I wanted to limit the number of steps for the end user. If we have code on fc, but a message on fif, it introduces 1 additional step to compile end message. With bash I was able to hide it. Second - bash is more readable and knowledgeable tool (maybe based on experience) then fift, so it allows me to construct the tool I want. In fact if I had task to unify approach with building/generating - I would choose bazel + Starlark as build tool (even for fift/func), and would like to recommend it to TON as a build tool rather CMAKE, but I wanted not to introduce additional tools and make submission as lightweight as possible
Also I wasn't familiar with blockchain technologies, lisp and assembler technologies before the contest. It was just an adventure. Checking other submissions I've got that my work is competitive and it makes me glad. But of course I am not able to see all works (but I will try), so please comment your thoughts (especially if you are an experienced developer in the subject). I was especially worried about performance cause lack of knowledge can lead me to use wrong data structures or use something inefficiently
Cheers
Cheers
TO Chic Dolhin comment (сontinuation)
> You can put try/catch around
Have you handled the case? Interesting, I'm going to check your submission then and will share my thoughts
> Also do you really need update code
In my case, it was done for development, as drop-data. But rather then drop-data, updating code I think should be kept. Updating code lies in a different dimension then interface consistency. Also there is no reasons to break existed interface, rather then extend it
> You can put try/catch around
Have you handled the case? Interesting, I'm going to check your submission then and will share my thoughts
> Also do you really need update code
In my case, it was done for development, as drop-data. But rather then drop-data, updating code I think should be kept. Updating code lies in a different dimension then interface consistency. Also there is no reasons to break existed interface, rather then extend it
You have not added any comments yet...
by rating
Issues
Manual DNS:
+ Support for partial matches.
- Cycle in dnsresolve is useless, because pfxdict_get_q immediately returns suitable prefix.
- There is no way to completely delete expired domains.
- add_resource_record doesn't check that zone_cs matches whole domain, i.e. suffix is empty.
- Sanity checks can be performed client-side, because all requests are signed. There is no reason to do them in the contract.
- When domain is found, but category is not found the returned length must be non-zero.
- Ability to change code of an inited smart contract is very dangerous.
+ Support for partial matches.
- Cycle in dnsresolve is useless, because pfxdict_get_q immediately returns suitable prefix.
- There is no way to completely delete expired domains.
- add_resource_record doesn't check that zone_cs matches whole domain, i.e. suffix is empty.
- Sanity checks can be performed client-side, because all requests are signed. There is no reason to do them in the contract.
- When domain is found, but category is not found the returned length must be non-zero.
- Ability to change code of an inited smart contract is very dangerous.
TODO: what about balance depletion on error
That's an actual problem. If I spot faulty transaction on chain, I can replay it and drain resources until you update seqno with another.
You can put try/catch around, but you'll loose error information. It would look like message was successfully processed. Alternative solution would be to send internal message to contract itself. So that seqno is updated, but the actual processing happens in another transaction. This way you can track the errors by following created message.
Also do you really need update code? It's a trust issue. If I make calls into your contract I expect it to behave the same way everytime. Code update introduces uncertainties, will it always behave the way I expect or maybe an author will change the rules later?
That's an actual problem. If I spot faulty transaction on chain, I can replay it and drain resources until you update seqno with another.
You can put try/catch around, but you'll loose error information. It would look like message was successfully processed. Alternative solution would be to send internal message to contract itself. So that seqno is updated, but the actual processing happens in another transaction. This way you can track the errors by following created message.
Also do you really need update code? It's a trust issue. If I make calls into your contract I expect it to behave the same way everytime. Code update introduces uncertainties, will it always behave the way I expect or maybe an author will change the rules later?
I tried trycatch but it doesn't make sense. I just eat all of the erros. It's beter to transfer message into internal queue. Here is an explanation why you should not throw exceptions after accept. https://gist.github.com/rainydio/b59f20c2342c71c8d7df34e5795cf821
Nobody added any issues yet...