位置: IT常识 - 正文

解决npm ERR! Cannot read properties of null (reading ‘pickAlgorithm‘)(解决口苦最快的方法)

编辑:rootadmin
解决npm ERR! Cannot read properties of null (reading ‘pickAlgorithm‘) 文章目录1. 复现问题2. 分析问题3. 解决问题

推荐整理分享解决npm ERR! Cannot read properties of null (reading ‘pickAlgorithm‘)(解决口苦最快的方法),希望有所帮助,仅作参考,欢迎阅读内容。

文章相关热门搜索词:解决的英文,解决肚子胀气最快方法,解决的英文,解决打呼噜只需一杯水,解决掉发的有效方法,解决烧心最快方法,解决烧心最快方法,解决口苦最快的方法,内容如对您有帮助,希望把文章链接给更多的朋友!

1. 复现问题

今天准备克隆Redis桌面(GUI)管理客户端,故按照官方文档给出的指令运行时,如下图所示:

但在执行指令npm install --platform=win32却报出如下图错误:

PS D:\Software\RedisDesktopManager\AnotherRedisDesktopManager> npm install --platform=win32npm WARN config global `--global`, `--local` are deprecated. Use `--location=global` instead.npm WARN deprecated chokidar@2.1.8: Chokidar 2 does not receive security updates since 2019. Upgrade to chokidar 3 with 15x fewer dependenciesnpm WARN deprecated chokidar@2.1.8: Chokidar 2 does not receive security updates since 2019. Upgrade to chokidar 3 with 15x fewer dependenciesnpm WARN deprecated stable@0.1.8: Modern JS already guarantees Array#sort() is a stable sort, so this library is deprecated. See the compatibility table on MDN: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/sort#browser_compatibilitynpm WARN deprecated electron-osx-sign@0.5.0: Please use @electron/osx-sign moving forward. Be aware the API is slightly differentnpm WARN deprecated querystring@0.2.0: The querystring API is considered Legacy. new code should use the URLSearchParams API instead.npm WARN deprecated uuid@3.4.0: Please upgrade to version 7 or higher. Older versions may use Math.random() in certain circumstances, which is known to be problematic. See https://v8.dev/blog/math-random for details.npm WARN deprecated debug@4.1.1: Debug versions >=3.2.0 <3.2.7 || >=4 <4.3.1 have a low-severity ReDos regression when used in a Node.js environment. It is recommended you upgrade to 3.2.7 or 4.3.1. (https://github.com/visionmedia/debug/issues/797)npm WARN deprecated browserslist@1.7.7: Browserslist 2 could fail on reading Browserslist >3.0 config used in other tools.npm WARN deprecated browserslist@1.7.7: Browserslist 2 could fail on reading Browserslist >3.0 config used in other tools.npm WARN deprecated browserslist@1.7.7: Browserslist 2 could fail on reading Browserslist >3.0 config used in other tools.npm WARN deprecated svgo@0.7.2: This SVGO version is no longer supported. Upgrade to v2.x.x.npm WARN deprecated debug@4.1.1: Debug versions >=3.2.0 <3.2.7 || >=4 <4.3.1 have a low-severity ReDos regression when used in a Node.js environment. It is recommended you upgrade to 3.2.7 or 4.3.1. (https://github.com/visionmedia/debug/issues/797)npm WARN deprecated svgo@1.3.2: This SVGO version is no longer supported. Upgrade to v2.x.x.npm ERR! Cannot read properties of null (reading 'pickAlgorithm')npm ERR! A complete log of this run can be found in:npm ERR! C:\Users\zxy\AppData\Local\npm-cache\_logs\2022-11-04T07_24_57_963Z-debug-0.log

注意看上述错误的倒数第3行,即Cannot read properties of null (reading 'pickAlgorithm')

2. 分析问题

Cannot read properties of null (reading 'pickAlgorithm')翻译成中文就是无法读取 null 的属性(读取 'pickAlgorithm')

但是,我在运行指令npm install --platform=win32时,并没有涉及pickAlgorithm字段呀,于是,通过查找资料可得如下解决方案:

方案1解决npm ERR! Cannot read properties of null (reading ‘pickAlgorithm‘)(解决口苦最快的方法)

重新安装node解决,这并没有解决我的问题,舍弃。

方案2

删了node models重新下。

或者直接下载CNPM(淘宝镜像)进行安装CNPM安装办法:

npm install -g cnpm -registry=https://registry.npm.taobao.org

查看cnpm是否真安装成功:

cnpm -v

这种方式也没有解决我的问题。

于是,使用如下第3种方案解决了我的问题。

3. 解决问题在终端输入指令npm cache clear --force,如下所示:PS D:\Software\RedisDesktopManager\AnotherRedisDesktopManager> npm cache clear --forcenpm WARN config global `--global`, `--local` are deprecated. Use `--location=global` instead.npm WARN using --force Recommended protections disabled.再次执行指令npm install --platform=win32,即可完成安装,如下所示:PS D:\Software\RedisDesktopManager\AnotherRedisDesktopManager> npm install --platform=win32npm WARN config global `--global`, `--local` are deprecated. Use `--location=global` instead.npm WARN deprecated uuid@3.4.0: Please upgrade to version 7 or higher. Older versions may use Math.random() in certain circumstances, which is known to be problematic. See https://v8.dev/blog/math-random for details.npm WARN deprecated browserslist@2.11.3: Browserslist 2 could fail on reading Browserslist >3.0 config used in other tools.npm WARN deprecated debug@4.1.1: Debug versions >=3.2.0 <3.2.7 || >=4 <4.3.1 have a low-severity ReDos regression when used in a Node.js environment. It is recommended you upgrade to 3.2.7 or 4.3.1. (https://github.com/visionmedia/debug/issues/797)npm WARN deprecated uuid@3.3.2: Please upgrade to version 7 or higher. Older versions may use Math.random() in certain circumstances, which is known to be problematic. See https://v8.dev/blog/math-random for details.npm WARN deprecated electron-osx-sign@0.5.0: Please use @electron/osx-sign moving forward. Be aware the API is slightly differentnpm WARN deprecated svgo@0.7.2: This SVGO version is no longer supported. Upgrade to v2.x.x.npm WARN deprecated browserslist@1.7.7: Browserslist 2 could fail on reading Browserslist >3.0 config used in other tools.npm WARN deprecated chokidar@2.1.8: Chokidar 2 does not receive security updates since 2019. Upgrade to chokidar 3 with 15x fewer dependenciesnpm WARN deprecated browserslist@1.7.7: Browserslist 2 could fail on reading Browserslist >3.0 config used in other tools.npm WARN deprecated browserslist@1.7.7: Browserslist 2 could fail on reading Browserslist >3.0 config used in other tools.npm WARN deprecated svgo@1.3.2: This SVGO version is no longer supported. Upgrade to v2.x.x.added 706 packages, and changed 55 packages in 2m93 packages are looking for funding run `npm fund` for details输入npm start启动程序,如下图所示:

此时,报出另外一个错误,即 Cannot find module 'D:\Software\RedisDesktopManager\AnotherRedisDesktopManager\node_modules\fs.realpath\index.js'. Please verify that the package.json has a valid "main" entry。

即在当前目录下找不到index.js文件,于是,我们去当前目录下区创建该文件即可:

创建index.js文件后,再次执行npm start指令,即可启动程序了,如下所示:

本文链接地址:https://www.jiuchutong.com/zhishi/269199.html 转载请保留说明!

上一篇:WPS广告怎么关闭 ?教你轻松去掉WPS广告方法(wps的广告怎么关掉)

下一篇:苹果14promax电池多少毫安(苹果14promax电池掉电很快)

  • 提高网店转化率需四招(提高网店转化率及客服服务水平的计划书)

    提高网店转化率需四招(提高网店转化率及客服服务水平的计划书)

  • 苹果实况拍照怎么用(苹果实况拍照怎么关声音)

    苹果实况拍照怎么用(苹果实况拍照怎么关声音)

  • 抖音评论区带图片怎么发的(抖音评论区的图片是怎么搞上去的)

    抖音评论区带图片怎么发的(抖音评论区的图片是怎么搞上去的)

  • 小米10青春版边框是什么材质(小米10青春版边框材质)

    小米10青春版边框是什么材质(小米10青春版边框材质)

  • 荣耀20s在哪里开启分屏功能(荣耀20s在哪里开小窗口)

    荣耀20s在哪里开启分屏功能(荣耀20s在哪里开小窗口)

  • 微信怎么不发信息知道对方删没有(微信怎么不发信息看好友是否把你删除)

    微信怎么不发信息知道对方删没有(微信怎么不发信息看好友是否把你删除)

  • 美图秀秀可以录制多长时间的视频(美图秀秀可以录音吗)

    美图秀秀可以录制多长时间的视频(美图秀秀可以录音吗)

  • 荣耀手机录屏在哪里(荣耀手机录屏在软件上图像而在其他软件上有图像)

    荣耀手机录屏在哪里(荣耀手机录屏在软件上图像而在其他软件上有图像)

  • 小米8发热(小米8发热怎么解决)

    小米8发热(小米8发热怎么解决)

  • 腾讯王卡可以开2张吗(腾讯王卡可以开副卡吗)

    腾讯王卡可以开2张吗(腾讯王卡可以开副卡吗)

  • iphone7plus有nfc功能吗(iphone7plus有nfc在哪)

    iphone7plus有nfc功能吗(iphone7plus有nfc在哪)

  • 为什么电脑有滋滋滋的声音(为什么电脑有滋啦滋啦的声音)

    为什么电脑有滋滋滋的声音(为什么电脑有滋啦滋啦的声音)

  • 怎么注销抖音号重新注册(抖音上怎么注销抖音号)

    怎么注销抖音号重新注册(抖音上怎么注销抖音号)

  • 退出家人共享对方有提示吗(退出家庭共享之后相册里的照片)

    退出家人共享对方有提示吗(退出家庭共享之后相册里的照片)

  • 天气冷苹果手机耗电快怎么办(天气冷苹果手机耗电快)

    天气冷苹果手机耗电快怎么办(天气冷苹果手机耗电快)

  • 微信收不到图片怎么回事(微信收不到图片发不出图片)

    微信收不到图片怎么回事(微信收不到图片发不出图片)

  • 怎么删除word中的所有标记(怎么删除word中的回车符号)

    怎么删除word中的所有标记(怎么删除word中的回车符号)

  • ios已升级的app怎么降(ios升级app还在吗)

    ios已升级的app怎么降(ios升级app还在吗)

  • 视频跟照片怎么一起拼(视频跟照片怎么压缩)

    视频跟照片怎么一起拼(视频跟照片怎么压缩)

  • 苹果x分辨率是2k吗(苹果x分辨率是几k)

    苹果x分辨率是2k吗(苹果x分辨率是几k)

  • 淘宝下单备注在哪里(淘宝下单在哪备注)

    淘宝下单备注在哪里(淘宝下单在哪备注)

  • qq自动转换语音怎么关闭(qq语音消息自动转文本什么意思)

    qq自动转换语音怎么关闭(qq语音消息自动转文本什么意思)

  • 什么叫增强短信(增强短信什么意思)

    什么叫增强短信(增强短信什么意思)

  • ie设置在哪里(ie页面设置在哪里找?)

    ie设置在哪里(ie页面设置在哪里找?)

  • beoplay中文叫什么(beoplayer中文)

    beoplay中文叫什么(beoplayer中文)

  • 苹果11双卡怎么装(苹果11双卡怎么设置主副卡打电话)

    苹果11双卡怎么装(苹果11双卡怎么设置主副卡打电话)

  • JavaScript charCodeAt() 方法

    JavaScript charCodeAt() 方法

  • 汇算清缴需要做分录吗
  • 2021年餐饮业的税率是多少?
  • 土增清算问题
  • 无形资产减值准备可以转回吗
  • 建筑行业异地工资怎么算
  • 合同资产减值准备怎么计提
  • 增值税加计扣除是什么意思啊
  • 以前年度损益调整结转到未分配利润
  • 罚没收入属于
  • 融资租赁营改增时间
  • 卷式发票要注意什么
  • 国有独资企业董事会应当在每年
  • 怎么把原材料转为成本
  • 物业公司代收的电费差额收入
  • 专票打印的时候密码区压线了能用吗
  • 工会是否具有有法律效力
  • 公园门票可以报销吗
  • 公司注销时存货计税依据
  • 增值税发票系统升级版
  • 专票的六位开票代码指的是什么
  • 原始股东减持要交多少税
  • 利润分配未分配利润期末有余额吗
  • 企业退款如何走账
  • php fork
  • 比较常见的病有哪些
  • linux网卡lo
  • macOS 10.13允许任何来源没有了怎么办?macOS 10.13允许任何来源没了开启步骤
  • php中split
  • u盘格式化后怎么还原数据
  • PQV2ISECURITY.EXE - PQV2ISECURITY是什么进程 有什么用
  • 日出的时候是圣诞节
  • php官方文档
  • 个体户缴纳的税有哪些
  • php登录注册整套源码
  • 机器学习期末复习题
  • 前后端分离项目部署到服务器
  • 投资性房地产抵债差额计入
  • 原始凭证一般没有
  • discuz php版本
  • 个体工商户经济类型是内资吗
  • 进项税额年末账务处理
  • 固定资产里含有增值税吗
  • 预收的贷方余额表示什么
  • 营业税改增值税是什么意思
  • 旧设备入账
  • 递延收益为什么属于负债
  • 小规模纳税人水利基金税率
  • 银行承兑汇票和银行汇票的区别
  • 手工账做账流程总结
  • 挂靠建筑公司企业所得税怎么交?
  • 财务预付账款情况说明
  • 房地产开发企业分为几个等级
  • 股权支付会计处理
  • 净现值率和现值指数与净现值什么时候它们评价结果一致
  • 期末结转之前会进行哪些工作
  • 暂估成本对冲分录怎么写
  • 营业执照注册资金变更
  • 商品流通企业如何控成本
  • 旅游饮食服务企业财务会计制度
  • mysql数据库全量备份
  • win8.1如何更新到win10
  • win安装ie8
  • linux使用mv命令,结果文件不见了
  • 清理ie八
  • eclipse 不同工程中文乱码问题(可对文件以及工程单独设置)
  • 将目录下的文件和文件夹按类型排序
  • shell编程入门
  • bootstrap基础
  • vue左侧菜单栏实现
  • framework res.apk
  • javascript教程
  • asynctask缺点
  • unity-chan
  • jquery 遍历
  • python的get
  • 厂房每年要交什么费用
  • 河南十大纳税公司
  • 江西省发票查询系统
  • 城市基础设施配套费由哪个部门收取
  • 一手房有契税和个税吗
  • 免责声明:网站部分图片文字素材来源于网络,如有侵权,请及时告知,我们会第一时间删除,谢谢! 邮箱:opceo@qq.com

    鄂ICP备2023003026号

    网站地图: 企业信息 工商信息 财税知识 网络常识 编程技术

    友情链接: 武汉网站建设