Giter VIP home page Giter VIP logo

Comments (3)

dduong1603 avatar dduong1603 commented on June 2, 2024 1

Hi, sorry I wasn't specfic enough. sling conns test works fine, but the command that failed for me was sling run

This works fine:
DEBUG=TRUE sling conns test TEST_SFTP

4:06PM DBG opened "sqlite" connection (conn-sqlite-BqY)
4:06PM DBG adding default private key (<redacted>/.ssh/id_rsa) as auth method for SFTP
4:06PM DBG file discover inputs: {"column_level":false,"pattern":"","recursive":false,"url":"sftp://demo:[email protected]:2222/"}
4:06PM DBG unfiltered nodes returned: 2
4:06PM DBG ["/upload/","/download/"]
4:06PM INF success!

But when I run:

sling run \
   --src-conn WAREHOUSE \
   --src-stream 'analytics.dim__dates' \
   --tgt-conn TEST_SFTP \
   --tgt-object '{stream_schema}/{stream_table}_{YYYY}_{MM}_{DD}.csv' \
   --tgt-options '{"mode": "full-refresh", "format":"csv"}' -d

I got (this run happened on my Mac, but same thing with linux)

2024-04-09 16:09:35 DBG adding default private key (<redacted>/.ssh/id_rsa) as auth method for SFTP
2024-04-09 16:09:36 DBG Sling version: 1.2.3 (darwin arm64)
2024-04-09 16:09:36 DBG type is db-file
2024-04-09 16:09:36 DBG using source options: {"empty_as_null":true,"null_if":"NULL","datetime_format":"AUTO","max_decimals":-1}
2024-04-09 16:09:36 DBG using target options: {"header":true,"compression":"AUTO","concurrency":7,"datetime_format":"auto","delimiter":",","format":"csv","max_decimals":-1,"use_bulk":true,"add_new_columns":true,"column_casing":"source"}
2024-04-09 16:09:36 INF connecting to source database (postgres)
2024-04-09 16:09:36 DBG opened "postgres" connection (conn-postgres-bq4)
2024-04-09 16:09:37 INF reading from source database
2024-04-09 16:09:37 DBG select * from "analytics"."dim__dates"
2024-04-09 16:09:37 INF writing to target file system (sftp)
2024-04-09 16:09:37 DBG adding default private key (<redacted>/.ssh/id_rsa) as auth method for SFTP
2024-04-09 16:09:41 DBG closed "postgres" connection (conn-postgres-bq4)
2024-04-09 16:09:41 INF execution failed
fatal:
~ failure running task (see docs @ https://docs.slingdata.io/sling-cli)
--- task_run.go:101 func1 ---
--- task_run.go:300 runDbToFile ---
~ execution failed
--- task_run_write.go:39 WriteToFile ---
~ Could not WriteToFile
--- fs.go:147 NewFileSysClientFromURLContext ---
~ Could not obtain client for: sftp
--- fs.go:120 NewFileSysClientContext ---
~ Error initiating File Sys Client
--- fs_sftp.go:33 Init ---
~ unable to connect to ssh server
--- fs_sftp.go:107 Connect ---
~ unable to connect to ssh server demo.wftpserver.com:22
--- ssh.go:107 Connect ---
ssh: handshake failed: ssh: unable to authenticate, attempted methods [none publickey password], no supported methods remain

from sling-cli.

flarco avatar flarco commented on June 2, 2024

Hi, I am unable to reproduce. I actually tried your URL, and it works fine with 1.2.2.
I changed the port to 2223, and it then correctly failed.
Can you check that there are no conflicts in your env? Meaning, an env variable is not overriding your env.yaml config.
Also, run with DEBUG=TRUE, like DEBUG=TRUE sling conns test sftp to see more details.

from sling-cli.

flarco avatar flarco commented on June 2, 2024

Was able to reproduce, thanks for reporting.
Fixed here: 3ef5fd6 in v1.2.4. Feel free to build & test.
Closing.

from sling-cli.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.