JSON RPC not working on ubuntu

I am trying to use the VERGE-PYTHON module to integrate verge payments onto a website. I have had this working on windows and have moved to ubuntu to test before going to a production environment.
No matter what I have tried the VERGEd RPC commands will not work, I need some help with what I am doing wrong here.
I have set everything up exactly as the documentation specifies but I only get 405 errors when trying to send RPC commands via cURL and empty responses from the VERGE-PYTHON module. Even if i try sudo VERGEd getinfo from the terminal I get a 405 from server.
Any help would be greatly appreciated!
Prerequisites

[] Are you running the latest version?
yes

User Story:

"I'm submitting a ... "

[] support request

Your Environment

Verge Release: VERGE version v<IP_ADDRESS>-541f2e9-funky-beta
CPU: Intel(R) Core(TM) i7-6500U
GPU: Sun XT [Radeon HD 8670A/8670M/8690M / R5 M330 / M430]
RAM: 12gb
OS: Ubuntu 18.04

[yes ] I'm using Linux

Any extra information that might be useful in the debugging process.

My VERGE.conf:
rpcuser=testuser
rpcpassword=testing
rpcport=20102
port=21102
daemon=1
server=1
algo=groestl
My torrc:
Tor opens a SOCKS proxy on port 9050 by default -- even if you don't
configure one below. Set "SOCKSPort 0" if you plan to run Tor only
as a relay, and not make any local application connections yourself.
HTTPTunnelPort localhost:20102
#SOCKSPort localhost:20101
#SOCKSPort 0 ## Default: Bind to localhost:9050 for local connections.
#SOCKSPort <IP_ADDRESS>:9100 # Bind to this address:port too.
cURL:
curl -v -u testuser:testing --data '{"version": "1.1", "method": "getinfo", "params": [], "id": 1}' -H 'content-type: text/plain;' http://localhost:20102

Rebuilt URL to: http://localhost:20102/
Trying <IP_ADDRESS>...
TCP_NODELAY set
Connected to localhost (<IP_ADDRESS>) port 20102 (#0)
Server auth using Basic with user 'testuser'

POST / HTTP/1.1
Host: localhost:20102
Authorization: Basic dGVzdHVzZXI6dGVzdGluZw==
User-Agent: curl/7.58.0
Accept: /
content-type: text/plain;
Content-Length: 62

upload completely sent off: 62 out of 62 bytes
HTTP 1.0, assume close after body
< HTTP/1.0 405 Method Not Allowed
<
Closing connection 0

With VERGE-PYTHON:
Internal Server Error: /home/
Traceback (most recent call last):
File "/home/user/env/test/lib/python3.6/site-packages/django/core/handlers/exception.py", line 35, in inner
response = get_response(request)
File "/home/user/env/test/lib/python3.6/site-packages/django/core/handlers/base.py", line 128, in _get_response
response = self.process_exception_by_middleware(e, request)
File "/home/user/env/test/lib/python3.6/site-packages/django/core/handlers/base.py", line 126, in _get_response
response = wrapped_callback(request, *callback_args, **callback_kwargs)
File "/home/user/env/test//views.py", line 56, in index
print(conn.getinfo())
File "/home/user/env/test/vergerpc/connection.py", line 132, in getinfo
return ServerInfo(**self.proxy.getinfo())
File "/home/user/env/test/vergerpc/proxy.py", line 126, in call
resp = json.loads(resp, parse_float=decimal.Decimal)
File "/usr/lib/python3.6/json/init.py", line 367, in loads
return cls(**kw).decode(s)
File "/usr/lib/python3.6/json/decoder.py", line 339, in decode
obj, end = self.raw_decode(s, idx=_w(s, 0).end())
File "/usr/lib/python3.6/json/decoder.py", line 357, in raw_decode
raise JSONDecodeError("Expecting value", s, err.value) from None
json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)
From Terminal:
sudo VERGEd getinfo
error: server returned HTTP error 405
tor.log:
May 11 23:06:19.000 [notice] Tor <IP_ADDRESS>-rc-dev opening log file.
May 11 23:06:19.365 [notice] Tor <IP_ADDRESS>-rc-dev running on Linux with Libevent 2.1.8-stable, OpenSSL 1.1.0g, Zlib 1.2.11, Liblzma N/A, and Libzstd N/A.
May 11 23:06:19.365 [notice] Tor can't help you if you use it wrong! Learn how to be safe at https://www.torproject.org/download/download#warning
May 11 23:06:19.365 [notice] Read configuration file "/home/user/.VERGE/tor/torrc".
May 11 23:06:19.369 [notice] Scheduler type KIST has been enabled.
May 11 23:06:19.369 [notice] Opening Socks listener on <IP_ADDRESS>:9089
May 11 23:06:19.369 [notice] Opening HTTP tunnel listener on <IP_ADDRESS>:20102
May 11 23:06:19.000 [notice] Parsing GEOIP IPv4 file /usr/local/share/tor/geoip.
May 11 23:06:19.000 [notice] Parsing GEOIP IPv6 file /usr/local/share/tor/geoip6.
May 11 23:06:19.000 [warn] You are running Tor as root. You don't need to, and you probably shouldn't.
May 11 23:06:19.000 [notice] Bootstrapped 0%: Starting
May 11 23:06:19.000 [notice] Starting with guard context "default"
May 11 23:06:19.000 [notice] Bootstrapped 80%: Connecting to the Tor network
May 11 23:06:20.000 [notice] Bootstrapped 85%: Finishing handshake with first hop
May 11 23:06:22.000 [notice] Bootstrapped 90%: Establishing a Tor circuit
May 11 23:06:23.000 [notice] Tor has successfully opened a circuit. Looks like client functionality is working.
May 11 23:06:23.000 [notice] Bootstrapped 100%: Done
May 11 23:11:18.000 [warn] Saying "HTTP/1.0 405 Method Not Allowed\r\n\r\n"
May 11 23:11:18.000 [warn] connection_mark_unattached_ap_(): Bug: stream (marked at src/or/connection_edge.c:2544) sending two socks replies? (on Tor <IP_ADDRESS>-rc-dev 9ef97a268b06fed7)
May 11 23:12:19.000 [warn] Saying "HTTP/1.0 405 Method Not Allowed\r\n\r\n"
May 11 23:12:19.000 [warn] connection_mark_unattached_ap_(): Bug: stream (marked at src/or/connection_edge.c:2544) sending two socks replies? (on Tor <IP_ADDRESS>-rc-dev 9ef97a268b06fed7)
May 11 23:15:45.000 [warn] Fetching v2 rendezvous descriptor failed. Retrying at another directory.
May 11 23:15:52.000 [warn] Fetching v2 rendezvous descriptor failed. Retrying at another directory.
May 11 23:16:28.000 [warn] Fetching v2 rendezvous descriptor failed. Retrying at another directory.
May 11 23:16:30.000 [notice] Closing stream for '[scrubbed].onion': hidden service is unavailable (try again later).
May 11 23:17:52.000 [notice] Closing stream for '[scrubbed].onion': hidden service is unavailable (try again later).
May 11 23:18:28.000 [notice] Closing stream for '[scrubbed].onion': hidden service is unavailable (try again later).
May 11 23:18:51.000 [warn] Fetching v2 rendezvous descriptor failed. Retrying at another directory.
May 11 23:18:54.000 [warn] Fetching v2 rendezvous descriptor failed. Retrying at another directory.
May 11 23:18:55.000 [notice] Closing stream for '[scrubbed].onion': hidden service is unavailable (try again later).
May 11 23:19:07.000 [warn] Saying "HTTP/1.0 405 Method Not Allowed\r\n\r\n"
May 11 23:19:07.000 [warn] connection_mark_unattached_ap_(): Bug: stream (marked at src/or/connection_edge.c:2544) sending two socks replies? (on Tor <IP_ADDRESS>-rc-dev 9ef97a268b06fed7)

I have tried it with my credentials, everything worked out fine:
curl -v -u kyon:lolcat --data '{"version": "1.1", "method": "getinfo", "params": [], "id": 1}' -H 'content-type: text/plain;' http://localhost:20102
* Rebuilt URL to: http://localhost:20102/
*   Trying <IP_ADDRESS>...
* TCP_NODELAY set
* Connected to localhost (<IP_ADDRESS>) port 20102 (#0)
* Server auth using Basic with user 'kyon'
> POST / HTTP/1.1
> Host: localhost:20102
> Authorization: Basic a3lvbjpsb2xjYXQ=
> User-Agent: curl/7.54.0
> Accept: */*
> content-type: text/plain;
> Content-Length: 62
>
* upload completely sent off: 62 out of 62 bytes
< HTTP/1.1 200 OK
< Date: Fri, 11 May 2018 18:48:01 +0000
< Connection: keep-alive
< Content-Length: 611
< Content-Type: application/json
< Server: VERGE-json-rpc/v<IP_ADDRESS>-80de5df-funky-beta
<
{"result":{ ... },"error":null,"id":1}
* Connection #0 to host localhost left intact

maybe you can have a try with my VERGE.conf
rpcuser= testuser
rpcpassword=testing
rpcport=20102
port=21102
server=1
daemon=1
rpcallowip=<IP_ADDRESS>

Just to eliminate Tor as a potential cause, you could try downloading the clearnet
git clone https://github.com/vergecurrency/VERGE.git
cd VERGE
git checkout 4.0clearnet
./autogen.sh
./configure
make

delete old peers.dat

@marpme tried your VERGE.conf  but still no luck. will try your suggestion @jrsikors and post back

@jrsikors Your suggestion got it working, so the issue is with my tor setup? If you think I do not need to run tor then I will keep it as is and consider it solved.
Thanks for your help!
Could update the VERGE-PYTHON docs to suggest this way for people in the future?

The only thing I could find was:
https://tor.stackexchange.com/questions/16095/405-method-connection-mark-unattached-ap
"The HTTPTunnelPort is an HTTP CONNECT proxy, so it only accepts the CONNECT method. It seems the app is using CONNECT for HTTPS and another method for HTTP?"
It must not like your HTTPTunnelPort localhost:20102 ?

May 11 23:06:19.365 [notice] Read configuration file "/home/user/.VERGE/tor/torrc".

Did you manually create it?  Or were those lines and torrc already there when you compiled it?

HTTPTunnelPort localhost:20102
#SOCKSPort localhost:20101
#SOCKSPort 0 ## Default: Bind to localhost:9050 for local connections.
#SOCKSPort <IP_ADDRESS>:9100 # Bind to this address:port too.

Basically either delete the torrc file, or put a # in front of HTTPTunnelPort localhost:20102

@marpme — were you using clearnet?  Or did you have a custom torrc?  Or did your test just work?

On May 16, 2018, at 1:37 PM, halfn0rmal<EMAIL_ADDRESS>wrote:
I manually created the torrc file, when I run without the httpTunnelPort I get a return that says:
This is a SOCKs proxy, not an HTTP proxy.
It appears you have configured your web browser to use this Tor port as an HTTP proxy.
This is not correct: This port is configured as a SOCKS proxy, not an HTTP proxy. If you need an HTTP proxy tunnel, use the HTTPTunnelPort configuration option in place of, or in addition to, SOCKSPort. Please configure your client accordingly.
See https://www.torproject.org/documentation.html for more information
After I initially got that message I added the torrc with the httpTunnelPort. The weird thing is this setup worked on my windows machine but not on Ubuntu.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub, or mute the thread.

So again from Ubuntu 16.04. (the closest I could actually test)
curl output:
curl -v -u vergetestuser:testing --data '{ "version": "1.1", "method": "getinfo", "params": [], "id": 1 }' -H 'content-type: text/plain;' http://localhost:20102
* Rebuilt URL to: http://localhost:20102/
*   Trying <IP_ADDRESS>...
* Connected to localhost (<IP_ADDRESS>) port 20102 (#0)
* Server auth using Basic with user 'vergetestuser'
> POST / HTTP/1.1
> Host: localhost:20102
> Authorization: Basic dmVyZ2V0ZXN0dXNlcjp0ZXN0aW5n
> User-Agent: curl/7.47.0
> Accept: */*
> content-type: text/plain;
> Content-Length: 64
>
* upload completely sent off: 64 out of 64 bytes
< HTTP/1.1 200 OK
< Date: Fri, 25 May 2018 22:13:32 +0000
< Connection: keep-alive
< Content-Length: 582
< Content-Type: application/json
< Server: VERGE-json-rpc/v<IP_ADDRESS>-e1b8fd8-funky-beta
<
{"result":{"version":"v<IP_ADDRESS>-e1b8fd8-funky-beta","protocolversion":90001,"walletversion":60000, ....},"error":null,"id":1}
* Connection #0 to host localhost left intact

verged output:
VERGE version v<IP_ADDRESS>-e1b8fd8-funky-beta (2018-04-16 21:59:28 +0200)
Using OpenSSL version OpenSSL 1.0.2g  1 Mar 2016
Startup time: 05/25/18 22:16:59
Default data directory /home/kyon/.VERGE
Default mining hash algorithm: scrypt
Used data directory /home/kyon/.VERGE
scrypt: using scrypt-sse2 as built.
dbenv.open LogDir=/home/kyon/.VERGE/database ErrorFile=/home/kyon/.VERGE/db.log
Bound to <IP_ADDRESS>:21102
TOR thread started.
AddLocal(6wmrllg42oylrbva.onion:21102,4)
Loading block index...
Opening LevelDB in /home/kyon/.VERGE/txleveldb
No OBFS4 found, not using it.
May 26 00:16:59.074 [notice] Tor <IP_ADDRESS>-rc-dev running on Linux with Libevent 2.0.21-stable, OpenSSL 1.0.2g, Zlib 1.2.8, Liblzma N/A, and Libzstd N/A.
May 26 00:16:59.074 [notice] Tor can't help you if you use it wrong! Learn how to be safe at https://www.torproject.org/download/download#warning
May 26 00:16:59.074 [notice] Configuration file "/home/kyon/.VERGE/tor/torrc" not present, using reasonable defaults.
May 26 00:16:59.076 [notice] Scheduler type KIST has been enabled.
May 26 00:16:59.076 [notice] Opening Socks listener on <IP_ADDRESS>:9089
Transaction index version is 70509
Opened LevelDB successfully
Loading block index 14% ...
Loading block index 28% ...
Loading block index 43% ...
Loading block index 57% ...
Loading block index 71% ...
Loading block index 85% ...
Loading block index 100% ...
LoadBlockIndex(): hashBestChain=00000000028545ad96770ceaeb302d639c50100148fa9cd72327be245a49207d  height=7031  trust=7032  date=10/14/14 13:47:19
LoadBlockIndex(): synchronized checkpoint 00000fc63692467faeb20cdb3b53200dc601d75bdfa1001463304cc790d77278
Verifying last 2500 blocks at level 1
 block index            2681ms
Loading wallet...
nFileVersion = 4000200
 wallet                  163ms
Loading addresses...
Loaded 7 addresses from peers.dat  0ms
mapBlockIndex.size() = 7032
nBestHeight = 7031
setKeyPool.size() = 101
mapWallet.size() = 0
mapAddressBook.size() = 1
Done loading
ThreadRPCServer started
ThreadSocketHandler started
Loading addresses from .onion seeds
ThreadMessageHandler started
7 addresses found from .onion seeds
ThreadOnionSeed exited
Flushed 7 addresses to peers.dat  3ms
trying connection plxs66tqlzbnh3ua.onion:21102 lastseen=73.5hrs
SOCKS5 connecting plxs66tqlzbnh3ua.onion
ThreadRPCServer method=getinfo

VERGE.conf:
rpcuser=vergetestuser
rpcpassword=testing
deamon=1
server=1

Freshly compiled on current master f8ca082 (so not clearnet) and nothing else is set up.
Just the default config and I also removed the .VERGE folder before running the newly compiled wallet.

If you are still interested in testing @halfn0rmal -- I would completely delete the torrc , or rename it to torrcOLD or something... and then try @marpme 's steps / configs... and try with only those 4 lines in the VERGE.conf
We want to see something like this in the tor log.
May 26 00:16:59.074 [notice] Configuration file "/home/kyon/.VERGE/tor/torrc" not present, using reasonable defaults.
May 26 00:16:59.076 [notice] Scheduler type KIST has been enabled.
May 26 00:16:59.076 [notice] Opening Socks listener on <IP_ADDRESS>:9089

Otherwise if you are done messing with it for now, you are good to just use the clearnet option we talked about earlier

Sorry for the delay, tried on production environment running CentOS, works perfectly first time without needing clearnet. Aside from updating the boost libraries it installed without any issue.

weird -- i'm glad it's working.  Keep an eye out for major updates coming with new codebase.  No ETA !
Cheers !


test: make test fail faster

Currently if we encounter the WPT fixture that does fetch we wait for 12 sec before it fails, which is absurd amount of time.
Extracting from other PR to see if anything fails.

@jrandolf Do you have a idea why the test for invalid may be timing out?

Blocked by https://github.com/GoogleChromeLabs/chromium-bidi/pull/1895

@jrandolf Still failing after the PR was merged.

I have run the CI with this seething multiple times on https://github.com/GoogleChromeLabs/chromium-bidi/pull/1871 only this test ever failed. So I am confident in this change.


[ml-service-remote] Change remote service API signature

Let's use ml_service_remote_request() instead of ml_service_remote_register().
ml_service_remote_request() includes register() and launch().
I will replace ml_service_remote_register() with ml_service_remote_request() later.

:memo: TAOS-CI Version: 1.5.20200925. Thank you for submitting PR #422. Please a submit 1commit/1PR (one commit per one PR) policy to get comments quickly from reviewers. Your PR must pass all verificiation processes of cibot before starting a review process from reviewers. If you are new member to join this project, please read manuals in documentation folder and wiki page. In order to monitor a progress status of your PR in more detail, visit http://ci.nnstreamer.ai/.

:octocat: cibot: @gichan-jang, A builder checker could not be completed because one of the checkers is not completed. In order to find out a reason, please go to http://ci.nnstreamer.ai/nnstreamer-api/ci/repo-workers/pr-checker/422-202311171618380.50733304023743-60b78e6748c551060d36a7b67b69cdd08b2363ef/.

Please be careful on naming APIs.
It's becoming ambiguous:

API to create a service accepting remote access at my local device.
API to create a service accepting remote access at a nearvy remote device.

The two are becoming mixed up. Make a naming rule to separate them.


Binary search is not well understood

The whole point of binary search is to do array searches in logarithmic time, instead of in linear time. Having recently taken a look at the implementations, I have not found a single one that actually does this. In fact, all the solutions I've looked at actually check to see that the array given is sorted by sorting copy of the array. This means that the solution is at least O(n) because it needs to create a copy and depending on the sorting algorithm (I think the default is merge sort), might well be O(n log n).
I think the README should make this point a lot clearer, but exercism might not be the best place to teach algorithmic complexity (or it might, I don't know). Perhaps we could add a rikki nit to check if the BinarySearch constructor sorts the input array and a call is made to the constructor in the code. Another rikki point might be to scan the code for array slices as these also create copy arrays, violating the O(log n) goal.
While it is possible to actually implement the problem as it stands in an O(log n) manner, by not using recursion, it is rather limiting. Not to mention the fact that non-recursive binary search is actually a very tricky algorithm to code up (it's easy to get off-by-one errors). It is also possible with recursion, but people tend to have difficulty in coming up with the idea of passing the start and end indices around as parameters. That would be a nice thing to teach, but is not really in the spirit of Ruby (programmer happiness)
We should also remove the test that asks clients to raise an ArgumentError if the array given is not in sorted order. It seems to mislead a lot of people and doesn't even give us any security. There is nothing stopping clients from mutating the array passed in, but exercists don't seem to be aware of that. It's a false sense of security and so is arguably teaching them a bad habit.

I wanted to add that the problems above feel like they are specifically ruby problems. Functional languages for example, can easily pass around array slices as they typically don't need to create copies. Many non-functional languages actually care about performance more than ruby and are a lot "closer to the metal" so thinking in terms of algorithmic complexity is more natural there.

These are good points.  I agree that exercism might not be the right place to teach algorithm analysis, and ruby does not lend itself well to implementing some of these "lower level" algorithms, but understanding the idea behind the exercise (even in ruby) is not a bad thing.  I do wonder though how we could enforce a specific implementation, which I don't really think is possible (or ideal).

I have been thinking about this some more.  One thought would be to distance ourselves from the "binary search" aspect of the exercise, and through code reviews/breadcrumbs lead the developer to the conclusion that there are more optimal ways to implement the particular solution.
Really we can only test what a method is doing, not its implementation so maybe the exercise should really be something along the lines of "Find the index of a particular item in a sorted array"

We should also remove the test that asks clients to raise an ArgumentError if the array given is not in sorted order

Seems good; that is in keeping with https://github.com/exercism/x-common/issues/234

I do wonder though how we could enforce a specific implementation (besides using nits from rikki), which I don't really think is possible (or ideal).

I'm not sure if this is something that would be desirable to replicate, but I'll share it in case it is: Lua creates a special TracedArray that counts the number of times you access its elements.

https://github.com/exercism/xlua/blob/master/exercises/binary-search/binary-search_spec.lua
https://github.com/exercism/xlua/blob/master/exercises/binary-search/TracedArray.lua

I have not done this exercise in Lua so I do not know whether this is prone to causing false positives or negatives, etc.
Sieve is another example of an exercise where we can only look at the result, not the implementation, and there are various submissions that will use a non-sieving implementation. Indeed, it can be argued that Exercism exercises in general should not really focus on particular implementations.

Sieve is another example of an exercise where we can only look at the result, not the implementation, and there are various submissions that will use a non-sieving implementation.

I was actually just about to mention that.

Lua creates a special TracedArray that counts the number of times you access its elements.

That seems like a great idea.

Something like the following seems like a good idea to me. Using a static array guarantees that we don't get weird array access and by ensuring that it is sorted, we can move the "ensure sorted" assertion out of the BinarySearch algorithm.
# A static sorted array.
# Maintains the invariant that all items are stored in sorted order.
# Constructing a new {TracedArray} takes time proportional to the number of
# items in the array. Returning the size and accessing an element of the array
# takes constant time.
class TracedArray
  # @!attribute [r] reads
  #   @return [Integer] The number of read accesses.
  attr_reader :reads

  # Initializes a new TracedArray
  # @param collection [Enumerable]
  def initialize(collection)
    @array  = collection.to_a.sort
    @reads  = 0
  end

  # Returns the size of the array.
  # @return [Integer]
  def size
    @array.size
  end

  # Return the ith element.
  # @param i [Integer] The index (Negative indices are NOT supported).
  # @return [Object]
  # @raise [RangeError] if i lies outside the valid dimensions of the array.
  def [](i)
    fail RangeError, i unless (0...@array.size).cover? i
    @reads += 1
    @array[i]
  end
end

Some suggestions for changing the tests:

Remove test_it_raises_error_for_unsorted_list as this is a precondition that we cannot enforce when doing a search without breaking the performance requirements and is really giving false confidence when used in the constructor.
Remove test_it_raises_error_for_data_not_in_list. A better solution is to return a negative number. Raising an exception is both expensive (you'd need to capture the exception, which adds overhead to the client) and not really appropriate. Not finding an item is not an exceptional circumstance when searching.
Remove test_it_finds_position_of_middle_item. Why do we care about returning the middle item? If we did, there should be a method #middle on the array, not on the binary search algorithm.
Add a test with random data. We could use some fuzz testing :)

@remcopeereboom This looks interesting, but I think forcing a user to implement a O(log n) search algorithm might be above the scope of exercism in its current form, and could very well turn off some users who don't have a CS background.  I think letting the user implement a solution that works first, and through code review be brought to better implementations is a better pattern.
I wonder though if we could categorize exercises somehow by their intended goal using the topics array in the config. (i.e. algorithm design and analysis/general purpose/language specific/object oriented design etc.)
This way a user who is interested in sharpening their CS skills could pull those types of exercises vs someone who is just trying to get a feel for the language and improve their broader knowledge.
I am curious what do @Insti and @kotp think?

There is a (few?) changes and conversation being made regarding ratings for difficulty and perhaps categorizing based on things being taught per exercise.
I am not sure that this will force the 0(log n) solution, but may encourage it.  If it forces it, then the discussion goes away, and that is not a good thing.  @bmulvihill are you finding that it does force this aspect?

@kotp I was looking at how Lua was using the traced array where they are ensuring that an element wa found in O(log n)
https://github.com/exercism/xlua/blob/master/exercises/binary-search/binary-search_spec.lua#L32-L37

Thanks @bmulvihill wanted to clarify the reference.

@bmulvihill

I think forcing a user to implement a O(log n) search algorithm might be above the scope of exercism in its current form

Yes, that was my thinking as well. More particularly, I don't think that it is a good platform for implementing specific algorithms. There is also a prime number sieve problem which asks clients to implement the Sieve of Eratosthenes, but very few people do so. Instead, they implement different algorithms that all find the first x primes. That was exercism is much better at, discussing a particular solution to a general (simple) problem. Some solutions might optimize performance, others might not. But the BinarySearch problem is specifically about performance. In fact, I'd ask how you would even say that something is a BinarySearch if it did not have O(log n) performance).
There is simply no reason to do binary search if not for performance. After all, a simple linear search can be used on collections that are not sorted and data structures that are not arrays.

I think letting the user implement a solution that works first,  and through code review be brought to better implementations is a better pattern.

I don't think that works for binary search as there really is only one good way to code one up; it is very hard to spot all the array copies (even for reviewers); and the topic of algorithmic performance is not easily (nor adequately) explained in a nit. But perhaps I am being overly negative. I can see this working for a problem that ask to simply find the element in a sorted array, but at the point we can start asking whether the problem is not too simple.

There is simply no reason to do binary search if not for performance. After all, a simple linear search can be used on collections that are not sorted and data structures that are not arrays.

@remcopeereboom I agree with this statement.  I think categorizing exercises under certain topics might solve this problem (but that is a larger issue).  If I am a CS student, or I just looking to brush up on my algorithms before an interview this is the exact type of problem I would want to solve, and I would want my solution to hold up to the O(log n) requirement.  If I am just trying to practice a language I might not be as interested in this exercise or want to be burdened with trying to meet that performance requirement.
I think the exercise difference-of-squares is a great example of how a user can be lead through review and bread crumbs from an O(n) solution to an O(1) by discovering the mathematical formulas behind the algorithm.  I don't know if that directly applies here because then as you mentioned the problem might be too simple.


UI Display of signed Docker images

Feature Request
We want to be able to support signed Docker images.  Both from the CLI but also some UI elements that allow users to see/inspect signatures.
Desired behaviour
CLI support, UI support, support for registration of signed Docker images
Additional Notes
From an email from Denis on 12/9/2016
Hi,
I just had a chance to look at the Docker content trust.
The good news is that is that it seems to just work. Both the cwltool and dockstore CLI don't seem to have any issue running images signed with Docker content trust. Since we just call out to cwltool and cwltool calls out to a standard Docker client, there do not appear to be any problems.
The downside is that this approach seems to conflict with automated builds and that tools will need to be registered with manual registration.
We can think about what we want to display on the Dockstore UI but we may be crippled here by the lack of an official API. Indeed, it doesn't look like the official Docker Hub (Or Docker Cloud) displays any indication that images are signed either.
But overall, it looks promising that we can write a tutorial or SOP for how to register signed tools.
┆Issue is synchronized with this Jira Story
┆Issue Type: Story
┆Fix Versions: Dockstore 1.9
┆Issue Number: DOCK-466

[~denis.yuen]Can we move this into milestone 1.7

➤ Charles Overbeck commented:
The outcome of this should be recommendations.

To clarify:

tutorial for using signed Docker images with (hopefully) the dockstore CLI backed by cwltool, cromwell
recommendations for how to let people know what is signed on Dockstore and how to make the experience better

Can live without UI elements for 1.9


ORDER BY FIELD

Hi I have a question.
Is possible to create this order sequence?
SELECT code, unit, rate FROM exchange ORDER BY FIELD(code, 'CHF', 'EUR', 'CZK') DESC, code;

Read about Order by field http://medoo.in/api/where


Bug: Extractor does not include examples for queryParameters and templateParameters

Report
When importing an OpenAPI specification with example values on the query and/or path (template) parameters in the API Management portal, the example values are imported successfully.
The values are shown in the exported template in the portal according to the specification:
https://learn.microsoft.com/en-us/rest/api/apimanagement/current-ga/api-operation/get?tabs=HTTP#parametercontract
But when using the Extractor tool, this property is missing in the output files.
Example:
Open API specification

Exported ARM template in the portal

Exported ARM template from the Extractor tool:

Expected Behavior
The example value(s) to be included in the generated ARM template.
Actual Behavior
Property "examples" is missing in the ARM template.
Steps to Reproduce the Problem

Import an OpenAPI specification which has an operation with query or path (template) parameters with an example value.
Run the Extractor tool.
Check the output of the operation in the generated ARM template.

Component
Extractor
DevOps Resource Kit Version
1.1.0
.NET Version
7.0.101
OS
Windows 10
Configuration
No response
API Management Configuration
- What SKU is being used (as the source for extractor or destination for creator)? Developer & Consumption.
- Do you have full admin rights to the service? Yes.
- Is the service in a VNET? If so, describe how it is configured? No.
Logs
No response
Anything else?
No response
Contact Details
No response

This project is now in "maintenance" mode. This means that no new features will be accepted and fixes will be limited to security fixes. We expect to retire the DevOps Resource Kit by the end of 2023. At that time, the DevOps Resource Kit repository will be archived and there will be no further updates.
While you are free to fork the DevOps Resource Kit yourself, we recommend that you migrate to the following products:

If you are using creator, switch over to using Bicep templates. Bicep is a descriptive language for describing infrastructure, fully supports all features of Azure API Management, and is covered in any support agreement that you have with Azure. You can find bicep modules and examples for handling API Management APIs at https://github.com/azure-samples/api-management-sample-apis.
If you are using extractor, switch your pipelines to use APIOps. APIOps applies the concepts of GitOps to API deployments. It is faster and more flexible than the DevOps Resource Kit.


rustfmt deletes lines instead of detecting a syntax error

Code sample
This code sample had an error that I introduced while trying to fix a clippy error.
impl<'a, P> Iterator for NlMessageIter<'a, NlTypeWrapper, P>
where
    P: Nl + Debug,
{
    type Item = Result<Nlmsghdr<NlTypeWrapper, P>, NlError>;

    fn next(&mut self) -> Option<Self::Item> {
        if let Some(true) = self.next_is_none {
            return None;
        }

        if self.stored.is_empty() {
            match self.socket_ref.recv_all_nl() {
                Ok(mut rn) => {
                    while let Some(item) = rn.pop() {
                        self.stored.push(item)
                    }
                }
                Err(e) => return Some(Err(e)),
            }
        }
        let next = self.stored.pop();
        if let Some(ref n) = next {
            if self.next_is_none.is_some() && if !n.nl_flags.contains(&NlmF::Multi) {
                self.next_is_none = Some(true);
            }
            if n.nl_type == NlTypeWrapper::Nlmsg(Nlmsg::Done) {
                return None;
            }
        }
        next.map(Ok)
    }
}

In particular, the line:
            if self.next_is_none.is_some() && if !n.nl_flags.contains(&NlmF::Multi) {

has two ifs.
Changes made by rustfmt
This is the diff I received when I ran rustfmt:
diff --git a/src/socket.rs b/src/socket.rs
index 029c27a..c3f562d 100644
--- a/src/socket.rs
+++ b/src/socket.rs
@@ -125,11 +125,7 @@ where
         }
         let next = self.stored.pop();
         if let Some(ref n) = next {
-            if self.next_is_none.is_some() && if !n.nl_flags.contains(&NlmF::Multi) {
-                self.next_is_none = Some(true);
             }
-            if n.nl_type == NlTypeWrapper::Nlmsg(Nlmsg::Done) {
-                return None;
             }
         }
         next.map(Ok)

Expected behavior
I would hope that rustfmt would throw a syntax error instead of deleting the code. Will rustfmt typically proceed even if there is a syntax error in the code? I don't think I've ever run rustfmt on malformed code before.

what version of rustfmt are you using @jbaublitz?(rustfmt --version)

Whoops! Sorry about that. rustfmt 1.4.13-nightly (c126730 2020-03-31)

No worries! Could you try the latest version (1.4.14) and see if there's any difference in behavior?
rustfmt uses the rustc parser to get the AST for the input files, so the parsing behavior is really dependent on the version of the rustc parser that's in use by rustfmt.
If the rustc parser errors, then rustfmt will bubble that error up accordingly. However, if the parser succeeds and is able to generate the AST, then rustfmt will use that AST to determine the corresponding formatting.

Just confirmed that rustfmt 1.4.14-nightly (a5cb5d2 2020-04-14) has the same issue.

So far I'm not able to reproduce this.
Could you run rustfmt in --check mode and include the terminal output from rustfmt. (if you are running cargo fmt then run cargo fmt -- --check, or if you are running rustfmt directly then just include the --check flag)

This may be related to the other code in the module outside of the example I pasted because I am getting:
Diff in /home/jbaublitz/Source/neli/src/socket.rs at line 125:
         }
         let next = self.stored.pop();
         if let Some(ref n) = next {
-            if self.next_is_none.is_some() && if !n.nl_flags.contains(&NlmF::Multi) {
-                self.next_is_none = Some(true);
             }
-            if n.nl_type == NlTypeWrapper::Nlmsg(Nlmsg::Done) {
-                return None;
             }
         }
         next.map(Ok)

when I reapply the incorrect syntax and run cargo fmt -- --check.
The repository is https://github.com/jbaublitz/neli and it is line number 128 on the branch v0.5.0-dev (or you can view it here). I've changed the code to be syntactically correct in git but when I add the second if again, I'm able to reproduce this behavior consistently.

I've changed the code to be syntactically correct in git but when I add the second if again, I'm able to reproduce this behavior consistently.

Yikes! Thanks for the extra info @jbaublitz . I can reproduce this with cargo fmt, but not with rustfmt which is baffling :confused:
Here's things working as expected using rustfmt
$ rustc -Vv
rustc 1.44.0-nightly (7f3df5772 2020-04-16)
binary: rustc
commit-hash: 7f3df5772439eee1c512ed2eb540beef1124d236
commit-date: 2020-04-16
host: x86_64-unknown-linux-gnu
release: 1.44.0-nightly
LLVM version: 9.0

$ rustfmt --version
rustfmt 1.4.14-nightly (a5cb5d26 2020-04-14)

$ git branch
  master
* v0.5.0-dev

$ rustfmt src/socket.rs --check
error: expected `{`, found keyword `if`
   --> /home/caleb/dev/forks/neli/src/socket.rs:131:13
    |
128 | ...   if self.next_is_none.is_some() && if !n.nl_flags.contains(&NlmF::...
    |       -- this `if` expression has a condition, but no block
...
131 | ...   if n.nl_type == NlTypeWrapper::Nlmsg(Nlmsg::Done) {
    |       ^^ expected `{`
    |
help: try placing this code inside a block
    |
131 |             { if n.nl_type == NlTypeWrapper::Nlmsg(Nlmsg::Done) {
132 |                 return None;
133 |             } }
    |

but then with cargo fmt
$ cargo fmt -- --check
Diff in /home/caleb/dev/forks/neli/src/socket.rs at line 125:
         }
         let next = self.stored.pop();
         if let Some(ref n) = next {
-            if self.next_is_none.is_some() && if !n.nl_flags.contains(&NlmF::Multi) {
-                self.next_is_none = Some(true);
             }
-            if n.nl_type == NlTypeWrapper::Nlmsg(Nlmsg::Done) {
-                return None;
             }
         }
         next.map(Ok)

A few things are happening here, will some require some changes to the mod resolver/non-inline module parsing (for example no longer disabling the parse session emitter after the initial crate parsing)

@calebcartwright Excellent, thanks for looking into this! Given that I'm doing development on that branch, is it sufficient for you to keep a copy of the file/repo or do you have another suggestion?

If you're asking if we need your source input as a reference then the answer is no, go ahead and do whatever you need with it!
There's far simpler reproduction cases (basically any mod defined in an external file that has a recoverable parser error) that we'll put together as part of the test suites that'll accompany the fix for this.

@calebcartwright Is this still reproducible with rustfmt from the master branch?

@topecongiro - unfortunately yes it is. I've pushed a minimal reproducible example here where cargo fmt and rustfmt src/lib.rs --recursive will strip syntax just like described in the OP, and rustfmt src/bad.rs will fail as expected with parser error.
The problem comes from the changes made to incorporate the upstream parser/expansion changes (particularly that the parser no longer parses out-of-line mods), and I just didn't think about this use case.
The formatting/mod resolver flow is still operating as if the pre-v651 version of the parser were in use,
https://github.com/rust-lang/rustfmt/blob/a9d7cd572cc07dccab703c8ce5df4ecbd2f085d4/rustfmt-core/rustfmt-lib/src/formatting.rs#L73-L99
originally, if the parser successfully generated the AST for the crate, we were basically done with parsing, thus capturing the timing and disabling the emitter.
https://github.com/rust-lang/rustfmt/blob/a9d7cd572cc07dccab703c8ce5df4ecbd2f085d4/rustfmt-core/rustfmt-lib/src/formatting.rs#L87-L90
however, parsing of out-of-line mods is now done as needed within the mod resolver as part of building out the mod/file mapping (initial step towards #3930).
the parser is, of course, encountering a syntax error in this case, but because we've switched to a silent emitter that diagnostic message is being swallowed. And in the case of parsing a file as mod, we aren't checking the ParseSess for any parsing errors:
https://github.com/rust-lang/rustfmt/blob/a9d7cd572cc07dccab703c8ce5df4ecbd2f085d4/rustfmt-core/rustfmt-lib/src/syntux/parser.rs#L185-L192
like we do when parsing the crate mod:
https://github.com/rust-lang/rustfmt/blob/a9d7cd572cc07dccab703c8ce5df4ecbd2f085d4/rustfmt-core/rustfmt-lib/src/syntux/parser.rs#L220-L236
the mod resolver/mapping process is due for a refactor (#3930), but I'm not sure if it'd be easiest to try to fix the existing flow (by not disabling the emitter and checking for session errors when parsing the out-of-line mod files) or just go ahead with the refactor

I think we should check for session errors in parse_file_as_module and make it a hard error. cc https://github.com/rust-lang/rustfmt/issues/3989.


ByteArrayOrdinalMap growth appears to be too aggressive

I think ByteArrayOrdinalMap grows too aggressively:

Wouldn't 134217728 be the table size with a load factor of 1.0? (I haven't taken the time to look really closely at the implementation, but I'm assuming pointersAndOrdinals is just the key array).

See also #378


Boost Screen isn't skipped

Preparation

[X] I tested the latest release
[X] I looked at other issues (even the closed ones)
[X] I read the Troubleshooting Guide

FGO server
CN
FGA build number
1551
Describe the bug
it don't skip the boost screen on Imaginary Scramble event.
Video
https://youtu.be/Tm3RSkg2CkM
Device model
LGK10
Android version
7
Screen size
No response
RAM
No response

I have this same exact issue now that NA has Imaginary Scramble


Enhance Postgresql backup feature

Is your feature request related to a problem? Please describe.
When backing up a postgresql database using the Tools > Backup feature, DBeaver uses schema backup commands (-n) which does not allow for the backing up of any other database objects outside of specified schemas.
Describe the solution you'd like
To have the option to backup all database objects (not specifying -n command). Two options to handle this from a UI perspective could be to:

When no schemas are selected it executes the backup without the -n commands.
When all schemas are selected a checkbox is available to give the option to backup all database objects including objects outside of specified schemas

Additional context
Current command that runs when all schemas are selected to backup postgresql database: /Applications/Postgres.app/Contents/Versions/9.6/bin/pg_dump --format=c -n "schema1" -n "schema2" -n "schema3" -n "schema4" -n "public" -n "schema6" --verbose --host=localhost --port=5432 --username=postgres databasename
Would like the following command to run:
/Applications/Postgres.app/Contents/Versions/9.6/bin/pg_dump --format=c --verbose --host=localhost --port=5432 --username=postgres databasename

When all schemas are selected a checkbox is available to give the option to backup all database objects including objects outside of specified schemas

From the 22.3.3 DBeaver release, you can use the Global Dump tool. It dumps databases.

We are having this same issue.
I tried using the Global Backup instead, but it created a huge file that seemed to contain much more than only the selected database. So this is not a viable alternative for us.
It would be very useful to have an option to make a backup without the -n commands.

Hello @FreyaDC
You can vote for the ticket with any emoji, then.


Empty phoneNumber string

Expected behaviour
Phone number field should give a valid data
Actual behaviour
Phone number field is emply
I'm seeing this behaviour on

[ ] iOS device
[ ] iOS simulator
[X] Android device
[ ] Android emulator

I am using

[ ] cordova
[X] ionic
[ ] PhoneGap
[ ] PhoneGap Developer App
[ ] Intel XDK
[ ] Intel App Preview
[ ] Telerik
[ ] Other:

Hardware models
Samsung Galaxy J7
OS versions
Android 8.1.0
I've checked these

[X] It happens on a fresh Cordova CLI project as well.
[X] I'm waiting for deviceready to fire.
[X] My JavaScript has no errors (window.onerror catches nothing).
[X] I'm using the latest cordova library, Android SDK, Xcode, etc.

So how can we reproduce this?
Create Ionic/ng project
npm install cordova-plugin-sim
npm install @ionic-native/sim
add Sim to the provider list in app.module.ts
Inject Sim in the constructor of any module (ie: app.component.ts)
add something like
this.Sim.requestReadPermission().then(       () => console.log('Permission granted'),       () => console.log('Permission denied')     ); ...     this.Sim.getSimInfo()     .then(       info => {         console.log(info);       }     )
ionic build
ionic cap add android
run android studio son gradle does its magic
ionic cap run android -l --host=<IP_ADDRESS>
That info object will have its phoneNumber field as an empty string

I am facing the same issue any suggestion please ?


Problem reaching the app - error shown when navigating to bot personal app

There is an ongoing issue in Teams that is causing some users to see an error ("There was a problem reaching the app") when navigating to the bot personal app from flyout. The fix has started rolling out to all users and is expected to finish rollout by early next week unless some unforeseen issues are encountered (ETA Oct 11).
Creating and pinning this issue for awareness.
Screenshot of the error:

Note that the compose box is functional and the messages can be sent and received.

Suggested workarounds for this issue: utilizing the app in web browser or in mobile Teams client.

same.

Same here. Looking for the solution soon. Thank you

There is an ongoing issue in Teams that is causing some users to see an error ("There was a problem reaching the app") when navigating to the bot personal app from flyout. The fix is expected to begin rolling out on October 4th and reach 100% by October 8th.
Creating and pinning this issue for awareness.
Screenshot of the error:
Note that the compose box is functional and the messages can be sent and received.

Hello, is there any official Microsoft document or statement regarding this? There is no confirmation available anywhere about when the fix is available?

Same here. Looking for the solution soon. Thank you

Do you know if there is any official Microsoft update on this? I don't think the correct updates are provided on this page

I just opened a ticket.

I just opened a ticket.

Do you have the ticket number from Microsoft

I've only gotten to the part where they make me do all the work and do not read my ticket.

Hi Mark, Hope you are doing well. My name is Chirag Dhamija and I am the support engineer from Microsoft 365 Support. I have assumed ownership of the case: 27776213
As per the description in the ticket, you are unable to connect to Teams and getting 'Unable to reach this app' error. If that is correct can you please provide the following details so I can get more information and better assist you on this ticket.

When was the issue first reported?
How many users are affected or experiencing the issue?
Is this on a cloud environment or hybrid environment?
Are any other office apps giving the same error too?
Are you able to access Teams online and if it is just the desktop app having issues?
Has any troubleshooting been done so far?
At what point does the error come up, after signing or right after starting the app?

Bug still here

I've only gotten to the part where they make me do all the work and do not read my ticket.

Hi Mark, Hope you are doing well. My name is Chirag Dhamija and I am the support engineer from Microsoft 365 Support. I have assumed ownership of the case: 27776213
As per the description in the ticket, you are unable to connect to Teams and getting 'Unable to reach this app' error. If that is correct can you please provide the following details so I can get more information and better assist you on this ticket.

When was the issue first reported?
How many users are affected or experiencing the issue?
Is this on a cloud environment or hybrid environment?
Are any other office apps giving the same error too?
Are you able to access Teams online and if it is just the desktop app having issues?
Has any troubleshooting been done so far?
At what point does the error come up, after signing or right after starting the app?

I dont blame them. The agents are doing their job and the best they can. They are providing us the information they have and can't do anything more. And as far these questions are concerned i don't see anything wrong with it, its their job to ask the questions to determine the root cause and if we submit a ticket we should be also ready to help them in order to receive the assistance.

I think we still got the problem, I already restarted my Teams Dekstop. but it just won't get away. Maybe in our country, the update is still not rolled up?  We are in SEA Region Indonesia.

@Bizjes - Thanks a lot for confirmation.

What should be the users actions after the fix will be applied? Update Teams client / Restart Teams or relogin? Or the issue should be gone without any extra actions?

The fix has just finished rolling to 100% of production. Teams desktop client will automatically pull the latest build after a period of inactivity, but you can also try doing Check for updates.
Please do not hesitate to reach out to us here on GitHub if you encounter any other issues while developing and running your apps.

Yeah, still not working.  Again, the error message is gone but the rendering is still messed up.  The two  happened at the same time so I assumed that they were related.   Do you have another tracker that we can follow the rendering fix?

@rchardin , @mboywang can you please open new issues on GitHub with the behavior you are observing? If possible, please provide a sample JSON to speed up the investigation.

@Bizjes - Microsoft Teams platform engineering team confirmed that fix is rolled out 100%. Could you please update your desktop client using "Check for updates" option? If you are still facing this issue please share your Teams client version.

We got confirmation that the fix was deployed. Our customer also confirmed this.


gcc4.7 build error

I tried to build duktape on a 32bit machine with g++-4.7 (as part of a c++ project)
Unfortunatly I couldnt build it because it complains about size_t being to small.
The  full error message was this:
duktape.h:1171:2: error: #error size_t is too small

I solved the problem by inserting this in the duktape header (its from stdint.h from gcc-4.8.2):
/* Limit of `size_t' type.  */
# if __WORDSIZE == 64
#  define SIZE_MAX<PHONE_NUMBER>3709551615UL)
# else
#  define SIZE_MAX<PHONE_NUMBER>U)
# endif

There was another toolchain where the SIZE_MAX constant was for a signed type (0x7ffffffff which is incorrect). The #error for SIZE_MAX check was removed because Duktape only needs SIZE_MAX for a few asserts.
Could you check if you get the same issue on master, e.g. http://duktape.org/snapshots/duktape-1.0.99-20150109053002-v1.0.0-435-g8ffa3da.tar.xz ?


add warp to target block for parachains

This PR is the first part of a 3 part PR to Substrate,Polkadot and Cumulus to address https://github.com/paritytech/cumulus/issues/1619
The goal of the PR is to enable warp sync support for parachains and is done by passing an enum WarpSyncParams that lets ChainSync start the warp sync to a target block
polkadot companion: https://github.com/paritytech/polkadot/pull/6334
cumulus companion: https://github.com/paritytech/cumulus/pull/1909

The CI pipeline was cancelled due to failure one of the required jobs.
Job name: cargo-check-each-crate
Logs: https://gitlab.parity.io/parity/mirrors/substrate/-/jobs/2076665

I think the failure is due to the fact that we need to do a PR into both Polkadot and Cumulus to apply the new changes.
How are these interdependencies managed? I am assuming PRs need to go into substrate first before making the changes downstream?

You need to add a polkadot companion: https://github.com/paritytech/substrate/blob/master/docs/CONTRIBUTING.adoc#updating-polkadot-as-well

The CI pipeline was cancelled due to failure one of the required jobs.
Job name: cargo-check-each-crate
Logs: https://gitlab.parity.io/parity/mirrors/substrate/-/jobs/2078012

@altonen is there something wrong with the CI server? Running the same commands passes locally
The below error leads me to believe there might be missing dependencies in the CI node?
            clang: error: linker command failed with exit code 1 (use -v to see invocation)

Is there a way for me to kick off the build without new commits?

The CI pipeline was cancelled due to failure one of the required jobs.
Job name: cargo-check-each-crate
Logs: https://gitlab.parity.io/parity/mirrors/substrate/-/jobs/2078170

The CI pipeline was cancelled due to failure one of the required jobs.
Job name: cargo-check-each-crate
Logs: https://gitlab.parity.io/parity/mirrors/substrate/-/jobs/2078367

The CI pipeline was cancelled due to failure one of the required jobs.
Job name: cargo-check-each-crate
Logs: https://gitlab.parity.io/parity/mirrors/substrate/-/jobs/2079362

The CI pipeline was cancelled due to failure one of the required jobs.
Job name: cargo-check-each-crate
Logs: https://gitlab.parity.io/parity/mirrors/substrate/-/jobs/2081326

The CI pipeline was cancelled due to failure one of the required jobs.
Job name: cargo-check-each-crate
Logs: https://gitlab.parity.io/parity/mirrors/substrate/-/jobs/2082286

The CI pipeline was cancelled due to failure one of the required jobs.
Job name: cargo-check-each-crate
Logs: https://gitlab.parity.io/parity/mirrors/substrate/-/jobs/2082604

Hi Everyone, let me know if there are any more changes that are required on this pr

Could you write some tests for this?

@altonen I spoke to @bkchr who kindly suggested I use the config to test. Let me know if the added test is acceptable

The CI pipeline was cancelled due to failure one of the required jobs.
Job name: cargo-check-benches
Logs: https://gitlab.parity.io/parity/mirrors/substrate/-/jobs/2132170

The CI pipeline was cancelled due to failure one of the required jobs.
Job name: cargo-check-benches
Logs: https://gitlab.parity.io/parity/mirrors/substrate/-/jobs/2132312

The CI pipeline was cancelled due to failure one of the required jobs.
Job name: cargo-check-benches
Logs: https://gitlab.parity.io/parity/mirrors/substrate/-/jobs/2132355

I don't know how interesting that test this, maybe others can chime in. Maybe they would make more sense on cumulus side, proving that parachain warp sync works.

I don't know how interesting that test this, maybe others can chime in. Maybe they would make more sense on cumulus side, proving that parachain warp sync works.

Yeah on the substrate side we are just reusing the target block functionality, the current test ensures that the flow works when we are using WaitForTarget rather than WithProvider
You are correct that it makes more sense on the parachain side. There is also a test on the cumulus side to verify

The CI pipeline was cancelled due to failure one of the required jobs.
Job name: cargo-check-benches
Logs: https://gitlab.parity.io/parity/mirrors/substrate/-/jobs/2159630

The CI pipeline was cancelled due to failure one of the required jobs.
Job name: test-linux-stable
Logs: https://gitlab.parity.io/parity/mirrors/substrate/-/jobs/2159817

The CI pipeline was cancelled due to failure one of the required jobs.
Job name: test-linux-stable
Logs: https://gitlab.parity.io/parity/mirrors/substrate/-/jobs/2159866

The CI pipeline was cancelled due to failure one of the required jobs.
Job name: test-linux-stable
Logs: https://gitlab.parity.io/parity/mirrors/substrate/-/jobs/2163928

@bkchr @arkpar perhaps you can help with this
I got to the bottom of why the parachain was stuck on Importing state
It's because the verification of the authorities fail
Verifying 538(0xd6eb…a3b4) failed: Could not fetch authorities at 0x1b16dde459a4bc96742d24694c09f8b386ed5a7c43c7d17cca4d94c1512edd6d: Current state of blockchain has invalid authorities set

Given we skipped the authorities for parachain warp sync, is there a simple way of skipping the verification?

There should not be any calls to authorities when importing state data. Where does it originate from?

There should not be any calls to authorities when importing state data. Where does it originate from?

After the sync completes, a call is made to on_blocks_processed which iterates over the results
The normal warp_sync goes here too but we then switch the sync mode to full and restart the process
https://github.com/paritytech/substrate/blob/HEAD/client/network/sync/src/lib.rs#L2770-L2778
However, with the parachain warp sync there are no authorities so the import fails the verification
https://github.com/paritytech/substrate/blob/HEAD/client/consensus/common/src/import_queue.rs#L331-L348

This should do it: https://github.com/paritytech/substrate/pull/13058

This should do it: #13058

Thanks Basti, you are awesome!
Although that fixed it and the chain is now producing blocks, we are still getting a few errors. I will post them on the pr you raised

The CI pipeline was cancelled due to failure one of the required jobs.
Job name: test-linux-stable
Logs: https://gitlab.parity.io/parity/mirrors/substrate/-/jobs/2263385

@samelamin please revert c0ecb220d66dd8e7b1a5ee29831b776f4f18d024. This was a bad idea by me. Your current implementation would not work and I think for now we don't need this. Can you please also stop using force pushes, this destroys github reviews.

/tip big

@samelamin please revert c0ecb220d66dd8e7b1a5ee29831b776f4f18d024

reverted

@samelamin please add your polkadot address to get some tip.

@samelamin please add your polkadot address to get some tip.

added now

The CI pipeline was cancelled due to failure one of the required jobs.
Job name: test-linux-stable
Logs: https://gitlab.parity.io/parity/mirrors/substrate/-/jobs/2365613

The CI pipeline was cancelled due to failure one of the required jobs.
Job name: cargo-check-benches
Logs: https://gitlab.parity.io/parity/mirrors/substrate/-/jobs/2381996

The CI pipeline was cancelled due to failure one of the required jobs.
Job name: test-linux-stable
Logs: https://gitlab.parity.io/parity/mirrors/substrate/-/jobs/2383630

@bkchr apologies, there is something weird happening with my merging, I am going to attempt to revert all commits the since i first merged master and start over

bot merge

bot merge

/tip big

/tip large


replace unittest dependency by test

According to the unittest documentation unittest has been deprecated and replaced by 'test'.
In my project I use test and cannot use junitconfiguration as a result :disappointed:

I looked at this recently. The problem is that test does not support the necessary callbacks for a custom output format as provided by this package. We will have to see, if the file format could be integrated into the official package instead.

Marking as obsolete, this package is no longer in use.


Cuevana

Source name
Cuevana
Source link
ww1.cuevana3.me
Language
Español
Other details
No response
Acknowledgements

[X] I have searched the existing issues and this is a new ticket, NOT a duplicate or related to another open issue.
[X] I have written a title with source name.
[X] I have checked that the extension does not already exist on the website extensions list or the app.
[X] I have checked that the extension does not already exist by searching the GitHub repository and verified it does not appear in the code base.
[X] I will fill out all of the requested information in this form.

#580 #565 Extension cave is already found, it would be good if you closed those requests.
Ya se encuentra cuevana de extensión, sería bueno que esas mismas peticiones que hiciste las cerraras:)


Added Testimonial Page and Form

Related Issues #434
-I have designed a testimonial section  and created a testimonial form for our website. This pull request adds the necessary HTML, CSS, and JavaScript code to implement the testimonial functionality.
Changes Made

Created a new testimonial section with HTML and CSS,Bootstrap.
Added JavaScript functionality to dynamically display testimonials in cards.
Implemented a testimonial form that captures user input.
Created an API endpoint on the server to receive and store testimonial data.
Updated the necessary routes and handlers to handle testimonial requests.

Additional Information

Any additional information or context

Checklist

[x] Tests
[x] Translations
[x] Documentations

Screenshots

See the Video
https://github.com/Opentek-Org/opentek/assets/85815172/51c35615-852b-46dd-b1f2-349cc2d8f10d
@AnirudhPanda ,please review and merge

@AnirudhPanda ,please review and merge my pull request

also, is the add testimonial fully functional?

@sunny0625 check this PR

also, is the add testimonial fully functional?

yes it is full functional see video ,i have shown demo

the add button one?
On Tue, Jul 11, 2023 at 4:28 PM Nishitbariya @.***>
wrote:

also, is the add testimonial fully functional?
yes it is full functional see video ,i have shown demo
—
Reply to this email directly, view it on GitHub
https://github.com/Opentek-Org/opentek/pull/444#issuecomment-1630611921,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/APZGUAAOU7ME3WUOP4L4D3DXPUWTRANCNFSM6AAAAAA2FAETFQ
.
You are receiving this because you were mentioned.Message ID:
@.***>

--
Thanks and Regards,
Anirudh Panda

the add button one?
…
On Tue, Jul 11, 2023 at 4:28 PM Nishitbariya @.> wrote: also, is the add testimonial fully functional? yes it is full functional see video ,i have shown demo — Reply to this email directly, view it on GitHub <#444 (comment)>, or unsubscribe https://github.com/notifications/unsubscribe-auth/APZGUAAOU7ME3WUOP4L4D3DXPUWTRANCNFSM6AAAAAA2FAETFQ . You are receiving this because you were mentioned.Message ID: @.>
-- Thanks and Regards, Anirudh Panda

yes adding testimonial functionality is working ,in video i have shown by adding testimonial

it does not seem to work!!
make a detailed video please
On Tue, Jul 11, 2023 at 4:32 PM Nishitbariya @.***>
wrote:

the add button one?
… <#m_2307669561207328261_>
On Tue, Jul 11, 2023 at 4:28 PM Nishitbariya @.> wrote: also, is the
add testimonial fully functional? yes it is full functional see video ,i
have shown demo — Reply to this email directly, view it on GitHub <#444
(comment)
https://github.com/Opentek-Org/opentek/pull/444#issuecomment-1630611921>,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/APZGUAAOU7ME3WUOP4L4D3DXPUWTRANCNFSM6AAAAAA2FAETFQ
https://github.com/notifications/unsubscribe-auth/APZGUAAOU7ME3WUOP4L4D3DXPUWTRANCNFSM6AAAAAA2FAETFQ
. You are receiving this because you were mentioned.Message ID: @.>
-- Thanks and Regards, Anirudh Panda
yes adding testimonial functionality is working ,in video i have shown by
adding testimonial
—
Reply to this email directly, view it on GitHub
https://github.com/Opentek-Org/opentek/pull/444#issuecomment-1630618626,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/APZGUAEJEF5FTBLR67LM7MDXPUXF5ANCNFSM6AAAAAA2FAETFQ
.
You are receiving this because you were mentioned.Message ID:
@.***>

--
Thanks and Regards,
Anirudh Panda

@AnirudhPanda ,You have to refresh and you can see your cards:

check this
https://github.com/Opentek-Org/opentek/assets/85815172/c0ccda42-bcd1-427c-9f7f-9135dcfdb21a

@AnirudhPanda ,     check this
PassFab20230711_170025262.mp4

@AnirudhPanda ,please review and merge

I have updated Validation for URL and Rating ( it should between 1 and 5) and also added respected Alerts and also page refreshes after successfully Added

update me once it's all done man!!
great going @Nishitbaria

@AnirudhPanda ,I have updated ,please review and merge pull request

the URL is a valid URL - https://avatars.githubusercontent.com/u/66218496?v=4

https://avatars.githubusercontent.com/u/66218496?v=4

The previous URL validation was not for link with params like ?v=4
So i have updated now

Okay, so when we add a testimonial it gets written in paste.js? So if we want to remove the testimonial we can remove it? Like SPAM etc? or else can we do an email validation too to ensure only one testimonial per person? Maybe in another PR

@AnirudhPanda  It is saved in mongo db database ,Yes i will create issue for email validation to remove spam  ,please merge this and I will start working on that

It is saved in mongo db database

how can I use it to remove a testimonial? Any collab access there?

@AnirudhPanda ,In upcoming issues i will make route to delete testimonial by that functionality you can delete and if you want access to database,i will tell you how to create MongoDB database andhave access to it using MongoDB atlas

okay cool. SO merging this PR just clear all the testimonials we have currently

okay cool. SO merging this PR just clear all the testimonials we have currently

@AnirudhPanda  Done

okay cool. SO merging this PR just clear all the testimonials we have currently

@AnirudhPanda Done

Hey @AnirudhPanda   I will Creating new Pr in 5min please also Review it :)

okay cool. SO merging this PR just clear all the testimonials we have currently

@AnirudhPanda Done

Hey @AnirudhPanda I will Creating new Pr in 5min please also Review it :)

sure


Unlisten to key events in ol.Map#disposeInternal

Something like:
this.keyHandlerKeys_.forEach(ol.events.unlistenByKey);
this.keyHandlerKeys_ = null;

Could also call this.setTarget(null), which would cause the keys to be unregistered as well.

yes, it's a better solution


FEATURE REQUEST: Display S.M.A.R.T status of the harddrives

Description
In the summary data show a indicator of the health of the hard drives, one by one or at least a red flag to check for the non-healthy ones

Outta scope. We simply wrap df. There's no portable way (even df usage requires we jump through hoops).
The config is a shell script. You can make neofetch display whatever you like.
https://github.com/dylanaraps/neofetch/wiki/Customizing-Info


Lemonbuddy crashed on click of a custom script.

I have a custom scrip as follows
[module/dropbox]
type = custom/script
exec = echo "%{A1:command}script%{A}"
format-underline = #458588
interval=10
Clicking on this crashes lemonbuddy, after which killing it is the only option.

Can you post your full config

Sure thing. This is a tiny script I wrote to indicate the status of dropbox
#!/bin/bash
#Dropbox Status outputs
#Dropbox isn't enabled : "Dropbox"
#Dropbox is startin: "Starting..."
#Dropbox is Syncing: "Syncing ..."
#Dropbox is running: "Up to date..."
STATUS="$(echo `dropbox status` | awk '{print $1;}')"
C_status=#fbf1c7
DROPBOX_ICON=""
if [[ $STATUS == *"Dropbox"* ]]; then
  C_status=#fb4934
elif [[ $STATUS == *"Starting"* ]]; then
  #statements
  ICON=
elif [[ $STATUS == *"Syncing"* ]]; then
  DROPBOX_ICON=
else
  I=1
fi
echo "%{F$C_status}$DROPBOX_ICON%{F}$ICON"
#echo "%{A:dropbox start}$DROPBOX_ICON $ICON%{A}"

The commented echo is what crashes the bar, and I intended on making the click action on the icon one that triggers dropbox
The module in my lemonbuddy config is as follows.
[module/dropbox]
type = custom/script
exec = echo "`~/github/Scripts/dropboxStatus.sh`"
format-underline = #458588
interval=5

As a side note, I think the wiki should have something about clickable buttons, I am completely new to this so I am horrendously lost.

You are missing the closing colon of the %{A} tag. The correct syntax is:
%{A:command:}....%{A}

And also the foreground color reset should be:
%{F-}

You are right about the wiki. Input like this is really helpful since it's hard for me to know how it is for new users.

Of course the invalid tags should not crash the bar so that will need to be fixed.

I also want to add a hint about the button handlers available for the custom/script module. Info on the wiki.

Now I've gone ahead and replaced the %{A} tags to the button handlers instead. Here is the code for it
#!/bin/bash
#Dropbox Status outputs
#Dropbox isn't enabled : "Dropbox"
#Dropbox is startin: "Starting..."
#Dropbox is Syncing: "Syncing ..."
#Dropbox is running: "Up to date..."
STATUS="$(echo `dropbox status` | awk '{print $1;}')"
C_status=#fbf1c7
DROPBOX_ICON=""
if [[ $STATUS == *"Dropbox"* ]]; then
  C_status=#ec644b
elif [[ $STATUS == *"Starting"* ]]; then
  #statements
  ICON=
elif [[ $STATUS == *"Syncing"* ]]; then
  DROPBOX_ICON=
else
  I=1
fi
echo "%{F$C_status}$DROPBOX_ICON%{-F} $ICON"

The module in lemonbar's config file looks as follows

[module/dropbox]
type = custom/script
exec = ~/github/Scripts/dropboxStatus.sh
format-underline = #458588
click-left = dropbox start
interval=2
format-padding = 2

The bar still crashes on a click.

I will test the script and get back to you

Try replace I=1 in the else with exit. Fixes it for me.
I don't know why the bar hangs, but but I'll look into it.

The whole script works fine as it is, dropbox launches accordingly, but the bar crashes and does not update any further. Thanks for looking into this

I found a bug that caused the execution to be blocked while the sub process was running. Please verify that it's fixed.

Whew! Works like a charm now!

Great! Please report any other issues you encounter.

Any chance you integrate this module ?

@blackbart420 it's a custom/script so you can use whatever @g-suraj posted here.


fix(adminmonitor): fix a data race in a unit test EE-2714

Closes https://github.com/portainer/portainer/issues/6677


fix: Add advisor plugins to the plugin classpath for distribution

Without this, building the distribution would not necessarily build the advisor plugins.

@nnobelis, this should fix your issue.


Can I make it a little bit less strict by using options?

I want to switch some of the errors to warnings:
For example, I'm trying to do something like this, and it is not working:
"standard.options": {
        "rules": {
            "no-unused-vars": "warn"
        }
    }

No, You can't. Please check it here.

You can't change anything about JavaScript Standard Style, that would kind of defeat the purpose, but it is possible to change the parser that standard uses internally to something else, so that you can use decorators and other things that aren't necessarily part of the Standard style.
https://github.com/feross/standard/issues/106#issuecomment-106883572
This allows you to use decorators and other things not understood by standard by default. I don't think this extension will support it though.


[Bug] long delay before entering <to_edi_normal> using map

About Bug
I switch to normal using the the  key. Here's the mapping in .vindrc when in INSERT more:
inoremap <insert> <to_edi_normal>

-- but the response time is very slow, about 1sec.
When I do the opposite operation:
ennoremap <esc> <to_resident>

-- the response time is very fast.
Any reason for the difference and how to fix this?
This is in vind v<IP_ADDRESS>
Thanks!!
Environments
Edition	Windows 10 Pro
Version	21H2
Installed on	3/13/2021
OS build	19044.2728
Experience	Windows Feature Experience Pack 120.2212.4190.0

@gilbh
Perhaps it is the autofocus_textarea option. When this option is enabled, the input area near the mouse is automatically focused after UI scanning when entering Edi Normal.
If you want to use this feature without any delays, consider using uiacachebuild.

I think this solved it. Thanks!


How to run this ffmpeg command through PHP-FFMpeg

Q
A

Bug?
no

New Feature?
no

Version Used
0.9.0

FFmpeg Version
FFmpeg 3.2.4

OS
macOS 10.12

I've been trying to convert .gif to .mp4 and it works with below code:
$ffmpeg = FFMpeg\FFMpeg::create();
$video = $ffmpeg->open('animated.gif');
$video->save(new FFMpeg\Format\Video\X264(), 'export-x264.mp4');

But the converted file doesn't play in browsers. I've found this ffmpeg ssh command that works great (the converted file does work in browsers) but I have no idea how to do it with package. Here is command:
ffmpeg -i animated.gif -movflags faststart -pix_fmt yuv420p -vf "scale=trunc(iw/2)*2:trunc(ih/2)*2" video.mp4

Thank you for your great package BTW.

Hi!
$format->setAdditionalParameters(array('foo', 'bar')); may help you.

Thanks man, that did the trick


Handle invalid inputs for find command

Fixes #148

Codecov Report
All modified and coverable lines are covered by tests :white_check_mark:

Files with missing lines
Coverage Δ
Complexity Δ

.../seedu/address/logic/parser/FindCommandParser.java
100.00% <100.00%> (ø)
9.00 <0.00> (+4.00)


Exception: Cannot read property 'replacements' of undefined

I can't use this package. I just installed it and used the helper in my template. I only get this exception logged to console:
Exception in template helper: TypeError: Cannot read property 'replacements' of undefined

I did not set any custom emoticons, I'm just using out-of-the-box installation.

Sorry, just saw this today. I've fixed it in version 0.0.4

Cool thx


USB Port Access

Hi,
I appreciate the effort that you gave while developing the code and everything is well explainable, but actually i am new with jtag as well as rpi pico, so after loading the uf2 file in the pico i lost the usb access to my laptop, so can you please help me with that .Also will i be needing to connect any jtag device on the other hand, currently i am using the analyzer to observe the jtag frames but even after writting to the buffer i am not able to see the frames, so also if some help with this is possible it will mean a lot.
Thanks
Devanshu

Hi,
What do you mean by "losing USB access" to your laptop? Do you mean that the USB controller got "borked" right after flashing DirtyJTAG?
If so, could you provide us with your hardware configuration (laptop model, operating system, etc.) and if possible any dmesg output happening after programming your RPi Pico?
Thanks,
Jean.

Hi,
Yes I think that usb controller is getting break basically, I want to make the message to get printed using the usb and also to communicate continuously with the rpi pico also after flashing it with the dirtyJTAG.
Hardware Details:
laptop model : dell latitude 5420
operating system : Linux (on windows)
Also can please give me some advice on the second part regarding the "Also will i be needing to connect any jtag device on the other hand? , currently i am using the analyzer to observe the jtag frames but even after writting to the buffer i am not able to see the frames, so also if some help with this is possible it will mean a lot."
DMESG

Thanks

@DevanshuGajjar: sorry about your problems. Are you using wsl2? As far as I know only COM and mounted mass storage will be forwarded to wsl from the host(Windows). DirtyJtag USB interfaces will not be visible or accessible by wsl2.
My advice would be to plug the rp board and look at the windows device manager to see if you see  a DirtyJtag in the "other devices" category. You know you must use Zadig to change the driver for DirtyJtag to WinUSB, right?
The other thing I want to ask is this: If you press the boot button while you connect your rp board, do you see the mass storage in Windows (and also in wsl?) This part is handled in the rp internal ROM so it still should work.
About observing some JTAG frames: You don't need a device. For example if you use OpenFPGALoader --detect -c dirtyJtag you will see quite a few JTAG frames (CLK, TMS, TDI)

@phdussud the problem was resolved, Thanks for your support. Actually I wanted to make Jtag Debugger so is there anyway to use your repo for the same? I am trying with bit banging, I am able to create the fsm but the data and the clocks are not synchronizing. Can you please guide me on same ?

If you want to use it as a debugger, check out my clone of openocd

I am closing this issue as it seems to be resolved


Add option to pass in own client factory

This adds support for passing in a client factory instead of connection details. This makes it possible to manage your own client, and use alternative clients such as ioredis.

LGTM


Training with recurrent cells from keras

Just in case anybody is interested, here is some example code that implements a policy based on the recurrent cells in tensorflow.python.keras.layers.
Pros:

Tested with SimpleRNNCell, LSTMCell and GRUCell.
It can work with other recurrent cells you implement for keras in the future.
It supports training the initial state of the network as suggested here.

Cons:

In my tests it was only half as fast (in terms of fps) as the LSTM implementation we have now (without layer normalization).
The unrolled version is slightly faster than the one using a tf.while_loop.
Uses hack to circumvent the LstmPolicy constructor (PPO2 forces us to inherit from LstmPolicy)
Uses hack to make shared variables between run and train network happen. The keras layers framework and our way of setting up shared models totally do not work together at all.

 I put lots of work in it. Maybe it is a starting point for something else.
I am thinking about putting it in the custom models section of the documentation. What do you guys think?
import numpy as np

import tensorflow as tf
from stable_baselines.a2c.utils import linear
from stable_baselines.common.policies import register_policy, LstmPolicy
from tensorflow.python.keras.layers import SimpleRNNCell, LSTMCell, GRUCell

def batch_to_seq(tensor_batch, n_batch, n_steps):
    return tf.unstack(tf.transpose(tf.reshape(tensor_batch, [n_batch, n_steps, -1]), [1, 0, 2]))

def batch_to_ta(tensor_batch, n_batch, n_steps):
    return tf.TensorArray(tf.float32, size=n_steps, dynamic_size=False).unstack(tf.transpose(tf.reshape(tensor_batch, [n_batch, n_steps, -1]), [1, 0, 2]))

def seq_to_batch(tensor_sequence):
    shape = tensor_sequence[0].get_shape().as_list()
    assert len(shape) > 1
    n_hidden = tensor_sequence[0].get_shape()[-1].value
    return tf.reshape(tf.concat(axis=1, values=tensor_sequence), [-1, n_hidden])

def ta_to_batch(tensor_array):
    return tf.reshape(tensor_array.stack(), [-1, 128])

class RecurrentPolicy(LstmPolicy):
    rnn_cell = None

    def __init__(self, sess, ob_space, ac_space, n_env, n_steps, n_batch, n_lstm=128, reuse=False, cell_type=LSTMCell, unroll_network=True, **_kwargs):
        super(LstmPolicy, self).__init__(sess, ob_space, ac_space, n_env, n_steps, n_batch, reuse,
                                         scale=False)

        act_fun = tf.nn.relu

        if RecurrentPolicy.rnn_cell is None and not reuse:
            with tf.variable_scope("model", reuse=True):
                RecurrentPolicy.rnn_cell = cell_type(n_lstm, name="lstm1")
        cell_state_size = RecurrentPolicy.rnn_cell.state_size
        if isinstance(cell_state_size, int):
            cell_state_size = [cell_state_size]

        with tf.variable_scope("input", reuse=True):
            self.masks_ph = tf.placeholder(tf.float32, [n_batch], name="masks_ph")
            self.states_ph = tf.placeholder(tf.float32, [n_env, sum(cell_state_size)], name="states_ph")

        with tf.variable_scope("model", reuse=reuse):

            initial_state = tf.get_variable(RecurrentPolicy.rnn_cell.get_initial_state(batch_size=n_env, dtype=tf.float32))
            # build shared network part consisting of parallel lstm and linear layer
            latent = tf.layers.flatten(self.processed_obs)
            state = tf.split(self.states_ph, cell_state_size, axis=1)

            if unroll_network:
                rnn_outputs = []
                masks = batch_to_seq(self.masks_ph, self.n_env, n_steps)
                input_sequence = batch_to_seq(latent, self.n_env, n_steps)
                with tf.variable_scope("my_lstm_scope"):
                    for mask, input in zip(masks, input_sequence):
                        state = mask * initial_state + (1 - mask) * state
                        output, state = RecurrentPolicy.rnn_cell(input, state)
                        rnn_outputs.append(output)
                latent = seq_to_batch(rnn_outputs)
            else:
                input_ta = batch_to_ta(latent, self.n_env, n_steps)
                mask_ta = batch_to_ta(self.masks_ph, self.n_env, n_steps)
                output_ta = tf.TensorArray(tf.float32, size=n_steps, dynamic_size=False)

                def loop_cond(idx, state, input_ta):
                    return idx < input_ta.size()

                def loop_body(idx, state, output_ta):
                    mask = mask_ta.read(idx)
                    input = input_ta.read(idx)
                    state = mask * initial_state + (1 - mask) * state
                    output, state = RecurrentPolicy.rnn_cell(input, state)
                    output_ta = output_ta.write(idx, output)
                    return idx+1, state, output_ta

                idx, state, output_ta = tf.while_loop(loop_cond, loop_body, (0, state, output_ta))
                latent = ta_to_batch(output_ta)

            self.snew = tf.concat(state, axis=1)

            # build deeper value network part
            latent_value = act_fun(linear(latent, "vf_fc1", 128, init_scale=np.sqrt(2)))
            latent_value = act_fun(linear(latent_value, "vf_fc2", 256, init_scale=np.sqrt(2)))

            self.value_fn = linear(latent_value, 'vf', 1)
            self.proba_distribution, self.policy, self.q_value = \
                self.pdtype.proba_distribution_from_latent(latent, latent_value)
        self.initial_state = np.zeros(self.states_ph.shape.as_list(), dtype=np.float32)
        self._setup_init()

register_policy("RecurrentPolicy", RecurrentPolicy)

I am thinking about putting it in the custom models section of the documentation. What do you guys think?

It seems quite advance to put it in the user guide. Or maybe in a new "advanced" section?
However, a simple example of using custom Keras policy could be a could idea (for instance a MlpPolicy).

Yes maybe there can be an advanced section. But I remember the above example to be somewhat buggy. So we can not just plain copy paste. We need to test it again first.


Revert bogus change to Armenian

This serves as a test of the CI setup.

Hmm, fontdiff should have returned a non-zero exit status in the latest Travis build. But I'm merging anyways. Can investigate more later.


Environment variables support for config file locations

Hello,
can you support environment variables like the following one?
GTK2_RC_FILES=${XDG_CONFIG_HOME}/gtk-2.0/gtkrc-2.0

Sure, but please specify what certain issue you expect it to resolve.

Issue:
Exports gtk-2 settings to ~.gtkrc-2.0 when it should export to $XDG_CONFIG_HOME/gtk-2.0/gtkrc-2.0.


OpenIdConnectConnect should not serialize SecurityKeys

Calling: JsonConvert.SerializeObject(new OpenIdConnectConfiguration()) results in JSON that contains entries for the SecurityKeys collection. This makes it difficult to use the serialization for generating metadata for discovery.

@brentschmaltz Should JsonWebKeySet still be serialized if it's null?


fixed commenting issue with django 1.8 upgrade

This fixes the issue with commenting after upgrading to django 1.8. @mjstealey please review and merge it if it looks good. In a nutshell, we can directly use the function clean_comment() provided by django-contrib-comments 1.6.2 module without customizing that function in our code base, so the fix was just remove the customized version. I have tested it out in my local dev env and everything works after removal of this customized function, so I am positive it will just work.

Can one of the admins verify this patch?

I am positive it will just work

Ah ha, famous last words ;-)
Looks simple enough, will wait for Jenkins test to complete and then merge.


[create] allow organization standards when creating a project

First of all I think it is great that someone thought about creating standards for WC and a CLI tool to bootstrap a project applying them by default.
The problem starts when you have to create a project for your organization. Then you probably have different coding standards. This ends up using npm init @open-wc and replacing configuration files after that. Obviously an organization should afford to have own tool to do this but I would argue that @open-wc is great and is worth using it instead internal tool that will be written once and never maintained.
I would like to see a configuration option to install different modules for prettier, eslint, and  commits. Or maybe the tool would detect a globally installed module that has required configuration files that will be applied to generated project and the user selects the template in the CLI UI. I think the later is a better UX for developer than configuration option.

This would be really useful, how should the public API for this look like?

If that would be only the CLI configuration options than it would accept a name of a npm package to install instead of predefined ones. So for example instead of default prettier configuration it could be used like this:
npm inint @open-wc --prettier @other/prettier-config

and then it would create the following prettier.config.js:
module.exports = require('@other/prettier-config');

However, giving that you have to use this command each time when creating a project (which could be done by using aliases) I would try to detect a globally installed packages and suggest an appropriate option in the CLI UI.
So for example, if you have a package installed globally called open-wc-create-prettier-other
it would ask you if you want to use prettier "other" instead of default one. This package would contain the definition for the prettier in the main file. The CLI would add this package to the list of dev dependencies and generate prettier.config.js file. Similarly yo generator works when creating templates for it.

This will get really messy really fast. Personally I think it would be better to add docs on how to modify the config or create your own generator based off of this one. there are way too many variables to try to predict end-user custom configs and tooling preferences

Would be grate to reuse existing generator and extend it in some way. I was thinking about forking it but then maintaining it would be quite painful. Hence I am asking for options :)


feat: Support lifecycle ignoreChanges with module

Check for previous/existing GitHub issues

[X] I have checked for previous/existing GitHub issues

Issue Type?
Feature Request
(Optional) Module Version
0.1.0
(Optional) Correlation Id
No response
Description
As Terraform doesn't support lifecycle meta-argument with modules (see hashicorp/terraform#27360) it would be nice that module would allow ignoring some things that are (at least in our environment) handled with policies. Of course the ignore can be more generic if possible, but at least for use tags and private_dns_zone_group.

hi @Hi-Fi thanks for this, apologies for the delay getting back to you.

it would be nice that module would allow ignoring some things that are (at least in our environment) handled with policies. Of course the ignore can be more generic if possible, but at least for use tags and private_dns_zone_group.

We have recently landed a general approach for dealing with private dns zone groups in the AVM template, and I will port this across to this module.
Your comment about tags makes sense for the same reason.  @matt-FFFFFF I feel this is something we need to add to the general template - what's your thoughts on simply applying a "lifecycle ignore" to tags?

This is a pain unfortunately. The lifecycle ignore changes block cannot contain anything other than literals
So we either ignore changes for tags, or we don't. This isn't configurable by the caller.
My opinion is that we should not ignore tag changes as then we could not manage them with terraform.

We now have a solution for private dns zone groups... you can see it on the shared interface page on the AVM site (or in the key vault module)

There is a PR at https://github.com/Azure/terraform-azurerm-avm-res-containerregistry-registry/pull/81 that

We now have a solution for private dns zone groups... you can see it on the shared interface page on the AVM site (or in the key vault module)

I've created a PR at https://github.com/Azure/terraform-azurerm-avm-res-containerregistry-registry/pull/81 that implements this for the container registry module (copied from the key vault module). @matt-FFFFFF

@alefteris private DNS zone changes have been merged into v0.3.  I'll add the updates we've discussed for inheriting tags to address policy issues.  Will post a comment once that has been completed.


[MLIR][5.7] add input fusion support for view ops

This commit adds support for slice,transpose,contigous and reshape
fusions into input tensors for a fused mlir kernel.
closes : https://github.com/ROCmSoftwarePlatform/llvm-project-private/issues/864

built on top of https://github.com/ROCmSoftwarePlatform/AMDMIGraphX/pull/1678

a friendly ping! @pfultz2...
I 've rebased over other PR that got merged yesterday.