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

fix: proxy_contract not found on evm_smart_contract #880

Merged
merged 3 commits into from
Aug 12, 2024

Conversation

fibonacci998
Copy link
Contributor

No description provided.

@fibonacci998
Copy link
Contributor Author

cái này sau muốn tìm lại thì chỉ cần

select * from evm_proxy_history where address not in (select address from evm_smart_contract)

là ra

@peara
Copy link
Member

peara commented Aug 12, 2024

là sao nhỉ? có cái history nào bị mất contract à?

@fibonacci998
Copy link
Contributor Author

là sao nhỉ? có cái history nào bị mất contract à?

case account abstract hôm trước ấy anh, là proxy nhưng không có record trong bảng contract. hiện tại mình drop FK đi để job proxy history vẫn insert vào bảng proxy_history mà không phụ thuộc vào bảng contract nữa

@fibonacci998
Copy link
Contributor Author

cái này sau muốn tìm lại thì chỉ cần

select * from evm_proxy_history where address not in (select address from evm_smart_contract)

là ra

còn cái này là để sau mình sửa lại, hôm trước anh bảo em đánh thêm status cho nó ấy mà em thấy không cần lắm, query câu kia là ra những cái contract bị thiếu

@fibonacci998 fibonacci998 changed the title fix: remove foreign key proxy_contract in proxy_history fix: proxy_contract not found on evm_smart_contract Aug 12, 2024
newProxyHistories.forEach((proxyHistory) => {
if (
proxyHistory.implementation_contract !== null &&
foundContractsInDB[proxyHistory.implementation_contract] !== null
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

hmm ở trên sao cái biến trong query lại là proxy_contract?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

case của mình đang là miss proxy_contract anh ạ, em sửa rồi nhé. Không biết có case miss implement_contract không

@peara peara merged commit b095eb7 into develop Aug 12, 2024
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants