8000 chore: data insertion implementation by MicBun · Pull Request #831 · trufnetwork/node · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

chore: data insertion implementation #831

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

Merged
merged 4 commits into from
Mar 6, 2025

Conversation

MicBun
Copy link
Member
@MicBun MicBun commented Mar 6, 2025

Description

This pull request introduces a new migration script to handle primitive actions related to the events stream. The script includes actions for inserting records, checking if the contract is initiated, retrieving metadata, and verifying wallet permissions. The most important changes are:

Migration Script for Primitive Actions:

  • internal/migrations/002-primitive-insertion.sql: Added a migration script that defines actions for inserting records into the primitive_events table, checking if the contract/stream is initiated, retrieving metadata with pagination, and verifying if a wallet is allowed to write.

Related Problem

resolves: #821

How Has This Been Tested?

I am able to create the actions, but unable to test

Blocked by:

@MicBun MicBun self-assigned this Mar 6, 2025
@MicBun MicBun linked an issue Mar 6, 2025 that may be closed by this pull request
@MicBun MicBun changed the title feat: data insertion implementation chore: data insertion implementation Mar 6, 2025
@MicBun MicBun force-pushed the feat/dataInsertion branch from e52ff72 to f6abce2 Compare March 6, 2025 07:34
@MicBun MicBun changed the base branch from main to refactor/node-2.0 March 6, 2025 07:34
@MicBun MicBun requested a review from outerlook March 6, 2025 10:12
@MicBun MicBun marked this pull request as ready for review March 6, 2025 10:12
Copy link
Contributor
@outerlook outerlook left a comment

Choose a reason for hiding this comment

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

Nice one. But it's also important to enable the tests that are now possible with this implementation, that exclusively tests insertion.

Even though we can't use get_records to query until it's ok, we can execute statements to query the table directly.

@MicBun MicBun requested a review from outerlook March 6, 2025 12:04
@MicBun
Copy link
Member Author
MicBun commented Mar 6, 2025

@outerlook we needs to figure out how to pass numeric()36,18) tried to pass as string, float32, float64 no success either.

@MicBun MicBun force-pushed the feat/dataInsertion branch from 51d8e55 to a84b566 Compare March 6, 2025 13:29
@MicBun MicBun requested a review from outerlook March 6, 2025 13:29
Copy link
pr-time-tracker bot commented Mar 6, 2025

@outerlook
⚠️⚠️⚠️
You must submit the time spent on this PR.
⚠️⚠️⚠️

@outerlook outerlook merged commit f7101af into refactor/node-2.0 Mar 6, 2025
3 of 5 checks passed
@outerlook outerlook deleted the feat/dataInsertion branch March 6, 2025 13:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Problem: missing data insertion implementation
2 participants
0