Investigate: Root newline change in snapshot update #286

Description

Investigate:

The root cause of why newlines were removed from root/targets in the snapshot update from #286
Why GitHub Actions was not triggering validate

@joshuagl @dlorenc

This is actually causing me problems in the verifier.
Before the newline was removed, the targets file had 3972 bytes. Old TUF clients (before commit https://github.com/theupdateframework/go-tuf/pull/247) cannot verify metadata with the newline:
asraa@asraa1:~/git/go-tuf$ ./tuf-client list -s /tmp/tuf.db http://localhost:8001
ERROR: tuf: unexpected file size: targets.json (expected 3971 bytes, got 3972 bytes)

The client at head CAN verify with either the newline present or removed.

Now, however, when we initialize a new root, we are adding the newline BACK. This means old clients cannot verify the change.
I'm still trying to figure out where we're using an old version of the client. I don't know why we are hitting the error.

I don't think this should be relevant anymore and we haven't seen this issue in some time. Closing.


Feature: remote sdk do not pass hard coded vector column to backend

SDK
Python
Description
We can infer vector columns from the query now. Remote SDK (Python / JS) doesn't need to code the vector column hard if users did not explicitly specify it.
ToDo

change vector_column_name to be optional for search - both OSS and remote
add tests to make sure Phalanx can accept remote search without the vector_column_name specified by the user
make sure we present clear error msgs, e.g. when there are multiple vectors but user didn't specify which one to use for search
add examples to guides

Our Python SDK is not using the Rust code in [Rust] schema coerce and vector column inference. We have https://github.com/lancedb/lancedb/issues/849 to address this.
However, in order to get LanceDB Cloud GA, we can add the infer_col to sync Python API


Unit editing selects wrong AMI chart on load

In the edit view of a listing and clicking "edit" on a unit the incorrect AMI chart is getting selected.
Listing where it's reproducible: https://partners.housingbayarea.mtc.ca.gov/listings/1be36fd5-a233-48b7-8c32-0459a0b9d576/edit
It appears that the first AMI chart is getting selected even though on the details page it shows the correct AMI chart name.
Other facts:

This unit uses an "San Mateo CTAC 2024" AMI chart and the values are updated
It is selecting "San Mateo County TCAC 2019" AMI chart
It doesn't happen 100% of the time

QA Notes
Create a listing with a unit that has an ami chart selected that is not the first chart that appears in the dropdown. Re-open the edit page and open the unit drawer and ensure the proper ami chart is selected.


HTTP errors out too often on SARA-R422M8S

Hi,
I'm having problems with HTTP both in an old version of ubxlib (80e76d49b97d8128202d5dd2a2fa9bfa2ecbc47a) that I'm using and in the current master (a97d994f59f391200b180922e7e071ad0439c045). The module I'm using is the SARA-R422M8S.
Namely, too often making HTTP requests results in -1. Too often meaning that I get more errors than successes.
http_example_error_log.txt
http_example_success_log.txt
In addition to +UHTTPER: 0,3,10, I have also observed errors like +UHTTPER: 0,10,22 and +UHTTPER: 0,3,11.
I tried to change the example to see whether retrying could help, but apprently once the HTTP client is in a state where it returns -1, it will keep returning -1.
retry_patch.txt
Tried to move the while (1) loop up, so each time it fails the HTTP profile is closed and then re-opened. Still same problem.
retry_http_reopen_patch.txt
Tried to move the while (1) loop up, so each time it fails the network is put down and turned up again (i.e. cellular connection is re-established). Does not help. Still keep getting -1 error. But then I tried to put a delay of 2 seconds after the network connection is established and it seems to mitigate the problem (stil get -1 sometimes, but it's much likely to succeed).
retry_network_reconnect_patch.txt
retry_network_reconnect_with_delay_patch.txt
Is there an explanation for this?

After further experimenting, the gist seems to be:

HTTP profile is orthogonal to cellular network connection, in the sense that it is OK to create the HTTP profile even before establishing the cellular network connection.
BUT, after establishing the cellular network connection, put a slight delay before making the first HTTP request.
If HTTP request returns -1, disconnecting and re-connecting to the cellular network is enough. No need to close and re-open the HTTP profile.

Hmph.  I will have to call in the cavalry on this one I'm afraid: there is obviously something going on inside the SARA-R422 module, something not directly visible to us, which is getting in your way.  We do test SARA-R422 in the test system here (two modules, both with FW version 00.12,A00.00) and, though the test system as a whole does sometimes see HTTP failures ('tis the internet, that's just life), I don't recall any particularly landing in the lap of SARA-R422.
The cavalry in this case are in North America so will hopefully get back to you tomorrow.

One thing I will likely be asked is what the signal strength/quality is like at your location.  Could you possible add something like the following, just before you do your HTTP request, and post what is printed-out back here?
uCellInfoRefreshRadioParameters(devHandle);
print("### RSRP %d dBm, RSRQ dB %d, SNR %d dB (EARFCN %d).\n", uCellInfoGetRsrpDbm(devHandle), uCellInfoGetRsrqDb(devHandle), uCellInfoGetSnrDb(devHandle), uCellInfoGetEarfcn(devHandle));

Sure. Will do now. Thanks for your help!

Can't draw too much conclusion as to the environment.
One thing to say is that you are on 2G, rather than LTE, so the bandwidth is going to be relatively small.  The HTTP connection seems to be an HTTPS one, so there will be certificate exchanges going on, a relatively large amount of data to transmit.
The signal strength in your logs ranges from -73 dBm down to -100 dBm (ubxlib reports the RSSI value from the AT+UCGED AT command since that is valid for all RATs, but it is also visible in the AT+CSQ command for 2G, and that shows up in your first log as -100 (113 - 13) at one point).  So it is washing around rather a lot; just the nature of RSSI measurement I'm afraid.
But whenever AT+CSQ reports a value, the value it reports is 0, which is good, and it does this in both the success and fail cases.
Cavalry time.

The same problem has been observed with plain HTTP (without TLS), so maybe we can also exclude that. Looking forward to reply from the cavalry!

Right, the cavalry says that to find out what's going on for the "internal client error" (+UHTTPER: 0, 3,10) case, which seems to form the main source of your issues, requires a diagnostic log.  Unfortunately, for the SARA-R4 module series, the tools to take such a log need an NDA, as well as access to the USB port of the SARA-R4.  Is that something you are able to deal with?  If so I can send you the NDA (contact me at rob.meades@u-blox.com).
If you don't want to go that far, they also say that +UHTTPER: 0,10,22 is only emitted if the PDP context is not active, so you could maybe call uCellNetGetIpAddressStr() before doing your HTTP thang, as that will return an error if there is no PDP context at the time, though of course there may always be a race condition.  There is also an AT command which ubxlib does not currently support, AT+CIND, which enables URCs on certain conditions (see section 5.4 of the SARA-R4 AT manual): you could maybe DIY-add that with your own callback that watches the "gprs" PS indication status, which will tell you the "live" state of the PDP context.
And, finally, +UHTTPER: 0, 3,11 can occur when there is packet loss or a server not responding or HTTP profile settings are incorrectly configured (though I see no sign of this latter).
But of course, if you are able to go down the diagnostic-logging route, it will help get true visibility for all of the above.

Hi Rob. Sorry for the delay in the reply.

Right, the cavalry says that to find out what's going on for the "internal client error" (+UHTTPER: 0,3,10) case, which seems to form the main source of your issues, requires a diagnostic log. Unfortunately, for the SARA-R4 module series, the tools to take such a log need an NDA, as well as access to the USB port of the SARA-R4. Is that something you are able to deal with? If so I can send you the NDA (contact me at rob.meades@u-blox.com).

My company should already have an NDA with ublox, I'm just trying to get it from my colleagues and that is not entirely under my control. Anyway, we don't have access to the USB port on our custom boards and the evaluation kit is also being shipped to me, so yeah, that will take a while. ASAP I get the NDA, I'll send it to you.

If you don't want to go that far, they also say that +UHTTPER: 0,10,22 is only emitted if the PDP context is not active, so you could maybe call uCellNetGetIpAddressStr() before doing your HTTP thang, as that will return an error if there is no PDP context at the time, though of course there may always be a race condition

And, finally, +UHTTPER: 0,3,11 can occur when there is packet loss or a server not responding or HTTP profile settings are incorrectly configured (though I see no sign of this latter).

In the meanwhile, I just had time to run some tests with trying to get the IP address. Here is the http example code I used
with_get_ip_address.txt
Basically, I try to get the IP address before any HTTP request and after any HTTP request error.
Here are two logs
error_0_3_11_with_no_ip_address.txt
I cannot get the IP address but the error is 0,3,11.
error_0_10_22_with_ip_address.txt
I can get the IP address but the error is 0,10,22.
I find the result quite strange, since the error codes seem to be the opposite of what you explained.

Hi @chenlijun99: I guess you probably got what you needed on this issue, and if not we have a direct channel via e-mail in any case, so I'm going to close this.  Please feel free to re-open it if you disagree.


使用got10k的测试工具报错

segmentation_dir:   /trdimp/trdimp_vot
Files already downloaded.
Running tracker GOT_Tracker on VOT...
Running supervised experiment...
--Sequence 1/60: ants1
Repetition: 1
Traceback (most recent call last):
File "GOT10k_VOT.py", line 45, in
experiment.run(tracker, visualize=False)
File "/home/admin312/anaconda3/envs/pytracking/lib/python3.7/site-packages/got10k/experiments/vot.py", line 71, in run
self.run_supervised(tracker, visualize)
File "/home/admin312/anaconda3/envs/pytracking/lib/python3.7/site-packages/got10k/experiments/vot.py", line 126, in run_supervised
tracker.init(frame, anno_rects[0])
File "GOT10k_VOT.py", line 32, in init
self.tracker.initialize(image, box)
File "../pytracking/tracker/trdimp/trdimp.py", line 55, in initialize
state = info['init_bbox']
IndexError: only integers, slices (:), ellipsis (...), numpy.newaxis (None) and integer or boolean arrays are valid indices
看上去是版本导致的错误？  请问作者有遇到过或者有修改的思路吗

To run and evaluate the tracker using GOT-10k toolkit, you have to modify the /tracker/trdimp/trdimp.py to ensure it supports the input and output formats of GOT-10k toolkit. /tracker/trdimp/trdimp_for_GOT.py is an example.


Interference notebook for this audio_classification_models

Can anyone provide interference notebook for this audio_classification_model that takes audio as input and then classify it Real or Fake.

You can check out this notebook, https://www.kaggle.com/code/awsaf49/fake-speech-detection-conformer-tf


replace flask-script with click

manage.py
# coding: utf-8

import click
import os

plugin_folder = os.path.join(os.path.dirname(__file__), 'commands')

class Manager(click.MultiCommand):

    def list_commands(self, ctx):
        rv = []
        for filename in os.listdir(plugin_folder):
            if filename.endswith('.py'):
                rv.append(filename[:-3])
        rv.sort()
        return rv

    def get_command(self, ctx, name):
        ns = {}
        fn = os.path.join(plugin_folder, name + '.py')
        with open(fn) as f:
            code = compile(f.read(), fn, 'exec')
            eval(code, ns, ns)
        return ns.get('main', ns.get('cli', ns.get('command')))

    def format_help_text(self, ctx, formatter):
        if self.help:
            #formatter.write_paragraph()
            with formatter.indentation():
                formatter.write(self.help)

if __name__ == '__main__':
    Manager(
        help="""
        Subcommands are loaded from the commands folder dynamically.
        File located in commands/<name>.py containing a click.command:

        Example:
        import click
        @click.command()
        @click.option(....)
        def main():  # name can be main, cli or command
            click.echo("Do whatever you want")

        The file name will be the command name
        """
    )()

I will try to merge this @abnerpc

@rochacbruno, can you wait so I can rebase my changes on top of current master and open a PR ?

:+1: @abnerpc
There is a lot of changes
look CONTRINUTING.md, now PRS goes to development branch.

:+1: merged with few changes


More disposable fixes

Another, but related thing, I think we should add a unit these to the memory leak. This all started with a memory leak. We could add something like this https://stackoverflow.com/a/24871092/85325. A failing test is a concrete thing to guide us.

I have added memory unit Tests, that suceed nie. Maybe although bevor these changes.

After merging this master has 33 results when searching on 'disable IDISP'.

I created a little research project and what is interesting is that this test fails:
https://github.com/pauldendulk/ResearchDispose/commit/4ef6682acf75a387130dad83e984f7f9b03edf26#diff-7a20f319ad5744f87d00ab1ec1efc602f060545b25112d2513e9c55ac7f81856R26
The test above, which seems to be equivalent, succeeds. The Map that is created here is a completely empty class with no IDispose interface. I assume the GC does not collect it because the Target field is access in the local function.

Maybe the Static Methodd need to bee decorated with a noinling Attribute.
Because with inlining the Target comes again into method scope and it ist
not Garage collected.
Paul den Dulk @.***> schrieb am Mo., 13. Dez. 2021,
8:54 AM:

I created a little research project and what is interesting is that this
test fails:
@.***
#diff-7a20f319ad5744f87d00ab1ec1efc602f060545b25112d2513e9c55ac7f81856R26
https://github.com/pauldendulk/ResearchDispose/commit/4ef6682acf75a387130dad83e984f7f9b03edf26#diff-7a20f319ad5744f87d00ab1ec1efc602f060545b25112d2513e9c55ac7f81856R26
The test above, which seems to be equivalent, succeeds. The Map that is
created here is a completely empty class with no IDispose interface. I
assume the GC does not collect it because the Target field is access in the
local function.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
https://github.com/Mapsui/Mapsui/pull/1420#issuecomment-992197319, or
unsubscribe
https://github.com/notifications/unsubscribe-auth/AARPJLZQ747M76SZ2JIVXHTUQWRCVANCNFSM5J3NWM3Q
.

Well, by putting it in a separate method it is solved as well. It is okay like this. It was a surprise to me though, that is why I mentioned it, but later I saw in your code comments you had discovered the same problem and had the same solution, so I deleted my remark.


TextField: Focus after clicking clear button (#4354)

Description

How Has This Been Tested?

Types of changes

[x] Bug fix (non-breaking change which fixes an issue)
[ ] New feature (non-breaking change which adds functionality)
[ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)

Checklist:

[x] The PR is submitted to the correct branch (dev).
[x] My code follows the code style of this project.
[x] I've added relevant tests.

Thanks, makes sense


Issues March24

Overall Review of Changes:
Issues addressed
Renaming of discovered variables
fix of typo in pam_unix config
Lint
Issue Fixes:
thanks to @bbaassssiiee

#353
#354
#359
#360
#361
#363
#364
#365

Enhancements:
quotes around mode entries
How has this been tested?:
Manually and community

#364 still needs fixing...


[Greetings] Appreciation :partying_face:

Hello! Just found out about you and all your projects :eyes: . I was looking for other Filipinos that use Julia since there is lil to no one I know of. I am glad that I found out about you :tada:
Hoping for more Filipinos to use Julia :smile:

Thank you very much, @uncomfyhalomacro! I looked into your profile as well when you started following me, and I am happy to know that you've seen the beauty of Julia as well. You are the first Filipino I know to have used Julia. 🥳  In my team of Data Scientist, most of them are either user of Python or R. Julia was first introduced to me in 2016 by a French instructor in one of my workshop in WorldBank who suggest to translate the Python code he made to Julia, since according to him it has a lot of potential, and from there I used Julia in 2017 for my Master's Thesis, and the rest is history.
Maraming Salamat, Soc! 😊

Thank you too! I hope there will be Julia in PH unis in the future and also a prospering Julia Filipino community. 🥳🥳🥳
Closing this issue as this will become noise 😄


Integrate spmd multidimensionnal views for partitioned_vectors

This PR proposes to add spmd multidimensionnal view functionalities to manage segments of partitioned_vector. The added features include:

View constructions from partitioned_vector iterators :
example: hpx::partitioned_vector_view<double,2> view (block, v.begin(), v.end(), {height,width} ), with block  being a spmd_block, v being a partitioned_vector and height and width being integral values
Put operations (in MPI sense) allowed via the expression a(i,j) = b(i,j) or  a(i,j) = some_std_vector
Get operations (in MPI sense) allowed via an explicit conversion :
std::vector<T> v = ( std::vector<T> ) a(i,j)
iterators to iterate globally (or locally) over the segments covered by the view

Inspect is unhappy with this: https://6936-4455628-gh.circle-artifacts.com/0/tmp/circle-artifacts.tnk4CwV/hpx_inspect_report.html

Documentation is in progress. But I need some documentation for partitioned_vector first to then make some increment concerning the views. The API is fully exposed in the following unit tests.

https://github.com/atrantan/hpx/blob/partitioned_vector_view/tests/unit/component/partitioned_vector_view.cpp
https://github.com/atrantan/hpx/blob/partitioned_vector_view/tests/unit/component/partitioned_vector_subview.cpp
https://github.com/atrantan/hpx/blob/partitioned_vector_view/tests/unit/component/partitioned_vector_view_iterator.cpp

Sorry, but I'm not Sithhel, I'm Sithell
19 Июн 2017 г. 7:40 PM пользователь "atrantan"<EMAIL_ADDRESS>написал:

@atrantan commented on this pull request.
In hpx/components/containers/partitioned_vector/detail/
make_index_sequence.hpp
https://github.com/STEllAR-GROUP/hpx/pull/2670#discussion_r122759441:

@@ -0,0 +1,113 @@
+//  Copyright (c) 2017 Antoine Tran Tan

@Sithell https://github.com/sithell I know. The reason is that
multidimensionnal view usually does not exceed dimension 3 or 4 in
scientific domains. The unrolled version implemented here (for those cases)
has a much faster compilation time.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/STEllAR-GROUP/hpx/pull/2670#discussion_r122759441,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AUET5qdEnPwdR_lpUV_YAMWW3z4qta1rks5sFqR7gaJpZM4NtP-a
.

Sorry, but I'm not Sithhel, I'm Sithell

@Sithell: sorry, this was not meant for you but for one of our team-members: @sithhell

Oh, guys, I'm not your teammate. I'm Sithell, not Sithhel.
25 Июн 2017 г. 7:27 PM пользователь "Hartmut Kaiser" <
<EMAIL_ADDRESS>написал:

@hkaiser approved this pull request.
Let's go ahead with this. I'd assume however that there will be another PR
adding some docs.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/STEllAR-GROUP/hpx/pull/2670#pullrequestreview-46149186,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AUET5lO6W7-1m09bmrrGMvRTz9MbE6Heks5sHopqgaJpZM4NtP-a
.

Oh, guys, I'm not your teammate. I'm Sithell, not Sithhel.

Sorry for that again :/ Can't guarantee it will not happen again, though ;)

Am 27.06.2017 12:12 nachm. schrieb "Denis Blank"<EMAIL_ADDRESS>@Naios commented on this pull request.
In hpx/components/containers/partitioned_vector/detail/
make_index_sequence.hpp
https://github.com/STEllAR-GROUP/hpx/pull/2670#discussion_r124233929:

@@ -0,0 +1,113 @@
+//  Copyright (c) 2017 Antoine Tran Tan

Wouldn't it be better then to add the unrolled version to pack.hpp instead,
so the whole library profits from it?
I agree, this should have been done instead.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/STEllAR-GROUP/hpx/pull/2670#discussion_r124233929, or mute
the thread
https://github.com/notifications/unsubscribe-auth/AADRl0eQZl-HKUu5b6bXQavAB-a8Fxkeks5sINV_gaJpZM4NtP-a
.

@atrantan: could you prepare a separate PR please which integrates your unrolled implementation with the existing code in pack.hpp? This also could be part of the PR you're working on to add documentation.

Khe khe. Well, you understand.
27 Июн 2017 г. 6:19 PM пользователь "Hartmut Kaiser" <
<EMAIL_ADDRESS>написал:

@atrantan https://github.com/atrantan: could you prepare a separate PR
please which integrates your unrolled implementation with the existing code
in pack.hpp? This also could be part of the PR you're working on to add
documentation.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/STEllAR-GROUP/hpx/pull/2670#issuecomment-311392080,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AUET5ohAxCf5hsyeGzb3duwkqKrAnz2hks5sIR2WgaJpZM4NtP-a
.

@hkaiser Done in 6ba7818214aca276c4879a843470b873d08aff2d


improve Union deserialization when "__type" field specifier is not present

This PR builds upon @pawelwilczewski's work to attempt to choose the correct dataclass from the list of union options and decode into the correct one depending on field names, and primitive types.

@idbentley I think we will need to retarget this against the main repo once https://github.com/lidatong/dataclasses-json/pull/464 is merged

Yes, agreed @TristanSpeakEasy - I left it as a draft for that reason.


addcomputeoffering: Fix typo in storagetype and network rate

@blueorangutan package

@davidjumani a Jenkins job has been kicked to build primate packages. I'll keep you posted as I make progress.

Packaging result: :heavy_check_mark:centos :heavy_check_mark:debian :heavy_check_mark:archive.
QA: http://primate-qa.cloudstack.cloud:8080/client/pr/739 (JID-3504)


Incomplete documentation for the irrigation code

There are several new irrigation options which are not included in the master lis.config
Irrigation GVF parameter 1:
Irrigation GVF parameter 2:
These config options are not intuitive - Please come up with better config entries for these  (minimum threshold, maximum threshold etc.)

The following log statement in noahmp36_getirrigationstates.F90 should be disabled (it  inundates the LIS log file when irrigation does not occur)

! If we are outside of the irrigation window, set rate to 0
if ((ltime.gt.shift_otimee).or.(ltime.lt.shift_otimes)) then
irrigRate(t) = 0.0
write(LIS_logunit,*) '[INFO] ',ltime, &
'is outside the irrigation window'
endif

Hi Sujay,
Sorry about the stray comment making it in to the final version! in SRC/lis/configs/lis.config.adoc, I had included a brief description of these parameters:
Irrigation GVF parameter 1: specifies growing season for
irrigation in Noah-MP (set to 0.40 for Noah 3.3 irrigation)
Irrigation GVF parameter 2: specifies growing season for
irrigation in Noah-MP (set to 0.00 for Noah 3.3 irrigation)
I agree that they need a better description, but should they be also somewhere else too?

I think we could provide more specifically what the two parameters represent and the source for this update to the original work implemented by Mutlu and Hiroko.
Here is some additional information that we could pull from and provide more background on these two parameters in the lis.config.adoc file.
In the original GVF threshold of the sprinkler irrigation scheme by Ozdogan et al. (2010), a fraction 0.4 was applied as part of the max-min seasonality in GVF.  Then from Wanshu, in her Nie et al. (2018) paper, she modified that constant fraction value when applied the dynamic GVF option.  Wanshu: "Instead of using 0.4, we use two parameters and the GVF range to adjust the percentage of cut-off, so that areas of greater GVF range will have a higher percentage cut-off and areas of lower GVF range will have a lower cut-off, we found this is helpful to improve the simulated irrigation amount under drought conditions for High Plains. On the other hand, the model is more flexible, since the two parameters (GVFparam1 and GVFparam2) can be adjusted accordingly, if prior information of growing season is available. We can also set GVFparam1=0.4, GVFparam2=0 to go back to the original setting in Ozdogan et al. (2010)."
Wanshu: "Thus, We are trying to use "(LIS_rc%irrigation_GVFparam1 + LIS_rc%irrigation_GVFparam2*(shdmax-shdmin))” to substitute a constant value of 0.4. Let’s say the 0.4 means that 40% cut-off for the threshold. By using the new equation, we are able to adjust this cut-off percentage as a function of the GVF range (shdmax - shdmin), so that irrigation will be triggered at for example 60% for the grid cell with higher GVF range while may be less than 40% for the grid cell with lower GVF range."

@karsenau, that's a great summary!
I modified it to read
In the original GVF threshold in the sprinkler irrigation scheme by Ozdogan et al. (2010),
a fraction of 0.4 was applied as part of the max-min seasonality in GVF. Nie et al. (2018)
added a dyanmic option. These two parameters and the GVF range allow the user to adjust
the percentage of the irrigation cut-off so that areas of greater GVF range will have a
higher percentage cut-off and areas of lower GVF range will have a lower cut-off. In the
code, the irrigation threhold contains the term
(GVFparam1 + GVFparam2*(shdmax-shdmin))
instead of a static value of 0.4. By using this equation, the user may adjust the cut-off
percentage as a function of GVF range (shdmax-shdmin).
and will issue a pull request for these fixes.


Make the logs path of system-docker configurable

The file path of system-docker logs is /var/log/system-docker.log, and it is hardcoded.
Someone wants to control system-docker logs to write to a separate partition, such as RANCHE_OEM partition. The RANCHER_OEM partition is mounted by default to /usr/share/os/oem.
We can let the user configure logs path via kernel parameters or os-config.

When users use the RANCHER_OEM partition and change the logs path of system-docker:
rancher:
  defaults:
    system_docker_logs: /usr/share/ros/oem/system-docker.log

The logs will be written to usr/share/ros/oem/system-docker.log:
[root@rancher ~]# ls -ahl /usr/share/ros/oem/
total 12
drwxr-xr-x    2 root     root        4.0K Oct 11 01:54 .
drwxr-xr-x    3 root     root        4.0K Oct 10 11:11 ..
-rw-r--r--    1 root     root        1.5K Oct 11 01:54 system-docker.log

[root@rancher ~]# blkid  | grep OEM
/dev/sda2: LABEL="RANCHER_OEM" UUID="8168d409-7ade-4ebc-896b-7cb02535139d" TYPE="ext4" PARTUUID="0ae64795-02"

[root@rancher ~]# df -hT | grep oem
/dev/sda2            ext4            6.8G     31.5M      6.4G   0% /usr/share/ros/oem

Backported to 1.4.2


Camera capture timer

Please add timer functionality. Currently, I'm going with:
private int timer;

public void capture(int seconds, final OnCapturingListener listener) {
    this.timer = seconds;

    final Handler handler = new Handler();
    handler.post(new Runnable() {
        @Override
        public void run() {
            if (timer > 0) {
                timer--;
                listener.onTicking(timer);
                handler.postDelayed(this, 1000);
            } else {
                listener.onCapturing();
                takePicture();
            }
        }
    });
}

public interface OnCapturingListener {

    void onTicking(int remainingSeconds);

    void onCapturing();
}

I'm not sure if this should be a feature of this library. The requirement will vary from app to app, and the implementation is not too tough.
I'll keep this open for a while for input from more people.


multiple containers using 443 and mapped 443 to 1044X

Hi,
Congrats for your excellent solution.
I'm using docker-compose to build my ci environment and I have several web sites for which I map the port 443 to other in other to co-exists.
container1: <IP_ADDRESS>:443 -> <IP_ADDRESS>:10443
container2: <IP_ADDRESS>:443 -> <IP_ADDRESS>:10444
container3: <IP_ADDRESS>:443 -> <IP_ADDRESS>:10445
then I've specified for each one corresponding VIRTUAL_HOST and VIRTUAL_PROTO=https
I success to connect to https://container1.dommain:10443 and so on but I fail to connect to https://container1.domain:443.
How should I deal in this case with multiple containers exposing ssl services?

Did you start the proxy using the instructions here: https://github.com/jwilder/nginx-proxy#ssl-support.  nginx-proxy will need access to the SSL certs for each container if you you are trying to connect to the proxy over SSL.

Thanks for your replay. Yes, I did exactly that. I've generated all the certificates like in the specs but it doesn't work still. Here's my docker-compose.yml, I've simplified it just to have nginx-proxy and redmine. Redmine goes out throught port 10444 (https://redmine.mydomain:10444) but what I want to achieve is https://redmine.mydomain:443 in coexistence with other web apps in the same docker server also mapping 443 to other ports.
container1: "10443:443" --> https://container1.mydomain:443 (to the public)
container1: "10443:443" --> https://container1.mydomain:443 (to the public)
container2: <IP_ADDRESS>:443 -> <IP_ADDRESS>:10444
container3: <IP_ADDRESS>:443 -> <IP_ADDRESS>:10445
reverseproxy:
image: jwilder/nginx-proxy
ports:
- "443:443"
- "80:80"
volumes:
- /var/run/docker.sock:/tmp/docker.sock:ro
- /mnt/sda1/srv/reverseproxy/certs:/etc/nginx/certs
postgresql_redmine:
image: sameersbn/postgresql:latest
environment:
- DB_USER=redmine
- DB_PASS=redminedev
- DB_NAME=redmine_production
volumes:
- /mnt/sda1/srv/redmine/postgresql:/var/lib/postgresql
redmine:
image: sameersbn/redmine:latest
links:
- postgresql_redmine:postgresql
environment:
- VIRTUAL_HOST=redmine.mydomain
- VIRUTAL_PROTO=https
- VIRTUAL_PORT=443
- TZ=Europe/Berlin
- REDMINE_PORT=10444
- REDMINE_HTTPS=true
- REDMINE_HTTPS_ONLY=true
- REDMINE_HTTPS_HSTS_ENABLED=true
- REDMINE_HTTPS_HSTS_MAXAGE=2592000
- SSL_KEY_PATH=/app/setup/certs/redmine.pem
- SSL_CERTIFICATE_PATH=/app/setup/certs/redmine.crt
- SSL_DHPARAM_PATH=/app/setup/certs/dhparam.pem

Reviewing OP's file since I am stuck port mapping to nginx-proxy, noticed you have a mis-spelling "- VIRUTAL_PROTO=https".

Awesome!I had already given up! Now I'm able to have my whole infrastructure running on https.
Thank you much for watching this!

The issue is solved. Bad Typo.
Thanks!


[SYSTEMML-1795] Specify a set of GPUs to use for a given machine

Can specify:
a) -1 for all GPUs
b) a specific number of GPU
c) a comma separated list of GPUs
d) a range of GPUs
Ping @niketanpansare

Refer to this link for build results (access rights to CI server needed):
https://sparktc.ibmcloud.com/jenkins/job/SystemML-PullRequestBuilder/1787/

Refer to this link for build results (access rights to CI server needed):
https://sparktc.ibmcloud.com/jenkins/job/SystemML-PullRequestBuilder/1792/

@niketanpansare - the tests seem to have passed.
Will wait for your review.

LGTM. Thanks @nakul02  :+1:

Thanks, I shall merge.


Move globalFetch out of experimental

Beaker version: Beaker v0.8.0-prerelease.9
I think we should move the globalFetch API from experimental to permanant because it is too important to consider it in any way just as experimental only. Millions of users will need this in the future,no point in keeping this experimental as it make it seem not credible enough for developers to rely on for serious dapps. Anyone who has used XMLHttpRequest,knows why globalFetch API provides a more powerful and flexible feature set with HTTP.

I don't plan to deprecate globalFetch without a good replacement. The question in my mind is whether the existing fetch API might be someday expanded to support the globalFetch behaviors (requesting to escape CORS). If we can be sure it won't, then I'm +1 to globalFetch moving to permanent support.


Remove event

we only use this in 1 place right now and it's executed synchronously so for me this is just overhead. All other mails are send from the mailerservice so we will follow that practice here too

reminder @tvlooy don't forget to delete branch on master repo when it is merged


build.rs python3 generate_self_schema.py pacnic on windows

https://github.com/pydantic/pydantic-core/blob/d6e7890b36ef21cb28180a7f5b1479da2319012d/build.rs#L13
windows don't have python3 alias, so it panics with python3 command not found. By changing  python3  to  python , it works well

Works fine on ci, but if you have a fix for this, happy to review a pr.

no answer on why this is happening, so closing.
Most likely it was either the wrong version of python or typing-extensions wasn't installed.


Only show semantic search if user has execute SQL permission

https://github.com/datasette/datasette-embeddings/blob/42d8e637a62bee2c160f09db14cd9ddf456d6e0f/datasette_embeddings/__init__.py#L138

Those tests fail on Datasette <1.0 because of this code:
https://github.com/datasette/datasette-embeddings/blob/0e23e76002e9edb31b12abb469bd01fa1b80e434/datasette_embeddings/__init__.py#L151-L154
Consider this in Datasette 0.64:
https://github.com/simonw/datasette/blob/4e3e8a01248397340e82f66bee518b0dd3921643/datasette/views/database.py#L379-L381
        allow_execute_sql = await self.ds.permission_allowed(
            request.actor, "execute-sql", database, default=True
        )

In 1.0 the default=True is no longer needed.


Slider add paramater to disable keyboard events

The Slider Composable always uses the internal Modifier.slideOnKeyEvents (defined in Slider.kt). It would be cool if this behavior could be disabled using a parameter, something like:
Slider(
    ...,
    enableSlideOnKeyEvents = false,
)

My use case: I use left/right/up/down keyboard events in my Window for a custom behavior (media app, skip song/skip 10 secs). As soon as the Slider is focused using the mouse, those events don't work anymore as the Slider catches all the key events.
My current workaround: As soon as onValueChangeFinished is called, the Slider is shortly disabled (clears focus) and reenabled:
var canHaveFocus by remember { mutableStateOf(false) }

Slider(
    value = [...],
    onValueChange = { slidingState = it },
    enabled = canHaveFocus,
    onValueChangeFinished = {
        // [...]
        canHaveFocus = false
    }
)

LaunchedEffect(canHaveFocus){
    if(!canHaveFocus) canHaveFocus = true
}

Hello @RocketJannis please try this code:
var value by remember { mutableStateOf(0.1f) }
Slider(
    value,
    onValueChange = {
        value = it
    },
    modifier = Modifier.focusProperties { canFocus = false }
)

It makes Slider non-focusable, so it won't receive any key events, but still will receive pointer events.
Please let me know and reopen the issue if it doesn't suit you!

@Walingar thank you very much, I didn't know :+1: sorry for opening an issue xD

Please check the following ticket on YouTrack for follow-ups to this issue. GitHub issues will be closed in the coming weeks.


How to format a Duration

Hello everyone,
I saw this was requested before, but didn't manage to find if since there there are any new solutions.
I have a moment.duration()  and I'd like to format it as  hh:mm:ss.
Specifically I'd like to use the format() function, so I don't have to take care of padding 0s as well as missing part of the time:
61000ms  -->    01:01   (and not 00:01:01, or 1:1)
59000 ms -->   59
In the past I wrote something like this:
return function(seconds) {
    const hours = Math.floor(this.props.length / (60 * 60));
    const reminderFromHours = this.props.length % (60 * 60);
    const minutes = Math.floor(reminderFromHours / 60);

    const reminderFromMinutes = reminderFromHours % 60;
    const seconds = Math.ceil(reminderFromMinutes);

      // add leading zero and start concatenating the string
    let timeString = (seconds < 10) ? ('0' + seconds) : seconds;
    if (minutes > 0) {
      timeString = ((minutes < 10) ? ('0' + minutes) : minutes) + ':' + timeString;
    }
    if (hours > 0) {
      timeString = hours + ':' + timeString;
    }
    return timeString;
};

But as I said, I'd prefer to leverage the built in functions of the library :)

Please see discussion at #1048


Overview in Markdown files

Issue Type: Feature Request
While reading the latest release notes within VS Code, I realized that there's one feature I lacked, the ability to easily navigate the Markdown file.
If you've ever read a long Google Docs document you might have a clue as to what I'm talking about. On the righthand side of the screen, theres a navigation pane, giving a clear overview of the document, showing all headings and subheadings withing the document. The same should be present within Markdown files within VS Code.
I put together a quick screenshot for reference.

VS Code version: Code 1.22.2 (3aeede733d9a3098f7b4bdc1f66b63b0f48c1ef9, 2018-04-12T16:38:45.278Z)
OS version: Windows_NT x64 10.0.16299

Duplicate of #5605 . Go to symbol already presents an outline and can be used to quickly jump between sections


IIT

INTERNATIONAL INSTITUTE OF TECHNOLOGY (http://www.iit-nau.com)

@achrafbenalaya Could you please rename the file? If the domain which you wish to add is IIT.tn, the file name has to be lib/domains/tn/IIT.txt. Please notice .txt extension, it is mandatory in this repository. Thank you!

@achrafbenalaya I am sorry, this request remains unanswered for a while, I close it. Please reopen if you have an update regarding the issue described above. Thank you!


Ruby group capstone - Catalog of my things - Kanban Board

We are three people in the team, Kola, Muhammed and Jose.
Kola is Team Member 1
Muhammed is Team Member 2
Jose is Team Member 3
Link to project:
https://github.com/edgardsoza/Ruby-capstone-project/projects/1

Hi team,
You've done an amazing job so far 👏 💯 👍
There are some issues that you still need to work on before starting your Capstone!
Highlights

The tasks are divided equally.

Required Changes ♻

[ ] Most of your cards don't have a description while it is required, kindly add description to every card.
[ ] It is required to give a number of points to every task and your group tasks cards don't have points. Kindly work on that issue then submit again so that your Kanban board can be reviewed.

Optional suggestions
Every comment with the [OPTIONAL] prefix is not crucial enough to stop the approval of this PR. However, I strongly recommend you to take them into account as they can make your code better.
Cheers and Happy coding!👏👏👏
Feel free to leave any questions or comments in the PR thread if something is not 100% clear.
Please, do not open a new Pull Request for re-reviews. You should use the same Pull Request submitted for the first review, either valid or invalid unless it is requested otherwise.

As described in the Code reviews limits policy you have a limited number of reviews per project (check the exact number in your Dashboard). If you think that the code review was not fair, you can request a second opinion using this form.

STATUS: APPROVED ✔ 🍾 🍾 🍾 🥳 🥳 🥳
Hi Team,
Your project is complete!  There is nothing else to say other than... it's time to merge it :shipit:
Congratulations! 🎉

Highlights
✅ Correct set of project kanban
✅ Neat Project cards
Cheers and Happy coding!👏👏👏


Work system design

Originally created by Tom Smyth at 2017-09-11 17:02, last assigned to Tom Smyth, migrated from redmine-#7117

Status changed from New to Closed

By Tom Smyth at 2017-09-18 13:09


responseJSON returns a Promise

In core Alamofire, the fact that responseJSON() returns Any makes sense, because it can return both the proper JSON response, and any kind of a non-JSON value for error.
In PromiseKit/Alamofire, the non-JSON values can be returned as part of a rejected promise. Fulfilled promises can get a [String: Any] instead of Any.

Correct me if wrong, but valid JSON can be any of:

Double
[Any]
`[String: Any]
Bool

We provide responseJsonDictionary because of this.

There's no reason to use NSNull() instead of nil. There's no reason to not properly serialize optionals with nil value to a JSON null. If anything, it's the more intuitive approach, and dozens of confused developers on StackOverflow prove it.
This:
var x: String? = nil
let data = ["x": x]

Is more reasonable than this:
var x: String? = nil
let data = ["x": x ?? NSNull()]

We don’t change anything that Alamofire gives us, and it doesn’t change anything that NSJSONSerialization gives it.

Closing due to lack of response.


YAMLParser: Some minor fixes/additions

I had originally made a PR on uml-robotics/ROS.NET, which included a couple of the commits in this PR. But then I found this fork, and I realized that I was rewriting code that you guys have been rewriting for 2 years! 😝 So this PR includes differences that I found between my own fork and this one. Feel free to cherry-pick any commits you find useful.
Specific details to follow:

Commit 1: YAMLParser: Fix some character escaping for string constants

Commit 5: YAMLParser: (experimentation) Allow strings to be constants

Commit 6: YAMLParser: (attempt to) Fix KnownStuff.WhatItIs bug

Commit 7: Merge code to sort messages by priority

I'm not sure if it is common practice to use string constants in ROS. But regardless, in its current state, YAMLParser had some issues parsing the following lines in one of my .msg files:

string CONTENT_JSON = "application/json"
string CONTENT_STREAM = "application/octet-stream"

Commit 1 fixes character escaping for this specific case. But Commit 1 also breaks resolving for certain messages (for example, the field filename in common_msgs/map_msgs/SaveMap doesn't resolve its type properly). Commit 6 fixes this by checking if the left-side of the / has been a resolved package name. Commit 7 (which I merged from uml-robotics/ROS.NET/master) sorts the msg file queue by priority, ensuring that std_msgs/geometry_msgs/actionlib_msgs are resolved first, which should hopefully increase the success rate of Commit 6.
Commit 5 comments out some old code that the original author had, which made string constants non-static. I personally prefer string constants to be static, so I commented the lines out. Feel free to skip this commit if not interested.
Note: I kept strings const instead of static readonly because I needed them to be processed at compile-time for my own use case.

Commit 2: YAMLParser: temp workaround to allow multiple arguments in -m

I think the CommandLineUtils library cannot actually support multiple arguments? Either that, or I was too dumb to figure it out. I tried many combinations of commas, quotes, and spaces, but it just kept combining them into one Value. I added a temporary workaround, but the bug needs some type of intervention in the future. Perhaps this updated version might work better?

Commit 3: YAMLParser: expand list of CSharpKeywords

Commit 4: YAMLParser: Add check to ensure pkgs/fields will be valid C# identifiers

Commit 3 expands the list of CSharpKeywords to include every keyword listed on Microsoft's website.
Commit 4 checks the package and field names of every message folder to make sure that they would work as valid identifier names in C#. (For example, if you had a folder named test-msgs, or if the name were in a different language, then YAMLParser would still run successfully, but the autogenerated code would not build)

Commit 8: YAMLParser: Ensure Messages.dll has parsed required ROS packages for lib

Commit 9: YAMLParser: comment out actionlib_msgs from required_packages check

Commit 8 ensures that required message packages (std_msgs, etc) were included in the args. In instances where they were not included, I have run into 2 distinct issues:

referenced fields like Header cannot resolve in the MD5 hash, so the code autogeneration gets stuck in an infinite loop
the autogenerated Messages project cannot build because of the following using statements from the template:

using Messages.geometry_msgs;
using Messages.sensor_msgs;
using Messages.actionlib_msgs;

Commit 9 comments out actionlib_msgs from the required_packages array, because it is not included in common_msgs, and the autogenerated code seems to build without it...

Thank you!

Added another commit, YAMLParser: Check if field name == class name:
In C#, a variable name cannot be the same as the class enclosing it. Currently, when this happens, YAMLParser will run successfully, but the autogenerated project will not build. I added a check for it, and for such cases, it now adds an underscore to the beginning of the var name.
A very rare instance, but a bug nonetheless 😝

@YaseenAlk Thanks a lot for your PR! The YAMLParser (whyever it was called that - it should be renamed to MessageGenerator or similar) is really the place that still requires significant improvements. So any help here is really appreciated.
I will review in detail and integrate it when I find a free slot.

YAMLParser: temp workaround to allow multiple arguments in -m

Thanks for the ref to natemcmaster/CommandLineUtils. I was not aware that MSFT stopped dev of that very popular extension, very crazy decision to drop support for a package with >4 mio nuget installs...
I think it would make sense fo upgrade to the follow-up community fork. But may I ask again what did not work for you? I just tested specifying the -m option multiple times (e.g.  -m ../test1 -m ../test2) and I got the values correctly split in the messageDirectories.Values.  I tested with .net core on Windows. Does the problem only occur on Linux?

I may have been using -m incorrectly -- the CommandUtil help said that the arguments needed to be comma-separated, so the examples I tried were in the format of -m ../test1,../test2. All of my testing was with .NET Core CLI/netcoreapp2.1, on macOS High Sierra 10.13.6. I had not thought to try using -m multiple times (my mistake!)


Nikhil/navigationlink

fixed the path of install.mdx
remove install.mdx file from current folder, didn't change link, changed the path of file, now both hyperlink link are working
"Fixes #1249":
-->
I have:

[x] Read and followed KubeVela's contribution process.
[x] Update sidebar.js if adding a new page.
[x] Run yarn start to ensure the changes has taken effect.

Special notes for your reviewer

@wonderflow kindly review this

@chivalryq kindly review this again, this time i didn't put url


Cryptopia is THE ONLY one who's commented on this and the first mention from them was to announce the closing of the market. No report on which wallet they were running - and it seemed to have ZERO issues sending and receiving transactions while we tried to interact with the cryptopia wallet.    Oh well.  See Ya on the Mothership Pink Boys.


44625 merge query into cdt datastore

This PR adds the query code and tests from CloudantQueryObjC into the CDTDatastore repo.  The majority of the changes within this branch are additions of the Query .h and .m files.  Actual file modifications within this branch are detailed below:

contents.xcworkspacedata: Adds query classes to Query group in workspace (done by Xcode)
CloudantSync.h: Adds CDTDatastore+Query.h and CDTQResults.h to CloudantSync.h
readme.md: Updates the old indexing/query reference to now match the new query syntax.
Podfile: Add Specta, Expecta library reference.
Tests OSX-Prefix.pch: Add Specta, Expecta library reference.
project.pbxproj: Updated by Xcode
Tests-Prefix.pch: Add Specta, Expecta library reference.
index-query.md:  Update old indexing/query documentation to alert readers that the code will be removed and to reference the new query.md doc.
query.md: This file was added and it includes the new query docs.  Worth a review.

A general comment, I think we should have mark the code blocks that contain just JSON with the JSON flag to get the pretty syntax highlighting

This seems good to me, when bd14f44 is merged into the appropriate main commit, +1.

+1 now we've released 0.15.0. Go ahead and merge.


i18n(zh-cn): Update 1.mdx

Description (required)
make sentences flow better

Related issues & labels (optional)

Closes #
Suggested label:

First-time contributor to Astro Docs?
Yes

Astro Discord username:
codelo

Hello! Thank you for opening your first PR to Astro’s Docs! 🎉
Here’s what will happen next:

Our GitHub bots will run to check your changes.
If they spot any broken links you will see some error messages on this PR.
Don’t hesitate to ask any questions if you’re not sure what these mean!

In a few minutes, you’ll be able to see a preview of your changes on Vercel 🥳

One or more of our maintainers will take a look and may ask you to make changes.
We try to be responsive, but don’t worry if this takes a few days.


krb5 - missing header

Include missing header in kssl.c. My pull request fixes.
kssl.c: In function ‘SSL_set0_kssl_ctx’:
kssl.c:2228:6: error: dereferencing pointer to incomplete type
     s->kssl_ctx = kctx;
      ^
kssl.c: In function ‘SSL_get0_kssl_ctx’:
kssl.c:2233:13: error: dereferencing pointer to incomplete type
     return s->kssl_ctx;
             ^

Pull request was applied. Closing issue.


"go vet" needs a 'ignore this' mechanism

What version of Go are you using (go version)?
go version go1.7.4 darwin/amd64
What operating system and processor architecture are you using (go env)?
GOARCH="amd64"
GOBIN=""
GOEXE=""
GOHOSTARCH="amd64"
GOHOSTOS="darwin"
GOOS="darwin"
GOPATH="/Users/bolson/psrc/gopath"
GORACE=""
GOROOT="/usr/local/go"
GOTOOLDIR="/usr/local/go/pkg/tool/darwin_amd64"
CC="clang"
GOGCCFLAGS="-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/rh/3lrlb3dx2gj8s_5yyxb2vsyc0000gn/T/go-build257955075=/tmp/go-build -gno-record-gcc-switches -fno-common"
CXX="clang++"
CGO_ENABLED="1"
What did you do?
a.go:
`
package main
import "fmt"
import "os"
func main() {
out := os.Stdout
i := 1
fmt.Fprint(out, "I am 100% sure what I'm doing here\n") // go vet ignore -- wouldn't it be nice if there were a directive to silence the go vet warning here?
}
`
What did you expect to see?
go vet should be able to have no complaint about this file
What did you see instead?
$ go vet
a.go:9: possible formatting directive in Fprint call
exit status 1
If this feature exists and is undocumented, it needs to be documented
https://golang.org/cmd/vet/
See also prior issue of excessive warnings like this
https://github.com/golang/go/issues/6407

This was discussed in #17058. Note that the introduction of a new directive/magic comment to be used to silence vet warnings was and unanimously rejected.

Duplicate of #17058


Fix lingering metadata in inventory for stopped containers

What does this PR do?

Avoid sending inventory data for unscheduled check.
In a k8s environment the container linked to a check instance might be stop/killed while the check is running. Since we don't have a way to stop a Python thread we unschedule the check but let it finish its last run. This means that inventories might receive metadata for a check that no longer exists in the collector and will never be cleaned.
This commit cleans the check metadata cache every time we generate the payload. This means we no longer send information about checks not in the collector. Therefore, the check command has to manually print metadata instead of relying on the status page.
Check if inventory is enabled in all public methods.  We don't want to store data in inventory when the collector is disabled.

Describe how to test/QA your changes

Create a python instance that sleep X second before registering metadata.

ex:
from time import sleep
from datadog_checks.base import AgentCheck
import datadog_agent

class Inv(AgentCheck):

    def check(self, _):
        self.log.error("sleeping")
        sleep(5)
        self.log.error("sending metadata")
        self.set_metadata("version", "1.0.0")
        self.log.error("Check run done")

Create a auto_conf config to link this check to a container (for example redis):
ex inv.yaml:

ad_identifiers:
  - redis

instances:
  - host: "%%host%%"

Start the agent, start a redis container, wait for the check to start and print sleeping, kill the container, watch the collector stop/clean the check. After 5s the check will still register some metadata. After the last run is completed wait inventories_min_interval and check that the inventory payload doesn't contain any info about the inv check (with the command troubleshooting metadata_inventories).

Reviewer's Checklist

[ ] If known, an appropriate milestone has been selected; otherwise the Triage milestone is set.
[ ] Use the major_change label if your change either has a major impact on the code base, is impacting multiple teams or is changing important well-established internals of the Agent. This label will be use during QA to make sure each team pay extra attention to the changed behavior. For any customer facing change use a releasenote.
[ ] A release note has been added or the changelog/no-changelog label has been applied.
[ ] Changed code has automated tests for its functionality.
[ ] Adequate QA/testing plan information is provided if the qa/skip-qa label is not applied.
[ ] At least one team/.. label has been applied, indicating the team(s) that should QA this change.
[ ] If applicable, docs team has been notified or an issue has been opened on the documentation repo.
[ ] If applicable, the need-change/operator and need-change/helm labels have been applied.
[ ] If applicable, the k8s/<min-version> label, indicating the lowest Kubernetes version compatible with this feature.
[ ] If applicable, the config template has been updated.

If I'm understanding the PR description and code here, this makes the agent check command implementation dependent on pkg/metadata/inventories in order to get some check information. That seems like a particularly strange direction in which to draw a dependency arrow, and ends up coupling those two components rather awkwardly. Is there another way to do this? Maybe a new component on which both inventories and agent check can depend, or maybe moving this functionality into a component on which both already depend?

I agree. The real issue is that the check command does manually run checks bypassing the collector but does rely on everything else working as if it was running the default agent (like the status page).
I think we had 2 options that don't involve a major rewrite: either have the check command manually pull metadata (the same way it manually init and run checks) or have 2 ways to initialize the inventory package (one where we ignore metadata not linked to a check and on where we don't). I felt that pushing the complexity to the check command was the "cleaner" solution since it was already dependent on the metadata package to init the inventory collection. WDYT ?

Hm, that's fair.  It's definitely "kicking the can down the road" but we have a giant bend in the road coming up: the component refactor.  This will be a knot we'll need to untangle in that process.


Is getMappedItems an anti-pattern in mapStateToProps?

In all real-world examples (including code we use in our own work) I see the following pattern emerging in mapStateToProps:
// action
export const getOrganizations = state => state.entities.organizations;

export const getMappedOrganizations = (state, ids) => {
    const { byId } = getOrganizations(state);
    return ids.map(id => byId[id]);
};

// view
const mapStateToProps = state => {
    const { byAll } = getOrganizations(state);
    const organizations = getMappedOrganizations(state, byAll.ids);

    return {
        isFetching: byAll.isFetching,
        lastUpdated: byAll.lastUpdated,
        organizations,
    };
};

This provides the view all the data it needs, but unfortunately organizations will always be a new array when store updates, resulting in redundant updates of the view even though nothing has changed.
This is especially noticed when you have a popup or modal that updates store as well, and the list in the background, resulting in slowness because the view is always updating.
Is this really the advised pattern? Should you modify shouldComponentUpdate to fit it for non-shallow comparison in this case? Perhaps you should pass down the functions to create the mapped items and do so in the render function instead?

In this case, you can use reselect to create your selectors, so that their result can be memoized.
For example:
import { createSelector } from 'reselect'

const organizationsSelector = state => state.entities.organizations;

const allOrganazationIdsSelector = createSelector(
  organizationsSelector,
  organizations => organizations.byAll.ids
)

const allOrganazationsSelector = createSelector(
  organizationsSelector,
  allOrganazationIdsSelector,
  ({ byId }, ids) => ids.map(id => byId[id])
)

const mapStateToProps = state => {
    const { byAll } = organizationsSelector(state);
    const organizations = allOrganazationsSelector(state);

    return {
        isFetching: byAll.isFetching,
        lastUpdated: byAll.lastUpdated,
        organizations,
    };
};

Great answer! thanks for the help!


Restyle address bar

Before:

After:

@Pyragon Definitely, we need fork this project

Gimme tonight and Ill get a fork on my repo with my fixes/changes including ones I havent uploaded yet.


Remove Swig Templating

Meanjs no longer uses swig as it has vulnerabilities and is no longer being maintained:
See: https://github.com/paularmstrong/swig
Meanjs has opted to use handlebars which uses a similar syntax and is a fairly straight forward conversion, as it's only used to present the server side views: modules/core/server/views.

But we did remove it... not sure what did you mean by this issue @daronjones?

Lol! Sorry Liran.
I'm now working somewhere using MeanJS. This message was meant to be put on
our internal TODO. :D
On 18 May 2017 at 07:47, Liran Tal<EMAIL_ADDRESS>wrote:

But we did remove it... not sure what did you mean by this issue
@daronjones https://github.com/daronjones?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/meanjs/mean/issues/1775#issuecomment-302316326, or mute
the thread
https://github.com/notifications/unsubscribe-auth/Aa_B_hJmmcRQZroZR68s3QMXvHrEmG7fks5r6-mYgaJpZM4Nd4ed
.

Cool no issues, I'm closing :)

Are you on top of all the issues in Meanjs? I got snowed under way back.

Been a bit busy but I did review quite a few items a few weeks back.
Would be great to have more active contributors onboard to help with the repo.

Definitely, things have been a bit like a ghost-town recently. I was going to have a crack at some of the stuff I've not had time before to work on.


Add cookiecutter-mediawiki-extension template

Current coverage is 99.64%

Merging #645 into master will not affect coverage as of b0fee56

@@            master    #645   diff @@
======================================
  Files           13      13
  Stmts          564     564
  Branches         0       0
  Methods          0       0
======================================
  Hit            562     562
  Partial          0       0
  Missed           2       2

Review entire Coverage Diff as of b0fee56

Uncovered Suggestions

+0.36% via ...ookiecutter/utils.py#27...28

Powered by Codecov. Updated on successful CI builds.

Hey @JonasGroeger, thanks for submitting a PR :bow:
Unfortunately your template raises an error during generation. The problem is this comment in jinja2 context.
This may help solve the problem.
Also it may be worth adding tests to your template as in cookiecutter-django

Hey @hackebrot
I have solved the problems. Tests are yet to come but for now its alright.

thanks :bow:


Error: INSTALLATION FAILED

Hello, I receive this erreor when try a helm install on version 7 :
Error: INSTALLATION FAILED: Deployment.apps "blue-agent711" is invalid: spec.template.spec.containers[0].lifecycle.preStop.exec.command: Required value

Can you share your helm values config and the generated deployment resource?

Maybe related to #242.

Can you please re-test with version v7.1.2? The issue might be fixed already.

Yes, it's fixed. Thanks!
Le dim. 29 sept. 2024, 05 h 37, Clémence Lesné @.***> a
écrit :

Can you please re-test with version v7.1.2? The issue might be fixed
already.
—
Reply to this email directly, view it on GitHub
https://github.com/clemlesne/blue-agent/issues/279#issuecomment-2381285024,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/BLVBUW4NQK2XP7RB7UAFYXTZY7C7FAVCNFSM6AAAAABO7L6QCGVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDGOBRGI4DKMBSGQ
.
You are receiving this because you authored the thread.Message ID:
@.***>


Bookstore: styling

In this pull request I did the following:

Added missing JSX elements to my project.
Made my final design to match Zeplin's design (this includes all elements + the same styling)

Thanks @Reem-lab 👍


Provide the "Access info" also under "Subscriptions -> Administrate"

OSCM supports an "Access info" field, which depending on the type of service contains information to access the service. This field is avaible to users of a subscription in the "My subscription" section of the catalog.
It would be useful for administrators to have access to this field within their "Administrate subscriptions" section whithout having to switch to the "My subscription" section, when accessing a service.

Released in March 2016


Add checks to avoid duplicated Names for Devices

What this PR does / why we need it:
This PR adds a few extra checks and tests in regards to duplicated field:'Name' for Devices.
Which issue(s) this PR fixes (optional, in fixes #<issue number>(, fixes #<issue_number>, ...) format, will close the issue(s) when PR gets merged):
Fixes #
Special notes for your reviewer:
Motivation for this comes from https://github.com/kubevirt/kubevirt/pull/6829#discussion_r756148440 and https://github.com/kubevirt/kubevirt/pull/6829#discussion_r756132092
This PR should be updated after https://github.com/kubevirt/kubevirt/pull/6829 is merged
Release note:

NONE

/hold
#6829 to be merged and this to be rebased + updated

/unhold

rebased after #6829

/retest

/retest

@rmohr hey, as usual, this PR is not urgent but let me know if I've got it right from your comment. cheers!

ping
/retest

@victortoso thanks! I will bring it up on the next community meeting. I want to check with a few more maintainers if they agree that we can take it in without breaking backward compatibility too much (like some people could have duplicates already).

/retest


Possible to add multiband?

Hi, thx for your great work!
I wonder is it possible to add multi band to further improve inference speed like https://github.com/MasayaKawamura/MB-iSTFT-VITS

This looks interesting and worth trying. I think it can definitely do it and make it with comparable performance while being two times faster.

Thanks for your suggestion. This looks interesting and worth trying. I think it can definitely do it and make it having comparable performance while being two times faster. I’ll try when I have time but I’ll leave this issue open if anyone else would like to try.


Rebase to ipfs 0.4.3

Coverage decreased (-16.4%) to 44.286% when pulling 7b8b9100e77717b8db40a6fc1f4e8143896e2275 on cpacia:master into 8ea6b4d7b91bb99a219e8747d1d572e661432bc7 on OpenBazaar:master.


Minimum number of forced security questions to be answered is mandatory in Console application

Describe the issue:
In Account Recovery configurations, Minimum number of forced security questions to be answered config is mentioned as a mandatory one. Please refer the screenshot.

Based on this behavior, user cannot change any other configuration in the same category without adding a value to this configuration. This is only happening in Console application. In Management Console, this is mentioned correctly. Please refer the below screenshot.

How to reproduce:

Login to the Console application and go to Manage -> Account Management -> Account Recovery.
Enable Notification based password recovery and try to update the category.

Expected behavior:
It needs to be able to update the category without having a value to the Minimum number of forced security questions to be answered config.
Environment information :

Product Version: IS 5.11.0 RC
OS: Mac
Database: H2
Userstore: LDAP

Governance connectors UI in the Console is implemented to be data driven. But currently, Governance API doesn't support any metadata regarding the fields hence all the input fields have been made mandatory by default. The API should provide more metadata regarding the type, required status etc. of the property fields.

Duplicates https://github.com/wso2/product-is/issues/13241


simple graphical UI?

Mostly I'm just coming here to stay thank you for this. It's very useful! Here's my feature request: a simple graphical UI, maybe just for selecting the colors of the rainbow. I bet that's not super-hard in Python, though I've never done that.

A flask web server for this could work. platform agnostic, mostly.


Inverse of :hidden in --preview (maybe :visible) ?

In my bashrc , I do :
FZF_DEFAULT_OPTS="--bind '?:toggle-preview' --preview 'less <<< {}' --preview-window 'up:50%:hidden"
(and others, since I find that I don't use preview-window that often, but might want to use it sometimes).
However, after sourcing this, I would like to force fzf to show the preview-window by default.
So I do:
fzf --preview-window 'right:70%' but the first hidden property is ignored (eg the preview window is hidden by default).
They are imo two ways of fixing this :

The explicit way  : fzf --preview-window 'right:70%:visible' will override a previous hidden (but if no hidden nor visible is given, the preview-window is visible)
The implicit way : fzf --preview-window 'right:70%' should completely remove a previous :hidden property.

In this particular case, I'm not sure which way I prefer.

Here's a patch if you decide for "2."
diff --git a/src/options.go b/src/options.go
index 2a72427..31ad497 100644
--- a/src/options.go
+++ b/src/options.go
@@ -724,6 +724,7 @@ func parseSize(str string, maxPercent float64, label string) sizeSpec {

 func parsePreviewWindow(opts *previewOpts, input string) {
 	layout := input
+	opts.hidden = false
 	if strings.HasSuffix(layout, ":hidden") {
 		opts.hidden = true
 		layout = strings.TrimSuffix(layout, ":hidden")

Thanks for the report. Lingering hidden property is not what I intended, it's just a bug. I'll apply your patch.

Ok, thanks !

In case other people end up here, when you have a default option of :hidden for the preview-window, you can override that with :nohidden but not :right, :left or similar.


feat: Implement ANSI support for Round

Which issue does this PR close?
Closes #466 .
Rationale for this change
Improves compatibility with spark
What changes are included in this PR?
ANSI support for Drop by adding input checks when ANSI mode enabled.
How are these changes tested?
val df = Seq(Int.MaxValue, Int.MinValue).toDF("a")
df.write.parquet("/tmp/int.parquet")
spark.read.parquet("/tmp/int.parquet").createTempView("t")

scala> spark.conf.set("spark.comet.ansi.enabled", true)

scala> spark.conf.set("spark.sql.ansi.enabled", true)

scala> spark.conf.set("spark.comet.enabled", true)

scala> spark.sql("select a, round(a,-1) from t").show

Ensure the above raises:
org.apache.spark.SparkArithmeticException: [ARITHMETIC_OVERFLOW] Overflow. If necessary set "spark.sql.ansi.enabled" to "false" to bypass this error.

I've just created a test that reproduces the error so far. I plan to keep working on this but I am having problems understanding the codebase and where the Round implementation is coming from. This is my first PR to the project so I am taking this as a learning exercise:
I've been investigating both:

https://github.com/apache/datafusion-comet/pull/471
https://github.com/apache/datafusion-comet/pull/500

And from my understanding I probably have to create a new native/core/src/execution/datafusion/expressions/round.rs to modify:
https://github.com/apache/datafusion-comet/blob/main/spark/src/main/scala/org/apache/comet/serde/QueryPlanSerde.scala#L1892-L1895
To something like:
diff --git a/spark/src/main/scala/org/apache/comet/serde/QueryPlanSerde.scala b/spark/src/main/scala/org/apache/comet/serde/QueryPlanSerde.scala
index 51b32b7..890703f 100644
--- a/spark/src/main/scala/org/apache/comet/serde/QueryPlanSerde.scala
+++ b/spark/src/main/scala/org/apache/comet/serde/QueryPlanSerde.scala
@@ -1889,7 +1889,7 @@ object QueryPlanSerde extends Logging with ShimQueryPlanSerde with CometExprShim
           val optExpr = scalarExprToProto("pow", leftExpr, rightExpr)
           optExprWithInfo(optExpr, expr, left, right)

-        case r: Round =>
+        case r: Round(failOnError) =>

And from my understanding I might also have to add the Drop definition to core/src/execution/proto/expr.proto.
I might be quite lost around here so I would appreciate if the above sounds right or I am completely lost here.

Thanks for picking this up @raulcd. I'll be happy to help you navigate this.
So Spark defines Round as:
case class Round(
    child: Expression,
    scale: Expression,
    override val ansiEnabled: Boolean = SQLConf.get.ansiEnabled)

in QueryPlanSerde, we have case r: Round, which is fine, but we currently ignore the value in r.ansiEnabled.
When serializing to protobuf, we use the generic ScalarFunction:
message ScalarFunc {
  string func = 1;
  repeated Expr args = 2;
  DataType return_type = 3;
}

Perhaps we should add an extra field here for fail_on_error?

Perhaps we should add an extra field here for fail_on_error?

That's interesting, probably some of the other ScalarFunc  might need to send the fail_on_error flag too in order to match ANSI mode so that seems like a good idea to me.
I've tried to do it on this commit: https://github.com/apache/datafusion-comet/pull/989/commits/6d0b46c88452a90a380b6f78da6fa2f0045b17ef
As per where to really check for the Overflow Error I guess we could do something like the stab I took on the following commit: https://github.com/apache/datafusion-comet/pull/989/commits/113ec6d8ffb38e3599f6bab03050f135f4c691cf
I'll have to check how to fix this error for Spark 3.3 too:
Error:  /__w/datafusion-comet/datafusion-comet/spark/src/main/scala/org/apache/comet/serde/QueryPlanSerde.scala:1930: value ansiEnabled is not a member of org.apache.spark.sql.catalyst.expressions.Round


Figure out how diagrams should work

For issue #119  @pdaniell contributed Illustrator files. I converted them to Tikz via Inkscape (Poppler import, svg2tikz export) and then ran a script to convert the color names to ones that are now defined in open-logic.sty. tikzscale makes the images the right size, but does not scale line widths so if someone provides an AI or even an Inkscape file with different line widths from those first ones they will look different and possibly not good at all.

Need to define a diagram style in the wiki
Figure out if tikzscale is the best way to scale diagrams
Put the sources and scripts in a separate repository
wrapfig down't seem to work next to theorem environments, so having figures be only half the line width and text wrap around doesn't work (it's ok in the biographies since the photos show up next to regular paragraph text)

Richard I have added a new version of the composition diagram. All the assets are prefixed with "composition_outlinestroke" and the succeeded by the appropriate file suffix. Find these here:
https://github.com/pdaniell/logic.open/tree/master/assets/diagrams
What I did in illustrator was change the "strokes" to shapes themselves. If you can try to see if that works, I will convert the other function diagrams. Otherwise, I can try to look for other solutions to the scaling.


Beam hardening not observed in results

Hi guys,
In my recent simulations, I found that beam hardening is not significant in the reconstruction results. To verify this, I built a water cylinder phantom and simulated the projection data with XCIST under a 120 kV spectrum. The reconstruction is done with ASTRA toolbox. Here is what I got.

I also plotted the center row.

Results show that there is no beam bardening artifact at all.
My scan protocal
protocol.scanTypes = [1, 1, 1]              # flags for airscan, offset scan, phantom scan

# Table and gantry
protocol.scanTrajectory = "Gantry_Helical"  # name of the function that defines the scanning trajectory and model
protocol.viewsPerRotation = 600             # total numbers of view per rotation
protocol.viewCount = 600                    # total number of views in scan
protocol.startViewId = 0                    # index of the first view in the scan
protocol.stopViewId = protocol.startViewId+protocol.viewCount-1 # index of the last view in the scan
protocol.airViewCount = 50                  # number of views averaged for air scan
protocol.offsetViewCount = 50               # number of views averaged for offset scan
protocol.rotationTime = 40.0                # gantry rotation period (in seconds)
protocol.rotationDirection = 1              # gantry rotation direction (1=CW, -1 CCW, seen from table foot-end)
protocol.startAngle = 0                     # relative to vertical y-axis (n degrees)
protocol.tableSpeed = 0                     # speed of table translation along positive z-axis (in mm/sec)
protocol.startZ = 0                         # start z-position of table
protocol.tiltAngle = 0                      # gantry tilt angle towards negative z-axis (in degrees)
protocol.wobbleDistance = 0.0               # focalspot wobble distance
protocol.focalspotOffset = [0, 0, 0]        # focalspot position offset

# X-ray tube technique and filtration
protocol.mA = 8                             # tube current (in mA)
protocol.spectrumCallback = "Spectrum"      # name of function that reads and models the X-ray spectrum
protocol.spectrumFilename = "tungsten_tar7_120_unfilt.dat" # name of the spectrum file
protocol.spectrumScaling = 1                # scaling factor such that spectrum is in photons / mA / s / mm^2 at 1000 mm
protocol.bowtie = []                        # name of the bowtie file (or [])
protocol.filterCallback = "Xray_Filter"     # name of function to compute additional filtration
protocol.flatFilter = []            # additional filtration - materials and thicknesses (in mm)
protocol.dutyRatio = 1.0                    # tube ON time fraction (for pulsed tubes)

Physics configurations
# Geometric and energy sampling
physics.energyCount = 110
physics.monochromatic = -1
physics.colSampleCount = 1
physics.rowSampleCount = 1
physics.srcXSampleCount = 1
physics.srcYSampleCount = 1
physics.viewSampleCount = 1

# Flags to determine what has to be recalculated each view
physics.recalcDet = 0
physics.recalcSrc = 0
physics.recalcRayAngle = 0
physics.recalcSpec = 0
physics.recalcFilt = 0
physics.recalcFlux = 0
physics.recalcPht = 0
physics.recalcDet = 0

# Noise on/off settings
physics.enableQuantumNoise = 0
physics.enableElectronicNoise = 0

# Internal physics models
physics.rayAngleCallback = "Detector_RayAngles_2D"
physics.fluxCallback = "Detection_Flux"
physics.scatterCallback = ""
physics.prefilterCallback = "Detection_prefilter"
physics.crosstalkCallback = ""
physics.lagCallback = ""
physics.opticalCrosstalkCallback = ""
physics.DASCallback = "Detection_DAS"

# I/O preferences
physics.outputCallback = "WriteRawView"

Scanner protocol
# Scanner geometry
scanner.detectorCallback = "Detector_ThirdgenCurved" # name of function that defines the detector shape and model
scanner.sid = 617.0                         # source-to-iso distance (in mm)
scanner.sdd = 1140.0                        # source-to-detector distance (in mm)
scanner.detectorColsPerMod = 1024           # number of detector columns per module
scanner.detectorRowsPerMod = 1024           # number of detector rows per module
scanner.detectorColOffset = 0.0             # detector column offset relative to centered position (in detector columns)
scanner.detectorRowOffset = 0.0             # detector row offset relative to centered position (in detector rows)
scanner.detectorColSize = 0.45              # detector column pitch or size (in mm)
scanner.detectorRowSize = 0.45              # detector row pitch or size (in mm)
scanner.detectorColCount = scanner.detectorColsPerMod     # total number of detector columns
scanner.detectorRowCount = scanner.detectorRowsPerMod     # total number of detector rows
scanner.detectorPrefilter = []              # detector filter

# X-ray tube
scanner.focalspotCallback = "Source_Uniform" # name of function that defines the focal spot shape and model
scanner.targetAngle = 7.0                   # target angle relative to scanner XY-plane (in degrees)
scanner.focalspotWidth = 1.0
scanner.focalspotLength = 1.0

# Detector
scanner.detectorMaterial = "CsI"            # detector sensor material
scanner.detectorDepth = 3.0                 # detector sensor depth (in mm)
scanner.detectionCallback = "Detection_EI"  # name of function that defines the detection process (conversion from X-rays to detector signal)
scanner.capacitor = 0.5                     # capacity of the readout capacitor (in pF)
scanner.readoutVolt = 5                     # voltage for readout ADC (in V)
scanner.maxReadout = 65535                  # maximum readout
scanner.detectionGain = 10.0                # factor to convert energy to electrons (electrons / keV)
scanner.detectorColFillFraction = 1.0       # active fraction of each detector cell in the column direction
scanner.detectorRowFillFraction = 1.0       # active fraction of each detector cell in the row direction
scanner.eNoise = 10.0                       # standard deviation of Gaussian electronic noise (in electrons)

Any idea why there is no beam hardening artifact?

Hi Tianling, I'd like to double check the recon first. Could you run the simulation with a phantom that has some structures, so that we can make sure the recon works correctly?

Hi Tianling, I'd like to double check the recon first. Could you run the simulation with a phantom that has some structures, so that we can make sure the recon works correctly?

Hi, here is a recon example on male lung phantom. I turned off noise simulation in this example.

Hi Tianling,
Do you still have the issue that it doesn't show BH artifacts?
If yes, maybe try: 1) update the code to the latest version; 2) use the sample main/examples/Sim_Sample_Analyic.py, AND remove the bowtie (set cfg.protocol.bowtie = "").

One more suggestion is that you may try the analytical water phantom, we have demonstrated BH artifacts in a study (will be published soon), in the latest code, please refer xcist\main\examples\Sim_Sample_Analyic.py
If you have more questions, please let us know.


[SPARK-35693][SS][TEST] Add plan check for stream-stream join unit test

What changes were proposed in this pull request?

The changed unit test was introduce in https://github.com/apache/spark/pull/21587, to fix the planner side of thing for stream-stream join. Ideally check the query result should catch the bug, but it would be better to add plan check to make the purpose of unit test more clearly and catch future bug from planner change.
Why are the changes needed?

Improve unit test.
Does this PR introduce any user-facing change?

No.
How was this patch tested?

Changed test itself.

cc @cloud-fan (original author) if you have time to take a look, thanks.

Test build #139549 has started for PR 32836 at commit cf9b7b9.

Close & Reopen PR to trigger unit test on github action again.

Rebased to latest master.

Test build #139559 has started for PR 32836 at commit 534459b.

Kubernetes integration test unable to build dist.
exiting with code: 1
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/44075/

Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/44075/

Test build #139549 has finished for PR 32836 at commit cf9b7b9.

This patch passes all tests.
This patch merges cleanly.
This patch adds no public classes.

Kubernetes integration test starting
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/44086/

Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/139549/

Test build #139559 has finished for PR 32836 at commit 534459b.

This patch passes all tests.
This patch merges cleanly.
This patch adds no public classes.

Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/139559/

thanks, merging to master!

Kubernetes integration test status failure
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/44086/

Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/44086/

Thank you @cloud-fan for review!


Fix to header misplacement in minimap

Issue: https://github.com/microsoft/vscode/issues/210198
Fixes bug where header would appear in wrong location in minimap when using Fill or Fit (when the file length causes Fit to start compressing the minimap).
It was previously always displaying the header in the location where it would be displayed if Proportional were selected.
Before:

After:

@microsoft-github-policy-service agree


Deactivate special signs for haskell applicative etc?

Wich setting is it that enables the translation of haskell commands such as <*> etc and how can i deactivate this?

If you want to disable all concealing and use normal Haskell symbols, set
let g:no_haskell_conceal = 1

in your ~/.vimrc.local file. You can also selectively enable/disable individual symbol substitutions by setting the g:hscoptions variable as described here

@favetelinguis did this do what you needed?

Well, a lot of time has passed. Consider closing it.

Sorry for the very late reply. Yes that fixed the problem, thanks!


torch.optim.lr_scheduler.ReduceLROnPlateau not registered

🐛 Describe the bug
For some reason, PyTorch's ReduceLROnPlateau learning rate scheduler is not registered as a subclass of LRScheduler. This causes Tango's registration to fail to register it, as Tango uses a subclass of LRScheduler check to see whether a given class ought to be registered.
Suggested fix: manually include ReduceLROnPlateau in Tango's registration code. I'd be happy to open a PR for this.
Versions
ai2tango==1.0.2
torch==1.13.0

OK, I actually see that ReduceLROnPlateau.step actually requires a metrics argument, which would complicate Tango's training implementation, so the fix is not as easy as I thought.


Just random crop 16 images from  a video?

I have questions about the input of images.I have researched the code, found that just random crop 16 images from a video as input. And the other frames just throw away.
Does the original paper mean this? Just my own doubts, hope to get answers, thanks!
for i in range(s_index, s_index + num_frames_per_clip):       image_name = str(filename) + '/' + str(filenames[i])       img = Image.open(image_name)       img_data = np.array(img) ret_arr.append(img_data)

Random is good for training, and you may take frames from one file so many times that every frame shoud be taken times.So ,there is no data-wasting if you set enough steps/epochs.

Random is good for training, and you may take frames from one file so many times that every frame shoud be taken times.So ,there is no data-wasting if you set enough steps/epochs.

I see, thanks!


Plugin based provider info.

The PR still has a small amount of tidying up to do, but it's in a state where it should be reviewed.
Levi, previously you have criticized me both for changing too much and having PR's that make the code ugly. Please bear in mind while you review this PR that I have chosen to err on the side of doing the minimal changes possible, but that has left some places that I think ought to be cleaned up further e.g. the method AurynInjector::makeClass is defintely not what I consider clean code, but I avoided changing it to read better, to minimise the lines changes in the PR.
Also I do try to avoid changing stuff at random. If you think I've changed something for no good reason, we will have a more productive conversation if you ask me why I've changed something rather than straight away criticizing me for doing something that you don't instantly like.
The commits for the PR are in the following chunks:

2dd3 - Splitting the holding of the information about what classes/params to use from the Injector into a separate ProviderPlugin class. Regardless of your views of the rest of the changes, I think this should be done as currently the Provider class is just doing too damn much.

To maintain backwards compatibility for people who are already using Auryn:

The actual injection class is now called AurynInjector.
Provider is now a facade that makes AurynInjector and a StandardProviderPlugin and passes the method calls through to the appropriate class, so people shouldn't see any change in how they call Auryn unless they want to upgrade to creating the exact ProviderPlugin to use and initializing the injector with it.

bad4 - Adding class chain constructor information. This has no external effect but it refactors the property beingProvisioned into an ordered array that holds the hierarchy of things being constructed by the injector. That array is passed to the StandardProviderPlugin, which completely ignores it, as that plugin doesn't resolve what to inject based on class hierarchy.

2fa6 - Added Class Contructor Chain plugin. This is what the two commits above were leading up to. This ProviderPlugin does use the chainClassConstructor information to allow you to do things that I think a fully featured DIC needs to be able to do.

Customising log level for certain classes
class Logger {
    function __cosntruct($logLevel) {...}
}

class SomeClassThatIsWorkingFine {
    funciton __construct(Logger $logger){...}
}

class SomeClassThatNeedsToBeDebugged {
    funciton __construct(Logger $logger){...}
}

$providerPlugin->define('Logger', [':logLevel' => 'warn']);
$providerPlugin->define('Logger', [':logLevel' => 'info'], ['SomeClassThatNeedsToBeDebugged']);

$classThatIsWorkingFine = $provider->make('SomeClassThatIsWorkingFine');
$classThatNeedsToBeDebugged = $provider->make('SomeClassThatNeedsToBeDebugged');

The above code creates two loggers, one set to 'warn' one set to 'info' for the two classes.
Being able to use more than on DB connection
class DBConnection {
	function __construct($server, $username, $password){...}
}

class ArchiveDBProxy  {
    function __construct(DBConnection $dbConnection){...}
}

class LiveDBProxy {
    function __construct(DBConnection $dbConnection){...}
}

//Moves stuff safely from the liveDB to the archiveDB
class DBArchiver {
    function __construct(ArchiveDBProxy $archiveDB, LiveDBProxy $liveDB) {...}
}

$providerPlugin->define(
    'DBConnection',
    [   ':server' => $archiveServerIP,
        ':username' => 'someusername',
        ':password' => 12345,
    ],
    ['ArchiveDBProxy']
);

$providerPlugin->define(
    'DBConnection',
    [   ':server' => $liveServerIP,
        ':username' => 'someusername',
        ':password' => 12345,
    ],
    ['LiveDBProxy']
);

$injector->make('DBArchiver')

I know you both feel the injector is getting more complicated than you would like. However I think the code needs to be just complex enough to support how users are trying to use it. The above two use-cases are both valid cases that Auryn doesn't currently support.
Obviously the nice thing about having the ProviderPlugin separate from the actual injector is that we don't have to have it like that (i.e. could leave the ClassConstructorChainPlugin out of the repo, if you really hate it) and also don't have to support peoples crazy ideas about how to define the information used by the injector. So instead of either having to support PR's to allow custom definition, we can just tell people to make their own plugin.
There are small tidy up commits after that one, just to improve some naming, and comments.
Things I know I need feedback on/have questions about myself:

I put all the methods that the injector uses when it creates objects into ProviderInjectionPlugin rather than putting them in ProviderPlugin which currently contains the methods that are used by users when setting up the plugin. I think all of the methods in that interface should be using the normalizedClass name, but as I said, i avoided tidying some things up to make the PR be as minimal as possible.

Question, is there any point to splitting them like that? It seems like it might be a good idea, but also falls under YAGNI. And yes I also need to document those methods.
Also, I think the names for these interfaces suck, but I can't think of good names, so suggestions please.

There are are currently some poor method names. I think we should change the following with some suggetsions of better name for them

prepare => setInitCallable
getPrepareDefine => getInitCallable
getInterfacePrepares => getInterfaceInitCallables
getDelegate => getDelegation
isDelegated => hasDelegation
isDelegated isn't actually required - the code should be able to be refactored to just call getDelegate; it's only the getParamDefine that requires the is function as null is a valid define to use as a param, but it's not for delegation. (Also I'm pretty sure that there's a bug in getInterfacePrepares.)
It may be worth me just doing the tidy up of stuff I consider crap code/naming in a separate branch and then you guys can pick and choose the cleanups you approve of and reject the ones you don't.

I haven't deeply checked that the InjectorBuilder against the refactored separation of the injector/plugin. The tests for it pass so I hope it's fine.

The checking of whether something is a valid callable when delegation is setup is not a good idea. At best it means that the code for every class that is used as a delegate gets pulled into the script and has reflection done on it, which is not great for speed. It also means that you can't setup a function delegate that hasn't been loaded yet - which seems a dumb limitation.

Is there a really good reason for it being there that I've missed? I realise detecting errors early is nice, but it seems a bad tradeoff here.

I realise that the code coverage on the ClassConstructorChain plugin isn't at 100%. Also it doesn't use the CCC for prepares or aliases. I will try to get it to closer to 100% soon. Also I guess this might need some documenatation.


Add links to headers and apply Gramarly fixes and suggestions

Add links to headers
Apply Gramarly fixes and suggestions

Thanks for the PR! I've pulled in the first commit and taken some of the suggestions from the second - many of the suggestions were British vs American English issues, and a few others I didn't agree with.

Thanks for the PR! I've pulled in the first commit and taken some of the suggestions from the second - many of the suggestions were British vs American English issues, and a few others I didn't agree with.

Awesome! Thanks for this awesome book!


Update kong config

removed need for the user configure the LFH host IP
removed hosts clause from the kong matching on each transaction
removed http from the kong config, since that port isn't open anyway

Tested on dev & server compose profiles, plus Azure and LinuxONE.