Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Deploy to mainnet #1549

Merged
merged 6 commits into from
Jan 2, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,7 @@ gem "redis" # , "~> 4.2.0"
gem "hiredis-client"
gem "digest-crc"

# Backgroud Jobs

# Background Jobs
gem "sidekiq"
gem "rufus-scheduler"
# bulk insertion of data into database using ActiveRecord
Expand Down
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,9 +35,9 @@ $ bin/setup
## Create & Setup database

```shell
bundle exec rake db:create # (create db for development and test)
bundle exec rake db:migrate # (run migration for development db)
bundle exec rake db:migrate RAILS_ENV=test # (run migration for test db)
bundle exec rake db:create # (create db for development and test)
bundle exec rake db:schema:load # (run migration for development db)
bundle exec rake db:schema:load RAILS_ENV=test # (run migration for test db)
```

## Running Test
Expand Down
4 changes: 2 additions & 2 deletions app/models/ckb_sync/new_node_data_processor.rb
Original file line number Diff line number Diff line change
Expand Up @@ -782,7 +782,7 @@ def build_cells_and_locks!(
if contract
temp_hash = temp_hash.merge is_contract: true, contract_id: contract.id
else
contract = Contract.create code_hash: lock_script.script_hash
contract = Contract.create code_hash: lock_script.code_hash
temp_hash = temp_hash.merge contract_id: contract.id
end
script = Script.find_or_create_by temp_hash
Expand All @@ -796,7 +796,7 @@ def build_cells_and_locks!(
type_script_ids.each do |type_script_id|
type_script = TypeScript.find(type_script_id)
temp_hash = { script_hash: type_script&.script_hash, is_contract: false }
contract = Contract.find_by code_hash: type_script.code_hash
contract = Contract.find_by code_hash: type_script.script_hash

if contract
temp_hash = temp_hash.merge is_contract: true, contract_id: contract.id
Expand Down
2 changes: 1 addition & 1 deletion app/serializers/ckb_transaction_serializer.rb
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ class CkbTransactionSerializer
end

attribute :cell_deps do |o|
o.cell_dependencies.explicit.includes(:cell_output).to_a.map(&:to_raw)
o.cell_dependencies.explicit.order("id asc").includes(:cell_output).to_a.map(&:to_raw)
end

attribute :header_deps do |o|
Expand Down
36 changes: 0 additions & 36 deletions db/migrate/20190327073533_create_blocks.rb

This file was deleted.

25 changes: 0 additions & 25 deletions db/migrate/20190327073646_create_uncle_blocks.rb

This file was deleted.

21 changes: 0 additions & 21 deletions db/migrate/20190327073737_create_ckb_transactions.rb

This file was deleted.

13 changes: 0 additions & 13 deletions db/migrate/20190327073848_create_addresses.rb

This file was deleted.

10 changes: 0 additions & 10 deletions db/migrate/20190327073920_create_account_books.rb

This file was deleted.

12 changes: 0 additions & 12 deletions db/migrate/20190327073948_create_cell_inputs.rb

This file was deleted.

11 changes: 0 additions & 11 deletions db/migrate/20190327074009_create_cell_outputs.rb

This file was deleted.

12 changes: 0 additions & 12 deletions db/migrate/20190327074053_create_lock_scripts.rb

This file was deleted.

11 changes: 0 additions & 11 deletions db/migrate/20190327074129_create_type_scripts.rb

This file was deleted.

13 changes: 0 additions & 13 deletions db/migrate/20190327074238_create_sync_infos.rb

This file was deleted.

5 changes: 0 additions & 5 deletions db/migrate/20190428084336_add_status_to_cell_output.rb

This file was deleted.

5 changes: 0 additions & 5 deletions db/migrate/20190428094733_add_address_id_to_cell_output.rb

This file was deleted.

This file was deleted.

7 changes: 0 additions & 7 deletions db/migrate/20190507083006_add_block_id_to_cell_outputs.rb

This file was deleted.

This file was deleted.

9 changes: 0 additions & 9 deletions db/migrate/20190520025819_change_unique_index_scope.rb

This file was deleted.

5 changes: 0 additions & 5 deletions db/migrate/20190521045538_add_address_ids_to_block.rb

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

7 changes: 0 additions & 7 deletions db/migrate/20190530090537_add_lock_hash_to_address.rb

This file was deleted.

This file was deleted.

This file was deleted.

5 changes: 0 additions & 5 deletions db/migrate/20190606083952_remove_args_from_cell_inputs.rb

This file was deleted.

8 changes: 0 additions & 8 deletions db/migrate/20190612034620_add_index_on_status_to_blocks.rb

This file was deleted.

7 changes: 0 additions & 7 deletions db/migrate/20190617015612_remove_indexes_from_blocks.rb

This file was deleted.

5 changes: 0 additions & 5 deletions db/migrate/20190617015805_add_index_on_number_to_blocks.rb

This file was deleted.

This file was deleted.

This file was deleted.

5 changes: 0 additions & 5 deletions db/migrate/20190625075829_add_reward_status_to_blocks.rb

This file was deleted.

This file was deleted.

5 changes: 0 additions & 5 deletions db/migrate/20190625093335_add_received_tx_fee_to_blocks.rb

This file was deleted.

Loading
Loading