Enhancement: IP/NIC selection

As discussed in https://github.com/phinze/landrush/issues/114 this is an attempt at making the IP selection more flexible on guests that have multiple NICs defined.
These may be actual NICs but may also just be tunnels defined by a number of tools. A very common use case are guests with Docker installed; currently, landrush will pick up the IP address of the docker0 interface rather than ethX.
This pull request is not yet complete, as further discussion is required regarding the options, this serves as a proof of concept.

Minimal proof of concept:
Vagrant.configure(2) do |vagrant|
    vagrant.vm.box      = 'debian/jessie64'
    vagrant.vm.hostname = 'test.landrush.dev'

    # This adds eth1; which will get an 172.xxx.xxx.xxx IP address
    vagrant.vm.network 'private_network', type: 'dhcp'

    # Landrush configuration
    vagrant.landrush.enabled   = true
    vagrant.landrush.tld       = 'landrush.dev'
    vagrant.landrush.interface = 'eth0'

    # VirtualBox settings (1 GB RAM @ 2 cores)
    vagrant.vm.provider :virtualbox do |vb|
        vb.customize ['modifyvm', :id, '--memory', '1024', '--cpus', '2']
    end
end

Result (some bits cut out for brevity)
$ vagrant up
...
==> default: Machine booted and ready!
==> default: [landrush] setting up machine's DNS to point to our server
==> default: [landrush] network: :private_network, {:type=>"dhcp", :protocol=>"tcp", :id=>"1a0b587c-df14-423c-8959-2b87b8ed8283"}
==> default: [landrush] network: :forwarded_port, {:guest=>22, :host=>2222, :host_ip=>"<IP_ADDRESS>", :id=>"ssh", :auto_correct=>true, :protocol=>"tcp"}
==> default: Checking for guest additions in VM...
==> default: Setting hostname...
==> default: Configuring and enabling network interfaces...
[landrush-ip] Platform: linux/amd64
[landrush-ip] Using https://github.com/Werelds/landrush-ip/releases/download/0.1.1/linux_amd64_landrush-ip
==> default: [landrush] adding machine entry: test.landrush.dev => <IP_ADDRESS>

SSH into the box to check that we indeed got eth0:
$ vagrant ssh

The programs included with the Debian GNU/Linux system are free software;
the exact distribution terms for each program are described in the
individual files in /usr/share/doc/*/copyright.

Debian GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent
permitted by applicable law.
Last login: Sat Aug 15 15:03:29 2015 from <IP_ADDRESS>

vagrant@test:~$ hostname -I
<IP_ADDRESS> <IP_ADDRESS>

vagrant@test:~$ ip a
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
    inet <IP_ADDRESS>/8 scope host lo
       valid_lft forever preferred_lft forever
    inet6 ::1/128 scope host
       valid_lft forever preferred_lft forever
2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP group default qlen 1000
    link/ether 08:00:27:fe:b8:21 brd ff:ff:ff:ff:ff:ff
    inet <IP_ADDRESS>/24 brd <IP_ADDRESS> scope global eth0
       valid_lft forever preferred_lft forever
    inet6 fe80::a00:27ff:fefe:b821/64 scope link
       valid_lft forever preferred_lft forever
3: eth1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP group default qlen 1000
    link/ether 08:00:27:62:7b:15 brd ff:ff:ff:ff:ff:ff
    inet <IP_ADDRESS>/24 brd <IP_ADDRESS> scope global eth1
       valid_lft forever preferred_lft forever

Last but not least, let's ping the bastard:
$ ping test.landrush.dev
PING test.landrush.dev (<IP_ADDRESS>): 56 data bytes
Request timeout for icmp_seq 0```

Further thoughts from my end:

exclude as an option, to exclude interfaces matching a pattern; i.e. landrush.exclude = ['docker*', 'tun*'] (which would be a sensible default too)?
Needs more/better logging; I wasn't sure how to structure it, so right now there's a little bit of a hack in the landrush-ip installer to have a tiny bit of debug logging going on, but this should be cleaner. And if it fails, that error should be logged. If someone can point me in the right direction I'll adjust this

:thumbsup:
This would be a great feature! At the moment I have no use for landrush since it uses the IP of bridged interface eth2 whereas I would need it to use the IP of eth1 which is a "public_network".

So sorry for the lack of activity on this, I have been ridiculously busy. I did get a few more things implemented a couple of weeks ago (changed my logging slightly and added the exclude option), just haven't had time to 100% test it yet.

@Werelds can you rebase this patch?

+1

Will do as soon as I get a chance.

+1

TBH, I am a bit skeptical about this. I don't like the idea of including a non standard binary. How do we make enhancement and bug fixes to it? We are having a hard time keeping this project alive and we basically take on another dependent one.
I agree that not all guest will have ipconfig or ip installed, but it can be provisioned. It is for sure a bit more effort, but there are examples out there which already do it. You just need to figure out which package manager to use and then install the right package.
That said, why not skip all the tools and go to the proc filesystem directly. Just catting something like /proc/net/tcp  or /proc/net/arp should give us the same information we would get via this little go program. We also can use all of Ruby's string manipulation capabilities to extract the information we need.
Thoughts?

Agree with your concerns.
Landrush is already installing iptables with a capabiliy.
But if we can get the IP information in a cross-platform compatible way from files in /proc then that would be wonderful! I have no experience with that though.

Landrush is already installing iptables with a capabiliy.

Right, so the same approach could be taken to get iptables or ifconfig installed.

But if we can get the IP information in a cross-platform compatible way from files in /proc then that would be wonderful

I am not an expert either, but I had a quick look at the files and they contain the information we need. Some files encode the IP in reverse order in HEX, but that's easy to decode. ATM, /proc/net/arp seems to be the easiest to use.
One thing which is not clear to me (in neither solution) is how to make a decision about which interface to use, if there are multiple. In the most common case you will have two interfaces. The first, the default Vagrant interface and the second the private network interface, either configured explicitly by the user or added by Landrush. But what if the user adds multiple network configurations. This will result into multiple routable interfaces. Either one needs to choose one "randomly" or based on some heuristics (10.x.x.x addresses before 192.x.x.x etc) or one lets the user interactively choose the IP to bind to. But as said, this is really an orthogonal issue.

If anything, the /proc approach is the only one to consider in my opinion. Installing ipconfig/ip is not a sustainable option, you would have to do this for every Linux flavour under the sun (and wouldn't work for Windows). I think that's far less maintainable than a tiny Golang binary that can easily be cross compiled.
I only did it in a separate project because it seemed the best way at the time, but the 97 lines in main.go can easily be put inside this project and compiled on Travis, as well as be pushed with every release.
That said, even /proc obviously doesn't work for Windows guests, but for Windows a single implementation without having to install anything should be possible. For Linux, /proc/net/arp is not useful, one would still have to have some tools to resolve the gateways. /proc/net/tcp is a list of open connections, it doesn't tell you which interface (and would only work for interfaces that actually have an open connection). In fact, there's not a single file that'll give us what we want, it'll involve a whole load of files..and not all are present on all distributions.
Do you have an example of how to retrieve it all from /proc/net?

Here's some sample data for you from one of my VMs. You're underestimating the complexity ;)
Interfaces, their IPs and MAC addresses:
lo      <IP_ADDRESS>    00:00:00:00:00:00
eth0    <IP_ADDRESS>    08:00:27:fe:b8:21
eth1    <IP_ADDRESS> 08:00:27:2f:54:b6
docker0 <IP_ADDRESS>   02:42:8c:05:39:2b

Now, let's take a look at /proc/net/arp:
IP address       HW type     Flags       HW address            Mask     Device
<IP_ADDRESS>     0x1         0x2         0a:00:27:00:00:01     *        eth1
<IP_ADDRESS>         0x1         0x2         52:54:00:12:35:03     *        eth0
<IP_ADDRESS>         0x1         0x2         52:54:00:12:35:02     *        eth0

There's nothing to be gained here. These are neighbours. None of this can be resolved back to local without odd tools.
Next up, /proc/net/tcp
  sl  local_address rem_address   st tx_queue rx_queue tr tm->when retrnsmt   uid  timeout inode
   0: 0100007F:0019 00000000:0000 0A 00000000:00000000 00:00000000 00000000     0        0 15431 1 ffff88003a6657c0 100 0 0 10 0
   1: 00000000:8105 00000000:0000 0A 00000000:00000000 00:00000000 00000000   107        0 8113 1 ffff880036ebd780 100 0 0 10 0
   2: 00000000:0CEA 00000000:0000 0A 00000000:00000000 00:00000000 00000000   108        0 14803 1 ffff88003dbad100 100 0 0 10 0
   3: 0100007F:2BCB 00000000:0000 0A 00000000:00000000 00:00000000 00000000   110        0 12615 1 ffff88003d1a9040 100 0 0 10 0
   4: 0100007F:18EB 00000000:0000 0A 00000000:00000000 00:00000000 00000000   111        0 12588 1 ffff880036ebd080 100 0 0 10 0
   5: 00000000:006F 00000000:0000 0A 00000000:00000000 00:00000000 00000000     0        0 10188 1 ffff88003d1a9740 100 0 0 10 0
   6: 00000000:0050 00000000:0000 0A 00000000:00000000 00:00000000 00000000     0        0 13491 1 ffff88003dbad800 100 0 0 10 0
   7: 00000000:0016 00000000:0000 0A 00000000:00000000 00:00000000 00000000     0        0 14340 1 ffff88003da26140 100 0 0 10 0
   8: 0F02000A:0016 0202000A:C3B0 01 00000000:00000000 02:00068944 00000000     0        0 16839 4 ffff88003a6650c0 20 4 25 10 -1

local_address can be resolved to an IP address, but then you still have absolutely no idea what interface they belong to.
Let's try /proc/net/route
Iface   Destination     Gateway         Flags   RefCnt  Use     Metric  Mask            MTU     Window  IRTT
eth0    00000000        0202000A        0003    0       0       0       00000000        0       0       0
eth0    0002000A        00000000        0001    0       0       0       00FFFFFF        0       0       0
eth1    0000FEA9        00000000        0001    0       0       1000    0000FFFF        0       0       0
docker0 000011AC        00000000        0001    0       0       0       0000FFFF        0       0       0
eth1    00801CAC        00000000        0001    0       0       0       00FFFFFF        0       0       0

So now what we need to do is to take the destinations, the masks and match them up with the active connections.
Let's convert some of the data first (won't filter duplicates). And I'll even use Ruby for this :P
def hex2ipdec(input)
  input.scan(/../).map { |n| n.to_i(16) }.reverse.join('.')
end

Destination in /proc/net/route:
irb(main):005:0> hex2ipdec '00801CAC' => "<IP_ADDRESS>"
irb(main):006:0> hex2ipdec '00000000' => "<IP_ADDRESS>"
irb(main):007:0> hex2ipdec '0002000A' => "<IP_ADDRESS>"
irb(main):008:0> hex2ipdec '0000FEA9' => "<IP_ADDRESS>"
irb(main):009:0> hex2ipdec '000011AC' => "<IP_ADDRESS>"
irb(main):010:0> hex2ipdec '00801CAC' => "<IP_ADDRESS>"

Mask in /proc/net/route:
irb(main):011:0> hex2ipdec '00000000' => "<IP_ADDRESS>"
irb(main):012:0> hex2ipdec '00FFFFFF' => "<IP_ADDRESS>"
irb(main):013:0> hex2ipdec '0000FFFF' => "<IP_ADDRESS>"
irb(main):014:0> hex2ipdec '0000FFFF' => "<IP_ADDRESS>"
irb(main):015:0> hex2ipdec '00FFFFFF' => "<IP_ADDRESS>"

So far so good, looks like we can get somewhere now, right? By using these destinations and their masks we should be able to figure out which local addresses belong to which interface.
local_address in /proc/net/tcp
irb(main):016:0> hex2ipdec '0100007F' => "<IP_ADDRESS>"
irb(main):017:0> hex2ipdec '00000000' => "<IP_ADDRESS>"
irb(main):018:0> hex2ipdec '00000000' => "<IP_ADDRESS>"
irb(main):019:0> hex2ipdec '0100007F' => "<IP_ADDRESS>"
irb(main):020:0> hex2ipdec '0100007F' => "<IP_ADDRESS>"
irb(main):021:0> hex2ipdec '00000000' => "<IP_ADDRESS>"
irb(main):022:0> hex2ipdec '00000000' => "<IP_ADDRESS>"
irb(main):023:0> hex2ipdec '00000000' => "<IP_ADDRESS>"
irb(main):024:0> hex2ipdec '0F02000A' => "<IP_ADDRESS>"

Well...crap. eth1 apparently has no active connection and thus we can't figure out what its IP is. And that's the interface I'd be interested in with this particular VM.

Here's some sample data for you from one of my VMs. You're underestimating the complexity ;)

Maybe. I have to admit that I have not really tried (I still would like to do so). There is also nothing directly coming up with Google :-(

Installing ipconfig/ip is not a sustainable option, you would have to do this for every Linux flavour under the sun (and wouldn't work for Windows)

I would assume that there are not so many variants on how to install it. Also I would just start with the most common one. Also in most cases either ipconfig or ip should already be installed, right? So one would start with checking whether the binary exists in the first place.

I only did it in a separate project because it seemed the best way at the time, but the 97 lines in main.go can easily be put inside this project and compiled on Travis, as well as be pushed with every release.

So you would make the Go code part of Landrush and make a release it together with each Landrush release? How so? The release process would need build the Go binaries put them on GitHub (provided that's where you want to host them) and build the gem for upload to Rubygems, right? And would you align versions? Otherwise how do you match which binary to download w/i the Ruby code?
You are saying this can all be easily done via Travis. Would you create the setup for this?
What if I want to release locally? In this case I would need to install Golang, right? What else would I need to cross compile?
Look, I am actually quite impressed by what your 97 lines of Go can do and I get your point that you can actually build binaries for all platforms. That's nice. I just don't see the whole picture yet on how to manage this from a project point of view. This complexity you won't have if you stick to the standard Vagrant capabilities approach. IMO it is not as elegant and does potentially not cover all OS types and flavors, but it straight forward and uses a "standard" approach.

I would assume that there are not so many variants on how to install it. Also I would just start with the most common one. Also in most cases either ipconfig or ip should already be installed, right? So one would start with checking whether the binary exists in the first place.
Again, I think you underestimate it. If I look at Debian, Wheezy has ifconfig/ip in freebsd-net-tools/iproute respectively. For Jessie, both change: net-tools, iproute2. Alpine 3.2 doesn't have ifconfig, ip is in iproute2; on 3.3 you do get ifconfig. SUSE doesn't have ifconfig either, Arch does.

And that's just 4 of the open distributions, I haven't even touched on RedHat, CentOS, derivatives of the above, nor have I considered the different repositories that they might be in. Package names do tend to be net-tools and iproute(2), but you still have to do one for every distribution to use the correct package manager. Aptitude, Pacman, Yum, Apk are 4 already :P

So you would make the Go code part of Landrush and make a release it together with each Landrush release? How so? The release process would need build the Go binaries put them on GitHub (provided that's where you want to host them) and build the gem for upload to Rubygems, right? And would you align versions? Otherwise how do you match which binary to download w/i the Ruby code?

Entirely up to the maintainers. I'm happy for anyone to take my code and use it as they see fit, move the repository to someone else's ownership. It could be reduced from the 15 binaries it produces now, to only produce what Landrush needs. Considering the size of the binaries, they could even be included in the gem, although I personally think that would be a waste.
As for versioning, again depends on what the maintainers want. You could include it in this repo and simply produce a matching build for every version of Landrush. Or you could do what I did now, which is to ensure backwards compatibility.

You are saying this can all be easily done via Travis. Would you create the setup for this?

Happy to help, can also just be taken from my repository. The build steps are extremely minimal.
https://github.com/Werelds/landrush-ip/blob/master/.travis.yml -> Installs gox (go cross-building tool) and ghr (tool to push to GitHub Releases) and that's it. Go projects on Travis default to running make if a Makefile is present; otherwise it defaults to go build.
https://github.com/Werelds/landrush-ip/blob/master/Makefile -> The default build just builds all possible targets (15 of them currently; all 15 combined are about 45 megs) and if it's a tag, pushes a new release (so not every repository push gets released).

What if I want to release locally? In this case I would need to install Golang, right? What else would I need to cross compile?

Depends on how it's set up; it's currently set up to always download the binary from my repo, which means you don't need Go installed.

Look, I am actually quite impressed by what your 97 lines of Go can do and I get your point that you can actually build binaries for all platforms. That's nice. I just don't see the whole picture yet on how to manage this from a project point of view. This complexity you won't have if you stick to the standard Vagrant capabilities approach. IMO it is not as elegant and does potentially not cover all OS types and flavors, but it straight forward and uses a "standard" approach.

I only offered this as an alternative after getting in touch with @phinze at the time. And that's still what it is, an alternative way. ip is the only real alternative and that'll require covering all bases with regards to distributions and their package managers. And obviously for a Windows guest an entirely separate implementation is necessary. That's what I am trying to avoid with this binary that has a uniform API across all platforms. Instead of having to install ip if necessary, then parse its output (which is subject to which version it is too, I might add) as well as having a separate implementation for Windows, this binary works the same everywhere.

Is the solution, going forward, to have the go tool built from GitHub using TravisCI, and packaged and deployed as a Vagrant Capability plugin, so that it is trivially consumable with landrush?

Again, I think you underestimate it

After looking more into this, I think you might be right.

ip is the only real alternative and that'll require covering all bases with regards to distributions and their package managers. And obviously for a Windows guest an entirely separate implementation is necessary. That's what I am trying to avoid with this binary that has a uniform API across all platforms.

Sure, the uniformity of the solution is very appealing.

I agree that it probably would be nicer to do it without an extra binary, but both approaches have their drawbacks

Right.
For me these are the open questions right now:

Should we include this as is, aka the Landrush plugin will download the landrush-ip binary from the GitHub releases page from its current location
Or should we include the relevant Go code and build setup into the Landrush code base?

At the moment I am tempted to go for the former. If need be we can decide to integrate the GO code later.
BTW, should we really just download the latest landrush-ip version or is it not better to download a fixed version?
I really would like to resolve this asap, since I think we should get a release out. Unfortunately, I am traveling next week. I might be able to do some work on Landrush, but otherwise the week after next. Maybe we can get to an agreement on how to proceed until then, so that we can cut a 1.0.0 release.
WDYT?

I think @joshrivers may have a point, that could actually be a nice way of doing it. The code to download and run the tool can then be 100% encapsulated and the binary would follow the cap plugin's versioning. It basically means taking my landrush-ip repository, wrapping it in the structure for a capability plugin and adjusting the Travis integration to not only build the binary, but also build and publish the gem.
So we would have:

vagrant-landrush-ip (working title :P) as cap plugin
vagrant-landrush with dependency on vagrant-landrush-ip

One of the decisions to make then would be whether to include the binary in the gem or not; in my opinion, fetching it from GitHub the way I do now saves a lot of space, it's only done once and it's pretty quick. The only change necessary would be a version check to make sure the binary is updated inside a guest if the plugin is updated.
I'll try to do a PoC of this today if I have the time, should be relatively quick.

I'll try to do a PoC of this today if I have the time, should be relatively quick.

+1 Sounds like a good plan

I'll try to do a PoC of this today if I have the time, should be relatively quick.

@Werelds any updates on this? Did you have any success to get it to work as a capability plugin?

Really sorry about the lack of activity, but work has been incredibly hectic.
So no, not yet @hferentschik - will see if I can do it over the weekend.

Quick update: I think I've got the cap plugin structure sorted (sorry, as I said, I'm not a Ruby developer so there's a lot I gotta figure out how to do exactly). Now I need to adjust my fork's code to rely on this gem and these caps and test that. Standalone it works.
I'm changing the approach a bit: the binary itself is now much more minimal, it only dumps out interfaces in a plain text, JSON or YAML format. The cap plugin also just returns this data (obviously I parse the YAML and return a hash from the capability :P). The actual NIC selection, exclusion logic and such I'll do in Landrush. This way most of the real logic is still within Landrush (making it easier for contributors here to do something with the data) and it opens the cap plugin up to potentially be used in other plugins too.
I'm just not sure how to effectively test Landrush + IP yet, as I don't want to push the cap plugin until I've done a test. I think using a local path in my Gemfile might do the trick (as I do this for the cap plugin itself too), just need to test that.

Quick update: I think I've got the cap plugin structure sorted (sorry, as I said, I'm not a Ruby developer so there's a lot I gotta figure out how to do exactly). Now I need to adjust my fork's code to rely on this gem and these caps and test that. Standalone it works.

Nice. I think this turns out nice now.

I'm changing the approach a bit: the binary itself is now much more minimal, it only dumps out interfaces in a plain text, JSON or YAML format. The cap plugin also just returns this data (obviously I parse the YAML and return a hash from the capability :P). The actual NIC selection, exclusion logic and such I'll do in Landrush. This way most of the real logic is still within Landrush (making it easier for contributors here to do something with the data) and it opens the cap plugin up to potentially be used in other plugins too.

+1 Very good. I like this approach a lot.
FYI, I am working on #171 which will configure host visibility on Windows automatically, similar to OS X /etc/resolver approach.
I also have some work in progress for #189. My idea is that in case of a statically defined private network IP, we should be able to extract the IP from the Vagrant config. In this case one even does not need to run anything on the guest.
All this work together could then be a nice package for a 1.1.0 release. I am hoping to work on the issues I mentioned some time next week.

Nice!
Windows support is on my list after I put this initial version up for your review. I only wrote the caps explicitly for Linux, doing them for BSD, Windows and so on will be trivial.
I've now tested it with Landrush, adjusted my code in this PR accordingly. I've got a day off tomorrow, so before I push I want to write the documentation and some tests.

Just pushed a commit with the necessary changes, some of it probably needs to be reverted though. I had to lock rake to 0.10, it wouldn't work for me otherwise (fresh install of El Capitan, haven't set rvm up yet). Also included a simple Vagrantfile just for demo purposes for you guys.
I did my best with the actual code and tests, but I would appreciate an actual Ruby developer doing a review of my shit on both ends :p
https://github.com/Werelds/landrush-ip just for  reference.

The pull request does still contain 5 commits, are they all needed or just the last one ("This should be it.")? I am asking since I am getting merge conflicts when I am trying to pull your changes.
Can you please make sure this applies to master and potentially drop unnecessary commits? Maybe we should even just close this pull request and create a new one. WDYT?

Overall I like the approach. Let's try to get this into a shape were I can apply it cleanly onto master. I added some comments for now.

Windows support is on my list after I put this initial version up for your review. I only wrote the caps explicitly for Linux, doing them for BSD, Windows and so on will be trivial.

ok

had to lock rake to 0.10, it wouldn't work for me otherwise

odd. I can take a look at it. Not quite sure atm what you want to achieve with the changes to Rakefile.

Also included a simple Vagrantfile just for demo purposes for you guys.

Right, I guess we would somehow use this Vagrantfile as part of an integration test via the new harness using Cucumber + Aruba. Check the features directory if you are interested.

https://github.com/Werelds/landrush-ip just for reference.

got it

I'm happy to do a new PR with only the necessary changes; I just continued on the existing ones now as they contained the relevant configuration changes.
I thought about using the Vagrantfile for tests somehow, but I had no idea how that would work. Seems that is the solution.

I'm happy to do a new PR with only the necessary changes;

cool

I just continued on the existing ones now as they contained the relevant configuration changes.

sure

I thought about using the Vagrantfile for tests somehow, but I had no idea how that would work. Seems that is the solution.

I think the Cucumber framework we have now is a good fit here.

@hferentschik I've brought my fork's master up to date and created a new branch. Changes are in and the current tests work (also works with rake as normal now). I'll now see if I can add Cucumber tests before I do a new PR; I don't think it's a good idea for me to do a forced push to the branch I used here.
How do you want to proceed with expanding OS support; shall we first get the Linux implementation going fully (as that's the most common anyway)?

@hferentschik I've created the new PR at https://github.com/vagrant-landrush/landrush/pull/193 so I'll close this one as it is now defunct.

I've created the new PR at #193 so I'll close this one as it is now defunct.

Sweet. Checking the new pull request.


🐛: twitching scoll bar for PBI report in MS Edge with 1080p

Description

Reproduce

Expected behavior

Duplicate of equinor/lighthouse#391


FileNotFoundException on Emulator

here is the logcat. This only happens on emulator. Device works fine.

W/System.err: java.io.FileNotFoundException:myapp/screenshots/1580444203567.png (No such file or directory)
W/System.err:     at java.io.FileOutputStream.open0(Native Method)
W/System.err:     at java.io.FileOutputStream.open(FileOutputStream.java:287)
W/System.err:     at java.io.FileOutputStream.(FileOutputStream.java:223)
W/System.err:     at java.io.FileOutputStream.(FileOutputStream.java:171)
W/System.err:     at com.muddzdev.quickshot.QuickShot$BitmapSaver.save(QuickShot.java:245)
W/System.err:     at com.muddzdev.quickshot.QuickShot$BitmapSaver.doInBackground(QuickShot.java:315)
W/System.err:     at com.muddzdev.quickshot.QuickShot$BitmapSaver.doInBackground(QuickShot.java:214)
W/System.err:     at android.os.AsyncTask$2.call(AsyncTask.java:333)
W/System.err:     at java.util.concurrent.FutureTask.run(FutureTask.java:266)
W/System.err:     at android.os.AsyncTask$SerialExecutor$1.run(AsyncTask.java:245)
W/System.err:     at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1162)
W/System.err:     at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:636)
W/System.err:     at java.lang.Thread.run(Thread.java:764)

minSdkVersion 23
targetSdkVersion 29
Emulator version: 8.1.0
& Here is the code
        QuickShot
                .of(ssView)
                .setPath(filepath)     //  Path defaults to /Pictures in the public storage.
//                        .setFilename(filename)              //  Filename defaults to a timestamp.
                .toPNG()                            //  Image format defaults to .JPG
                .setResultListener(new QuickShot.QuickShotListener() {
                    @Override
                    public void onQuickShotSuccess(String path) {
                        Log.d(TAG, path);
                        shareOnWhatsApp(path);
                    }

                    @Override
                    public void onQuickShotFailed() {
                        Toast.makeText(mContext, "Sorry, Failed to save screenshot.", Toast.LENGTH_SHORT).show();
                    }
                })
                .save();

Have you set your path to myapp/screenshots/1580444203567.png
Post the actual path and filename

Yes, File name is commented so it takes default. But the path is correct.
String filepath = "myapp/screenshots";

@AbhinayMe I will take a look at it with the same configuration and emulator.

The solution to your problem is to specificy the full path in the device storage:
String filepath = Environment.getExternalStorageDirectory() + File.separator + "myapp/screenshots";
Here we are saving to the public storage. In QuickShot the client of the library is fully responsible for the full path.

Here we are saving to the public storage. In QuickShot the client of the library is fully responsible for the full path. - it seems like this isn't true.
I'm having to implement conditional behavior based on API level because on Q quickshot prepend /Pictures to any path I provide it.

@athornz I will take a look at it.

I feel like the library shouldn't have any special handling of the storage path if the user specifies one. Or alternatively have a setAbsolutePath and setRelativePath method where the user can choose.
I'd like to be able to pass in an absolute path and have that path returned in the callback of the saved screenshot.

@athornz
The library checks if the app is Android Q or below and handles the saving process differently due to Android's new Scooped Storage system.
If you app is Android Q or above, it will use this method and the root path must alwasy be ./Pictures (Environment.DIRECTORY_PICTURES) when you save images to the public storage space. Else you will get an error.  That is why any path always will be relative to ./Pictures
Anything below Android Q is does not follow this rule and you are free to use any path
If no path is specified then QuickShot will always default to ./Pictures regardless of API level or filename


Further improved serializer registration

:white_check_mark: Build ExtendedXmlSerializer <IP_ADDRESS>-uwguyuxq completed (commit https://github.com/ExtendedXmlSerializer/home/commit/8b4f9d471a by @Mike-EEE)
Install it by running the following command in Package Manager Console:
Install-Package ExtendedXmlSerializer -Version <IP_ADDRESS>-uwguyuxq -Source https://ci.appveyor.com/nuget/extendedxmlserializer-preview


Download fontawesome files to serve locally

Avoids using a CDN that tries to using tracking cookies, and also lets us use font-url (which the npm package doesn't do, causing it to break in production).

@SMores, can you say more about the font-url problem? Is this a known issue with the npm package?

Sure, sorry I missed this! When you precompile rails assets, the pipeline renames them, appending a hash code to the filename, as a cache-busting mechanism. The node module isn't specifically built to work with the rails asset pipeline, so the CSS looks for the font files by their statically defined filename, which doesn't include the hash code. The solution to this, in rails land, is the font-url, which is rails asset-pipeline-aware, and can update the URL in the CSS at compile-time to have the newly compiled font file names.


Gauge keeps trembling after setting the speed to zero

Hi,
thanks for the nice work with the SpeedView
why the gauge keeps trembling after setting the speed to zero? since its not receiving speedTo calls anymore.
I even call stop() and clearAnimation() after speedTo(0.0f)
thanks in advance

just stop Tremble by app:sv_withTremble="false" Attribute.
or in code: speedometer.setWithTremble(false); #9 #28


IFUS Camera seems bricked

Hello,
My camera was OFF since a few weeks.
I have 0.2.2 yi-hack installed on it and it was working great.
My camera was having the IFUS 9.0.36 so it must a y211ga
I have power on the camera today and it's sticked on yellow led...
reset button have no action.
I have follow the unbrick readme for my camera : https://github.com/roleoroleo/yi-hack-Allwinner-v2/tree/master/unbrick
❯ cp -vf ~/yi_hack/backup/mtd*.bin y211ga
'/home/pi/yi_hack/backup/mtdblock0.bin' -> 'y211ga/mtdblock0.bin'
'/home/pi/yi_hack/backup/mtdblock1.bin' -> 'y211ga/mtdblock1.bin'
'/home/pi/yi_hack/backup/mtdblock2.bin' -> 'y211ga/mtdblock2.bin'
'/home/pi/yi_hack/backup/mtdblock3.bin' -> 'y211ga/mtdblock3.bin'
'/home/pi/yi_hack/backup/mtdblock4.bin' -> 'y211ga/mtdblock4.bin'
'/home/pi/yi_hack/backup/mtdblock5.bin' -> 'y211ga/mtdblock5.bin'
'/home/pi/yi_hack/backup/mtdblock6.bin' -> 'y211ga/mtdblock6.bin'
'/home/pi/yi_hack/backup/mtdblock7.bin' -> 'y211ga/mtdblock7.bin'

❯ ./build.sh factory
Image Name:   xiaoyi-rootfs
Created:      Thu Aug  4 19:37:12 2022
Image Type:   ARM Linux Filesystem Image (uncompressed)
Data Size:    1179648 Bytes = 1152.00 KiB = 1.12 MiB
Load Address: 00000000
Entry Point:  00000000
Image Name:   xiaoyi-home
Created:      Thu Aug  4 19:37:12 2022
Image Type:   ARM Linux Filesystem Image (uncompressed)
Data Size:    3407872 Bytes = 3328.00 KiB = 3.25 MiB
Load Address: 00000000
Entry Point:  00000000
Image Name:   xiaoyi-backup
Created:      Thu Aug  4 19:37:12 2022
Image Type:   ARM Linux Filesystem Image (uncompressed)
Data Size:    1245184 Bytes = 1216.00 KiB = 1.19 MiB
Load Address: 00000000
Entry Point:  00000000

❯ cd y211ga
❯ gunzip *.gz
❯ ls home_y211ga backup_y211ga rootfs_y211ga -la
-rw-r--r-- 1 pi pi 1245248 Aug  4 19:37 backup_y211ga
-rw-r--r-- 1 pi pi 3407936 Aug  4 19:37 home_y211ga
-rw-r--r-- 1 pi pi 1179712 Aug  4 19:37 rootfs_y211ga

❯

I put the file one by one on the SD card, the yellow led blink one time and I wait 10min. So i made this 3 times, one time per file.

backup
home
rootfs

The camera still does not boot. Now when i try to put the file again and reboot, there is no more blink of the LED.
Is there any other solution ?
Soldering and burning backup via serial may help ?
Thanks !

So i have solder some cables and restore de the backup file. on reboot now i have this :
[174]HELLO! BOOT0 is starting Nov 14 2019 20:01:31!
[179]BOOT0 commit : 81c18ee
[182]board init start
[184]set pll start
[187]set pll end
[189][pmu]: bus read error
[191]board init ok
[193]chip id check OK
[195]DRAM BOOT DRIVE INFO: V0.41
[198]DRAM CLK = 528 MHz
[201]DRAM Type = 2 (2:DDR2,3:DDR3)
[204]DRAMC read ODT  off.
[207]DRAM ODT off.
[209]DRAM SIZE =64 M
[216]DRAM simple test OK.
[218]rtc standby flag is 0x0, super standby flag is 0x0
[224]dram size =64
[226]spinor id is: c8 40 17, read cmd: 03
[230]Succeed in reading toc file head.
[234]The size of toc is 4c000.
[287]Entry_name        = optee
[290]Entry_name        = u-boot
[294]Entry_name        = dtb
[297]Jump to secend Boot.
MESSAGE: [0x0] TEE-CORE: OP-TEE version: sun8iw19p1_v0.6.0-12-g97f2688 #1 2019年 11月 08日 星期五 08:26:51 UTC arm
ERROR:   [0x0] TEE-CORE:platform_standby_fdt_parse:126: no pmu node
ERROR:   [0x0] TEE-CORE:sunxi_twi_parse_from_dt:84: no pmu node

U-Boot 2018.05-00015-g8fe585e (Nov 10 2020 - 16:09:41 +0800) Allwinner Technology

[00.343]DRAM:  64 MiB
[00.345]Relocation Offset is: f9f94000
[00.357]secure enable bit: 0
[00.359]CPU=816 MHz,PLL6=600 Mhz,AHB=200 Mhz, APB1=100Mhz  MBus=132Mhz
[00.365]gic: sec monitor mode
[00.368]flash init start
[00.370]workmode = 0,storage type = 3
SF: Detected gd25q64 with page size 256 Bytes, erase size 4 KiB, total 8 MiB
[00.387]sunxi flash init ok
[00.390]Loading Environment from SUNXI_FLASH... start: 0x2e0, len: 0x1
start: 0x2e1, len: 0x1
start: 0x2e2, len: 0x2
start: 0x2e0, len: 0x1
start: 0x2e1, len: 0x1
start: 0x2e2, len: 0x2
start: 0x2e0, len: 0x1
start: 0x2e1, len: 0x1
start: 0x2e2, len: 0x2
start: 0x2e0, len: 0x1
start: 0x2e1, len: 0x1
start: 0x2e2, len: 0x2
start: 0x2e0, len: 0x1
start: 0x2e1, len: 0x1
start: 0x2e2, len: 0x2
start: 0x3e00, len: 0x100
OK
[00.451]try sprite_led_gpio config
xxxxxxxxxxxxxxlijun uboot xiaoyiledinit
[00.458]sprite_led_gpio start
[00.462](weak)update dtb dram start
[00.466]update dtb dram  end
[00.468]update dts
root_partition is rootfs
start: 0x2e0, len: 0x1
start: 0x2e1, len: 0x1
start: 0x2e2, len: 0x2
start: 0x2e0, len: 0x1
start: 0x2e1, len: 0x1
start: 0x2e2, len: 0x2
start: 0x2e0, len: 0x1
start: 0x2e1, len: 0x1
start: 0x2e2, len: 0x2
start: 0x2e0, len: 0x1
start: 0x2e1, len: 0x1
start: 0x2e2, len: 0x2
start: 0x2e0, len: 0x1
start: 0x2e1, len: 0x1
start: 0x2e2, len: 0x2
start: 0x2e0, len: 0x1
start: 0x2e1, len: 0x1
start: 0x2e2, len: 0x2
start: 0x2e0, len: 0x1
start: 0x2e1, len: 0x1
start: 0x2e2, len: 0x2
start: 0x2e0, len: 0x1
start: 0x2e1, len: 0x1
start: 0x2e2, len: 0x2
start: 0x2e0, len: 0x1
start: 0x2e1, len: 0x1
start: 0x2e2, len: 0x2
set root to /dev/mtdblock2
[00.531]update part info
[00.533]update bootcmd
mmc driver ver uboot2018:2019-8-15 16:34:00
get mem for descripter OK !
[00.546]get sdc_wipe fail.
[00.548]get sdc0 sdc_erase fail.
[00.551]get sdc0 sdc_boot fail.
[00.554]get sdc0 sdc_odly_50M fail.
[00.557]get sdc0 sdc_sdly_50M fail.
[00.560]get sdc0 sdc_odly_50M_ddr fail.
[00.564]get sdc0 sdc_sdly_50M_ddr fail.
[00.567]get sdc0 sdc_freq fail.
[00.570]get sdc0 sdc_b0p fail.
[00.573]get card0_boot_para:sdc_ex_dly_used fail
[00.578]get card-pwr-gpios handler:1119307304
[00.582]get card0_boot_para:time_pwroff:200ms
[00.588]Using default timing para
[00.791]init mmc 0 clock and io
devnum 0, prv 43fbd440, bdesc 42b7476c
SUNXI SD/MMC: 0
[00.798]==================== work mode: 0 0, sample_mode:0
[00.803]=============== start mmc_init_boot...
card_caps:0x3000000a
host_caps:0x3000003f
[00.957]unable to read ssr
[00.960]unable to read ssr
[00.964]the mode SD Legacy (freq : 25 MHz)
** Unrecognized filesystem type **
check_file [/one_y211ga.bin] exsit
check_file [/one_y211ga.bin] exsit
start: 0x2e0, len: 0x1
start: 0x2e1, len: 0x1
start: 0x2e2, len: 0x2
part_name:boot start_offset:0x20 part_size:1900544
start: 0x2e0, len: 0x1
start: 0x2e1, len: 0x1
start: 0x2e2, len: 0x2
part_name:rootfs start_offset:0xea0 part_size:1179648
start: 0x2e0, len: 0x1
start: 0x2e1, len: 0x1
start: 0x2e2, len: 0x2
part_name:home start_offset:0x17a0 part_size:3407872
start: 0x2e0, len: 0x1
start: 0x2e1, len: 0x1
start: 0x2e2, len: 0x2
part_name:backup start_offset:0x31a0 part_size:1245184
start: 0x2e0, len: 0x1
start: 0x2e1, len: 0x1
start: 0x2e2, len: 0x2
part_name:env start_offset:0x3b20 part_size:131072
Nothing updated, start normal boot
Hit any key to stop autoboot:  1 �����C�w���

yellow fix led.
if i enter and then enter reset i have a yi hack loaded. but yello led blinking and no ping.
I have used the RESET button too, avec the reset command. it seems have broken something

More logs when boot after the reset command :
============================================= begin to start app... =========================================

dispatch.c(get_productinfo-1620)[00:00:49.563]:get system did info: did[IFUSY65HT06P25201207], key[Fs8PtPu76vvWz0Os], key_mi[FFFFFFFFFFFFFFFF], p2pid[TNPUSAM-500212-BHMXP], did_mi[00000000]

dispatch.c(sync_did_to_backup_region-1440)[00:00:49.569]:Backup DID info is right

dispatch.c(get_productinfo-1688)[00:00:49.569]:hardware version is invalid, need to be restored from backup data!

dispatch.c(get_productinfo-1697)[00:00:49.575]:Gpio infor is invalid, need to be restored from backup data!

[    7.412797] cpld_periph: loading out-of-tree module taints kernel.
[    7.420370]

I have setup wifi via this link : https://github.com/roleoroleo/yi-hack-Allwinner-v2/wiki/Change-WiFi-credentials
ps i does not work, i had to run startup.sh manually via serial.
On (auto) reboot camera works.
on power off/power on, camera stay on fix yellow led. autoboot seems not working. is there a way to reenable it ?

Issue was the power : https://github.com/roleoroleo/yi-hack-Allwinner-v2/issues/103


redis cache

Fixes #19542

@mohsinnasir  using an Azure Redis cache for dev is probably pretty expensive. You don't want to use the same instance as the production cache.

@Rick-Anderson I totally agree that using azure cache for redis for development is pretty expensive plus its response time would also be slow as it ill be over wan while doing development on local machine. However, there should be an emulator for azure cache for redis like CosmosDb or MongoDB

@Rick-Anderson Changes looks fine to me


Only import CSQLite module when building with CocoaPods

Issue #492 re-appeared so I made the change in db8f39b which was done in PR #502 again to fix it.
I'm using Xcode 8.2.1 and my Xcode app is placed in /Applications/Xcode.app. I only have one Xcode app installed.

dup of #615

I strongly believe that #615 > #597 :) But thank you anyway @jberkel

@ceyhuno @yusufseyrek this is merged now, I'll soon push 0.11.3 if you want to use a released version.


Importing blob files

I am attempting to replace a zip file in socrata.  This file may be generated on a nightly basis.  The Google Transit Feed System file format has a number of csv files of different schemas, so it doesn't make sense for a direct CSV upsert.
Safe FME has provided a method for pushing blob files to Socrata.  It seems to hit the not-so-documented api end point of POST https://data.texas.gov/api/imports2?method=blob&fileUploaderfile=['C:', 'myfile.zip'] with the usual header files.
I was thinking about providing a PR that incorporates this functionality in sodapy.  Do you think it would make sense to put a blob parameter in replace and upsert.  If blob is true, then use the endpoint above to push the file?
I was curious if there is a reason why api/imports2 is not used and if there are potentially other methods.

imports2 seems to be fully supported by Socrata. At least in their soda-java.  https://github.com/socrata/soda-java/blob/master/src/main/java/com/socrata/api/SodaImporter.java#L33

Yea, that's be rad if you want to add a file upload endpoint! Here is the backstory on the import2 api if you're interested.

Hey guys, I just had a good chat with @PeterAustinMoore from Socrata yesterday. Apparently the imports2 endpoint is the way forward. It's old, as @chrismetcalf pointed out, but the code behind it has been updated and it's what will likely be supported. An important caveat: it's not officially supported, and only used internally at this point, so use at your own risk!
He walked me through some sample code that you could construct by walking through the "create geospatial dataset" wizard on the web interface. It basically uploads a file as the first call, which returns a file id. You then make another request using that file ID to turn it into a dataset and import its data as rows. This request returns the /api/views/xxxx-xxxx.json response that we've seen before.
For geospatial data, the /api/views/... response contains a childViews property. It's an array of the shapefile layers that were imported. Those layers are the actual data, and what you'd want to connect datasync or something else to. Alternatively, you can use the replace methods on the imports2 endpoint.
It sounds like this is the intended creation process for any dataset, whether tabular, geospatial, or blobular. I just made up the word blobular but I'm going to stick with it. There's a method querystring (I believe that's what it is) that has a few options.
Sounds like it's worth touching up the overall create() method of this library, though it's definitely a breaking change, as it requires a file to use it. Any thoughts so far or info you guys know that I don't?

Thanks for the thoughts @timwis.  Great to know that imports2 won't disappear at some point.  I think you generally covered what I added with https://github.com/xmunoz/sodapy/pull/17.  My goal was not to support shapefile imports though, just non-row based data.  They sound like similar processes.

I'm afraid that refactoring up the existing create might be squeezing too much distinct functionality into one method. I support the creation of an additional create method to upload and publish file-based datasets. I probably won't roll a new version of sodapy until the new create can handle geospatial data as well, but I'm mostly happy with the functionality of the current PR as-is.

Opening a new issue for shapefiles.   This is not a pressing need for me at this point.  Maybe someone else could pick it up.

Hey all, jumping in late to the discussion, but let me know if you need help. It looks like we're going to officially expose the imports2 API to learn more about how people will use it while we design 3.0, so let me know if you have feedback or questions! :tada:

@chrismetcalf expose as in document? :D :D

@timwis Correct! No guarantees that everything on your wishlist will be in there, but at least it'll be something to start a discussion around


slack: 4.2.0 -> 4.3.3, add Darwin target

Motivation for this change
This PR adds Darwin as a target for slack and bumps the version from 4.2.0 to 4.3.3.
For the Darwin target, we have to use hdiutil to mount the dmg and copy the app bundle from there. Using undmg or xpwn to extract the app from the dmg unfortunately yields corrupted binaries.
Things done

[x] Tested using sandboxing (nix.useSandbox on NixOS, or option sandbox in nix.conf on non-NixOS linux)
Built on platform(s)

[x] NixOS
[x] macOS
[ ] other Linux distributions

[ ] Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
[ ] Tested compilation of all pkgs that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review wip"
[x] Tested execution of all binary files (usually in ./result/bin/)
[ ] Determined the impact on package closure size (by running nix path-info -S before and after)
[ ] Ensured that relevant documentation is up to date
[x] Fits CONTRIBUTING.md.

Looks like 4.3.3 is not out yet?
curl: (22) The requested URL returned error: 403
error: cannot download slack-desktop-4.3.3-amd64.deb from any mirror

@mmahut you're correct, it's not available for Linux yet, sorry about that. I've downgraded back to 4.2.0.
On a separate note, is there a policy on having multiple versions for different platforms within the same package? Is it considered good/bad practice?

Having both in the same file is considered good practice. There is not much code sharing but at least the metadata is the same.

@Mic92 but which is better, preferring to keep the same version between two different platforms or offering a more recent version for the other platform when one is available? I'm worried about breaking expressions and tooling that depend on the version field, assuming that the package has a single canonical version (example: package search results).

@earksiinni if the delay between the two is acceptable we could keep one version. Otherwise they could diverge as well.


Threshold error message correction

Thanks for the fixes

When can u release this plugin?

I am quite busy for the moment, and the process of releasing a plugin in Grafana is time consuming. (https://grafana.com/docs/grafana/latest/developers/plugins/package-a-plugin/)
If you have time to do it and interested in doing it, I can invite you to this repository and you can do everything by yourself.
Cheers,

Yes please send me the invite and i will help release the plugin


fix ipad retina table width issue

I had issue on iPad retina where table header was not aligned (had same width) with table.

Reason for that was difference between table sizing columns and table width itself (from calculation).

Table sizing cols had fractions, but for table width calculation offsetWidth was used and it  always return integers.
Switching from .offsetWidth to  getOffsetWidth() for table width calculation solved problem.
getOffsetWidth() is using getBoundingClientRect() which return width with fractions.

thanks!


OnTouch event handling while menu is scrollable

Hi,
I want to express my appreciate of your work, this is really amazing project.
Issue description
I'm using a sliding-down menu(a menu located at the top of the screen) as the following screen indicates - the red area is the menu, the orange area is the main-body of the layout. The sliding menu contains a ListView. You can find two screen shots at the end.
Now the current situation is

if a gesture is regarded as a fling, the SlidingUpPanelLayout would intercept the events without negotiating with child ListView
If a gesture is regarded as a scroll, the red ListView could receive the events in onTouchEvent.

My requirement is

as long as the Red ListView is not having scrolled to the bottom, all the onTouch event should be handled by the red ListView.
When the list is at the bottom,

All the scrolling-up/fling-up gesture should be handled by the SlidingUpPanelLayout(because the listView is already at its bottom-most)
Otherwise, the ListView handles. it.

Up menu collapsed:

Up menu expanded:

Thank you in advance.

Update:
I was wrong about the onFling & onScroll.
It is the ViewDragHelper::checkTouchSlop determines who to handle the onTouch event. When it's scrolled very slow, the checkTouchSlop method would regard it as a "touch slop" and will NOT intercept the event, so that the ListView will have the opportunity to scroll. When the scrolling is relatively fast, it will intercept the touch event.

Work in progress. Dupe of https://github.com/umano/AndroidSlidingUpPanel/issues/116


OSM Plugin UI Theme

I just want to know that this plugin support for Dark Mode UI Map, or anyother theme to control light mode , dark mode ?

you can use tile dark mode its better


[Question] How to add new themes?

I want to add SynthWave theme, but I'm unable to get where and how I could add.
Can I add the design only or I've to add code as well?

Hello, I just sent a PR #13  but not if the theme was like SynthWave


setcmdline(): ability to set the command line contents

Is your feature request about something that is currently impossible or hard to do? Please describe the problem.
I would like to be able to set the contents of the command line from Vim script.
Describe the solution you'd like
I would like a setcmdline function, the partner of the already-existing setcmdline function.
Describe alternatives you've considered
You can approximate this by using feedkeys, but that has many downsides. It is hacky, and it is asynchronous (the keys don't get processed immediately from Vim script).

This was implemented in 07ea5f150.


Document Windows secrets support

Problem description
Document https://github.com/moby/moby/pull/32208
Project version(s) affected
Docker 17.06

Closed via #3494


BUGFIX: thumnail is not updated if generated and set by user after so…

Pull request checklist

[x] All tests pass. Demo project builds and runs.
[x] I have resolved any merge conflicts.
[x] I have followed the coding style, and reviewed the contributing guidelines. Confirmation: ____

This fixes issue
Using in my project video thumbnails, but we have our own mech for generating them. So found out that when update VideoMediaItem with my thumbnail image after some time, it has no effect in chat.
What's in this pull request?
…mewhile

Hello everyone!
I'm sorry to inform the community that I'm officially deprecating this project. 😢 Please read my blog post for details:
http://www.jessesquires.com/blog/officially-deprecating-jsqmessagesviewcontroller/
Thus, I'm closing all issues and pull requests and making the necessary updates to formally deprecate the library. I'm sorry if this is unexpected or disappointing. Please know that this was an extremely difficult decision to make. I'd like to thank everyone here for contributing and making this project so great. It was a fun 4 years. 😊
Thanks for understanding,
— jsq


Revoke Installation

Closes #21

Looks like a good start!
I think the key type makes sense. I think there may be some missed opportunities to add test coverage here too.

yeah definitely still missing tests!


pytorch_lightning.utilities.exceptions.MisconfigurationException:                  You requested GPUs: [0]                 But your machine only has: [

Thank you for sharing the code, it is really neat and helpful. But when i run it, i meet thi error
python main.py
Using backend: pytorch
LOADING dialogre dataset
LOADING dialogre dataset for conversation setting
Finetune all word embeddings
DGL backend not selected or invalid.  Assuming PyTorch for now.
Setting the default backend to "pytorch". You can change it in the ~/.dgl/config.json file or export the DGLBACKEND environment variable.  Valid options are: pytorch, mxnet, tensorflow (all lowercase)
Using backend: pytorch
2020-11-22 04:06:31.661428: I tensorflow/stream_executor/platform/default/dso_loader.cc:48] Successfully opened dynamic library libcudart.so.10.1
/usr/local/lib/python3.6/dist-packages/spacy/util.py:275: UserWarning: [W031] Model 'en_core_web_sm' (2.2.5) requires spaCy v2.2 and is incompatible with the current spaCy version (2.3.2). This may lead to unexpected results or runtime errors. To resolve this, download a newer compatible model or retrain your custom model with the current spaCy version. For more details and available updates, run: python -m spacy validate
warnings.warn(warn_msg)
LOADING dialogre dataset
LOADING dialogre dataset for conversation setting
Finetune all word embeddings
Traceback (most recent call last):
File "main.py", line 65, in
trainer = Trainer(**trainer_args, resume_from_checkpoint=config.ckpt_path if config.ckpt_path else None)
File "/usr/local/lib/python3.6/dist-packages/pytorch_lightning/trainer/trainer.py", line 511, in init
self.data_parallel_device_ids = _parse_gpu_ids(self.gpus)
File "/usr/local/lib/python3.6/dist-packages/pytorch_lightning/trainer/distrib_parts.py", line 361, in _parse_gpu_ids
gpus = sanitize_gpu_ids(gpus)
File "/usr/local/lib/python3.6/dist-packages/pytorch_lightning/trainer/distrib_parts.py", line 320, in sanitize_gpu_ids
""")
pytorch_lightning.utilities.exceptions.MisconfigurationException:
You requested GPUs: [0]
But your machine only has: []
I'm newbie in cuda , when i run nvidia-smi  i met this error
nvidia-smi
+-----------------------------------------------------------------------------+
| NVIDIA-SMI 455.38       Driver Version: 418.67       CUDA Version: 10.1     |
|-------------------------------+----------------------+----------------------+
| GPU  Name        Persistence-M| Bus-Id        Disp.A | Volatile Uncorr. ECC |
| Fan  Temp  Perf  Pwr:Usage/Cap|         Memory-Usage | GPU-Util  Compute M. |
|                               |                      |               MIG M. |
|===============================+======================+======================|
|   0  Tesla T4            Off  | 00000000:00:04.0 Off |                    0 |
| N/A   53C    P8    10W /  70W |      0MiB / 15079MiB |      0%      Default |
|                               |                      |                 ERR! |
+-------------------------------+----------------------+----------------------+
+-----------------------------------------------------------------------------+
| Processes:                                                                  |
|  GPU   GI   CI        PID   Type   Process name                  GPU Memory |
|        ID   ID                                                   Usage      |
|=============================================================================|
|  No running processes found                                                 |
+-----------------------------------------------------------------------------+

Hi Thank you for asking.
It looks like you cuda driver is not working. You will need cuda driver to run pytorch with gpu. To install cuda driver, you can follow below for convenience:

Start terminal and remove any NVIDIA traces you may have on your machine.

sudo rm /etc/apt/sources.list.d/cuda*
sudo apt remove --autoremove nvidia-cuda-toolkit
sudo apt remove --autoremove nvidia-*

Install CUDA 10.1 follow the nvidia official website:
https://developer.nvidia.com/cuda-10.1-download-archive-base

You can use nvidia-smi to verify installation.

Hi Thank you for asking.
It looks like you cuda driver is not working. You will need cuda driver to run pytorch with gpu. To install cuda driver, you can follow below for convenience:
1. Start terminal and remove any NVIDIA traces you may have on your machine.

sudo rm /etc/apt/sources.list.d/cuda*
sudo apt remove --autoremove nvidia-cuda-toolkit
sudo apt remove --autoremove nvidia-*

1. Install CUDA 10.1 follow the nvidia official website:
   https://developer.nvidia.com/cuda-10.1-download-archive-base

You can use nvidia-smi to verify installation.

Thank you for answer,
When i run
nvidia-smi
+-----------------------------------------------------------------------------+
| NVIDIA-SMI 455.38 Driver Version: 418.67 CUDA Version: 10.1 |
|-------------------------------+----------------------+----------------------+
| GPU Name Persistence-M| Bus-Id Disp.A | Volatile Uncorr. ECC |
| Fan Temp Perf Pwr:Usage/Cap| Memory-Usage | GPU-Util Compute M. |
| | | MIG M. |
|===============================+======================+======================|
| 0 Tesla T4 Off | 00000000:00:04.0 Off | 0 |
| N/A 53C P8 10W / 70W | 0MiB / 15079MiB | 0% Default |
| | | ERR! |
+-------------------------------+----------------------+----------------------+
+-----------------------------------------------------------------------------+
| Processes: |
| GPU GI CI PID Type Process name GPU Memory |
| ID ID Usage |
|=============================================================================|
| No running processes found |
+-----------------------------------------------------------------------------+
nvcc --version
nvcc: NVIDIA (R) Cuda compiler driver
Copyright (c) 2005-2019 NVIDIA Corporation
Built on Sun_Jul_28_19:07:16_PDT_2019
Cuda compilation tools, release 10.1, V10.1.243
i installed pip install --pre dgl-cu101
Now, when i run python main.py; It's seem be a problem with my DGL backend
DGL backend not selected or invalid.  Assuming PyTorch for now.
Setting the default backend to "pytorch". You can change it in the ~/.dgl/config.json file or export the DGLBACKEND environment variable.  Valid options are: pytorch, mxnet, tensorflow (all lowercase)
Using backend: pytorch.
.....

when i run
import torch
print(torch.cuda.device_count())
it return 0

torch.cuda.device_count() = 0 means you are still not able to use gpu on pytorch. You can refer to my comment above for cuda reinstallation.

i reinstalled it, and it can run <3 Thank you


Atom.Object.defineProperty.get is deprecated.

atom.services is no longer available. To register service providers and
consumers, use the providedServices and consumedServices fields in
your package's package.json.
Atom.Object.defineProperty.get (/usr/share/atom/resources/app/src/atom.js:64:11)
ProviderManager.module.exports.ProviderManager.consumeApi (/home/adham/.atom/packages/autocomplete-plus/lib/provider-manager.coffee:110:28)

This is fixed. Please update. Duplicate of #234, #229.


Go: able to config logging to file system as well as blob storage

Need to implement something similar to "nodejs interceptor" for Go

@shrimpy I'm Dominic from this SO question
So would that be something I could contribute for Kudu, instead of handling my own logging for Go app in Azure?  Where is this "nodejs interceptor", maybe that could give me a basic idea of what's required.
Do you think this task is small enough for a first contribution?

@dstpierre thanks for your offering to contribute.
RE: Do you think this task is small enough for a first contribution?
[shrimpy] it is hard to say how difficult the task will be, and i haven`t done any further investigation.
Different technologies need to be handled differently. We have rich support for .net tracing, where trace can go to FileSystem/Blob/Table storage, and for NodeJS we only support FileSystem via a customer version of interceptor i believe.
For Go, the challenge is to find out is how to redirect standard output, which would be very different from what was done for .net and nodejs. So there is not much to reference.
 The easy approach we might just bring in an opensource library to do that with come customization.

Well I would personally not use any external Library, the log package seems to be enough [well for my own usage]. Since we can change its output to be a file, it might be enough as a starting point. Couple of question if I may?

So is it Kudu that is responsible to start the process for HttpPlatformHandler? From what I was thinking Azure was kind of grabbing the stdout / stderr of the running process and was itself writing to files in LogFiles/Application directory and this is what get tail when using azure site log tail sitename.  Did not thought it was handle differently for different technologies.

Might be basic question but are the Go app azureapp.exe that gets build after a git push do have write access to LogFiles/Application than?  Because in that case I would just write the clean-up code to make sure log files are rolling over just like the custom Node interceptor. Is the tail command simply listen to file changes in LogFiles/Application and writes them to console?

For now my needs are very basic, and similar feature to what I had with Node would be enough for now, so without rewriting anything from my app, which already use the Go core log package, I think I might just pipe the output to files in the LogFiles/Application and create a simple package that takes care of cleaning those files.
If the azureapp.exe do not have write access, than, if my question 1. is positive and Kudu do start the process, than it might have a way to grab stdout / stderr from there and write into the log files. But I've read your documentation yesterday and it seems Kudu have the same permissions than the web app itself.
If you can confirm that I'm in the right direction assuming that once there would be file written in LogFiles/Application they will get tail by the azure CLI, than I can maybe write a small package that could eventually be able to write to Blob, I'm already using azure-sdk-for-go which works nicely for Blob.
Also what about multiple app instance, are the LogFiles/Application shared across all app instance, we current have 2 and will soon scale to 3 instance, does that have any impact on log files?
Thanks for your time

Kudu is not in the picture for HttpPlatformHandler, not is it responsible for writing to LogFiles/Application. Kudu does consume the content of this folder for log streaming, but something else at runtime needs to write to it. Yes, that folder is writable to you.
Try the following fun test which will help understand things:

Run azure site log tail sitename
In Kudu Console, go to D:\home\LogFiles\Application
Run touch foo.txt to create an empty file, and click the edit button next to it
Write some text in there and hit Ctrl-S. Each time you save, you should see the new content being display by the tail command.

Yes, all instances share the same LogFiles/Application. Recommendation is to use the first 6 characters of %WEBSITE_INSTANCE_ID% as part of your log file name to help differentiate. The streaming will include all files in that folder, regardless of their name.
Does this help?

You do raise a good point about how this could be automatic if the stdout/stderr of HttpPlatformHandler was automatically written there. I think it's a worthwhile idea to consider (/cc @ranjith-r).

Per http://www.iis.net/learn/extensions/httpplatformhandler/httpplatformhandler-configuration-reference, HttpPlatformHandler already has support for this via stdoutLogEnabled / stdoutLogFile. However, in my initial testing, I could not make it work reliably. It seems out the output gets buffered and is not written to the file until I touch web.config, which doesn't make sense...

David and I tried playing around with HttpPlatformHandler, seems like stdoutLogEnabled / stdoutLogFile works in a strange way, where standard output did write to log file, but file metadata (file size, modify date) doesn`t always change (/cc @ranjith-r).
The above issue will cause "LogStream" feature not working properly. As for actual logging, you can reference custom web.config from below repository. And you will need to manual download the file to see the log as for now.
https://github.com/shrimpy/HelloGoApp

thank you @davidebbo @shrimpy this all got more clear for me suddenly, the stdoutLogEnabled / stdoutLogFile is promising though, but for immediate debugging need I think I will just directly write into the LogFiles/Application.
Unless you think the stability of the HttpPlatformHandler stdout capturing could be something that can improved in a somewhat not far future?

@dstpierre i would suggest you to directly write output to LogFIles/Application for now.  (LogFIles/Application folder is not there by default, make sure you have code to create folder if not existed)

will do, might even wrap it into a Go Azure log package and share it than, since I need to write it for our SaaS. Thanks again for your time, appreciate it.

I came up with an alternate (temporary) solution that works with the current platform handler. See https://github.com/davidebbo-test/ConsoleInterceptor for details.

Hi
Kudu will continue to run in Azure App Service. However, this repo will no longer be maintained.
If the problem persists and is related to running on Azure App Service, please open a support incident in Azure:
https://learn.microsoft.com/en-us/azure/azure-portal/supportability/how-to-create-azure-support-request
This way we can better track and assist you on this case
Thanks,
Joaquin Vano
Azure App Service


Logging Feature

This is what I have so far thanks
Issue: #5

this is a good start. I love the use of rotatingfilehandler. maybe you could add some actual logging in the bot as well? it'd be useful to log whenever we load in a cog, and the new userinfo thing cog we merged earlier could probably use a few log events.

Excellent! I'm gonna merge this.


My submersible is fully closed. I set fill ratio to 1. Why won't the boat sink?

Behold, the rantings of a confused minecrafter:
I am using Davinci's Vessels V1.12-6.340 and moving world V1.12-6.342 on a server with a couple other mods. Minecraft 1.12.2, forge <IP_ADDRESS>05.
I have made a fully enclosed block of nearly solid iron, and it didn't sink. I made it hollow, and it still didn't sink. I messed around with the fill ratio, setting it to 0, .3, 1, and .9, and none of these options made the vessel sink, I checked my ascend/descend keybinds with airships, and they worked. Enable submersibles is set to true. What am I missing? Why can't I make a craft that sinks? I have attached my davincisvessels.cfg file in .txt form, just the way github likes it.
davincisvessels.txt

You don't submerse using the up and down keybinds. To submerse you need to open the vessel's inventory and click the button with the picture of the helm on it.

Thank you for the prompt response! The button is grayed out however.

I fiddled around  by placing and removing some blocks, and it worked. Thank you for your hard work on this amazing project! I am using Davinci's vessels in concert with ICBM in order to make a submarine that can pull up to a base and launch missiles. Some of the most amazing things are possible with this mod, and I really appreciate it.

good idea with the ICBM mod, this mod is one of my favorites

good idea with the ICBM mod, this mod is one of my favorites


Father, forgive me, for I am adding inline types.

Description
This PR fixes #

@Kludex , I am sure you will be happy to see this PR.

It makes more sense, yep 😁


[BUG] - Initial sync may block forever with CPU maxed out

External
Initial Sync
Summary
After a varying number of slots the node freezes with CPU maxed out.

There is no more logging to console nor to the (debug) log file
The EKG/Prometheus endpoints do not respond any more

As if the node has gotten itself in a tight endless loop.
Steps to reproduce
On ARM64 I do ...
docker run --detach \
    --name=relay \
    -p 3001:3001 \
    nessusio/cardano run

docker logs -f relay

https://hub.docker.com/r/nessusio/cardano
Expected behavior
Initially, I'd like to see some indication of what is going on in the log so that eventually we can get to the bottom of this.
System info

ARM64
RaspberryPi4 or AWS CentOS8
Docker
cardano-node-1.24.2

Screenshots and attachments
Nothing suspicious in the log
[relay:cardano.node.ChainDB:Info:43] [2021-01-04 19:21:41.82 UTC] Valid candidate 3f8a7c65f73ee0485dcad85bc2174c0eb7ab651bcf5110721b6fb8613ca0a73e at slot 44576
[relay:cardano.node.ChainDB:Notice:43] [2021-01-04 19:21:41.82 UTC] Chain extended, new tip: 3f8a7c65f73ee0485dcad85bc2174c0eb7ab651bcf5110721b6fb8613ca0a73e at slot 44576
[relay:cardano.node.ChainDB:Info:43] [2021-01-04 19:21:41.83 UTC] Valid candidate 59d9848454e1b12dcb985695fe424d9823ebc0f0ac5d919b579ea8e972c663fa at slot 44577
[relay:cardano.node.ChainDB:Notice:43] [2021-01-04 19:21:41.84 UTC] Chain extended, new tip: 59d9848454e1b12dcb985695fe424d9823ebc0f0ac5d919b579ea8e972c663fa at slot 44577
[relay:cardano.node.ChainDB:Info:579] [2021-01-04 19:21:41.87 UTC] before next, messages elided =<PHONE_NUMBER>9862
[relay:cardano.node.ChainDB:Info:579] [2021-01-04 19:21:41.87 UTC] Valid candidate 92f47f9867cc1a2e0e6e2ec4f04a1fcb7764cc395cb0a00447823b907c59de3f at slot 44578
[relay:cardano.node.ChainDB:Notice:43] [2021-01-04 19:21:41.87 UTC] Chain extended, new tip: 92f47f9867cc1a2e0e6e2ec4f04a1fcb7764cc395cb0a00447823b907c59de3f at slot 44578
[relay:cardano.node.ChainDB:Info:43] [2021-01-04 19:21:41.97 UTC] Valid candidate 7ea7a82ce1d7ae747532b7174a4fc03f022a99e905bdffdc4aa95bb9f13b2903 at slot 44588
[relay:cardano.node.ChainDB:Notice:43] [2021-01-04 19:21:41.97 UTC] Chain extended, new tip: 7ea7a82ce1d7ae747532b7174a4fc03f022a99e905bdffdc4aa95bb9f13b2903 at slot 44588
[relay:cardano.node.ChainDB:Notice:43] [2021-01-04 19:21:42.01 UTC] Chain extended, new tip: 6e2dedc9f5188ce372908ea5b31bccc69fba5d231928ce9bd924580bf7f97a47 at slot 44593
[relay:cardano.node.ChainDB:Notice:43] [2021-01-04 19:21:42.10 UTC] Chain extended, new tip: 506678c536215bebde58dbec021eae2c6f1485c6273d56a25829da4335909aae at slot 44605
[relay:cardano.node.ChainDB:Notice:43] [2021-01-04 19:21:42.13 UTC] Chain extended, new tip: df0824814a70181c39230bc5e5c896d1c84a83659743eccd474f0a045f493f87 at slot 44609
[relay:cardano.node.ChainDB:Info:43] [2021-01-04 19:21:42.17 UTC] Valid candidate f752a1fe0095404a9170ec32a113fb3a87e04d6f5090de3c7fd102c827fe0212 at slot 44612
[relay:cardano.node.ChainDB:Notice:43] [2021-01-04 19:21:42.17 UTC] Chain extended, new tip: f752a1fe0095404a9170ec32a113fb3a87e04d6f5090de3c7fd102c827fe0212 at slot 44612
[relay:cardano.node.ChainDB:Notice:43] [2021-01-04 19:21:42.21 UTC] Chain extended, new tip: 9b68f553ff387583d28b9393e7038628d012fa4a747c58a5d4a709189ca5da22 at slot 44614
[relay:cardano.node.ChainDB:Notice:43] [2021-01-04 19:21:42.23 UTC] Chain extended, new tip: 0776a4927813c3bb2ad110399d7e42df5e7427041ab221aab41d1a5007bff094 at slot 44617
[relay:cardano.node.ChainDB:Notice:43] [2021-01-04 19:21:43.48 UTC] Chain extended, new tip: 1e90177828e3433851ea7a62c0e40c1d08df5efebe3127735c22928f8c1b6a8f at slot 44820
[relay:cardano.node.ChainDB:Notice:43] [2021-01-04 19:21:44.73 UTC] Chain extended, new tip: b4a0943d858cb6b60a4e9ebc23b8e7e77bfdc4ac74094fcdced7a3b436eaaec5 at slot 45022
[relay:cardano.node.ChainDB:Notice:43] [2021-01-04 19:21:45.99 UTC] Chain extended, new tip: 5e3981dec27f84bd98e2ea155916ce4730e1a9f83361d57acfcb84c5206b4a01 at slot 45242
[relay:cardano.node.ChainDB:Notice:43] [2021-01-04 19:21:47.24 UTC] Chain extended, new tip: 475f393f3797e771cd5639cdc8cef96f1f15ae3bbe7ca07055d00540c07c89e6 at slot 45463
[relay:cardano.node.ChainDB:Notice:43] [2021-01-04 19:21:48.49 UTC] Chain extended, new tip: 3137b378f9c43c658473b03603c1e0c7893969f32220cc5d8e62e33a124ecae0 at slot 45628
[relay:cardano.node.ChainDB:Notice:43] [2021-01-04 19:21:49.75 UTC] Chain extended, new tip: f607d1f38508a965da678c941bd3c4d4aae57fac6e682872d4ae1c1aca788cbe at slot 45765
[relay:cardano.node.ChainDB:Notice:43] [2021-01-04 19:21:51.00 UTC] Chain extended, new tip: 165c54de8e7b37c8fa7455e60d5fd566d38305e11e85400999043192fad3723b at slot 45930
[relay:cardano.node.ChainDB:Notice:43] [2021-01-04 19:21:52.25 UTC] Chain extended, new tip: 3cab325f853b82b54fb9564c1f5126b932f08ffac96960605f650780bb0a3a79 at slot 46123
[relay:cardano.node.ChainDB:Notice:43] [2021-01-04 19:21:53.50 UTC] Chain extended, new tip: ac15ef556795e551043b0851f96bf4daa69241910cd3e44e86c2ade4f7c3c2f2 at slot 46325
[relay:cardano.node.ChainDB:Notice:43] [2021-01-04 19:21:54.75 UTC] Chain extended, new tip: feca1e1be67f1f3a83fa644f7bd4e4a660facae96f6014bff90e7decbd03de61 at slot 46554
[relay:cardano.node.ChainDB:Notice:43] [2021-01-04 19:21:56.00 UTC] Chain extended, new tip: 846c6ce3c92b27c91b2385dfc15719c1f691e1ff20dd6049a9fc3feeaa48c093 at slot 46779
[relay:cardano.node.ChainDB:Notice:43] [2021-01-04 19:21:57.26 UTC] Chain extended, new tip: 681ced6441ee47ab7e53ce0ca2d19794ad20ae7a55d563b4acdf94604811d837 at slot 46925
[relay:cardano.node.ChainDB:Notice:43] [2021-01-04 19:21:58.52 UTC] Chain extended, new tip: 3bc6219cfbae66b51a3d81722e3b1135ed2e7fbb3e7ea9fa71d990310add1491 at slot 47079
[relay:cardano.node.ChainDB:Notice:43] [2021-01-04 19:21:59.77 UTC] Chain extended, new tip: a419a6c6aafd309903c0dcef5d83d21b8f3b31bcadb2bc2fc78fff86f2b4e1a0 at slot 47237
[relay:cardano.node.ChainDB:Notice:43] [2021-01-04 19:22:01.02 UTC] Chain extended, new tip: e7334bed09c631e1c57e34b94e0eed71d9f144e01deff97b34ff1a9c2a190061 at slot 47442
[relay:cardano.node.ChainDB:Notice:43] [2021-01-04 19:22:02.29 UTC] Chain extended, new tip: c51fd6044bfd31ab1e043350d5c5c4d9aba6b040ef99081185dd6cc4c621cbd1 at slot 47647
[relay:cardano.node.ChainDB:Notice:43] [2021-01-04 19:22:03.54 UTC] Chain extended, new tip: bfbab36bae5f0b77d3d1590c476185620ff854caee775ad8eefab84fe4c676f2 at slot 47836

Any idea what I could do next to find out what's going on. Is there perhaps a way to dump stack traces for active threads?
Additional context
CrossRef: https://github.com/tdiesler/nessus-cardano/issues/6
This seems to be a general ARM64 issue and not so much a RaspberryPi 4 one.
On x86_64 this works fine.

I have been trying to sync to it for 12 hours but need to keep stopping the relay and then starting it again about every hour or so to keep the sync process going. Any ideas why this would happen? My CPU is not maxed out.

compiled version 1.25.1 from source on Pi4 8GB OS Ubuntu Server 64bit and am seeing similar issue. Compiled with cabal-install <IP_ADDRESS> and ghc 8.10.2, the node runs and starts to sync, after a period of about 20 minutes cardano-cli query tip --mainnet becomes unresponsive. Running cardano-node in the terminal reveals the sync appears to stop, but the node is still running full tilt, left overnight consumed 80% of RAM but no additional blocks written to disk. Restarting the cardano-node resumes sync until it fails again. cardano-cli did error on socket exhaustion one time, but cant recreate that condition reliably.
May be a localhost socket exhaustion issue?

You need ghc-8.10.4 for Arm in order to get the needed fixes to the haskell RTS.
With out it it is possible that cardano-node deadlocks or livelocks (as in your case).

This has been fixed in nessus-cardano-1.25.1-rev3
I think we can close this now.


ERROR: Unknown argument '--types'.

I'm developing on Drupal 7 and the run-tests.sh script doesn't recognize the --types switch provided by the drupal run tests plugin.
I've tried deselecting all the types in the configuration, but the --types argument is still supplied as:
--types ""

Thanks, this is only available on D8. I'll need to check the Drupal enabled support setting for current version.

Thanks for fixing this. I'll have to give it a try.
On Mon, Feb 27, 2017 at 2:15 PM Matt Glaman<EMAIL_ADDRESS>wrote:

Closed #27
https://github.com/mglaman/intellij-drupal-run-tests/issues/27 via
f2749b0
https://github.com/mglaman/intellij-drupal-run-tests/commit/f2749b072720ad4738ed926d3237d07684e16154
.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
https://github.com/mglaman/intellij-drupal-run-tests/issues/27#event-978908654,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AArZ121A0eJDqYEHwBG9rTdE42lWgWtoks5rgyBCgaJpZM4L7Pi-
.

--
Sent from my iPhone

@jayusa123 it's not in a tagged release, yet. Working on a few more fixes. When the update comes through it will be all good :)


[Repo maintenance]: pnpm run check-all script returns an error

I forgot to migrate apps/documentation to eslint@9 so check-all script now fails.
The workspace needs to be updated like other packages/* workspace.

[!NOTE]
This issue is caused by CI not been executed on docs folder.
#147 only edited packages/** source code so ci-documentation was not trigged.

[!TIP]
To avoid issue in the future both typescript and ci-documentation must have root package.json added to the paths trigger


Vite 6 support

Clear and concise description of the problem
Vite 6 support
Suggested solution
https://vite.dev/guide/migration.html
Alternative
No response
Additional context
No response
Validations

[X] Follow the Code of Conduct.
[X] Read the Contributing Guidelines.
[X] Read the docs.
[X] Check that there isn't already an issue that requests the same feature to avoid creating a duplicate.

wip

I'm starting a new project with Vite@6 overrides, and it works till now

<EMAIL_ADDRESS>Although vite@5 Although the job is pretty good. But there will be warnings during installation
npm error code ERESOLVE
npm error ERESOLVE could not resolve
npm error
npm error While resolving<EMAIL_ADDRESS>npm error Found<EMAIL_ADDRESS>npm error node_modules/vite
npm error   dev<EMAIL_ADDRESS>from the root project
npm error   peer<EMAIL_ADDRESS>|| ^6.0.0" from<EMAIL_ADDRESS>npm error   node_modules/@vitejs/plugin-vue
npm error     dev<EMAIL_ADDRESS>from the root project
npm error
npm error Could not resolve dependency:
npm error peer<EMAIL_ADDRESS>|| ^5.0.0" from<EMAIL_ADDRESS>npm error node_modules/electron-vite
npm error   dev<EMAIL_ADDRESS>from the root project
npm error
npm error Conflicting peer dependency<EMAIL_ADDRESS>npm error node_modules/vite
npm error   peer<EMAIL_ADDRESS>|| ^5.0.0" from<EMAIL_ADDRESS>npm error   node_modules/electron-vite
npm error     dev<EMAIL_ADDRESS>from the root project
npm error
npm error Fix the upstream dependency conflict, or retry
npm error this command with --force or --legacy-peer-deps
npm error to accept an incorrect (and potentially broken) dependency resolution.

Hi @alex8088,
I've been following this issue and noticed it's been quiet for about 2 weeks. I was wondering if there are any updates on the progress or if there's any way I could help move this forward?
Thank you for your time!

Hello, Can I know if there will be an update this month? And what is the status of the update?


Swap the menu entry for Port Phasmatys Energy Barrier

Currently the left click option opens a dialog, and the Pay-toll(2 ecto) gets you through w/o a dialog.

Looking through the code, it appears that it is already implemented. It should be grouped with the "Travel" checkbox. I do not have the quest done, however, so I cannot test this.
else if (config.swapTravel() && option.equals("pass") && target.equals("energy barrier")) 		{ 			swap("pay-toll(2-ecto)", option, target, true); 		}

Hmm it appears so. I'm not running the snapshot so I didn't see it/can't test it.
And I didn't find any open/closed PRs when searching "phasmatys."


Confusing error message from CSV AUTODETECT

Bug: got a different (and wrong!) error messages from CSV import when using AUTO_DETECT.
[Using the python interface, where "c" below is a cursor on the db connection.]
My table:
    c.execute('''CREATE TABLE imageTags
                 (image_id INT,
                  tag_id INT,
                  PRIMARY KEY(image_id,tag_id))''')

NOTE: three columns.
The CSV to import (sample subset):
tag_id|name|category|count
470575|1girl|0|2612433
16751|bangs|0|527398
11826|barefoot|0|165731
537684|blunt_bangs|0|76594

NOTE: four columns.
Attempt 1:
    c.execute("COPY tags FROM 'tags.csv' ( AUTO_DETECT TRUE )")

Error message: RuntimeError: Parser: Error on line 2: expected 3 values but got 1
Attempt 2:
    c.execute("COPY tags FROM 'tags.csv' ( DELIMITER '|', HEADER )")

Error message: RuntimeError: Parser: Error on line 2: expected 3 values but got 4

Hi, I tried to reproduce the issue based on your provided examples

I changed the table name from imageTags to tags in the CREATE TABLE statement. I hope that this is was correct.

The resulting table tags has 2 columns and a primary key constraint on my system, not 3 columns.

I assume that what you intended to do was to import the tags.csv file into the just created tags table. Correct? Currently, we do not support an automatic filtering of columns based on the target schema, but it is a planned feature for future releases (see https://github.com/cwida/duckdb/issues/782)

Now to the error messages you got. I could actually not reproduce the same messages. Instead, I received the following output, which I can also explain:
COPY tags FROM 'tags.csv' ( AUTO_DETECT TRUE )
-->
Parser: Error on line 2: expected 2 values but got 1
The parser expects 2 values (per column) because it looks at the tags schema at hand. It only got one column because it dismissed the | separator as a possible option because it would have resulted in 4 columns which would have been too many. Therefore it fell back to default parameters (comma separation) which resulted in 1 value (per column).
COPY tags FROM 'tags.csv' ( DELIMITER '|', HEADER )
-->
Parser: Error on line 2: expected 2 values but got 3
Here, the parser expects 2 values again (based on the provided tags schema), but as it got to the 3rd value in the column it stopped with an error message.

I understand that the error messages are not very expressive and should be improved. Thanks for the report.

D'oh! Copy-pastad the wrong table:
    c.execute('''CREATE TABLE tags
                 (tag_id INT,
                  name TEXT,
                  category INT)''')

My apologies for the mixup. You were able to repro the essence of the issue.

It only got one column because it dismissed the | separator as a possible option because it would have resulted in 4 columns which would have been too many.

Reasonable enough! That is actually a clever attempt to be smart.

Perhaps an idea would be to add the detected settings to the error message in case auto detect is enabled. For example:
RuntimeError: Parser: Error on line 2: expected 3 values but got 1 (DELIMITER ',', HEADER 1)

Right! That would be cool. Let me push a change.

I think that this has been resolved now with the latest error message updates. Feel free to re-open if you have more issues related to this.


HTK sharing is not working b/w hololens and Immersive headsets!!.

Overview
trying to sharing bw hololens and immersive headset!!.
Expected Behavior
it supposed to be work like 2 hololenses.
Actual Behavior
Not connected.
Steps to reproduce
tried with HTK sharing scene , not connecting / sharing  bw hololens and immersive headsets.
Unity Editor Version
2017.2.1p1
Mixed Reality Toolkit Release Version
2<IP_ADDRESS>

Are either devices able to connect? The HoloLens or the immersive headset?

Immersive headset even didnt connect to HTK sharing services!!.

Closing issues older than 180 days. If this is still an issue, please reactivate with recent information.


"Illegal Hardware Instruction"

Hi Brenden,
Sorry to bother you again! When I was trying to run the example config file, I encountered the error saying "illegal hardware instruction" as shown in the figure. Do you have any idea about why this happens? I am currently using a macbook with M1 pro chip. Thank you so much!

Jiayi

Just want to add a little more information. I see the answer in another post saying that the TensorFlow 1.14 is required which means that we need to use python 3.7 or older, does it correct? Currently I am using python 3.8, is this the issue here?  Thanks!

Sorry you’re having issues, we’ve never seen this before.
The Python versioning could be it. We have only tested up to TF 1.14 and Python 3.7.

Sorry you’re having issues, we’ve never seen this before.
The Python versioning could be it. We have only tested up to TF 1.14 and Python 3.7.

Thank you for your reply Brenden! Just one more quick question,  I see that you have tested this on UNIX and OSX. I was wondering can it work on the Windows? Thanks!

Hi, we have not tested on Windows. There may be some additional installation challenges there.

Hi, we have not tested on Windows. There may be some additional installation challenges there.

Thanks Brenden. Just want to add my two cents here, I tried it on a Windows 10 and it works fine.


Locations search fix update version 2.0.2

Create new 2.0.2 release for brapi client with locations search fix.

This should merge into master if you want to make a release.

This should merge into master if you want to make a release.

Thanks for catching that, updated


FHIR field assignment error: EDIFACT delimiter get populated in the coded value display

Bugs
Some of the coded value population get mixed with the EDIFACT delimiter
see example  https://github.com/nhsconnect/integration-adaptor-lab-results/blob/main/src/intTest/resources/success_uat_data/NHS004/screening_full_acceptance_with_nhsack.1.fhir.json
in this text:
{
"system": "http://snomed.info/sct",
"code": "368481000000103",
"display": "BCS?:FOB result"
}
Step to reproduce
See example above
Expected behaviors
delimiter character should not be populated.

RETEST 1
TEST STEPS TO REPRODUCE ISSUE
Resend screening_full_acceptance_with_nhsack.edifact.dat and inspect FHIR response
ACTUAL RESULT
EDIFACT delimiter is not present in 'display' FHIR element.
Please see screenshots attached.

NHS004_screening_full_acceptance_with_nhsack.edifact.dat FHIR payload txt.txt
Retest 1 PASSED
Defect 152 Closed


Enable attach() to work with any buffer given the necessary context data

Could we extend the gitsigns.attach() function to allow for attaching to any arbitrary buffer given the necessary git context data? This would allow plugins to utilize gitsigns to attach to any buffer that represents a real git object.
The motivation for this is that - from time to time - users ask about the possibility to show inline diffs in diffview.nvim. I figured that using gitsigns with toggle_linehl and toggle_deleted is perfect for this. Except that currently I can only do this with the current, working tree version of a file (and fugitive buffers).
Instead of giving gitsigns the capability to parse diffview URI's, I figured it would be a lot more extensible to extend the attach() function such that callers can optionally give it information about:

What file the buffer represents.
The top-level of it's parent git repository.
The path to the git dir.
The revision it belongs to (i.e. a commit SHA).
The base revision it should be diffed against.

Imagined API
---@param bufnr integer # Buffer number
---@param ctx GitContext
function gitsigns.attach(bufnr, ctx) --[[ ... ]] end

---@class GitContext
---@field toplevel string # Path to the top-level of the repository
---@field gitdir string # Path to the git dir
---@field file string # Path to the file represented by the buffer
---@field commit string # Git revision the file belongs to
---@field base string # Git revision the file should be diffed against

-- Works the same as before when only given a bufnr
gitsigns.attach(12)

-- When given, gitsigns will try to attach to the buffer using the context
-- data, instead of deriving this from the buffer name / path.
gitsigns.attach(12, {
  toplevel = "/path/to/toplevel",
  gitdir = "/path/to/toplevel/.git",
  file = "path/to/file.txt",
  commit = "d076301",
  base = "a4e2275",
})

Is this something you'd be willing to include? If so, I can work on a PR.

It's an interesting idea. I'd review a PR.


Update the new featured collections to point to the correct pipelines

Submitted a PR in the collections repo to pull in the appropriate pipelines.
https://github.com/kabanero-io/collections/pull/32


enabling debug dumping-as-json mode for v6 files

If you set SCENE_FILE_V6_DEBUG=1 prior to running xochitl will start dumping the rm files as json files for debug when it saves them - it'll output in journalctl what the filenames are.
If you wanna enable this persistently:
[Unit]
Description=reMarkable main application
StartLimitIntervalSec=600
StartLimitBurst=4
OnFailure=remarkable-fail.service
After=home.mount
Wants=rm-sync.service

[Service]
ExecStart=/usr/bin/xochitl --system
Restart=on-failure
WatchdogSec=60
Environment="SCENE_FILE_V6_DEBUG=1"

[Install]
WantedBy=multi-user.target

Super interesting! Do you have an example of what such a file looks like? I don't have access to my ReMarkable at the moment since it's bricked :x

Sorry to hear that!
I'll get a sample one together soon, but they can be pretty huge. Its the entire file in plain JSON format. For example here's block type 13:
    "SceneInfo": {
        "backgroundVisible": {
            "timestamp": "0:0",
            "value": 1
        },
        "currentLayer": {
            "timestamp": "1:1892",
            "value": "0:11"
        },
        "rootDocumentVisible": {
            "timestamp": "1:1887",
            "value": 1
        }
    },

and block type 8:
        {
            "CrdtTombstoneItem": {
                "deletedLength": 20,
                "id": "1:43",
                "left": "1:42",
                "parentId": "0:11",
                "right": "0:0"
            }
        },

patches incoming :D

Oh my
Did you discover this debugging flag yourself? It's stupidly useful for what we're doing here 😅😅

yeah, just found them this afternoon! I'd spotted there were some interesting strings which were clearly about "writing scene files out as JSON" so I went poking about with Ghidra.. and there it was!

Awesome! You should really share this discovery in the remarkable discord!

Good plan: done!
Here's a simple sample of the RM file and its matching json file.
2584527c-7667-4b1c-994c-ae70215653e4.rm.gz
2584527c-7667-4b1c-994c-ae70215653e4.rm.tmp.json.gz

@adq that's great! Thanks for sharing and for the patches.

I've added a link to this issue in the README and so will close it here.


Add WebDAV methods

It would be great if snowcrash supported the WebDAV methods. This PR will make it recognize additional methods from RFC4918, RFC3253, RFC5323, RFC4791 and RFC3744 to allow parsing and subsequently rendering nice html and json.

Snowcrash is deprecated. We have moved everything monorepo style. drafter#564


ApiFutures::catching with executor does not use executor

Hello, while trying to understand an issue I was debugging I ended up reading the code for ApiFutures, and I noticed that the passed executor was not used and instead directExecutor() was always used. This seems like a bug, so I figured I should report it, terribly sorry if that is not the case.
I would have expected this line to pass the executor:
https://github.com/googleapis/api-common-java/blob/master/src/main/java/com/google/api/core/ApiFutures.java#L103

The ApiFuture class and other infrastructure uses the same paradigms as Guava, which you can see here: https://github.com/google/guava/wiki/ListenableFutureExplained.  In fact, ApiFuture is basically implemented as a wrapped version of ListenableFuture.  We use ApiFuture because Guava is used everywhere, and we'd like to potentially do things like repackage the underlying ListenableFuture implementation so our applications would be compatible with other environments that use an incompatible version of Guava.
The bottom line is that ApiFuture works as intended.  The general use starts with an Executor, which will usually spawn a thread to do something interesting.  There are follow up operations once the "interesting" behavior is done.  Transforming the result of the future or doing something with an exceptions are in that "follow up" category.  In most cases, MoreExecutors.directExecutor() can be used for the "follow up" operation, since they will be quick.  Guava gives you the option to run the "follow up" on a different thread, just in case you need to.  The cases where you see directExecutor() should be fine.

If the intended behaviour is to always run using a directExecutor(), isn't it confusing that the method takes an executor as a parameter that is not used. Wouldn't it be better to not even have that parameter?

oh... I see. I'll change that :).  Sorry for the rant.


Update use_cli_effectively.md

Add a section: Understand different behavior of Command Prompt, Powershell and Bash

This checklist is used to make sure that common guidelines for a pull request are followed.

[ ] The PR has modified HISTORY.rst describing any customer-facing, functional changes. Note that this does not include changes only to help content. (see Modifying change log).

[ ] I adhere to the Command Guidelines.

I'd prefer adding this to appendix section.

I'd prefer adding this to the appendix section.


Add 'all' as query for targeting all Simulators

There's currently no way of selecting 'all' simulators when performing a query, this means that killing or deleting all the simulators has to be done via pool preconditions like --delete-all and --kill-all. This doesn't make a huge amount of sense, as having purpose built operations is much more obvious.
Also adds defaulting of Query for the list command so that fbsimctl list lists all Simulators.

@facebook-github-bot shipit


Check context response existence before logging it

Q
A

Bug fix?
yes

New feature?
no

BC breaks?
no

Deprecations?
no

Tests pass?
yes

License
MIT

Sometimes when i try to access a page, i get this error :
Argument 1 passed to EightPoints\Bundle\GuzzleBundle\Log\LogResponse::__construct() must be an instance of Psr\Http\Message\ResponseInterface, null given, called in /path/to/bundle/GuzzleBundle/Log/Logger.php on line 44
Refreshing the page does not repeat the error (making it hard to reproduce).
I don't know why this append.
I fixed it by checking not null $context['response'] but it might be interesting to look for root problem.
Does anyone have an idea ?
Thank you.

I will check the response issue this afternoon.

Hi @MatthieuCutin, thanks for your contribution and your time!
Can you do the same for if (isset($context['request'])) {?
Afterwards I will gladly merge your fix.

Nice! Thanks a lot.
Going to release a new version later.

My pleasure :)

Release 5.0.2: https://github.com/8p/GuzzleBundle/releases/tag/v5.0.2


Burn After -> First Read gets 2 reads to create content

Steps to reproduce problem:
NEW
BURN AFTER -> First Read
SAVE
[display content to get link, edit or remove]
Read 2 times, last just now
Description
When NEW content is created and BURN AFTER is set "First Read",  just after SAVE and show content to recover LINK the system reports:
Read 2 times, last just now

Problem
It is unuseful to get the link because the content has been deleted and the link shows 404 always.

same here with Version 2.0.4, Build 20230711

Hey guys. Any possible fixes there?

Any update on this? Thank you very much to push microbin further!

Tackling this now because it's quite annoying. There's two GET requests sent to the pasta's endpoint as soon as it's created, instead of just one. I haven't been able to identify why there are two requests yet

@szabodanika Thank you for your investigations!

@szabodanika Thank you. I am a first time user, encountered this issue and came here to see if it'd been reported. Loving it otherwise so far!

@szabodanika Seeing that the last push was August 2023, is there any way to get this pushed sooner rather than later? I use the docker image, and it would be great if this became available.
Thank you!


-[NSKeyedUnarchiver validateAllowedClass:forKey:]  allowed unarchiving safe plist type ''NSString' (0x1e1552fd8) [/System/Library/Frameworks/Foundation.framework]'

I am getting the following error
-[NSKeyedUnarchiver validateAllowedClass:forKey:] allowed unarchiving safe plist type ''NSString' (0x1e1552fd8) [/System/Library/Frameworks/Foundation.framework]' for key '********', even though it was not explicitly included in the client allowed classes set: '{(  )}'. This will be disallowed in the future.
I think this is an error in Defaults as I am using defaults to save a custom object and the object conforms to __DefaultsSerializable_
if found this
Specifying the type here fixed it:     override static var allowedTopLevelClasses: [AnyClass] {
return [NSArray.self, NSString.self]
}

Is it a logged warning or an error?
It would be great if you could submit a failing test.

it is a logged warning, it works fine now but I get the error repeatedly every time I access Defaults[.myValue]