The current implementation of derive procedural macros refers to types and traits from the library, assuming it is in scope. This leads to "cannot find trait ... in this scope" and alike when it is not the case.
The code now imports types and traits needed because of this issue separately and they are marked with TODO: Remove these imports once hygiene of procedural macros is fixed. comment (for instance here).
The current implementation of derive procedural macros refers to types and traits from the library, assuming it is in scope. This leads to "cannot find trait
...
in this scope" and alike when it is not the case.