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

(node:784) [DEP0128] DeprecationWarning: Invalid 'main' field in 'D:\Dropbox\hexo\node_modules\jsftp\package.json' of './jsftp.js'. Please either fix that or report it to the module author #122

Closed
5 tasks done
punksinatra opened this issue Mar 8, 2022 · 3 comments
Labels
dependencies Pull requests that update a dependency file

Comments

@punksinatra
Copy link

punksinatra commented Mar 8, 2022

Check List

Please check followings before submitting a new issue.

Expected behavior

should be no error

Actual behavior

still works but shows deprecation error

How to reproduce?

any hexo command i.e. hexo server, hexo version, hexo clean, hexo generate

Is the problem still there under "Safe mode"?

no

Environment & Settings

npm -v
(node:6504) [LRU_CACHE_OPTION_maxAge] DeprecationWarning: The maxAge option is deprecated. Please use options.ttl instead.
(Use `node --trace-deprecation ...` to show where the warning was created)
(node:9844) [LRU_CACHE_OPTION_maxAge] DeprecationWarning: The maxAge option is deprecated. Please use options.ttl instead.
(Use `node --trace-deprecation ...` to show where the warning was created)
8.3.1

node -v
v16.14.0

hexo -v
(node:12684) [DEP0128] DeprecationWarning: Invalid 'main' field in 'D:\Dropbox\blog\node_modules\jsftp\package.json' of './jsftp.js'. Please either fix that or report it to the module author
(Use `node --trace-deprecation ...` to show where the warning was created)
hexo: 5.4.1
hexo-cli: 4.3.0
os: win32 10.0.19044
node: 16.14.0
v8: 9.4.146.24-node.20
uv: 1.43.0
zlib: 1.2.11
brotli: 1.0.9
ares: 1.18.1
modules: 93
nghttp2: 1.45.1
napi: 8
llhttp: 6.0.4
openssl: 1.1.1m+quic
cldr: 40.0
icu: 70.1
tz: 2021a3
unicode: 14.0
ngtcp2: 0.1.0-DEV
nghttp3: 0.1.0-DEV

Your site _config.yml (Optional)

Your theme _config.yml (Optional)

Hexo and Plugin version(npm ls --depth 0)

npm ls --depth 0
(node:1744) [LRU_CACHE_OPTION_maxAge] DeprecationWarning: The maxAge option is deprecated. Please use options.ttl instead.
(Use `node --trace-deprecation ...` to show where the warning was created)
(node:14888) [LRU_CACHE_OPTION_maxAge] DeprecationWarning: The maxAge option is deprecated. Please use options.ttl instead.
(Use `node --trace-deprecation ...` to show where the warning was created)
[email protected] D:\Dropbox\blog
+-- [email protected]
+-- [email protected]
+-- [email protected]
+-- [email protected]
+-- [email protected]
+-- [email protected]
+-- [email protected]
+-- [email protected]
+-- [email protected]
+-- [email protected]
+-- [email protected]
+-- [email protected]
+-- [email protected]
+-- [email protected]
+-- [email protected]
+-- [email protected]
`-- [email protected]

Your package.json package.json

{
  "name": "hexo-site",
  "version": "0.0.0",
  "private": true,
  "scripts": {
    "build": "hexo generate",
    "clean": "hexo clean",
    "deploy": "hexo deploy",
    "server": "hexo server"
  },
  "hexo": {
    "version": "5.4.1"
  },
  "dependencies": {
    "bulma-stylus": "^0.8.0",
    "hexo": "^5.0.0",
    "hexo-component-inferno": "^0.10.5",
    "hexo-deployer-ftpsync": "^0.1.1",
    "hexo-deployer-rsync": "^1.0.0",
    "hexo-generator-archive": "^1.0.0",
    "hexo-generator-category": "^1.0.0",
    "hexo-generator-index": "^2.0.0",
    "hexo-generator-tag": "^1.0.0",
    "hexo-renderer-ejs": "^1.0.0",
    "hexo-renderer-inferno": "^0.1.3",
    "hexo-renderer-marked": "^4.0.0",
    "hexo-renderer-stylus": "^2.0.0",
    "hexo-server": "^2.0.0",
    "hexo-theme-landscape": "^0.0.3",
    "inferno": "^7.3.3",
    "inferno-create-element": "^7.3.3"
  }
}

Others

Additional info

10:28:26.772 DEBUG Plugin loaded: hexo-component-inferno
10:28:26.773 DEBUG Plugin loaded: hexo-deployer-ftpsync
10:28:26.773 DEBUG Plugin loaded: hexo-deployer-rsync
10:28:26.773 DEBUG Plugin loaded: hexo-generator-archive
10:28:26.774 DEBUG Plugin loaded: hexo-generator-index
10:28:26.774 DEBUG Plugin loaded: hexo-generator-category
10:28:26.774 DEBUG Plugin loaded: hexo-generator-tag
10:28:26.774 DEBUG Plugin loaded: hexo-renderer-ejs
10:28:26.774 DEBUG Plugin loaded: hexo-renderer-inferno
(node:14684) [DEP0128] DeprecationWarning: Invalid 'main' field in 'D:\Dropbox\omglulz\node_modules\jsftp\package.json' of './jsftp.js'. Please either fix that or report it to the module author
(Use `node --trace-deprecation ...` to show where the warning was created)
10:28:27.033 DEBUG Plugin loaded: hexo-renderer-marked
10:28:27.034 DEBUG Plugin loaded: hexo-renderer-stylus
10:28:27.034 DEBUG Plugin loaded: hexo-server
@yoshinorin
Copy link
Member

Surely, this is the jsftp issue. And we can not do anything unless the jsftp will release a fixed version.

@yoshinorin yoshinorin added the dependencies Pull requests that update a dependency file label Mar 18, 2022
@yoshinorin yoshinorin transferred this issue from hexojs/hexo Apr 2, 2022
@mulianju
Copy link

同样遇到这个问题了,并且同步文件时,提交一半就报错终止了
Committing

events.js:377
throw er; // Unhandled 'error' event
^

Error: connect ECONNREFUSED 10.0.0.205:30360
at TCPConnectWrap.afterConnect [as oncomplete] (net.js:1159:16)
Emitted 'error' event on Socket instance at:
at emitErrorNT (internal/streams/destroy.js:106:8)
at emitErrorCloseNT (internal/streams/destroy.js:74:3)
at processTicksAndRejections (internal/process/task_queues.js:82:21) {
errno: -111,
code: 'ECONNREFUSED',
syscall: 'connect',
address: '10.0.0.205',
port: 30360
}

@stevenjoezhang
Copy link
Member

stevenjoezhang commented Mar 28, 2024

Both ftpsync and jsftp library on npm have not been updated for many years. I'm gonna to replace them and the problem should be resolved: #148 The installation method for the new version is: npm i [email protected]

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dependencies Pull requests that update a dependency file
Projects
None yet
Development

No branches or pull requests

4 participants