Skip to content

Teloxide docs fail to build on nightly #139116

Closed

Description

@shdwchn10

While releasing teloxide 0.14.0 we encountered docs build failure on docs.rs: https://docs.rs/crate/teloxide/0.14.0/builds/1924379 (rust-lang/docs.rs#2780).

Bisecting this issue led to these findings:

  • teloxide docs build fine on nightly-2025-02-16 (rust version 1.86.0-nightly (9cd60bd 2025-02-15))
  • starting with nightly-2025-02-17 (rust version 1.87.0-nightly (5bc6231 2025-02-16) docs build fails with:
    error: unresolved link to `adaptors::AutoSend`
      --> crates/teloxide-core/src/lib.rs:51:19
       |
    51 | //! [`AutoSend`]: adaptors::AutoSend
       |                   ^^^^^^^^^^^^^^^^^^ no item named `AutoSend` in module `adaptors`
       |
    note: the lint level is defined here
      --> crates/teloxide-core/src/lib.rs:80:49
       |
    80 | #![cfg_attr(all(feature = "full", docsrs), deny(rustdoc::broken_intra_doc_links))]
       |                                                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    
    error: could not document `teloxide-core`
    
  • starting with nightly-2025-03-12 (rust version 1.87.0-nightly (6650252 2025-03-11)) docs build fails with: https://pastebin.com/TV4JcCD4
  • issue persists on nightly-2025-03-29

Activity

  1. added
    needs-triageThis issue may need triage. Remove when done. See docs forge.rust-lang.org/release/issue-triaging
    on Mar 29, 2025
  2. added
    T-rustdocRelevant to the rustdoc team, which will review and decide on the PR/issue.
    and removed
    needs-triageThis issue may need triage. Remove when done. See docs forge.rust-lang.org/release/issue-triaging
    on Mar 29, 2025
  3. added
    I-prioritizeIssue needs a team member to assess the impact. Will be replaced by P-{low,medium,high,critical}
    on Mar 29, 2025
  4. Noratrieb commented on Mar 29, 2025

    @Noratrieb
    Member

    Thank you for the report! It would be useful to more precisely bisect the regression using cargo-bisect-rustc to make it easier to figure out where exactly it regressed and ping the relevant people.
    @rustbot label E-needs-bisection

  5. added
    E-needs-bisectionCall for participation: This issue needs bisection: https://github.com/rust-lang/cargo-bisect-rustc
    on Mar 29, 2025
  6. shdwchn10 commented on Mar 29, 2025

    @shdwchn10
    Author

    test.sh: (cargo docs isn't a typo, but alias with correct feature flags enabled)

    #!/bin/sh
    
    OUTPUT=`cargo docs 2>&1`
    COUNT=`echo "$OUTPUT" | grep -c "mismatched types"`
    test $COUNT -eq 0

    cargo bisect-rustc --start=2025-03-11 --end=2025-03-12 --script ./test.sh:

    searched nightlies: from nightly-2025-03-11 to nightly-2025-03-12
    regressed nightly: nightly-2025-03-12
    searched commit range: 9fb94b3...6650252
    regressed commit: 6650252

    bisected with cargo-bisect-rustc v0.6.9

    Host triple: x86_64-unknown-linux-gnu
    Reproduce with:

    cargo bisect-rustc --start=2025-03-11 --end=2025-03-12 --script ./test.sh 

    cargo bisect-rustc --start=2025-02-16 --end=2025-02-17 -- docs (probably not relevant, since the first error seems to have been fixed):

    searched nightlies: from nightly-2025-02-16 to nightly-2025-02-17
    regressed nightly: nightly-2025-02-17
    searched commit range: 9cd60bd...5bc6231
    regressed commit: 23032f3

    bisected with cargo-bisect-rustc v0.6.9

    Host triple: x86_64-unknown-linux-gnu
    Reproduce with:

    cargo bisect-rustc --start=2025-02-16 --end=2025-02-17 -- docs 
  7. Noratrieb commented on Mar 29, 2025

    @Noratrieb
    Member
  8. notriddle commented on Mar 29, 2025

    @notriddle
    Contributor

    The adaptors module doesn't seem to have an AutoSend item in it (no re-export of the type itself, and no wildcard exports).

  9. shdwchn10 commented on Mar 29, 2025

    @shdwchn10
    Author

    The adaptors module doesn't seem to have an AutoSend item in it (no re-export of the type itself, and no wildcard exports).

    Thanks! AutoSend removal from docs fixes first error, but second is still here.
    cargo bisect-rustc --start=2025-03-11 --end=2025-03-12 -- docs:

    searched nightlies: from nightly-2025-03-11 to nightly-2025-03-12
    regressed nightly: nightly-2025-03-12
    searched commit range: 9fb94b3...6650252
    regressed commit: 6650252

    bisected with cargo-bisect-rustc v0.6.9

    Host triple: x86_64-unknown-linux-gnu
    Reproduce with:

    cargo bisect-rustc --start=2025-03-11 --end=2025-03-12 -- docs 
  10. workingjubilee commented on Mar 30, 2025

    @workingjubilee
    Member
  11. fmease commented on Mar 30, 2025

    @fmease
    Member

    but second is still here.

    not a bug. You now need to slap #[define_opaque(Opaque)] onto fns etc. defining the opaque type Opaque

  12. shdwchn10 commented on Mar 30, 2025

    @shdwchn10
    Author

    but second is still here.

    not a bug. You now need to slap #[define_opaque(Opaque)] onto fns etc. defining the opaque type Opaque

    Thank you, now docs compile without issues!

  13. removed
    I-prioritizeIssue needs a team member to assess the impact. Will be replaced by P-{low,medium,high,critical}
    on Mar 31, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    C-bugCategory: This is a bug.E-needs-bisectionCall for participation: This issue needs bisection: https://github.com/rust-lang/cargo-bisect-rustcT-rustdocRelevant to the rustdoc team, which will review and decide on the PR/issue.regression-from-stable-to-nightlyPerformance or correctness regression from stable to nightly.

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions