Optimize GQL and getBlock APIs (#201)

* Add optional block number filter to getLogs API

* Use block number while fetching block with transactions

* Fix for failing tests

* Use block number when fetching block objects

* Use block number when fetching a tx by hash

* Add back methods to get block objects by block hash

* Update run_unit_test.sh

Removing echo command, as it seems to be only change in CICD.

* Increase wait time for db setup in unit test job

Co-authored-by: Michael <michael@abastionofsanity.com>
This commit was merged in pull request #201.
This commit is contained in:
prathamesh0
2022-11-04 10:02:09 +05:30
committed by GitHub
co-authored by Michael
parent 33602aa0e0
commit cc17368c0d
7 changed files with 208 additions and 35 deletions
+2 -2
View File
@@ -6,7 +6,7 @@ set -e
start_dir=$(pwd)
temp_dir=$(mktemp -d)
cd $temp_dir
echo "git clone -b $(cat /tmp/git_head_ref) https://github.com/$(cat /tmp/git_repository).git"
git clone -b $(cat /tmp/git_head_ref) "https://github.com/$(cat /tmp/git_repository).git"
cd ipld-eth-server
@@ -17,7 +17,7 @@ rm -f /tmp/git_head_ref /tmp/git_repository
echo 'docker-compose up -d migrations ipld-eth-db'
docker-compose up -d migrations ipld-eth-db
trap "docker-compose down -v --remove-orphans; cd $start_dir ; rm -r $temp_dir" SIGINT SIGTERM ERR
sleep 30
sleep 60
# Remove old logs so there's no confusion, then run test
rm -f /tmp/test.log /tmp/return_test.txt