- 云函数如果绑定了层并引用了层,如何在本地进行开发调试?
云函数如果绑定了层并引用了层,如何在本地进行开发调试云函数?如果不可以,那么层的正确使用场景是什么? [图片]
2021-07-03 - 使用dayjs库后使用代码保护功能报错,如何解决?
求助!使用dayjs库后使用代码保护功能报错,报错信息如下,请问如何解决? message:miniprogram_npm/dayjs/index.js: 无法使用代码保护功能 in miniprogram_npm/dayjs/index.js 'require' requires one and only one static string literal 1 | "use strict";var t,e,n=require("../../@babel/runtime/helpers/typeof");module.exports=(t={},e=function(e,r){if(!t[e])return require(r);if(!t[e].status){var i=t[e].m;i._exports=i._tempexports;var s=Object.getOwnPropertyDescriptor(i,"exports");s&&s.configurable&&Object.defineProperty(i,"exports",{set:function(t){"object"===n(t)&&t!==i._exports&&(i._exports.__proto__=t.__proto__,Object.keys(t).forEach((function(e){i._exports[e]=t[e]}))),i._tempexports=t},get:function(){return i._tempexports}}),t[e].status=1,t[e].func(t[e].req,i,i.exports)}return t[e].m.exports},function(e,n,r){t[e]={status:0,func:n,req:r,m:{exports:{},_tempexports:{}}}}(1624102295068,(function(t,e,r){!function(t,i){"object"==n(r)&&void 0!==e?e.exports=i():"function"==typeof define&&define.amd?define(i):t.dayjs=i()}(this,(function(){var t="millisecond",e="second",r="minute",i="hour",s="day",u="week",o="month",a="quarter",f="year",c="date",h=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[^0-9]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,d=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,$={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_")},l=function(t,e,n){var r=String(t);return!r||r.length>=e?t:""+Array(e+1-r.length).join(n)+t},p={s:l,z:function(t){var e=-t.utcOffset(),n=Math.abs(e),r=Math.floor(n/60),i=n%60;return(e<=0?"+":"-")+l(r,2,"0")+":"+l(i,2,"0")},m:function t(e,n){if(e.date()<n.date())return-t(n,e);var r=12*(n.year()-e.year())+(n.month()-e.month()),i=e.clone().add(r,o),s=n-i<0,u=e.clone().add(r+(s?-1:1),o);return+(-(r+(n-i)/(s?i-u:u-i))||0)},a:function(t){return t<0?Math.ceil(t)||0:Math.floor(t)},p:function(n){return{M:o,y:f,w:u,d:s,D:c,h:i,m:r,s:e,ms:t,Q:a}[n]||String(n||"").toLowerCase().replace(/s$/,"")},u:function(t){return void 0===t}},m="en",y={};y[m]=$;var M=function(t){return t instanceof _},v=function(t,e,n){var r;if(!t)return m;if("string"==typeof t)y[t]&&(r=t),e&&(y[t]=e,r=t);else{var i=t.name;y[i]=t,r=i}return!n&&r&&(m=r),r||!n&&m},g=function(t,e){if(M(t))return t.clone();var r="object"==n(e)?e:{};return r.date=t,r.args=arguments,new _(r)},D=p;D.l=v,D.i=M,D.w=function(t,e){return g(t,{locale:e.$L,utc:e.$u,x:e.$x,$offset:e.$offset})};var _=function(){function n(t){this.$L=v(t.locale,null,!0),this.parse(t)}var $=n.prototype;return $.parse=function(t){this.$d=function(t){var e=t.date,n=t.utc;if(null===e)return new Date(NaN);if(D.u(e))return new Date;if(e instanceof Date)return new Date(e);if("string"==typeof e&&!/Z$/i.test(e)){var r=e.match(h);if(r){var i=r[2]-1||0,s=(r[7]||"0").substring(0,3);return n?new Date(Date.UTC(r[1],i,r[3]||1,r[4]||0,r[5]||0,r[6]||0,s)):new Date(r[1],i,r[3]||1,r[4]||0,r[5]||0,r[6]||0,s)}}return new Date(e)}(t),this.$x=t.x||{},this.init()},$.init=function(){var t=this.$d;this.$y=t.getFullYear(),this.$M=t.getMonth(),this.$D=t.getDate(),this.$W=t.getDay(),this.$H=t.getHours(),this.$m=t.getMinutes(),this.$s=t.getSeconds(),this.$ms=t.getMilliseconds()},$.$utils=function(){return D},$.isValid=function(){return!("Invalid Date"===this.$d.toString())},$.isSame=function(t,e){var n=g(t);return this.startOf(e)<=n&&n<=this.endOf(e)},$.isAfter=function(t,e){return g(t)<this.startOf(e)},$.isBefore=function(t,e){return this.endOf(e)<g(t)},$.$g=function(t,e,n){return D.u(t)?this[e]:this.set(n,t)},$.unix=function(){return Math.floor(this.valueOf()/1e3)},$.valueOf=function(){return this.$d.getTime()},$.startOf=function(t,n){var a=this,h=!!D.u(n)||n,d=D.p(t),$=function(t,e){var n=D.w(a.$u?Date.UTC(a.$y,e,t):new Date(a.$y,e,t),a);return h?n:n.endOf(s)},l=function(t,e){return D.w(a.toDate()[t].apply(a.toDate("s"),(h?[0,0,0,0]:[23,59,59,999]).slice(e)),a)},p=this.$W,m=this.$M,y=this.$D,M="set"+(this.$u?"UTC":"");switch(d){case f:return h?$(1,0):$(31,11);case o:return h?$(1,m):$(0,m+1);case u:var v=this.$locale().weekStart||0,g=(p<v?p+7:p)-v;return $(h?y-g:y+(6-g),m);case s:case c:return l(M+"Hours",0);case i:return l(M+"Minutes",1);case r:return l(M+"Seconds",2);case e:return l(M+"Milliseconds",3);default:return this.clone()}},$.endOf=function(t){return this.startOf(t,!1)},$.$set=function(n,u){var a,h=D.p(n),d="set"+(this.$u?"UTC":""),$=(a={},a[s]=d+"Date",a[c]=d+"Date",a[o]=d+"Month",a[f]=d+"FullYear",a[i]=d+"Hours",a[r]=d+"Minutes",a[e]=d+"Seconds",a[t]=d+"Milliseconds",a)[h],l=h===s?this.$D+(u-this.$W):u;if(h===o||h===f){var p=this.clone().set(c,1);p.$d[$](l),p.init(),this.$d=p.set(c,Math.min(this.$D,p.daysInMonth())).$d}else $&&this.$d[$](l);return this.init(),this},$.set=function(t,e){return this.clone().$set(t,e)},$.get=function(t){return this[D.p(t)]()},$.add=function(t,n){var a,c=this;t=Number(t);var h=D.p(n),d=function(e){var n=g(c);return D.w(n.date(n.date()+Math.round(e*t)),c)};if(h===o)return this.set(o,this.$M+t);if(h===f)return this.set(f,this.$y+t);if(h===s)return d(1);if(h===u)return d(7);var $=(a={},a[r]=6e4,a[i]=36e5,a[e]=1e3,a)[h]||1,l=this.$d.getTime()+t*$;return D.w(l,this)},$.subtract=function(t,e){return this.add(-1*t,e)},$.format=function(t){var e=this;if(!this.isValid())return"Invalid Date";var n=t||"YYYY-MM-DDTHH:mm:ssZ",r=D.z(this),i=this.$locale(),s=this.$H,u=this.$m,o=this.$M,a=i.weekdays,f=i.months,c=function(t,r,i,s){return t&&(t[r]||t(e,n))||i[r].substr(0,s)},h=function(t){return D.s(s%12||12,t,"0")},$=i.meridiem||function(t,e,n){var r=t<12?"AM":"PM";return n?r.toLowerCase():r},l={YY:String(this.$y).slice(-2),YYYY:this.$y,M:o+1,MM:D.s(o+1,2,"0"),MMM:c(i.monthsShort,o,f,3),MMMM:c(f,o),D:this.$D,DD:D.s(this.$D,2,"0"),d:String(this.$W),dd:c(i.weekdaysMin,this.$W,a,2),ddd:c(i.weekdaysShort,this.$W,a,3),dddd:a[this.$W],H:String(s),HH:D.s(s,2,"0"),h:h(1),hh:h(2),a:$(s,u,!0),A:$(s,u,!1),m:String(u),mm:D.s(u,2,"0"),s:String(this.$s),ss:D.s(this.$s,2,"0"),SSS:D.s(this.$ms,3,"0"),Z:r};return n.replace(d,(function(t,e){return e||l[t]||r.replace(":","")}))},$.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},$.diff=function(t,n,c){var h,d=D.p(n),$=g(t),l=6e4*($.utcOffset()-this.utcOffset()),p=this-$,m=D.m(this,$);return m=(h={},h[f]=m/12,h[o]=m,h[a]=m/3,h[u]=(p-l)/6048e5,h[s]=(p-l)/864e5,h[i]=p/36e5,h[r]=p/6e4,h[e]=p/1e3,h)[d]||p,c?m:D.a(m)},$.daysInMonth=function(){return this.endOf(o).$D},$.$locale=function(){return y[this.$L]},$.locale=function(t,e){if(!t)return this.$L;var n=this.clone(),r=v(t,e,!0);return r&&(n.$L=r),n},$.clone=function(){return D.w(this.$d,this)},$.toDate=function(){return new Date(this.valueOf())},$.toJSON=function(){return this.isValid()?this.toISOString():null},$.toISOString=function(){return this.$d.toISOString()},$.toString=function(){return this.$d.toUTCString()},n}(),S=_.prototype;return g.prototype=S,[["$ms",t],["$s",e],["$m",r],["$H",i],["$W",s],["$M",o],["$y",f],["$D",c]].forEach((function(t){S[t[1]]=function(e){return this.$g(e,t[0],t[1])}})),g.extend=function(t,e){return t.$i||(t(e,_,g),t.$i=!0),g},g.locale=v,g.isDayjs=M,g.unix=function(t){return g(1e3*t)},g.en=y[m],g.Ls=y,g.p={},g}))}),(function(t){return e({}[t],t)})),e(1624102295068)); appid: wxc91df3a38400bec7 openid: o6zAJs0JpkBa8vzuSY97204JQn-g ideVersion: 1.05.2106091 osType: win32-x64 time: 2021-06-27 14:32:46
2021-06-27 - 敢问:云函数->预拉取->获取到的path时不时为空是什么原因?
一般情况下,EVENT里是没有path这个字段,开启预拉取才有。目前遇到的情况是:在小程序端不能每次都获取到预拉取数据,查云函数日志后发现path为空,想请问下,什么情况会造成path为空。 云函数端日志: START {"SOURCE":"wx_client","CLIENTIP":"","ENV":"prd-kaduck","EVENT":"{\"path\":\"\",\"query\":\"\",\"scene\":1089,\"userInfo\":{\"appId\":\"wxc91df3a38400bec7\",\"openId\":\"o1FNq5GLxxq*******2tOD6MpU0Y\"}}"} REPORT RequestId:d577898b-d0a5-11eb-a19c-525400742e8d Duration:1ms Memory:256MB MemUsage:31.628906MB END
2021-06-19 - 云函数推送订阅消息报43108错误码是什么原因,如何解决?
云函数推送订阅消息报43108错误码是什么原因,如何解决?文档没有该错误码说明 {"errCode":43108,"errMsg":"openapi.subscribeMessage.send:fail Cannot make concurrent calls to the same OpenID, please try again rid: 60c387cc-01733063-7d722f93"} [图片]
2021-06-13 - 云函数getWXContext(),SOURCE值为wx_crawler是什么来源?
getWXContext()相关文档中关于SOURCE未列举全,暂时发现的有wx_trigger、wx_crawler未说明,请求完整版说明。 [图片]
2021-06-05 - 云开发数据库高级操作在黑色主题下文字颜色变黑,有bug?
windows10 IDE v1.3.82 [图片]
2021-04-17 - 云函数上传一直提示状态错误,无法删除如何解决?
Win10 工具版本1.04.2010162 云函数上传一直提示状态错误,无法删除 Error: TencentCloud API error: { "Response": { "Error": { "Code": "FailedOperation.UpdateFunctionCode", "Message": "当前函数状态无法进行此操作,请在函数状态正常时重试。" }, "RequestId": "d801f1ab-7b8b-44c4-8577-768502609826" } } [图片][图片]
2020-10-21 - 开发工具点保存后编译,不生效,预览效果仍是上一次编译的效果!?
开发工具版本:Windows 1.04.2009032 这个问题最近几个版本都会出现,不是偶然出现,是每次必现,必须要重启开发工具。
2020-09-08 - 小程序分享卡片后下方会出现可交互文字,如何实现?
微信读书小程序分享卡片后,卡片下方会出现可交互文字,此功能如何实现的?是开放的新功能? [图片]
2020-08-13 - 【1154: 朋友圈打开朋友圈分享页】 场景下,onload调用云函数获取数据报错,如何解决?
VM17:1 (in promise) MiniProgramError errCode: -404011 cloud function execution error | errMsg: cloud.callFunction:fail requestID , cloud function service error code -501023, error message Unauthenticated access is denied; at cloud.callFunction api; Error: errCode: -404011 cloud function execution error | errMsg: cloud.callFunction:fail requestID , cloud function service error code -501023, error message Unauthenticated access is denied; at cloud.callFunction api;
2020-07-07