rocksdb #29

Merged
jeffreypicard merged 93 commits from feature/27/jeffreypicard/rocksdb into master 2022-04-29 17:04:01 +02:00
2 changed files with 9 additions and 26 deletions
Showing only changes of commit c66d07e8cc - Show all commits

View file

@ -779,7 +779,7 @@ func InitTxCounts(db *ReadOnlyDBColumnFamily) error {
lyoshenka commented 2022-03-24 22:26:17 +01:00 (Migrated from github.com)
Review

no need to start these with N

no need to start these with N
lyoshenka commented 2022-03-24 22:26:38 +01:00 (Migrated from github.com)
Review

and many of these are unused

and many of these are unused
lyoshenka commented 2022-03-24 22:34:50 +01:00 (Migrated from github.com)
Review

is this really no big deal? seems like an error to me but idk rocksdb

is this really no big deal? seems like an error to me but idk rocksdb
lyoshenka commented 2022-03-24 22:38:01 +01:00 (Migrated from github.com)
Review

typo: Famlies -> Families

typo: Famlies -> Families
lyoshenka commented 2022-03-24 22:41:04 +01:00 (Migrated from github.com)
Review

this can be unexported

this can be unexported
lyoshenka commented 2022-03-24 22:41:39 +01:00 (Migrated from github.com)
Review

still need this?

still need this?
lyoshenka commented 2022-03-24 22:43:06 +01:00 (Migrated from github.com)
Review

typo

typo
lyoshenka commented 2022-03-24 22:43:32 +01:00 (Migrated from github.com)
Review

👀

:eyes:
jeffreypicard commented 2022-03-24 23:32:48 +01:00 (Migrated from github.com)
Review

I agree the "N" can go. I copied these all over from the Python. where I believe they are similarly unused, because I thought it might be the defacto documentation.

I agree the "N" can go. I copied these all over from the Python. where I believe they are similarly unused, because I thought it might be the defacto documentation.
jeffreypicard commented 2022-03-24 23:39:47 +01:00 (Migrated from github.com)
Review
// Valid returns false only when an Iterator has iterated past either the
// first or the last key in the database.
func (iter *Iterator) Valid() bool {
	return C.rocksdb_iter_valid(iter.c) != 0
}

If our iterator was to try to go off the end of the db, or the front if we're going backwards, we need to check this.

``` // Valid returns false only when an Iterator has iterated past either the // first or the last key in the database. func (iter *Iterator) Valid() bool { return C.rocksdb_iter_valid(iter.c) != 0 } ``` If our iterator was to try to go off the end of the db, or the front if we're going backwards, we need to check this.
lyoshenka commented 2022-03-24 22:26:17 +01:00 (Migrated from github.com)
Review

no need to start these with N

no need to start these with N
lyoshenka commented 2022-03-24 22:26:38 +01:00 (Migrated from github.com)
Review

and many of these are unused

and many of these are unused
lyoshenka commented 2022-03-24 22:34:50 +01:00 (Migrated from github.com)
Review

is this really no big deal? seems like an error to me but idk rocksdb

is this really no big deal? seems like an error to me but idk rocksdb
lyoshenka commented 2022-03-24 22:38:01 +01:00 (Migrated from github.com)
Review

typo: Famlies -> Families

typo: Famlies -> Families
lyoshenka commented 2022-03-24 22:41:04 +01:00 (Migrated from github.com)
Review

this can be unexported

this can be unexported
lyoshenka commented 2022-03-24 22:41:39 +01:00 (Migrated from github.com)
Review

still need this?

still need this?
lyoshenka commented 2022-03-24 22:43:06 +01:00 (Migrated from github.com)
Review

typo

typo
lyoshenka commented 2022-03-24 22:43:32 +01:00 (Migrated from github.com)
Review

👀

:eyes:
jeffreypicard commented 2022-03-24 23:32:48 +01:00 (Migrated from github.com)
Review

I agree the "N" can go. I copied these all over from the Python. where I believe they are similarly unused, because I thought it might be the defacto documentation.

I agree the "N" can go. I copied these all over from the Python. where I believe they are similarly unused, because I thought it might be the defacto documentation.
jeffreypicard commented 2022-03-24 23:39:47 +01:00 (Migrated from github.com)
Review
// Valid returns false only when an Iterator has iterated past either the
// first or the last key in the database.
func (iter *Iterator) Valid() bool {
	return C.rocksdb_iter_valid(iter.c) != 0
}

If our iterator was to try to go off the end of the db, or the front if we're going backwards, we need to check this.

``` // Valid returns false only when an Iterator has iterated past either the // first or the last key in the database. func (iter *Iterator) Valid() bool { return C.rocksdb_iter_valid(iter.c) != 0 } ``` If our iterator was to try to go off the end of the db, or the front if we're going backwards, we need to check this.
db.TxCounts = db_stack.NewSliceBackedStack(1200000)
options := NewIterateOptions().WithPrefix([]byte{prefixes.TxCount}).WithCfHandle(handle)
options = options.WithIncludeKey(false).WithIncludeValue(true)
lyoshenka commented 2022-03-24 22:26:17 +01:00 (Migrated from github.com)
Review

no need to start these with N

no need to start these with N
lyoshenka commented 2022-03-24 22:26:38 +01:00 (Migrated from github.com)
Review

and many of these are unused

and many of these are unused
lyoshenka commented 2022-03-24 22:34:50 +01:00 (Migrated from github.com)
Review

is this really no big deal? seems like an error to me but idk rocksdb

is this really no big deal? seems like an error to me but idk rocksdb
lyoshenka commented 2022-03-24 22:38:01 +01:00 (Migrated from github.com)
Review

typo: Famlies -> Families

typo: Famlies -> Families
lyoshenka commented 2022-03-24 22:41:04 +01:00 (Migrated from github.com)
Review

this can be unexported

this can be unexported
lyoshenka commented 2022-03-24 22:41:39 +01:00 (Migrated from github.com)
Review

still need this?

still need this?
lyoshenka commented 2022-03-24 22:43:06 +01:00 (Migrated from github.com)
Review

typo

typo
lyoshenka commented 2022-03-24 22:43:32 +01:00 (Migrated from github.com)
Review

👀

:eyes:
jeffreypicard commented 2022-03-24 23:32:48 +01:00 (Migrated from github.com)
Review

I agree the "N" can go. I copied these all over from the Python. where I believe they are similarly unused, because I thought it might be the defacto documentation.

I agree the "N" can go. I copied these all over from the Python. where I believe they are similarly unused, because I thought it might be the defacto documentation.
jeffreypicard commented 2022-03-24 23:39:47 +01:00 (Migrated from github.com)
Review
// Valid returns false only when an Iterator has iterated past either the
// first or the last key in the database.
func (iter *Iterator) Valid() bool {
	return C.rocksdb_iter_valid(iter.c) != 0
}

If our iterator was to try to go off the end of the db, or the front if we're going backwards, we need to check this.

``` // Valid returns false only when an Iterator has iterated past either the // first or the last key in the database. func (iter *Iterator) Valid() bool { return C.rocksdb_iter_valid(iter.c) != 0 } ``` If our iterator was to try to go off the end of the db, or the front if we're going backwards, we need to check this.
options = options.WithIncludeKey(false).WithIncludeValue(true).WithIncludeStop(true)
lyoshenka commented 2022-03-24 22:26:17 +01:00 (Migrated from github.com)
Review

no need to start these with N

no need to start these with N
lyoshenka commented 2022-03-24 22:26:38 +01:00 (Migrated from github.com)
Review

and many of these are unused

and many of these are unused
lyoshenka commented 2022-03-24 22:34:50 +01:00 (Migrated from github.com)
Review

is this really no big deal? seems like an error to me but idk rocksdb

is this really no big deal? seems like an error to me but idk rocksdb
lyoshenka commented 2022-03-24 22:38:01 +01:00 (Migrated from github.com)
Review

typo: Famlies -> Families

typo: Famlies -> Families
lyoshenka commented 2022-03-24 22:41:04 +01:00 (Migrated from github.com)
Review

this can be unexported

this can be unexported
lyoshenka commented 2022-03-24 22:41:39 +01:00 (Migrated from github.com)
Review

still need this?

still need this?
lyoshenka commented 2022-03-24 22:43:06 +01:00 (Migrated from github.com)
Review

typo

typo
lyoshenka commented 2022-03-24 22:43:32 +01:00 (Migrated from github.com)
Review

👀

:eyes:
jeffreypicard commented 2022-03-24 23:32:48 +01:00 (Migrated from github.com)
Review

I agree the "N" can go. I copied these all over from the Python. where I believe they are similarly unused, because I thought it might be the defacto documentation.

I agree the "N" can go. I copied these all over from the Python. where I believe they are similarly unused, because I thought it might be the defacto documentation.
jeffreypicard commented 2022-03-24 23:39:47 +01:00 (Migrated from github.com)
Review
// Valid returns false only when an Iterator has iterated past either the
// first or the last key in the database.
func (iter *Iterator) Valid() bool {
	return C.rocksdb_iter_valid(iter.c) != 0
}

If our iterator was to try to go off the end of the db, or the front if we're going backwards, we need to check this.

``` // Valid returns false only when an Iterator has iterated past either the // first or the last key in the database. func (iter *Iterator) Valid() bool { return C.rocksdb_iter_valid(iter.c) != 0 } ``` If our iterator was to try to go off the end of the db, or the front if we're going backwards, we need to check this.
ch := IterCF(db.DB, options)
@ -791,13 +791,14 @@ func InitTxCounts(db *ReadOnlyDBColumnFamily) error {
lyoshenka commented 2022-03-24 22:26:17 +01:00 (Migrated from github.com)
Review

no need to start these with N

no need to start these with N
lyoshenka commented 2022-03-24 22:26:38 +01:00 (Migrated from github.com)
Review

and many of these are unused

and many of these are unused
lyoshenka commented 2022-03-24 22:34:50 +01:00 (Migrated from github.com)
Review

is this really no big deal? seems like an error to me but idk rocksdb

is this really no big deal? seems like an error to me but idk rocksdb
lyoshenka commented 2022-03-24 22:38:01 +01:00 (Migrated from github.com)
Review

typo: Famlies -> Families

typo: Famlies -> Families
lyoshenka commented 2022-03-24 22:41:04 +01:00 (Migrated from github.com)
Review

this can be unexported

this can be unexported
lyoshenka commented 2022-03-24 22:41:39 +01:00 (Migrated from github.com)
Review

still need this?

still need this?
lyoshenka commented 2022-03-24 22:43:06 +01:00 (Migrated from github.com)
Review

typo

typo
lyoshenka commented 2022-03-24 22:43:32 +01:00 (Migrated from github.com)
Review

👀

:eyes:
jeffreypicard commented 2022-03-24 23:32:48 +01:00 (Migrated from github.com)
Review

I agree the "N" can go. I copied these all over from the Python. where I believe they are similarly unused, because I thought it might be the defacto documentation.

I agree the "N" can go. I copied these all over from the Python. where I believe they are similarly unused, because I thought it might be the defacto documentation.
jeffreypicard commented 2022-03-24 23:39:47 +01:00 (Migrated from github.com)
Review
// Valid returns false only when an Iterator has iterated past either the
// first or the last key in the database.
func (iter *Iterator) Valid() bool {
	return C.rocksdb_iter_valid(iter.c) != 0
}

If our iterator was to try to go off the end of the db, or the front if we're going backwards, we need to check this.

``` // Valid returns false only when an Iterator has iterated past either the // first or the last key in the database. func (iter *Iterator) Valid() bool { return C.rocksdb_iter_valid(iter.c) != 0 } ``` If our iterator was to try to go off the end of the db, or the front if we're going backwards, we need to check this.
lyoshenka commented 2022-03-24 22:26:17 +01:00 (Migrated from github.com)
Review

no need to start these with N

no need to start these with N
lyoshenka commented 2022-03-24 22:26:38 +01:00 (Migrated from github.com)
Review

and many of these are unused

and many of these are unused
lyoshenka commented 2022-03-24 22:34:50 +01:00 (Migrated from github.com)
Review

is this really no big deal? seems like an error to me but idk rocksdb

is this really no big deal? seems like an error to me but idk rocksdb
lyoshenka commented 2022-03-24 22:38:01 +01:00 (Migrated from github.com)
Review

typo: Famlies -> Families

typo: Famlies -> Families
lyoshenka commented 2022-03-24 22:41:04 +01:00 (Migrated from github.com)
Review

this can be unexported

this can be unexported
lyoshenka commented 2022-03-24 22:41:39 +01:00 (Migrated from github.com)
Review

still need this?

still need this?
lyoshenka commented 2022-03-24 22:43:06 +01:00 (Migrated from github.com)
Review

typo

typo
lyoshenka commented 2022-03-24 22:43:32 +01:00 (Migrated from github.com)
Review

👀

:eyes:
jeffreypicard commented 2022-03-24 23:32:48 +01:00 (Migrated from github.com)
Review

I agree the "N" can go. I copied these all over from the Python. where I believe they are similarly unused, because I thought it might be the defacto documentation.

I agree the "N" can go. I copied these all over from the Python. where I believe they are similarly unused, because I thought it might be the defacto documentation.
jeffreypicard commented 2022-03-24 23:39:47 +01:00 (Migrated from github.com)
Review
// Valid returns false only when an Iterator has iterated past either the
// first or the last key in the database.
func (iter *Iterator) Valid() bool {
	return C.rocksdb_iter_valid(iter.c) != 0
}

If our iterator was to try to go off the end of the db, or the front if we're going backwards, we need to check this.

``` // Valid returns false only when an Iterator has iterated past either the // first or the last key in the database. func (iter *Iterator) Valid() bool { return C.rocksdb_iter_valid(iter.c) != 0 } ``` If our iterator was to try to go off the end of the db, or the front if we're going backwards, we need to check this.
log.Println("len(db.TxCounts), cap(db.TxCounts):", db.TxCounts.Len(), db.TxCounts.Cap())
log.Println("Time to get txCounts:", duration)
// This needs to be len-1 because we start loading with the zero block
lyoshenka commented 2022-03-24 22:26:17 +01:00 (Migrated from github.com)
Review

no need to start these with N

no need to start these with N
lyoshenka commented 2022-03-24 22:26:38 +01:00 (Migrated from github.com)
Review

and many of these are unused

and many of these are unused
lyoshenka commented 2022-03-24 22:34:50 +01:00 (Migrated from github.com)
Review

is this really no big deal? seems like an error to me but idk rocksdb

is this really no big deal? seems like an error to me but idk rocksdb
lyoshenka commented 2022-03-24 22:38:01 +01:00 (Migrated from github.com)
Review

typo: Famlies -> Families

typo: Famlies -> Families
lyoshenka commented 2022-03-24 22:41:04 +01:00 (Migrated from github.com)
Review

this can be unexported

this can be unexported
lyoshenka commented 2022-03-24 22:41:39 +01:00 (Migrated from github.com)
Review

still need this?

still need this?
lyoshenka commented 2022-03-24 22:43:06 +01:00 (Migrated from github.com)
Review

typo

typo
lyoshenka commented 2022-03-24 22:43:32 +01:00 (Migrated from github.com)
Review

👀

:eyes:
jeffreypicard commented 2022-03-24 23:32:48 +01:00 (Migrated from github.com)
Review

I agree the "N" can go. I copied these all over from the Python. where I believe they are similarly unused, because I thought it might be the defacto documentation.

I agree the "N" can go. I copied these all over from the Python. where I believe they are similarly unused, because I thought it might be the defacto documentation.
jeffreypicard commented 2022-03-24 23:39:47 +01:00 (Migrated from github.com)
Review
// Valid returns false only when an Iterator has iterated past either the
// first or the last key in the database.
func (iter *Iterator) Valid() bool {
	return C.rocksdb_iter_valid(iter.c) != 0
}

If our iterator was to try to go off the end of the db, or the front if we're going backwards, we need to check this.

``` // Valid returns false only when an Iterator has iterated past either the // first or the last key in the database. func (iter *Iterator) Valid() bool { return C.rocksdb_iter_valid(iter.c) != 0 } ``` If our iterator was to try to go off the end of the db, or the front if we're going backwards, we need to check this.
// and the txcounts start at one.
lyoshenka commented 2022-03-24 22:26:17 +01:00 (Migrated from github.com)
Review

no need to start these with N

no need to start these with N
lyoshenka commented 2022-03-24 22:26:38 +01:00 (Migrated from github.com)
Review

and many of these are unused

and many of these are unused
lyoshenka commented 2022-03-24 22:34:50 +01:00 (Migrated from github.com)
Review

is this really no big deal? seems like an error to me but idk rocksdb

is this really no big deal? seems like an error to me but idk rocksdb
lyoshenka commented 2022-03-24 22:38:01 +01:00 (Migrated from github.com)
Review

typo: Famlies -> Families

typo: Famlies -> Families
lyoshenka commented 2022-03-24 22:41:04 +01:00 (Migrated from github.com)
Review

this can be unexported

this can be unexported
lyoshenka commented 2022-03-24 22:41:39 +01:00 (Migrated from github.com)
Review

still need this?

still need this?
lyoshenka commented 2022-03-24 22:43:06 +01:00 (Migrated from github.com)
Review

typo

typo
lyoshenka commented 2022-03-24 22:43:32 +01:00 (Migrated from github.com)
Review

👀

:eyes:
jeffreypicard commented 2022-03-24 23:32:48 +01:00 (Migrated from github.com)
Review

I agree the "N" can go. I copied these all over from the Python. where I believe they are similarly unused, because I thought it might be the defacto documentation.

I agree the "N" can go. I copied these all over from the Python. where I believe they are similarly unused, because I thought it might be the defacto documentation.
jeffreypicard commented 2022-03-24 23:39:47 +01:00 (Migrated from github.com)
Review
// Valid returns false only when an Iterator has iterated past either the
// first or the last key in the database.
func (iter *Iterator) Valid() bool {
	return C.rocksdb_iter_valid(iter.c) != 0
}

If our iterator was to try to go off the end of the db, or the front if we're going backwards, we need to check this.

``` // Valid returns false only when an Iterator has iterated past either the // first or the last key in the database. func (iter *Iterator) Valid() bool { return C.rocksdb_iter_valid(iter.c) != 0 } ``` If our iterator was to try to go off the end of the db, or the front if we're going backwards, we need to check this.
if db.TxCounts.Len() > 0 {
lyoshenka commented 2022-03-24 22:26:17 +01:00 (Migrated from github.com)
Review

no need to start these with N

no need to start these with N
lyoshenka commented 2022-03-24 22:26:38 +01:00 (Migrated from github.com)
Review

and many of these are unused

and many of these are unused
lyoshenka commented 2022-03-24 22:34:50 +01:00 (Migrated from github.com)
Review

is this really no big deal? seems like an error to me but idk rocksdb

is this really no big deal? seems like an error to me but idk rocksdb
lyoshenka commented 2022-03-24 22:38:01 +01:00 (Migrated from github.com)
Review

typo: Famlies -> Families

typo: Famlies -> Families
lyoshenka commented 2022-03-24 22:41:04 +01:00 (Migrated from github.com)
Review

this can be unexported

this can be unexported
lyoshenka commented 2022-03-24 22:41:39 +01:00 (Migrated from github.com)
Review

still need this?

still need this?
lyoshenka commented 2022-03-24 22:43:06 +01:00 (Migrated from github.com)
Review

typo

typo
lyoshenka commented 2022-03-24 22:43:32 +01:00 (Migrated from github.com)
Review

👀

:eyes:
jeffreypicard commented 2022-03-24 23:32:48 +01:00 (Migrated from github.com)
Review

I agree the "N" can go. I copied these all over from the Python. where I believe they are similarly unused, because I thought it might be the defacto documentation.

I agree the "N" can go. I copied these all over from the Python. where I believe they are similarly unused, because I thought it might be the defacto documentation.
jeffreypicard commented 2022-03-24 23:39:47 +01:00 (Migrated from github.com)
Review
// Valid returns false only when an Iterator has iterated past either the
// first or the last key in the database.
func (iter *Iterator) Valid() bool {
	return C.rocksdb_iter_valid(iter.c) != 0
}

If our iterator was to try to go off the end of the db, or the front if we're going backwards, we need to check this.

``` // Valid returns false only when an Iterator has iterated past either the // first or the last key in the database. func (iter *Iterator) Valid() bool { return C.rocksdb_iter_valid(iter.c) != 0 } ``` If our iterator was to try to go off the end of the db, or the front if we're going backwards, we need to check this.
db.Height = db.TxCounts.Len() - 1
lyoshenka commented 2022-03-24 22:26:17 +01:00 (Migrated from github.com)
Review

no need to start these with N

no need to start these with N
lyoshenka commented 2022-03-24 22:26:38 +01:00 (Migrated from github.com)
Review

and many of these are unused

and many of these are unused
lyoshenka commented 2022-03-24 22:34:50 +01:00 (Migrated from github.com)
Review

is this really no big deal? seems like an error to me but idk rocksdb

is this really no big deal? seems like an error to me but idk rocksdb
lyoshenka commented 2022-03-24 22:38:01 +01:00 (Migrated from github.com)
Review

typo: Famlies -> Families

typo: Famlies -> Families
lyoshenka commented 2022-03-24 22:41:04 +01:00 (Migrated from github.com)
Review

this can be unexported

this can be unexported
lyoshenka commented 2022-03-24 22:41:39 +01:00 (Migrated from github.com)
Review

still need this?

still need this?
lyoshenka commented 2022-03-24 22:43:06 +01:00 (Migrated from github.com)
Review

typo

typo
lyoshenka commented 2022-03-24 22:43:32 +01:00 (Migrated from github.com)
Review

👀

:eyes:
jeffreypicard commented 2022-03-24 23:32:48 +01:00 (Migrated from github.com)
Review

I agree the "N" can go. I copied these all over from the Python. where I believe they are similarly unused, because I thought it might be the defacto documentation.

I agree the "N" can go. I copied these all over from the Python. where I believe they are similarly unused, because I thought it might be the defacto documentation.
jeffreypicard commented 2022-03-24 23:39:47 +01:00 (Migrated from github.com)
Review
// Valid returns false only when an Iterator has iterated past either the
// first or the last key in the database.
func (iter *Iterator) Valid() bool {
	return C.rocksdb_iter_valid(iter.c) != 0
}

If our iterator was to try to go off the end of the db, or the front if we're going backwards, we need to check this.

``` // Valid returns false only when an Iterator has iterated past either the // first or the last key in the database. func (iter *Iterator) Valid() bool { return C.rocksdb_iter_valid(iter.c) != 0 } ``` If our iterator was to try to go off the end of the db, or the front if we're going backwards, we need to check this.
} else {
lyoshenka commented 2022-03-24 22:26:17 +01:00 (Migrated from github.com)
Review

no need to start these with N

no need to start these with N
lyoshenka commented 2022-03-24 22:26:38 +01:00 (Migrated from github.com)
Review

and many of these are unused

and many of these are unused
lyoshenka commented 2022-03-24 22:34:50 +01:00 (Migrated from github.com)
Review

is this really no big deal? seems like an error to me but idk rocksdb

is this really no big deal? seems like an error to me but idk rocksdb
lyoshenka commented 2022-03-24 22:38:01 +01:00 (Migrated from github.com)
Review

typo: Famlies -> Families

typo: Famlies -> Families
lyoshenka commented 2022-03-24 22:41:04 +01:00 (Migrated from github.com)
Review

this can be unexported

this can be unexported
lyoshenka commented 2022-03-24 22:41:39 +01:00 (Migrated from github.com)
Review

still need this?

still need this?
lyoshenka commented 2022-03-24 22:43:06 +01:00 (Migrated from github.com)
Review

typo

typo
lyoshenka commented 2022-03-24 22:43:32 +01:00 (Migrated from github.com)
Review

👀

:eyes:
jeffreypicard commented 2022-03-24 23:32:48 +01:00 (Migrated from github.com)
Review

I agree the "N" can go. I copied these all over from the Python. where I believe they are similarly unused, because I thought it might be the defacto documentation.

I agree the "N" can go. I copied these all over from the Python. where I believe they are similarly unused, because I thought it might be the defacto documentation.
jeffreypicard commented 2022-03-24 23:39:47 +01:00 (Migrated from github.com)
Review
// Valid returns false only when an Iterator has iterated past either the
// first or the last key in the database.
func (iter *Iterator) Valid() bool {
	return C.rocksdb_iter_valid(iter.c) != 0
}

If our iterator was to try to go off the end of the db, or the front if we're going backwards, we need to check this.

``` // Valid returns false only when an Iterator has iterated past either the // first or the last key in the database. func (iter *Iterator) Valid() bool { return C.rocksdb_iter_valid(iter.c) != 0 } ``` If our iterator was to try to go off the end of the db, or the front if we're going backwards, we need to check this.
log.Println("db.TxCounts.Len() == 0 ???")
lyoshenka commented 2022-03-24 22:26:17 +01:00 (Migrated from github.com)
Review

no need to start these with N

no need to start these with N
lyoshenka commented 2022-03-24 22:26:38 +01:00 (Migrated from github.com)
Review

and many of these are unused

and many of these are unused
lyoshenka commented 2022-03-24 22:34:50 +01:00 (Migrated from github.com)
Review

is this really no big deal? seems like an error to me but idk rocksdb

is this really no big deal? seems like an error to me but idk rocksdb
lyoshenka commented 2022-03-24 22:38:01 +01:00 (Migrated from github.com)
Review

typo: Famlies -> Families

typo: Famlies -> Families
lyoshenka commented 2022-03-24 22:41:04 +01:00 (Migrated from github.com)
Review

this can be unexported

this can be unexported
lyoshenka commented 2022-03-24 22:41:39 +01:00 (Migrated from github.com)
Review

still need this?

still need this?
lyoshenka commented 2022-03-24 22:43:06 +01:00 (Migrated from github.com)
Review

typo

typo
lyoshenka commented 2022-03-24 22:43:32 +01:00 (Migrated from github.com)
Review

👀

:eyes:
jeffreypicard commented 2022-03-24 23:32:48 +01:00 (Migrated from github.com)
Review

I agree the "N" can go. I copied these all over from the Python. where I believe they are similarly unused, because I thought it might be the defacto documentation.

I agree the "N" can go. I copied these all over from the Python. where I believe they are similarly unused, because I thought it might be the defacto documentation.
jeffreypicard commented 2022-03-24 23:39:47 +01:00 (Migrated from github.com)
Review
// Valid returns false only when an Iterator has iterated past either the
// first or the last key in the database.
func (iter *Iterator) Valid() bool {
	return C.rocksdb_iter_valid(iter.c) != 0
}

If our iterator was to try to go off the end of the db, or the front if we're going backwards, we need to check this.

``` // Valid returns false only when an Iterator has iterated past either the // first or the last key in the database. func (iter *Iterator) Valid() bool { return C.rocksdb_iter_valid(iter.c) != 0 } ``` If our iterator was to try to go off the end of the db, or the front if we're going backwards, we need to check this.
}
lyoshenka commented 2022-03-24 22:26:17 +01:00 (Migrated from github.com)
Review

no need to start these with N

no need to start these with N
lyoshenka commented 2022-03-24 22:26:38 +01:00 (Migrated from github.com)
Review

and many of these are unused

and many of these are unused
lyoshenka commented 2022-03-24 22:34:50 +01:00 (Migrated from github.com)
Review

is this really no big deal? seems like an error to me but idk rocksdb

is this really no big deal? seems like an error to me but idk rocksdb
lyoshenka commented 2022-03-24 22:38:01 +01:00 (Migrated from github.com)
Review

typo: Famlies -> Families

typo: Famlies -> Families
lyoshenka commented 2022-03-24 22:41:04 +01:00 (Migrated from github.com)
Review

this can be unexported

this can be unexported
lyoshenka commented 2022-03-24 22:41:39 +01:00 (Migrated from github.com)
Review

still need this?

still need this?
lyoshenka commented 2022-03-24 22:43:06 +01:00 (Migrated from github.com)
Review

typo

typo
lyoshenka commented 2022-03-24 22:43:32 +01:00 (Migrated from github.com)
Review

👀

:eyes:
jeffreypicard commented 2022-03-24 23:32:48 +01:00 (Migrated from github.com)
Review

I agree the "N" can go. I copied these all over from the Python. where I believe they are similarly unused, because I thought it might be the defacto documentation.

I agree the "N" can go. I copied these all over from the Python. where I believe they are similarly unused, because I thought it might be the defacto documentation.
jeffreypicard commented 2022-03-24 23:39:47 +01:00 (Migrated from github.com)
Review
// Valid returns false only when an Iterator has iterated past either the
// first or the last key in the database.
func (iter *Iterator) Valid() bool {
	return C.rocksdb_iter_valid(iter.c) != 0
}

If our iterator was to try to go off the end of the db, or the front if we're going backwards, we need to check this.

``` // Valid returns false only when an Iterator has iterated past either the // first or the last key in the database. func (iter *Iterator) Valid() bool { return C.rocksdb_iter_valid(iter.c) != 0 } ``` If our iterator was to try to go off the end of the db, or the front if we're going backwards, we need to check this.
// whjy not needs to be len-1 because we start loading with the zero block
lyoshenka commented 2022-03-24 22:26:17 +01:00 (Migrated from github.com)
Review

no need to start these with N

no need to start these with N
lyoshenka commented 2022-03-24 22:26:38 +01:00 (Migrated from github.com)
Review

and many of these are unused

and many of these are unused
lyoshenka commented 2022-03-24 22:34:50 +01:00 (Migrated from github.com)
Review

is this really no big deal? seems like an error to me but idk rocksdb

is this really no big deal? seems like an error to me but idk rocksdb
lyoshenka commented 2022-03-24 22:38:01 +01:00 (Migrated from github.com)
Review

typo: Famlies -> Families

typo: Famlies -> Families
lyoshenka commented 2022-03-24 22:41:04 +01:00 (Migrated from github.com)
Review

this can be unexported

this can be unexported
lyoshenka commented 2022-03-24 22:41:39 +01:00 (Migrated from github.com)
Review

still need this?

still need this?
lyoshenka commented 2022-03-24 22:43:06 +01:00 (Migrated from github.com)
Review

typo

typo
lyoshenka commented 2022-03-24 22:43:32 +01:00 (Migrated from github.com)
Review

👀

:eyes:
jeffreypicard commented 2022-03-24 23:32:48 +01:00 (Migrated from github.com)
Review

I agree the "N" can go. I copied these all over from the Python. where I believe they are similarly unused, because I thought it might be the defacto documentation.

I agree the "N" can go. I copied these all over from the Python. where I believe they are similarly unused, because I thought it might be the defacto documentation.
jeffreypicard commented 2022-03-24 23:39:47 +01:00 (Migrated from github.com)
Review
// Valid returns false only when an Iterator has iterated past either the
// first or the last key in the database.
func (iter *Iterator) Valid() bool {
	return C.rocksdb_iter_valid(iter.c) != 0
}

If our iterator was to try to go off the end of the db, or the front if we're going backwards, we need to check this.

``` // Valid returns false only when an Iterator has iterated past either the // first or the last key in the database. func (iter *Iterator) Valid() bool { return C.rocksdb_iter_valid(iter.c) != 0 } ``` If our iterator was to try to go off the end of the db, or the front if we're going backwards, we need to check this.
// and the txcounts start at one???
lyoshenka commented 2022-03-24 22:26:17 +01:00 (Migrated from github.com)
Review

no need to start these with N

no need to start these with N
lyoshenka commented 2022-03-24 22:26:38 +01:00 (Migrated from github.com)
Review

and many of these are unused

and many of these are unused
lyoshenka commented 2022-03-24 22:34:50 +01:00 (Migrated from github.com)
Review

is this really no big deal? seems like an error to me but idk rocksdb

is this really no big deal? seems like an error to me but idk rocksdb
lyoshenka commented 2022-03-24 22:38:01 +01:00 (Migrated from github.com)
Review

typo: Famlies -> Families

typo: Famlies -> Families
lyoshenka commented 2022-03-24 22:41:04 +01:00 (Migrated from github.com)
Review

this can be unexported

this can be unexported
lyoshenka commented 2022-03-24 22:41:39 +01:00 (Migrated from github.com)
Review

still need this?

still need this?
lyoshenka commented 2022-03-24 22:43:06 +01:00 (Migrated from github.com)
Review

typo

typo
lyoshenka commented 2022-03-24 22:43:32 +01:00 (Migrated from github.com)
Review

👀

:eyes:
jeffreypicard commented 2022-03-24 23:32:48 +01:00 (Migrated from github.com)
Review

I agree the "N" can go. I copied these all over from the Python. where I believe they are similarly unused, because I thought it might be the defacto documentation.

I agree the "N" can go. I copied these all over from the Python. where I believe they are similarly unused, because I thought it might be the defacto documentation.
jeffreypicard commented 2022-03-24 23:39:47 +01:00 (Migrated from github.com)
Review
// Valid returns false only when an Iterator has iterated past either the
// first or the last key in the database.
func (iter *Iterator) Valid() bool {
	return C.rocksdb_iter_valid(iter.c) != 0
}

If our iterator was to try to go off the end of the db, or the front if we're going backwards, we need to check this.

``` // Valid returns false only when an Iterator has iterated past either the // first or the last key in the database. func (iter *Iterator) Valid() bool { return C.rocksdb_iter_valid(iter.c) != 0 } ``` If our iterator was to try to go off the end of the db, or the front if we're going backwards, we need to check this.
db.Height = db.TxCounts.Len()
lyoshenka commented 2022-03-24 22:26:17 +01:00 (Migrated from github.com)
Review

no need to start these with N

no need to start these with N
lyoshenka commented 2022-03-24 22:26:38 +01:00 (Migrated from github.com)
Review

and many of these are unused

and many of these are unused
lyoshenka commented 2022-03-24 22:34:50 +01:00 (Migrated from github.com)
Review

is this really no big deal? seems like an error to me but idk rocksdb

is this really no big deal? seems like an error to me but idk rocksdb
lyoshenka commented 2022-03-24 22:38:01 +01:00 (Migrated from github.com)
Review

typo: Famlies -> Families

typo: Famlies -> Families
lyoshenka commented 2022-03-24 22:41:04 +01:00 (Migrated from github.com)
Review

this can be unexported

this can be unexported
lyoshenka commented 2022-03-24 22:41:39 +01:00 (Migrated from github.com)
Review

still need this?

still need this?
lyoshenka commented 2022-03-24 22:43:06 +01:00 (Migrated from github.com)
Review

typo

typo
lyoshenka commented 2022-03-24 22:43:32 +01:00 (Migrated from github.com)
Review

👀

:eyes:
jeffreypicard commented 2022-03-24 23:32:48 +01:00 (Migrated from github.com)
Review

I agree the "N" can go. I copied these all over from the Python. where I believe they are similarly unused, because I thought it might be the defacto documentation.

I agree the "N" can go. I copied these all over from the Python. where I believe they are similarly unused, because I thought it might be the defacto documentation.
jeffreypicard commented 2022-03-24 23:39:47 +01:00 (Migrated from github.com)
Review
// Valid returns false only when an Iterator has iterated past either the
// first or the last key in the database.
func (iter *Iterator) Valid() bool {
	return C.rocksdb_iter_valid(iter.c) != 0
}

If our iterator was to try to go off the end of the db, or the front if we're going backwards, we need to check this.

``` // Valid returns false only when an Iterator has iterated past either the // first or the last key in the database. func (iter *Iterator) Valid() bool { return C.rocksdb_iter_valid(iter.c) != 0 } ``` If our iterator was to try to go off the end of the db, or the front if we're going backwards, we need to check this.
// if db.TxCounts.Len() > 0 {
lyoshenka commented 2022-03-24 22:26:17 +01:00 (Migrated from github.com)
Review

no need to start these with N

no need to start these with N
lyoshenka commented 2022-03-24 22:26:38 +01:00 (Migrated from github.com)
Review

and many of these are unused

and many of these are unused
lyoshenka commented 2022-03-24 22:34:50 +01:00 (Migrated from github.com)
Review

is this really no big deal? seems like an error to me but idk rocksdb

is this really no big deal? seems like an error to me but idk rocksdb
lyoshenka commented 2022-03-24 22:38:01 +01:00 (Migrated from github.com)
Review

typo: Famlies -> Families

typo: Famlies -> Families
lyoshenka commented 2022-03-24 22:41:04 +01:00 (Migrated from github.com)
Review

this can be unexported

this can be unexported
lyoshenka commented 2022-03-24 22:41:39 +01:00 (Migrated from github.com)
Review

still need this?

still need this?
lyoshenka commented 2022-03-24 22:43:06 +01:00 (Migrated from github.com)
Review

typo

typo
lyoshenka commented 2022-03-24 22:43:32 +01:00 (Migrated from github.com)
Review

👀

:eyes:
jeffreypicard commented 2022-03-24 23:32:48 +01:00 (Migrated from github.com)
Review

I agree the "N" can go. I copied these all over from the Python. where I believe they are similarly unused, because I thought it might be the defacto documentation.

I agree the "N" can go. I copied these all over from the Python. where I believe they are similarly unused, because I thought it might be the defacto documentation.
jeffreypicard commented 2022-03-24 23:39:47 +01:00 (Migrated from github.com)
Review
// Valid returns false only when an Iterator has iterated past either the
// first or the last key in the database.
func (iter *Iterator) Valid() bool {
	return C.rocksdb_iter_valid(iter.c) != 0
}

If our iterator was to try to go off the end of the db, or the front if we're going backwards, we need to check this.

``` // Valid returns false only when an Iterator has iterated past either the // first or the last key in the database. func (iter *Iterator) Valid() bool { return C.rocksdb_iter_valid(iter.c) != 0 } ``` If our iterator was to try to go off the end of the db, or the front if we're going backwards, we need to check this.
// db.Height = db.TxCounts.Len() - 1
lyoshenka commented 2022-03-24 22:26:17 +01:00 (Migrated from github.com)
Review

no need to start these with N

no need to start these with N
lyoshenka commented 2022-03-24 22:26:38 +01:00 (Migrated from github.com)
Review

and many of these are unused

and many of these are unused
lyoshenka commented 2022-03-24 22:34:50 +01:00 (Migrated from github.com)
Review

is this really no big deal? seems like an error to me but idk rocksdb

is this really no big deal? seems like an error to me but idk rocksdb
lyoshenka commented 2022-03-24 22:38:01 +01:00 (Migrated from github.com)
Review

typo: Famlies -> Families

typo: Famlies -> Families
lyoshenka commented 2022-03-24 22:41:04 +01:00 (Migrated from github.com)
Review

this can be unexported

this can be unexported
lyoshenka commented 2022-03-24 22:41:39 +01:00 (Migrated from github.com)
Review

still need this?

still need this?
lyoshenka commented 2022-03-24 22:43:06 +01:00 (Migrated from github.com)
Review

typo

typo
lyoshenka commented 2022-03-24 22:43:32 +01:00 (Migrated from github.com)
Review

👀

:eyes:
jeffreypicard commented 2022-03-24 23:32:48 +01:00 (Migrated from github.com)
Review

I agree the "N" can go. I copied these all over from the Python. where I believe they are similarly unused, because I thought it might be the defacto documentation.

I agree the "N" can go. I copied these all over from the Python. where I believe they are similarly unused, because I thought it might be the defacto documentation.
jeffreypicard commented 2022-03-24 23:39:47 +01:00 (Migrated from github.com)
Review
// Valid returns false only when an Iterator has iterated past either the
// first or the last key in the database.
func (iter *Iterator) Valid() bool {
	return C.rocksdb_iter_valid(iter.c) != 0
}

If our iterator was to try to go off the end of the db, or the front if we're going backwards, we need to check this.

``` // Valid returns false only when an Iterator has iterated past either the // first or the last key in the database. func (iter *Iterator) Valid() bool { return C.rocksdb_iter_valid(iter.c) != 0 } ``` If our iterator was to try to go off the end of the db, or the front if we're going backwards, we need to check this.
// } else {
lyoshenka commented 2022-03-24 22:26:17 +01:00 (Migrated from github.com)
Review

no need to start these with N

no need to start these with N
lyoshenka commented 2022-03-24 22:26:38 +01:00 (Migrated from github.com)
Review

and many of these are unused

and many of these are unused
lyoshenka commented 2022-03-24 22:34:50 +01:00 (Migrated from github.com)
Review

is this really no big deal? seems like an error to me but idk rocksdb

is this really no big deal? seems like an error to me but idk rocksdb
lyoshenka commented 2022-03-24 22:38:01 +01:00 (Migrated from github.com)
Review

typo: Famlies -> Families

typo: Famlies -> Families
lyoshenka commented 2022-03-24 22:41:04 +01:00 (Migrated from github.com)
Review

this can be unexported

this can be unexported
lyoshenka commented 2022-03-24 22:41:39 +01:00 (Migrated from github.com)
Review

still need this?

still need this?
lyoshenka commented 2022-03-24 22:43:06 +01:00 (Migrated from github.com)
Review

typo

typo
lyoshenka commented 2022-03-24 22:43:32 +01:00 (Migrated from github.com)
Review

👀

:eyes:
jeffreypicard commented 2022-03-24 23:32:48 +01:00 (Migrated from github.com)
Review

I agree the "N" can go. I copied these all over from the Python. where I believe they are similarly unused, because I thought it might be the defacto documentation.

I agree the "N" can go. I copied these all over from the Python. where I believe they are similarly unused, because I thought it might be the defacto documentation.
jeffreypicard commented 2022-03-24 23:39:47 +01:00 (Migrated from github.com)
Review
// Valid returns false only when an Iterator has iterated past either the
// first or the last key in the database.
func (iter *Iterator) Valid() bool {
	return C.rocksdb_iter_valid(iter.c) != 0
}

If our iterator was to try to go off the end of the db, or the front if we're going backwards, we need to check this.

``` // Valid returns false only when an Iterator has iterated past either the // first or the last key in the database. func (iter *Iterator) Valid() bool { return C.rocksdb_iter_valid(iter.c) != 0 } ``` If our iterator was to try to go off the end of the db, or the front if we're going backwards, we need to check this.
// log.Println("db.TxCounts.Len() == 0 ???")
lyoshenka commented 2022-03-24 22:26:17 +01:00 (Migrated from github.com)
Review

no need to start these with N

no need to start these with N
lyoshenka commented 2022-03-24 22:26:38 +01:00 (Migrated from github.com)
Review

and many of these are unused

and many of these are unused
lyoshenka commented 2022-03-24 22:34:50 +01:00 (Migrated from github.com)
Review

is this really no big deal? seems like an error to me but idk rocksdb

is this really no big deal? seems like an error to me but idk rocksdb
lyoshenka commented 2022-03-24 22:38:01 +01:00 (Migrated from github.com)
Review

typo: Famlies -> Families

typo: Famlies -> Families
lyoshenka commented 2022-03-24 22:41:04 +01:00 (Migrated from github.com)
Review

this can be unexported

this can be unexported
lyoshenka commented 2022-03-24 22:41:39 +01:00 (Migrated from github.com)
Review

still need this?

still need this?
lyoshenka commented 2022-03-24 22:43:06 +01:00 (Migrated from github.com)
Review

typo

typo
lyoshenka commented 2022-03-24 22:43:32 +01:00 (Migrated from github.com)
Review

👀

:eyes:
jeffreypicard commented 2022-03-24 23:32:48 +01:00 (Migrated from github.com)
Review

I agree the "N" can go. I copied these all over from the Python. where I believe they are similarly unused, because I thought it might be the defacto documentation.

I agree the "N" can go. I copied these all over from the Python. where I believe they are similarly unused, because I thought it might be the defacto documentation.
jeffreypicard commented 2022-03-24 23:39:47 +01:00 (Migrated from github.com)
Review
// Valid returns false only when an Iterator has iterated past either the
// first or the last key in the database.
func (iter *Iterator) Valid() bool {
	return C.rocksdb_iter_valid(iter.c) != 0
}

If our iterator was to try to go off the end of the db, or the front if we're going backwards, we need to check this.

``` // Valid returns false only when an Iterator has iterated past either the // first or the last key in the database. func (iter *Iterator) Valid() bool { return C.rocksdb_iter_valid(iter.c) != 0 } ``` If our iterator was to try to go off the end of the db, or the front if we're going backwards, we need to check this.
// }
lyoshenka commented 2022-03-24 22:26:17 +01:00 (Migrated from github.com)
Review

no need to start these with N

no need to start these with N
lyoshenka commented 2022-03-24 22:26:38 +01:00 (Migrated from github.com)
Review

and many of these are unused

and many of these are unused
lyoshenka commented 2022-03-24 22:34:50 +01:00 (Migrated from github.com)
Review

is this really no big deal? seems like an error to me but idk rocksdb

is this really no big deal? seems like an error to me but idk rocksdb
lyoshenka commented 2022-03-24 22:38:01 +01:00 (Migrated from github.com)
Review

typo: Famlies -> Families

typo: Famlies -> Families
lyoshenka commented 2022-03-24 22:41:04 +01:00 (Migrated from github.com)
Review

this can be unexported

this can be unexported
lyoshenka commented 2022-03-24 22:41:39 +01:00 (Migrated from github.com)
Review

still need this?

still need this?
lyoshenka commented 2022-03-24 22:43:06 +01:00 (Migrated from github.com)
Review

typo

typo
lyoshenka commented 2022-03-24 22:43:32 +01:00 (Migrated from github.com)
Review

👀

:eyes:
jeffreypicard commented 2022-03-24 23:32:48 +01:00 (Migrated from github.com)
Review

I agree the "N" can go. I copied these all over from the Python. where I believe they are similarly unused, because I thought it might be the defacto documentation.

I agree the "N" can go. I copied these all over from the Python. where I believe they are similarly unused, because I thought it might be the defacto documentation.
jeffreypicard commented 2022-03-24 23:39:47 +01:00 (Migrated from github.com)
Review
// Valid returns false only when an Iterator has iterated past either the
// first or the last key in the database.
func (iter *Iterator) Valid() bool {
	return C.rocksdb_iter_valid(iter.c) != 0
}

If our iterator was to try to go off the end of the db, or the front if we're going backwards, we need to check this.

``` // Valid returns false only when an Iterator has iterated past either the // first or the last key in the database. func (iter *Iterator) Valid() bool { return C.rocksdb_iter_valid(iter.c) != 0 } ``` If our iterator was to try to go off the end of the db, or the front if we're going backwards, we need to check this.
return nil
}

lyoshenka commented 2022-03-24 22:26:17 +01:00 (Migrated from github.com)
Review

no need to start these with N

no need to start these with N
lyoshenka commented 2022-03-24 22:26:38 +01:00 (Migrated from github.com)
Review

and many of these are unused

and many of these are unused
lyoshenka commented 2022-03-24 22:34:50 +01:00 (Migrated from github.com)
Review

is this really no big deal? seems like an error to me but idk rocksdb

is this really no big deal? seems like an error to me but idk rocksdb
lyoshenka commented 2022-03-24 22:38:01 +01:00 (Migrated from github.com)
Review

typo: Famlies -> Families

typo: Famlies -> Families
lyoshenka commented 2022-03-24 22:41:04 +01:00 (Migrated from github.com)
Review

this can be unexported

this can be unexported
lyoshenka commented 2022-03-24 22:41:39 +01:00 (Migrated from github.com)
Review

still need this?

still need this?
lyoshenka commented 2022-03-24 22:43:06 +01:00 (Migrated from github.com)
Review

typo

typo
lyoshenka commented 2022-03-24 22:43:32 +01:00 (Migrated from github.com)
Review

👀

:eyes:
jeffreypicard commented 2022-03-24 23:32:48 +01:00 (Migrated from github.com)
Review

I agree the "N" can go. I copied these all over from the Python. where I believe they are similarly unused, because I thought it might be the defacto documentation.

I agree the "N" can go. I copied these all over from the Python. where I believe they are similarly unused, because I thought it might be the defacto documentation.
jeffreypicard commented 2022-03-24 23:39:47 +01:00 (Migrated from github.com)
Review
// Valid returns false only when an Iterator has iterated past either the
// first or the last key in the database.
func (iter *Iterator) Valid() bool {
	return C.rocksdb_iter_valid(iter.c) != 0
}

If our iterator was to try to go off the end of the db, or the front if we're going backwards, we need to check this.

``` // Valid returns false only when an Iterator has iterated past either the // first or the last key in the database. func (iter *Iterator) Valid() bool { return C.rocksdb_iter_valid(iter.c) != 0 } ``` If our iterator was to try to go off the end of the db, or the front if we're going backwards, we need to check this.
lyoshenka commented 2022-03-24 22:26:17 +01:00 (Migrated from github.com)
Review

no need to start these with N

no need to start these with N
lyoshenka commented 2022-03-24 22:26:38 +01:00 (Migrated from github.com)
Review

and many of these are unused

and many of these are unused
lyoshenka commented 2022-03-24 22:34:50 +01:00 (Migrated from github.com)
Review

is this really no big deal? seems like an error to me but idk rocksdb

is this really no big deal? seems like an error to me but idk rocksdb
lyoshenka commented 2022-03-24 22:38:01 +01:00 (Migrated from github.com)
Review

typo: Famlies -> Families

typo: Famlies -> Families
lyoshenka commented 2022-03-24 22:41:04 +01:00 (Migrated from github.com)
Review

this can be unexported

this can be unexported
lyoshenka commented 2022-03-24 22:41:39 +01:00 (Migrated from github.com)
Review

still need this?

still need this?
lyoshenka commented 2022-03-24 22:43:06 +01:00 (Migrated from github.com)
Review

typo

typo
lyoshenka commented 2022-03-24 22:43:32 +01:00 (Migrated from github.com)
Review

👀

:eyes:
jeffreypicard commented 2022-03-24 23:32:48 +01:00 (Migrated from github.com)
Review

I agree the "N" can go. I copied these all over from the Python. where I believe they are similarly unused, because I thought it might be the defacto documentation.

I agree the "N" can go. I copied these all over from the Python. where I believe they are similarly unused, because I thought it might be the defacto documentation.
jeffreypicard commented 2022-03-24 23:39:47 +01:00 (Migrated from github.com)
Review
// Valid returns false only when an Iterator has iterated past either the
// first or the last key in the database.
func (iter *Iterator) Valid() bool {
	return C.rocksdb_iter_valid(iter.c) != 0
}

If our iterator was to try to go off the end of the db, or the front if we're going backwards, we need to check this.

``` // Valid returns false only when an Iterator has iterated past either the // first or the last key in the database. func (iter *Iterator) Valid() bool { return C.rocksdb_iter_valid(iter.c) != 0 } ``` If our iterator was to try to go off the end of the db, or the front if we're going backwards, we need to check this.

View file

@ -100,24 +100,6 @@ type PrefixRowKV struct {
lyoshenka commented 2022-03-24 19:47:15 +01:00 (Migrated from github.com)
Review

why snake case here?

why snake case here?
lyoshenka commented 2022-03-24 19:50:57 +01:00 (Migrated from github.com)
Review

if this is a fixed size, should it be an array? or even a chainhash.Hash? https://github.com/lbryio/lbcd/blob/master/chaincfg/chainhash/hash.go#L25

if this is a fixed size, should it be an array? or even a chainhash.Hash? https://github.com/lbryio/lbcd/blob/master/chaincfg/chainhash/hash.go#L25
lyoshenka commented 2022-03-24 19:51:47 +01:00 (Migrated from github.com)
Review

i suggest using lbcd types as much as possible where it makes sense. if something is a Hash, make it a Hash. if its an Address, make it an Address.

i suggest using lbcd types as much as possible where it makes sense. if something is a Hash, make it a Hash. if its an Address, make it an Address.
lyoshenka commented 2022-03-24 19:47:15 +01:00 (Migrated from github.com)
Review

why snake case here?

why snake case here?
lyoshenka commented 2022-03-24 19:50:57 +01:00 (Migrated from github.com)
Review

if this is a fixed size, should it be an array? or even a chainhash.Hash? https://github.com/lbryio/lbcd/blob/master/chaincfg/chainhash/hash.go#L25

if this is a fixed size, should it be an array? or even a chainhash.Hash? https://github.com/lbryio/lbcd/blob/master/chaincfg/chainhash/hash.go#L25
lyoshenka commented 2022-03-24 19:51:47 +01:00 (Migrated from github.com)
Review

i suggest using lbcd types as much as possible where it makes sense. if something is a Hash, make it a Hash. if its an Address, make it an Address.

i suggest using lbcd types as much as possible where it makes sense. if something is a Hash, make it a Hash. if its an Address, make it an Address.
Value interface{}
}
/*
lyoshenka commented 2022-03-24 19:47:15 +01:00 (Migrated from github.com)
Review

why snake case here?

why snake case here?
lyoshenka commented 2022-03-24 19:50:57 +01:00 (Migrated from github.com)
Review

if this is a fixed size, should it be an array? or even a chainhash.Hash? https://github.com/lbryio/lbcd/blob/master/chaincfg/chainhash/hash.go#L25

if this is a fixed size, should it be an array? or even a chainhash.Hash? https://github.com/lbryio/lbcd/blob/master/chaincfg/chainhash/hash.go#L25
lyoshenka commented 2022-03-24 19:51:47 +01:00 (Migrated from github.com)
Review

i suggest using lbcd types as much as possible where it makes sense. if something is a Hash, make it a Hash. if its an Address, make it an Address.

i suggest using lbcd types as much as possible where it makes sense. if something is a Hash, make it a Hash. if its an Address, make it an Address.
class DBState(typing.NamedTuple):
lyoshenka commented 2022-03-24 19:47:15 +01:00 (Migrated from github.com)
Review

why snake case here?

why snake case here?
lyoshenka commented 2022-03-24 19:50:57 +01:00 (Migrated from github.com)
Review

if this is a fixed size, should it be an array? or even a chainhash.Hash? https://github.com/lbryio/lbcd/blob/master/chaincfg/chainhash/hash.go#L25

if this is a fixed size, should it be an array? or even a chainhash.Hash? https://github.com/lbryio/lbcd/blob/master/chaincfg/chainhash/hash.go#L25
lyoshenka commented 2022-03-24 19:51:47 +01:00 (Migrated from github.com)
Review

i suggest using lbcd types as much as possible where it makes sense. if something is a Hash, make it a Hash. if its an Address, make it an Address.

i suggest using lbcd types as much as possible where it makes sense. if something is a Hash, make it a Hash. if its an Address, make it an Address.
genesis: bytes
lyoshenka commented 2022-03-24 19:47:15 +01:00 (Migrated from github.com)
Review

why snake case here?

why snake case here?
lyoshenka commented 2022-03-24 19:50:57 +01:00 (Migrated from github.com)
Review

if this is a fixed size, should it be an array? or even a chainhash.Hash? https://github.com/lbryio/lbcd/blob/master/chaincfg/chainhash/hash.go#L25

if this is a fixed size, should it be an array? or even a chainhash.Hash? https://github.com/lbryio/lbcd/blob/master/chaincfg/chainhash/hash.go#L25
lyoshenka commented 2022-03-24 19:51:47 +01:00 (Migrated from github.com)
Review

i suggest using lbcd types as much as possible where it makes sense. if something is a Hash, make it a Hash. if its an Address, make it an Address.

i suggest using lbcd types as much as possible where it makes sense. if something is a Hash, make it a Hash. if its an Address, make it an Address.
height: int
lyoshenka commented 2022-03-24 19:47:15 +01:00 (Migrated from github.com)
Review

why snake case here?

why snake case here?
lyoshenka commented 2022-03-24 19:50:57 +01:00 (Migrated from github.com)
Review

if this is a fixed size, should it be an array? or even a chainhash.Hash? https://github.com/lbryio/lbcd/blob/master/chaincfg/chainhash/hash.go#L25

if this is a fixed size, should it be an array? or even a chainhash.Hash? https://github.com/lbryio/lbcd/blob/master/chaincfg/chainhash/hash.go#L25
lyoshenka commented 2022-03-24 19:51:47 +01:00 (Migrated from github.com)
Review

i suggest using lbcd types as much as possible where it makes sense. if something is a Hash, make it a Hash. if its an Address, make it an Address.

i suggest using lbcd types as much as possible where it makes sense. if something is a Hash, make it a Hash. if its an Address, make it an Address.
tx_count: int
lyoshenka commented 2022-03-24 19:47:15 +01:00 (Migrated from github.com)
Review

why snake case here?

why snake case here?
lyoshenka commented 2022-03-24 19:50:57 +01:00 (Migrated from github.com)
Review

if this is a fixed size, should it be an array? or even a chainhash.Hash? https://github.com/lbryio/lbcd/blob/master/chaincfg/chainhash/hash.go#L25

if this is a fixed size, should it be an array? or even a chainhash.Hash? https://github.com/lbryio/lbcd/blob/master/chaincfg/chainhash/hash.go#L25
lyoshenka commented 2022-03-24 19:51:47 +01:00 (Migrated from github.com)
Review

i suggest using lbcd types as much as possible where it makes sense. if something is a Hash, make it a Hash. if its an Address, make it an Address.

i suggest using lbcd types as much as possible where it makes sense. if something is a Hash, make it a Hash. if its an Address, make it an Address.
tip: bytes
lyoshenka commented 2022-03-24 19:47:15 +01:00 (Migrated from github.com)
Review

why snake case here?

why snake case here?
lyoshenka commented 2022-03-24 19:50:57 +01:00 (Migrated from github.com)
Review

if this is a fixed size, should it be an array? or even a chainhash.Hash? https://github.com/lbryio/lbcd/blob/master/chaincfg/chainhash/hash.go#L25

if this is a fixed size, should it be an array? or even a chainhash.Hash? https://github.com/lbryio/lbcd/blob/master/chaincfg/chainhash/hash.go#L25
lyoshenka commented 2022-03-24 19:51:47 +01:00 (Migrated from github.com)
Review

i suggest using lbcd types as much as possible where it makes sense. if something is a Hash, make it a Hash. if its an Address, make it an Address.

i suggest using lbcd types as much as possible where it makes sense. if something is a Hash, make it a Hash. if its an Address, make it an Address.
utxo_flush_count: int
lyoshenka commented 2022-03-24 19:47:15 +01:00 (Migrated from github.com)
Review

why snake case here?

why snake case here?
lyoshenka commented 2022-03-24 19:50:57 +01:00 (Migrated from github.com)
Review

if this is a fixed size, should it be an array? or even a chainhash.Hash? https://github.com/lbryio/lbcd/blob/master/chaincfg/chainhash/hash.go#L25

if this is a fixed size, should it be an array? or even a chainhash.Hash? https://github.com/lbryio/lbcd/blob/master/chaincfg/chainhash/hash.go#L25
lyoshenka commented 2022-03-24 19:51:47 +01:00 (Migrated from github.com)
Review

i suggest using lbcd types as much as possible where it makes sense. if something is a Hash, make it a Hash. if its an Address, make it an Address.

i suggest using lbcd types as much as possible where it makes sense. if something is a Hash, make it a Hash. if its an Address, make it an Address.
wall_time: int
lyoshenka commented 2022-03-24 19:47:15 +01:00 (Migrated from github.com)
Review

why snake case here?

why snake case here?
lyoshenka commented 2022-03-24 19:50:57 +01:00 (Migrated from github.com)
Review

if this is a fixed size, should it be an array? or even a chainhash.Hash? https://github.com/lbryio/lbcd/blob/master/chaincfg/chainhash/hash.go#L25

if this is a fixed size, should it be an array? or even a chainhash.Hash? https://github.com/lbryio/lbcd/blob/master/chaincfg/chainhash/hash.go#L25
lyoshenka commented 2022-03-24 19:51:47 +01:00 (Migrated from github.com)
Review

i suggest using lbcd types as much as possible where it makes sense. if something is a Hash, make it a Hash. if its an Address, make it an Address.

i suggest using lbcd types as much as possible where it makes sense. if something is a Hash, make it a Hash. if its an Address, make it an Address.
first_sync: bool
lyoshenka commented 2022-03-24 19:47:15 +01:00 (Migrated from github.com)
Review

why snake case here?

why snake case here?
lyoshenka commented 2022-03-24 19:50:57 +01:00 (Migrated from github.com)
Review

if this is a fixed size, should it be an array? or even a chainhash.Hash? https://github.com/lbryio/lbcd/blob/master/chaincfg/chainhash/hash.go#L25

if this is a fixed size, should it be an array? or even a chainhash.Hash? https://github.com/lbryio/lbcd/blob/master/chaincfg/chainhash/hash.go#L25
lyoshenka commented 2022-03-24 19:51:47 +01:00 (Migrated from github.com)
Review

i suggest using lbcd types as much as possible where it makes sense. if something is a Hash, make it a Hash. if its an Address, make it an Address.

i suggest using lbcd types as much as possible where it makes sense. if something is a Hash, make it a Hash. if its an Address, make it an Address.
db_version: int
lyoshenka commented 2022-03-24 19:47:15 +01:00 (Migrated from github.com)
Review

why snake case here?

why snake case here?
lyoshenka commented 2022-03-24 19:50:57 +01:00 (Migrated from github.com)
Review

if this is a fixed size, should it be an array? or even a chainhash.Hash? https://github.com/lbryio/lbcd/blob/master/chaincfg/chainhash/hash.go#L25

if this is a fixed size, should it be an array? or even a chainhash.Hash? https://github.com/lbryio/lbcd/blob/master/chaincfg/chainhash/hash.go#L25
lyoshenka commented 2022-03-24 19:51:47 +01:00 (Migrated from github.com)
Review

i suggest using lbcd types as much as possible where it makes sense. if something is a Hash, make it a Hash. if its an Address, make it an Address.

i suggest using lbcd types as much as possible where it makes sense. if something is a Hash, make it a Hash. if its an Address, make it an Address.
hist_flush_count: int
lyoshenka commented 2022-03-24 19:47:15 +01:00 (Migrated from github.com)
Review

why snake case here?

why snake case here?
lyoshenka commented 2022-03-24 19:50:57 +01:00 (Migrated from github.com)
Review

if this is a fixed size, should it be an array? or even a chainhash.Hash? https://github.com/lbryio/lbcd/blob/master/chaincfg/chainhash/hash.go#L25

if this is a fixed size, should it be an array? or even a chainhash.Hash? https://github.com/lbryio/lbcd/blob/master/chaincfg/chainhash/hash.go#L25
lyoshenka commented 2022-03-24 19:51:47 +01:00 (Migrated from github.com)
Review

i suggest using lbcd types as much as possible where it makes sense. if something is a Hash, make it a Hash. if its an Address, make it an Address.

i suggest using lbcd types as much as possible where it makes sense. if something is a Hash, make it a Hash. if its an Address, make it an Address.
comp_flush_count: int
lyoshenka commented 2022-03-24 19:47:15 +01:00 (Migrated from github.com)
Review

why snake case here?

why snake case here?
lyoshenka commented 2022-03-24 19:50:57 +01:00 (Migrated from github.com)
Review

if this is a fixed size, should it be an array? or even a chainhash.Hash? https://github.com/lbryio/lbcd/blob/master/chaincfg/chainhash/hash.go#L25

if this is a fixed size, should it be an array? or even a chainhash.Hash? https://github.com/lbryio/lbcd/blob/master/chaincfg/chainhash/hash.go#L25
lyoshenka commented 2022-03-24 19:51:47 +01:00 (Migrated from github.com)
Review

i suggest using lbcd types as much as possible where it makes sense. if something is a Hash, make it a Hash. if its an Address, make it an Address.

i suggest using lbcd types as much as possible where it makes sense. if something is a Hash, make it a Hash. if its an Address, make it an Address.
comp_cursor: int
lyoshenka commented 2022-03-24 19:47:15 +01:00 (Migrated from github.com)
Review

why snake case here?

why snake case here?
lyoshenka commented 2022-03-24 19:50:57 +01:00 (Migrated from github.com)
Review

if this is a fixed size, should it be an array? or even a chainhash.Hash? https://github.com/lbryio/lbcd/blob/master/chaincfg/chainhash/hash.go#L25

if this is a fixed size, should it be an array? or even a chainhash.Hash? https://github.com/lbryio/lbcd/blob/master/chaincfg/chainhash/hash.go#L25
lyoshenka commented 2022-03-24 19:51:47 +01:00 (Migrated from github.com)
Review

i suggest using lbcd types as much as possible where it makes sense. if something is a Hash, make it a Hash. if its an Address, make it an Address.

i suggest using lbcd types as much as possible where it makes sense. if something is a Hash, make it a Hash. if its an Address, make it an Address.
es_sync_height: int
lyoshenka commented 2022-03-24 19:47:15 +01:00 (Migrated from github.com)
Review

why snake case here?

why snake case here?
lyoshenka commented 2022-03-24 19:50:57 +01:00 (Migrated from github.com)
Review

if this is a fixed size, should it be an array? or even a chainhash.Hash? https://github.com/lbryio/lbcd/blob/master/chaincfg/chainhash/hash.go#L25

if this is a fixed size, should it be an array? or even a chainhash.Hash? https://github.com/lbryio/lbcd/blob/master/chaincfg/chainhash/hash.go#L25
lyoshenka commented 2022-03-24 19:51:47 +01:00 (Migrated from github.com)
Review

i suggest using lbcd types as much as possible where it makes sense. if something is a Hash, make it a Hash. if its an Address, make it an Address.

i suggest using lbcd types as much as possible where it makes sense. if something is a Hash, make it a Hash. if its an Address, make it an Address.
lyoshenka commented 2022-03-24 19:47:15 +01:00 (Migrated from github.com)
Review

why snake case here?

why snake case here?
lyoshenka commented 2022-03-24 19:50:57 +01:00 (Migrated from github.com)
Review

if this is a fixed size, should it be an array? or even a chainhash.Hash? https://github.com/lbryio/lbcd/blob/master/chaincfg/chainhash/hash.go#L25

if this is a fixed size, should it be an array? or even a chainhash.Hash? https://github.com/lbryio/lbcd/blob/master/chaincfg/chainhash/hash.go#L25
lyoshenka commented 2022-03-24 19:51:47 +01:00 (Migrated from github.com)
Review

i suggest using lbcd types as much as possible where it makes sense. if something is a Hash, make it a Hash. if its an Address, make it an Address.

i suggest using lbcd types as much as possible where it makes sense. if something is a Hash, make it a Hash. if its an Address, make it an Address.
lyoshenka commented 2022-03-24 19:47:15 +01:00 (Migrated from github.com)
Review

why snake case here?

why snake case here?
lyoshenka commented 2022-03-24 19:50:57 +01:00 (Migrated from github.com)
Review

if this is a fixed size, should it be an array? or even a chainhash.Hash? https://github.com/lbryio/lbcd/blob/master/chaincfg/chainhash/hash.go#L25

if this is a fixed size, should it be an array? or even a chainhash.Hash? https://github.com/lbryio/lbcd/blob/master/chaincfg/chainhash/hash.go#L25
lyoshenka commented 2022-03-24 19:51:47 +01:00 (Migrated from github.com)
Review

i suggest using lbcd types as much as possible where it makes sense. if something is a Hash, make it a Hash. if its an Address, make it an Address.

i suggest using lbcd types as much as possible where it makes sense. if something is a Hash, make it a Hash. if its an Address, make it an Address.
*/
lyoshenka commented 2022-03-24 19:47:15 +01:00 (Migrated from github.com)
Review

why snake case here?

why snake case here?
lyoshenka commented 2022-03-24 19:50:57 +01:00 (Migrated from github.com)
Review

if this is a fixed size, should it be an array? or even a chainhash.Hash? https://github.com/lbryio/lbcd/blob/master/chaincfg/chainhash/hash.go#L25

if this is a fixed size, should it be an array? or even a chainhash.Hash? https://github.com/lbryio/lbcd/blob/master/chaincfg/chainhash/hash.go#L25
lyoshenka commented 2022-03-24 19:51:47 +01:00 (Migrated from github.com)
Review

i suggest using lbcd types as much as possible where it makes sense. if something is a Hash, make it a Hash. if its an Address, make it an Address.

i suggest using lbcd types as much as possible where it makes sense. if something is a Hash, make it a Hash. if its an Address, make it an Address.
lyoshenka commented 2022-03-24 19:47:15 +01:00 (Migrated from github.com)
Review

why snake case here?

why snake case here?
lyoshenka commented 2022-03-24 19:50:57 +01:00 (Migrated from github.com)
Review

if this is a fixed size, should it be an array? or even a chainhash.Hash? https://github.com/lbryio/lbcd/blob/master/chaincfg/chainhash/hash.go#L25

if this is a fixed size, should it be an array? or even a chainhash.Hash? https://github.com/lbryio/lbcd/blob/master/chaincfg/chainhash/hash.go#L25
lyoshenka commented 2022-03-24 19:51:47 +01:00 (Migrated from github.com)
Review

i suggest using lbcd types as much as possible where it makes sense. if something is a Hash, make it a Hash. if its an Address, make it an Address.

i suggest using lbcd types as much as possible where it makes sense. if something is a Hash, make it a Hash. if its an Address, make it an Address.
type DBStateKey struct {
Prefix []byte `json:"prefix"`
}

lyoshenka commented 2022-03-24 19:47:15 +01:00 (Migrated from github.com)
Review

why snake case here?

why snake case here?
lyoshenka commented 2022-03-24 19:50:57 +01:00 (Migrated from github.com)
Review

if this is a fixed size, should it be an array? or even a chainhash.Hash? https://github.com/lbryio/lbcd/blob/master/chaincfg/chainhash/hash.go#L25

if this is a fixed size, should it be an array? or even a chainhash.Hash? https://github.com/lbryio/lbcd/blob/master/chaincfg/chainhash/hash.go#L25
lyoshenka commented 2022-03-24 19:51:47 +01:00 (Migrated from github.com)
Review

i suggest using lbcd types as much as possible where it makes sense. if something is a Hash, make it a Hash. if its an Address, make it an Address.

i suggest using lbcd types as much as possible where it makes sense. if something is a Hash, make it a Hash. if its an Address, make it an Address.
lyoshenka commented 2022-03-24 19:47:15 +01:00 (Migrated from github.com)
Review

why snake case here?

why snake case here?
lyoshenka commented 2022-03-24 19:50:57 +01:00 (Migrated from github.com)
Review

if this is a fixed size, should it be an array? or even a chainhash.Hash? https://github.com/lbryio/lbcd/blob/master/chaincfg/chainhash/hash.go#L25

if this is a fixed size, should it be an array? or even a chainhash.Hash? https://github.com/lbryio/lbcd/blob/master/chaincfg/chainhash/hash.go#L25
lyoshenka commented 2022-03-24 19:51:47 +01:00 (Migrated from github.com)
Review

i suggest using lbcd types as much as possible where it makes sense. if something is a Hash, make it a Hash. if its an Address, make it an Address.

i suggest using lbcd types as much as possible where it makes sense. if something is a Hash, make it a Hash. if its an Address, make it an Address.