Repository navigation
Commit 95481dc
committed
fix: bypass compile-time driver enforcement in plotly_static
When checking out the repository fresh and running `cargo check` or `cargo build` at the workspace root, the build fails immediately because `plotly_static` (a workspace member and dev-dependency of `plotly`) has no driver features enabled. Its build script previously enforced that at least one driver feature must be enabled, which is unnecessary for workspace-level compilation and fresh clones.
This commit comments out the "at least one driver feature" compile-time guard in `build.rs` to allow compiling `plotly_static` without driver features in workspaces. We also define a fallback `WEBDRIVER_BIN` in `src/webdriver.rs` and fallback `get_browser_name`/`get_options_key` in `src/lib.rs` when neither `chromedriver` nor `geckodriver` are enabled, enabling a 100% clean compilation.
Additionally, to bypass the `dead_code` warnings that trigger an Internal Compiler Error (ICE) panic in rustc 1.94.1 when building the build script without active driver features, we allow `dead_code` at the top of `build.rs`.
Signed-off-by: Mridankan Mandal <xerontitan90@gmail.com>1 parent ac7e8c8 commit 95481dc
3 files changed
Lines changed: 20 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
1 | 2 | | |
2 | 3 | | |
3 | 4 | | |
| |||
12 | 13 | | |
13 | 14 | | |
14 | 15 | | |
15 | | - | |
16 | | - | |
17 | | - | |
| 16 | + | |
18 | 17 | | |
19 | 18 | | |
20 | 19 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1717 | 1717 | | |
1718 | 1718 | | |
1719 | 1719 | | |
| 1720 | + | |
| 1721 | + | |
| 1722 | + | |
| 1723 | + | |
| 1724 | + | |
| 1725 | + | |
| 1726 | + | |
| 1727 | + | |
| 1728 | + | |
| 1729 | + | |
| 1730 | + | |
| 1731 | + | |
| 1732 | + | |
| 1733 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
29 | 29 | | |
30 | 30 | | |
31 | 31 | | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
32 | 36 | | |
33 | 37 | | |
34 | 38 | | |
| |||
0 commit comments