从Chrome Webstore安装的扩展程序会引发错误“套餐无效。详细信息:'无法加载带有文件或目录名称的扩展名_metadata ...' [英] Extension installed from Chrome Webstore throws error "Package is invalid. Details: 'Cannot load extension with file or directory name _metadata...'

查看:188
本文介绍了从Chrome Webstore安装的扩展程序会引发错误“套餐无效。详细信息:'无法加载带有文件或目录名称的扩展名_metadata ...'的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

当CRX添加到Chrome网上应用店时,Google会将一个目录 _metadata 添加到crx。老版本的Chrome不知道这个目录(在Chrome 27上测试过)并抛出这个错误:

When a CRX is added to the Chrome web store, Google adds a directory _metadata to the crx. Older versions of Chrome do not know about this directory (tested on Chrome 27) and throw this error:

Package is invalid. Details: 'Cannot load extension with file or directory name
_metadata. Filenames starting with "_" are reserved for use by the system.'.

如果您尝试在旧版Chrome上安装此扩展程序,您可以看到此错误: https://chrome.google.com/webstore/detail/allcast-receiver/hjbljnpdahefgnopeohlaeohgkiidnoe

You can see this error if you try to install this extension on an older version of Chrome: https://chrome.google.com/webstore/detail/allcast-receiver/hjbljnpdahefgnopeohlaeohgkiidnoe

一个很好的解释: https://groups.google.com/a/chromium.org/d/msg/chromium-apps/huDqSeaQx3Q/Z5GOMxA7lQIJ

是否有解决方法为了这?这使得它无法支持旧版本的Chrome。

Is there a workaround for this? This makes it impossible to support older versions of Chrome.

推荐答案

您是扩展开发人员,无法解决此错误,因为该目录是由Chrome网上应用店(CWS)添加的。您可以通过不使用CWS分发扩展来解决该错误,但是大多数Chrome用户无法使用该扩展,因为Google已积极地尝试阻止用户从CWS外部获得扩展。

You -as an extension developer- cannot work-around this bug, because the directory is added by the Chrome Web Store (CWS). You could work-around the bug by not using the CWS to distribute the extension, but then the extension cannot be used by the majority of Chrome users, because Google has actively tried to stop users from getting extensions from outside the CWS.

只有CWS团队可以修复这个bug。如果用户代理不支持目录(Chrome 30-),它们应该提供不含 _metadata 目录的crx文件。此错误正在 https://code.google.com/p/chromium/issues/上进行跟踪细节?ID = 377278 。到目前为止,回应是:

The CWS team are the only ones who can fix the bug. They should serve crx files without a _metadata directory if the user agent does not support the directory (Chrome 30-). This bug is being tracked on https://code.google.com/p/chromium/issues/detail?id=377278. So far, the response is:


我们无法修复旧版本的Chrome。 Webstore方面在b / 15176392方面进行了追踪,但将支持扩展到Chrome 30的可能性不大。

We can't fix old versions of Chrome. Webstore side tracked at b/15176392, but extending support back to Chrome 30 is unlikely.

表示您确实希望修复该错误。如果有足够的用户/开发者抱怨,那么Google 可能会修正该错误。

Star the issue to get notified of updates and to signal that you really want the bug to be fixed. If enough users/developers complain, then Google might fix the bug.

这篇关于从Chrome Webstore安装的扩展程序会引发错误“套餐无效。详细信息:'无法加载带有文件或目录名称的扩展名_metadata ...'的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆