Unable to upgrade/edit load balancer (haproxy) config from rancher UI

Rancher versions:
rancher/server: 1.6.14
rancher/agent: 1.2.9
Infrastructure Stack versions:
healthcheck: haproxy rancher/healthcheck:v0.3.3
ipsec: rancher/net:v0.13.7 - rancher/net:holder
network-services: rancher/network-manager:v0.7.19 - rancher/metadata:v0.9.5
scheduler: rancher/scheduler:v0.8.3
kubernetes (if applicable): using cattle
Docker version: (docker version,docker info preferred)
17.06.2-ce
Operating system and kernel: (cat /etc/os-release, uname -r preferred)
RancherOS v1.1.3 (4.9.75)
Type/provider of hosts: (VirtualBox/Bare-metal/AWS/GCE/DO)
AWS (ami-72613d08 - us-east-1)
Setup details: (single node rancher vs. HA rancher, internal DB vs. external DB)
HA rancher, external DB
Environment Template: (Cattle/Kubernetes/Swarm/Mesos)
Cattle
Steps to Reproduce:
N/A
Results:
I have a rancher high availability cluster running on our production environment. This has been running for a while since the last OS/rancher upgrade (few months).
We do releases frequently, which involves pushing a new stack and updating our load balancer rules every so often.
This has always worked on the same server (same setup), without any problems.
Today I could not update the load balancer config from the UI. The error was:
Validation failed in API: instanceId
Inspecting the request/response revealed that the PUT request on /v2-beta/projects/[projectid]/loadbalancerservices/[serviceid] was failing with 504, where the content of the request included the instanceId of the load balancer (haproxy) service itself. For some strange reason, one of the instanceId in the request was wrong.
The instanceIds of haproxy (load balancer service) running on each hosts (3 hosts) were:

1i2554
1i2775
1i2834

The request included 1i2554, 1i2775, and 1i2832 (that one did not exist anywhere)
All the content of each services looked OK (ip address, name of services, rules, etc), but just the instanceId of the 3rd haproxy service was strange (with the 2 digit difference)
Looking at the load balancer service was showing only 3 running instances (with the listed instanceIds). And all the results from all the endpoints in rancher API (stacks, services, instances) were always returning the same correct ids.
No idea where the incorrect 1i2832 is coming from.
The rules in haproxy are definitely correct - since they are running fine. And doing a simple upgrade without changing the config is still returning the same error.
After about an hour (without doing anything), doing exactly the same operation worked fine. None of the load balancer instanceIds have changed.
Any ideas as to what might have caused this?

Same problem appears again, out of the blue. Really annoying, and no idea how to fix it other than wait a couple of hours and pray...

Thanks for your report!
With the release of Rancher 2.0, development on v1.6 is only limited to critical bug fixes and security patches.
If you think we should keep this issue open, please let me know.

This issue is still happening, really annoying as all you want to do is change the LB config

Hi,
When I get sometime this issue, I do the following steps:

create a new stack"loadbalancer2"  and disable "start" options in the advanced options
copy/paste docker-compose.yml and rancher-compose-yml from the old "loadbalancer" to the new stack "loadbalancer2"
stop the old stack "loadbalancer"
start the stack "loadbalancer2"

I have been able to get it working if i restart the lb services.

I had a similar issue that was not a load balancer. I just restarted the service. After restarting I was successful in upgrading.

I solved this problem by using rancher api.
im my case:

service_id: 1s110
instanceids: li1949

in service page, click View in API, GET /v2-beta/projects/1a5/services/1s110，in publicEndpoints, instanceId is 1i1937, which is wrong
publicEndpoints": [
{
"type": "publicEndpoint",
"hostId": "1h1",
"instanceId": "1i1937",
"ipAddress": "xxx.xxx.xxx.xxx",
"port": xxx,
"serviceId": "1s110"
}
],

so the validation failed, cause GET /v2-beta/projects/1a5/instances/1i1937 returns empty.
then i clik edit button, and change publiEndpoints-instanceid to li1949, submit my put request and return to service page in rancher, I can update service now.


[base-ui] Add a hook, support OTP/ PinInput usePinInput

Duplicates

[X] I have searched the existing issues

Summary
I believe it would be fantastic to introduce a base-ui hook specifically designed for handling OTP inputs.
Chakra already offers a PinInput component along with a headless UI hook in their Zag library (https://zagjs.com/components/react/pin-input).
Examples
No response
Motivation
No response
Search keywords:
Benchmarks

https://zagjs.com/components/react/pin-input
https://chakra-ui.com/docs/components/pin-input
https://vuetifyjs.com/en/components/otp-input/
https://mantine.dev/core/pin-input/
https://www.radix-vue.com/components/pin-input

:+1: Let's wait for the community upvotes so we can prioritize this.

I have added a few benchmarks.
2FA grew in popularity recently, and so did this component. I wonder about the impact passwordless (biometric, passkey, device, email link) authentification will have though.

It would be great to have this in Material UI as well, not only here in Base.


backend: Use user IDs as recipients.

@showell, @timabbott: I had to submit another PR because apparently, GitHub doesn't let me re-order history if the branch has already been pushed to a remote once! So I thought, pushing on a new branch might fix that, but that doesn't cut it either. It might reflect the intended ordering of commits once you fetch the PR locally. :/
@showell: The idea is that after the extract_recipients commit, I will add another one on top that finally implements the backend support for using IDs in typing notifications. I had to commit the extract_recipients work first because it made testing the backend changes a whole lot easier. I'll push the rest of the changes once they are complete. Getting mypy to pass took a lot of work!
After that, the idea is that all commits on top of the last one will be geared towards implementing user ID support for sending PMs and what not!
Thanks! :)

Looks good so far.  I added a few comments.  You should try to figure out which commit is breaking the build.  The build is reporting that we are losing line coverage on actions.py, which I suspect is due to the recipients_for_user_ids changes, but I haven't checked.  That's the one commit where I think we still need a re-think, so it might be worth trying to get a PR with everything up until that.  In particular it would be nice to get a PR merged that does the following:

break out new function to validate typing indicators
inline helper into recipient_from_emails
unsplit get_user_profiles

I can make the JS-side changes to typing.js as needed.

@showell: I just updated this with the following:

Responded to your critique about not using mirroring arguments in recipient_for_user_ids.
Responded to your critique about extract_recipients. I have one concern. I don't think we should be complaining about empty recipient lists inside extract_recipients. That would mess up how such errors are currently raised throughout the code base, wouldn't it? Isn't it better to complain about empty recipients in Addressee, like one of my commit already does? For now, we just return the empty list. Let me know what you think. :)
I also added another commit that finally adds support for user IDs to check_send_typing_notification.

Of course, GitHub messes up the order of the commits. But if you rebase my PR locally, I think the order of the commits would make more sense! :)
Looking forward to your feedback! Thanks! :)

@showell: Just updated this! I'd really appreciate it if you could please give this a full review when you have time! I'd love to see part of this PR getting merged slowly before I stack more commits on top! Thanks! :)

get_user_profile_by_id_in_realm doesn't include cross-realm users; my guess is that this PR breaks sending messages to welcome-bot (for example).

@timabbott: I just submitted #10463, which implements get_user_by_id_in_realm_including_cross_realm. Once we close that PR, I should be able to update this one and @adnrs96 should be able to continue his work on #10360. Thanks! :)

@timabbott I think we can merge everything up to but not include the commit `extract_recipients: Support user IDs' to start chipping away at this, after you look at them.  After that I'm not necessarily saying there are problems, just saying the first few are pretty straightforward.

@showell, @timabbott: Just updated this with a commit that adds support for user IDs to handle_deferred_message. Thanks! :)

@timabbott: Just rebased and resolved conflicts! Thanks! :)

I merged the first 3 commits, since they look great.  One thing I'm curious for your thinking on is why you thought "require them to be all IDs or all emails", was more cumbersome than processing a mix -- can you talk about any of the issues you see with changing that?  I think that would simplify the typing issues (since you'd have an Iterable[Union[str, int]]), and I can imagine a use case for it (though not any really good ones).
For your question above, create_mirrored_message_users sorta fundamentally needs to receive emails (the whole point is to create user entries for emails that don't have accounts yet.

@timabbott: Okay, so initially, I had written extract_recipients to be able to support heterogeneous recipient lists. That was some time ago, so I can't exactly remember what my rationale was for asserting that supporting heterogeneous lists is too "cumbersome". So, I just spent a few hours today trying to play around with heterogeneous recipient lists and re-writing a couple of commits. A couple of things I'd like to say:

Keeping lists homogenous had the added benefit of simplifying things by having logically separate functions such as recipient_for_user_ids and recipient_for_emails which could operate under the assumption that the lists would either contain only IDs or only emails. Other examples include Addressee.for_user_ids and get_user_profiles_by_ids. Please note that if we decide to support heterogenous lists, we will have to modify the commits that you have already merged in this PR!
The typing issues are only slightly improved by supporting heterogeneous lists. The mypy annotations for converter functions will still have to be modified regardless of whether we support mixed lists or not! I already rewrote the "extract_recipients" commit to support mixed lists, and it doesn't improve our typing situation at all.
I am really not sure that type checking is less complex with mixed lists overall.

I guess the one takeaway from this explanation should be that supporting mixed lists definitely leads to an implementation that looks somewhat like a "kludge", where we'll just end up adding additional type checking to existing functions. On the other hand, with homogeneous lists, things are a bit cleaner because we can delegate more to functions that can handle either IDs or emails, but not both!
Now, having said that, homogeneous lists complicate things for mirrored users, where they don't have any IDs, which, admittedly, I hadn't thought of! So we have two choces, either do the bulk of the work to support mixed lists (which involves rewriting much of this PR, including the commits that have already been merged), or enforce that recipient lists with mirrored users only use emails. The latter option is definitely less work!
Would love to know your thoughts on how to move forward! Thanks!
@showell: FYI :)

I've decided I'm fine with merging this with the homogenous approach.  Posted a bunch of comments on issues that can be fixed, and then this should be mergable.


How to set Badge after create?

Create a badge add it to the NavigationItem before intialise() and just hide it till you need it.
When ever you need it to be shown call show() on badge.
refer this further details https://github.com/Ashok-Varma/BottomNavigation/wiki/Badges


Empty path-prefix parameter doesn't work with Nginx "/" location

Bug Report
What did you do?
Use TiDB Dashboard with Nginx reverse proxy. Followed doc step-by-step. Doc url.
Start PD with:
[dashboard]
public-path-prefix = "/"

Then config Nginx with:
server {
  listen 2379;
  location / {
    proxy_pass http://<IP_ADDRESS>:2379/dashboard/;
  }
}

<IP_ADDRESS>:2379 is the URL of PD service

What did you expect to see?
Access dashboard with http://{nginx_address}:2379. Dashboard should work well.
What did you see instead?

What version of TiDB Dashboard are you using (./tidb-dashboard --version)?
v6.4.x

One more case:
If the following configs are used:
[dashboard]
public-path-prefix = "/"

Then config Nginx with:
server {
  listen 2379;
  location /dashboard/ {
    proxy_pass http://<IP_ADDRESS>:2379/dashboard/;
  }
}

The dashboard homepage (login) can be accessed, but after login, it always shows a blank page. Some requests are failed:'


TrialResult.measurements typo fix

How did this pass tests?

maybe to_list was added in a more recent version of pandas than the one I've got?

yes, It was added on 0.24.0 and I have 0.23.4

Add a minimum version to the pandas line in requirements.txt

This seems to be subsumed by other changes to TrialResult


Device Request - [Motion Sensor] - [eWeLink] / [SNZB-03]

Prerequisites:

Before requesting a device addition, please ensure there is not already a request for the device among the open issues.
Make sure your Homey is upgraded to firmware v5 or higher.
You need a physical example of the device.

Device Information

Device Name: Motion Sensor
Device Model: SNZB-03
Device Description: Detect motion and send signal
-[ Link to device image: [(https://www.zigbee2mqtt.io/images/devices/SNZB-03.png)]]

Device Interview
Device 1
{
    ["info 2024-10-28 21:11:20z2m: Removing device '0xa4c138f9f5e8df98' (block: false, force: true)
info 2024-10-28 21:11:20z2m:mqtt: MQTT publish: topic 'zigbee2mqtt/0xa4c138f9f5e8df98', payload ''
info 2024-10-28 21:11:20z2m: Successfully removed device '0xa4c138f9f5e8df98' (block: false, force: true)
info 2024-10-28 21:11:20z2m:mqtt: MQTT publish: topic 'zigbee2mqtt/bridge/response/device/remove', payload '{"data":{"block":false,"force":true,"id":"0xa4c138f9f5e8df98"},"status":"ok","transaction":"e32n3-11"}'
info 2024-10-28 21:11:43zh:controller: Interview for '0xa4c138f9f5e8df98' started
info 2024-10-28 21:11:43z2m: Device '0xa4c138f9f5e8df98' joined
info 2024-10-28 21:11:43z2m:mqtt: MQTT publish: topic 'zigbee2mqtt/bridge/log', payload '{"message":{"friendly_name":"0xa4c138f9f5e8df98"},"type":"device_connected"}'
info 2024-10-28 21:11:43z2m: Starting interview of '0xa4c138f9f5e8df98'
info 2024-10-28 21:11:43z2m:mqtt: MQTT publish: topic 'zigbee2mqtt/bridge/log', payload '{"message":"interview_started","meta":{"friendly_name":"0xa4c138f9f5e8df98"},"type":"pairing"}'
info 2024-10-28 21:11:43z2m:mqtt: MQTT publish: topic 'zigbee2mqtt/bridge/event', payload '{"data":{"friendly_name":"0xa4c138f9f5e8df98","ieee_address":"0xa4c138f9f5e8df98"},"type":"device_joined"}'
info 2024-10-28 21:11:43z2m:mqtt: MQTT publish: topic 'zigbee2mqtt/bridge/event', payload '{"data":{"friendly_name":"0xa4c138f9f5e8df98","ieee_address":"0xa4c138f9f5e8df98","status":"started"},"type":"device_interview"}'
info 2024-10-28 21:11:44z2m:mqtt: MQTT publish: topic 'zigbee2mqtt/bridge/log', payload '{"message":"announce","meta":{"friendly_name":"0xa4c138f9f5e8df98"},"type":"device_announced"}'
info 2024-10-28 21:11:44z2m:mqtt: MQTT publish: topic 'zigbee2mqtt/bridge/event', payload '{"data":{"friendly_name":"0xa4c138f9f5e8df98","ieee_address":"0xa4c138f9f5e8df98"},"type":"device_announce"}'
info 2024-10-28 21:11:56zh:controller: Succesfully interviewed '0xa4c138f9f5e8df98'
info 2024-10-28 21:11:56z2m: Successfully interviewed '0xa4c138f9f5e8df98', device has successfully been paired
info 2024-10-28 21:11:56z2m: Device '0xa4c138f9f5e8df98' is supported, identified as: SONOFF Motion sensor (SNZB-03)
info 2024-10-28 21:11:56z2m: Configuring '0xa4c138f9f5e8df98'
info 2024-10-28 21:11:56z2m:mqtt: MQTT publish: topic 'zigbee2mqtt/bridge/log', payload '{"message":"interview_successful","meta":{"description":"Motion sensor","friendly_name":"0xa4c138f9f5e8df98","model":"SNZB-03","supported":true,"vendor":"SONOFF"},"type":"pairing"}'
info 2024-10-28 21:11:56z2m:mqtt: MQTT publish: topic 'zigbee2mqtt/bridge/event', payload '{"data":{"definition":{"description":"Motion sensor","exposes":[{"access":1,"description":"Indicates whether the device detected occupancy","label":"Occupancy","name":"occupancy","property":"occupancy","type":"binary","value_off":false,"value_on":true},{"access":1,"category":"diagnostic","description":"Indicates if the battery of this device is almost empty","label":"Battery low","name":"battery_low","property":"battery_low","type":"binary","value_off":false,"value_on":true},{"access":1,"category":"diagnostic","description":"Remaining battery in %, can take up to 24 hours before reported","label":"Battery","name":"battery","property":"battery","type":"numeric","unit":"%","value_max":100,"value_min":0},{"access":1,"category":"diagnostic","description":"Voltage of the battery in millivolts","label":"Voltage","name":"voltage","property":"voltage","type":"numeric","unit":"mV"},{"access":1,"category":"diagnostic","description":"Link quality (signal strength)","label":"Linkquality","name":"linkquality","property":"linkquality","type":"numeric","unit":"lqi","value_max":255,"value_min":0}],"model":"SNZB-03","options":[],"supports_ota":false,"vendor":"SONOFF"},"friendly_name":"0xa4c138f9f5e8df98","ieee_address":"0xa4c138f9f5e8df98","status":"successful","supported":true},"type":"device_interview"}'
info 2024-10-28 21:11:57z2m:mqtt: MQTT publish: topic 'zigbee2mqtt/0xa4c138f9f5e8df98', payload '{"linkquality":86,"voltage":3000}'
info 2024-10-28 21:11:58z2m:mqtt: MQTT publish: topic 'zigbee2mqtt/0xa4c138f9f5e8df98', payload '{"battery":100,"linkquality":84,"voltage":3000}'
info 2024-10-28 21:11:58z2m: Successfully configured '0xa4c138f9f5e8df98'"]
}

Device 2 Interview
Device 2
{
    ["info 2024-10-28 21:26:02z2m: Accepting joining not in blocklist device '0xa4c1387b44fdf5a0'
info 2024-10-28 21:26:02zh:controller: Interview for '0xa4c1387b44fdf5a0' started
info 2024-10-28 21:26:02z2m: Device '0xa4c1387b44fdf5a0' joined
info 2024-10-28 21:26:02z2m:mqtt: MQTT publish: topic 'zigbee2mqtt/bridge/log', payload '{"message":{"friendly_name":"0xa4c1387b44fdf5a0"},"type":"device_connected"}'
info 2024-10-28 21:26:02z2m: Starting interview of '0xa4c1387b44fdf5a0'
info 2024-10-28 21:26:02z2m:mqtt: MQTT publish: topic 'zigbee2mqtt/bridge/log', payload '{"message":"interview_started","meta":{"friendly_name":"0xa4c1387b44fdf5a0"},"type":"pairing"}'
info 2024-10-28 21:26:02z2m:mqtt: MQTT publish: topic 'zigbee2mqtt/bridge/event', payload '{"data":{"friendly_name":"0xa4c1387b44fdf5a0","ieee_address":"0xa4c1387b44fdf5a0"},"type":"device_joined"}'
info 2024-10-28 21:26:02z2m:mqtt: MQTT publish: topic 'zigbee2mqtt/bridge/event', payload '{"data":{"friendly_name":"0xa4c1387b44fdf5a0","ieee_address":"0xa4c1387b44fdf5a0","status":"started"},"type":"device_interview"}'
info 2024-10-28 21:26:03z2m:mqtt: MQTT publish: topic 'zigbee2mqtt/bridge/log', payload '{"message":"announce","meta":{"friendly_name":"0xa4c1387b44fdf5a0"},"type":"device_announced"}'
info 2024-10-28 21:26:03z2m:mqtt: MQTT publish: topic 'zigbee2mqtt/bridge/event', payload '{"data":{"friendly_name":"0xa4c1387b44fdf5a0","ieee_address":"0xa4c1387b44fdf5a0"},"type":"device_announce"}'
info 2024-10-28 21:26:12zh:controller: Succesfully interviewed '0xa4c1387b44fdf5a0'
info 2024-10-28 21:26:12z2m: Successfully interviewed '0xa4c1387b44fdf5a0', device has successfully been paired
info 2024-10-28 21:26:12z2m: Device '0xa4c1387b44fdf5a0' is supported, identified as: SONOFF Motion sensor (SNZB-03)
info 2024-10-28 21:26:12z2m: Configuring '0xa4c1387b44fdf5a0'
info 2024-10-28 21:26:12z2m:mqtt: MQTT publish: topic 'zigbee2mqtt/bridge/log', payload '{"message":"interview_successful","meta":{"description":"Motion sensor","friendly_name":"0xa4c1387b44fdf5a0","model":"SNZB-03","supported":true,"vendor":"SONOFF"},"type":"pairing"}'
info 2024-10-28 21:26:12z2m:mqtt: MQTT publish: topic 'zigbee2mqtt/bridge/event', payload '{"data":{"definition":{"description":"Motion sensor","exposes":[{"access":1,"description":"Indicates whether the device detected occupancy","label":"Occupancy","name":"occupancy","property":"occupancy","type":"binary","value_off":false,"value_on":true},{"access":1,"category":"diagnostic","description":"Indicates if the battery of this device is almost empty","label":"Battery low","name":"battery_low","property":"battery_low","type":"binary","value_off":false,"value_on":true},{"access":1,"category":"diagnostic","description":"Remaining battery in %, can take up to 24 hours before reported","label":"Battery","name":"battery","property":"battery","type":"numeric","unit":"%","value_max":100,"value_min":0},{"access":1,"category":"diagnostic","description":"Voltage of the battery in millivolts","label":"Voltage","name":"voltage","property":"voltage","type":"numeric","unit":"mV"},{"access":1,"category":"diagnostic","description":"Link quality (signal strength)","label":"Linkquality","name":"linkquality","property":"linkquality","type":"numeric","unit":"lqi","value_max":255,"value_min":0}],"model":"SNZB-03","options":[],"supports_ota":false,"vendor":"SONOFF"},"friendly_name":"0xa4c1387b44fdf5a0","ieee_address":"0xa4c1387b44fdf5a0","status":"successful","supported":true},"type":"device_interview"}'
info 2024-10-28 21:26:13z2m:mqtt: MQTT publish: topic 'zigbee2mqtt/0xa4c1387b44fdf5a0', payload '{"linkquality":89,"voltage":3000}'
info 2024-10-28 21:26:14z2m:mqtt: MQTT publish: topic 'zigbee2mqtt/0xa4c1387b44fdf5a0', payload '{"battery":100,"linkquality":86,"voltage":3000}'
info 2024-10-28 21:26:14z2m: Successfully configured '0xa4c1387b44fdf5a0'
}

Additional Comments:

https://www.zigbee2mqtt.io/devices/SNZB-03.html

How to interview a device

Add the device as a generic Zigbee device in Homey
Navigate to https://developer.athom.com/tools/zigbee.
Interview the device, the button for this is to the right of the device in the list of Zigbee units.
Click the copy button/icon to capture the device information.
Paste the copied information above.

Note: To be able to add more devices to the Tuya Zigbee app, we rely on community members like you to provide interviews of the devices you want to be added. Thank you for your contribution!

{info 2024-10-28 21:26:02z2m: Accepting joining not in blocklist device '0xa4c1387b44fdf5a0' info 2024-10-28 21:26:02zh:controller: Interview for '0xa4c1387b44fdf5a0' started info 2024-10-28 21:26:02z2m: Device '0xa4c1387b44fdf5a0' joined info 2024-10-28 21:26:02z2m:mqtt: MQTT publish: topic 'zigbee2mqtt/bridge/log', payload '{"message":{"friendly_name":"0xa4c1387b44fdf5a0"},"type":"device_connected"}' info 2024-10-28 21:26:02z2m: Starting interview of '0xa4c1387b44fdf5a0' info 2024-10-28 21:26:02z2m:mqtt: MQTT publish: topic 'zigbee2mqtt/bridge/log', payload '{"message":"interview_started","meta":{"friendly_name":"0xa4c1387b44fdf5a0"},"type":"pairing"}' info 2024-10-28 21:26:02z2m:mqtt: MQTT publish: topic 'zigbee2mqtt/bridge/event', payload '{"data":{"friendly_name":"0xa4c1387b44fdf5a0","ieee_address":"0xa4c1387b44fdf5a0"},"type":"device_joined"}' info 2024-10-28 21:26:02z2m:mqtt: MQTT publish: topic 'zigbee2mqtt/bridge/event', payload '{"data":{"friendly_name":"0xa4c1387b44fdf5a0","ieee_address":"0xa4c1387b44fdf5a0","status":"started"},"type":"device_interview"}' info 2024-10-28 21:26:03z2m:mqtt: MQTT publish: topic 'zigbee2mqtt/bridge/log', payload '{"message":"announce","meta":{"friendly_name":"0xa4c1387b44fdf5a0"},"type":"device_announced"}' info 2024-10-28 21:26:03z2m:mqtt: MQTT publish: topic 'zigbee2mqtt/bridge/event', payload '{"data":{"friendly_name":"0xa4c1387b44fdf5a0","ieee_address":"0xa4c1387b44fdf5a0"},"type":"device_announce"}' info 2024-10-28 21:26:12zh:controller: Succesfully interviewed '0xa4c1387b44fdf5a0' info 2024-10-28 21:26:12z2m: Successfully interviewed '0xa4c1387b44fdf5a0', device has successfully been paired info 2024-10-28 21:26:12z2m: Device '0xa4c1387b44fdf5a0' is supported, identified as: SONOFF Motion sensor (SNZB-03) info 2024-10-28 21:26:12z2m: Configuring '0xa4c1387b44fdf5a0' info 2024-10-28 21:26:12z2m:mqtt: MQTT publish: topic 'zigbee2mqtt/bridge/log', payload '{"message":"interview_successful","meta":{"description":"Motion sensor","friendly_name":"0xa4c1387b44fdf5a0","model":"SNZB-03","supported":true,"vendor":"SONOFF"},"type":"pairing"}' info 2024-10-28 21:26:12z2m:mqtt: MQTT publish: topic 'zigbee2mqtt/bridge/event', payload '{"data":{"definition":{"description":"Motion sensor","exposes":[{"access":1,"description":"Indicates whether the device detected occupancy","label":"Occupancy","name":"occupancy","property":"occupancy","type":"binary","value_off":false,"value_on":true},{"access":1,"category":"diagnostic","description":"Indicates if the battery of this device is almost empty","label":"Battery low","name":"battery_low","property":"battery_low","type":"binary","value_off":false,"value_on":true},{"access":1,"category":"diagnostic","description":"Remaining battery in %, can take up to 24 hours before reported","label":"Battery","name":"battery","property":"battery","type":"numeric","unit":"%","value_max":100,"value_min":0},{"access":1,"category":"diagnostic","description":"Voltage of the battery in millivolts","label":"Voltage","name":"voltage","property":"voltage","type":"numeric","unit":"mV"},{"access":1,"category":"diagnostic","description":"Link quality (signal strength)","label":"Linkquality","name":"linkquality","property":"linkquality","type":"numeric","unit":"lqi","value_max":255,"value_min":0}],"model":"SNZB-03","options":[],"supports_ota":false,"vendor":"SONOFF"},"friendly_name":"0xa4c1387b44fdf5a0","ieee_address":"0xa4c1387b44fdf5a0","status":"successful","supported":true},"type":"device_interview"}' info 2024-10-28 21:26:13z2m:mqtt: MQTT publish: topic 'zigbee2mqtt/0xa4c1387b44fdf5a0', payload '{"linkquality":89,"voltage":3000}' info 2024-10-28 21:26:14z2m:mqtt: MQTT publish: topic 'zigbee2mqtt/0xa4c1387b44fdf5a0', payload '{"battery":100,"linkquality":86,"voltage":3000}' info 2024-10-28 21:26:14z2m: Successfully configured '0xa4c1387b44fdf5a0}'
i have 2 of this devices
last time i added my own code to this app and installed it with athom cli but now i cant seem to login anymore so i hope you can add it
i installed test version on my homey pro

Got it to work
its the same as motion sensor driver only different manufacturerName and batteries
{     "id": "motion_sensor",     "name": {       "en": "Motion Sensor"     },     "class": "sensor",     "platforms": ["local"],     "connectivity": ["zigbee"],     "capabilities": [       "alarm_motion",       "measure_battery"     ],     "energy": {       "batteries": [ "AAA" , "AAA" ]     },     "images": {       "large": "{{driverAssetsPath}}/images/large.png",       "small": "{{driverAssetsPath}}/images/small.png"     },     "zigbee": {       "manufacturerName": [         "eWeLink"       ],       "productId": [         "SNZB-03"       ],       "endpoints": {         "1": {           "clusters": [0, 1, 1280],           "bindings": [1, 1280]         }       },       "learnmode": {         "image": "{{driverAssetsPath}}/icon.svg",         "instruction": {           "en": "Push the setup button on the side of the device for aprox 5 seconds until the LED blinks rapidly. If the pairing does not start, press the setup button again for 10-15 seconds until the led stops blinking and then try again."         }       }     }   }

doesnt work for me, it is not connected as a motion sensor, i made a new device request


Plugins do not support AndroidX

I have a flutter project. Inside of its android folder I have a lot of android code, including background processing classes and some native UI. I updated this code to use the new androidX packages.
Now, some of the plugins stopped working. A example is the permission_handler plugin.
permissionhandler\PermissionHandlerPlugin.kt: (10, 31): Unresolved reference: ActivityCompat
permissionhandler\PermissionHandlerPlugin.kt: (11, 27): Unresolved reference: content
permissionhandler\PermissionHandlerPlugin.kt: (152, 37): Unresolved reference: ContextCompat
permissionhandler\PermissionHandlerPlugin.kt: (191, 20): Unresolved reference: ActivityCompat
permissionhandler\PermissionHandlerPlugin.kt: (235, 13): Unresolved reference: ActivityCompat`

I believe this is because the native Android part of my app is using the AndroidX packages, since those plugins are still using the old support library. In the current state, it is impossible to me to roll back to the support library.
Also, when I add the camera plugin I get the following error:
error: package android.support.annotation does not exist
import android.support.annotation.NonNull;
                                 ^

Is this a intended behavior? Can someone give me a light?
[√] Flutter (Channel beta, v0.9.4, on Microsoft Windows [versÃ£o 10.0.17134.376], locale pt-BR)
[√] Android toolchain - develop for Android devices (Android SDK 28.0.3)
[√] Android Studio (version 3.2)
[√] IntelliJ IDEA Community Edition (version 2018.2)
[√] Connected devices (1 available)

• No issues found!`

I also have this problem ，when i use flutter module for my android project，use flutter packages get，then flutter android source would be replace by default and it is use support library ，not the androidx library

related to #23586.
We're working on making it easier to update this stuff for the engine, but we'll have to think of plugins as well...

Hi, we have a third party plugin and our customers start hitting this issue when they migrate to Androidx. We'd like to fix this issue ASAP, is there a guideline of how to update plugin to support AndroidX migration? Or can we suggest a workaround to the customer?
Another question is - how do we support those customers who haven't migrated?

Getting the following error when using cloud_functions 0.1.0 package.
cloud_functions-0.1.0\android\src\main\java\io\flutter\plugins\firebase\cloudfunctions\cloudfunctions\CloudFunctionsPlugin.java:7: error: cannot find symbol
import androidx.annotation.NonNull;
                          ^
  symbol:   class NonNull
  location: package androidx.annotation

[√] Flutter (Channel dev, v1.2.0, on Microsoft Windows [Version 10.0.17134.523], locale en-US)
• Flutter version 1.2.0 at C:\dev\libraries\flutter2\flutter
• Framework revision 06b979c4d5 (11 days ago), 2019-01-25 14:27:35 -0500
• Engine revision 36acd02c94
• Dart version 2.1.1 (build 2.1.1-dev.3.2 f4afaee422)
[√] Android toolchain - develop for Android devices (Android SDK version 28.0.3)
• Android SDK at C:\dev\libraries\android-sdk
• Android NDK location not configured (optional; useful for native profiling support)
• Platform android-28, build-tools 28.0.3
• ANDROID_HOME = C:\dev\libraries\android-sdk
• Java binary at: C:\dev\tools\android-studio-ide-171.4402976-windows\android-studio\jre\bin\java
• Java version OpenJDK Runtime Environment (build 1.8.0_152-release-1248-b01)
• All Android licenses accepted.
[√] Android Studio (version 3.3)
• Android Studio at C:\dev\tools\android-studio-ide-171.4402976-windows\android-studio
• Flutter plugin version 32.0.1
• Dart plugin version 182.5124
• Java version OpenJDK Runtime Environment (build 1.8.0_152-release-1248-b01)
• No issues found!

flutter run
Launching lib/main.dart on Telthem in debug mode...
Initializing gradle...                                          34.6s
Resolving dependencies...                                       369.1s
Gradle task 'assembleDebug'...
[Fatal Error] support-core-ui-26.1.0.pom:2:1: Content is not allowed in prolog.
[Fatal Error] support-compat-26.1.0.pom:2:1: Content is not allowed in prolog.
[Fatal Error] support-core-utils-26.1.0.pom:2:1: Content is not allowed in prolog.
[Fatal Error] support-compat-26.1.0.pom:2:1: Content is not allowed in prolog.
[Fatal Error] support-core-ui-26.1.0.pom:2:1: Content is not allowed in prolog.
[Fatal Error] support-core-utils-26.1.0.pom:2:1: Content is not allowed in prolog.
[Fatal Error] support-fragment-26.1.0.pom:2:1: Content is not allowed in prolog.
[Fatal Error] support-fragment-26.1.0.pom:2:1: Content is not allowed in prolog.
[Fatal Error] support-annotations-26.1.0.pom:2:1: Content is not allowed in prolog.
[Fatal Error] support-annotations-26.1.0.pom:2:1: Content is not allowed in prolog.
*********************************************************
WARNING: This version of google_maps_flutter will break your Android build if it or its dependencies aren't compatible with AndroidX.
See https://goo.gl/CP92wY for more information on the problem and how to fix it.
This warning prints for all Android build failures. The real root cause of the error may be unrelated.
*********************************************************
FAILURE: Build failed with an exception.

What went wrong:
Could not resolve all files for configuration ':app:debugRuntimeClasspath'.

Could not resolve com.android.support:support-compat:26.1.0.
Required by:
project :app > project :google_maps_flutter > com.google.android.gms:play-services-maps:15.0.1 > com.google.android.gms:play-services-basement:15.0.1 > com.android.support:support-v4:26.1.0
project :app > project :google_maps_flutter > com.google.android.gms:play-services-maps:15.0.1 > com.google.android.gms:play-services-basement:15.0.1 > com.android.support:support-v4:26.1.0 > com.android.support:support-media-compat:26.1.0
Could not resolve com.android.support:support-compat:26.1.0.
Could not parse POM https://dl.google.com/dl/android/maven2/com/android/support/support-compat/26.1.0/support-compat-26.1.0.pom
Content is not allowed in prolog.
Could not resolve com.android.support:support-compat:26.1.0.
Could not parse POM https://dl.google.com/dl/android/maven2/com/android/support/support-compat/26.1.0/support-compat-26.1.0.pom
Content is not allowed in prolog.
Could not resolve com.android.support:support-core-utils:26.1.0.
Required by:
project :app > project :google_maps_flutter > com.google.android.gms:play-services-maps:15.0.1 > com.google.android.gms:play-services-basement:15.0.1 > com.android.support:support-v4:26.1.0
Could not resolve com.android.support:support-core-utils:26.1.0.
Could not parse POM https://dl.google.com/dl/android/maven2/com/android/support/support-core-utils/26.1.0/support-core-utils-26.1.0.pom
Content is not allowed in prolog.
Could not resolve com.android.support:support-core-utils:26.1.0.
Could not parse POM https://dl.google.com/dl/android/maven2/com/android/support/support-core-utils/26.1.0/support-core-utils-26.1.0.pom
Content is not allowed in prolog.
Could not resolve com.android.support:support-core-ui:26.1.0.
Required by:
project :app > project :google_maps_flutter > com.google.android.gms:play-services-maps:15.0.1 > com.google.android.gms:play-services-basement:15.0.1 > com.android.support:support-v4:26.1.0
Could not resolve com.android.support:support-core-ui:26.1.0.
Could not parse POM https://dl.google.com/dl/android/maven2/com/android/support/support-core-ui/26.1.0/support-core-ui-26.1.0.pom
Content is not allowed in prolog.
Could not resolve com.android.support:support-core-ui:26.1.0.
Could not parse POM https://dl.google.com/dl/android/maven2/com/android/support/support-core-ui/26.1.0/support-core-ui-26.1.0.pom
Content is not allowed in prolog.
Could not resolve com.android.support:support-fragment:26.1.0.
Required by:
project :app > project :google_maps_flutter > com.google.android.gms:play-services-maps:15.0.1 > com.google.android.gms:play-services-basement:15.0.1 > com.android.support:support-v4:26.1.0
Could not resolve com.android.support:support-fragment:26.1.0.
Could not parse POM https://dl.google.com/dl/android/maven2/com/android/support/support-fragment/26.1.0/support-fragment-26.1.0.pom
Content is not allowed in prolog.
Could not resolve com.android.support:support-fragment:26.1.0.
Could not parse POM https://dl.google.com/dl/android/maven2/com/android/support/support-fragment/26.1.0/support-fragment-26.1.0.pom
Content is not allowed in prolog.
Could not resolve com.android.support:support-annotations:26.1.0.
Required by:
project :app > project :google_maps_flutter > com.google.android.gms:play-services-maps:15.0.1 > com.google.android.gms:play-services-basement:15.0.1 > com.android.support:support-v4:26.1.0 > com.android.support:support-media-compat:26.1.0
Could not resolve com.android.support:support-annotations:26.1.0.
Could not parse POM https://dl.google.com/dl/android/maven2/com/android/support/support-annotations/26.1.0/support-annotations-26.1.0.pom
Content is not allowed in prolog.
Could not resolve com.android.support:support-annotations:26.1.0.
Could not parse POM https://dl.google.com/dl/android/maven2/com/android/support/support-annotations/26.1.0/support-annotations-26.1.0.pom
Content is not allowed in prolog.

Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.

Get more help at https://help.gradle.org

BUILD FAILED in 45s
49.1s
Gradle task assembleDebug failed with exit code 1

this error is killing me

Following Error appears SUDDENLY with no code changes, after Flutter Packages Upgrade, I believe it's the new camera plugin bugs.
Execution failed for task ':app:transformDexArchiveWithExternalLibsDexMergerForDebug'.

com.android.builder.dexing.DexArchiveMergerException: Error while merging dex archives: D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\2.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\3.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\4.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\5.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\6.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\7.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\8.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\9.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\10.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\11.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\12.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\13.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\14.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\15.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\16.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\17.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\18.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\19.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\20.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\21.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\22.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\23.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\24.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\25.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\26.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\27.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\28.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\29.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\30.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\31.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\32.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\33.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\34.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\35.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\36.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\37.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\38.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\39.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\40.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\41.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\42.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\43.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\44.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\45.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\46.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\47.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\48.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\49.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\50.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\51.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\52.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\53.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\54.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\55.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\56.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\57.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\58.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\59.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\60.jar, D:\flutter\mms01\build\app\intermediates\transforms\dexBuilder\debug\61.jar
*********************************************************
WARNING: This version of camera will break your Android build if it or its dependencies aren't compatible with AndroidX.
See https://goo.gl/CP92wY for more information on the problem and how to fix it.
This warning prints for all Android build failures. The real root cause of the error may be unrelated.
*********************************************************
Learn how to resolve the issue at https://developer.android.com/studio/build/dependencies#duplicate_classes.
Program type already present: android.support.v4.app.INotificationSideChannel

Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.

Get more help at https://help.gradle.org

BUILD FAILED in 24s
Finished with error: Gradle task assembleDebug failed with exit code 1

You need either limit the version of the camera dependency in pubspec.yaml or follow the instructions to migrate to AndroidX.
0.2.9+1 is the last version that does not depend on AndroidX (https://pub.dartlang.org/packages/camera#030) so
dependencies:
  camera: ^0.2.9

and running flutter packages get should fix it.
You might get similar errors for other plugins if you didn't apply such constraints.

The plugins have all been updated to AndroidX, so I'm going to close this as fixed.
The official guide for migrating apps and plugins to work with AndroidX is up on our website. Please feel empowered to file new issues if you're still running into crashes after following the guide, or if the guide is unclear.

geolocator:
after adding this dependency, am getting following error from androidx
Launching lib\main.dart on E6553 in debug mode...
Initializing gradle...
Resolving dependencies...
Running Gradle task 'assembleDebug'...
E:\Flutter\flutter.pub-cache\hosted\pub.dartlang.org\geolocator-2.1.1\android\src\main\java\com\baseflow\flutter\plugin\geolocator\tasks\LastKnownLocationUsingLocationServicesTask.java:4: error: package android.support.annotation does not exist
import android.support.annotation.NonNull;
^
E:\Flutter\flutter.pub-cache\hosted\pub.dartlang.org\geolocator-2.1.1\android\src\main\java\com\baseflow\flutter\plugin\geolocator\tasks\LocationUpdatesUsingLocationServicesTask.java:5: error: package android.support.annotation does not exist
import android.support.annotation.NonNull;
^
E:\Flutter\flutter.pub-cache\hosted\pub.dartlang.org\geolocator-2.1.1\android\src\main\java\com\baseflow\flutter\plugin\geolocator\tasks\LastKnownLocationUsingLocationServicesTask.java:40: error: cannot find symbol
public void onFailure(@NonNull Exception e) {
^
symbol: class NonNull
E:\Flutter\flutter.pub-cache\hosted\pub.dartlang.org\geolocator-2.1.1\android\src\main\java\com\baseflow\flutter\plugin\geolocator\tasks\LocationUpdatesUsingLocationServicesTask.java:62: error: cannot find symbol
public void onComplete(@NonNull Task task) {
^
symbol: class NonNull
Note: Some input files use unchecked or unsafe operations.
Note: Recompile with -Xlint:unchecked for details.
4 errors
FAILURE: Build failed with an exception.

What went wrong:
Execution failed for task ':geolocator:compileDebugJavaWithJavac'.

Compilation failed; see the compiler error output for details.

Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.

Get more help at https://help.gradle.org

BUILD FAILED in 44s

The Gradle failure may have been because of AndroidX incompatibilities in this Flutter app.
See https://goo.gl/CP92wY for more information on the problem and how to fix it.

Finished with error: Gradle task assembleDebug failed with exit code 1

Faced the same issue. In my case, it's because of the "Firebase_auth" package used in a target Android SDK 28. As per the official documentation, the right version 0.7.0 and NOT THE LATEST VERSION.
You can refer to the all packages which have conflicthere

Same issues here
Launching lib\main.dart on SM G930F in debug mode...
warning: [options] source value 7 is obsolete and will be removed in a future release
warning: [options] target value 7 is obsolete and will be removed in a future release
warning: [options] To suppress warnings about obsolete options, use -Xlint:-options.
C:\flutter\.pub-cache\hosted\pub.dartlang.org\location-1.4.1\android\src\main\java\com\lyokone\location\LocationPlugin.java:14: error: package android.support.annotation does not exist
import android.support.annotation.MainThread;
                                 ^
C:\flutter\.pub-cache\hosted\pub.dartlang.org\location-1.4.1\android\src\main\java\com\lyokone\location\LocationPlugin.java:15: error: package android.support.annotation does not exist
import android.support.annotation.NonNull;
                                 ^
C:\flutter\.pub-cache\hosted\pub.dartlang.org\location-1.4.1\android\src\main\java\com\lyokone\location\LocationPlugin.java:16: error: package android.support.annotation does not exist
import android.support.annotation.Nullable;
                                 ^
C:\flutter\.pub-cache\hosted\pub.dartlang.org\location-1.4.1\android\src\main\java\com\lyokone\location\LocationPlugin.java:17: error: cannot find symbol
import android.support.v4.app.ActivityCompat;
                             ^
  symbol:   class ActivityCompat
  location: package android.support.v4.app
C:\flutter\.pub-cache\hosted\pub.dartlang.org\location-1.4.1\android\src\main\java\com\lyokone\location\LocationPlugin.java:18: error: package android.support.v4.content does not exist
import android.support.v4.content.ContextCompat;
                                 ^
C:\flutter\.pub-cache\hosted\pub.dartlang.org\location-1.4.1\android\src\main\java\com\lyokone\location\LocationPlugin.java:193: error: cannot find symbol
        int permissionState = ActivityCompat.checkSelfPermission(activity, Manifest.permission.ACCESS_FINE_LOCATION);
                              ^
  symbol:   variable ActivityCompat
  location: class LocationPlugin
C:\flutter\.pub-cache\hosted\pub.dartlang.org\location-1.4.1\android\src\main\java\com\lyokone\location\LocationPlugin.java:198: error: cannot find symbol
        ActivityCompat.requestPermissions(activity, new String[]{Manifest.permission.ACCESS_FINE_LOCATION},
        ^
  symbol:   variable ActivityCompat
  location: class LocationPlugin
C:\flutter\.pub-cache\hosted\pub.dartlang.org\location-1.4.1\android\src\main\java\com\lyokone\location\LocationPlugin.java:203: error: cannot find symbol
        return ActivityCompat.shouldShowRequestPermissionRationale(activity, Manifest.permission.ACCESS_FINE_LOCATION);
               ^
  symbol:   variable ActivityCompat
  location: class LocationPlugin
C:\flutter\.pub-cache\hosted\pub.dartlang.org\location-1.4.1\android\src\main\java\com\lyokone\location\LocationPlugin.java:296: error: cannot find symbol
            public void onFailure(@NonNull Exception e) {

  symbol:   variable ActivityCompat
  location: class LocationPlugin
C:\flutter\.pub-cache\hosted\pub.dartlang.org\location-1.4.1\android\src\main\java\com\lyokone\location\LocationPlugin.java:296: error: cannot find symbol
            public void onFailure(@NonNull Exception e) {
                                   ^
  symbol: class NonNull
9 errors
3 warnings

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':location:compileDebugJavaWithJavac'.
> Compilation failed; see the compiler error output for details.

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.

* Get more help at https://help.gradle.org

BUILD FAILED in 14s
*******************************************************************************************
The Gradle failure may have been because of AndroidX incompatibilities in this Flutter app.
See https://goo.gl/CP92wY for more information on the problem and how to fix it.
*******************************************************************************************
Gradle task assembleDebug failed with exit code 1
Exited (sigterm)

how do i start projects with Android X support. the migrating instructions are not working

I also have this problem ，when i use flutter module for my android project，use flutter packages get，then flutter android source would be replace by default and it is use support library ，not the androidx library

Did you solved this problem?

same issues here, someone fix it?

I found that starting projects in Android studio or migrating them to
Android x in Android studio was the way to go
On Wed, 4 Dec 2019, 7:31 pm robsondon<EMAIL_ADDRESS>wrote:

same issues here, someone fix it?
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
https://github.com/flutter/flutter/issues/23995?email_source=notifications&email_token=AMIKZA7GHCMMIR6GA2TUBELQW7SO7A5CNFSM4GCB2O3KYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEF53OYA#issuecomment-561756000,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AMIKZA64FKCI34WGO3Z25MTQW7SO7ANCNFSM4GCB2O3A
.

same issues here,someone fix it ?

almost 1 year after same error


Add Widget tests

Adds basic test https://github.com/maheshmnj/navbar_router/commit/1061dc34187ddbe99c2bee4c220aba8a90905cf7

All necessary widget tests are now present on the main branch


Update README.md

Hi @chsha, I'm your friendly neighborhood Microsoft Pull Request Bot (You can call me MSBOT). Thanks for your contribution!
You've already signed the contribution license agreement. Thanks!
The agreement was validated by Microsoft and real humans are currently evaluating your PR.
TTYL, MSBOT;


Video encoding using x265 2.8+69 failed with exit code: -1073741795 (0xC000001D)

So here's the error again that generated , tho this time I tried with fresh install and default settings with LONG PATHS enabled but x265 encoder still gives up and ends up with this :

Error Video encoding using x265 2.8+69 (<IP_ADDRESS>)
Video encoding using x265 2.8+69 failed with exit code: -1073741795 (0xC000001D)
The exit code might be a system error code: {EXCEPTION}
Illegal Instruction
An attempt was made to execute an illegal instruction.
------------------- Video encoding using x265 2.8+69 -------------------
"C:\Portables\StaxRip-x64-<IP_ADDRESS>\Apps\avs2pipemod\avs2pipemod64.exe" -y4mp "C:\Users\Useranon\Videos\Aquaman - Extended Trailer_temp\Aquaman - Extended Trailer.avs" | "C:\Portables\StaxRip-x64-<IP_ADDRESS>\Apps\x265\x265.exe" --crf 26 --profile main10 --frames 7611 --y4m --output "C:\Users\Useranon\Videos\Aquaman - Extended Trailer_temp\Aquaman - Extended Trailer_out.hevc" -
avs2pipemod[info]: writing 7611 frames of 24000/1001 fps, 1280x720,
sar 0:0, YUV-420-planar-8bit progressive video.
avs2pipemod[info]: finished, wrote 0 frames [0%].
avs2pipemod[info]: total elapsed time is 14.625 sec.
avs2pipemod[error]: only wrote 0 of 7611 frames.
StaxRip.ErrorAbortException: Video encoding using x265 2.8+69 failed with exit code: -1073741795 (0xC000001D)
The exit code might be a system error code: {EXCEPTION}
Illegal Instruction
An attempt was made to execute an illegal instruction.
------------------- Video encoding using x265 2.8+69 -------------------
"C:\Portables\StaxRip-x64-<IP_ADDRESS>\Apps\avs2pipemod\avs2pipemod64.exe" -y4mp "C:\Users\Useranon\Videos\Aquaman - Extended Trailer_temp\Aquaman - Extended Trailer.avs" | "C:\Portables\StaxRip-x64-<IP_ADDRESS>\Apps\x265\x265.exe" --crf 26 --profile main10 --frames 7611 --y4m --output "C:\Users\Useranon\Videos\Aquaman - Extended Trailer_temp\Aquaman - Extended Trailer_out.hevc" -
avs2pipemod[info]: writing 7611 frames of 24000/1001 fps, 1280x720,
sar 0:0, YUV-420-planar-8bit progressive video.
avs2pipemod[info]: finished, wrote 0 frames [0%].
avs2pipemod[info]: total elapsed time is 14.625 sec.
avs2pipemod[error]: only wrote 0 of 7611 frames.
at StaxRip.Proc.Start() in C:\Users\Revan\Desktop\staxrip-<IP_ADDRESS>\General\Proc.vb:line 338
at StaxRip.x265Enc.Encode(String passName, String commandLine, ProcessPriorityClass priority) in C:\Users\Revan\Desktop\staxrip-<IP_ADDRESS>\Encoding\x265Enc.vb:line 65
at StaxRip.x265Enc.Encode() in C:\Users\Revan\Desktop\staxrip-<IP_ADDRESS>\Encoding\x265Enc.vb:line 41
at StaxRip.GlobalClass.ProcessVideo() in C:\Users\Revan\Desktop\staxrip-<IP_ADDRESS>\General\GlobalClass.vb:line 231
at System.Threading.Tasks.Parallel.<>c__DisplayClass4_0.b__0()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at StaxRip.GlobalClass.ProcessJob(String jobPath) in C:\Users\Revan\Desktop\staxrip-<IP_ADDRESS>\General\GlobalClass.vb:line 138

It's very likely your filters or your CPU doesn't support the filter being used.


Update ApplicationLanguage.cs

for change output view direction when change language.

first edit LanguageInfo in abp then edit it and rebuild

We just use a simple code to check if current culture is RTL:
    public static class CultureHelper
    {
        public static bool IsRtl
        {
            get { return Thread.CurrentThread.CurrentUICulture.TextInfo.IsRightToLeft; }
        }
    }

So, .net already provides a simple way of calculating it. Why we store a calculateable value in the database?

I Like It, Thanks, but for example, in google translate page, current language and final language are not same.
this code return current cultures, i need current and final language in same time.

This was just an example of getting RTL. If you know the culture code (you know it since language definition contains it) you can do that:
var isRtl = new CultureInfo("tr-TR").TextInfo.IsRightToLeft;


[WIP] support contract call bytes array

Fixes # .
Motivation

Solution

Open questions

🟡 Heimdall Review Status

Requirement
Status
More Info

Reviews

🟡
0/1

Denominator calculation

Show calculation

1 if user is bot
0

1 if user is external
0

From .codeflow.yml

1

Additional review requirements

Show calculation

Max
0

0

From CODEOWNERS

0

Global minimum
0

Max

1

1

1 if commit is unverified
1

Sum
2


Heredocs break syntax highlighting

Including a heredoc in an HCL file causes this plugin to highlight everything after the heredoc as a string.
Update: Only happens if there is white space before the end delimiter of the HEREDOC

According to syntax:

Multi-line strings start with <<EOF at the end of a line, and end with EOF on its own line (here documents).

It states that "EOF must be on its own line", i.e. it ends when a line is found containing only EOF (so no whitespace, or other things)
So I do not think this is a bug...?


secure fatal operations

secure fatal hive operations, make them harder to execute
closes #2770

Improvement

Maybe we should also refuse queries that set both (ownerid, owneridx) and tabletid?

Maybe we should also refuse queries that set both (ownerid, owneridx) and tabletid?

the intention of this PR is to make harder to call these two particular handlers


Show param values in validation error messages

Feature Request
This originates from https://github.com/tiangolo/fastapi/issues/473:
The error messages created by the parameter validation are like "msg": "value is not a valid integer".
It would be helpful for debugging if they contained the actual value of that parmeter: "msg": f"value '{param}' is not a valid integer" -> "msg": "value 'spam' is not a valid integer"

I disagree. What if the value is a string of 5000 characters? Should we show the entire thing in the error message.
However I think we could do with improving the data available about errors, for example we should make sure the provided value is always available in ctx and that all error types are unique, so completely custom logic and error message translations work properly.

If the string is too long, we might abbreviate it like this?
str_val = str(value)
if len(str_val) > 15:
    str_val = f'{str_val[:8]}...{str_val[-4:]}'

But I would be hapy with anything that improves the error message (and thus, debugging). :)

debugging would be fixed by adding the original value to ctx which would then be shown in the str() method of ValidationError and therefore python's standard error printing.

Can I somehow help with this?

Mentioning #1938 for another use-case/problem that arises from this issue.

First of all, absolutely love the package, thanks for making something so magical @Pydantic crew.
This was doing my absolute head in as i'm working with some incredibly complex nested dataclasses, so you can do the following for a quick fix until it gets patched in:

Version: pydantic==1.6.1
validators.py
Modify the error call for the validator you want to change so that is passes the value, v
raise errors.AnyStrMaxLengthError(limit_value=min_length)
becomes...
raise errors.AnyStrMaxLengthError(value=v, limit_value=min_length)
errors.py
Follow the function call and edit the init function so it takes the value and adds it to the Super() init
class AnyStrMaxLengthError(PydanticValueError):
    code = 'any_str.max_length'
    msg_template = 'ensure this value has at most {limit_value} characters'

    # def __init__(self, *, limit_value: int) -> None:
    #   super().__init__(limit_value=limit_value)

    def __init__(self, *, value, limit_value: int) -> None:
        super().__init__(value=value, limit_value=limit_value)

It should now show up inside the ctx value in e.errors()
{'ctx': {'value': 'abcdefghijklmnopqrs', 'limit_value': 15}  ヽ( ヅ )ノ

@Fireclunge sounds like we got a PR on our hands 😜

Hallo.  If this is actually of interest to have in Pydantic, I'm (somewhat) happy to make the PR.  Have one in progress.  Many unit tests to update.  Before I go on what could be a fool's errand and continue working on tweaking each and every unit test, would there be objection to surfacing more info in ctx for each ValidationError?

Just to check.. I'm currently struggling with the fact that I don't get a traceback to the offending line of code when there's an exception in custom validation, just the validation error that includes the original exception. Would this possibly help with that?

Nope -- My in-progress change's only delta is to include the offending value for ValidationErrors.

Look forward for this feature

The ability to capture the inputs in the context would be a killer feature for me.  It sounds like this is planned for version 2, but does anyone have a workaround to get that functionality with the current version?

+1, I agree it's needed.
We shall take into consideration that value could be very long, and could use some formating to avoid it ( for example lambda value: str(value)[:20])

Use this little utility to extract the value from a validation error:
def value_from_validation_error(d: Dict, ex: ValidationError):
    values = {}
    for error in ex.errors():
        loc = error["loc"]
        value = d
        for field in loc:
            if field == "__root__":
                break
            value = value[field]
        values[".".join([str(location) for location in loc])] = value
    return values

No, we need context. What if the error is thrown by external library? I don't have anything to debug my problem. Ba, what if the library is do loop. How i can find the value that cause the error?

Use this little utility to extract the value from a validation error:
def value_from_validation_error(d: Dict, ex: ValidationError):
    values = {}
    for error in ex.errors():
        loc = error["loc"]
        value = d
        for field in loc:
            if field == "__root__":
                break
            value = value[field]
        values[".".join([str(location) for location in loc])] = value
    return values

Where do we get the d: Dict argument from?

@thorin-schiffer wrote:

Use this little utility to extract the value from a validation error:
def value_from_validation_error(d: Dict, ex: ValidationError):
    values = {}
    for error in ex.errors():
        loc = error["loc"]
        value = d
        for field in loc:
            if field == "__root__":
                break
            value = value[field]
        values[".".join([str(location) for location in loc])] = value
    return values

Where do we get the d: Dict argument from?

it's the data you supply to the pydantic model

We really need to add this functionality in configuration of pydantic model

As per https://github.com/pydantic/pydantic/issues/784#issuecomment-1136873433 this will be supported in V2 which will be released in the next couple of weeks. Closing this issue as completed 😄.

If it is not difficult to backport or implement similar functionality in V1, it would be great to see it. I do not think that all the people will be able witthout problems move to V2 in short period of time. But having this issue is something frustrating...


Remove “unified search” from more files

Following on from https://github.com/alphagov/rummager/pull/698, this commit removes “unified search” from a couple of places where they were missed last time.
Trello: https://trello.com/c/cj8UX2jX

👍 💯


⚠ File access (beta) has degraded performance

In 6a1e815, File access (beta) (https://beta.fyle.uk/file/fish) experienced degraded performance:

HTTP code: 503
Response time: 13725 ms

Resolved: File access (beta) performance has improved in 5c644c5.


Optimize AVX2 implementation

Replace mask calculation code with 3 instructions.

Go can guarantee only 8-byte alignment for our big numbers https://go.dev/ref/spec#Size_and_alignment_guarantees .
MOVDQA requires memory argument to be aligned on 32-byte boundary. This probably worked earlier because Go uses bigger alignment for small arrays on x86_64 architecture, though I am not sure and the spec provides no guarantees anyway.


added fixes for bot file

Build status - All builds passed
https://github.com/OfficeDev/Microsoft-Teams-Samples/actions/runs/6196356315


Add api.maragi.is-cool.dev.json

Requirements

[x] You have completed your website.
[x] The website is reachable.
[x] The CNAME record doesn't contain https:// or /.
[x] There is sufficient information at the owner field.
[x] Your website is not hosting on the following due to SSL issues: Vercel, Netlify

Description
This is for the API of my projects.
Link to Website
http://pnode2.danbot.host:7287/

@andrewstech only one more to go now i think lol


Hugo panics when running with -s exampleSite in v0.123.x

What version of Hugo are you using (hugo version)?

hugo v0.123.3-a75a659f6fc0cb3a52b2b2ba666a81f79a459376+extended darwin/arm64 BuildDate=2024-02-23T17:09:20Z VendorInfo=brew

Does this issue reproduce with the latest release?
Yes
Context
When upgrading Hugo from v0.122.0 to v0.123.3 I get a Hugo panic. Below the full error logs (specific to the mod-leaflet module):

Full logs
Start building sites …
hugo v0.123.3-a75a659f6fc0cb3a52b2b2ba666a81f79a459376+extended darwin/arm64 BuildDate=2024-02-23T17:09:20Z VendorInfo=brew

panic: not supported [recovered]
	panic: interface conversion: string is not error: missing method Error

goroutine 25 [running]:
github.com/spf13/fsync.(*Syncer).syncRecover.func1()
	github.com/spf13/fsync@v0.10.0/fsync.go:132 +0xac
panic({0x104063b40?, 0x1044a48f0?})
	runtime/panic.go:770 +0x124
github.com/bep/overlayfs.(*Dir).Read(0x8000?, {0x104063bc0?, 0x14000749501?, 0x100966154?})
	github.com/bep/overlayfs@v0.9.1/overlayfs.go:391 +0x2c
io.copyBuffer({0x12ca25a00, 0x1400015ed00}, {0x12ca25a20, 0x1400015eee0}, {0x0, 0x0, 0x0})
	io/io.go:429 +0x18c
io.Copy(...)
	io/io.go:388
github.com/spf13/fsync.(*Syncer).sync(0x14000749d28, {0x14000a54140, 0xd}, {0x14000a54170, 0xd})
	github.com/spf13/fsync@v0.10.0/fsync.go:173 +0x588
github.com/spf13/fsync.(*Syncer).sync.func1({0x12c9c8760, 0x1400037a540})
	github.com/spf13/fsync@v0.10.0/fsync.go:199 +0xf0
github.com/spf13/fsync.withDirEntry({0x1044d39d8?, 0x1400000e030?}, {0x103eb7d28?, 0x200000003?}, 0x14000749b80)
	github.com/spf13/fsync@v0.10.0/fsync.go:343 +0x2a8
github.com/spf13/fsync.(*Syncer).sync(0x14000749d28, {0x103eb7d28, 0x1}, {0x103eb7d28, 0x1})
	github.com/spf13/fsync@v0.10.0/fsync.go:196 +0x2ac
github.com/spf13/fsync.(*Syncer).syncRecover(0x14000749d28?, {0x103eb7d28?, 0x1?}, {0x103eb7d28?, 0x1?})
	github.com/spf13/fsync@v0.10.0/fsync.go:136 +0x58
github.com/spf13/fsync.(*Syncer).Sync(0x14000749d28, {0x103eb7d28, 0x1}, {0x103eb7d28, 0x1})
	github.com/spf13/fsync@v0.10.0/fsync.go:111 +0xa0
github.com/gohugoio/hugo/commands.(*hugoBuilder).copyStaticTo(0x14000b93100, 0x14000754120)
	github.com/gohugoio/hugo/commands/hugobuilder.go:445 +0x1e4
github.com/gohugoio/hugo/commands.(*hugoBuilder).doWithPublishDirs(0x14000b93100, 0x14000749ef8)
	github.com/gohugoio/hugo/commands/hugobuilder.go:472 +0x13c
github.com/gohugoio/hugo/commands.(*hugoBuilder).copyStatic(0x140003fa960?)
	github.com/gohugoio/hugo/commands/hugobuilder.go:403 +0x34
github.com/gohugoio/hugo/commands.(*hugoBuilder).fullBuild.func2()
	github.com/gohugoio/hugo/commands/hugobuilder.go:507 +0x28
golang.org/x/sync/errgroup.(*Group).Go.func1()
	golang.org/x/sync@v0.6.0/errgroup/errgroup.go:78 +0x58
created by golang.org/x/sync/errgroup.(*Group).Go in goroutine 1
	golang.org/x/sync@v0.6.0/errgroup/errgroup.go:75 +0x98

To reproduce
git clone https://github.com/gethinode/mod-leaflet.git
cd mod-leaflet
hugo mod vendor
hugo --gc --minify -s exampleSite

Notes
I'm transitioning the various modules maintained by gethinode to take advantage of work files (see https://github.com/gethinode/hinode/pull/786), which might prevent this issue. Nevertheless, it seemed to make sense to submit this issue anyways.

OK, I have a failing test case for this now and I will fix this.
  [[module.imports.mounts]]
    source = "dist"
    target = "static"
  [[module.imports.mounts]]
    source = "dist/leaflet.scss"
    target = "static/leaflet.css"

My logic didn't handle the "double mounts" above and paniced when it tried to read the directory as a file. You can workaround this by ... removing the single file mount (and rename or copy the source file).
I have reimplemented and simplified the file mounts in Hugo, and I obviously missed some cases where the old code worked, but at least I can now understand my own code :-)
But I will fix, thanks for the report.

Thanks @bep!
I agree the “double” mounting is a bit odd. The module is basically wrapping an existing npm package to modularize it for Hugo. I was trying to avoid an additional npm script to rename/copy an existing dist file…


Unable receive response from serial device

I have a SIM7000 NB-IoT modem attached to a Raspberry Pi. It's connected via serial and I'm trying to control it using node.js and node-serialport.
Using screen I am able to communicate with the modem. Sending AT commands works and the response is received back and printed to the terminal.
When I issue the same command using node-serialport I do not receive an error on the .write() command however the response is not received and shown on screen.
Using screen /dev/ttyS0:
AT+CSQ
+CSQ: 30,99

OK

AT+CSQ is the command send to the modem by typing it in the terminal.
The output of the script, source below, when running DEBUG=serialport/* node index.js:
  serialport/bindings loading LinuxBinding +0ms
  serialport/stream opening path: /dev/ttyS0 +0ms
  serialport/binding-abstract open +0ms
  serialport/stream _read queueing _read for after open +38ms
  serialport/bindings/poller Creating poller +0ms
  serialport/stream opened path: /dev/ttyS0 +25ms
Port is open
  serialport/stream _write 6 bytes of data +36ms
  serialport/binding-abstract write 6 bytes +97ms
  serialport/stream _read reading +13ms
  serialport/binding-abstract read +12ms
  serialport/bindings/unixWrite Starting write 6 bytes offset 0 bytesToWrite 6 +0ms
  serialport/bindings/unixRead Starting read +0ms
  serialport/bindings/unixWrite write returned null 6 +27ms
  serialport/bindings/unixWrite wrote 6 bytes +2ms
  serialport/bindings/unixWrite Finished writing 6 bytes +2ms
  serialport/stream binding.write write finished +49ms
Message send
  serialport/bindings/unixRead waiting for readable because of code: EAGAIN +35ms
  serialport/bindings/poller Polling for "readable" +119ms
  serialport/bindings/poller received "readable" +6ms
  serialport/binding-abstract read +71ms
  serialport/bindings/unixRead Starting read +19ms
  serialport/bindings/unixRead Finished read 6 bytes +4ms
  serialport/stream binding.read finished +38ms
Data:  AT+CSQ
  serialport/stream _read reading +21ms
  serialport/binding-abstract read +35ms
  serialport/bindings/unixRead Starting read +32ms
  serialport/bindings/unixRead waiting for readable because of code: EAGAIN +4ms
  serialport/bindings/poller Polling for "readable" +51ms

The source code of index.js:
const SerialPort = require('serialport');
const port = new SerialPort('/dev/ttyS0', {
  baudRate: 9600,
  dataBits: 8,
  stopBits: 1,
  parity: 'none',
  xon: true,
  xoff: true
});

port.on('open', function () {

  console.log('Port is open');

  port.write('AT+CSQ', function(error) {
    console.log('Message send');
    if(error) console.error('Error:', error);
  });

});

port.on('data', function (data) {
  console.log('Data: ', data.toString())
});

<EMAIL_ADDRESS>Node: v10.15.1
Running on Raspbian (Linux) on a RaspberryPi.
The serial port is enabled and the ssh terminal on the serial port is disabled.
I've tried connecting the modem to my Windows laptop and using Putty and that also does work.
Putty settings:

I've followed the examples from the documentation and tried several solutions from Github and StackOverflow. The command seems to be echo'ed back just fine it's just the response that should follow after it that's not received.
The device works as is shown using screen and putty so I clearly must be missing something in the JS code. I just can't figure out what I'm missing so any help on this is appreciated.

In my case, the problem was with ModemManager, which was probing the serial port during startup and block it. I create the udev rule to specify the ModemManger should skip modem's (GPS, etc) serial port.


View migrator feature?

So far, most of the logic I have seen for handling migrations, is written to handle table creation. But database views are also a very powerful concept that is relevant to database related development as it can greatly simplify the database queries in the application.
Views are different from most tables in that you never alter a view; you drop it and recreate it. However, it is still useful to describe multiple versions of a view, so that you can "migrate" to a specific view version. While doing so, you don't want to drop and recreate all the intermediate view versions.
So a "migrator" for a view would, instead of tracking "applied" migrations, track only a single version per view (or group of views). If the applied version does not match the target version, run the "target" migration "up". We can assume this migration starts with a DROP VIEW x IF EXISTS; before creation.
The approach can also be used to manage materialized views.
Having a separate migration concept for view could be a real power feature. If it's useful to include in the scope of bun or bun/migrate is a completely different question, so please feel free to reject this.

We can assume this migration starts with a DROP VIEW x IF EXISTS; before creation.

Or maybe a more accurate approach.. run down on the applied migration, the up for the target migration.

It is hard to tell whether all (supported) dbs behave the same, but even then being too smart with migrations does not sound like a good idea. I think that rules for running migrations must be simple and consistent. We should not (and likely can't) introduce migration-specific rules.
I personally never had problems with VIEWs and Postgres. The only catch is that you need to re-create them manually whenever base table changes, but it is pretty simple to do with CREATE OR REPLACE or DROP+CREATE.

While doing so, you don't want to drop and recreate all the intermediate view versions.

But why? Just to save few queries? It does not seem worth optimizing...

Let's close this.


Add new command to create generalized tables

It would be useful when importing to be able to split the generalization off from the import stage.
When we have a database that has existed for some time, being updated regularly, it would be useful to update the generalized without needing to do a full reimport.

@pnorman, @moodstubos,
Was this issue already addressed?
When using imposm 0.11.1  to run =imposm diff, it prints Updating generalized tables:
[2022-04-14T07:00:43Z] 0:00:04 [step] Starting: Processing /import/changes.osc.gz
[2022-04-14T07:00:43Z] 0:00:04 [step] Starting: Parsing changes, updating cache and removing elements
[2022-04-14T07:00:54Z] 0:00:14 [step] Finished: Parsing changes, updating cache and removing elements in 10.5643517s
[2022-04-14T07:00:54Z] 0:00:14 [step] Starting: Importing added/modified elements
[2022-04-14T07:00:54Z] 0:00:14 [progress]    10s C:       0/s (35384) N:       0/s (21) W:       0/s (433) R:      0/s (26)
[2022-04-14T07:01:02Z] 0:00:22 [step] Starting: Updating generalized tables
[2022-04-14T07:01:02Z] 0:00:22 [step] Finished: Updating generalized tables in 23.2597ms
[2022-04-14T07:01:54Z] 0:01:14 [progress]   1m0s C:       0/s (0) N:       0/s (22) W:       0/s (106) R:      0/s (21)
[2022-04-14T07:01:57Z] 0:01:17 [step] Finished: Importing added/modified elements in 1m2.7701817s
[2022-04-14T07:01:57Z] 0:01:17 [progress]   1m2s C:       0/s (0) N:       0/s (22) W:       0/s (106) R:      0/s (21)
[2022-04-14T07:01:57Z] 0:01:17 [step] Finished: Processing /import/changes.osc.gz in 1m13.3705493s


mermaidjs with the react-markdown issue with Remix ESM

I tried to use the mermaidjs with the react-markdown for a Remix app. However, my app stop working with error
TypeError: The argument 'filename' must be a file URL object, file URL string, or absolute path string. Received undefined
    at new NodeError (node:internal/errors:372:5)
    at createRequire (node:internal/modules/cjs/loader:1224:11)
    at Object.<anonymous> (/my-app/node_modules/remark-mermaidjs/index.js:8:11)
    at Module._compile (node:internal/modules/cjs/loader:1105:14)
    at Object.Module._extensions..js (node:internal/modules/cjs/loader:1159:10)
    at Module.load (node:internal/modules/cjs/loader:981:32)
    at Function.Module._load (node:internal/modules/cjs/loader:822:12)
    at Module.require (node:internal/modules/cjs/loader:1005:19)
    at require (node:internal/modules/cjs/helpers:102:18)
    at /my-app/node_modules/@remix-run/serve/dist/index.js:43:17
    at Layer.handle [as handle_request] (/my-app/node_modules/express/lib/router/layer.js:95:5)
    at next (/my-app/node_modules/express/lib/router/route.js:144:13)
    at next (/my-app/node_modules/express/lib/router/route.js:140:7)
    at next (/my-app/node_modules/express/lib/router/route.js:140:7)
    at next (/my-app/node_modules/express/lib/router/route.js:140:7)
    at next (/my-app/node_modules/express/lib/router/route.js:140:7)

package.json
"react-markdown": "^8.0.3",
"remark-mermaidjs": "^4.1.1",

I also have a list of rehype and remark that has no issue running with react-markdown
"rehype-sanitize": "^5.0.1",
"rehype-slug": "^5.0.1",
"remark-breaks": "^3.0.2",
"remark-directive": "^2.0.1",
"remark-directive-rehype": "^0.4.0",
"remark-gfm": "^3.0.1",
"remark-remove-comments": "^0.2.0",

component.tsx
import React from "react";

import ReactMarkdown from "react-markdown";
import remarkMermaid from "remark-mermaidjs";

import rehypeSlug from "rehype-slug";
import remarkGfm from "remark-gfm";
import remarkDirective from "remark-directive";
import remarkDirectiveRehype from "remark-directive-rehype";
import remarkRemoveComments from "remark-remove-comments";
import remarkBreaks from "remark-breaks";

interface Props {
	content: string;
}

export function MarkDown({ content }: Props) {
	return (
        <ReactMarkdown
            components={{
                p: ({ children }) => {
                    return (

                            {children}

                    );
                },
            }}
            children={content}
            rehypePlugins={[rehypeSlug]}
            remarkPlugins={[
                remarkBreaks,
                remarkGfm,
                remarkDirective,
                remarkDirectiveRehype,
                remarkRemoveComments,
                remarkMermaid,
            ]}
        />
	);
}

Content in markdown
## Heading 2
Paragraph lorem ipsum

The error appears on this line:
https://github.com/remcohaszing/remark-mermaidjs/blob/95188b1a1466f1e16b057426562e0b99a8c26c90/index.ts#L15
This line uses import.meta.url, which is defined in ESM, but appears to be undefined for you. This is probably caused by an incorrect transpilation to CJS.
This is a bug in Remix, not remark-mermaidjs. Some possibilities I see for them to fix it are:

Support ESM. (This is definitely preferred!)
Replace import.meta.url with String(pathToFileURL(__filename))
Replace createRequire(import.meta.url) with require

@remcohaszing Thanks for the insights.
Are you referring to this Remix issue Unable to import from libs using ESM. Remix has a work around for importing ESM packages, that I have applied for react-markdown, rehype* and remark* packages. If I don't, it will show in the console in development mode. However, it was not the case with remark-mermaidjs
[1] rehype-slug is possibly an ESM only package and should be bundled with "serverDependenciesToBundle in remix.config.js.
[1] remark-gfm is possibly an ESM only package and should be bundled with "serverDependenciesToBundle in remix.config.js.
[1] remark-directive is possibly an ESM only package and should be bundled with "serverDependenciesToBundle in remix.config.js.
[1] remark-directive-rehype is possibly an ESM only package and should be bundled with "serverDependenciesToBundle in remix.config.js.
[1] remark-breaks is possibly an ESM only package and should be bundled with "serverDependenciesToBundle in remix.config.js.

Yes, that is the issue where they attempted to solve it. They just didn’t solve it for the specific use case of import.meta.url. You should create a new issue there (if it doesn’t exist yet).

There is this discussion about support import.meta.url.
Is there any alternative that I could work on in my end?
Probably to use shortcode in markdown to call for a react mermaidjs component instead of using remark...

That discussion is old. Maybe if you create a new issue about being unable to use ESM packages, with a link to this particular issue, they will take it more seriously. Yours is a very legitimate, practical use case they should support IMO.
As a workaround, ff you can move it to an async context, you can try a dynamic import.
Otherwise, maybe, as a very last resort this works:
function cjsRemarkMermaid(options) {
  return async (ast, file) => {
    const { default: remarkMermaid } = await import('remark-mermaidjs')
    const transformer = remarkMermaid.call(this, options)
    return transformer.call(this, ast, file)
  }
}

module.exports = cjsRemarkMermaid

@remcohaszing I created a Remix issue #5588 -> If you think there is something missing or incorrect feel free to comment 🙏
I tried your suggested alternative by creating the following -> I might have misunderstood how to use it:
// esm.modules.js
function cjsRemarkMermaid(options) {
  return async (ast, file) => {
    const { default: remarkMermaid } = await import('remark-mermaidjs')
    const transformer = remarkMermaid.call(this, options)
    return transformer.call(this, ast, file)
  }
}

module.exports = cjsRemarkMermaid

// component.tsx
import ReactMarkdown from "react-markdown";
import cjsRemarkMermaid from "../../esm-modules.js;

interface Props {
	content: string;
}

export function MarkDown({ content }: Props) {
	return (
        <ReactMarkdown
            components={{
                p: ({ children }) => {
                    return (

                            {children}

                    );
                },
            }}
            children={content}
            remarkPlugins={[
                cjsRemarkMermaid,
            ]}
        />
	);
}

But the app crash with the additional error:
Probably because react-markdown currently expects all plugins to be syncronous
Error: `runSync` finished async. Use `run` instead
    at assertDone (/my-app/node_modules/react-markdown/node_modules/unified/lib/index.js:566:11)
    at Function.runSync (/my-app/node_modules/react-markdown/node_modules/unified/lib/index.js:352:5)
    at ReactMarkdown (/my-app/node_modules/react-markdown/lib/react-markdown.js:106:30)
    at processChild (/my-app/node_modules/react-dom/cjs/react-dom-server.node.development.js:3353:14)
    at resolve (/my-app/node_modules/react-dom/cjs/react-dom-server.node.development.js:3270:5)
    at ReactDOMServerRenderer.render (/my-app/node_modules/react-dom/cjs/react-dom-server.node.development.js:3753:22)
    at ReactDOMServerRenderer.read (/my-app/node_modules/react-dom/cjs/react-dom-server.node.development.js:3690:29)
    at renderToString (/my-app/node_modules/react-dom/cjs/react-dom-server.node.development.js:4298:27)
    at handleRequest (/my-app/app/entry.server.tsx:30:17)
    at handleDocumentRequest (/my-app/node_modules/@remix-run/node/node_modules/@remix-run/server-runtime/dist/server.js:395:18)
    at processTicksAndRejections (node:internal/process/task_queues:96:5)
    at requestHandler (/my-app/node_modules/@remix-run/node/node_modules/@remix-run/server-runtime/dist/server.js:49:18)
    at /my-app/node_modules/@remix-run/express/dist/server.js:39:22
TypeError: The argument 'filename' must be a file URL object, file URL string, or absolute path string. Received undefined
    at new NodeError (node:internal/errors:372:5)
    at createRequire (node:internal/modules/cjs/loader:1224:11)
    at node_modules/remark-mermaidjs/index.js (/my-app/node_modules/remark-mermaidjs/index.js:8:11)
    at /my-app/build/index.js:7:56
    at /my-app/esm-modules.js:3:46
    at processTicksAndRejections (node:internal/process/task_queues:96:5)
    at /my-app/esm-modules.js:3:40
fatal error: all goroutines are asleep - deadlock!

Oof that’s a tough one. I’m not sure how to proceed here.
remark-mermaidjs is an asynchronous plugin. I don’t see how it can be synchronous. To solve this, react-markdown would need to support asynchronous plugins, and it would need to work with Remix, and it would need to work with other React frameworks.
Do you need to use a content prop? Can you use MDX? (MDX can also handle plain markdown files and use all of remark / rehype)

Do you need to use a content prop?

The content of the markdown comes from a field that editor add content in the Sanity CMS.
## Heading
Paragraph lorem ipsum
... mermaid code

I know Remix supports MDX, but I don't know how they support it. I haven't used Remix nor Sanity CMS myself.
I'm afraid I can't help you any further. I hope you find a solution and are willing to share it here to help others who might run into this.

Going with MDX approach by using shortcode in markdown to render mermaid component using remark-directive and remark-directive-rehype packages.
// markdown.tsx
import React from "react";
import ReactMarkdown from "react-markdown";
import remarkDirective from "remark-directive";
import remarkDirectiveRehype from "remark-directive-rehype";

import { Mermaid } from "~/components/mermaid";

declare global {
	namespace JSX {
		interface IntrinsicElements {
			mermaid: { id: string; children: string };
		}
	}
}

interface Props {
	content: string;
}

export function MarkDown({ content }: Props) {
	return (
        <ReactMarkdown
            components={{
                mermaid: Mermaid,
            }}
            children={content}
            remarkPlugins={[
                remarkDirective,
                remarkDirectiveRehype,
            ]}
        />
	);
}

// components/mermaid.tsx
import React from "react";
import mermaid from "mermaid";

// Set default configuration for Mermaid
mermaid.initialize({
  startOnLoad: true,
});

type MermaidProps = {
  children: string;
  id?: string;
};

export function Mermaid({
  children,
  id,
}: MermaidProps) {
  //const randomId = generateRandomId();

  React.useEffect(() => {
    mermaid.init(undefined, `#mermaid-${id}`);
  }, []);

  if (!children) return null;

  return <div id={`mermaid-${id}`}>{children}
;
};

Importing ESM package to Remix - guide
//remix.config.js
module.exports = {
	serverDependenciesToBundle: [
		/^rehype.*/,
		/^remark.*/,
		/^react-markdown$/,
		/^mermaid.*/,
		/^khroma*/,
		/^d3*/,
		/^lodash-es*/,
		/^dagre-d3-es.*/,
		/^robust-predicates*/,
		/^internmap.*/,
	],
};

Shortcode in markdown
::mermaid[flowchart TD;Start-->Stop;]{id="1"}

This approach works but if there are more mermaid diagram in the same page, some of the diagram didn't get render with the following error, probably due to the mermaid script loads as async.

It looks like you went from server-side rendering to client-side rendering. This is also supported by remark-mermaidjs, and is even synchronous.

uhh, I don’t think that’s an “MDX approach”? Where is MDX?

What i meant is include JSX in Markdown document

Do you have an example how it would work in my example setup?

The same as in your original example. I don’t know how Remix determines what to run on the server or client. Your original post showed a Node.js stacktrace, which means it runs on the server. Your latest examples shows you import mermaid, which only works client-side.

Is tricky with the Remix setup.
Sometime or some of the diagram didn't get render with the following error, probably due to Remix to bundle the ESM module directly into the server build instead of requiring it at runtime causing the text node not matching between server and client side.
The same component works with basic react component - code example.


update poetry and pre-commit

Closes #408

[x] Updated pytorch
[x] updated pytorch lightning
[x] fix optimizer_closure error
[x] remove warnings from torch / pytorch lightning that have been piling up

Looks like you're getting some errors from Ray. But I don't think we need that dependency any more, right? Perhaps this is a good time to get rid of it.

@jeff-regier - we haven't used ray in a while but the bliss/tune.py still exists which uses ray and that is how we got some of the hyper-parameters for optimizing m2.

It seems to be a known issue:  https://github.com/ray-project/ray/issues/20741

I thought no one was using tune.py. If so, it seems better to remove it from master.

@jeff-regier or @dereklhansen have any of you seen the current message in the CI ? It's strange because I don't get this in the server when I run pytest

Maybe relevant: https://stackoverflow.com/questions/70520120/attributeerror-module-setuptools-distutils-has-no-attribute-version

same error pinning version 1.9 of pytorch, I might put off upgrading till later

The post suggests that pinning setuptools==59.5.0 will work. It's strange, the issue doesn't come up for me either on the deeplearning-01 server

I pinned torch to >= 1.8, < 1.9 and the test pass now but I get these warnings only in the CI. Should we merge @jeff-regier  ?
../../../.cache/pypoetry/virtualenvs/bliss-UE3m6-Ul-py3.8/lib/python3.8/site-packages/torch/utils/tensorboard/__init__.py:3
../../../.cache/pypoetry/virtualenvs/bliss-UE3m6-Ul-py3.8/lib/python3.8/site-packages/torch/utils/tensorboard/__init__.py:3
  /home/runner/.cache/pypoetry/virtualenvs/bliss-UE3m6-Ul-py3.8/lib/python3.8/site-packages/torch/utils/tensorboard/__init__.py:3: DeprecationWarning: distutils Version classes are deprecated. Use packaging.version instead.
    if not hasattr(tensorboard, '__version__') or LooseVersion(tensorboard.__version__) < LooseVersion('1.15'):
../../../.cache/pypoetry/virtualenvs/bliss-UE3m6-Ul-py3.8/lib/python3.8/site-packages/astropy/version.py:26
  /home/runner/.cache/pypoetry/virtualenvs/bliss-UE3m6-Ul-py3.8/lib/python3.8/site-packages/astropy/version.py:26: DeprecationWarning: distutils Version classes are deprecated. Use packaging.version instead.
    for j, piece in enumerate(LooseVersion(version).version[:3]):
../../../.cache/pypoetry/virtualenvs/bliss-UE3m6-Ul-py3.8/lib/python3.8/site-packages/astropy/utils/introspection.py:161
../../../.cache/pypoetry/virtualenvs/bliss-UE3m6-Ul-py3.8/lib/python3.8/site-packages/astropy/utils/introspection.py:161
../../../.cache/pypoetry/virtualenvs/bliss-UE3m6-Ul-py3.8/lib/python3.8/site-packages/astropy/utils/introspection.py:161
../../../.cache/pypoetry/virtualenvs/bliss-UE3m6-Ul-py3.8/lib/python3.8/site-packages/astropy/utils/introspection.py:161
../../../.cache/pypoetry/virtualenvs/bliss-UE3m6-Ul-py3.8/lib/python3.8/site-packages/astropy/utils/introspection.py:161
../../../.cache/pypoetry/virtualenvs/bliss-UE3m6-Ul-py3.8/lib/python3.8/site-packages/astropy/utils/introspection.py:161
  /home/runner/.cache/pypoetry/virtualenvs/bliss-UE3m6-Ul-py3.8/lib/python3.8/site-packages/astropy/utils/introspection.py:161: DeprecationWarning: distutils Version classes are deprecated. Use packaging.version instead.
    return LooseVersion(have_version) >= LooseVersion(version)
../../../.cache/pypoetry/virtualenvs/bliss-UE3m6-Ul-py3.8/lib/python3.8/site-packages/seaborn/rcmod.py:82
  /home/runner/.cache/pypoetry/virtualenvs/bliss-UE3m6-Ul-py3.8/lib/python3.8/site-packages/seaborn/rcmod.py:82: DeprecationWarning: distutils Version classes are deprecated. Use packaging.version instead.
    if LooseVersion(mpl.__version__) >= "3.0":
../../../.cache/pypoetry/virtualenvs/bliss-UE3m6-Ul-py3.8/lib/python3.8/site-packages/setuptools/_distutils/version.py:351
  /home/runner/.cache/pypoetry/virtualenvs/bliss-UE3m6-Ul-py3.8/lib/python3.8/site-packages/setuptools/_distutils/version.py:351: DeprecationWarning: distutils Version classes are deprecated. Use packaging.version instead.
    other = LooseVersion(other)
-- Docs: https://docs.pytest.org/en/stable/warnings.html

Yes, seems fine. We can figure out how to update to pytorch all the way another time.

Hey @ismael-mendoza @jeff-regier fyi newer versions of Ray Tune now support PTL 1.5, if this was the blocker for using Ray Tune.


UFD use case tutorial and usability improvement

Added additional tutorial on how to use UFD to train and evaluate on custom dataset
Bug fix for UFD parse_args_and_load_config util function
Added feature to create folder if folder doesn't exist
Added some train args param in eval args param to improve usability
Made caching optional
Added validation to make debugging easier
Added links to config file examples for reccon models

closes #10


Reduce container image size

File creations and deletions moved to same layer to reduce size.
Achieved the image size reduction of 270MB.
$ docker image ls |grep chainer-chemistry
chainer-chemistry           modified<PHONE_NUMBER>        18 minutes ago      4.59GB
chainer-chemistry           latest<PHONE_NUMBER>        About an hour ago   4.86GB

Codecov Report

Merging #365 into master will not change coverage.
The diff coverage is n/a.

@@           Coverage Diff           @@
##           master     #365   +/-   ##
=======================================
  Coverage   83.89%   83.89%
=======================================
  Files         219      219
  Lines       10324    10324
=======================================
  Hits         8661     8661
  Misses       1663     1663

LGTM!

Thank you for PR & Review!!


Fix const-ness bug in sparse_map::value

Hello,
Thank you for your contribution. Unfortunately removing the constness of iterator::value_type would allow the modification of the key which could lead to breaking the hash map.
See https://github.com/Tessil/ordered-map/issues/32 if you want some details on the reason of the value() method.
Thibaut


fix new sts selector not match template labels

fix #1465
when reconcile chk statefulset, cur selector should be updated together with spec.Template
Important items to consider before making a Pull Request
Please check items PR complies to:

[x] All commits in the PR are squashed. More info
[x] The PR is made into dedicated next-release branch, not into master branch1. More info
[x] The PR is signed. More info

thanks for contribution


Problem with some android versions?

I've tried 4 or 5 devices for now, from different manufacturer. Generally the plugin works well, only on a samsung s4 mini (android 4.2.2) the plugin fails without errors (and the same for sockets-upd plugin too). There are any known incompatibility? There are some tests that I can try to identify or resolve this problem?
Thanks.

Seems a problem with String.fromCharCode.apply function that fail on some android device (ie samsung s4 mini), resolved using different function to convert arrayBuffer to string.


Get the very basic phaser instance working

Current dependencies on/for this PR:

main

PR #13

PR #14   👈

This stack of pull requests is managed by Graphite.

Merge activity

Dec 18, 12:46 AM: @@kadhirvelm started a stack merge that includes this pull request via Graphite.


Deployment Powershell SAS Template

The Powershell New-AzResourceGroupDeployment can't just read the json file, it seems that you need to generate the SAS token first since the location is not public, please double check the information on the deployment section

Document Details
⚠ Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.

ID: e50dfe50-c177-f976-753b-9fa689d20f92
Version Independent ID: 7f787259-8ce5-9ba6-8df7-58ab0b89dd5c
Content: Back up and recover Azure VMs with PowerShell - Azure Backup
Content Source: articles/backup/backup-azure-vms-automation.md
Service: backup
GitHub Login: @dcurwin
Microsoft Alias: dacurwin

#reassign:pvrk

@dcurwin Thanks for the quick response. :+1:

@jofrance : Thanks for this. I missed documenting the command which allows you to get temporary SAS token as mentioned here. Will update the documentation and update this thread.

Updated the document under this section.
Hope this helps. Many thanks for the feedback.
#please-close


Hello

Hello, I wanna let you know that with the new update, whenever I make a new URI now, it would not add the ID/UID right to the existing YAML, but rather add it on its top, so it looks like this:
---
UID: 91608624-80cf-4362-8ead-1dee50281ab9
---
---
Personal ID: - - MM
ID:<PHONE_NUMBER>1730
Title: MM - y - DC - 10. Release Approval
Aliases: [MM - y - DC - 10. Release Approval ]
Summary:
Date Created: 2022 W48 Thursday, November 24
---

It used to make this:
---
UID: 91608624-80cf-4362-8ead-1dee50281ab9
Personal ID: - - MM
ID:<PHONE_NUMBER>1730
Title: MM - y - DC - 10. Release Approval
Aliases: [MM - y - DC - 10. Release Approval ]
Summary:
Date Created: 2022 W48 Thursday, November 24
---

Can you help me with this issue? Thank you

Your yaml(frontmatter) is invalid. You can validate it for example here. You need to surround your Personal ID" value with "`.


⚠ SceneTime has degraded performance

In e5de90a, SceneTime ($ST) experienced degraded performance:

HTTP code: 200
Response time: 1502 ms

Resolved: SceneTime performance has improved in 26c6f50 after 7 minutes.