🐛 Bug Reports
When reporting a bug, please provide the following information. If this is not a bug report you can just discard this template.
🌍 Environment
- Your operating system and version:
Arch Linux x86_64 5.7.4-arch1-1
- Your python version:
Python 3.8.3
- How did you install python (e.g. apt or pyenv)? Did you use a virtualenv?:
pacman
- Your Rust version (
rustc --version): rustc 1.46.0-nightly (6bb3dbfc6 2020-06-22)
- Your PyO3 version:
0.10.1
- Have you tried using latest PyO3 master (replace
version = "0.x.y" with git = "https://github.com/PyO3/pyo3")?: No
💥 Reproducing
Please provide a minimal working example. This means both the Rust code and the Python.
This compiles
#[cfg_attr(feature="pyo3", pyclass)]
#[derive(Debug, Default)]
pub struct Foo {
#[pyo3(get, set)]
bar: bool,
}
However, this doesn't
#[cfg_attr(feature="pyo3", pyclass)]
#[derive(Debug, Default)]
pub struct Foo {
#[cfg_attr(feature="pyo3", pyo3(get, set))]
bar: bool,
}
Because it can't find the pyo3 attribute
error: cannot find attribute `pyo3` in this scope
--> src/material/texture/mod.rs:45:32
|
45 | #[cfg_attr(feature="pyo3", pyo3(get, set))]
| ^^^^
Please also write what exact flags are required to reproduce your results.
🐛 Bug Reports
When reporting a bug, please provide the following information. If this is not a bug report you can just discard this template.
🌍 Environment
Arch Linux x86_64 5.7.4-arch1-1Python 3.8.3pacmanrustc --version):rustc 1.46.0-nightly (6bb3dbfc6 2020-06-22)0.10.1version = "0.x.y"withgit = "https://github.com/PyO3/pyo3")?: No💥 Reproducing
Please provide a minimal working example. This means both the Rust code and the Python.
This compiles
However, this doesn't
Because it can't find the
pyo3attributePlease also write what exact flags are required to reproduce your results.