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

Scaladoc spurious error messages: error while loading package, class file ... contains wrong package package #5593

Closed
scabug opened this issue Mar 21, 2012 · 3 comments
Assignees
Milestone

Comments

@scabug
Copy link

@scabug scabug commented Mar 21, 2012

Clone scala/scala, compile it and run scaladoc in the repository root dir:

$ git clone  git://github.com/scala/scala.git scala
$ cd scala
$ ant
[...]
$ echo "case class A" > test.scala
$ build/pack/bin/scaladoc test.scala
Picked up _JAVA_OPTIONS: -Xms1g -Xmx4g -Xss128m -XX:+CMSClassUnloadingEnabled -XX:MaxPermSize=512M -XX:ReservedCodeCacheSize=256m -XX:+UseParallelGC -XX:PermSize=256m
warning: there were 1 deprecation warnings; re-run with -deprecation for details
error: error while loading package, class file './build/locker/classes/compiler/scala/tools/cmd/package.class' contains wrong package package
error: error while loading package, class file './build/locker/classes/compiler/scala/tools/util/color/package.class' contains wrong package package
error: error while loading package, class file './build/locker/classes/compiler/scala/tools/reflect/package.class' contains wrong package package
error: error while loading package, class file './build/locker/classes/compiler/scala/tools/nsc/package.class' contains wrong package package
error: error while loading package, class file './build/locker/classes/compiler/scala/tools/nsc/symtab/package.class' contains wrong package package
error: error while loading package, class file './build/locker/classes/compiler/scala/tools/nsc/symtab/classfile/package.class' contains wrong package package
error: error while loading package, class file './build/locker/classes/compiler/scala/tools/nsc/interpreter/package.class' contains wrong package package
error: error while loading package, class file './build/locker/classes/compiler/scala/tools/nsc/interpreter/session/package.class' contains wrong package package
error: error while loading package, class file './build/locker/classes/compiler/scala/tools/nsc/util/package.class' contains wrong package package
error: error while loading package, class file './build/locker/classes/compiler/scala/tools/nsc/io/package.class' contains wrong package package
error: error while loading package, class file './build/locker/classes/library/scala/package.class' contains wrong package package
error: error while loading package, class file './build/locker/classes/library/scala/annotation/target/package.class' contains wrong package package
error: error while loading package, class file './build/locker/classes/library/scala/annotation/meta/package.class' contains wrong package package
error: error while loading package, class file './build/locker/classes/library/scala/sys/package.class' contains wrong package package
error: error while loading package, class file './build/locker/classes/library/scala/sys/process/package.class' contains wrong package package
error: error while loading package, class file './build/locker/classes/library/scala/collection/package.class' contains wrong package package
error: error while loading package, class file './build/locker/classes/library/scala/collection/immutable/package.class' contains wrong package package
error: error while loading package, class file './build/locker/classes/library/scala/collection/parallel/package.class' contains wrong package package
error: error while loading package, class file './build/locker/classes/library/scala/collection/parallel/immutable/package.class' contains wrong package package
error: error while loading package, class file './build/locker/classes/library/scala/collection/parallel/mutable/package.class' contains wrong package package
error: error while loading package, class file './build/locker/classes/library/scala/collection/generic/package.class' contains wrong package package
error: error while loading package, class file './build/locker/classes/library/scala/math/package.class' contains wrong package package
error: error while loading package, class file './build/locker/classes/library/scala/runtime/package.class' contains wrong package package
error: error while loading package, class file './build/locker/classes/library/scala/reflect/package.class' contains wrong package package
error: error while loading package, class file './build/locker/classes/library/scala/xml/package.class' contains wrong package package
error: error while loading package, class file './build/locker/classes/library/scala/xml/pull/package.class' contains wrong package package
error: error while loading package, class file './build/locker/classes/library/scala/concurrent/package.class' contains wrong package package
error: error while loading package, class file './build/quick/classes/partest/scala/tools/partest/package.class' contains wrong package package
error: error while loading package, class file './build/quick/classes/compiler/scala/tools/cmd/package.class' contains wrong package package
error: error while loading package, class file './build/quick/classes/compiler/scala/tools/util/color/package.class' contains wrong package package
error: error while loading package, class file './build/quick/classes/compiler/scala/tools/reflect/package.class' contains wrong package package
error: error while loading package, class file './build/quick/classes/compiler/scala/tools/nsc/package.class' contains wrong package package
error: error while loading package, class file './build/quick/classes/compiler/scala/tools/nsc/symtab/package.class' contains wrong package package
error: error while loading package, class file './build/quick/classes/compiler/scala/tools/nsc/symtab/classfile/package.class' contains wrong package package
error: error while loading package, class file './build/quick/classes/compiler/scala/tools/nsc/interpreter/package.class' contains wrong package package
error: error while loading package, class file './build/quick/classes/compiler/scala/tools/nsc/interpreter/session/package.class' contains wrong package package
error: error while loading package, class file './build/quick/classes/compiler/scala/tools/nsc/util/package.class' contains wrong package package
error: error while loading package, class file './build/quick/classes/compiler/scala/tools/nsc/io/package.class' contains wrong package package
error: error while loading package, class file './build/quick/classes/library/scala/package.class' contains wrong package package
error: error while loading package, class file './build/quick/classes/library/scala/swing/package.class' contains wrong package package
error: error while loading package, class file './build/quick/classes/library/scala/annotation/target/package.class' contains wrong package package
error: error while loading package, class file './build/quick/classes/library/scala/annotation/meta/package.class' contains wrong package package
error: error while loading package, class file './build/quick/classes/library/scala/dbc/package.class' contains wrong package package
error: error while loading package, class file './build/quick/classes/library/scala/sys/package.class' contains wrong package package
error: error while loading package, class file './build/quick/classes/library/scala/sys/process/package.class' contains wrong package package
error: error while loading package, class file './build/quick/classes/library/scala/collection/package.class' contains wrong package package
error: error while loading package, class file './build/quick/classes/library/scala/collection/immutable/package.class' contains wrong package package
error: error while loading package, class file './build/quick/classes/library/scala/collection/parallel/package.class' contains wrong package package
error: error while loading package, class file './build/quick/classes/library/scala/collection/parallel/immutable/package.class' contains wrong package package
error: error while loading package, class file './build/quick/classes/library/scala/collection/parallel/mutable/package.class' contains wrong package package
error: error while loading package, class file './build/quick/classes/library/scala/collection/generic/package.class' contains wrong package package
error: error while loading package, class file './build/quick/classes/library/scala/math/package.class' contains wrong package package
error: error while loading package, class file './build/quick/classes/library/scala/util/continuations/package.class' contains wrong package package
error: error while loading package, class file './build/quick/classes/library/scala/runtime/package.class' contains wrong package package
error: error while loading package, class file './build/quick/classes/library/scala/reflect/package.class' contains wrong package package
error: error while loading package, class file './build/quick/classes/library/scala/xml/package.class' contains wrong package package
error: error while loading package, class file './build/quick/classes/library/scala/xml/pull/package.class' contains wrong package package
error: error while loading package, class file './build/quick/classes/library/scala/actors/package.class' contains wrong package package
error: error while loading package, class file './build/quick/classes/library/scala/concurrent/package.class' contains wrong package package
model contains 2 documentable templates
one warning found
59 errors found

Always appears if you run in the cloned repo root (/scala) or in the build dir (/scala/build).

@scabug

This comment has been minimized.

Copy link
Author

@scabug scabug commented Mar 21, 2012

@scabug

This comment has been minimized.

Copy link
Author

@scabug scabug commented Mar 22, 2012

@VladUreche said:
The root cause is that if no classpath is given, scaladoc/scalac add "." to the classpath by default. A workaround until I find a proper fix is running scaladoc with -classpath "":

scaladoc -classpath "" ...
@scabug

This comment has been minimized.

Copy link
Author

@scabug scabug commented Mar 26, 2012

@VladUreche said:
Fixed in 72c104b8b7.

@scabug scabug closed this Mar 26, 2012
@scabug scabug added this to the 2.10.0-M2 milestone Apr 7, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
2 participants
You can’t perform that action at this time.