lein doesn't print all tasks in Windows XP #592

Closed
borkdude opened this Issue May 21, 2012 · 10 comments

Comments

5 participants
@borkdude
Contributor

borkdude commented May 21, 2012

@michaelklishin

This comment has been minimized.

Show comment
Hide comment
@michaelklishin

michaelklishin May 21, 2012

Collaborator

Do you have .lein/profile.clj? It may be because some plugin fails to load and it terminates task listing operation

Collaborator

michaelklishin commented May 21, 2012

Do you have .lein/profile.clj? It may be because some plugin fails to load and it terminates task listing operation

@borkdude

This comment has been minimized.

Show comment
Hide comment
@borkdude

borkdude May 21, 2012

Contributor

I assume you mean profiles.clj (plural), but with or without doesn't make a difference.

Contributor

borkdude commented May 21, 2012

I assume you mean profiles.clj (plural), but with or without doesn't make a difference.

@kumarshantanu

This comment has been minimized.

Show comment
Hide comment
@kumarshantanu

kumarshantanu May 21, 2012

Collaborator

I can reproduce this bug. I have a 32-bit XP on JDK 1.7.0_04 with no %USERPROFILE%/.lein/profiles.clj file created.

Collaborator

kumarshantanu commented May 21, 2012

I can reproduce this bug. I have a 32-bit XP on JDK 1.7.0_04 with no %USERPROFILE%/.lein/profiles.clj file created.

@technomancy

This comment has been minimized.

Show comment
Hide comment
@technomancy

technomancy May 21, 2012

Owner

Is XP the only Windows version where this occurs?

Owner

technomancy commented May 21, 2012

Is XP the only Windows version where this occurs?

@ath

This comment has been minimized.

Show comment
Hide comment
@ath

ath May 29, 2012

Contributor

A workmate also sees a very short list under Windows XP. Could it have to do with spaces in the path C:\Documents and Settings\…?
Under Vista and Win7 MS changed this to C:\Users\….

Contributor

ath commented May 29, 2012

A workmate also sees a very short list under Windows XP. Could it have to do with spaces in the path C:\Documents and Settings\…?
Under Vista and Win7 MS changed this to C:\Users\….

@borkdude

This comment has been minimized.

Show comment
Hide comment
@borkdude

borkdude Jun 2, 2012

Contributor

Discovered the following:

  • this only occurs on windows XP, not on Windows 7
  • When running from a leiningen checkout lein prints all its tasks in XP.
  • When not running from a checkout (inside or outside project) lein prints only the plugins as tasks in XP.

Any clues on where to look next?

Contributor

borkdude commented Jun 2, 2012

Discovered the following:

  • this only occurs on windows XP, not on Windows 7
  • When running from a leiningen checkout lein prints all its tasks in XP.
  • When not running from a checkout (inside or outside project) lein prints only the plugins as tasks in XP.

Any clues on where to look next?

@technomancy

This comment has been minimized.

Show comment
Hide comment
@technomancy

technomancy Jun 2, 2012

Owner

It sounds like a problem with the bultitude library: https://github.com/Raynes/bultitude

The help task uses bultitude's namespaces-on-classpath function.

Owner

technomancy commented Jun 2, 2012

It sounds like a problem with the bultitude library: https://github.com/Raynes/bultitude

The help task uses bultitude's namespaces-on-classpath function.

@borkdude

This comment has been minimized.

Show comment
Hide comment
@borkdude

borkdude Jun 6, 2012

Contributor

I included these lines in leiningen/help.clj to debug a little more and build a standalone jar which I tried on XP:

 (println "-------")
 (println "classpath-files" (b/classpath-files))
 (println "-------")
 (println "namespaces-on-classpath without prefix" (b/namespaces-on-classpath :prefix ""))
 (println "-------")
 (println "namespaces-on-classpath" (b/namespaces-on-classpath :prefix "leiningen"))

The output can be seen here:
https://gist.github.com/2885180

It seems that only paths that are not encoded with %20 for spaces get their namespaces recognized. For some reason the default java libraries and the leiningen standalone are encoded, but plugins (lein newnew) or dependencies (clojure) are not.

Maybe @Raynes know something?

PS: The reason why the tasks on Windows 7 -are- printed is probably that the self-install directory doesn't contain any spaces there (output on Windows 7: https://gist.github.com/2885264).

PPS: FWIW, I can manually get at the leiningen self-install "URL" by doing this in a REPL in XP:

https://gist.github.com/2885423

Contributor

borkdude commented Jun 6, 2012

I included these lines in leiningen/help.clj to debug a little more and build a standalone jar which I tried on XP:

 (println "-------")
 (println "classpath-files" (b/classpath-files))
 (println "-------")
 (println "namespaces-on-classpath without prefix" (b/namespaces-on-classpath :prefix ""))
 (println "-------")
 (println "namespaces-on-classpath" (b/namespaces-on-classpath :prefix "leiningen"))

The output can be seen here:
https://gist.github.com/2885180

It seems that only paths that are not encoded with %20 for spaces get their namespaces recognized. For some reason the default java libraries and the leiningen standalone are encoded, but plugins (lein newnew) or dependencies (clojure) are not.

Maybe @Raynes know something?

PS: The reason why the tasks on Windows 7 -are- printed is probably that the self-install directory doesn't contain any spaces there (output on Windows 7: https://gist.github.com/2885264).

PPS: FWIW, I can manually get at the leiningen self-install "URL" by doing this in a REPL in XP:

https://gist.github.com/2885423

@borkdude

This comment has been minimized.

Show comment
Hide comment
@borkdude

borkdude Jun 7, 2012

Contributor

This fix in bultitude seems to solve it: Raynes/bultitude#9

Contributor

borkdude commented Jun 7, 2012

This fix in bultitude seems to solve it: Raynes/bultitude#9

@borkdude

This comment has been minimized.

Show comment
Hide comment
@borkdude

borkdude Jun 9, 2012

Contributor

Bumping to bultitude version 0.1.6 in project.clj should fix this issue.

Contributor

borkdude commented Jun 9, 2012

Bumping to bultitude version 0.1.6 in project.clj should fix this issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment