我最近将边缘扩展提交给Microsoft商店进行审查。但是它没有通过软件包合规性测试。我不确定现在如何进行。我检查了清单json中是否有无效条目,但没有。我粘贴了清单文件的详细信息,下面是错误报告。
JSON模式验证测试检测到以下错误:
System.InvalidCastException:无法将类型为“ System.Xml.Linq.XComment”的对象转换为类型为“ System.Xml.Linq.XElement”。 Microsoft.Windows.SoftwareLogoTest上的Microsoft.Windows.SoftwareLogo.Tests.BrowserExtensionApp.JsonManifestValidation.Test(BrowserExtensionApp browserExtensionApp)上的Microsoft.Windows.SoftwareLogo.Tests.BrowserExtensionApp.JsonManifestValidation.GetAppxExtensions(String appxManifestPath)
{
"manifest_version": 2,
"name": "AB C",
"version": "1.0",
"author" : "AB C",
"description": "Edge extension",
"homepage_url" : "https://AB.C.com/online/main",
"browser_action": {
"default_icon": {
"19" : "images/PNG/ABC-19-disable.png",
"20" : "images/PNG/ABC-20-disable.png",
"25" : "images/PNG/ABC-25-disable.png",
"30" : "images/PNG/ABC-30-disable.png",
"35" : "images/PNG/ABC-35-disable.png",
"38" : "images/PNG/ABC-38-disable.png",
"40" : "images/PNG/ABC-40-disable.png"
},
"default_title": "AB C",
"default_popup" : "html/ABCPopup.html"
},
"browser_specific_settings": {
"edge": {
"browser_action_next_to_addressbar": true
}
},
"minimum_edge_version" : "42.17134.1.0",
"background": {
"persistent" : true,
"page": "html/background.html"
},
"content_scripts": [
{
"matches": ["http://*/*", "https://*/*"],
"js": ["js/ABCUtil.min.js", "js/ABCCS.min.js","js/jquery-3.3.1.min.js"],
"run_at": "document_idle",
"all_frames": true
}
],
"permissions": [
"tabs",
"cookies",
"idle",
"privacy",
"notifications",
"https://AB.C.com/",
"https://AB.C.eu/",
"https://AB.C.com.cn/",
"https://AB.C.in/",
"contextMenus",
"clipboardWrite",
"clipboardRead",
"unlimitedStorage"
],
"content_security_policy": "style-src 'self' 'unsafe-inline' https://fonts.googleapis.com/css https://fonts.gstatic.com/s/opensans/ ; font-src 'self' https://fonts.googleapis.com/css https://fonts.gstatic.com/s/opensans/ ; default-src 'self';script-src 'self'; frame-src 'self';img-src 'self' data: blob:;connect-src https://AB.C.com https://AB.C.eu https://AB.C.in https://AB.C.com.cn",
"icons": {
"16" : "images/PNG/ABC-32.png",
"48": "images/PNG/ABC-48.png",
"128": "images/PNG/ABC-128.png"
},
"web_accessible_resources": [
"/html/ABCSSFrame.html",
"/html/ABCUSFrame.html",
"/html/ABCMSFrame.html",
"/html/ABCResetProgress.html",
"/html/ABCGetPP.html",
"/html/ABCInsecureFrame.html",
"/images/secret11x11.svg",
"/images/loading.gif",
"/images/tpband-close.png",
"/images/clearicon.png"
]
}
答案 0 :(得分:0)
如果使用的代码,功能,方法,图像,徽标已被任何其他扩展使用,或者不允许在扩展中使用,或者由于任何其他原因,MS Store会为您提供此类错误。
要获取有关Microsoft商店政策的更多信息,请参阅下面的链接。
您可以首先尝试使用Windows App认证工具包。
要增加扩展程序发布到Microsoft Store的机会,您需要安装并运行Windows App认证工具包。这会在您的扩展程序包上进行一系列测试,以确保它可以用于Microsoft Store。
参考:
答案 1 :(得分:0)
我在AppxManifest.xml中有一个注释,由于某种原因,Microsoft不允许在xml文件中添加注释。我删除了评论以解决此问题。