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

proc-macro2 is hard pinned in arrow-flight #1101

Closed
alamb opened this issue Dec 28, 2021 · 1 comment · Fixed by #1102
Closed

proc-macro2 is hard pinned in arrow-flight #1101

alamb opened this issue Dec 28, 2021 · 1 comment · Fixed by #1102
Labels
arrow-flight Changes to the arrow-flight crate bug

Comments

@alamb
Copy link
Contributor

alamb commented Dec 28, 2021

Describe the bug

Pinning the version of proc-macro used in arrow-flight prevents updates of the proc-macro crate.

In the meantime, an indirect dependency (quote) released a version that was not strictly backwards compatible and didn't work with this version of proc-macro2. The issue was subsequently fixed in newer versions of the quote but the old version is still on crates.io, preventing arrow from compiling. dtolnay/quote#204 requests to author to yank it.

Trying to publish arrow-flight results in the following error:

   Compiling prost-build v0.8.0
error[E0599]: no function or associated item named `from_str_unchecked` found for struct `proc_macro2::Literal` in the current scope
   --> /Users/alamb/.cargo/registry/src/github.com-1ecc6299db9ec823/quote-1.0.11/src/runtime.rs:301:41
    |
301 |         let literal = unsafe { Literal::from_str_unchecked(repr) };
    |                                         ^^^^^^^^^^^^^^^^^^ function or associated item not found in `proc_macro2::Literal`

error[E0599]: no function or associated item named `from_str_unchecked` found for struct `proc_macro2::Literal` in the current scope
   --> /Users/alamb/.cargo/registry/src/github.com-1ecc6299db9ec823/quote-1.0.11/src/runtime.rs:310:45
    |
310 |         let mut literal = unsafe { Literal::from_str_unchecked(repr) };
    |                                             ^^^^^^^^^^^^^^^^^^ function or associated item not found in `proc_macro2::Literal`

For more information about this error, try `rustc --explain E0599`.
error: could not compile `quote` due to 2 previous errors
warning: build failed, waiting for other jobs to finish...
error: failed to verify package tarball

Caused by:
  build failed

It also causes errors in downstream dependencies such as Datafusion, such as apache/datafusion#1498 (when a bugfix to a dependent crate requires upgrading to a newer version of proc-macro2

To Reproduce
See apache/datafusion#1498

Expected behavior
Be as flexible with the versions allowed as possible

Additional context
Add any other context about the problem here.

@alamb alamb added the bug label Dec 28, 2021
@alamb alamb changed the title proc-macro is pinned in arrow-flight proc-macro2 is hard pinned in arrow-flight Dec 28, 2021
@alamb alamb added the arrow-flight Changes to the arrow-flight crate label Dec 28, 2021
@alamb
Copy link
Contributor Author

alamb commented Dec 29, 2021

Filed request to yank broken crates.io release: dtolnay/quote#204

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
arrow-flight Changes to the arrow-flight crate bug
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant