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

Rollback to pyo3 = { version = "0.16.6", features = ["abi3"] } #714

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

hswong3i
Copy link

@hswong3i hswong3i commented Jan 3, 2024

In order to avoid ImportError: PyO3 modules compiled for CPython 3.8 or older may only be initialized once per interpreter process introduced since pyo3 >= 0.17.0, which only allow each #[pymodule] to be initialized once, this PR temporarily rollback to pyo3 = 0.16.6.

It also remove the use of PyUserWarning which introduced since pyo3 > 0.18.0.

See PyO3/pyo3@78ba70d
See PyO3/pyo3@1d20f2a

Fixes #694

hswong3i added a commit to alvistack/pyca-bcrypt that referenced this pull request Jan 3, 2024
    git clean -xdf
    mkdir -p .cargo
    cargo vendor --manifest-path ./src/_bcrypt/Cargo.toml > .cargo/config.toml
    tar zcvf ../python-bcrypt_4.1.1.orig.tar.gz --exclude=.git .
    debuild -uc -us
    cp python-bcrypt.spec ../python-bcrypt_4.1.1-1.spec
    cp ../python*-bcrypt*4.1.1*.{gz,xz,spec,dsc} /osc/home\:alvistack/pyca-bcrypt-4.1.1/
    rm -rf ../python*-bcrypt*4.1.1*.*

See pyca#695
See pyca#714

Signed-off-by: Wong Hoi Sing Edison <[email protected]>
hswong3i added a commit to alvistack/pyca-bcrypt that referenced this pull request Jan 3, 2024
    git clean -xdf
    mkdir -p .cargo
    cargo vendor --manifest-path ./src/_bcrypt/Cargo.toml > .cargo/config.toml
    tar zcvf ../python-bcrypt_4.1.2.orig.tar.gz --exclude=.git .
    debuild -uc -us
    cp python-bcrypt.spec ../python-bcrypt_4.1.2-1.spec
    cp ../python*-bcrypt*4.1.2*.{gz,xz,spec,dsc} /osc/home\:alvistack/pyca-bcrypt-4.1.2/
    rm -rf ../python*-bcrypt*4.1.2*.*

See pyca#714

Signed-off-by: Wong Hoi Sing Edison <[email protected]>
hswong3i added a commit to alvistack/pyca-bcrypt that referenced this pull request Jan 3, 2024
    git clean -xdf
    mkdir -p .cargo
    cargo vendor --manifest-path ./src/_bcrypt/Cargo.toml > .cargo/config.toml
    tar zcvf ../python-bcrypt_4.1.2.orig.tar.gz --exclude=.git .
    debuild -uc -us
    cp python-bcrypt.spec ../python-bcrypt_4.1.2-1.spec
    cp ../python*-bcrypt*4.1.2*.{gz,xz,spec,dsc} /osc/home\:alvistack/pyca-bcrypt-4.1.2/
    rm -rf ../python*-bcrypt*4.1.2*.*

See pyca#714

Signed-off-by: Wong Hoi Sing Edison <[email protected]>
hswong3i added a commit to alvistack/pyca-bcrypt that referenced this pull request Jan 3, 2024
    git clean -xdf
    mkdir -p .cargo
    cargo vendor --manifest-path ./src/_bcrypt/Cargo.toml > .cargo/config.toml
    tar zcvf ../python-bcrypt_4.1.1.orig.tar.gz --exclude=.git .
    debuild -uc -us
    cp python-bcrypt.spec ../python-bcrypt_4.1.1-1.spec
    cp ../python*-bcrypt*4.1.1*.{gz,xz,spec,dsc} /osc/home\:alvistack/pyca-bcrypt-4.1.1/
    rm -rf ../python*-bcrypt*4.1.1*.*

See pyca#695
See pyca#714

Signed-off-by: Wong Hoi Sing Edison <[email protected]>
@alex
Copy link
Member

alex commented Jan 3, 2024

This does not actually fix the issue, it merely removes the error -- pyo3 modules still do not support sub-interpreters.

@hswong3i
Copy link
Author

hswong3i commented Jan 3, 2024

Yes this PR doesn't solve the problem but just rolling back as original behavior...

BTW I couldn't see any schedule for PyO3/pyo3#576 getting done...

If we don't really depends on features provided by pyo3 >= 0.17.0, at least this PR will not block the use of bcrypt on Ceph...

hswong3i added a commit to alvistack/pyca-bcrypt that referenced this pull request Feb 24, 2024
    git clean -xdf
    mkdir -p .cargo
    cargo vendor --manifest-path ./src/_bcrypt/Cargo.toml > .cargo/config.toml
    tar zcvf ../python-bcrypt_4.1.1.orig.tar.gz --exclude=.git .
    debuild -uc -us
    cp python-bcrypt.spec ../python-bcrypt_4.1.1-1.spec
    cp ../python*-bcrypt*4.1.1*.{gz,xz,spec,dsc} /osc/home\:alvistack/pyca-bcrypt-4.1.1/
    rm -rf ../python*-bcrypt*4.1.1*.*

See pyca#695
See pyca#714

Signed-off-by: Wong Hoi Sing Edison <[email protected]>
hswong3i added a commit to alvistack/pyca-bcrypt that referenced this pull request Feb 24, 2024
    git clean -xdf
    mkdir -p .cargo
    cargo vendor --manifest-path ./src/_bcrypt/Cargo.toml > .cargo/config.toml
    tar zcvf ../python-bcrypt_4.1.2.orig.tar.gz --exclude=.git .
    debuild -uc -us
    cp python-bcrypt.spec ../python-bcrypt_4.1.2-1.spec
    cp ../python*-bcrypt*4.1.2*.{gz,xz,spec,dsc} /osc/home\:alvistack/pyca-bcrypt-4.1.2/
    rm -rf ../python*-bcrypt*4.1.2*.*

See pyca#714

Signed-off-by: Wong Hoi Sing Edison <[email protected]>
hswong3i added a commit to alvistack/pyca-bcrypt that referenced this pull request May 4, 2024
    git clean -xdf
    mkdir -p .cargo
    cargo vendor --manifest-path ./src/_bcrypt/Cargo.toml > .cargo/config.toml
    tar zcvf ../python-bcrypt_4.1.3.orig.tar.gz --exclude=.git .
    debuild -uc -us
    cp python-bcrypt.spec ../python-bcrypt_4.1.3-1.spec
    cp ../python*-bcrypt*4.1.3*.{gz,xz,spec,dsc} /osc/home\:alvistack/pyca-bcrypt-4.1.3/
    rm -rf ../python*-bcrypt*4.1.3*.*

See pyca#714

Signed-off-by: Wong Hoi Sing Edison <[email protected]>
In order to avoid `ImportError: PyO3 modules compiled for CPython 3.8 or
older may only be initialized once per interpreter process` introduced
since pyo3 >= 0.17.0, which only allow each `#[pymodule]` to be
initialized once, this PR temporarily rollback to pyo3 = 0.16.6.

It also remove the use of `PyUserWarning` which introduced since pyo3 >
0.18.0.

See PyO3/pyo3@78ba70d
See PyO3/pyo3@1d20f2a

Fixes pyca#694

Signed-off-by: Wong Hoi Sing Edison <[email protected]>
@hswong3i
Copy link
Author

hswong3i commented May 4, 2024

Still, this is not a good idea for rollback; but well, PyO3/pyo3#576 have no progress as expected...

So at least an update for 4.1.3 + force push for this PR, used with my:

hswong3i added a commit to alvistack/pyca-bcrypt that referenced this pull request Jul 23, 2024
    git clean -xdf
    mkdir -p .cargo
    cargo vendor --manifest-path ./src/_bcrypt/Cargo.toml > .cargo/config.toml
    tar zcvf ../python-bcrypt_4.2.0.orig.tar.gz --exclude=.git .
    debuild -uc -us
    cp python-bcrypt.spec ../python-bcrypt_4.2.0-1.spec
    cp ../python*-bcrypt*4.2.0*.{gz,xz,spec,dsc} /osc/home\:alvistack/pyca-bcrypt-4.2.0/
    rm -rf ../python*-bcrypt*4.2.0*.*

See pyca#714

Signed-off-by: Wong Hoi Sing Edison <[email protected]>
hswong3i added a commit to alvistack/pyca-bcrypt that referenced this pull request Jul 23, 2024
    git clean -xdf
    mkdir -p .cargo
    cargo vendor --manifest-path ./src/_bcrypt/Cargo.toml > .cargo/config.toml
    tar zcvf ../python-bcrypt_4.2.0.orig.tar.gz --exclude=.git .
    debuild -uc -us
    cp python-bcrypt.spec ../python-bcrypt_4.2.0-1.spec
    cp ../python*-bcrypt*4.2.0*.{gz,xz,spec,dsc} /osc/home\:alvistack/pyca-bcrypt-4.2.0/
    rm -rf ../python*-bcrypt*4.2.0*.*

See pyca#714

Signed-off-by: Wong Hoi Sing Edison <[email protected]>
hswong3i added a commit to alvistack/pyca-bcrypt that referenced this pull request Jul 23, 2024
    git clean -xdf
    mkdir -p .cargo
    cargo vendor --manifest-path ./src/_bcrypt/Cargo.toml > .cargo/config.toml
    tar zcvf ../python-bcrypt_4.2.0.orig.tar.gz --exclude=.git .
    debuild -uc -us
    cp python-bcrypt.spec ../python-bcrypt_4.2.0-1.spec
    cp ../python*-bcrypt*4.2.0*.{gz,xz,spec,dsc} /osc/home\:alvistack/pyca-bcrypt-4.2.0/
    rm -rf ../python*-bcrypt*4.2.0*.*

See pyca#714

Signed-off-by: Wong Hoi Sing Edison <[email protected]>
hswong3i added a commit to alvistack/pyca-bcrypt that referenced this pull request Nov 16, 2024
    git clean -xdf
    mkdir -p .cargo
    cargo vendor --manifest-path ./src/_bcrypt/Cargo.toml > .cargo/config.toml
    tar zcvf ../python-bcrypt_4.2.0.orig.tar.gz --exclude=.git .
    debuild -uc -us
    cp python-bcrypt.spec ../python-bcrypt_4.2.0-1.spec
    cp ../python*-bcrypt*4.2.0*.{gz,xz,spec,dsc} /osc/home\:alvistack/pyca-bcrypt-4.2.0/
    rm -rf ../python*-bcrypt*4.2.0*.*

See pyca#714

Signed-off-by: Wong Hoi Sing Edison <[email protected]>
hswong3i added a commit to alvistack/pyca-bcrypt that referenced this pull request Nov 16, 2024
    git clean -xdf
    mkdir -p .cargo
    cargo vendor --manifest-path ./src/_bcrypt/Cargo.toml > .cargo/config.toml
    tar zcvf ../python-bcrypt_4.2.0.orig.tar.gz --exclude=.git .
    debuild -uc -us
    cp python-bcrypt.spec ../python-bcrypt_4.2.0-1.spec
    cp ../python*-bcrypt*4.2.0*.{gz,xz,spec,dsc} /osc/home\:alvistack/pyca-bcrypt-4.2.0/
    rm -rf ../python*-bcrypt*4.2.0*.*

See pyca#714

Signed-off-by: Wong Hoi Sing Edison <[email protected]>
hswong3i added a commit to alvistack/pyca-bcrypt that referenced this pull request Nov 16, 2024
    git clean -xdf
    mkdir -p .cargo
    cargo vendor --manifest-path ./src/_bcrypt/Cargo.toml > .cargo/config.toml
    tar zcvf ../python-bcrypt_4.2.0.orig.tar.gz --exclude=.git .
    debuild -uc -us
    cp python-bcrypt.spec ../python-bcrypt_4.2.0-1.spec
    cp ../python*-bcrypt*4.2.0*.{gz,xz,spec,dsc} /osc/home\:alvistack/pyca-bcrypt-4.2.0/
    rm -rf ../python*-bcrypt*4.2.0*.*

See pyca#714

Signed-off-by: Wong Hoi Sing Edison <[email protected]>
hswong3i added a commit to alvistack/pyca-bcrypt that referenced this pull request Nov 19, 2024
    git clean -xdf
    mkdir -p .cargo
    cargo vendor --manifest-path ./src/_bcrypt/Cargo.toml > .cargo/config.toml
    tar zcvf ../python-bcrypt_4.2.1.orig.tar.gz --exclude=.git .
    debuild -uc -us
    cp python-bcrypt.spec ../python-bcrypt_4.2.1-1.spec
    cp ../python*-bcrypt*4.2.1*.{gz,xz,spec,dsc} /osc/home\:alvistack/pyca-bcrypt-4.2.1/
    rm -rf ../python*-bcrypt*4.2.1*.*

See pyca#714

Signed-off-by: Wong Hoi Sing Edison <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants