Skip to content

Prefix string too short #762

@au-phiware

Description

@au-phiware

Describe the bug

Attempting to build an uberjar with Selenium as a dependency raises the following exception:

clojure.lang.ExceptionInfo: Prefix string "9" too short: length must be at least 3

To Reproduce

build.boot:

(set-env!
  :resource-paths #{"."}
  :dependencies '[[org.clojure/clojure                            "1.10.1"]
                  [org.seleniumhq.selenium/selenium-support       "3.141.59"]
                  [org.seleniumhq.selenium/selenium-remote-driver "3.141.59"]])

(task-options!
  pom {:project 'selenium :version "0.1.0-SNAPSHOT"}
  aot {:namespace #{'selenium}}
  jar {:main 'selenium})

boot.properties:

BOOT_VERSION=2.8.3
BOOT_CLOJURE_VERSION=1.10.1
BOOT_CLOJURE_NAME=org.clojure/clojure

selenium.clj:

(ns selenium (:gen-class))
(defn -main [& args] ())

Run boot aot pom uber jar target

Expected behavior

Successful build and jar written to disk.

Actual behavior

Compiling 1/1 selenium...
Writing pom.xml and pom.properties...
Adding uberjar entries...
                              java.lang.Thread.run              Thread.java:  832
java.util.concurrent.ThreadPoolExecutor$Worker.run  ThreadPoolExecutor.java:  630
 java.util.concurrent.ThreadPoolExecutor.runWorker  ThreadPoolExecutor.java: 1130
               java.util.concurrent.FutureTask.run          FutureTask.java:  264
                                               ...
               clojure.core/binding-conveyor-fn/fn                 core.clj: 2030
                                 boot.core/boot/fn                 core.clj: 1031
                               boot.core/run-tasks                 core.clj: 1022
              boot.task.built-in/eval2944/fn/fn/fn             built_in.clj:  800
              boot.task.built-in/eval2662/fn/fn/fn             built_in.clj:  576
              boot.task.built-in/eval2828/fn/fn/fn             built_in.clj:  753
                               clojure.core/reduce                 core.clj: 6828
                       clojure.core.protocols/fn/G            protocols.clj:   13
                         clojure.core.protocols/fn            protocols.clj:   75
                 clojure.core.protocols/seq-reduce            protocols.clj:   31
                       clojure.core.protocols/fn/G            protocols.clj:   19
                         clojure.core.protocols/fn            protocols.clj:  168
            boot.task.built-in/eval2828/fn/reducer             built_in.clj:  733
                                               ...
                     boot.core/add-cached-resource                 core.clj:  622
                     boot.core/add-cached-resource                 core.clj:  632
                 boot.tmpdir.TmpFileSet/add-cached               tmpdir.clj:  308
                          boot.tmpdir/merge-trees!               tmpdir.clj:  187
                        boot.tmpdir/apply-mergers!               tmpdir.clj:  148
                       java.io.File.createTempFile                File.java: 2083
java.lang.IllegalArgumentException: Prefix string "9" too short: length must be at least 3
        clojure.lang.ExceptionInfo: Prefix string "9" too short: length must be at least 3
    line: 15

Desktop:

I used a container to run the above i.e.

docker run -it --rm -v "$PWD":/usr/src/app -w /usr/src/app clojure:openjdk-15-boot-2.8.3-alpine boot aot pom uber jar target

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions