Announcement stopped working on third party devices: Sonos Speakers, ecobee4, Bose

Describe the bug
Announce doesn't work, while TTS does. Until Sunday announce worked perfect on my Alexa enabled Sonos speakers (Sonos One and Beam).
If i use the Aleaxa app to do the annoncement it works perfect. In the FAQ is mentioned to check that "Communications" is enabled and it is on all my speakers. But i noties that if I click on "Communications" the Alexa app get stuck loading the page.
It is one of my favorite features and I use it as my doorbell annoncement.
To Reproduce
Steps to reproduce the behavior:

Send announce to Sonos Alexa enabled speaker.
Northing happens

Expected behavior
Play announced message on every speaker taget.
System details

Home-assistant (version): 0.97.2
Hassio (Yes/No): No, plain Home-assistant docker version.
alexa_media  (version from const.py or HA startup): 1.4.1 (installed from HACS)
alexapy (version from pip show alexapy or HA startup): 0.7.1

Having the same issue.
As suggested in a comment on the seemingly related albeit closed, issue 200, moving from type: announce to type: tts at least gets Alexa to say something. I'm currently using it as a workaround...

My issue with accessing the "Communications" setting is fixed now after i spoke to Amazon support. My account where reset and moved from UK to US. We removed all devices and I setup everything.
Still only the TTS mode works and not the annoncement.

Does announce work on any non Sonos speakers? We haven't touched the announce code for a while.

For us to debug we will need the alexapy debug logs. Please provide for announce and tts.

I have a Sonos and an Echo Dot. Announce worked on both prior to upgrading to 1.4.1. Works on neither afterwards.
Wonder if it could be related to migration to HACS rather than 1.4.1?
I’ll be away for a couple of days. Will provide logs once I’ve returned!

For us to debug we will need the alexapy debug logs. Please provide for announce and tts.

Running in docker where do I get the logs?
I enabled:
logger:
default: critical
logs:
for v 1.0.0
custom_components.alexa_media: debug

for API debugging (verbose and intended for service debugging)
alexapy: debug

I have a Sonos and an Echo Dot. Announce worked on both prior to upgrading to 1.4.1. Works on neither afterwards.
Wonder if it could be related to migration to HACS rather than the upgrade to 1.4.1?
I’ll be away for a couple of days. Will provide logs once I’ve returned!

Good to hear its not only a Sonos problem. Upgrading from 1.2.* to 1.4.1 I changed to use HACS.

Back at home, enabled debug, and was running the exact same service calls as I did prior (indeed, it was cached and ready to go), but "unfortunately" it ran as it should. Ie. no errors. So no logs to send, I'm afraid.
Could it have been some caching error or the like, perhaps related to migrating to HACS? Either fixed by some amount of time having gone by, or X amount of reboots...

Mine still dosen't work. Tell me what to provide.
Is it like this:
2019-08-15 17:25:02 DEBUG (SyncWorker_9) [custom_components.alexa_media.media_player] Mikkel's Sonos Beam is last_called: 8****************************6d5
2019-08-15 17:25:21 DEBUG (Thread-5) [alexapy.alexawebsocket] Got Pong MSG from Server
2019-08-15 17:28:21 DEBUG (Thread-5) [alexapy.alexawebsocket] Got Pong MSG from Server
2019-08-15 17:31:21 DEBUG (Thread-5) [alexapy.alexawebsocket] Got Pong MSG from Server
2019-08-15 17:34:21 DEBUG (Thread-5) [alexapy.alexawebsocket] Got Pong MSG from Server
2019-08-15 17:35:48 DEBUG (Thread-5) [alexapy.alexawebsocket] Received WebSocket MSG.
2019-08-15 17:35:48 DEBUG (Thread-5) [alexapy.alexawebsocket] Received b'MSG 0x00000362 0x7896ee63 f 0x00000001 0xc14c2e59 0x00000241 GWM MSG 0x0000b479 0x0000005c urn:tcomm-endpoint:service:serviceName:DeeWebsiteMessagingService:domain:prod:realm:USAmazon 0x00000081 urn:tcomm-endpoint:device:customerId:A1VLQF1TDI6MEL:deviceType:ALEGCNGL9K0HM:deviceSerialNumber:134-4642686-3180638-1565878758000 {"payload":"{\"destinationUserId\":\"A1VLQF1TDI6MEL\",\"dopplerId\":{\"deviceSerialNumber\":\"c54b64b91ef94ea6a9f2f13d79bf8404\",\"deviceType\":\"A2OSP3UA4VC85F\"},\"dopplerConnectionState\":\"OFFLINE\"}","command":"PUSH_DOPPLER_CONNECTION_CHANGE"}FABE'
2019-08-15 17:35:48 DEBUG (Thread-5) [alexapy.alexawebsocket] Received Standard MSG.

@krissen HACS shouldn't have any impact. Sometimes it could be an Amazon connectivity issue and we have seen issues where multiple commands to the same Echo may result in some being ignored.
@mikkelke Can you try to do an announce and a tts and show the logs from when it issues those commands?

@krissen HACS shouldn't have any impact. Sometimes it could be an Amazon connectivity issue and we have seen issues where multiple commands to the same Echo may result in some being ignored.
@mikkelke Can you try to do an announce and a tts and show the logs from when it issues those commands?

 Can you try renaming the pickle file and relogging in and seeing if that helps?
The next thing may be to craft an announcement by itself without the subsequent volume change. This is so we can make sure it's not because the Sonos is dropping a command because it's getting hit by more than one.
If that doesn't work, there may be something special about the way the Sonos packet has to be configured. I'd need you to create a routine with announce targeting your Sonos in the app, and then pull the sequence data.  Basically you'd follow the instructions here, and then stop at step 7 and provide the entire operationPayload portion to compare to what we're sending.

@alandtse Thanks for your help. I made this rutine and when I play it from the app or say "Test this" northing happens, I think I must contact Amazon again (Annonce works when i go into "Communicate" and "Annonce":
{
"@type": "com.amazon.alexa.behaviors.model.Automation",
"automationId": "amzn1.alexa.automation.55ad9f56-555b-4b2b-83ae-c28425f58b3a",
"name": null,
"triggers": [
{
"payload": {
"customerId": "A1VLQF1TDI6MEL",
"utterance": "test this",
"locale": "en-DK",
"marketplaceId": "ATVPDKIKX0DER"
},
"id": "amzn1.alexa.trigger.791afa5c-6778-4c2b-8446-597fc0d92c98",
"type": "CustomUtterance",
"timeLapse": null
}
],
"sequence": {
"@type": "com.amazon.alexa.behaviors.model.Sequence",
"sequenceId": "amzn1.alexa.sequence.a3e04491-2cf5-43d0-844a-70d65f0d04c5",
"startNode": {
"@type": "com.amazon.alexa.behaviors.model.OpaquePayloadOperationNode",
"type": "AlexaAnnouncement",
"skillId": "amzn1.ask.1p.messaging",
"operationPayload": {
"expireAfter": "PT5S",
"content": [
{
"locale": "en-DK",
"display": {
"title": "Alexa Routines",
"body": "Someone is at the door"
},
"speak": {
"type": "text",
"value": "Someone is at the door"
}
}
],
"customerId": "A1VLQF1TDI6MEL",
"target": {
"customerId": "A1VLQF1TDI6MEL"
}
},
"name": null
}
},
"owner": null,
"clientAlias": null,
"condition": null,
"status": "ENABLED",
"creationTimeEpochMillis":<PHONE_NUMBER>434,
"lastUpdatedTimeEpochMillis":<PHONE_NUMBER>095
}
]

Ok I agree, I think if you can't get the Alexa App to get it to work, then there's something happening in your setup.  I noticed that the locale is being populated as en-DK, which I believe is English in Denmark?  This is the first time I saw that locale and I don't know if Announce is supposed to work for there. Amazon support may know better.

The issue started before i changed locale.
When I started using the Alexa Media Player, my Alexa account where on amazon.com, I got the impression that I could get faster responds time (lower latency) if I change my locale. I contacted Amazon and they change it to Germany. All skils text where now written in German, so I made them change it to UK and that have been working for more then half a year. When i contacted Amazon I contacted Amazon they gave me this link: https://www.amazon.com/mycd and this time I put in my correct address and region where changed to Denmark. When I logged in on Alexa I could see that I was back on alexa.amazon.com aka the US servers.

I will also continue to troubleshoot this, as I noticed this morning that the Echo dot indeed announced as it should in my morning routine, having switched back from ’type: tts’ to ’type: announce’, but the Sonos did not. (Prior to 1.4.1 and HACS, both announced.) So +1 that it might be something Sonos-specific.
I’ll get back with logs and whatnot within a day, I hope.

Announcement through the Alexa app works here; announces on Sonos as well as the Echo dot.

Testing with the following data, for service notify.alexa_media_MYSONOSDEVICE: { "message": "test", "data": { "type": "announce", "method": "speak" } }
Debug lines for Sonos, announce (does not work):
2019-08-16 21:55:14 DEBUG (SyncWorker_10) [custom_components.alexa_media.notify] Message: test, kwargs: {'target': ['REDACTEDSONOSSERIAL'], 'data': {'type': 'announce', 'method': 'speak'}}
2019-08-16 21:55:14 DEBUG (SyncWorker_10) [custom_components.alexa_media.notify] Testing item: REDACTEDSONOSSERIAL against (<Entity Vardagsrum: standby>, Vardagsrum, a****************************0cc, media_player.vardagsrum_2)
2019-08-16 21:55:14 DEBUG (SyncWorker_10) [custom_components.alexa_media.notify] Converting: REDACTEDSONOSSERIAL to (entities): <Entity Vardagsrum: standby>
2019-08-16 21:55:14 DEBUG (SyncWorker_10) [custom_components.alexa_media.notify] Testing item: REDACTEDSONOSSERIAL against (<Entity Sonos One: standby>, Sonos One, 2****************************2f8, media_player.sonos_one_2)
2019-08-16 21:55:14 DEBUG (SyncWorker_10) [custom_components.alexa_media.notify] Testing item: REDACTEDSONOSSERIAL against (<Entity Pricken: playing>, Pricken, G************XT5, media_player.pricken)
2019-08-16 21:55:14 DEBUG (SyncWorker_10) [custom_components.alexa_media.notify] Testing item: REDACTEDSONOSSERIAL against (<Entity This Device: standby>, This Device, B****************************C74, media_player.this_device_4)
2019-08-16 21:55:14 DEBUG (SyncWorker_10) [custom_components.alexa_media.notify] Testing item: REDACTEDSONOSSERIAL against (<Entity Kristian's Alexa Apps: standby>, Kristian's Alexa Apps, 6****************************8B5, media_player.kristian_s_alexa_apps)
2019-08-16 21:55:14 DEBUG (SyncWorker_10) [custom_components.alexa_media.notify] Testing item: REDACTEDSONOSSERIAL against (<Entity This Device: standby>, This Device, 1****************************03d, media_player.this_device_3)
2019-08-16 21:55:14 DEBUG (SyncWorker_10) [custom_components.alexa_media.notify] Testing item: <Entity Vardagsrum: standby> against (<Entity Vardagsrum: standby>, Vardagsrum, a****************************0cc, media_player.vardagsrum_2)
2019-08-16 21:55:14 DEBUG (SyncWorker_10) [custom_components.alexa_media.notify] Converting: <Entity Vardagsrum: standby> to (serialnumbers): REDACTEDSONOSSERIAL
2019-08-16 21:55:14 DEBUG (SyncWorker_10) [custom_components.alexa_media.notify] Testing item: <Entity Vardagsrum: standby> against (<Entity Sonos One: standby>, Sonos One, 2****************************2f8, media_player.sonos_one_2)
2019-08-16 21:55:14 DEBUG (SyncWorker_10) [custom_components.alexa_media.notify] Testing item: <Entity Vardagsrum: standby> against (<Entity Pricken: playing>, Pricken, G************XT5, media_player.pricken)
2019-08-16 21:55:14 DEBUG (SyncWorker_10) [custom_components.alexa_media.notify] Testing item: <Entity Vardagsrum: standby> against (<Entity This Device: standby>, This Device, B****************************C74, media_player.this_device_4)
2019-08-16 21:55:14 DEBUG (SyncWorker_10) [custom_components.alexa_media.notify] Testing item: <Entity Vardagsrum: standby> against (<Entity Kristian's Alexa Apps: standby>, Kristian's Alexa Apps, 6****************************8B5, media_player.kristian_s_alexa_apps)
2019-08-16 21:55:14 DEBUG (SyncWorker_10) [custom_components.alexa_media.notify] Testing item: <Entity Vardagsrum: standby> against (<Entity This Device: standby>, This Device, 1****************************03d, media_player.this_device_3)
2019-08-16 21:55:14 DEBUG (SyncWorker_10) [custom_components.alexa_media.notify] Announce targets: ['a****************************0cc'] entities: [<Entity Vardagsrum: standby>]
2019-08-16 21:55:14 DEBUG (SyncWorker_10) [custom_components.alexa_media.notify]<EMAIL_ADDRESS>Announce by <Entity Vardagsrum: standby> to targets: ['a****************************0cc']: test
2019-08-16 21:55:14 DEBUG (SyncWorker_10) [alexapy.alexaapi] Running sequence: AlexaAnnouncement data: {"behaviorId": "PREVIEW", "sequenceJson": "{\"@type\": \"com.amazon.alexa.behaviors.model.Sequence\", \"startNode\": {\"@type\": \"com.amazon.alexa.behaviors.model.OpaquePayloadOperationNode\", \"type\": \"AlexaAnnouncement\", \"operationPayload\": {\"deviceType\": \"A15ERDAKK5HQQG\", \"deviceSerialNumber\": \"REDACTEDSONOSSERIAL\", \"locale\": \"en-us\", \"customerId\": \"REDACTED\", \"expireAfter\": \"PT5S\", \"content\": [{\"locale\": \"en-us\", \"display\": {\"title\": \"\", \"body\": \"\"}, \"speak\": {\"type\": \"text\", \"value\": \"test\"}}], \"target\": {\"customerId\": \"REDACTED\", \"devices\": [{\"deviceSerialNumber\": \"REDACTEDSONOSSERIAL\", \"deviceTypeId\": \"A15ERDAKK5HQQG\"}]}}}}", "status": "ENABLED"}
2019-08-16 21:55:16 DEBUG (Thread-13) [alexapy.alexawebsocket] Received WebSocket MSG.

Debug line for Sonos, service data { "message": "test", "data": { "type": "tts", "method": "speak" } } (does work)
2019-08-16 21:48:55 DEBUG (SyncWorker_15) [custom_components.alexa_media.notify] TTS entities: [<Entity Vardagsrum: standby>]
2019-08-16 21:48:55 DEBUG (SyncWorker_15) [custom_components.alexa_media.notify] TTS by <Entity Vardagsrum: standby> : test
2019-08-16 21:48:55 DEBUG (SyncWorker_15) [alexapy.alexaapi] Running sequence: Alexa.Speak data: {"behaviorId": "PREVIEW", "sequenceJson": "{\"@type\": \"com.amazon.alexa.behaviors.model.Sequence\", \"startNode\": {\"@type\": \"com.amazon.alexa.behaviors.model.OpaquePayloadOperationNode\", \"type\": \"Alexa.Speak\", \"operationPayload\": {\"deviceType\": \"A15ERDAKK5HQQG\", \"deviceSerialNumber\": \"REDACTED\", \"locale\": \"en-us\", \"customerId\": \"REDACTED\", \"textToSpeak\": \"test\"}}}", "status": "ENABLED"}

Debug line for Echo dot (notify.alexa_media_MYECHODOTDEVICE), service data { "message": "test", "data": { "type": "announce", "method": "speak" } } (does work):
2019-08-16 21:54:24 DEBUG (SyncWorker_8) [alexapy.alexaapi] Running sequence: Alexa.Speak data: {"behaviorId": "PREVIEW", "sequenceJson": "{\"@type\": \"com.amazon.alexa.behaviors.model.Sequence\", \"startNode\": {\"@type\": \"com.amazon.alexa.behaviors.model.OpaquePayloadOperationNode\", \"type\": \"Alexa.Speak\", \"operationPayload\": {\"deviceType\": \"A32DOYMUN6DTXA\", \"deviceSerialNumber\": \"REDACTEDSERIAL\", \"locale\": \"en-us\", \"customerId\": \"REDACTED\", \"textToSpeak\": \"test\"}}}", "status": "ENABLED"}
2019-08-16 21:54:25 DEBUG (Thread-13) [alexapy.alexawebsocket] Received WebSocket MSG.
2019-08-16 21:54:25 DEBUG (Thread-13) [alexapy.alexawebsocket] Received b'MSG 0x00000362 0x71c973b2 f 0x00000001 0xd0fcd4e7 0x00000227 GWM MSG 0x0000b479 0x0000005c urn:tcomm-endpoint:service:serviceName:DeeWebsiteMessagingService:domain:prod:realm:USAmazon 0x00000081 urn:tcomm-endpoint:device:customerId:REDACTED:deviceType:ALEGCNGL9K0HM:deviceSerialNumber:REDACTEDSERIAL {"payload":"{\\"destinationUserId\\":\\"REDACTED\\",\\"key\\":{\\"entryId\\":\\"1565985265370#A32DOYMUN6DTXA#REDACTED\\",\\"registeredUserId\\":\\"REDACTED\\"},\\"timestamp\\":1565985265698}","command":"PUSH_ACTIVITY"}FABE'
2019-08-16 21:54:25 DEBUG (Thread-13) [alexapy.alexawebsocket] Received Standard MSG.
2019-08-16 21:54:25 DEBUG (Thread-13) [custom_components.alexa_media]<EMAIL_ADDRESS>Received websocket command: PUSH_ACTIVITY : {'destinationUserId': 'REDACTED', 'key': {'entryId': '1565985265370#A32DOYMUN6DTXA#REDACTED', 'registeredUserId': 'REDACTED'}, 'timestamp':<PHONE_NUMBER>698}
2019-08-16 21:54:25 DEBUG (Thread-13) [custom_components.alexa_media]<EMAIL_ADDRESS>Updated last_called: {'serialNumber': 'G************XT5', 'timestamp':<PHONE_NUMBER>698}
2019-08-16 21:54:25 DEBUG (Thread-13) [custom_components.alexa_media]<EMAIL_ADDRESS>last_called changed: {'serialNumber': 'G************XT5', 'timestamp':<PHONE_NUMBER>478} to {'serialNumber': 'G************XT5', 'timestamp':<PHONE_NUMBER>698}
2019-08-16 21:54:25 DEBUG (SyncWorker_13) [custom_components.alexa_media.media_player] Pricken is last_called: G************XT5

Prior to running the above, I 1) removed alexa_media through HACS. 2) Turned off HA. 3) Removed the pickle file. 4) Checked there no longer was a directory custom_components/alexa_media(there wasn't). 5) Started HA. 6) Installed alexa_media through HACS. 7) Rebooted. 8) Logged into Amazon/alexa_media again. 9) Tested announcements. Worked on Echo dot. Did not work on Sonos. TTS worked on Sonos, too.

If any of you are a 0.96 version or HA and try a 1.3.1 version of the component for comparison that would be helpful. I'm not seeing anything specifically wrong from the output.
I'm working on a revamp major release that may impact the way we interact so may need to table debugging this until we migrate since the way we interact here will be deprecated.

Don't know if it matters, but I tried pulling the nodestoExecute data, for a routine I had created in the Alexa app for the purpose and noticed

My Sonos device was not listed among devices possible to announce to. Despite that, I can do a manual announcement in the Alexa app, announced on the Sonos. But not create a routine which does it.

Locale, in the nodestoExecute data, is set to en-SE.  🤷♂Haven't seen that before.

{"@type":"com.amazon.alexa.behaviors.model.Automation","automationId":"amzn1.alexa.automation.bed72266-d475-4b07-9530-c3aa81bbe345","name":null,"triggers":[{"payload":{"customerId":"CUSTOMERID","utterance":"make it rain","locale":"en-SE","marketplaceId":"MARKETPLACEID"},"id":"amzn1.alexa.trigger.f6744e87-ad91-4e56-84ca-f8f9efa01270","type":"CustomUtterance","timeLapse":null}],"sequence":{"@type":"com.amazon.alexa.behaviors.model.Sequence","sequenceId":"amzn1.alexa.sequence.e273f122-8f3b-43c8-ba69-aeb1d4e8f932","startNode":{"@type":"com.amazon.alexa.behaviors.model.OpaquePayloadOperationNode","type":"AlexaAnnouncement","skillId":"amzn1.ask.1p.messaging","operationPayload":{"expireAfter":"PT5S","content":[{"locale":"en-SE","display":{"title":"Alexa Routines","body":"Testing"},"speak":{"type":"text","value":"Testing"}}],"customerId":"CUSTOMERID","target":{"customerId":"CUSTOMERID"}},"name":null}},"owner":null,"clientAlias":null,"condition":null,"status":"ENABLED","creationTimeEpochMillis":1566242209772,"lastUpdatedTimeEpochMillis":1566242209772}

Can you test the 2.0.0 release to see if this is resolved? We switched libraries so debugging in here won't be too relevant anymore.

Upgraded, restarted; it is as before. type: announce does not work; type: tts does work.

 (Only my Dot is listed as a valid device for the function.) I don't know if I was able to, earlier; never tried it.
What I can do, from the Alexa app, is to use the "Communicate" tab, and send an announcement that way to all devices. (Can't seem to specify only one device.) Doesn't work quite the same way as the announce available as routine though. Instead of just "Bling Test", I get "Bling From NAME, Test". That gets broadcasted to both the Sonos and the Echo Dot.

@krissen Thanks for the help debugging, I really appreciate the log generation even if I'm not directly responding.  The reason I try to get the routine info is that at least can show us acceptable syntax.  Again, the syntax looks fine, so I'm a bit stumped. The fact it's not an option in the routine makes me think perhaps Amazon stopped supporting it?
Some additional tests I can think of:

Are you able to create a whole house audio group and add in the sonos and dot and then try announcing to the group? (HA group won't work because we just iterate within the group). I'm trying to figure out how the "Communicate" tab differs.
You mentioned this worked before 1.4.x right? Can you try going back to 1.3.1?
Are you testing using a dev_service call or using an automation/script? I just want to eliminate the chance you may be issuing multiple commands like a volume set immediately before the announce.  We have seen issues where multiple commands results in erratic completion of commands.

Whole house audio group. Normal Alexa-groups doesn't seem to support more than one speaker. Tried to create a multi-room music group, but was told no compatible speakers were found. So far, I haven't been able to find a way to create a group within Alexa, for the two speakers.
1.3.1 Tried that some days ago, but seemed the alexa_media -component wouldn't run? I don't recall the exact errors; sorry. Also downgraded alexapy, but that didn't help. I thought that maybe 1.3.1 required HA < 0.97? (I'm on 0.97.2.)
Testing via dev_service. (Though I've tested via automations as well.)
Let me know if you've got something else to try or troubleshoot. Testing custom .py files or the like is fine as well.

I contected Amazon severeal times and thay could not tell me why it stopped working. They say the escalated my issue to techincal team but I never got a responds.
Since i use the announcement for my doorbell (I can enable the old ringer) I will try to change to Google Assistant. Thansk for the help and support.

I have the same behavior for my ecobee4.  I suspect amazon changed something on the back end for these third-party devices.
Seems like about a month ago that HA announcements stopped on the ecobee4.  Announcements still work for all amazon-manufactured devices, and using an echo to make an announcement ("alexa, announce that it's bedtime") includes the ecobee4.
Updated to latest HA (98.3) and alexa_media (2.1) through hacs (13.2) without any change.
Finally got around to "fixing it" tonight and TTS works.  I liked the chime at the beginning of an announcement, but I'm fine with TTS for now.

@mikeydarin just to check, when it stopped working for you, were you on an older version of alexa_media? Some people said it last worked for them in 1.3.1 (but it's unclear if the issue arose because of a new release or because Amazon changed something). If you hadn't been updating and still had it stop working, that would answer that question.

@alandtse I believe I was on an older version (1.2.1, maybe?) and it just stopped working, and then I deleted alexa_media, installed hacs, and used hacs 12.x to install alexa_media 1.4.1.  I've been lazy for the last few weeks, then tonight I upgraded everything.
All of this is from memory and a little amateur detective work, so it could all be wrong.

Announce stopped working on my echo dot. I have 1.3.1 and did not update or change anything.

@martin3000 your pickle likely expired if nothing has changed. Please try renaming and relogging in and seeing if it resolves.

same here, both on Echo Dot and Echo Spot announcements stopped working, TTS does work. (amazon.it)

@martin3000 your pickle likely expired if nothing has changed. Please try renaming and relogging in and seeing if it resolves.

Indeed, thank you!

Just updating to say, that matters are still functioning, or not, in the same manner in v2.3.2 as before. That is, TTS works; announce does not, on a Sonos.

@krissen thanks for the update. What may be helpful is to see if the routine mechanism ever starts working. As soon as it does, then I think we can edit the command to follow that.

Is there any advantage of using Announce rather than TTS since TTS works?

Is there any advantage of using Announce rather than TTS since TTS works?

Minor advantage: it adds a chime prior to the message. Sounds trivial, but it's nice. 🤷♂ Could be achieved by playing a custom sound prior to message, too.

With announcement there are also other things possible like change voice, intonation, ....

I know over at Smartthings I used to use an application that's called EchoSpeaks and he could never integrate the Sonos as Amazon doesn't treat these like true Alexa devices apparently.

Sames issues here, must be a Sonos thing... Like SamB-GB set, they are always a little bit special in Alexa's eyes.

Hi, same problem here with an echo dot 2nd gen. TTS works, Announce doesn't.
Any idea when this could be fixed ?
Thanks

@septeven please open a new issue since you're reporting a different issue.

@alandtse
Huh I'm sorry but I'm encountering the exact same issue than other people here ?!
TTS works - announce doesn't (and other people here got the problem on other device than sonos one)...
You should let me know what's different maybe?

This is for Sonos and ecobee. You're claiming an issue with an Amazon device.

@alandtse
Well, if you do a quick search here, you'll find several occurences of ppl talking about the issue occuring both on sonos and amazon devices...
Anyway, I don't see the point to open another issue since it's clearly related.

@septeven Yeah its a slightly different issue because Sonos and Ecobee while can have Alexa through them they are not treated by Amazon and a full Alexa device and that's why these have stopped working. It seems your having an issue with an amazon device so best not to confused this thread with Amazon and Non-Amazon devices as this one specifically related to non Amazon devices.

@septeven As mentioned by @SamB-GB, others are monitoring this thread for a specific third-party device issue. For me to do anything for you on an echo dot I'll need logs and it doesn't make sense to add it to this thread since that's not the main problem.  That said, I appreciate the report but I do not plan to look into the issue without data to review. I'll mark this subthread offtopic so others can find relevant information for the thread.

Sames issues here, must be a Sonos thing... Like SamB-GB set, they are always a little bit special in Alexa's eyes.

I have a bose and I have the same issue the announce feature seems don't work

Unlike others, tts does not work for me either, on my Bose devices.
announce and tts both work on my Echo, but neither work on my Bose devices.

I'm having the same issue on my bose smart speaker, tts works but announce does not

Same here Yamaha YAS-109, tts works but announce does not


[iOS] Wrong build number

Description
Hi, first of all sorry for my bad English, I'm facing a problem when I try to build (Archive) from Xcode, after the build is finish my build number show wrong version, under the Xcode General tab I set to 35, but doesn't use the correct number.
Please see the attachment below

my version in General Tab

on organizer window before uploading to App Store it's show 1.6.5 (1) instead of 1.6.5 (35)

Version
0.70.4
Output of npx react-native info
System:
OS: macOS 13.0
CPU: (8) arm64 Apple M1
Memory: 71.16 MB / 8.00 GB
Shell: 5.8.1 - /bin/zsh
Binaries:
Node: 16.17.1 - ~/.nvm/versions/node/v16.17.1/bin/node
Yarn: 1.22.19 - ~/.nvm/versions/node/v16.17.1/bin/yarn
npm: 8.15.0 - ~/.nvm/versions/node/v16.17.1/bin/npm
Watchman: Not Found
Managers:
CocoaPods: 1.11.3 - /opt/homebrew/bin/pod
SDKs:
iOS SDK:
Platforms: DriverKit 21.4, iOS 16.0, macOS 12.3, tvOS 16.0, watchOS 9.0
Android SDK:
API Levels: 31, 32, 33
Build Tools: 30.0.2, 30.0.3, 31.0.0, 33.0.0
Android NDK: Not Found
IDEs:
Android Studio: 2021.3 AI-213.7172.25.2113.9014738
Xcode: 14.0.1/14A400 - /usr/bin/xcodebuild
Languages:
Java: 11.0.13 - /usr/bin/javac
npmPackages:
@react-native-community/cli: Not Found
react: 18.1.0 => 18.1.0
react-native: 0.70.4 => 0.70.4
react-native-macos: Not Found
npmGlobalPackages:
react-native: Not Found
Steps to reproduce
open project in Xcode -> Product -> Archive
Snack, code example, screenshot, or link to a repository

solved by manually changing CFBundleVersion value in info.plist


whitelist all domains, exclude certain $http request

Hi everyone,
I find this module very useful, however I wonder if there is a way to whitelist all domains at once? Or more precisely, my application sends $http requests to a relative path so it works both in the testing and the productive environment. Whitelisting the server's domain doesn't seem to work when making relative requests ...
Additionally, I wonder if it's possible to exclude a certain $http request to a whitelisted domain to avoid the loader to show up? I'm reloading messages every 2 seconds and don't want the loader to show up here.
Cheers,
Rob

Hi,
Is this still an issue you'd like to resolve?
If I understand you correctly there is actually two requests here, one to whitelist relative requests and one to blacklist certain urls on a whitelisted domain?
Chris

Hi Chris,
It is still an issue for me, yes :) Right now, I'm just not loading the module in my messages controller but have to include in separately in all other controllers - being able to blacklist the url of the messages request would make it a lot easier. Also, the ability to whitelist relative paths would make the loader work both locally and on the server - right now I only have the server domain whitelisted and the loader just doesn't show up in the local testing environment.
Rob

We can actually add some flag to whitelist relatives requests.
Feel free to PR it if you want.
Could be a good idea

robhei, the latest version includes a flag to whitelist local requests so that should help your development. Can you explain your blacklist request a little better?

Added https://github.com/wongatech/angular-http-loader/issues/28 to track the blacklisting urls request.

Functionality added in v0.1.7


Add support to specify ItemsPanel for ItemsControl elements such as GridView

Summary
We're looking to use GridView as a radio for our app but we need to have the GridView and its GridViewItems to take the full width of the container and currently the GridView as implemented in react-native-xaml doesn't do that and there doesn't seem to be an option to configure it to take up the full width.
Looking into the XAML tree we see that the ItemsPresenter used by the react-native-xaml GridView currently is using ItemsWrapGrid and searching around it seems like a solution to make a GridView take up the full width in XAML is to use ItemsStackPanel instead for the GridView's ItemsPanel https://stackoverflow.com/a/35451090, however there's no option to set this for react-native-xaml currently.
There are multiple different possible Panel but for now only ItemsWrapGrid and ItemsStackPanel  may be needed as options.
Motivation
This is needed to make GridView and other ItemsControl able to take up the full width of it's container. This would be useful for any user of GridView.
Basic Example
No response
Open Questions
No response

There's a lot of work here. It may be more straightforward for you to create a custom GridView that has the configuration you want. That'd also future proof you from any other gaps in react-native-xaml.

Will be making a custom GridView that uses ItemsStackPanel as the ItemsPanel.


Only depend on kernel32 and winapi on Windows

kernel32 and winapi are completely pointless for non-Windows builds. (They’re empty crates on non-Windows owing to a #![cfg(windows)] crate attribute so that they build.) They shouldn’t even be depended on for non-Windows builds.
The duplication is ugly, but necessary for now; see also https://github.com/rust-lang/cargo/issues/1007

Thanks for the pull request, and welcome! The Rust team is excited to review your changes, and you should hear from @huonw (or someone else) soon.
If any changes to this PR are deemed necessary, please add them as extra commits. This ensures that the reviewer can see what has changed since they last reviewed the code. The way Github handles out-of-date commits, this should also make it reasonably obvious what issues have or haven't been addressed. Large or tricky changes may require several passes of review and changes.
Please see the contribution instructions for more information.

For now we're idiomatically just adding these dependencies to avoid the duplication across all our crates. For example the rand crate also depends on these two crates. Build times shouldn't be affected by this very much at all and in general it seems like there aren't enough cons to warrant this for now. We can certainly do so once the associated Cargo issue is fixed!


Increase Kanojo render resolution

The Kanojos seem to be rendered lower than device resolution which makes them appear blurry. Higher resolutions should improve the look.

This might now actually be valid

Honestly I think this is just the textures being low res


Adjust DOI information so that it can be integrated with Metax/Etsin

Description

As part of the integration with #292 we would need to register DOIs for study and dataset

whenever new study or datasets are created we will register each as draft in Datacite
when we publish the folder we will publish the study and datasets in Datacite

We will need to add keywords to the datacite.json schema to be able to have keywords present for #292
A folder with the new changes will look like:
{
    "folderId": "folderid",
    "name": "mock folder",
    "description": "test mock folder",
    "published": "true",
    "metadataObjects": [
        {
            "accessionId": "EDAG3991701442770179",
            "schema": "study"
        },
        {
            "accessionId": "EGA123456",
            "schema": "sample"
        }
    ],
    "extraInfo": {
        "studyIdentifier": {
            "accessionId": "acccessionId",
            "identifier": {
                "identifierType": "DOI",
                "doi": "https://doi.url"
            },
            "url": "https://etsin.url",
            "types": {
                "resourceTypeGeneral": "Collection"
            }
        },
        "datasetIdentifiers": [
            {
                "accessionId": "acccessionId1",
                "identifier": {
                    "identifierType": "DOI",
                    "doi": "https://doi.url"
                },
                "url": "https://etsin.url",
                "types": {
                    "ris": "DATA",
                    "bibtex": "misc",
                    "citeproc": "dataset",
                    "schemaOrg": "Dataset",
                    "resourceTypeGeneral": "Collection"
                }
            },
            {
                "accessionId": "acccessionId2",
                "identifier": {
                    "identifierType": "DOI",
                    "doi": "https://doi.url"
                },
                "url": "https://etsin.url",
                "types": {
                    "ris": "DATA",
                    "bibtex": "misc",
                    "citeproc": "dataset",
                    "schemaOrg": "Dataset",
                    "resourceTypeGeneral": "Collection"
                }
            }
        ],
        "publicationYear": 2020,
        "publisher": "CSC"
    },
    "drafts": []
}

DoD (Definition of Done)

make necessary changes to datacite.json to add keywords
make changes to folders extraInfo to allow multiple dois
make changes to publication so it matches
link study and datasets in datacite
publish to datacite study and datasets, not only as draft but as registered and finable DOIs

Testing

unit and integration testing

will be continued in #367


Additional fpm options

Possibility to set --category and --directories reference https://github.com/jordansissel/fpm/wiki
Updated README file

I have made a diff between #46 and master this PR is the result. These are the only two missing options we would love to see in the pkgr.

Thanks!

@crohr when You have merged this branch You can close #46


"edit this page" in the docs still points to separate repo

At the bottom of each page in our docs we have a link to edit:

However, after moving docs from weave-gitops-docs to weave-gitops/website/docs this link has broken.
As an example, the link on https://docs.gitops.weave.works/docs/cluster-management/getting-started/index.html points to https://github.com/weaveworks/weave-gitops-docs/edit/main/versioned_docs/version-0.6.2/cluster-management/getting-started.mdx
cc @luizbafilho

Rapid :) thanks @Callisto13


Feature request: Add rainbow for new empty line with auto indents

Automatically add rainbow for new empty line who inherits an auto-indent param from the previous line.

This is definitely a good idea. If you wish to contribute this feature, feel free to do so, I'm not sure when I will get to this.

Could you share a document/example where this is the case? I found that Visual Studio inserts virtual indentation that is only render but does not exist in the actual text. If the line contains actual whitespaces or tabs, they should be colored correctly.

Could you share a document/example where this is the case?

In this case, the visual studio cursor gives an auto-indent after pressing enter, but IndentRainbow does not react to this.

I found that Visual Studio inserts virtual indentation that is only render but does not exist in the actual text.

This should be why IndentRaimbow does not react to auto-indent creation by pressing enter.
I found out that if I add a space at one of the ends of the auto-indent lines, the rainbow will appear even if I delete that space later, the rainbow will keep anyway.
Even that's the case. I found it very inconvenient to add and then delete space for every empty line to get them to show the rainbow.
It would be great if it could be improved.

I'd like to propose a "one step farther" variation: I'd like to see lines that are blank (only whitespace) should always show the same rainbow indent.  For example, in move2win's screenshot above, lines 76-83 would all have the same rainbow colors as like 75.
I think it is okay to show these even though there are no characters there because the goal of the extension is to show the structure of code, not to visualize space/tab characters.

This is definitely a good idea, however implementation is probably not that easy since we would now need to store the indentation of the last line. Doable but not as easy as other features that have been added throughout the years 😅


Update continuous-integration-faqs.md

Harness Developer Pull Request
Thanks for helping us make the Developer Hub better. The PR will be looked at
by the maintainers.
What Type of PR is This?

[ ] Issue
[ ] Feature
[ ] Maintenance/Chore

If tied to an Issue, list the Issue(s) here:

Issue(s)

House Keeping
Some items to keep track of. Screen shots of changes are optional but would help the maintainers review quicker.

[ ] Tested Locally
[ ] Optional Screen Shoot.

Please check the Execution Link of the Pipeline for the Website Draft URL. This is located in the Preview Step and also is available in #hdh_alerts. E.g Website Draft URL: https://unique-id--harness-developer.netlify.app

@aavloni sent you a Slack. Can combine these PRs into a bigger change e.g more than one-two liners, there is some overhead we have when a PR is open. Also mind setting a reviewer, in this case @deepanshuHarness  please? Thanks!


Float16 TFLite models with multiple interpreters doesn't share weights but bloats memory

System information

Linux 5.11.4-arch1-1 #1 SMP PREEMPT Sun, 07 Mar 2021 18:00:49 +0000 x86_64 GNU/Linux
TensorFlow 2.4.1 from tensorflow-opt-cuda package (https://archlinux.org/packages/community/x86_64/tensorflow-opt-cuda)

Describe the current behavior
When we create multiple interpreters per single model (e.g. for thread-safety reasons) the expected behavior is that all interpreters share model weights. And that's statement is true when the model is float32 model:
$ ./minimal mem-bloat-float32.tflite
initial mem 1 MB
interpreter #1, mem 139 MB
interpreter #2, mem 141 MB
interpreter #3, mem 144 MB
interpreter #4, mem 146 MB
interpreter #5, mem 148 MB
interpreter #6, mem 150 MB
interpreter #7, mem 152 MB
interpreter #8, mem 154 MB
interpreter #9, mem 156 MB

But when the same model had been converted to be float16 the weights are not shared anymore and memory is bloated so that each interpreter has its own copy of model weights:
$ ./minimal mem-bloat-float16.tflite
initial mem 1 MB
interpreter #1, mem 206 MB
interpreter #2, mem 341 MB
interpreter #3, mem 476 MB
interpreter #4, mem 610 MB
interpreter #5, mem 745 MB
interpreter #6, mem 880 MB
interpreter #7, mem 1015 MB
interpreter #8, mem 1149 MB
interpreter #9, mem 1284 MB

Describe the expected behavior
The expected behavior is that multiple interpreters share weights for the same model, whenever it's float16 or float32 model.
Standalone code to reproduce the issue

unzip TFLite models: mem-bloat-tflite.zip
build TFLite minimal example with the following code within tensorflow/tensorflow/lite/examples/minimal.cc:

#include <cstdio>

#include "tensorflow/lite/interpreter.h"
#include "tensorflow/lite/kernels/register.h"
#include "tensorflow/lite/model.h"
#include "tensorflow/lite/optional_debug_tools.h"

#if defined(_WIN32)
#include <windows.h>
#include <psapi.h>

#elif defined(__unix__) || defined(__unix) || defined(unix) || (defined(__APPLE__) && defined(__MACH__))
#include <unistd.h>
#include <sys/resource.h>

#if defined(__APPLE__) && defined(__MACH__)
#include <mach/mach.h>

#elif (defined(_AIX) || defined(__TOS__AIX__)) || (defined(__sun__) || defined(__sun) || defined(sun) && (defined(__SVR4) || defined(__svr4__)))
#include <fcntl.h>
#include <procfs.h>

#elif defined(__linux__) || defined(__linux) || defined(linux) || defined(__gnu_linux__)
#include <stdio.h>

#endif

#else
#error "Cannot define getCurrentRSS( ) for an unknown OS."
#endif

/**
 * Returns the current resident set size (physical memory use) measured
 * in bytes, or zero if the value cannot be determined on this OS.
 */
size_t getCurrentRSS( )
{
#if defined(_WIN32)
    /* Windows -------------------------------------------------- */
    PROCESS_MEMORY_COUNTERS info;
    GetProcessMemoryInfo( GetCurrentProcess( ), &info, sizeof(info) );
    return (size_t)info.WorkingSetSize;

#elif defined(__APPLE__) && defined(__MACH__)
    /* OSX ------------------------------------------------------ */
    struct mach_task_basic_info info;
    mach_msg_type_number_t infoCount = MACH_TASK_BASIC_INFO_COUNT;
    if ( task_info( mach_task_self( ), MACH_TASK_BASIC_INFO,
        (task_info_t)&info, &infoCount ) != KERN_SUCCESS )
        return (size_t)0L;      /* Can't access? */
    return (size_t)info.resident_size;

#elif defined(__linux__) || defined(__linux) || defined(linux) || defined(__gnu_linux__)
    /* Linux ---------------------------------------------------- */
    long rss = 0L;
    FILE* fp = NULL;
    if ( (fp = fopen( "/proc/self/statm", "r" )) == NULL )
        return (size_t)0L;      /* Can't open? */
    if ( fscanf( fp, "%*s%ld", &rss ) != 1 )
    {
        fclose( fp );
        return (size_t)0L;      /* Can't read? */
    }
    fclose( fp );
    return (size_t)rss * (size_t)sysconf( _SC_PAGESIZE);

#else
    /* AIX, BSD, Solaris, and Unknown OS ------------------------ */
    return (size_t)0L;          /* Unsupported. */
#endif
}

#define TFLITE_MINIMAL_CHECK(x)                              \
  if (!(x)) {                                                \
    fprintf(stderr, "Error at %s:%d\n", __FILE__, __LINE__); \
    exit(1);                                                 \
  }

int main(int argc, char* argv[])
{
  if (argc != 2) {
    fprintf(stderr, "minimal <tflite model>\n");
    return 1;
  }
  const char* filename = argv[1];

  printf("initial mem %d MB\n", getCurrentRSS() >> 20);

  // Load model
  std::unique_ptr<tflite::FlatBufferModel> model = tflite::FlatBufferModel::BuildFromFile(filename);
  TFLITE_MINIMAL_CHECK(model != nullptr);

  tflite::ops::builtin::BuiltinOpResolver resolver;
  tflite::InterpreterBuilder builder(*model, resolver);

  std::unique_ptr<tflite::Interpreter> interpreter_list[9];
  for (auto &interpreter : interpreter_list) {

    builder(&interpreter, 1);
    TFLITE_MINIMAL_CHECK(interpreter != nullptr);
    TFLITE_MINIMAL_CHECK(interpreter->AllocateTensors() == kTfLiteOk);
    interpreter->Invoke();

    printf("interpreter #%d, mem %d MB\n", &interpreter - &interpreter_list[0] + 1, getCurrentRSS() >> 20);
  }

  return 0;
}

Other info / logs
Both versions of model had been converted from this protobuf file: mem-bloat-protobuf.zip

Thanks for your valuable feedback. Currently, each TensorFlow Lite interpreter owns each memory space by design. We will consider this as a feature request for increasing memory sharing across the mulitple interpreter interfaces.
@daverim @terryheo any thoughts on this?

Interpreter can share data in flatbuffer file which contains constant tensors.
But each interpreter needs its own memory to store intermediate tensors. so it's natural to see a certain amount of memory increasement.
Regarding your testing, I have few comments.

Could you check /proc/self/statm shared pages?
According to https://www.kernel.org/doc/html/latest/filesystems/proc.html, VmRSS = RssAnon + RssFile + RssShmem
which means VmRSS contains RssFile size. So you need to check it separately.
If RssFile is zero, please confirm your model is using MMAPAllocation() https://github.com/tensorflow/tensorflow/blob/master/tensorflow/lite/model_builder.cc#L50

@terryheo

Interpreter can share data in flatbuffer file which contains constant tensors. But each interpreter needs its own memory to store intermediate tensors. so it's natural to see a certain amount of memory increasement.

That's right, but the difference between models is datatype (float32 vs float16), so it's counter-intuitive to see that float32 version do share weights and float16 does not.
The memory usage gives insights of what's going on with memory usage.
For float32 we've got: 1, 139, 141, 144, 146 etc.
That means 137 MB of constant tensors in float32 + 2 MB for intermediate tensors per interpreter.
So model of the memory usage is (roughly): 137 + 2 * interpreters_count MB
For float16 we've got: 1, 206, 341, 476, 610 etc.
That means 69 MB of constant tensors in float16 + 137 MB for intermediate tensors per interpreter
So model of the memory usage is (roughly): 69 + 137 * interpreters_count MB
..and 137 MB for intermediate tensors looks very similar to 137 MB of the float32 model, so I assume there's conversion of float16 constant tensors to float32 constant tensors within each interpreter.

Could you check /proc/self/statm shared pages?
I modified both the program and TFLite sources to show /proc/self/statm and MMAPAllocation::IsSupported() (at the location you pointed)

$ ./minimal mem-bloat-float32.tflite
/proc/self/statm -> 2289 486 432 726 0 105 0
initial mem 1 MB
MMAPAllocation::IsSupported() is false
/proc/self/statm -> 36798 35848 1341 726 0 34614 0
interpreter #1, mem 140 MB
/proc/self/statm -> 37329 36442 1341 726 0 35145 0
interpreter #2, mem 142 MB
/proc/self/statm -> 37893 36970 1341 726 0 35709 0
interpreter #3, mem 144 MB
/proc/self/statm -> 38424 37498 1341 726 0 36240 0
interpreter #4, mem 146 MB
/proc/self/statm -> 38988 38026 1341 726 0 36804 0
interpreter #5, mem 148 MB
/proc/self/statm -> 39519 38554 1341 726 0 37335 0
interpreter #6, mem 150 MB
/proc/self/statm -> 40083 39148 1341 726 0 37899 0
interpreter #7, mem 152 MB
/proc/self/statm -> 40614 39676 1341 726 0 38430 0
interpreter #8, mem 154 MB
/proc/self/statm -> 41178 40204 1341 726 0 38994 0
interpreter #9, mem 157 MB
$ ./minimal mem-bloat-float16.tflite
/proc/self/statm -> 2289 501 447 726 0 105 0
initial mem 1 MB
MMAPAllocation::IsSupported() is false
/proc/self/statm -> 53770 52848 1301 726 0 51586 0
interpreter #1, mem 206 MB
/proc/self/statm -> 88268 87352 1301 726 0 86084 0
interpreter #2, mem 341 MB
/proc/self/statm -><PHONE_NUMBER>63 1301 726 0 120627 0
interpreter #3, mem 476 MB
/proc/self/statm -><PHONE_NUMBER>54 1301 726 0 155100 0
interpreter #4, mem 610 MB
/proc/self/statm -><PHONE_NUMBER>42 1301 726 0 189606 0
interpreter #5, mem 745 MB
/proc/self/statm -><PHONE_NUMBER>32 1301 726 0 224079 0
interpreter #6, mem 880 MB
/proc/self/statm -><PHONE_NUMBER>20 1301 726 0 258552 0
interpreter #7, mem 1014 MB
/proc/self/statm -><PHONE_NUMBER>86 1301 726 0 293018 0
interpreter #8, mem 1149 MB
/proc/self/statm -><PHONE_NUMBER>98 1301 726 0 327562 0
interpreter #9, mem 1284 MB

@terryheo
I decided to rebuild the example with -DTFLITE_ENABLE_MMAP=ON and now MMAPAllocation::IsSupported() is true, but result is the same:
$ ./minimal mem-bloat-float16.tflite
/proc/self/statm -> 2291 487 432 727 0 105 0
initial mem 1 MB
MMAPAllocation::IsSupported() is true
/proc/self/statm -> 53772 52885 18311 727 0 34612 0
interpreter #1, mem 206 MB
/proc/self/statm -> 88270 87389 18311 727 0 69110 0
interpreter #2, mem 341 MB
/proc/self/statm -><PHONE_NUMBER>00 18311 727 0 103653 0
interpreter #3, mem 476 MB
/proc/self/statm -><PHONE_NUMBER>91 18311 727 0 138126 0
interpreter #4, mem 610 MB
/proc/self/statm -><PHONE_NUMBER>79 18311 727 0 172632 0
interpreter #5, mem 745 MB
/proc/self/statm -><PHONE_NUMBER>69 18311 727 0 207105 0
interpreter #6, mem 880 MB
/proc/self/statm -><PHONE_NUMBER>57 18311 727 0 241578 0
interpreter #7, mem 1015 MB
/proc/self/statm -><PHONE_NUMBER>23 18311 727 0 276044 0
interpreter #8, mem 1149 MB
/proc/self/statm -><PHONE_NUMBER>35 18311 727 0 310588 0
interpreter #9, mem 1284 MB

Let me humbly emphasize that weights sharing between interpreters is very important. With our runtime environment we're running up to eight threads of realtime inferences with precomputed ~130 MB of float32 weights. It's counter-productive to copy ~130 MB of weights per each interpreter. And also it would be better to have ~65 MB of float16 weights shared between eight interpreters/threads.

..and 137 MB for intermediate tensors looks very similar to 137 MB of the float32 model, so I assume there's conversion of float16 constant tensors to float32 constant tensors within each interpreter.

I think this is the case since there is no float16 native kernels. @jdduke, @daverim FYI,
I wonder if you tried full integer quantization which saves more memory. https://www.tensorflow.org/lite/performance/post_training_quantization
I guess it also allows to share constant tensors.

@terryheo

I wonder if you tried full integer quantization which saves more memory
At some point I will, but I'd split the whole graph into preparation (float32), inference (int quantization) and postprocessing (float32) parts. Currently it would be very beneficial to have just float16. More to say, it's shame that previous implementation of the same model had been done manually with float16 arithmetic (== two times less memory) and the same performance. Also, for a single thread there was no need to have 2 MB of intermediate tensors per interpreter. So I hope TFLite will improve in this direction.

Hi @barabanus . Your request is quite reasonable, though there would be quite a bit of complexity involved to make this work properly, due to the lazy manner in which float16 weights are currently "inflated" at runtime. Terry's suggestion to try int8 quantization is probably the best approach to both reduce the model size but also enable weight sharing.
That said, for Q2 we are looking into supporting native float16 execution paths that operate natively on float16 weights for ARM devices. There are some issues involved as it relates to accuracy (the most widely available float16 ARM intrinsics do not accumulate into float32, though the latest devices to support this), but we'll also be working on tooling to validate that the relaxed runtime precision doesn't significantly degrade accuracy.

Hi,
Thank you for opening this issue. Since this issue has been open for a long time, the code/debug information for this issue may not be relevant with the current state of the code base.
The TFLite team is constantly improving the framework by fixing bugs and adding new features. We suggest you try the latest TensorFlow version with the latest compatible hardware configuration which could potentially resolve the issue. If you are still facing the issue, please create a new GitHub issue with your latest findings, with all the debugging information which could help us investigate.
Please follow the release notes to stay up to date with the latest developments which are happening in the TFLite space.
Thanks.


[HealthChecker] allow automation for update

I currently have <IP_ADDRESS>5 and I am aware that an update is available.  However I cannot force the script to update in automation with the Confirm:$False switch
Seems to me this should be a simple enough switch to allow since it creates a backup anyway.  As an alternative I would only be able to update when running interactively and skip the version check in automation.

This issue should have been solved with a later build. Now in HC, we don't even prompt for do you want to download the latest version. Please just install the latest version.
#1111
#1098

Closing issue as this should have been resolved.


A ring attention with flash attention kernel implementation

Hi! Thank you for your work on implementing the ring attention in pytorch!
I've just tried to implement a ring_flash_attn_qkvpacked_func (corresponding to flash_attn_qkvpacked_func in flash attention) with the flash attention kernels here: https://github.com/zhuzilin/ring-flash-attention/
Maybe this can help :)

Updates:

ring_flash_attn_varlen_qkvpacked_func is also implemented.

@zhuzilin if you do embark on the pull request, the minimal features would be the ring IPC, able to specify the maximum number of ring passes (as I believe they must have curriculum learned the local attention to a full global, or mixed local and global using variable ring passes throughout the transformer), and finally, if you have the bandwidth, specialize masking logic for striped attention to balance the workload

thank you! 🚀 ❤

@zhuzilin actually, after looking into CUDA IPC stuff, your approach may be the best for now

Are you planning on upstreaming the finalized implementation to Tri Dao's official flash attention repository?

I'll draft an issue to the flash attention repo to see if they have interest in merging (or design a better version) in the official repo :)

after looking into CUDA IPC stuff, your approach may be the best for now
yeah, using nccl based p2p communication would be at least an easier way to implement with acceptable performance.

@zhuzilin awesome work, we‘ll organize a little hack today 19:00 UTC on the cuda-mode discord to hack your impl - just fyi https://x.com/neurosp1ke/status/1760558683136589983

i also wanted to do some LOTR references, but one meme is enough

oh... sorry, I took a day off and missed all the notification from github....

@zhuzilin i think my version is working too now, with a modified forward flash attention kernel to minimize ring passes
thanks for sharing your repo for proof of concept!

@lucidrains thanks a lot for your hard work & very interesting that you used a custom triton kernel! :-)

@andreaskoepf thanks! seems like there's still issue with backwards, but i'll leave it to someone or some team to fix. yup, i think the forwards requires the key, values to be iterated on the outer loop (to save on extraneous ring passes), so the reduced values needs to be stored and passed back in on the next ring pass. but i could be wrong and there may be a simpler way

it isn't correct, probably something small with regards to how i'm using the flash attention api
feel free to submit a PR, i likely won't be able to get to this as i'll be running around bay area meeting people next month

@ericauld ah, good news, the cuda backwards actually yielded the right gradients (full attention, no causal or key padding mask). it is my naive version that is broken
alright, i guess it is safe to remove the wip

@lucidrains Knowing the LSE doesn't actually help you compute the backwards for softmax though, correct? The derivative of LSE is softmax, not the other way around. What am I missing, and what is the utility of returning the LSE?

What am I missing, and what is the utility of returning the LSE?

The returned log sum exp is what allows to apply flash-attenion in a blockwise manner (e.g. without it it wouldn't be possible to use flash-attn to implement ring-attn). See ring_flash_attn/utils.py#L19-L21.

Ah, alright. That's what I'm missing. Makes sense :)


Adding script to carry forward SOH from the client.

Does not perform SOH calculation server side, just carries forward the previous results when missing.

Testing in progress


How can I extends the props of a component?

Im trying to extends the props of the accordion component and I'm having some truble getting it done.
For example I would like to have a prop where I can pass a boolean to define where the accordion has borders or not. Something like this
const AccordionItem = React.forwardRef<
	React.ElementRef<typeof AccordionPrimitive.Item>,
	React.ComponentPropsWithoutRef<typeof AccordionPrimitive.Item>
>(({ className, ...props }, ref) => (
	<AccordionPrimitive.Item
		ref={ref}
		className={classNames(
			props.hasBorder ? "border-b border-b-slate-200" : "",
			className
		)}
		{...props}
	/>
));

But I've been trying to extend the props but I having trubble finding a way to do that. Any help?

You can create an interface that extends the props of the AccordionPrimitive.Item, something like
interface AccordionItemProps extends React.ComponentPropsWithoutRef<typeof AccordionPrimitive.Item> {
  hasBorder?: boolean
}

const AccordionItem = React.forwardRef<
  React.ElementRef<typeof AccordionPrimitive.Item>,
  AccordionItemProps
>(({ className, ...props }, ref) => (
  <AccordionPrimitive.Item
    ref={ref}
    className={cn(
      props.hasBorder ? "border-b border-b-slate-200" : "",
      className
    )}
    {...props}
  />
))
AccordionItem.displayName = "AccordionItem"

Exactly what @emicba said. This is the recommended way.
I'll add this to the docs. I'm going to keep this open for now.

Thank you so much guys! It worked perfectly

Kindly share how to pass props as string, not just boolean.

I am having an issue where I extend the props like in the example
interface DialogContentProps
  extends React.ComponentPropsWithoutRef<typeof DialogPrimitive.Content> {
  noClose?: boolean;
}

However, when I use my component with <DialogContent noClose={true}>, I get error
React does not recognize the `noClose` prop on a DOM element. If you intentionally want it to appear in the DOM as a custom attribute, spell it as lowercase `noclose` instead. If you accidentally passed it from a parent component, remove it from the DOM element.```

in the console. If I lowercase it to noclose, I get a separate error of

app-index.js:31 Warning: Received true for a non-boolean attribute noclose.
If you want to write it to the DOM, pass a string instead: noclose="true" or noclose={value.toString()}.

const Select = SelectPrimitive.Root
For the select, Is there any way to extend it with a custom Prop ?

Kindly share how to pass props as string, not just boolean.

I tried it by changing the interface type to string and it works.

This issue has been automatically closed because it received no activity for a while. If you think it was closed by accident, please leave a comment. Thank you.

For SelectTrigger and how to change the CaretDown I extended the type like this
type SelectTriggerProps = React.ComponentPropsWithoutRef<typeof SelectPrimitive.Trigger> & {
  Icon?: React.ReactNode;
}

<SelectTrigger
     Icon={<Calendar className="h-5 w-5" />}
     className="w-[180px] rounded-none border-0 ring-0 focus:border-none focus:ring-0 focus:ring-offset-2 active:border-none">
     <SelectValue placeholder="Theme" />
</SelectTrigger>


Falcon agent abnormal exit with the err, Please helpp me

Falcon agent running period of time without any err message. But unexpected, the agent exit with the err
acquirep: p->m=859536485376(92) p->status=1
fatal error: acquirep: invalid p state
fatal error: unexpected signal during runtime execution
How could i solve it.
Thanks!

You can check $WorkDir/$moduleName/log/logs/xxx.log
In your case,the module name is agent.

@shaohk more information? or solved?

solved, the reason is go'version lowwer. update go to 1.9, solved.
thx

great ^_^


Feature for Issue #25

Hello @Nilhcem,
Here is the first version of the requested feature #25. This is the first time, when I code something for an open source project. Any suggestions, advices, improvements proposals are welcome.
The commit 3367f11 contains the description of my changes. In addition, I have decided to add the final modifier to a couple of internal variables.
I have tried to follow the style of the code that you have.
p.s. just in case, I have added an option to enable/disable the system tray feature in the configuration file.
Kind regards,
Vest

Small addition, maybe it makes sense to close the application, when the "X" button is clicked (or the Exit menu item is selected), but when the window is minimized - hide it and create the tray icon.

Many thanks for your smartly implemented Pull Request!
I've merged it but have temporarily disabled the application.tray.use property (set to false), as the tray feature does not work well on GNOME shell (and some other desktop managers).
See http://stackoverflow.com/questions/29995727/java-systemtray-icon-does-not-always-work

@Nilhcem, thank you for the merge. I will take a look at the behavior, what my code does.
Do you have other suggestions what else I can add? E.g. create checkbox that helps to enable/disable the tray.
Or, what worries me is that the window is always minimized, if you try to close it. Who knows, maybe it is useless, and I have to minimize the window into the tray, when the user clicks a corresponding button only?

In terms of features it seems fine. I don't see anything else to add.
I agree the  'close-to-put-to-system-tray' is quite disturbing but may be common for Windows users.
Maybe we could just enable this feature for Windows users, so that we could bypass the gnome/kde issue in the same time

Ok, I will check this. I have an Ubuntu machine.
By the way, I have a short questions regarding the removal of final keywords. What was the intention of doing this?
When I was writing them, I assumed that it makes the code more defensive against accident changes of references.

I mostly stayed consistent with the existing code base (there's a lot of things I have done and regret, mostly the tab indentation).
You may be right in adding them.
My point of view is that the final keywords are great when making an API, less for an open source application where I prefer to have less code.
I'm not keen on defensive programming and prefer to have smart PRs that do not alter the reference of a method parameter, for instance.

Ok, clear.
Thanks.

I found what happened with the frame in Linux: https://community.oracle.com/thread/1352367
I have exactly the same behavior as written in the thread - the Iconify event is called twice.
I will probably create a new issue in future and investigate how I can fix it (without using some "trigger" variable, or time).


Can't use it out of the box with esbuild

css    | CssSyntaxError: tailwindcss: /Users/peterberkenbosch/code/nex13/rapid/app/assets/stylesheets/shadcn.css:223:3: The `text-destructive` class does not exist. If `text-destructive` is a custom class, make sure it is defined within a `@layer` directive.

Trying to wrap it in a @layer does not seem to work for me.

Yeah, did that.. will setup an public repo in a little bit with some samples to try to figure it out.

I've dealt with this before, I can't remember how I fixed it. Is this an existing app or a new one that you're integrating with...did you make any edits or is this out of the box? Oh esbuild - hmm, I haven't tested it on that yet, I should've thats a big oversight, I'll look into that shortly..

No worries, it's on my starter app (and a rails edge one).. playground with my current problem: https://github.com/peterberkenbosch/shadcn-demo
I have dealt with this before too, and will keep looking what I needed to do to solve this. Was hoping that postcss nesting was picking it up properly. Will google and play some more.

Hey - so you had a slight misconfig in your tailwind.config.js
Here's what it looks like now:
const shadcnConfig = require("./config/shadcn.tailwind");

module.exports = {
  plugins: [
    require("@tailwindcss/forms"),
    require("@tailwindcss/typography"),
    require("@tailwindcss/aspect-ratio"),
    require("@tailwindcss/line-clamp"),
    require("@tailwindcss/container-queries"),
  ],

  content: [
    "./app/helpers/**/*.rb",
    "./app/javascript/**/*.js",
    "./app/views/**/*.erb",
  ],

  theme: {
    extend: {},
  },
  variants: {
    extend: {},
  },
  ...shadcnConfig,
};

Basically by having it above the theme/extend it was clearing it out.

@aviflombaum duh.. thanks man! Working like a charm now!


readme restructure

This Readme structure could be marginally better.
It is probably not a priority and you can probably borrow ideas from this version if you ever want to change the appearance of the README.

Agreed, I'll copypaste the relevant version into my Readme. Thank you, it will look much better!


[Question] Server Side Permission Policy Provider

Hi Mukesh,
I just added permission based policy to the server side.
But whatever I do I get unauthorized even with the admin role.
I added the PermissionAuthorizationHandler and the PermissionPolicyProvider to tthe server Api project but I don't see where you use them. I assume it should be in the startup class.
Thanks for your help.

Add Permissions to the Static Constant Class, BlazorHero.CleanArchitecture.Shared.Constants.Permission - public const string Users = "Users"; is an example.
The GeneratePermissionsForModule method will generate the required permissions strings for you, Create,View,Edit,Delete.
Once you add a new permission, you need to manually ensure that the ADMIN Role has this permission, since this is a role-based permission. BlazorHero.CleanArchitecture.Infrastructure.DatabaseSeeder is where the seeding happens when the application starts.
Under the AddAdministrator method , somewhere around the 80th line, add this await _roleManager.GeneratePermissionClaimByModule(adminRole, PermissionModules.xxxxx);. This adds the new permission to admin role. Once the app is started, check your db - RoleClaims table to check if this permission exists.

That's for the backend. Now for the frontend to receive this newly updated permission list, you need to make some changes on the Controller Service level.

 BlazorHero.CleanArchitecture.Infrastructure.Services.Identity is the required service.
Line #76 is where you would want to add a allPermissions.GetPermissions(typeof(Permissions.xxxx), roleId);

This should get your permissions working. Similarly, you can add the attributes as well when required. [Authorize(Policy = Permissions.Users.Edit)]


Shoutbox data is empty

Related upstream issue: https://github.com/cheeplusplus/fa.js/issues/17
Filing for visibility.

Fixed in v0.0.2


Scheduling looks unfair

Repro:
use std::net::{TcpStream, TcpListener};
use smol::{Async, Task};
use std::io::Error;

use futures_util::{select, AsyncWriteExt, AsyncReadExt};
use futures_util::future::{self, FutureExt};

async fn task(task_id: u32) -> Result<(), Error> {
    let listener = Async::<TcpListener>::bind("<IP_ADDRESS>:0")?;
    let addr = listener.get_ref().local_addr()?;
    println!("Listening on {}", addr);
    let accept = listener.accept();
    let connect = Async::<TcpStream>::connect(&addr);
    let (writer, reader) = future::join(accept, connect).await;
    let ((mut writer, _), mut reader) = (writer?, reader?);

    let mut buf = [0u8; 4];
    for i in 1..10_000_000u32 {
        let w = task_id.to_ne_bytes();
        select! {
            _ = writer.write(&w).fuse() => { }
            _ = reader.read(&mut buf).fuse() => { }
        }
        if i % 100_000 == 0 {
            println!("task {} processed {}", task_id, i);
        }
    }

    Ok(())
}

fn main() {
    smol::run(async {
        let t1 = Task::local(async {
            task(1).await.unwrap();
        });
        let t2 = Task::local(async {
            task(2).await.unwrap();
        });
        t1.await;
        t2.await;
    })
}

I would expect it to switch from t1 to t2 (or t2 to t1, depends on the run), but it doesn't until first one is complete.

So I straced it, what I see is (interesting part):
recvfrom(10, "\2\0\0\0", 4, 0, NULL, NULL) = 4
recvfrom(10, 0x55bb6674b960, 4, 0, NULL, NULL) = -1 EAGAIN (Resource temporarily unavailable)
<- this is poll_read() / read_with_mut()
epoll_ctl(5, EPOLL_CTL_MOD, 10, {EPOLLIN|EPOLLRDHUP|EPOLLONESHOT, {u32=4, u64=4}}) = 0 <- this is source.readable() registering task
sendto(14, "\2\0\0\0", 4, MSG_NOSIGNAL, NULL, 0) = 4 <- always succeeds because tcp write buffer is huge
sendto(14, "\2\0\0\0", 4, MSG_NOSIGNAL, NULL, 0) = 4
recvfrom(10, "\2\0\0\0", 4, 0, NULL, NULL) = 4 <- this is poll_read() again, the reactor doesn't know if it's readable but we try it anyway and succeed (because we just sent some bytes in there)

It never gives up control to the reactor (no epoll_wait). My guess would be that it happens because read_with_/write_with_ is optimistic and tries to perform read/write without actually checking if the source is readable/writable.

I have witnessed similar behavior with a non-trivial async-std application. The solution that I found was to throw some task::yield_now().await calls  (async-std) in a couple of key places to ensure one task wouldn't dominate the runtime.
Unfortunately I wasn't able to file a bug here, but it is reproducible with the application, but to reproduce it, requires some Docker containers spun up for some integration testing of the whole app. :frowning:

Does it change behavoir if futures_util::join! is used?

I do also think it is the expected behaviour. Take a look at https://rust-lang.github.io/async-book/06_multiple_futures/02_join.html

@zserik no.
@bjornmolin how is this expected? It is not t1.await; t2.await;, tasks were spawned.

It's not an issue with awaiting task1 before task2. Since these tasks are spawned onto smol with Task::local, they should operate concurrently regardless of the order of the awaits. Further, spawning them at all doesn't change the outcome. An even simpler repro could exist by joining two calls to the task function. e.g.
fn main() {
  smol::run(future::try_join(task(1), task(2))).unwrap();
}

While both tasks should be polled concurrently task(1) completes it's iteration before task(2)'s iteration begins. Both futures print "Listening on" before task(1) starts it's iteration, so the problem is definitely that it's refusing to yield.

The following works as expected, but I explicitly needed to remove the async blocks around the task(n) calls...
use std::net::{TcpStream, TcpListener};
use smol::{Async, Task};
use std::io::Error;

use futures_util::{select, AsyncWriteExt, AsyncReadExt};
use futures_util::future::{self, FutureExt};

async fn task(task_id: u32) -> Result<(), Error> {
    let listener = Async::<TcpListener>::bind("<IP_ADDRESS>:0")?;
    let addr = listener.get_ref().local_addr()?;
    println!("Listening on {}", addr);
    let accept = listener.accept();
    let connect = Async::<TcpStream>::connect(&addr);
    let (writer, reader) = future::join(accept, connect).await;
    let ((mut writer, _), mut reader) = (writer?, reader?);

    let mut buf = [0u8; 4];
    for i in 1..10_000_000u32 {
        let w = task_id.to_ne_bytes();
        select! {
            _ = writer.write(&w).fuse() => { }
            _ = reader.read(&mut buf).fuse() => { }
        }
        if i % 100_000 == 0 {
            println!("task {} processed {}", task_id, i);
        }
    }

    Ok(())
}

fn main() {
    smol::run(async {
        let t1 = Task::blocking(task(1));
        let t2 = Task::blocking(task(2));
        future::join(t1, t2).await;
    })
}

Seems to work as expected with #151

Ah interesting...I was way too fast in my conclusion and is obviously learning some good basic stuff :smile:
It has something to do with what's in the task function since the code below is also working as you expected.
use std::net::{TcpStream, TcpListener};
use smol::{Async, Task};
use std::io::Error;
use std::time::Duration;

use futures_util::{select, AsyncWriteExt, AsyncReadExt};
use futures_util::future::{self, FutureExt};

async fn task(task_id: u32) -> Result<(), Error> {
    println!("Task start {}", task_id);
    async_std::task::sleep(Duration::from_secs(5)).await;
    println!("Task done {}", task_id);

    Ok(())
}

fn main() {
    smol::run(async {
        let t1 = Task::local(async {
            task(1).await.unwrap();
        });
        let t2 = Task::local(async {
            task(2).await.unwrap();
        });
        t1.await;
        t2.await;
    })
}

Ah interesting...I was way too fast in my conclusion and is obviously learning some good basic stuff :smile:
It has something to do with what's in the task function since the code below is also working as you expected.
use std::net::{TcpStream, TcpListener};
use smol::{Async, Task};
use std::io::Error;
use std::time::Duration;

use futures_util::{select, AsyncWriteExt, AsyncReadExt};
use futures_util::future::{self, FutureExt};

async fn task(task_id: u32) -> Result<(), Error> {
    println!("Task start {}", task_id);
    async_std::task::sleep(Duration::from_secs(5)).await;
    println!("Task done {}", task_id);

    Ok(())
}

fn main() {
    smol::run(async {
        let t1 = Task::local(async {
            task(1).await.unwrap();
        });
        let t2 = Task::local(async {
            task(2).await.unwrap();
        });
        t1.await;
        t2.await;
    })
}

@yoshuawuyts suggested I include some details of a problem I'm investigating here:
I am investigating a performance issue and it looks like what was previously parallel computation is now concurrent, and that's not desired (duh).
+--------------------+                  +------------------------+
|                    |  channel.send()  |                        |
|   BufReader task   |                  |                        |
|   off TcpStream    +----------------->+ Worker task in loop w/ |
|                    |                  | channel.read()         |
+--------------------+                  |                        |
                                        |                        |
                                        +------------------------+

While developing, I added a task::yield_now().await into place after I send on an async-std channel, that seemed to make things seem more parallel, but that makes me think the application is still not properly parallelizing its execution of tasks on smol.
interestingly, running the same code on async-std 1.5.0 (no smol) and 1.6.0 (much smol) definitely shows different performance when I remove my yield_now hack.  With async-std 1.6.0 it seems that one task is dominating the reactor and never cooperates with a concurrent task, meaning the behavior is that the "TCP" buffer receives everything there is to receive, enqueues it in a channel, and once the TCP reads are done, then the consumer from that channel starts executing its runloop. In 1.5.0, those operations are interwoven.
this behavior is only reproducible when the data is streaming into the TCP connection, i.e. the BufReader.lines().next().await is returning a value on each iteration, if I have my test client pause for a moment between sending lines, then the 1.6.0-based version properly interleaves the tasks

This is now solved by the latest version of async-io, which yields inside read/write operation with some small probability, thus preventing tasks from hogging the executor forever.


I would expected for menu option to display first the question then the options

I would expect to have a menu option to display first the question then the options, but unfortunately, I don't see it.
Am I missing something?

I see the question display and the response parsing are tightly coupled

@RonQedit Not sure I get what you are asking? Do you have an example?

I think I follow. Do you want an option to switch which displays first? Currently, it is options than the question. But you want question then option. Am I following?

@dixonwille right, an menu option that i can choose what to display first:

Qestion and then the options.
Options and then the question.

You understand it correctly.
Thanks
Ron

Sounds good :) thanks!

how about add a func in wlog to support this feature
like this one
func (ui *BasicUI) AskWithCb(message, trim string, cb func(ui *BasicUI)) (string, error) {
	if message != "" {
		ui.Output(message)
		cb(ui)
	}
	reader := bufio.NewReader(ui.Reader)
	res, err := reader.ReadString('\n')
	if err != nil {
		return "", err
	}
	res = strings.Replace(res, "\r", "", -1) //this will only be useful under windows
	res = strings.Replace(res, "\n", "", -1)
	res = strings.Trim(res, trim)
	return res, err
}

and the test case
func TestAskWithCb(t *testing.T) {
	assert := assert.New(t)
	for _, c := range trimCases {
		writer, errWriter, in := initTest(c.input)
		basic := New(in, writer, errWriter)
		res, err := basic.AskWithCb("Awesome string", c.trim,func(ui *BasicUI) {ui.Output("option")})
		if err != nil {
			assert.Fail(err.Error())
		}
		out:= writer.String()
		// if err != nil {
		// 	assert.Fail(err.Error())
		// }
		_, err = errWriter.ReadString((byte)('\n'))
		expectedString := "Awesome string\noption\n"
		assert.Equal("EOF", err.Error())
		assert.Equal(expectedString, out)
		expectedAns := strings.Replace(c.input, "\r", "", -1)
		expectedAns = strings.Replace(expectedAns, "\n", "", -1)
		expectedAns = strings.Trim(expectedAns, c.trim)
		assert.Equal(expectedAns, res)
	}
}


Added register entries for pmpaddr registers

In this PR I have added pmpaddr registers without which riscv_isac cannot perform coverage of the coverpoints which include pmpaddrX registers. After this PR, the cgf files with pmp address registers (e.g. pmpaddr1) will successfully execute with riscv_isac

@alitariq4589 maybe include the exhaustive list of pmpcfg* as well in this PR

@alitariq4589 maybe include the exhaustive list of pmpcfg* as well in this PR

Sure. I am adding it.

@neelgala I have added all pmpcfg* registers

You'll also need to add them to the dictionary inside the csr_registers class. The class only contains values for 16 pmp entries right now.

@pawks I dont see any pmpaddr* register in csr_regs dictionary. Are they also needed to be added ?

They are added here.

Slightly off topic: The PMP spec has lot of corner cases, and has one very
ugly oversight: the number of PMP registers is not specified, nor is there
a specified allocation.
Maybe every other register? Only the prime numbered ones? Completely legal.
When tests are generated for BMP, it would be useful to define the CSRs
with #defined names instead of numbers, so that a test could be modified to
adjust for non-standard allocations just by changing the #defines base on a
mask of implemented CSRs provided by the model
On Sat, Jun 17, 2023 at 4:56 AM Ali Tariq @.***> wrote:

In this PR I have added pmpaddr registers without which riscv_isac cannot
perform coverage of the coverpoints which include pmpaddrX registers. After
this PR, the cgf files with pmp address registers (e.g. pmpaddr1) will
successfully execute with riscv_isac
You can view, comment on, or merge this pull request online at:
https://github.com/riscv-software-src/riscv-isac/pull/70
Commit Summary

1e4d74d
https://github.com/riscv-software-src/riscv-isac/pull/70/commits/1e4d74d0765bc948322fe3739f99dc9338cc2a85
Added register entries for pmpaddr registers

File Changes
(1 file https://github.com/riscv-software-src/riscv-isac/pull/70/files)

M riscv_isac/coverage.py
https://github.com/riscv-software-src/riscv-isac/pull/70/files#diff-b5454e2defdd8d2dfa6e943f56243ca817f3c26606912111092abdbcecb3178b
(64)

Patch Links:

https://github.com/riscv-software-src/riscv-isac/pull/70.patch
https://github.com/riscv-software-src/riscv-isac/pull/70.diff

—
Reply to this email directly, view it on GitHub
https://github.com/riscv-software-src/riscv-isac/pull/70, or unsubscribe
https://github.com/notifications/unsubscribe-auth/AHPXVJUW7H356HBFLHN623TXLWLOLANCNFSM6AAAAAAZKF3QIA
.
You are receiving this because you are subscribed to this thread.Message
ID: @.***>

Good point @allenjbaum, but here we are trying to simplify the register entries by following Sail as reference. Currently Sail supports 16 pmpaddr and 4 pmpcfg regs so those entries have been added in ISAC to test some coverpoint definitions related to PMP.

@alitariq4589 please change the target branch of the PR to dev and rebase to it. Also provide an entry in the CHANGELOG.md file under the WIP-DEV section.


WebSocket's do not mask all frames(pong/close) which leads to close connection

Servers close a connection with an error if receives not a masked frame from Client. Currently, WebSocket supports masking but does not mask all frames, it needs to mask pond and close frame also.
According to RFC6455 section 5.3:

a client MUST mask all frames that it
sends to the server

I fixed it in #24

This will be added in 1.1.0. Thanks!


Re-frame is leaking metadata, perhaps?

This does not happen with a vanila reagent build, but it does with reframe. I get lines like this in the compiled advanced compilation:
(ce,"/Users/andrew/projects/ajs/NONCPP/cljstest/reframe3/target/cljsbuild-compiler-1/cljs/core.cljc")
David Nolen via Slack suggested that this is a leak of meta data happening in re-frame, and that I should post an issue here.
This happens with a hello-world reframe build, no logic of my own added.

Can you give more information on what you mean by "A hello-world re-frame build" ?   Does that mean you used a template?

I'm using the re-frame lein template. I've narrowed down the problem. Observe:
~/projects/ajs/NONCPP/cljstest lein new re-frame metaleak
Generating re-frame project.
~/projects/ajs/NONCPP/cljstest cd metaleak/
~/projects/ajs/NONCPP/cljstest/metaleak lein cljsbuild once min
Compiling ClojureScript...
Compiling "resources/public/js/compiled/app.js" from ["src/cljs"]...
Successfully compiled "resources/public/js/compiled/app.js" in 14.405 seconds.

Then also:
~/projects/ajs/NONCPP/cljstest lein new re-frame metaleak2 +re-frisk
Generating re-frame project.
~/projects/ajs/NONCPP/cljstest cd metaleak2/
~/projects/ajs/NONCPP/cljstest/metaleak2 lein cljsbuild once min
Compiling ClojureScript...
Compiling "resources/public/js/compiled/app.js" from ["src/cljs"]...
Jul 14, 2017 3:23:09 PM com.google.javascript.jscomp.LoggerErrorManager println
WARNING: /Users/andrew/projects/ajs/NONCPP/cljstest/metaleak2/target/cljsbuild-compiler-1/cljs/compiler.js:559: WARNING - References to the global RegExp object prevents optimization of regular expressions.
cljs.compiler.emit_constant.cljs$core$IMultiFn$_add_method$arity$3(null,RegExp,(function (x){
                                                                        ^

Jul 14, 2017 3:23:09 PM com.google.javascript.jscomp.LoggerErrorManager printSummary
WARNING: 0 error(s), 1 warning(s)
Successfully compiled "resources/public/js/compiled/app.js" in 193.626 seconds.

Note the huge difference in compilation time: wow!
But -- the metadata leakage does not happen in the first build, without re-frisk. It does appear in the second build (along with the odd compiler errors).

closing this issue since it will be handled by the re-frisk repo


📃: Notes App

:red_circle: Title : Notes App
:red_circle: Aim : This app allows you to create your own notes and save them in the local storgae which will not be deleted even when you reload the page. It will be deleted once you click on the delete note button.
:red_circle: Tech Stack Used :  html css and vanilla js
Screenshots 📷

:white_check_mark: To be Mentioned while taking the issue :

Full name : Ananya Gupta
What is your participant role?  gssoc and hacktoberfest

Happy Contributing 🚀
All the best. Enjoy your open source journey ahead. 😎

Can you assign it to me. I have made this project so it will be easy for me.

Name: Aditya Raj
Gssoc and hacktoberFest

can you assign it to  me


.txt file not opening

Environment data

Language Server version: v2022.6.20
OS and version: Windows 10
Python version (& distribution if applicable, e.g. Anaconda): python 3.10.0

Code Snippet

f = open("demofile.txt", "r")
print(f.read())

Expected behavior
should print
Hello! Welcome to demofile.txt
This file is for testing purposes.
Actual behavior
Exception has occurred: FileNotFoundError
[Errno 2] No such file or directory: 'demofile.txt'
  File "C:\Users\Arthu\Documents\python\txt test\txt test.py", line 1, in <module>
    f = open("demofile.txt", "r")

it appears it can't find your file 'No such file or directory: 'demofile.txt''

This doesn't appear to be related to Pylance. This isn't the right forum for general Python programming and debugging questions.

It works fine on python IDLE, VS code is screwing it up

The problem is most likely that demofile.txt does not exist in your current working directory. Are you familiar with the concept of relative and absolute paths? Since you are calling open with just a filename (which is a relative path), open is trying to find that file relative to your current working directory. If your current working directory is not the directory that contains demofile.txt it won't be found.
Try adding this before your open call to see what you current working directory is:
from os import getcwd
print(getcwd())

I believe that by default, VS Code will use the root of your current workspace as your working directory. You can override that in your launch.json file by setting the cwd property. For example, you could set your current working directory to always be the directory containing the .py file that you are running, which may be what you are expecting(?), by using the ${fileDirname} variable:
{
    // Use IntelliSense to learn about possible attributes.
    // Hover to view descriptions of existing attributes.
    // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
    "version": "0.2.0",
    "configurations": [
        {
            "name": "Python: Current File",
            "type": "python",
            "request": "launch",
            "program": "${file}",
            "console": "integratedTerminal",
            "justMyCode": true,
            "cwd": "${fileDirname}"
        }
    ]
}


Intermittent failure in ProxyClientIntegrationTest

ProxyClientIntegrationTest > testHttpsProxyBasicCase() FAILED
    java.util.concurrent.CompletionException: com.linecorp.armeria.client.WriteTimeoutException
        at java.base/java.util.concurrent.CompletableFuture.reportJoin(CompletableFuture.java:412)
        at java.base/java.util.concurrent.CompletableFuture.join(CompletableFuture.java:2115)
        at com.linecorp.armeria.common.util.EventLoopCheckingFuture.join(EventLoopCheckingFuture.java:88)
        at com.linecorp.armeria.client.proxy.ProxyClientIntegrationTest.testHttpsProxyBasicCase(ProxyClientIntegrationTest.java:232)

        Caused by:
        com.linecorp.armeria.client.WriteTimeoutException
            at com.linecorp.armeria.client.WriteTimeoutException.get(WriteTimeoutException.java:36)
            at com.linecorp.armeria.client.HttpRequestSubscriber.lambda$onSubscribe$0(HttpRequestSubscriber.java:145)
            at io.netty.util.concurrent.PromiseTask.runTask(PromiseTask.java:98)
            at io.netty.util.concurrent.ScheduledFutureTask.run(ScheduledFutureTask.java:170)
            at io.netty.util.concurrent.AbstractEventExecutor.safeExecute(AbstractEventExecutor.java:164)
            at io.netty.util.concurrent.SingleThreadEventExecutor.runAllTasks(SingleThreadEventExecutor.java:472)
            at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:500)
            at io.netty.util.concurrent.SingleThreadEventExecutor$4.run(SingleThreadEventExecutor.java:989)
            at io.netty.util.internal.ThreadExecutorMap$2.run(ThreadExecutorMap.java:74)
            at io.netty.util.concurrent.FastThreadLocalRunnable.run(FastThreadLocalRunnable.java:30)
            at java.base/java.lang.Thread.run(Thread.java:830)

This happens a lot in my local recently, which a bit annoying.
I think the reason is that the promise used to connect is complete after the connection to the proxy server is established, not after to the final destination.
The writing to the socket is pending until the channel reads a message that indicates the proxy server connects to the final endpoint.
So there's a high chance that WriteTimeoutException happens because it additionally needs to wait for the proxy to connect the final endpoint.
I think we can solve this by making promise complete after the connection to the final endpoint is established using connectPromise.
https://github.com/netty/netty/blob/4.1/handler-proxy/src/main/java/io/netty/handler/proxy/ProxyHandler.java#L179

That would change the behavior of ProxyHandler which might break existing applications that use it, i.e. it can only happen in Netty 5. We should update HttpSessionHandler so that sessionPromise is completed only after a ProxyConnectionEvent.


My app won't install on device after 1.12.13.hotfix3 and hotfix5 and hotfix6

My app's APK won't install on devices after 1.12 update showing the message "App not installed" and when I downgrade to 1.9 it works,

Android 9.0
Samsung Galaxy s8 and Huawai P30

Hi @youssefhad did you fix this issue?  If so, how did you do that?  I'm having the same problem.

Hi @Mosely
I run this command  flutter build apk --release on the terminal


Fixed typo in the documentation for the search function

I noticed a typo in the documentation for "search"; "get" had been used instead of "search".  See my change to the .md file.

Duplicate of https://github.com/twitter/typeahead.js/pull/1275