text:
Bug report: Error: Access denied. You do not have permission to perform this action or access this resource

Description

Error: Access denied. You do not have permission to perform this action or access this resource
I'm the site collection administrator and also part of the site owners group
I'm not the tenant admin

Steps to reproduce

Ran powershell script (see below)

Expected result
Actual result

Error: Access denied. You do not have permission to perform this action or access this resource.

Environment

Windows 10
Powershell Version 5.1.17763.1007
Node JS version v10.19.0
Office 365 CLI version  2.10.0

Hey @souravkar123 thank you for reporting this and apologies for the trouble.
Could you execute the command with the --debug option and paste the output into this issue?

PS C:\windows\system32> C:\Sourav\Tutorials\Powershell scripts\O365CLI Test.ps1
To sign in, use a web browser to open the page https://microsoft.com/devicelogin and enter the code D4V6BFUS9 to authenticate.
connectedAs: Sourav.Kar@honeywell.com
No token found for resource https://honeywellprod.sharepoint.com
Retrieving new access token using existing refresh token AQABAAAAAAAm-06blBE1TpVMil8KPQ41no0XZVaQF_GEcZV7jxLXQgrs3mWjvbA2NIMKqS--clNhRdHWEuXbFhYERW_VFceVnT5hPP66i3RTFJH19XE874ZALQLBK
bL87ORt26bLDAeJyySa8tNqPgTui9gSs8rusPQa_yM8undDvm03xxflRh47_irZoXF0hZGyrIWJ6IdUSPEky0nclccF5MRMtfLpO1j9MT6Ip985ESZf-9bVbUyFhxjn_C0ou2RgF5Zpl1Mu_3tRL2L0z03J_V23Swi7V5__J02xB_uTAWHooP-
nyJ7E-t4JStM667_oirLq8VSFDy-IfRCx0DzA4HsLkaEVN2FIsAtz36YsiIWPdwiirj6YilnC3hdBRUk1FvCJwjG8hfd6DanmUUk6qormZrUTBEjWc0g4oVToIygNR9Mb38hVlKxUrSeKUOfkjcRVxYcRJBJR4wuY5hBZVDrumoJW22OS64bU9
ntlBYosx-ckXlBh9CMsZ2k14XOrCpAb-Ab4CJyR46xrWHJs21E8oMpfablFvJjSXrPXBLMlDxLO9wm1eWUd9ITzIv5hkBscutjEARzZgb7OBtY8UTkT-9d7s_0DdoC2xYzWw5-JuWpSyo71B8_e4V1-VLaTYARVBUkDp9W6evsgFLLsk_gS5m1
cdAZKQXDUb46e3lZx6CqH7307FNwoE287qVTpkf4Uam-wSsobTrZNOqploELxGW86b3gtARuu0DhpTm9TuC7f8yN0pkYinJXyJmw25GSa4hnU1k5X8IdA0UVfGsvdNrJyt_dwPOjhESMBU4HhSS55M_eRojs_MMZKm0JTbCFL2NwxYHnBMBEk3
gGnlBTIc4ilVibH-WETnCNUge1kujnUt_k7VvZJ6-A3UPU9crpCJxUWCT6z6tlG5Dmo5zf7MDjITaSBnD40Y7Vi3981Lvxs36Y2U7pRP1BpB3Go9dlyRFY95eeVMcKQny8PIlGSIXuRyuXKTGDUMmh8q0OEUw_iL0sMs0mjrOFrJipnofyEbu6
VI08JazK3mJgNxheH8P0f054uWlHGO-6f5KW6w6R6popbPw4o8bf7PvrvNRGV0wIgAA
Wed, 17 Jun 2020 20:58:42 GMT:cdf86243-1476-42e7-a2bd-747ae41b78f1 - Authority: VERBOSE: Performing instance discovery
Wed, 17 Jun 2020 20:58:42 GMT:cdf86243-1476-42e7-a2bd-747ae41b78f1 - Authority: VERBOSE: Performing static instance discovery
Wed, 17 Jun 2020 20:58:42 GMT:cdf86243-1476-42e7-a2bd-747ae41b78f1 - Authority: VERBOSE: Authority validated via static instance discovery.
Wed, 17 Jun 2020 20:58:42 GMT:cdf86243-1476-42e7-a2bd-747ae41b78f1 - TokenRequest: INFO: Getting a new token from a refresh token.
Response:
accessToken        : eyJ0eXAiOiJKV1QiLCJhbGciOiJSUzI1NiIsIng1dCI6IlNzWnNCTmhaY0YzUTlTNHRycFFCVEJ5TlJSSSIsImtpZCI6IlNzWnNCTmhaY0YzUTlTNHRycFFCVEJ5TlJSSSJ9.eyJhdWQiOiJodHRwczovL2hvbmV5
d2VsbHByb2Quc2hhcmVwb2ludC5jb20iLCJpc3MiOiJodHRwczovL3N0cy53aW5kb3dzLm5ldC85NmVjZTUyNi05YzdkLTQ4YjAtOGRhZi04YjkzYzkwYTVkMTgvIiwiaWF0IjoxNTkyNDI3MjIyLCJuYmYiOjE1OTI0MjcyMjIsImV4cCI6MT
U5MjQzMTEyMiwiYWNyIjoiMSIsImFpbyI6IkFWUUFxLzhQQUFBQWduMjhLM04wSDZDT1lKT3VSbHU3aXVWbFBmcDdKSk5NRHR2bjdMRkpsQUluNVJwM3EzaWJBNGRYTktRVzNHbTlhNU5NSlBoMnpnN05HWGZKL3ZsN3l6dEFaVVhLdVZCRmhp
STFJcjVLUU5FPSIsImFtciI6WyJ3aWEiLCJtZmEiXSwiYXBwX2Rpc3BsYXluYW1lIjoiUG5QIE9mZmljZSAzNjUgTWFuYWdlbWVudCBTaGVsbCIsImFwcGlkIjoiMzEzNTljN2YtYmQ3ZS00NzVjLTg2ZGItZmRiOGM5Mzc1NDhlIiwiYXBwaW
RhY3IiOiIwIiwiZmFtaWx5X25hbWUiOiJLYXIiLCJnaXZlbl9uYW1lIjoiU291cmF2IiwiaWR0eXAiOiJ1c2VyIiwiaXBhZGRyIjoiNjkuMTEzLjE2MC4xMTQiLCJuYW1lIjoiS2FyLCBTb3VyYXYiLCJvaWQiOiIyYjkwM2VlNS0yZTk1LTRl
NWQtYTcxMC03OTY2NmFiZjM2MjciLCJvbnByZW1fc2lkIjoiUy0xLTUtMjEtMjE0MDE0ODQyOC03MTg2MDg0NTItOTM3NzY5OTcyLTE2NzYxMCIsInB1aWQiOiIxMDAzQkZGRDk1ODE4NUQ5Iiwic2NwIjoiQXBwQ2F0YWxvZy5SZWFkV3JpdG
UuQWxsIERpcmVjdG9yeS5BY2Nlc3NBc1VzZXIuQWxsIERpcmVjdG9yeS5SZWFkV3JpdGUuQWxsIEdyb3VwLlJlYWRXcml0ZS5BbGwgSWRlbnRpdHlQcm92aWRlci5SZWFkV3JpdGUuQWxsIE1haWwuU2VuZCBSZXBvcnRzLlJlYWQuQWxsIFVz
ZXIuSW52aXRlLkFsbCIsInNpZCI6ImIwZDhiNTE3LTY3YWItNGE2My04YTFlLTMyNDkzODY3NjFmMSIsInN1YiI6Im5VLTNyUFpMd3FqbmxWcE5WVXBPUVo0cTFaYnJKQThGMFh0UXZaZ0NqRzAiLCJ0aWQiOiI5NmVjZTUyNi05YzdkLTQ4Yj
AtOGRhZi04YjkzYzkwYTVkMTgiLCJ1bmlxdWVfbmFtZSI6IlNvdXJhdi5LYXJAaG9uZXl3ZWxsLmNvbSIsInVwbiI6IlNvdXJhdi5LYXJAaG9uZXl3ZWxsLmNvbSIsInV0aSI6InFRQzlQMWJWWTBldU9ZNGJHSmVNQUEiLCJ2ZXIiOiIxLjAi
fQ.rDeNfhx6laXptWWH2OwCMr1bZNrXVSVcuL6Nua6K-az64TXMHCPldpmApQSPHBltJwHgK-qpZToKgrXI90mJ3g5RCJZ0wpfRTEbryo7Euh1GYeSaaXlJtDkfhc7Rz6cbqJpPgmPaUmRRWKXaMHFNFAUKKk2GioXLw_ZoKn8LkuOahxc-bHm
qXtkgQ8xXAPPSsyBcDcqwH1ulmc0jqWaBM2EmSdNNhbo768simo0t3Jf9FMV5nSbXNWUd226bCNb5ady6BwPVj7gSBZ15-pr1roIkGm1vfh-mdcBxGAHqr_43KUrKkKL40rhGGQ6zVDTD1SDWrVTx8C-clK9wZSRecw
expiresIn          : 3599
expiresOn          : "2020-06-17T21:58:41.662Z"
familyName         : Kar
givenName          : Sourav
isUserIdDisplayable: true
oid                : 2b903ee5-2e95-4e5d-a710-79666abf3627
refreshToken       : AQABAAAAAAAm-06blBE1TpVMil8KPQ41t4SbOrjq42FgtOpB7qlzBYa6rQhqeNd8pwTk3PVHfBxK5ioSpqNyf6zqjXnnbMWJrhXzv6JCc4H8wMgYKN_c3yGBdwNW8jyVq-Fw06RtHQ5IglD8XE6KbaSHwBdCBRkTl
OwBaxMjANF-TKRdzBY4CUBV6vdkPcAi5WZVJbFHIPEXRnPHJ49JfZp9vFCdmj8eyH7xUSUurTTGYA9lTdMO0kVvBwAGeu9szVHRphjsaR2SsMHZelo6SLcl_P8mnfTRDG2_OzhWcDkFlQXBs8eUfF-DR3A6yjwcN0uc0uuxEsFGbhY2RSeH86C
-7kKG8G_68EkNiWUyQ-7u3hmpG6jy0f6YXbzUdITfvLjVVM37LKyFFJfhiB1e5Yz5fX7pzwo2SWPgdF9x6L3CVI9QiIOefz8SvIt8d1DGCoCudJUtz9JtxunP4o6UuCmbbqwdVz1D0Jaya_6UsUHYH41sFMJE6ryUpIBy8mAivcb_6qKTgwfVD
cyGOUxb6FiaySQXHYdINka5QyyxNM8YIpWspWc4hnsZM64hJSjVxO_-WMXEi_LOskHCIVQ2mgsGNL263hMTWNww6kfYkA4gTn14uhkz8_r8NBief0Ikk4c_4PdQTQVDVhSn9BbQbtlGQhsQt_sz1yMeR1uj9GTCtyQeFIkr6TtlCx-vrZ8ds2n
RuzF9Kqc228T39fLTzbCUGyvTmW3hLYFOIcm3UUcb5-sV7_AICVYN9CBXUcK_SeL3DhpDmxTBmZXBlJcKZYfz2TzqRenn3FKinsn3nwZwJok_x9wd7iwohksWsbriL-CMs1vlsXbxPxYMJFug-8mT3-Y3NxLqbtFuEpFbJaMqFtUXvbPV11_sD
fg3tzJXaIPmlw525Mh3rhwuLqsoQxAbS4POv1WXNcMIL3ukw-vEaQIxQV8CsQwO9ex8lpCTyNp_c3w8fAXAOl8UUkYty141CiQM7lTCmvpLEX7lR3HtL76En6QXu2XAT5owQ4OoWZM6FsFjT2sIqCHXwNvZK9lMtvXmZbMeLcskI5ZfFo6FC_-
BkLvVRdapYk4QK1YJPQDa4n8zBT1LBLZ7jPJScfF1tZD07rSxmNDnRt-1IsOWIo2c4cTKynncAllH9GC0yqbkVYORWZSV_AN99-uGD5FTT24xO1YnIAA
resource           : https://honeywellprod.sharepoint.com
tenantId           : 96ece526-9c7d-48b0-8daf-8b93c90a5d18
tokenType          : Bearer
userId             : Sourav.Kar@honeywell.com
node.exe : REQUEST { headers:
At C:\Users\E879829\AppData\Roaming\npm\o365.ps1:15 char:3

& "node$exe"  "$basedir/node_modules/@pnp/office365-cli/dist/index. ...

+ CategoryInfo          : NotSpecified: (REQUEST { headers::String) [], RemoteException
+ FullyQualifiedErrorId : NativeCommandError

{ 'user-agent': 'NONISV|SharePointPnP|Office365CLI/2.9.0',
accept: 'application/json;odata=nometadata',
authorization:
'Bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJSUzI1NiIsIng1dCI6IlNzWnNCTmhaY0YzUTlTNHRycFFCVEJ5TlJSSSIsImtpZCI6IlNzWnNCTmhaY0YzUTlTNHRycFFCVEJ5TlJSSSJ9.eyJhdWQiOiJodHRwczovL2hvbmV5d2VsbH
Byb2Quc2hhcmVwb2ludC5jb20iLCJpc3MiOiJodHRwczovL3N0cy53aW5kb3dzLm5ldC85NmVjZTUyNi05YzdkLTQ4YjAtOGRhZi04YjkzYzkwYTVkMTgvIiwiaWF0IjoxNTkyNDI3MjIyLCJuYmYiOjE1OTI0MjcyMjIsImV4cCI6MTU5MjQ
zMTEyMiwiYWNyIjoiMSIsImFpbyI6IkFWUUFxLzhQQUFBQWduMjhLM04wSDZDT1lKT3VSbHU3aXVWbFBmcDdKSk5NRHR2bjdMRkpsQUluNVJwM3EzaWJBNGRYTktRVzNHbTlhNU5NSlBoMnpnN05HWGZKL3ZsN3l6dEFaVVhLdVZCRmhpSTFJ
cjVLUU5FPSIsImFtciI6WyJ3aWEiLCJtZmEiXSwiYXBwX2Rpc3BsYXluYW1lIjoiUG5QIE9mZmljZSAzNjUgTWFuYWdlbWVudCBTaGVsbCIsImFwcGlkIjoiMzEzNTljN2YtYmQ3ZS00NzVjLTg2ZGItZmRiOGM5Mzc1NDhlIiwiYXBwaWRhY
3IiOiIwIiwiZmFtaWx5X25hbWUiOiJLYXIiLCJnaXZlbl9uYW1lIjoiU291cmF2IiwiaWR0eXAiOiJ1c2VyIiwiaXBhZGRyIjoiNjkuMTEzLjE2MC4xMTQiLCJuYW1lIjoiS2FyLCBTb3VyYXYiLCJvaWQiOiIyYjkwM2VlNS0yZTk1LTRlNW
QtYTcxMC03OTY2NmFiZjM2MjciLCJvbnByZW1fc2lkIjoiUy0xLTUtMjEtMjE0MDE0ODQyOC03MTg2MDg0NTItOTM3NzY5OTcyLTE2NzYxMCIsInB1aWQiOiIxMDAzQkZGRDk1ODE4NUQ5Iiwic2NwIjoiQXBwQ2F0YWxvZy5SZWFkV3JpdGU
uQWxsIERpcmVjdG9yeS5BY2Nlc3NBc1VzZXIuQWxsIERpcmVjdG9yeS5SZWFkV3JpdGUuQWxsIEdyb3VwLlJlYWRXcml0ZS5BbGwgSWRlbnRpdHlQcm92aWRlci5SZWFkV3JpdGUuQWxsIE1haWwuU2VuZCBSZXBvcnRzLlJlYWQuQWxsIFVz
ZXIuSW52aXRlLkFsbCIsInNpZCI6ImIwZDhiNTE3LTY3YWItNGE2My04YTFlLTMyNDkzODY3NjFmMSIsInN1YiI6Im5VLTNyUFpMd3FqbmxWcE5WVXBPUVo0cTFaYnJKQThGMFh0UXZaZ0NqRzAiLCJ0aWQiOiI5NmVjZTUyNi05YzdkLTQ4Y
jAtOGRhZi04YjkzYzkwYTVkMTgiLCJ1bmlxdWVfbmFtZSI6IlNvdXJhdi5LYXJAaG9uZXl3ZWxsLmNvbSIsInVwbiI6IlNvdXJhdi5LYXJAaG9uZXl3ZWxsLmNvbSIsInV0aSI6InFRQzlQMWJWWTBldU9ZNGJHSmVNQUEiLCJ2ZXIiOiIxLj
AifQ.rDeNfhx6laXptWWH2OwCMr1bZNrXVSVcuL6Nua6K-az64TXMHCPldpmApQSPHBltJwHgK-qpZToKgrXI90mJ3g5RCJZ0wpfRTEbryo7Euh1GYeSaaXlJtDkfhc7Rz6cbqJpPgmPaUmRRWKXaMHFNFAUKKk2GioXLw_ZoKn8LkuOahxc-
bHmqXtkgQ8xXAPPSsyBcDcqwH1ulmc0jqWaBM2EmSdNNhbo768simo0t3Jf9FMV5nSbXNWUd226bCNb5ady6BwPVj7gSBZ15-pr1roIkGm1vfh-mdcBxGAHqr_43KUrKkKL40rhGGQ6zVDTD1SDWrVTx8C-clK9wZSRecw' },
gzip: true,
url:
'https://honeywellprod.sharepoint.com/teams/HBS-Budgetary-Tool-DEV/_api/web/',
json: true,
method: 'GET',
callback: [Function: RP$callback],
transform: undefined,
simple: true,
resolveWithFullResponse: false,
transform2xxOnly: false }
REQUEST make request https://honeywellprod.sharepoint.com/teams/HBS-Budgetary-Tool-DEV/_api/web/
REQUEST onRequestResponse https://honeywellprod.sharepoint.com/teams/HBS-Budgetary-Tool-DEV/_api/web/ 403 { 'cache-control': 'private, max-age=0',
'transfer-encoding': 'chunked',
'content-type':
'application/json;odata=nometadata;streaming=true;charset=utf-8',
expires: 'Tue, 02 Jun 2020 20:58:43 GMT',
'last-modified': 'Wed, 17 Jun 2020 20:58:43 GMT',
server: 'Microsoft-IIS/10.0',
'x-sharepointhealthscore': '3',
'x-msdavext_error':
'917656; Access+denied.+Before+opening+files+in+this+location%2c+you+must+first+browse+to+the+web+site+and+select+the+option+to+login+automatically.',
dataserviceversion: '3.0',
'x-aspnet-version': '4.0.30319',
sprequestguid: '08645d9f-4079-a000-bf13-5c5ca57d2668',
'request-id': '08645d9f-4079-a000-bf13-5c5ca57d2668',
'ms-cv': 'n11kCHlAAKC/E1xcpX0maA.0',
'strict-transport-security': 'max-age=31536000',
'x-frame-options': 'SAMEORIGIN',
'content-security-policy':
'frame-ancestors 'self' teams.microsoft.com *.teams.microsoft.com *.skype.com *.teams.microsoft.us local.teams.office.com;',
'x-powered-by': 'ASP.NET',
microsoftsharepointteamservices: '16.0.0.20203',
'x-content-type-options': 'nosniff',
'x-ms-invokeapp': '1; RequireReadOnly',
p3p:
'CP="ALL IND DSP COR ADM CONo CUR CUSo IVAo IVDo PSA PSD TAI TELo OUR SAMo CNT COM INT NAV ONL PHY PRE PUR UNI"',
date: 'Wed, 17 Jun 2020 20:58:43 GMT',
connection: 'close' }
REQUEST reading response's body
REQUEST finish init function https://honeywellprod.sharepoint.com/teams/HBS-Budgetary-Tool-DEV/_api/web/
REQUEST response end https://honeywellprod.sharepoint.com/teams/HBS-Budgetary-Tool-DEV/_api/web/ 403 { 'cache-control': 'private, max-age=0',
'transfer-encoding': 'chunked',
'content-type':
'application/json;odata=nometadata;streaming=true;charset=utf-8',
expires: 'Tue, 02 Jun 2020 20:58:43 GMT',
'last-modified': 'Wed, 17 Jun 2020 20:58:43 GMT',
server: 'Microsoft-IIS/10.0',
'x-sharepointhealthscore': '3',
'x-msdavext_error':
'917656; Access+denied.+Before+opening+files+in+this+location%2c+you+must+first+browse+to+the+web+site+and+select+the+option+to+login+automatically.',
dataserviceversion: '3.0',
'x-aspnet-version': '4.0.30319',
sprequestguid: '08645d9f-4079-a000-bf13-5c5ca57d2668',
'request-id': '08645d9f-4079-a000-bf13-5c5ca57d2668',
'ms-cv': 'n11kCHlAAKC/E1xcpX0maA.0',
'strict-transport-security': 'max-age=31536000',
'x-frame-options': 'SAMEORIGIN',
'content-security-policy':
'frame-ancestors 'self' teams.microsoft.com *.teams.microsoft.com *.skype.com *.teams.microsoft.us local.teams.office.com;',
'x-powered-by': 'ASP.NET',
microsoftsharepointteamservices: '16.0.0.20203',
'x-content-type-options': 'nosniff',
'x-ms-invokeapp': '1; RequireReadOnly',
p3p:
'CP="ALL IND DSP COR ADM CONo CUR CUSo IVAo IVDo PSA PSD TAI TELo OUR SAMo CNT COM INT NAV ONL PHY PRE PUR UNI"',
date: 'Wed, 17 Jun 2020 20:58:43 GMT',
connection: 'close' }
REQUEST end event https://honeywellprod.sharepoint.com/teams/HBS-Budgetary-Tool-DEV/_api/web/
REQUEST has body https://honeywellprod.sharepoint.com/teams/HBS-Budgetary-Tool-DEV/_api/web/ 201
REQUEST emitting complete https://honeywellprod.sharepoint.com/teams/HBS-Budgetary-Tool-DEV/_api/web/
Error: Access denied. You do not have permission to perform this action or access this resource.

Can you use the o365 --reconsent command and follow the link that it returns.
You will be asked to consent to the permissions that the PnP Office 365 Management Shell Azure AD application requires and it will list the permissions being requested, as the screenshot below shows.
Can you screenshot this screen and paste into this issue?

@souravkar123 are you still blocked or is the above information sufficient for you to continue?

Closing due to lack of response


text:
[BUG] - Adding Site Collection Admins using Set-PnPTenantSite throws unauthorized error

Notice
Many bugs reported are actually related to the PnP Framework which is used behind the scenes. Consider carefully where to report an issue:

Are you using Invoke-PnPSiteTemplate or Get-PnPSiteTemplate? The issue is most likely related to the Provisioning Engine. The Provisioning engine is not located in the PowerShell repo. Please report the issue here: https://github.com/pnp/pnpframework/issues.
Is the issue related to the cmdlet itself, its parameters, the syntax, or do you suspect it is the code of the cmdlet that is causing the issue? Then please continue reporting the issue in this repo.
If you think that the functionality might be related to the underlying libraries that the cmdlet is calling (We realize that might be difficult to determine), please first double check the code of the cmdlet, which can be found here: https://github.com/pnp/powershell/tree/master/src/Commands. If related to the cmdlet, continue reporting the issue here, otherwise report the issue at https://github.com/pnp/pnpframework/issues

Reporting an Issue or Missing Feature
Reporting an issue with setting owners for a sitecollection using Set-PnPTenantSite
Expected behavior
Adding a user with SharePoint Admin role to all the site collections as admin using Set-PnPTenantSite -Identity <> -Owners <> cmdlet
Actual behavior
Get an error "Set-PnPTenantSite: Attempted to perform an unauthorized operation."
Steps to reproduce behavior
Run under a context of user with SharePoint Admin role assigned
Use Connect-PnPOnline to connect to SiteCollection to which the admin should be added as SiteCollectionAdmin
Use Set-PnPTenantSite to add a user as SiteCollectionAdmin
Error : "Set-PnPTenantSite: Attempted to perform an unauthorized operation."
What is the version of the Cmdlet module you are running?
1.6.26-nightly
Which operating system/environment are you running PnP PowerShell on?

[ ] Windows
[ ] Linux
[ X] MacOS
[ ] Azure Cloud Shell
[ ] Azure Functions
[ ] Other : please specify

@sairao77 , @siddharth-vaghasia - I think this is by design as follows the same behavior as that in UI. You need to an admin of the site collection to add other admins.

@gautamdsheth   - In my case, I am first connecting to SharePoint Admin URL with user credential who is SharePoint Admin... and so ideally all future commands should run under the context of the SharePoint Admin....
Also, I can confirm that the same script and command works fine in the legacy module 'SharePointPnPPowerShellOnline'... For now, I have moved to the older module...it is just I think the same thing should supported in the new version also....
Function SetUserPermission(){
    try{
        Write-Host "Setting User Permission..." -ForegroundColor Yellow
        Connect-PnPOnline -Url https://tenant-admin.sharepoint.com/ -Credentials $Credentials
         Set-PnPTenantSite -Url https://tenant.sharepoint.com/sites/TestSiteWithoutAccess -Owners 'siddharth@tenant.onmicrosoft.com'
        Write-Host "Setting User Permission Successful..." -ForegroundColor Yellow
    }
    catch{
        Write-Host "Error in setting user permission'" $_.Exception.Message -ForegroundColor Red
    }
}

@gautamdsheth - Adding on to what @siddharth-vaghasia stated. According to the docs link below we would use Set-PnPTenantSite when we are not a site collection admin of the site and use Add-PnPSiteCollectionAdmin if we are already an admin on that SC.
[https://docs.microsoft.com/en-us/powershell/module/sharepoint-pnp/add-pnpsitecollectionadmin?view=sharepoint-ps]

I'm seeing this same behavior since updating to the latest Pnp.Powershell module. Previously this script worked fine, but now its throwing unauthorized even though I'm logged in as a Sharepoint Admin:
PS C:\PowerShell> Set-PnPTenantSite -Identity $OneDriveSiteUrl -Owners $adminEmail
Set-PnPTenantSite : The remote server returned an error: (401) Unauthorized.
At line:1 char:1

Set-PnPTenantSite -Identity $OneDriveSiteUrl -Owners $adminEmail

Something clearly changed in the last update, as with 1.6 it was working and now 1.7 is throwing this error, and my code hasn't changed.

I'm having the same Problem trying to update the sharing permissions for SiteCollections.
I'm running my Script under SharePoint App-only principal with tenant permissions
image
The script was running for month now but stopped working 2-5 days ago. With 401 error.
I even tried to create a new App permission, but it's giving me the same error.
I was able to pin-point the problem even further for me.
This call is working fine:
Set-PnPTenantSite -Identity https://$($tenantName).sharepoint.com/sites/$($EMail) -SharingAllowedDomainList "xxx.com,YYY.com" -SharingDomainRestrictionMode AllowList
but if I include -SharingCapability ExistingExternalUserSharingOnly as needed, I get a 401 message.
Seems to be really strange, that just one parameter isn't working, as of last week

The issue still can be reproduced by using the following cmdlet and throwing Unauthorized or Forbidden Error.
Set-PnPTenantSite -Identity https://domain.sharepoint.com/sites/mysite1 -Owners someemailaddress@onmicrosoft.com
Same with using Set-PnPSite
Set-PnPSite -Identity https://domain.sharepoint.com/sites/mysite1 -Owners someemailaddress@onmicrosoft.com
I hope this can be fix soon as we got stuff running in the background using the cmdlets

I'm experiencing the same issue. I'm using an account with SharePoint admin role and perform this action using UI but not PnP version 1.7.0
Use the following steps to reproduce the issue:

Connect-PnPOnline -Url "https://yourtenant-admin.sharepoint.com" -UseWebLogin (i'm using MFA enabled account)
Set-PnPTenantSite -Identity "https://yourtenant.sharepoint.com/sites/yoursite" -Owners "someone@yourtenant.com"

I get the following error:
Set-PnPTenantSite : The remote server returned an error: (403) Forbidden.

Any updates? It seems this has been open awhile now with no action or response. We are thinking of moving off of PnP back to SharePoint Online Module as we don't want to manually assign owners to 300 sites that have been created during the time we've been waiting for this to get addressed.

@TA1973 - This is a community driven module, so there's no ETA on resolving issues as we also have day jobs or unforeseen priorities, but we usually do our best. If the SharePoint Online module works, then that's at least an immediate solution for you. Feel free.

Issue has been fixed, please try with the latest nightly and reopen this if it still exists !

This was resolved as of version 1.8.0, but is somehow an issue again in v1.10.0. Was this fix inadvertently reverted?

This issue still exists in 1.12.0

I have the same issue in PnP.PowerShell 2.4.0 Version,
how to bypass this?
i need to add one group of my "SharePoint Online Admins" to all my site collection, someone know a workaround?

I've just started getting this issue today - it was working yesterday, I don't know what has changed.
PnP.PowerShell v2.4.0.

I thought I was having an issue with this, but it turns the LockState property on some of the SharePoint sites was set to "ReadOnly", so no changes could be made (including adding or removing admins).  Setting it back to "Unlock" got it working.

It's 2024, I'm on PnP 2.12.0, and I'm here searching for the same issue... Anyway, I managed to find a workaround.
Suppose you have PowerShell variables:

$adminCentreUrl: your admin centre, e.g. https://contoso-admin.sharepoint.com
$siteUrl: your site URL, e.g. https://contoso.sharepoint.com/teams/mysite
$clientId: client ID for use with PnP with appropriate permissions

You also need to know the GUID of the account or group you want to use, so you can build a claims account name.
Then you can try code like this:
Connect-PnPOnline $adminCentreUrl -Interactive -ClientId $clientId $siteAdminClaims = "c:0t.c|tenant|c560df76-1b93-405d-a379-6f12b8c1816b" $context = Get-PnPContext $tenant = New-Object Microsoft.Online.SharePoint.TenantAdministration.Tenant $context $context.Load($tenant) $context.ExecuteQuery() $tenant.SetSiteAdmin($siteUrl, $siteAdminClaims, $true) | Out-Null $context.ExecuteQuery()

source: gharchive/issue

authors: ADOrigin KashifMajeed24 LastGunslinger MrV8Rumble gautamdsheth mandrick91 ollimenzel repton-infinity sairao77 siddharth-vaghasia terriast vaderj veronicageek vinreel

repo: pnp/powershell

license: MIT

license_type: permissive

license_source: github-api


text:
Redirect web part fails if there are specific permissions on list items

Category

[x] Bug

Describe the bug
The Redirect extension works correctly when both the "PnP Redirect Links" list and list items therein do not have their permissions modified.
When list items have specific permissions (i.e. breaking inheritance and applying specific permissions to list items) then the Redirect extension fails.
Expected or Desired Behavior
Expected that the Redirect continues to work even with specific list item security.
Observed Behavior
Redirect fails with console message "Failed to create custom list PnP Redirect Links" when item level security is applied.
Steps to Reproduce
Install the Redirect extension and let it create the custom list.
Create two list items, each with same source URL and different destination URL's
Go to the source URL - Redirects correctly on the first "found" item.
Now, stop inheriting permissions on each item and only allow members of specific groups to see the list items.
When user logs in they can navigate to the custom list and they will only see ONE of the two items.
Redirect now fails with console message "Failed to create custom list PnP Redirect Links"
NOTE:  I have determined that the bug appears to be in the this line:
       const ensureResult: ListEnsureResult = await sp.web.lists.ensure(redirectionsListTitle,
       'Redirections',
        100,
        true);

The "ensure" method fails, even though the list exists for the user.
My workaround is to
a) allow the default extension to create the list in the first place
b) replace line 67
   if (await this.ensureRedirectionsList(redirectionsListTitle))

with
   if (true)

then build a new version of the extension
then deploy the extension
Environment Details (Development & Target environment)
SharePoint online

Since you have broken inheritence, can you confirm whether the users have access on the list level for READ, and not just the list item?

Hi and thanks for picking this up.
To confirm, users do have "Read" access to the list (Inheritance is not broken at list level - only at item level).
If I login as a user then they can see the list and open the list.
A user will see their single list item.
A site admin will see all the items in the list.

Thank you. I have looked into this a bit further, apologies for the delay. It appears the ensure() method requires elevated permissions, as users with READ permissions cannot use the Ensure() method.
We will need to update the code and remove and/or update the ensure method logic to better establish the existence of the list.

@eoverfield - I am going to put in a fix for this. As above, a user with "read" permission is unable to call the ensure() function. Question for you:
Would you prefer we...

Simplify the code and make an assumption that the list exists and is accurate (remove ensure())
Put in more logic to determine whether the current user can call the ensure() method, this could still result in a 404 for end users with Read.

My preference would be option a - to remove the ensure all together, given that if the list isn't set up correctly in the first place, a read user would still be unable to redirect.

repo: pnp/sp-starter-kit


text:
Update CORE to 1.9.2

Update instructions: https://github.com/poanetwork/poa-devops/blob/master/docs/Update-parity-version.md

[X] Migration playbook (https://github.com/poanetwork/poa-devops/blob/master/roles/upd-parity-version/tasks/main.yml):

[X] add cors section for bootnodes

[x] Update nodes (I round - less critical nodes):

[x] Bootnode-Archive
[x] Bootnode-Traces
[x] Explorer

[x] Update defaults in deployment playbooks repository (https://github.com/poanetwork/deployment-playbooks/pull/86):

[x] change default parity bin url to https://d1h4xl4cr1h0mo.cloudfront.net/v1.9.2/x86_64-unknown-linux-gnu/parity, checksum to 3604a030388cd2c22ebe687787413522106c697610426e09b3c5da4fe70bbd33
https://github.com/poanetwork/deployment-playbooks/blob/core/group_vars/all.network
https://github.com/poanetwork/deployment-playbooks/blob/core/group_vars/all.example
[x] include the following commits from sokol upgrade:
https://github.com/poanetwork/deployment-playbooks/commit/05b81aa09102e42cb3ddb7bdbc78dc181be442f8
https://github.com/poanetwork/deployment-playbooks/commit/16096823e6c3a321154215948a23d12abbbeb844

[x] Update nodes (II round - public rpc nodes and MoC):

[x] Bootnode A
[x] Bootnode B
[x] Bootnode C
[x] Bootnode D
[x] Bootnode MoC OVH
[x] Master of Ceremony

[x] Update nodes (III round - part of validators)

[x] Jeff Flowers
[x] Jim O'Regan
[x] John H LeGassic
[x] Roman Storm

[x] Notify BINANCE?

[ ] Update nodes (IV round - other bootnodes and validators):

[x] Bootnode Atlanta A
[ ] Bootnode Azure Brazil A
[x] Bootnode Chicago A
[x] Bootnode Chicago B
[x] Bootnode Chicago C
[x] Bootnode Dallas A
[x] Bootnode Frankfurt
[x] Bootnode Santa Clara
[ ] ~Bootnode_Paris~
[x] Bootnode_YTI
[x] Alex Emelyanov
[x] John D. Storey
[x] Lillian Chan
[x] Melanie Marsollier
[x] Michael Milirud
[x] Rocco Federico Mancini
[x] Sherina Hsuan Yang
[x] Stephen Arsenault
[x] Sviataslau Vishneuski

[ ] Update nodes (V round - backup)

[ ] Bootnode-HB

Update nodes III round - part of validators - Jim O'Regan Validator node updated Parity 1.9.2 03/13/2018
Update nodes IV round - other bootnodes and validators - POA Core Bootnode Chicago A, Bootnode Chicago B, Bootnode Chicago C all updated to Parity 1.9.2  03/13/2018

Updated.

[x] Bootnode Frankfurt

Bootnode_YTI updated

Update nodes (III round - part of validators) - John H LeGassic and Jeff Flowers nodes updated 03/14/2018

Update nodes Round III completed - can now notify Binance per outline.

@6proof it's not a HF, it's not mandatory to notify. But ty for mentioning

Thanks for the info Igor.  The notification was next in line and wasn't sure if the Github post was necessary to trigger an update.  Thanks again!

[ ] Bootnode Atlanta A
[ ] Bootnode Dallas A
[ ] Stephen Arsenault

All updated and verified!

My validator node is updated and verified.

Successfully updated

Successfully upgraded Sviataslau Vishneuski validator node to version Parity/v1.9.2-beta-0feb0bb-20180201/x86_64-linux-gnu/rustc1.23.0

Successfully upgraded Michael Milirud validator node to Parity/v1.9.2-beta-0feb0bb-20180201/x86_64-linux-gnu/rustc1.23.0

Checked Melanie's node

All done

authors: 6proof RoccoFMancini banteg hashguide henryvishnevsky igorbarinov micwebnet phahulin shkron youtweakit

repo: poanetwork/deployment-playbooks


text:
Testing Performance

Hi,
The endpoints in a project using this are slow. Averaging between 1000 and 1400 ms. I'm trying to understand where this time is being taken.
Within the functions themselves I have tested them with:
let start = Local::now();
...
let end = Local::now();
println!("Time taken to execute: {:?}", (end - start).num_milliseconds());

and they average between 100 - 140 ms which I would expect as it includes a sqlx query.
Any ideas as to how I would find where the slowdown is?
It's using poem openapi. So there are a few levels of abstraction that I'm not sure how to test.

After a bit more testing this seems to only be the case when not built in release mode. So not an issue. Would still like to know if there is a way to test this in the future if possible though.

repo: poem-web/poem


text:
Cancel in flight timers with the same id

As discussed in an issue not cancelling in flight timer with an existing ID is fairly unusual/unexpected behavior. This PR just sets the cancelInFlight parameter to true for the underlying timer effect.

My only concern with the change that it's somewhat breaking behavior altering change. Maybe there's a softer, more gradual (with deprecation warning first) introduction of such change? I don't have any code that could subtly change behavior due to this, but some developers might.

My only concern with the change that it's somewhat breaking behavior altering change. Maybe there's a softer, more gradual (with deprecation warning first) introduction of such change? I don't have any code that could subtly change behavior due to this, but some developers might.

Definitely would be less potentially disruptive to pass cancelInFlight as an explicit param and default it to false.

While it might be a breaking change, it seems unlikely that anyone relies on this behavior (though if there are use cases folks can think of or are taking advantage of, please let us know). We'll think on it over the weekend, though!

source: gharchive/pull-request

authors: andreyz dannyhertz stephencelis


text:
Fix state sharing bug in .dependency(_:_:) trait

When the .dependency(_:_:) function is used with a reference type to override the dependency for a test suite, tests can inadvertently share state because the same instance is used for each test:
@Suite(.serialized, .dependency(\.classClient, ClassClient()))
struct Example {
  @Test
  func test1() {
    @Dependency(\.classClient) var client
    client.count += 1
    #expect(client.count == 1)
  }

  @Test
  func test2() {
    @Dependency(\.classClient) var client
    client.count += 1
    #expect(client.count == 1) // 🛑 Expectation failed: (client.count → 2) == 1
  }
}

To fix this, this PR changes the value argument to be an @autoclosure so that a new instance can be created for each test. Let me know if there's an alternate solution that would be better!

Fixed in https://github.com/pointfreeco/swift-dependencies/pull/314

@TimHendricksenDD Sorry that we lost track of this fix and ended up reimplementing! Brandon and I have been traveling and it's been harder to keep track of everything in flight. Thanks for taking the time to dig into the problem and submit a patch all the same.

authors: TimHendricksenDD stephencelis

repo: pointfreeco/swift-dependencies


text:
SwiftUI have some offset on iOS 14.4 simulator

Hello everyone,
I noticed today that the snapshots produced by the iOS 14.4 simulator have an incorrect offset on the top.
To test this I created a completely new project with minimum deployment target of iOS 13, added the SnapshotTesting package via the swift package manager to the test target and copied the testSwiftUIView_iOS test from SnapshotTestingTests.swift. The results are as following:

With the simulator running iOS 14.4:

With the simulator running iOS 13.7:

Can it be that I am missing some configuration in the project? I am asking because running the tests from the cloned repo seems to work just fine.
An other observation I made is that the offset is dependent on the simulated device. For the iPod touch (7th generation) simulator running iOS 14.4 the offset is smaller then for the above tested iPhone 11.

I'm also seeing this issue, have you found a workaround?

No sadly I have not found a workaround, beside using the 13.7 simulator for now.

So it looks like the issue here is the ignoresSafeArea: property on UIHostingController. The built-in SwiftUI view snapshotting strategy wraps the SwiftUI view in a hosting controller but does not set this property to false. I have been able to get rid of this offset by explicitly wrapping my SwiftUI view in a hosting controller with ignoresSafeArea: set to true. Can you see if this works for you?

Am I missing something or why do I not have the UIHostingController initializer with the ignoreSafeArea: property?
But it also works by adding the .ignoreSafeArea() view modifier. Thanks a lot.

Ah, it looks like that's a custom extension we have within our project. I can't share the exact code but it seems to be based on this: https://gist.github.com/b8591340/97a8fb48822ac83e9e1cbbc746b258ef
If .ignoresSafeArea() works for you that's less hacky, it didn't work for me unfortunately.

Since this doesn't appear to be an issue with the library, I'm going to convert it to a discussion for now. If you believe this kind of thing can/should be addressed in the strategy, we'd be happy to discuss potential fixes there!

repo: pointfreeco/swift-snapshot-testing


text:
Maintainer to confirm "Completed" issue

Once an issue is closed with pledges behind it, we should prompt the maintainer (notification + email + in-app action) to confirm that it's considered completed incl. providing a custom note to backers (optional).
Todo

[x] Rename "Completed" to "Closed" for issues to map our language with Github (avoid cognitive overhead & confusion) #745
[ ] Introduce confirmation_pending on pledges for issues that have been closed
See this discussion for some good context about this design choice: https://github.com/polarsource/polar/issues/568  #750
[ ] Design how issues should be confirmed completed in dashboard / extension @petterheterjag
[ ] Implement the design
[ ] Send notification to maintainer once issues are closed with pledges – nudge for them to confirm completion

Design: https://www.figma.com/file/XyFpx0vdHk6bfWYLWmOHSC/Polar-Mega-File?type=design&node-id=2757-73650&t=UVPOj63BD7o8NKw3-4
Notes:

There are three parts of the prompt: a notification in the dashboard, a button added to the pledge part of the issue and an email (needs copy).
When pressed, the "Mark as solved" button should change styling and say "Marked as solved". We can work out how this should look together.

In back office, we can currently mark a pledge in state created as pending. How should we deal with this going forward? Seems like marking it as confirmation_pending has very little effect? Should we keep mark as pending, allowing back office to bypass confirmation_pending?

I think we should also rename these states. Not a priority now (scope creep too for this issue). Just a note to self for the future. I find they add cognitive overhead to grasp each time I review them, or just me? :-)

Absolutely agree about the renaming, super confusing

authors: birkjernstrom hult petterheterjag

repo: polarsource/polar


text:
ENH: Functional workflow

Following #7, this PR focuses on compatibility with the BOLD workflows.

I'm going to merge this in now so we aren't stuck in limbo, despite it not being fully functional yet.

repo: poldracklab/fmriprep-rodents


text:
(RTM/DOC) ReadTheDocs builds

here's the final version: http://fmriprep.readthedocs.io/en/doc/

Thanks!

authors: chrisfilo shoshber

repo: poldracklab/fmriprep


text:
Orbit.from_sbdb raises unhelpful error if no object was found

In [9]: Orbit.from_sbdb("67/P")
---------------------------------------------------------------------------
KeyError                                  Traceback (most recent call last)
<ipython-input-9-75d3da3ffd57> in <module>
----> 1 Orbit.from_sbdb("67/P")

~/.pyenv/versions/poliastro37_4/lib/python3.7/site-packages/poliastro/twobody/orbit.py in from_sbdb(cls, name, **kargs)
    572             )
    573
--> 574         a = obj["orbit"]["elements"]["a"].to(u.AU) * u.AU
    575         ecc = float(obj["orbit"]["elements"]["e"]) * u.one
    576         inc = obj["orbit"]["elements"]["i"].to(u.deg) * u.deg

KeyError: 'orbit'

It should give something more meaningful, like ValueError("Object 67/P not found")

I am on it

@iamabhishek0 I was working on it.:)

@priyanshurohilla As per my comment from 15 days ago:

On the other hand, it gives the impression that others should refrain to work on the issue, which is wrong.

I will be more explicit this time: blocking issues this way is not the correct attitude. Please refrain from doing so in the future.

@priyanshurohilla As per my comment from 15 days ago:

On the other hand, it gives the impression that others should refrain to work on the issue, which is wrong.

I will be more explicit this time: blocking issues this way is not the correct attitude. Please refrain from doing so in the future.

@astrojuanlu  understood.. Won't happen from now onwards 😊

Fixed in #919!

authors: astrojuanlu priyanshurohilla

repo: poliastro/poliastro


text:
T. Gestión del Sprint Backlog S8

[ ] Revisar que todas las tareas tengan todos los responsables (8 fases)
[ ] Verificar que las tareas corresponda a un milestrone
[ ] Asignar las historias que se encuentran pendientes por un responsable

Se alarga el sprint 8 una semana más

Se realizó revisión y seguimiento de las tareas e historias asignadas para dar cierre del proyecto

license_source: bigquery


text:
Sharing options?

I know we didn't include options to share for paella-ethz, but I'm surprised https://paellaplayer.upv.es/#/ doesn't have any sharing either - did you remove them completely? Or is this configurable?

We have sharing in Tobira, so that's not an issue anymore.

repo: polimediaupv/paella-ethz


text:
update all.json

"systemnodeautorepair.com",
"walletnoderepair.com",
"polkastarterweb.net",
"dapssolution.org",

This one is tricky, scam site impersonating Polkastarter but then it has "seed-stealing" page on Connect to server:

I decided to add it to block list but let me know if this needs to be removed.

That one seems 100% correct - there are a lot of pages now that looks legit, but they have seed stealing somewhere.

repo: polkadot-js/phishing


text:
[Bug]:

Checklist

[X] I believe this issue is a problem with polybar itself and not a misconfiguration on my part
[X] I have read the appropriate section in the contributing guidelines
[X] I have searched for other open and closed issues that may have already reported this problem
[X] I have checked the known issues page for this problem.
[X] I have followed the debugging guide to narrow down the problem to a minimal config.

Steps to reproduce
polybar
Minimal config
[network-base]
type = internal/network
interval = 5
format-connected = <label-connected>
format-disconnected = <label-disconnected>

[module/wlan]
inherit = network-base
interface-type = wireless
label-connected = 󰤨
label-disconnected = 󰤭

[module/eth]
inherit = network-base
interface-type = wired
label-connected = 󰈁
label-disconnected = 󰈂

Polybar log
󰈺 kaushiksahu18 ◉ polybar
notice: Parsing config file: /home/kaushiksahu18/.config/polybar/config.ini
notice: Listening for IPC messages (PID: 46435)
notice: Loading module 'xworkspaces' of type 'internal/xworkspaces'
notice: Loading module 'xwindow' of type 'internal/xwindow'
notice: Loading module 'filesystem' of type 'internal/fs'
notice: Loading module 'pulseaudio' of type 'internal/pulseaudio'
notice: pulseaudio: using default sink alsa_output.pci-0000_00_1b.0.analog-stereo
error: Disabling module "xkeyboard" (reason: Missing section "module/xkeyboard")
notice: Loading module 'memory' of type 'internal/memory'
notice: Loading module 'cpu' of type 'internal/cpu'
notice: Loading module 'wlan' of type 'internal/network'
notice: module/wlan: Discovered wireless interface wlan0
notice: Loading module 'eth' of type 'internal/network'
notice: module/eth: Discovered wired interface enp0s25
notice: Loading module 'date' of type 'internal/date'
notice: Loaded 9 modules
notice: Loaded font ""MesloLGS Nerd Font"" (name=Noto Sans, offset=2, file=/usr/share/fonts/noto/NotoSans-Regular.ttf)
warn: background_manager: Failed to get root pixmap, default to black (is there a wallpaper?)
warn: background_manager: Failed to get root pixmap, default to black (is there a wallpaper?)
warn: Dropping unmatched character '󰤭' (U+f092d) in '  󰤭'
warn: Dropping unmatched character '󰈂' (U+f0202) in '  󰈂'
warn: background_manager: Failed to get root pixmap, default to black (is there a wallpaper?)
warn: background_manager: Failed to get root pixmap, default to black (is there a wallpaper?)
warn: Dropping unmatched character '󰤨' (U+f0928) in '  󰤨'
warn: Dropping unmatched character '󰈂' (U+f0202) in '  󰈂'
warn: Dropping unmatched character '󰤨' (U+f0928) in '  󰤨'
warn: Dropping unmatched character '󰈂' (U+f0202) in '  󰈂'
warn: Dropping unmatched character '󰤨' (U+f0928) in '  󰤨'

Expected behavior
nerdfont icon should show up

i am using meslo nerdfont
font-0 = "MesloLGS Nerd Font";2

Actual behavior
nerdfont icons are not showing up
Window Manager and Version
mutter 46.1
Linux Distribution
EndeavourOS Linux x86_64
Polybar version
polybar 3.7.1

Features: +alsa +curl +i3 +mpd +network(libnl) +pulseaudio +xkeyboard

X extensions: +randr (+monitors) +composite +xkb +xrm +xcursor

Build type: Release
Compiler: /usr/bin/c++
Compiler flags: -march=x86-64 -mtune=generic -O2 -pipe -fno-plt -fexceptions         -Wp,-D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security         -fstack-clash-protection -fcf-protection -Wp,-D_GLIBCXX_ASSERTIONS -g -ffile-prefix-map=/build/polybar/src=/usr/src/debug/polybar -flto=auto -O3 -DNDEBUG -Wall -Wextra -Wpedantic -Wdeprecated-copy-dtor -Wsuggest-override
Linker flags: -Wl,-O1,--sort-common,--as-needed,-z,relro,-z,now -flto=auto -Wall -Wextra -Wpedantic -Wdeprecated-copy-dtor -Wsuggest-override  -Wall -Wextra -Wpedantic -Wdeprecated-copy-dtor -Wsuggest-override

Additional Context / Screenshots

notice: Loaded font ""MesloLGS Nerd Font"" (name=Noto Sans, offset=2, file=/usr/share/fonts/noto/NotoSans-Regular.ttf)

It didn't load the right font, it loaded Noto Sans. Try font-0 = "MesloLGS Nerd Font;2".
Otherwise you need to figure out how that font is called on your system. See also the font debugging guide

font-0 = "MesloLGS Nerd Font;2"

this worked thankyou

repo: polybar/polybar


text:
Readme Update - running tests depends on installed ffmpeg

Hey hey,
I was trying to run tests on my system where I didn't have ffmpeg installed and it was throwing a bit of obscured message like 'no such file or directory' in test_issue_39 and one other. It was because I was missing that dependency.
Would it be possible to add it to Readme somewhere please ?
Thank you

Oh yes, I can certainly do that!
I is probably also worth it to have this check be less cryptic :grimacing:

authors: jakubbalas polyfloyd


text:
new research spotlight PMID:30914423

Simple procedure for the generation of temperature-sensitive mutations with error-prone PCR

ALso
PMID:30914423
pretty much the same method

I have pushed both papers through together.
text:
Isolation of single amino acid t-s mutants in condensin hinge domain.

I have pushed both papers through together.

Should we have one Spotlight or two?  What was the PMID of the second paper?

ah sorry two.
PMID for second paper PMID:30914423

PMID for second paper PMID:30914423

Is that the PMID for the first image or the second image?

Good point :)
PMID:31042107 is the first

I've added those two Spotlights.

authors: ValWood kimrutherford

repo: pombase/website


text:
make build-js-production fails

root@cloud:/var/www/html/apps/peppol-php/nextcloud-app/peppolnext# make build-js-production
npm run build

> peppolnext@19.0.0 build
> webpack --node-env production --progress

[webpack-cli] Failed to load '/var/www/html/apps/peppol-php/nextcloud-app/peppolnext/webpack.config.js' config
[webpack-cli] Error: Cannot find module 'vue/compiler-sfc'

@navid-dada can you have a look at cloud.pondersource.org and see if you can fix the issue there?

repo: pondersource/peppol-php


text:
Flutter Toast not looking same in android devices its show a flutter icon also

I am using the following method to show toast in the flutter app It works perfectly on ios side but in android, it's not working as same its shows a logo of the flutter icon or does not change the background color please check the attached image.
Android image Link: Android Screenshot
Ios image Lins: iOS Screenshot
  static void showToast({required String message}) {
    Fluttertoast.showToast(
        msg: message,
        toastLength: Toast.LENGTH_SHORT,
        gravity: ToastGravity.BOTTOM,
        timeInSecForIosWeb: 1,
        backgroundColor: Colors.black,
        textColor: Colors.white,
        fontSize: 16.0);
  }

Hi @alok2811 , according to this package's latest readme, it says the following
"Custom Toast will not work on android 11 and above, it will only use msg and toastLength remaining all properties are ignored"
I believe this is why it works perfectly on iOS but not in android.

@ngjunya Thank you for the kind reply can you please suggest what I can do or move with another package?
@ponnamkarthik Sir can you please tell me when it is resolved?

@alok2811 Welcome. While waiting it to be resolved, you can try out this package -> https://pub.dev/packages/flutter_styled_toast. This toast package allows you to create customised toast message. The only difference is this toast package requires build context.

@alok2811 : How do we show app icon on iOS?

repo: ponnamkarthik/FlutterToast


text:
在poi 10.0.0的Dark主题下，是否满足远征条件的高亮失效

如图，Dark主题下不能直观区分

顺便，Light主题下正常

已知问题. 会抽空调整.

authors: Javran Sunev

repo: poooi/poi-plugin-ezexped

license: mit


text:
Real time data in dashboard

in admin dashboard display realtime data
Fixes # (issue)
#342
Type of change
Please give a X on it which is applicable

[x] Bug fix (non-breaking change which fixes an issue)
[x] New feature (non-breaking change which adds functionality)
[ ] Refactor Code
[ ] A documentation update
[ ] Others(mentioned in the issue number)

Screenshots and Videos:

Checklist:
Give a X on, which is applicable

[x] My code follows the style guidelines of this project
[x] I have performed a self-review of my code
[x]I have commented my code, particularly in hard-to-understand areas
[x] I have made corresponding changes to the documentation
[x] My changes generate no new warnings
[x] I have added tests that prove my fix is effective or that my feature works
[x] New and existing unit tests pass locally with my changes
[x] Any dependent changes have been merged and published in downstream modules

@pooranjoyb , review it and if you want to any changes then inform me

Recent Custome ,store overview and checkout data comes from supabase

Recent Custome ,store overview and checkout data comes from supabase

Okay do one thing, list down the features you integrated in Admin Dashboard. @Varsani2520

@pooranjoyb
i fetched data from supabase :
list are:
Recent Customer ,
store overview and
checkout data

@pooranjoyb ,please give me update
if you have any query then tell me i solved that

@pooranjoyb ,any update @pooranjoyb

@pooranjoyb give the response

@pooranjoyb give the response

Hey @Varsani2520 Really sorry I was traveling for few days. :/

repo: pooranjoyb/popShop


text:
Made a cleaner interface with the vga writer

The vga buffer module was bloated with functions that did almost the same thing. So i made a CommandToVgaWriter enum that specifies what should vga writer do.

will check later if someone else doesnt, bit busy rn

I'm merging it?

authors: SparkySimp TadoTheMiner electron271

repo: popcorn-kernel/popcorn


text:
feat: basic fixed strategy support [2.0]

For my use case I use the fixed strategy since I mount the poppers inside of a portal (to prevent z-index) issues.
I initially went down this path, but it's beginning to seem that the strategy might need to flow down into getElementClientRect instead, which seems like a much bigger feat change

Thanks so much for the PR!
Is it really that easy? 🧐
May you try to switch to the fixed strategy in the other visual tests and see if they still behave properly?

It's not working with the scrolling container tests

Our current getElementClientRect behavior works for fixed for all scrolling tests except for offset-parent.html.
I managed to solve it like this for fixed:

Don't take subtract directOffsetParent rect
Include the first offsetParent in the ancestorOffsetParents array

export default (
  element: Element | VirtualElement,
  // pass in the strategy
  isFixed: boolean = false
): Rect => {
  // ...
  // I think we only need one window stored here to check
  const win = getWindow(unwrappedElement);

  const directOffsetParentRect =
    directOffsetParent instanceof win.Element && !isFixed
      ? getBoundingClientRect(directOffsetParent)
      : { left: 0, top: 0 };

  const ancestorOffsetParents = isFixed ? [directOffsetParent] : [];
  let currentOffsetParent = directOffsetParent;

  while (currentOffsetParent instanceof win.Element) {
    currentOffsetParent = getOffsetParent(currentOffsetParent);
    ancestorOffsetParents.push(currentOffsetParent);
  }

  // ...
};

Should fixed be the default positioning strategy? What are the differences besides the popper not being affected by clipping parents (which seems like a good thing)? That behavior may be wanted in some cases where the user can choose absolute.

absolute is generally more preformant, in the simplest cases it doesn’t need to reposition the popper on each scroll.
We could automatically change strategy based on the detected environment though.

Actually the more I think about it, the more it's unclear to me what getElementClientRect does--getBoundingClientRect already gets the position relative to the viewport, taking into account scroll, while for offsets relative to the parent, there's offsetLeftandoffsetTop`. What does the summing of the ancestral scroll do?

offsetTop and offsetLeft don't work when the element has transforms or for SVG elements

getBoundingClientRect returns the offsets relative to the viewport, not to the whole document.

I'm going to close this since I just merged #868 that does the same thing, thank you again for the help with the initial implementation!!

thanks so much @FezVrasta  and @atomiks !

authors: FezVrasta Joelkang atomiks


text:
All validation errors for a single value?

ValidateAll does early exit when the first validator rejects the value, is there a feature that would generate messages for all the validation errors for a single value?
For example:
{
 username: 'required|alpha_numeric|min:6|max:15'
}

0!aa:
Username must be alphanumeric
Username must be at least 6 characters long

Will add that functionality too

authors: Gratiandev thetutlage

repo: poppinss/indicative


text:
Add new script to zip GCS file trees and upload them to Zenodo

Run via analysis-runner so it has direct access to our buckets, zips via Python's zipfile library, and uploads directly to a (pre-made) Zenodo deposit via Zenodo's API.
Context: https://centrepopgen.slack.com/archives/C018KFBCR1C/p1730142264294839?thread_ts=1728943125.475979&cid=C018KFBCR1C

@dancoates It's a good point — In this case, there's ~15,000 files going in to each zip archive, for a total of almost 400,000. I don't have much test data in a test bucket, so I guess the thing to do will be to merge it and see what happens… 🤞

repo: populationgenomics/analysis-runner


text:
Make OAuth glue less opinionated

The OAuth glue in the External authentication extension has a static value for the prompt parameter in the Authorize call. From strings(1):
response_type=code&client_id=%s&redirect_uri=%s&scope=%s&prompt=login

According to the OIDC spec, prompt=login SHOULD cause the IdP to ask the user to re-authenticate, even if the user is already authenticated. In the case of Okta, it does just that.
I'm not sure if there's any particular rationale behind the extra prompt? It seems that just dropping the prompt option altogether would leave the decision to the IdP and whatever policy one has applied to it. This would be consistent with how other OIDC RP's implement it.

@xAt0mZ what are your thoughts on this? I could see this as a useful enhancement

Regarding file history, it has been introduced by commit d510d23 for Azure OAuth.
Remember why you did it this way @deviantony ?
As prompt is an optional param, if there is no specific reason to keep it we can definitely remove.

Regarding file history, it has been introduced by commit d510d23 for Azure OAuth.
Remember why you did it @deviantony ?
As prompt is an optional param, if there is no specific reason to keep it, it can be removed.

so IIRC this was originally added because one of the provider would not work without it. Might have been the Azure one then.
It might be good to try to remove it and see if Azure still works.

Please just make this a configurable option in the OAuth configuration with the rest. Something like "prompt" and a dropdown with ["none", "login"].
The behavior today breaks the SSO experience.
I saw AAD was mentioned. Please let me know if you have questions about AAD.

Please just make this a configurable option in the OAuth configuration with the rest. Something like "prompt" and a dropdown with ["none", "login"].
The behavior today breaks the SSO experience.
I saw AAD was mentioned. Please let me know if you have questions about AAD.

This should have been resolved by https://github.com/portainer/portainer/issues/5182

authors: deviantony huib-portainer itsconquest kandsten timcappalli xAt0mZ

repo: portainer/portainer

license: Zlib


text:
"This stack was created outside of Portainer. Control over this stack is limited"

Bug description
Since a few weeks i wanted to create a new Stack
After clicking Deploy stack, the error came up
Stacks are there with comment "This stack was created outside of Portainer. Control over this stack is limited."
This means, that inbetween "Add new Stack" and "Deploy Stack" some sort of stack with the same name is created, what inhibits the stack to be deployed
The stack is DEFINETLY created by portainer but portainder behaves like it was another service
Reference:
https://github.com/portainer/portainer/issues/4939
ametdoohan
balasu
keverv
Expected behavior
Creating stacks should not be a problem
Portainer Logs
Provide the logs of your Portainer container or Service.
You can see how here

INFO 2022/03/04 18:50:57 Loading PortainerDB: portainer.db
INFO 2022/03/04 18:51:03 Opened existing store
2022/03/04 18:51:03 server: Reverse tunnelling enabled
2022/03/04 18:51:03 server: Fingerprint e3:e6:4d:ae:d2:10:e4:aa:8f:a4:d9:8d:37:38:54:63
2022/03/04 18:51:03 server: Listening on 0.0.0.0:8000...
INFO 2022/03/04 18:51:03 [INFO] [cmd,main] Starting Portainer version 2.11.1

level=info msg="2022/03/04 18:51:03 [DEBUG] [chisel, monitoring] [check_interval_seconds: 10.000000] [message: starting tunnel management process]"
level=info msg="2022/03/04 18:51:03 [DEBUG] [internal,init] [message: start initialization monitor ]"
level=info msg="2022/03/04 18:51:03 [INFO] [http,server] [message: starting HTTPS server on port :9443]"
level=info msg="2022/03/04 18:51:39 http: TLS handshake error from 192.168.178.20:40792: remote error: tls: unknown certificate"
level=info msg="2022/03/04 18:51:40 http error: A valid authorisation token is missing (err=Unauthorized) (code=401)"
level=info msg="2022/03/04 18:51:40 http error: A valid authorisation token is missing (err=Unauthorized) (code=401)"
level=info msg="2022/03/04 18:51:40 http error: A valid authorisation token is missing (err=Unauthorized) (code=401)"
level=info msg="2022/03/04 19:05:44 [libstack,composebinary] [message: finish deploying] [output: milestone-alpine: Pulling from openhab/openhab"
level=info msg="Digest: sha256:ec7db7aa30d39499a6fd66752e5e90bf7ad8dae53e8f99b1119df86218936242"
level=info msg="Status: Downloaded newer image for openhab/openhab:milestone-alpine"
level=info msg="] [err: %!s(<nil>)]"
level=info msg="2022/03/04 19:10:21 http: TLS handshake error from 192.168.178.20:40796: remote error: tls: unknown certificate"
level=info msg="2022/03/04 19:13:23 http: TLS handshake error from 192.168.178.20:40800: remote error: tls: unknown certificate"
level=info msg="2022/03/04 21:37:47 http: TLS handshake error from 192.168.178.20:40814: remote error: tls: unknown certificate"
level=info msg="2022/03/04 21:42:55 [libstack,composebinary] [message: finish deploying] [output: latest: Pulling from pihole/pihole"
level=info msg="Digest: sha256:60a9127372b0f7bb4b5eb09bc95e2735eb7b237999acf4bb079eb14b0f14632e"
level=info msg="Status: Downloaded newer image for pihole/pihole:latest"
level=info msg="] [err: %!s(<nil>)]"
level=info msg="2022/03/05 09:29:24 http: TLS handshake error from 192.168.178.20:52712: remote error: tls: unknown certificate"
level=info msg="2022/03/05 09:29:24 http: TLS handshake error from 192.168.178.20:52714: remote error: tls: unknown certificate"
level=info msg="2022/03/05 09:29:25 http error: A valid authorisation token is missing (err=Unauthorized) (code=401)"
level=info msg="2022/03/05 09:41:10 http error: failed to deploy a stack: Creating network \"adguard_default\" with the default driver"
level=info msg="Pulling adguard (adguard/adguardhome:latest)..."
level=info msg="Creating adguard ... "
level=info msg="Host is already in use by another container"
level=info msg="\x1b[1A\x1b[2K\rCreating adguard ... \x1b[31merror\x1b[0m\r\x1b[1B"
level=info msg="ERROR: for adguard  Cannot start service adguard: driver failed programming external connectivity on endpoint adguard (dd323976e90b5b20cc1c79cdc4fe16ecfbcb92e5e60973892babe640b11dcbdc): Bind for 0.0.0.0:3000 failed: port is already allocated"
level=info
level=info msg="ERROR: for adguard  Cannot start service adguard: driver failed programming external connectivity on endpoint adguard (dd323976e90b5b20cc1c79cdc4fe16ecfbcb92e5e60973892babe640b11dcbdc): Bind for 0.0.0.0:3000 failed: port is already allocated"
level=info msg="Encountered errors while bringing up the project."
level=info msg=": exit status 1 (err=failed to deploy a stack: Creating network \"adguard_default\" with the default driver"
level=info msg="Pulling adguard (adguard/adguardhome:latest)..."
level=info msg="Creating adguard ... "
level=info msg="Host is already in use by another container"
level=info msg="\x1b[1A\x1b[2K\rCreating adguard ... \x1b[31merror\x1b[0m\r\x1b[1B"
level=info msg="ERROR: for adguard  Cannot start service adguard: driver failed programming external connectivity on endpoint adguard (dd323976e90b5b20cc1c79cdc4fe16ecfbcb92e5e60973892babe640b11dcbdc): Bind for 0.0.0.0:3000 failed: port is already allocated"
level=info
level=info msg="ERROR: for adguard  Cannot start service adguard: driver failed programming external connectivity on endpoint adguard (dd323976e90b5b20cc1c79cdc4fe16ecfbcb92e5e60973892babe640b11dcbdc): Bind for 0.0.0.0:3000 failed: port is already allocated"
level=info msg="Encountered errors while bringing up the project."
level=info msg=": exit status 1) (code=500)"
ERROR 2022/03/05 09:41:20 Failed to convert to Stack object
level=info msg="2022/03/05 09:41:20 http error: A stack with the normalized name 'adguard' already exists (err=A stack with the normalized name 'adguard' already exists) (code=409)"
ERROR 2022/03/05 09:44:13 Failed to convert to Stack object
level=info msg="2022/03/05 09:44:13 http error: A stack with the normalized name 'adguard' already exists (err=A stack with the normalized name 'adguard' already exists) (code=409)"
ERROR 2022/03/05 09:46:17 Failed to convert to Stack object
level=info msg="2022/03/05 09:46:17 http error: A stack with the normalized name 'adguard' already exists (err=A stack with the normalized name 'adguard' already exists) (code=409)"
level=info msg="2022/03/05 09:48:34 http error: failed to deploy a stack: Creating network \"adguardhome_default\" with the default driver"
level=info msg="Creating adguardhome ... "
level=info msg="Host is already in use by another container"
level=info msg="\x1b[1A\x1b[2K\rCreating adguardhome ... \x1b[31merror\x1b[0m\r\x1b[1B"
level=info msg="ERROR: for adguardhome  Cannot start service adguardhome: driver failed programming external connectivity on endpoint adguardhome (8826be064aeb57d4271105a8a9b71e14545eb618aaaf2571b5ab0dc7d5e231d3): Error starting userland proxy: listen tcp4 0.0.0.0:443: bind: address already in use"
level=info
level=info msg="ERROR: for adguardhome  Cannot start service adguardhome: driver failed programming external connectivity on endpoint adguardhome (8826be064aeb57d4271105a8a9b71e14545eb618aaaf2571b5ab0dc7d5e231d3): Error starting userland proxy: listen tcp4 0.0.0.0:443: bind: address already in use"
level=info msg="Encountered errors while bringing up the project."
level=info msg=": exit status 1 (err=failed to deploy a stack: Creating network \"adguardhome_default\" with the default driver"
level=info msg="Creating adguardhome ... "
level=info msg="Host is already in use by another container"
level=info msg="\x1b[1A\x1b[2K\rCreating adguardhome ... \x1b[31merror\x1b[0m\r\x1b[1B"
level=info msg="ERROR: for adguardhome  Cannot start service adguardhome: driver failed programming external connectivity on endpoint adguardhome (8826be064aeb57d4271105a8a9b71e14545eb618aaaf2571b5ab0dc7d5e231d3): Error starting userland proxy: listen tcp4 0.0.0.0:443: bind: address already in use"
level=info
level=info msg="ERROR: for adguardhome  Cannot start service adguardhome: driver failed programming external connectivity on endpoint adguardhome (8826be064aeb57d4271105a8a9b71e14545eb618aaaf2571b5ab0dc7d5e231d3): Error starting userland proxy: listen tcp4 0.0.0.0:443: bind: address already in use"
level=info msg="Encountered errors while bringing up the project."
level=info msg=": exit status 1) (code=500)"
ERROR 2022/03/05 09:49:59 Failed to convert to Stack object
level=info msg="2022/03/05 09:49:59 http error: A stack with the normalized name 'adguardhome' already exists (err=A stack with the normalized name 'adguardhome' already exists) (code=409)"
level=info msg="2022/03/05 09:50:19 http error: failed to deploy a stack: Creating adguard ... "
level=info msg="Host is already in use by another container"
level=info msg="\x1b[1A\x1b[2K\rCreating adguard ... \x1b[31merror\x1b[0m\r\x1b[1B"
level=info msg="ERROR: for adguard  Cannot start service adguard: driver failed programming external connectivity on endpoint adguard (0b20f87974ea6f5fc87f759216d8b5bb953940879183f0e5091dcbd8a76446d5): Error starting userland proxy: listen tcp4 0.0.0.0:443: bind: address already in use"
level=info
level=info msg="ERROR: for adguard  Cannot start service adguard: driver failed programming external connectivity on endpoint adguard (0b20f87974ea6f5fc87f759216d8b5bb953940879183f0e5091dcbd8a76446d5): Error starting userland proxy: listen tcp4 0.0.0.0:443: bind: address already in use"
level=info msg="Encountered errors while bringing up the project."
level=info msg=": exit status 1 (err=failed to deploy a stack: Creating adguard ... "
level=info msg="Host is already in use by another container"
level=info msg="\x1b[1A\x1b[2K\rCreating adguard ... \x1b[31merror\x1b[0m\r\x1b[1B"
level=info msg="ERROR: for adguard  Cannot start service adguard: driver failed programming external connectivity on endpoint adguard (0b20f87974ea6f5fc87f759216d8b5bb953940879183f0e5091dcbd8a76446d5): Error starting userland proxy: listen tcp4 0.0.0.0:443: bind: address already in use"
level=info
level=info msg="ERROR: for adguard  Cannot start service adguard: driver failed programming external connectivity on endpoint adguard (0b20f87974ea6f5fc87f759216d8b5bb953940879183f0e5091dcbd8a76446d5): Error starting userland proxy: listen tcp4 0.0.0.0:443: bind: address already in use"
level=info msg="Encountered errors while bringing up the project."
level=info msg=": exit status 1) (code=500)"
ERROR 2022/03/05 09:52:44 Failed to convert to Stack object
level=info msg="2022/03/05 09:52:44 http error: A stack with the normalized name 'adguardhome' already exists (err=A stack with the normalized name 'adguardhome' already exists) (code=409)"
INFO 2022/03/05 09:57:20 Encryption key file `portainer` not present
INFO 2022/03/05 09:57:20 Proceeding without encryption key
INFO 2022/03/05 09:57:20 Loading PortainerDB: portainer.db
INFO 2022/03/05 09:57:27 Opened existing store
2022/03/05 09:57:28 server: Reverse tunnelling enabled
2022/03/05 09:57:28 server: Fingerprint e3:e6:4d:ae:d2:10:e4:aa:8f:a4:d9:8d:37:38:54:63
2022/03/05 09:57:28 server: Listening on 0.0.0.0:8000...
INFO 2022/03/05 09:57:28 [INFO] [cmd,main] Starting Portainer version 2.11.1

level=info msg="2022/03/05 09:57:28 [DEBUG] [chisel, monitoring] [check_interval_seconds: 10.000000] [message: starting tunnel management process]"
level=info msg="2022/03/05 09:57:28 [DEBUG] [internal,init] [message: start initialization monitor ]"
level=info msg="2022/03/05 09:57:28 [INFO] [http,server] [message: starting HTTPS server on port :9443]"
level=info msg="2022/03/05 10:03:21 http: TLS handshake error from 192.168.178.20:52718: remote error: tls: unknown certificate"
level=info msg="2022/03/05 10:03:22 http error: A valid authorisation token is missing (err=Unauthorized) (code=401)"
level=info msg="2022/03/05 10:03:22 http error: A valid authorisation token is missing (err=Unauthorized) (code=401)"
level=info msg="2022/03/05 10:03:22 http error: A valid authorisation token is missing (err=Unauthorized) (code=401)"

Steps to reproduce the issue:

Go to Stacks
Click on Add Stack
Instert docker-compose credentials and stack name
Click Deploy
Error occurs

Technical details:

Portainer version: 2.11.1

Client: Docker Engine - Community
Version:           20.10.12
API version:       1.41
Go version:        go1.16.12
Git commit:        e91ed57
Built:             Mon Dec 13 11:45:37 2021
OS/Arch:           linux/amd64
Context:           default
Experimental:      true
Server: Docker Engine - Community
Engine:
Version:          20.10.12
API version:      1.41 (minimum version 1.12)
Go version:       go1.16.12
Git commit:       459d0df
Built:            Mon Dec 13 11:43:46 2021
OS/Arch:          linux/amd64
Experimental:     false
containerd:
Version:          1.4.12
GitCommit:        7b11cfaabd73bb80907dd23182b9347b4245eb5d
runc:
Version:          1.0.2
GitCommit:        v1.0.2-0-g52b36a2
docker-init:
Version:          0.19.0
GitCommit:        de40ad0

Platform (windows/linux): TrueNAS SCALE (Debian) with using custom Docker configuration "Vanilla Docker"
Command used to start Portainer (docker run -p 9443:9443 portainer/portainer):

docker run -d -p 8000:8000 -p 9443:9443 --name portainer
--restart=always
-v /var/run/docker.sock:/var/run/docker.sock
-v portainer_data:/data
portainer/portainer-ce:latest

Browser: Vivaldi
Use Case (delete as appropriate): Using Portainer at Home, Using Portainer in a Commercial setup. --> At home on TrueNAS Server in Docker
Have you reviewed our technical documentation and knowledge base? Yes

Additional context
Add any other context about the problem here.
I hope this is not a Problem with my personal environment, but it worked now for weeks, so i dont think, that a problem in "only" generating and deploying a new stack ...

OK this was only caused, because of the stack not being deployed due to port-settings
The strange thing is, that the error messages (for me) did not exactly point to the root-cause

OK this was only caused, because of the stack not being deployed due to port-settings The strange thing is, that the error messages (for me) did not exactly point to the root-cause

Could you be more precise ? What port setting are you talking about exactly ? I am having the same problem for months now and can't find a working solution.

authors: LeVraiRoiDHyrule SHU-red


text:
Use bleach to sanitize HTML; allows use with newer versions of html5lib.

Fixes #296
This patch is needed to fix the Debian packaging as Debian already ships a newer version of html5lib, which no longer supports sanitizing. I'm submitting this PR in case you also want to ship this upstream.

Tests with Python2.6 fail with this PR, because bleach no longer supports Python 2.6. https://github.com/mozilla/bleach/issues/275

Since support for py 2.6 has been dropped, can this PR be reconsidered?

I've reopened the pull request here: https://github.com/posativ/isso/pull/483
However, master seems to have a lot of test failures at the moment so those will need to be addressed first.

@jelmer wow I just noticed you are isso's maintainer for debian as well. The isso package on debian is 1-year-old now, so I've been trying to create an updated package using current master. However, I only realised I will have to do a NMU (plus finding a mentor) after I got most of it working. What do you think would be the most suitable next step for me?

On Fri, Sep 28, 2018 at 08:18:18AM +0000, gloomy-ghost wrote:

@jelmer wow I just noticed you are isso's maintainer for debian as well. The isso package on debian is 1-year-old now, so I've been trying to create an updated package using current master. However, I only realised I will have to do a NMU (plus finding a mentor) after I got most of it working. What do you think would be the most suitable next step for me?
If you get the package in a reasonable shape for an upload, I'd be
happy to sponsor.

--
Jelmer Vernooĳ jelmer@jelmer.uk
PGP Key: https://www.jelmer.uk/D729A457.asc

uploaded at https://mentors.debian.net/package/isso
I couldn't get r.js to be happy with debian's jade packed in commonjs, but I suppose it's better than a use upstream...

I couldn't get r.js to be happy with debian's jade packed in commonjs, but I suppose it's better than a use upstream...

it works now :smile:

authors: gloomy-ghost jelmer

repo: posativ/isso


text:
Add the fmt_url() method

This adds the fmt_url() method, which allows for the formatting of cells that contain URLs. This method can be used to transform the text into navigable links. This should ideally be used on columns that contain only URL text (i.e., no URLs as part of a larger block of text).
Fixes: https://github.com/posit-dev/great-tables/issues/80

pairing w/ Rich -- we'll revisit down the road

authors: machow rich-iannone

repo: posit-dev/great-tables


text:
IP authentication - errors [doesn't work]

I'm trying to use the SMTP-IP feature but I think I hit a bug
I've created a profile for SMTP-IP and assigned just for test an IP and this is how it's saved

Bellow is the info from database.

And the logs from smtp_server.log
[smtp.1:14414] [2020-12-10T11:14:43.162] ERROR -- : [QQ19CC] An error occurred while processing data from a client.
[smtp.1:14414] [2020-12-10T11:14:43.162] ERROR -- : [QQ19CC] NoMethodError: undefined method `prefix' for #<IPAddr: IPv4:192.168.3.100/255.255.255.255>
[smtp.1:14414] [2020-12-10T11:14:43.163] ERROR -- : [QQ19CC] /opt/postal/app/lib/postal/smtp_server/client.rb:317:in `block in rcpt_to'
[smtp.1:14414] [2020-12-10T11:14:43.164] ERROR -- : [QQ19CC] /opt/postal/vendor/bundle/ruby/2.3.0/gems/activerecord-5.2.4.3/lib/active_record/relation/delegation.rb:71:in `each'
[smtp.1:14414] [2020-12-10T11:14:43.164] ERROR -- : [QQ19CC] /opt/postal/vendor/bundle/ruby/2.3.0/gems/activerecord-5.2.4.3/lib/active_record/relation/delegation.rb:71:in `each'
[smtp.1:14414] [2020-12-10T11:14:43.165] ERROR -- : [QQ19CC] /opt/postal/app/lib/postal/smtp_server/client.rb:317:in `sort_by'
[smtp.1:14414] [2020-12-10T11:14:43.166] ERROR -- : [QQ19CC] /opt/postal/app/lib/postal/smtp_server/client.rb:317:in `rcpt_to'
[smtp.1:14414] [2020-12-10T11:14:43.166] ERROR -- : [QQ19CC] /opt/postal/app/lib/postal/smtp_server/client.rb:79:in `handle_command'
[smtp.1:14414] [2020-12-10T11:14:43.167] ERROR -- : [QQ19CC] /opt/postal/app/lib/postal/smtp_server/client.rb:50:in `handle'
[smtp.1:14414] [2020-12-10T11:14:43.168] ERROR -- : [QQ19CC] /opt/postal/app/lib/postal/smtp_server/server.rb:160:in `block (2 levels) in run_event_loop'
[smtp.1:14414] [2020-12-10T11:14:43.169] ERROR -- : [QQ19CC] /opt/postal/app/lib/postal/smtp_server/server.rb:87:in `select'
[smtp.1:14414] [2020-12-10T11:14:43.170] ERROR -- : [QQ19CC] /opt/postal/app/lib/postal/smtp_server/server.rb:87:in `block in run_event_loop'
[smtp.1:14414] [2020-12-10T11:14:43.171] ERROR -- : [QQ19CC] /opt/postal/app/lib/postal/smtp_server/server.rb:85:in `loop'
[smtp.1:14414] [2020-12-10T11:14:43.172] ERROR -- : [QQ19CC] /opt/postal/app/lib/postal/smtp_server/server.rb:85:in `run_event_loop'
[smtp.1:14414] [2020-12-10T11:14:43.172] ERROR -- : [QQ19CC] /opt/postal/app/lib/postal/smtp_server/server.rb:260:in `run'
[smtp.1:14414] [2020-12-10T11:14:43.173] ERROR -- : [QQ19CC] /opt/postal/app/lib/tasks/postal.rake:13:in `block (2 levels) in <top (required)>'
[smtp.1:14414] [2020-12-10T11:14:43.174] ERROR -- : [QQ19CC] /opt/postal/vendor/bundle/ruby/2.3.0/gems/rake-12.3.3/lib/rake/task.rb:273:in `block in execute'
[smtp.1:14414] [2020-12-10T11:14:43.174] ERROR -- : [QQ19CC] /opt/postal/vendor/bundle/ruby/2.3.0/gems/rake-12.3.3/lib/rake/task.rb:273:in `each'
[smtp.1:14414] [2020-12-10T11:14:43.175] ERROR -- : [QQ19CC] /opt/postal/vendor/bundle/ruby/2.3.0/gems/rake-12.3.3/lib/rake/task.rb:273:in `execute'
[smtp.1:14414] [2020-12-10T11:14:43.176] ERROR -- : [QQ19CC] /opt/postal/vendor/bundle/ruby/2.3.0/gems/rake-12.3.3/lib/rake/task.rb:214:in `block in invoke_with_call_chain'
[smtp.1:14414] [2020-12-10T11:14:43.177] ERROR -- : [QQ19CC] /usr/lib/ruby/2.3.0/monitor.rb:214:in `mon_synchronize'
[smtp.1:14414] [2020-12-10T11:14:43.177] ERROR -- : [QQ19CC] /opt/postal/vendor/bundle/ruby/2.3.0/gems/rake-12.3.3/lib/rake/task.rb:194:in `invoke_with_call_chain'
[smtp.1:14414] [2020-12-10T11:14:43.178] ERROR -- : [QQ19CC] /opt/postal/vendor/bundle/ruby/2.3.0/gems/rake-12.3.3/lib/rake/task.rb:183:in `invoke'
[smtp.1:14414] [2020-12-10T11:14:43.178] ERROR -- : [QQ19CC] /opt/postal/vendor/bundle/ruby/2.3.0/gems/rake-12.3.3/lib/rake/application.rb:160:in `invoke_task'
[smtp.1:14414] [2020-12-10T11:14:43.179] ERROR -- : [QQ19CC] /opt/postal/vendor/bundle/ruby/2.3.0/gems/rake-12.3.3/lib/rake/application.rb:116:in `block (2 levels) in top_level'
[smtp.1:14414] [2020-12-10T11:14:43.180] ERROR -- : [QQ19CC] /opt/postal/vendor/bundle/ruby/2.3.0/gems/rake-12.3.3/lib/rake/application.rb:116:in `each'
[smtp.1:14414] [2020-12-10T11:14:43.180] ERROR -- : [QQ19CC] /opt/postal/vendor/bundle/ruby/2.3.0/gems/rake-12.3.3/lib/rake/application.rb:116:in `block in top_level'
[smtp.1:14414] [2020-12-10T11:14:43.181] ERROR -- : [QQ19CC] /opt/postal/vendor/bundle/ruby/2.3.0/gems/rake-12.3.3/lib/rake/application.rb:125:in `run_with_threads'
[smtp.1:14414] [2020-12-10T11:14:43.182] ERROR -- : [QQ19CC] /opt/postal/vendor/bundle/ruby/2.3.0/gems/rake-12.3.3/lib/rake/application.rb:110:in `top_level'
[smtp.1:14414] [2020-12-10T11:14:43.182] ERROR -- : [QQ19CC] /opt/postal/vendor/bundle/ruby/2.3.0/gems/rake-12.3.3/lib/rake/application.rb:83:in `block in run'
[smtp.1:14414] [2020-12-10T11:14:43.183] ERROR -- : [QQ19CC] /opt/postal/vendor/bundle/ruby/2.3.0/gems/rake-12.3.3/lib/rake/application.rb:186:in `standard_exception_handling'
[smtp.1:14414] [2020-12-10T11:14:43.184] ERROR -- : [QQ19CC] /opt/postal/vendor/bundle/ruby/2.3.0/gems/rake-12.3.3/lib/rake/application.rb:80:in `run'
[smtp.1:14414] [2020-12-10T11:14:43.185] ERROR -- : [QQ19CC] /opt/postal/vendor/bundle/ruby/2.3.0/gems/rake-12.3.3/exe/rake:27:in `<top (required)>'
[smtp.1:14414] [2020-12-10T11:14:43.186] ERROR -- : [QQ19CC] /opt/postal/vendor/bundle/ruby/2.3.0/bin/rake:22:in `load'
[smtp.1:14414] [2020-12-10T11:14:43.186] ERROR -- : [QQ19CC] /opt/postal/vendor/bundle/ruby/2.3.0/bin/rake:22:in `<main>'

At first glance, it appears to be failing in sorting available IPs
https://github.com/postalhq/postal/blob/2595481b266199d8e29347dea2764f2c10202805/lib/postal/smtp_server/client.rb#L317
Does it work if you specify the appropriate /whatever in the credential?

At first glance, it appears to be failing in sorting available IPs
https://github.com/postalhq/postal/blob/2595481b266199d8e29347dea2764f2c10202805/lib/postal/smtp_server/client.rb#L317
Does it work if you specify the appropriate /whatever in the credential?

Pardon my english but I don't understand what should I do :-)
Do you mean to replace "credential" with "SMTP-IP" ?

Try specifying network as 192.168.3.100/32 and see if you still get the error when trying to send mail with your Postal

I tried with IP only, IP/32 and a full network /24, it doesn't work, same error.

Thanks for confirming, I would presume that there is a quirk with how you're supposed to enter IP addresses that isn't covered by form validation in the UI, also I would have hoped that the || 0 in the code would have compensated in this regard but evidently not.
Can you also confirm the version of Ruby you are using? That may be relevant.
Otherwise @catphish or @adamcooke would be able to comment further.

Ubuntu 18.04.5 with ruby version as bellow.
zulu@medea:~$ ruby -v
ruby 2.3.8p459 (2018-10-18 revision 65136) [x86_64-linux-gnu]

Hmm, quick and dirty fix what seems to be working (checks the ip and if it's not in IP-SMTP it does not authorize).
@credential = Credential.where(:type => 'SMTP-IP').all.sort_by { |c| c.ipaddr || 0 }.reverse.find do |credential|
Seems that the ipaddr library included on default ruby does not need that prefix option becouse the prefix is in x.x.x.x/y format in database so ipaddr.include knows howto compare it. (maybe i didnt do full debug)

Hmm, quick and dirty fix what seems to be working (checks the ip and if it's not in IP-SMTP it does not authorize).
@credential = Credential.where(:type => 'SMTP-IP').all.sort_by { |c| c.ipaddr || 0 }.reverse.find do |credential|
Seems that the ipaddr library included on default ruby does not need that prefix option becouse the prefix is in x.x.x.x/y format in database so ipaddr.include knows howto compare it. (maybe i didnt do full debug)

Hello @foggeri , thanks for the workaround, it works, I have tested with one IP and a subnet.
Do you have an idea how can I set for multiple IPs (not a subnet, just a list of IPs). I have tried to add a list of IPs, comma separated, but it doesn't work: "Key must be a valid IPv4 or IPv6 address"

Hello @foggeri , thanks for the workaround, it works, I have tested with one IP and a subnet.
Do you have an idea how can I set for multiple IPs (not a subnet, just a list of IPs). I have tried to add a list of IPs, comma separated, but it doesn't work: "Key must be a valid IPv4 or IPv6 address"

Hello @foggeri , thanks for the workaround, it works, I have tested with one IP and a subnet.
Do you have an idea how can I set for multiple IPs (not a subnet, just a list of IPs). I have tried to add a list of IPs, comma separated, but it doesn't work: "Key must be a valid IPv4 or IPv6 address"

Hello,
Just add new IP-SMTP credential from "Credentials" tab.

Hello @foggeri , thanks for the workaround, it works, I have tested with one IP and a subnet.
Do you have an idea how can I set for multiple IPs (not a subnet, just a list of IPs). I have tried to add a list of IPs, comma separated, but it doesn't work: "Key must be a valid IPv4 or IPv6 address"

Hello,
Just add new IP-SMTP credential from "Credentials" tab.

This is/was an issue with running Postal with Ruby 2.3. Upgrade to 2.6.x.

authors: adamcooke foggeri nenominal willpower232

repo: postalhq/postal


text:
Update lodash v3.

Updates lodash to v3 to take advantage of cherry-picking modules for a smaller bundle size.
Using the bundle-collapser Browserify plugin, some additional Uglify commands, & gzip-size:
$ browserify test.js -p bundle-collapser/plugin -o bundle.js
$ uglifyjs bundle.js -m -c "comparisons=false,keep_fargs=true,unsafe=true,unsafe_comps=true,warnings=false" -b "ascii_only=true,beautify=false" -o bundle.min.js

Also included are results of replacing the Browserify-step with webpack:
webpack --optimize-dedup --optimize-occurence-order test.js bundle.js

For kitchen sink require('lodash') of 2.4.1 the size is
$ gzip-size bundle.min.js # => browserify: 14.96kb; webpack: 13.3kb

For cherry-pick require('lodash/foo/bar') of 3.1.0 the size is
$ gzip-size bundle.min.js # => browserify: 6.65kb; webpack: 6.4kb

@jdalton thanks for submitting this! And I appreciate you taking time to weigh in on the other thread(s) - much appreciated. My team's going through a release cycle, so schedule's a bit intense for me at the moment, but I hope to get to this in the next week or so. Can't wait to look this over, since it looks like I can leverage similar ideas in machina (which also has a lodash dep). :smile:

@ifandelse No prob. It was great to dig in and try browserify/webpack.

@jdalton managed to take a peek at this for a few minutes today. So far I really like it. I'm thinking that I would offer this along side the current UMD wrapper that works dropped-in-as-is for RequireJS and plain browser global usage (and update the docs to indicate the option you have if you're using webpack or browserify, etc.). That seem to be the right approach, or would you have a different suggestion?

That seem to be the right approach, or would you have a different suggestion?

Sounds good.

Hey guys,
thanks for awesome work, but one question:
even though postal 1.0 uses subset of lodash 3.1 I still need to have full blown lodash loaded to make postal work? Both postal.js & postal.lodash.js?
So if I want to bundle it with my own library I will need to do that webpack thingie to have postal and minimalistic lodash version, right?

@z0r1k  - the postal.js/postal.min.js files are the same as always - they take a full lodash as a dep, regardless of environment. The postal.lodash/postal.lodash.min files do require you to be using something like webpack or browserify - so your packed/bundled/built version will only have the partial lodash. So, yes, you'll need full lodash available for the build step in order to produce that bundle.

authors: ifandelse jdalton z0r1k


text:
Pen Test - Insecure Randomness

Findings:
The application uses a weak method of generating pseudo-random values, such that other numbers could be determined from a relatively small sample size. Since the pseudo-random number generator used is designed for statistically uniform distribution of
values, it is approximately deterministic. Thus, after collecting a few generated values, it would be possible for an attacker to calculate past or future values.
Specifically, if this pseudo-random value is used in any security context, such as one-time passwords, keys, secret identifiers or salts - an attacker would likely be able to predict the next value generated and steal it, or guess a previously generated value and spoof its original intent.
Risk:
Random values are often used as a mechanism to prevent malicious users from knowing or predicting a given value, such as a password, encryption key, or session identifier. Depending on what this random value is used for, an attacker would be able to predict the next numbers generated, or previously generated values, based on sources often used to derive certain randomness; however, while they may seem random, large statistical samples would demonstrate that they are insufficiently random, producing a much smaller space of possible "random" values than a truly random sample would. This could enable an attacker to derive or guess this value, and thus hijack another user's session, impersonate another user, or crack an encryption key (depending on what the pseudo-random value was used for).
Recommendations:
•	Always use a cryptographically secure pseudo-random number generator, instead of basic random methods, particularly when dealing with a security context
•	Use the cryptorandom generator that is built-in to your language or platform, and ensure it is securely seeded. Do not seed the generator with a weak, non-random seed. (In most cases, the default is securely random).
•	Ensure you use a long enough random value, thus making brute-force attacks unfeasible.

As with all your tickets. Please provide links to specific code.

authors: catphish hackeys

repo: postalserver/postal


text:
Doesn't outputs source file path

Stylelint throws errors in source files, so it's easy to find where actual syntax error is (it shows path to source file).
However postcss-browser-report reports error in generated file not source (it show path to generated file).

@iamfrntdv  The same problem I have. @brainopia

authors: iamfrntdv rtxrulez

repo: postcss/postcss-browser-reporter


text:
Solubility data

@mc-robinson - thank you for mapping.
20200527_Solubility.xlsx

20200527_Solubility_MCR_mapped.xlsx

authors: LizbeK mc-robinson


text:
Added random_state as an available hyper parameter for xgboost models

I followed the standard found throughout the repo and just called unwrap on line 166. This does have the potential to cause somewhat confusing error messages if they have malformed arguments. I would be happy to go through and replace the unwrap() calls with expect(SOME HELPFUL ERROR MESSAGE) throughout pgml-extension if that would be helpful?

You're right. expect() is preferable to unwrap(), but rather than trying to convert all existing cases, I think it'd be better to try to move most functions that currently unwrap to instead return an anyhow::Result, and add context() to their calls for better nested function call clarity.
I think the current transformer bindings for transform and embed are the worst offenders with the mostly likely failure cases, and the scikit algorithm's are probably second worst on that front.

authors: SilasMarvin montanalow

repo: postgresml/postgresml


text:
Deprecate combinatorics/generator and combinatorics/enumerator

Deprecate these files that contained ruby 1.8 vs 1.9 code. Add a warn message and avoid requiring them anywhere.

Done in 2200e46f020ccee2d43a596354043cfdbc083cb3.

repo: postmodern/combinatorics


text:
[Docs] Improve the "Using the store" section.

What problem is this solving
The "Using the store" section starts from explaining the gotchas. Usually docs are written in a different way - the very first example is usually dead simple, but yet complete, code snippet that explains how do do things right - a code snippet that a user can just copy/paste without analyzing it.
In Pinia docs it's the opposite - the sections starts from an examples that tell the user how not to use Pinia - these are all valid and necessary information but the most important piece information is at the very bottom of the page.
Proposed solution
I would start from a very basic example:
export default defineComponent({
  setup() {
    const store = useStore();

    return {
      firstName: computed(() => store.firstName),
      lastName: computed(() => store.lastName),
    }
  },
})

It might be also a good idea to include the source code for the useStore() function.
Then I would explain that destructuring will break reactivity, that useStore() needs to be called in setup(), etc.

BTW, I would also consider moving the "Using the store" section outside the "Defining a store" section. I think that a better Idea would be to put it after "Actions" but before "Plugins".  The reason for it is that first the user needs to learn how to define state/getters/actions before they can import the store and use it.

Yeah, thanks for the feedback. I will

Put the component example first
Still explain why we have 2 functions (define vs use)
Move the example for SSR somewhere else and still link it there

authors: posva wujekbogdan

repo: posva/pinia


text:
Allow Control.load to manage parameters like Control.add

If I want to emulate the functionality of the -c switch of gringo/clingo via the Python API, it cannot be directly done with the Control.load function. I made a workaround like this:
 class MyControl(Control):
     def load_add(self, name, parameters, file):
         with open(file) as f:
             program = f.read()
         self.add(name, parameters, program)

But that feels a bit clunky. I believe the Control.load function itself should be able to achieve a similar effect itself. Maybe there is a better way that I don't know of?

This does not really emulate the -c switch because its effect is global affecting the whole program. You could add a program with a #const directive and then load a file. This would have the "same" effect as the -c switch. As long as the programs you are adding are small enough, there is also no problem with your code. Just large instances are better loaded using Control.load.

Ok, but is there a convenient way to set the #const directive programatically? I mean, there is the Control.get_const  method, but apparently no set_const method. I could work around that by reading the file to string and appending a #const directive, but again, that feels pretty clunky.

There is no function to set it conveniently but there are different ways to set it. The most "convenient" way is probably by passing ['-c', 'name=<value>'] as arguments to the control object. Otherwise, #const statements can also be added via the ast module. This avoids strings but is quite verbose. You could also avoid #const statements completely and just pass the value via a fact.

The most "convenient" way is probably by passing ['-c', 'name=<value>'] as arguments to the control object.

OK, that seems like a relatively clean solution to my problem. Didn't know that's possible. Thanks for your time!

authors: jachymb rkaminsk

repo: potassco/clingo


text:
Training on custom dataset

Hi @potterhsu
I am trying to train a Faster R-CNN(Resnet101) model on my custom dataset. The dataset is in the same format as MS COCO, with 16 categories. However, I am not sure how to proceed. I am new to pytorch and don't have the slightest of ideas about where I can start from. I would really appreciate your help regarding this.
Thanks and Regards
Chaitanya Agrawal

Basically, it can be done by

Copy dataset/coco2017.py to dataset/coco2017-custom.py (or whatever you want)

Change all COCO2017 to COCO2017Custom, for example:

class  COCO2017(Base) -> class  COCO2017Custom(Base)
self._mode == COCO2017.Mode.TRAIN -> self._mode == COCO2017Custom.Mode.TRAIN
os.path.join('caches', 'coco2017' -> os.path.join('caches', 'coco2017-custom'

Modify CATEGORY_TO_LABEL_DICT and update def num_classes()

In dataset/base.py, append a new branch under from_name functionelif name == 'coco2017-custom':
    from dataset.coco2017_custom import COCO2017Custom
    return COCO2017Custom

Please let me know if it works for you.

Hi @potterhsu
Your solution worked for me perfectly! There was just a very small issue where you have this underlying assumption that all image_ids are integers. But dealing with that was really easy.
Thanks a lot for your help and your wonderful library!
Regards
Chaitanya Agrawal

Hi,sorry to bother you,can you give an example for dataset in the same format as VOC?@potterhsu

authors: PeterBishop0 culechetoo potterhsu


text:
TRIM support

It would be useful to collect and display whether an instance type with instance SSDs supports the TRIM command.  Not all of them do.

@eliaslevy You could do a PR...

Would this be the only place to scrape for this data? http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ssd-instance-store.html#InstanceStoreTrimSupport
I wish it was at http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/instance-types.html#instance-networking-storage, I think that would have been much cleaner and easier to scrape since we already get data from other rows of that table.

There is also http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/InstanceStorage.html

Thanks, I wasn't aware of that.
I'll try to refactor the entire logic for local instance storage and scrape all the data from that table into existing or new columns.

Fixed in #235, which also refactors the entire scraping of local instance storage, which is now based on that page.

authors: cristim dejlek eliaslevy


text:
Instrumenting assert.throws()

Hello!
We've been using power-assert with Lab (and Ava to some extend) since a while, and it's really a wonderful tool.
One of the few missing bits is the instrumentation of assert.throw().
Before even trying to contribute, I'd like first to validate with you that I'm taking the proper approach.
After few experiments, here is what I came up with.
Case 1
assert.throws(function() {/* whatever */});

Could be turned into:
var _rec1 = new _PowerAssertRecorder1();
_rec1.hasThrown = false;
try {
  (function() {/* whatever */})();
} catch (err) {
  _rec1.hasThrown = true;
}
// check it has thrown
assert(_rec1._expr(_rec1.hasThrown? true : !_rec1._capt('did not throw', 'arguments/0'), {
  content: 'assert.throws(function() {/* whatever */});',
  filepath: 'path/to/some_test.js',
  line: 1
})/* , message*/);

When the asserted function doesn't throw, power-assert will report the following:
AssertionError [ERR_ASSERTION]:   # path/to/some_test.js:1

  assert.throws(function() {/* whatever */});
                |
                "did not throw"

assert.throws(block, [expected], [message]) also have a message argument which, if present,  should be reported when the asserted didn't throw.
Case 2
assert.throws(function() {/* whatever */}, RangeError);

Could be turned into:
_rec1.hasThrown = false;
try {
  (function() {/* whatever */})();
} catch (err) {
  _rec1.hasThrown = true;
  // validates expected class
  assert(_rec1._expr(_rec1._capt(err instanceof RangeError, 'arguments/1') || !_rec1._capt(err.toString(), 'callee'), {
    content: 'assert.throws(function() {/* whatever */}, RangeError);',
    filepath: 'path/to/some_test.js',
    line: 1
  }));
}
// check it has thrown
assert(_rec1._expr(_rec1.hasThrown? true : !_rec1._capt('did not throw', 'arguments/0'), {
  content: 'assert.throws(function() {/* whatever */}, RangeError);',
  filepath: 'path/to/some_test.js',
  line: 1
})/*, message */);

When the asserted function thrown object with unexpected class, power-assert will report the following:
AssertionError [ERR_ASSERTION]:   # path/to/some_test.js:1

  assert.throws(function() {/* whatever */}, RangeError);
         |                                   |
         "Error: unexpected"                 false

Case 3
assert.throws(function() {/* whatever */}, /expected/);

Could be turned into:
var _rec1 = new _PowerAssertRecorder1();
_rec1.hasThrown = false;
try {
  (function() {/* whatever */})();
} catch (err) {
  _rec1.hasThrown = true;
  // validates expected regexp
  assert(_rec1._expr(_rec1._capt(/expected/.test(err), 'arguments/1') || !_rec1._capt(err.toString(), 'callee'), {
    content: 'assert.throws(function() {/* whatever */}, /expected/);',
    filepath: 'path/to/some_test.js',
    line: 1
  }));
}
// check it has thrown
assert(_rec1._expr(_rec1.hasThrown? true : !_rec1._capt('did not throw', 'arguments/0'), {
  content: 'assert.throws(function() {/* whatever */}, /expected/);',
  filepath: 'path/to/some_test.js',
  line: 1
})/* , message*/);

When the asserted function thrown value which doesn't match regexp, power-assert will report the following:
AssertionError [ERR_ASSERTION]:   # path/to/some_test.js:1

  assert.throws(function() {/* whatever */}, /expected/);
         |                                   |
         "10"                                /expected/

Case 4
assert.throws(function() {/* whatever */}, err => err instanceof Error && err.message.includes('expected'));

Could be turned into:
var _rec1 = new _PowerAssertRecorder1();
_rec1.hasThrown = false;
try {
  (function() {/* whatever */})();
} catch (err) {
  _rec1.hasThrown = true;
  // validates expected function
  assert(_rec1._expr(_rec1._capt((err => err instanceof Error && err.message.includes('expected'))(err), 'arguments/1') || !_rec1._capt(err.toString(), 'callee'), {
    content: 'assert.throws(function() {/* whatever */}, err => err instanceof Error && err.message.includes(\'expected\'));',
    filepath: 'path/to/some_test.js',
    line: 1
  }));
}
// check it has thrown
assert(_rec1._expr(_rec1.hasThrown? true : !_rec1._capt('did not throw', 'arguments/0'), {
  content: 'assert.throws(function() {/* whatever */}, err => err instanceof Error && err.message.includes(\'expected\'));',
  filepath: 'path/to/some_test.js',
  line: 1
})/* , message*/);

When the asserted function thrown value that doesn't pass custom function, power-assert will report the following:
AssertionError [ERR_ASSERTION]:   # path/to/some_test.js:1

  assert.throws(function() {/* whatever */}, err => err instanceof Error && err.message.includes('expected'));
         |                                   |
         "SyntaxError: wrong"                false

Case 5
For doesNotThrow(), it could be slightly simpler:
assert.doesNotThrow(function() {/* whatever */});

Could be turned into:
try {
  (function() {/* whatever */ })();
} catch (err) {
  assert(_rec1._expr(err && !_rec1._capt('threw ' + err, 'arguments/0'), {
    content: 'assert.doesNotThrow(function() {/* whatever */});',
    filepath: 'path/to/some_test.js',
    line: 1
  })/*, message */);
}

Which will produce on unexpected error:
AssertionError [ERR_ASSERTION]:   # path/to/some_test.js:1

  assert.doesNotThrow(function() {/* whatever */});
                      |
                      "threw Error: unexpected"

For the expected second parameter, I'm not sure it worth any instrumentation, as the result will be logically the same.
As soon as the asserted function throws something, whether it comply with expected class/regexp/custom function or not, an AssertionError will be raised.

That's it, thanks for your time and feedback!

@feugy Thank you for your comments. Instrumenting assert.throws is a bit difficult task to wrestle with, There may be some edge cases to consider carefully. I'll review your implementation plans and also show you what's I'm thinking. Let's make it happen together.

Hello @twada. Any news on this?
You might be interested to know that rejects() and doesNotReject() were added to nodejs assert module.
Having those 4 functions instrumented would be really awesome.

authors: feugy twada

repo: power-assert-js/espower


text:
Update Prow to v20201020-a5b49bc903 version

Update the prow to v20201020-a5b49bc903 version
To include the fix - https://github.com/kubernetes/test-infra/pull/18001
https://github.ibm.com/powercloud/container-dev/issues/1328

[APPROVALNOTIFIER] This PR is NOT APPROVED
This pull-request has been approved by: Rajalakshmi-Girish
To complete the pull request process, please assign mkumatag
You can assign the PR to them by writing /assign @mkumatag in a comment when ready.
The full list of commands accepted by this bot can be found here.

Needs approval from an approver in each of these files:

OWNERS

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

/assign @mkumatag

closed via #81 and #82

authors: Rajalakshmi-Girish ltccci mkumatag