bio-guoda / preston

a biodiversity dataset tracker
MIT License
24 stars 1 forks source link

allow comma separates remotes option list #209

Closed jhpoelen closed 1 year ago

jhpoelen commented 1 year ago

previously, prior to migration to #136 , I was able to say:

preston history --remote https://linker.bio,https://deeplinker.bio 

but now, I am getting error message that includes:

Caused by: java.net.UnknownHostException: linker.bio,https
    at java.base/java.net.InetAddress$CachedAddresses.get(InetAddress.java:797)
    at java.base/java.net.InetAddress.getAllByName0(InetAddress.java:1519)
    at java.base/java.net.InetAddress.getAllByName(InetAddress.java:1378)
    at java.base/java.net.InetAddress.getAllByName(InetAddress.java:1306)
    at org.apache.http.impl.conn.SystemDefaultDnsResolver.resolve(SystemDefaultDnsResolver.java:45)
preston history --remote https://linker.bio --remote https://deeplinker.bio 

is not producing errors.

jhpoelen commented 1 year ago

after settings the "split" character to ",", the expected behavior was seen.

jhpoelen commented 1 year ago

e.g.,

$ preston history --remote https://linker.bio,https://deeeplinker.bio
[https://linker.bio/hash:...210ef59e06b640a3539cb5a] 100.0% of 78 bytes at 0.01 MB/s completed in < 1 minute
[https://linker.bio/hash:...fd61a815eee82cdffeab196] 100.0% of 78 bytes at 0.07 MB/s completed in < 1 minute
[https://linker.bio/hash:...be88791f79f6fc7c979d5a6] 100.0% of 78 bytes at 0.07 MB/s completed in < 1 minute
[https://linker.bio/hash:...658fe1943acc0a2023fab32] 100.0% of 78 bytes at 0.07 MB/s completed in < 1 minute
...