Jobs on ibm_qasm_simulator fail due to wrong extraction of name from IBMBackend instance

When running a job with the new primitives (or rather the estimator) I get this error:
Traceback (most recent call last):
  File "C:\Users\poc\Anaconda3\envs\qiskit\lib\site-packages\qiskit\algorithms\minimum_eigensolvers\vqe.py", line 253, in evaluate_energy
    job = self.estimator.run(batch_size * [ansatz], batch_size * [operator], parameters)
  File "C:\Users\poc\Anaconda3\envs\qiskit\lib\site-packages\qiskit_ibm_runtime\estimator.py", line 249, in run
    return super().run(
  File "C:\Users\poc\Anaconda3\envs\qiskit\lib\site-packages\qiskit\primitives\base\base_estimator.py", line 233, in run
    return self._run(
  File "C:\Users\poc\Anaconda3\envs\qiskit\lib\site-packages\qiskit_ibm_runtime\estimator.py", line 313, in _run
    return self._session.run(
  File "C:\Users\poc\Anaconda3\envs\qiskit\lib\site-packages\qiskit_ibm_runtime\session.py", line 36, in _wrapper
    return func(self, *args, **kwargs)
  File "C:\Users\poc\Anaconda3\envs\qiskit\lib\site-packages\qiskit_ibm_runtime\session.py", line 143, in run
    job = self._service.run(
  File "C:\Users\poc\Anaconda3\envs\qiskit\lib\site-packages\qiskit_ibm_runtime\qiskit_runtime_service.py", line 934, in run
    hgp = self._get_hgp(
  File "C:\Users\poc\Anaconda3\envs\qiskit\lib\site-packages\qiskit_ibm_runtime\qiskit_runtime_service.py", line 491, in _get_hgp
    raise QiskitBackendNotFoundError(
qiskit.providers.exceptions.QiskitBackendNotFoundError: "Backend <IBMBackend('ibmq_qasm_simulator')> cannot be found in any hub/group/project for this account."

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "C:\Users\poc\Documents\quantum-chemistry-on-quantum-computers\quantum_chemistry_on_quantum_computers\ground_state_energy_calc.py", line 365, in run
    self.minimum_eigensolver_result = self._solve(initial_point=_initial_point)
  File "C:\Users\poc\Documents\quantum-chemistry-on-quantum-computers\quantum_chemistry_on_quantum_computers\ground_state_energy_calc.py", line 895, in _solve
    vqe_result = self.minimum_eigensolver.compute_minimum_eigenvalue(
  File "C:\Users\poc\Anaconda3\envs\qiskit\lib\site-packages\qiskit\algorithms\minimum_eigensolvers\vqe.py", line 191, in compute_minimum_eigenvalue
    optimizer_result = self.optimizer.minimize(
  File "C:\Users\poc\Anaconda3\envs\qiskit\lib\site-packages\qiskit\algorithms\optimizers\scipy_optimizer.py", line 148, in minimize
    raw_result = minimize(
  File "C:\Users\poc\Anaconda3\envs\qiskit\lib\site-packages\scipy\optimize\_minimize.py", line 708, in minimize
    res = _minimize_slsqp(fun, x0, args, jac, bounds,
  File "C:\Users\poc\Anaconda3\envs\qiskit\lib\site-packages\scipy\optimize\_slsqp_py.py", line 374, in _minimize_slsqp
    sf = _prepare_scalar_function(func, x, jac=jac, args=args, epsilon=eps,
  File "C:\Users\poc\Anaconda3\envs\qiskit\lib\site-packages\scipy\optimize\_optimize.py", line 263, in _prepare_scalar_function
    sf = ScalarFunction(fun, x0, args, grad, hess,
  File "C:\Users\poc\Anaconda3\envs\qiskit\lib\site-packages\scipy\optimize\_differentiable_functions.py", line 158, in __init__
    self._update_fun()
  File "C:\Users\poc\Anaconda3\envs\qiskit\lib\site-packages\scipy\optimize\_differentiable_functions.py", line 251, in _update_fun
    self._update_fun_impl()
  File "C:\Users\poc\Anaconda3\envs\qiskit\lib\site-packages\scipy\optimize\_differentiable_functions.py", line 155, in update_fun
    self.f = fun_wrapped(self.x)
  File "C:\Users\poc\Anaconda3\envs\qiskit\lib\site-packages\scipy\optimize\_differentiable_functions.py", line 137, in fun_wrapped
    fx = fun(np.copy(x), *args)
  File "C:\Users\poc\Anaconda3\envs\qiskit\lib\site-packages\qiskit\algorithms\minimum_eigensolvers\vqe.py", line 256, in evaluate_energy
    raise AlgorithmError("The primitive job to evaluate the energy failed!") from exc
qiskit.algorithms.exceptions.AlgorithmError: 'The primitive job to evaluate the energy failed!'

Something close to a minimal example is here:
from qiskit_ibm_runtime import Estimator, QiskitRuntimeService, Session
from qiskit_ibm_provider import IBMProvider
from qiskit.algorithms.minimum_eigensolvers import VQE
from qiskit.circuit.library import EfficientSU2
from qiskit.algorithms.optimizers import SLSQP

qasm_backend=IBMProvider().get_backend("ibm_qasm_simulator")
service = QiskitRuntimeService()
with Session(service=service, backend=qasm_backend) as session:
    estimator = Estimator(session=session)
    estimator.set_options(shots=1000)
    minimum_eigensolver = VQE(
        estimator=estimator,
        ansatz=EfficientSU2(num_qubits=2),
        optimizer=SLSQP(),
    )
    vqe_result = minimum_eigensolver.compute_minimum_eigenvalue(
        operator=TaperedPauliSumOp(SparsePauliOp(['II', 'IZ', 'ZI', 'ZZ', 'XX'],
              coeffs=[-1.05398915+0.j,  0.39313145+0.j, -0.39313145+0.j, -0.01122705+0.j,
  0.18136666+0.j]), coeff=1.0) # this operator is pseudocode for the typical VQE hydrogen molecule example (too verbose to copy my whole script...)
    )

I tracked down the problem to this line in the code.
The Session class gets the backend name from backend.name if the backend is an instance of IBMBackend.
Else it falls back at some point to the string representation of the backend object.
In above mentioned case it falls back to the string "Backend <IBMBackend('ibmq_qasm_simulator')".
This is caused by some confusion of IBMBackend.
There are 2 different IBMBackends

The first one can be imported from qiskit_ibm_provider and is the IBMBackend(1) on which ibmq_qasm_simulator is based.
The other one is used in Session and is imported from qiskit_ibm_runtime. This is the IBMBackend(2) in this line

Both implementations of IBMBackend are very similar (only some details are different) and both inherit from Backend in qiskit.providers.backend.py
Since this is a bug in the interface between qiskit_ibm_runtime and qiskit_ibm_provider I'm not sure whether this repo or the qiskit_ibm_provider repo is the better one to place this issue. Feel free to port the issue to qiskit_ibm_provider.
Possible fix
The 2 different implementations of IBMBackend should be merged and only one of them should be used in all qiskit packages.
As a quick-and-dirty workaround one could import both IBMBackends and do the isinstance() check with both to get the correct backend.name.
The issue is somewhat related to #534

Now it gets even more confusing. Shouldn't there be only a "single source of truth" in programming? As it seems right now both service.get_backend() and IBMProvider().get_backend() do exactly the same job. So, which one is preferred? The new qiskit tutorials around primitives I have in mind all use the IBMProvider for this task.
So, at least the documentation and tutorials are misleading then...
And yet the problem stays that it is very difficult for a user to find out that IBMBackend and IBMBackend are two different classes and that the Session fails for one but not for the other.
So, please consider one of the following cases

Drop support for IBMBackend and enforce using the string (but this would enforce the user to manually call backend.name which wouldn't be that user friendly and somewhat counter-intuitive in the sense that strings are preferred over the "official" qiskit IBMBackend class)
Support both IBMBackends (most user friendly and would also be in the sense of #534 )
Add an error message that makes it actually easier to find this bug without hours of diving deep into the source code (as it happened to me); e.g. via checking if the specified backend is an instance of str, and if not raise an error accordingly.

Still, I wonder about the sense of 2 IBMBackend classes in different qiskit subpackages and I would like them to be merged. There might be design reasons, which I don't know of, that prevent this. In that case I would highly appreciate if you took care of the issue with one of the suggestions in above list.

By the way, here are the package versions I use if it is of relevance.
qiskit 0.39.3
qiskit_ibm_provider 0.1.0
qiskit_ibm_runtime 0.8.0

As it seems right now both service.get_backend() and IBMProvider().get_backend() do exactly the same job. So, which one is preferred? The new qiskit tutorials around primitives I have in mind all use the IBMProvider for this task.

@cpossel Can you point us to specific primitive tutorials that use IBMProvider? Primitives is a qiskit-ibm-runtime concept, so it should not reference IBMProvider at all, which belongs to qiskit-ibm-provider.
Having said that, we do have plans to reuse the code from qiskit-ibm-provider in qiskit-ibm-runtime, which would solve this issue. That's going to take some time though, so we should first need to fix tutorials.

@jyu00 Thanks for the information! It is reassuring that a merge of those two is planned for the future.
I don't have all tutorials/references at hand which I used to gather the information. The main problem lies actually in omitting information about the 2 different packages and as you can imagine it is difficult to point to tutorials that omit some information ;)
I'll try either way with one tutorial in https://github.com/Qiskit/qiskit-ibm-runtime#readme:
https://github.com/Qiskit/qiskit-ibm-runtime#sampler and https://github.com/Qiskit/qiskit-ibm-runtime#estimator use a string as input for the backend: backend="ibmq_qasm_simulator". The final paragraph https://github.com/Qiskit/qiskit-ibm-runtime#accessing-your-ibm-quantum-backends suggests to get a backend via backend = service.backend('ibmq_qasm_simulator'). So, the conclusion is to say 'Okay, a backend object can be passed to the Session. Then I can just re-use my old code' which then uses qiskit-ibm-provider.
So, a warning/comment about this backend issue (or just a short notice that it is highly recommended to pass a string instead of a backend instance) in the examples of section https://github.com/Qiskit/qiskit-ibm-runtime#primitives would be very helpful already.
I'll keep looking around for other (explicite or implicite) examples of that confusion and will post them here as soon as I find them.

A better error message has been added if a backend from the wrong service is used - closing this for now
https://github.com/Qiskit/qiskit-ibm-runtime/pull/671


Why is the eks-default VM running on the private subnet and not on the control-plane subnet?

Using the current version of this project I see that the VM named "sas-eks-default" ("sas" is the cluster name) is running in subnet "sas-private-" which is a surprise as I thought the eks-default machines should run on the "control-plane" subnets and not on the "private" subnets.
Is this a bug or my understanding is incorrect about placement of VMs on subnets?

@miaeyg, none of the worker nodes are expected to be placed in either of the two control-plane subnets. The single private subnet, which is located in a single AZ, is the subnet that all worker node IPs should be allocated from. Your "sas-eks-default" VM is running in the private subnet as expected.

Hi @dhoucgitter, I have 4 "sas-eks-generic" instances + 1 "sas-eks-cas" instance + 1 "sas-eks-default" instance
All of them are running on the single "private" subnet.
I do not understand what is supposed to run on the "control-plane" subnets...


wsProxy config doesnt work anymore in 0.10.4

Steps to reproduce
Setup nextjs up using the websocket proxy & docker approach outlined on: https://vercel.com/docs/storage/vercel-postgres/local-development
Using<EMAIL_ADDRESS>Expected result
wsProxy callback is executed, which allows next.js app to connect
Actual result
wsProxy is never executed and all queries fail.
I put a debugger in the wsProxy callback but it was never reached in 0.10.4
Downgraded back to 0.9.5 fixes the problem, havent tried previous versions yet
Environment
Logs, links

hey, @marcodejongh  do you think this error Error: All attempts to open a WebSocket to connect to the database failed. Please refer to https://github.com/neondatabase/serverless/blob/main/CONFIG.md#websocketconstructor-typeof-websocket--undefined. Details: fetch failed
is somehow related to what you are experiencing I am using "^0.9.5" version of @neondatabase/serverless


MegaBot Profile

When doing MegaBot commands, MegaBot would respond with an embed, and at the bottom in the footer there would be an image of its profile picture. I was unable to figure out how to do this in discord.py.

Use set_footer(*, text="text", icon_url="pfp link")

Thank you suspense.


Add Abort Callback to Run

Adds the option to provide a callback which is executed when a run is aborted:
with Run(abort_callback=my_callback):
   ...

Latest on this is that _exit has been used to cover the Python-based simulation as opposed to terminal/external process. Need a solution which:

Will stop the Python simulation if an alert is thrown
Won't stop the script if it is NOT a python based simulation but rather uses add_process, perhaps use of add_process switches this off?

@wk9874  what do you think?


How to support ldap with using username and password when the harbor use ldap_auth mode

I need input "-w" when use ldapsearch command. So, how harbor can support this mode.

can you give more info about what "-w" means in your use case?

@hainingzhang sorry, this is my fault, i set a wrong value to dn. close this issue


improve docs

you're welcome

it always seems impossible until it's done
thank you for invaluable contribution kind sir


Iterate over base options

Previously it didn't look like baseOptions was actually iterated over, since executionTimeout was hard-coded in there.
This pull request addresses that and also adds a helper method so that baseOptions and options use the same path.

:+1:


Enable to create Azure Function from VS Code

<Please be sure to remove any private information before submitting.>
Repro steps:
<Enter steps to reproduce issue>
Action: azureFunctions.createFunction
Error type: Error
Error Message: You must have the .NET CLI installed to perform this operation.
Version: 0.12.0
OS: win32

Do you have the .NET CLI installed and on your path? If not you can install it here: https://www.microsoft.com/net/download

Closing due to lack of response. Feel free to re-open with more info


SetWindowsHookEx not installed error at Startup of PC

Microsoft PowerToys version
0.57.2
Running as admin

[X] Yes

Area(s) with issue?
Always on Top, Awake, ColorPicker, Developer file preview, FancyZones, FancyZones Editor, Image Resizer, Keyboard Manager, MD Preview, Mouse Utilities, PDF Preview, PDF Thumbnail, G-code Preview, G-code Thumbnail, PowerRename, PowerToys Run, Shortcut Guide, STL Thumbnail, SVG Preview, SVG Thumbnail
Steps to reproduce
Happens with every Restart of PC.  Lenovo i7 Yova Laptop
✔ Expected Behavior
No error messages nor need to manually re-install WIndowsHookEx for every Power Toy every time I use.
❌ Actual Behavior
I get the Uninstalled error at startup, have to manually re-install for every Toy!
Other Software
I do not get a compatibility error.  I turned off Power Toys Run since I have Outlook installed, but that didn't due anything to correct the problem.  I tried using as User and as Admin, still got the same error.

Uninstalled error at startup? What error is this?
What error message are you getting? This is not very helpful to understand what's going on.
Perhaps a screenshot would help?
/needinfo


Support for add_scalars in log

Is your feature request related to a problem? Please describe.
Sometimes we want to use add_scalars instead of add_scalar in the log results. For example, our loss function is a multitasking loss function, and we want to be able to display a graph of each loss function in the same graph.

def training_step(self, batch, batch_nb):
    # REQUIRED
    x, y = batch
    y_hat = self.forward(x)
    loss = F.cross_entropy(y_hat, y)
    # tensorboard_logs = {'train_loss': loss}
    #We want to draw multiple loss function curves in the same coordinate system
    tensorboard_logs = {'train_loss1': loss,
                        'train_loss2': loss*2,
                        'train_loss3': loss*3,}
    return {'loss': loss, 'log': tensorboard_logs}

But in this way, we will get:

The root of the problem is that the log in test-tube only supports add_scalar and does not support add_scalars. In order to achieve the desired effect, I intend to change it like this:
def training_step(self, batch, batch_nb):
    # REQUIRED
    x, y = batch
    y_hat = self.forward(x)
    loss = F.cross_entropy(y_hat, y)
    # tensorboard_logs = {'train_loss': loss}
    #We want to draw multiple loss function curves
    # tensorboard_logs = {'train_loss1': loss,
    #                     'train_loss2': loss*2,
    #                     'train_loss3': loss*3,}
    #modify like this
    tensorboard_logs = {'losses':{'train_loss1': loss,
                        'train_loss2': loss*2,
                        'train_loss3': loss*3,}}
    return {'loss': loss, 'log': tensorboard_logs}

Not only that, but you also need to change the “log” function in test-tube/log.py to:

Then we can get

Is this scheme feasible?

great suggestion! would welcome this PR!

@williamFalcon
Hello, it is better to use the add_image(s) to visualize some intermediate results during the training process! For example, when using the visual attention mechanism, we hope to see the heat map of attention during the training process.

A desirable solution for using the above features is to add a new metric such as "log_imgs_metrics".

Do you think this kind of function is necessary?

you can add anything you want during training... look at the GAN example.
But generally you can just do:
self.logger.experiment.add_image
etc....
access self.logger.experiment from anywhere in your lightning module

In gan.py it is trained with a single GPU. However, in multi-GPU (dp), add_image only displays (batch_size/nGPU) images, but not the entire batch_size image.

correct. that’s by design. you wouldn’t see a difference otherwise because you are sampling from the model which on every gpu has the same weights, so it doesn’t matter


Update best-practices.md

I added a row in the B2C fundamentals section table, focused on with Securing B2C , and a link to our B2C Security Architecture guidance.   This should be top of mind for B2C customers as many are not protected against DDOS, BOTs  (customers who implemented B2C custom domains, but didn't place a WAF in front of their b2c deployment), therefore we want to emphasize this as a core priority in deploying B2C

@kengaderdus
Can you review the proposed changes?
Important: When the changes are ready for publication, adding a #sign-off comment is the best way to signal that the PR is ready for the review team to merge.
#label:"aq-pr-triaged"
@MicrosoftDocs/public-repo-pr-review-team

@kengaderdus - Thanks for reviewing! I committed your suggestion. Please #sign-off if this PR is ready to merge.

#sign-off


Getting "!  internal error" frequently when forking our application and copying over the DB:

This internal error has become a common sight for us recently when we try to fork and provision a new DB. I am happy to provide more information (and real app names, etc) offline. Let me know how I can help track this down.
00:19:05.750 + echo 'The target app doesn'\''t appear to exist, so I'\''m creating it by forking first-app:'
00:19:05.751 The target app doesn't appear to exist, so I'm creating it by forking first-app:
00:19:05.751 + heroku fork --app first-app forkee-app
00:19:09.590 Forking first-app... done. Forked to forkee-app
00:19:09.878 Deploying build/d to forkee-app... done
00:19:13.476 Adding addon logentries:tryit to forkee-app... done
00:19:17.004 Adding addon papertrail:fixa to forkee-app... done
00:19:17.463 Adding addon loaderio:basic to forkee-app... done
00:19:17.572 Adding addon pgbackups:auto-month to forkee-app... Skipped addon pgbackups:auto-month
00:19:17.573  !    No such add-on plan.
00:19:17.751 Adding addon deployhooks:http to forkee-app... Skipped addon deployhooks:http
00:19:17.752  !    http hook is missing config: url
00:19:20.174 Adding addon newrelic:stark to forkee-app... done
00:19:20.463 Adding addon scheduler:standard to forkee-app... done
00:19:25.128 Adding addon heroku-postgresql:standard-0 to forkee-app... done
00:20:48.260 Status: preparing
Status: preparing
Status: preparing
Status: preparing
Status: preparing
Status: preparing
Status: preparing
Status: preparing
Status: preparing
Status: preparing
Status: preparing
Status: preparing
Status: preparing
Status: preparing
Status: preparing
Status: preparing
Status: available
Status: available
00:20:48.261 Transferring HEROKU_POSTGRESQL_BROWN to HEROKU_POSTGRESQL_GOLD...
00:21:17.886
00:21:17.886  !  internal error
00:21:17.887
00:21:17.887 There was an error forking to forkee-app.
00:21:17.887
00:21:17.887 In order to avoid being charged for any resources on forkee-app, it is being destroyed...
00:21:18.043 Destroying app forkee-app... done

saw another one of these in a totally different part of the codebase, I think it's on the server side

so we think it's related to polling, I need to add something to fork like this: https://github.com/heroku/heroku/pull/1531
working on it

just pushed a fix out for this

Thank you so much for the quick fix  @dickeyxxx!

Ditto @dickeyxxx, thanks for the fix.


bind variable is null

Using Oracle database and ojdbc6 jar, when I try to execute a query like this:
select * from table where name=:name;
I enter a varchar2 as the name but the generated query is
select * from table where name=NULL;
The query works fine if I hard-code a value instead of binding a variable.
Thanks!

Can't reproduce.
What's your DBeaver version?

3.7.3 Enterprise.  I just figured it out.  When I type in the value and click OK the value is not saved.  I just went back and by accident I typed ENTER key on the field and then it worked.  I guess the UI is a little confusing in that regard.
Thanks for your help.


adding methods based on SQL lag and lead

See https://duckdb.org/docs/sql/window_functions#:~:text=-- compute the difference between the current amount%2C and the previous amount%2C by order of time
SELECT amount - lag(amount) OVER (ORDER BY time) FROM sales%3B

Possible to use rolling method instead.


Add dotenv to dependencies

CATEGORY
Choose one

[x] Enhancement (new features, refinement)

SUMMARY
This lib is optional but helpful, let's add it to setup.py

Codecov Report

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

@@           Coverage Diff           @@
##           master    #7330   +/-   ##
=======================================
  Coverage   64.94%   64.94%
=======================================
  Files         424      424
  Lines       20598    20598
  Branches     2281     2281
=======================================
  Hits        13378    13378
  Misses       7097     7097
  Partials      123      123

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 07d9dbd...c5b5538. Read the comment docs.

@mistercrunch could you provide more context as to how/where this will be used. Additionally you mention the package is optional and there's been a tendency to remove optional (configuration dependent) packages per here.

This just enables .flaskenv to get picked up, without install requirements-dev.txt. It makes setting up the environment a tiny bit easier.

@mistercrunch sorry I wasn't aware of the .flaskenv file. What was the reason for migrating away from superset run towards using flask run (per the CONTRIBUTING.md file)?

It was somewhat necessary for the Flask 1.0 upgrade if I remember well. Something around using flask run CLI over the app.run method. It seemed to fit the pattern we had before with gunicorn.
It's better for us to use the rich flask run command that is rich and has lots of options instead of maintaining our own equivalent.

@mistercrunch apologies for the delay in responding. I recently upgraded some other Flask apps to Flask 1.0 and was exposed to the newer way of configuring/running applications.
I agree that including the dependency for python-dotenv makes sense however I was wondering whether this should be included in requirements-dev.txt rather than requirements.txt as i) one actually doesn't require this to run Superset, and ii) I was wondering whether there was a concern that in production any CLI calls, i.e., superset db upgrade would be run using the FLASK_ENV='development' environment per here which reads the .flaskenv if the dotenv package is present.
Also in your PR in the CONTRIBUTING.md by including this package, I believe
cd superset
FLASK_ENV=development flask run -p 8088 --with-threads --reload --debugger

now simplifies to,
flask run -p 8088 --with-threads

Right, all this is assuming you're firing up the command from inside the repo too. I don't think flask run makes sense for production anyways, people should really gunicorn or nginx which from my understanding wouldn't be affected by this.

@mistercrunch people will still be using the CLI commands in production, i.e., we run superset db upgrade, superset init, etc. as part of every production deploy which would inherit the .flaskenv environment.


Add wrapper to all tables with scroll property

Add a parent div tag with overflow scroll to allow horizontal scroll

I assume the whitespace stuff is dependant on https://github.com/openregister/openregister-java/pull/150?

I've closed #150 and will re-do after this.


small changes

add: Coverage reporting to Codecov

Codecov Report

:exclamation: No coverage uploaded for pull request base (main@2ad9865). Click here to learn what that means.
Patch has no changes to coverable lines.

Additional details and impacted files
@@           Coverage Diff           @@
##             main      #25   +/-   ##
=======================================
  Coverage        ?   92.28%
=======================================
  Files           ?        8
  Lines           ?      285
  Branches        ?       34
=======================================
  Hits            ?      263
  Misses          ?       15
  Partials        ?        7

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

:umbrella: View full report at Codecov.
:loudspeaker: Do you have feedback about the report comment? Let us know in this issue.


[util,bazel,dvsim] make entropy buffers default entropy source for build randomization

This implements what is described here, and below, to enable using the entropy buffer files for the sole source of entropy for:

generating LC state encodings
generating the OTP memory map
Additionally, since both of the above are used to generate OTP images, this also changes how OTP images are generated by Bazel and dvsim.

This also checks-in default entropy buffer files to be used in testing, which can be overwritten right before tapeout with a secure entropy source before regenerating netlist constants.
Updates to the Generation of LC State Encodings and OTP Memory Map
Below I describe the old vs. new architecture for generating LC state encodings and the OTP memory map.

Updates to the Generation of OTP Images
Below I describe the old vs. new architecture for generating OTP images.

I think we can close this PR since we are going to go a separate route from entropy buffers it seems.


Revert "removed optional annotation from non-optional fields (#400)"

This reverts commit f6e079c5dd386256a27974338a111da3b628fb9b.
With https://github.com/nutanix-cloud-native/cluster-api-provider-nutanix/pull/400 we made prismCentral a mandatory field in NutanixCluster. As a result, the test is now failing on both periodic jobs since and presubmits on new PRs with the following errors.
Expected success, but got an error:
    <*errors.StatusError | 0xc000411cc0>:
    NutanixCluster.infrastructure.cluster.x-k8s.io "cluster-ntnx-client-qwqlsf" is invalid: spec.prismCentral: Required value
    {
        ErrStatus: {
            TypeMeta: {Kind: "", APIVersion: ""},
            ListMeta: {
                SelfLink: "",
                ResourceVersion: "",
                Continue: "",
                RemainingItemCount: nil,
            },
            Status: "Failure",
            Message: "NutanixCluster.infrastructure.cluster.x-k8s.io \"cluster-ntnx-client-qwqlsf\" is invalid: spec.prismCentral: Required value",
            Reason: "Invalid",
            Details: {
                Name: "cluster-ntnx-client-qwqlsf",
                Group: "infrastructure.cluster.x-k8s.io",
                Kind: "NutanixCluster",
                UID: "",
                Causes: [
                    {
                        Type: "FieldValueRequired",
                        Message: "Required value",
                        Field: "spec.prismCentral",
                    },
                ],
                RetryAfterSeconds: 0,
            },
            Code: 422,
        },
    } failed [FAILED] Timed out after 300.000s.

The clusterclass tests are also failing because variables are used to specify values for prismCentral and controlPlaneEndpoint in a a cluster created with a clusterclass reference and clusterclass patches patch those values into the cluster which was not accounted for when making the change.
Running kubectl apply --kubeconfig /var/folders/g3/lb827bt96z10xz_m_c2xn93w0000gp/T/e2e-kind1856394220 -f -
stderr:
The NutanixClusterTemplate "nutanix-quick-start-nct" is invalid:
* spec.template.spec.controlPlaneEndpoint: Required value
* spec.template.spec.prismCentral: Required value

This PR reverts the changes made in https://github.com/nutanix-cloud-native/cluster-api-provider-nutanix/pull/400

if the fields are indeed required, then they should remain as required in the underlying type imo.
For other providers that have required fields in cluster class resources that we add patches for to fill in required information (e.g. machine type in CAPA clusters), we use a dummy value PLACEHOLDER in the cluster class resources that makes the resource valid via the API. We then ensure that the variable used in the CC patch is required to ensure that the patch is applied and this dummy value is replaced.
I think this is worth an upstream discussion as it's a common use case, but I don't think reverting the previous PR here is actually the right thing to do.

@thunderboltsid can we post the exact test which fails since i would preferred to fix that test case by passing the required values instead of reverting the change. change has actually done what it is implemented for.

if the fields are indeed required, then they should remain as required in the underlying type imo.
For other providers that have required fields in cluster class resources that we add patches for to fill in required information (e.g. machine type in CAPA clusters), we use a dummy value PLACEHOLDER in the cluster class resources that makes the resource valid via the API. We then ensure that the variable used in the CC patch is required to ensure that the patch is applied and this dummy value is replaced.
I think this is worth an upstream discussion as it's a common use case, but I don't think reverting the previous PR here is actually the right thing to do.

Reverting the PR is done to fix the broken CI so we can unblock other changes until we fix this in a better tested manner.

@thunderboltsid can we post the exact test which fails since i would preferred to fix that test case by passing the required values instead of reverting the change. change has actually done what it is implemented for.

All clusterclass tests.


Generic defaults doesn't enforce typechecks for function arguments without the default value inheritance

TypeScript Version:  4.1.3 (also tried the older one)
Search Terms:
default generic with partial
Expected behavior:
Function arguments with
 <GenericType = SomeDefaultType>(val:Partial<GenericType>)=>{}

works the same way as
const someVal:Partial<SomeDefaultType>

So it requires the user to specify only known properties in the function arguments while also making them optional.
In example below i simply want
doStuff({
  customKey: 44
});

to behave the same way like
const val:Partial<SomeModel> = {
  customKey:44
};

Actual behavior:
User can simply pass any value to the function if it's generic variable isn't extending the default type like so
<GenericType extends SomeDefaultType = SomeDefaultType>(val:Partial<GenericType>)=>{}

But this simply doesn't fit my use-case because it requires GenericType to always inherit the SomeDefaultType which is bad interface.
Related Issues:
No
Code
type SomeModel = {
  key:number;
}

function doStuff<ValModel = SomeModel>(val:Partial<ValModel>){
  console.log(val);
}

// works as expected (customKey is blocked as it doesn't exist in original type)
const val:Partial<SomeModel> = {
  customKey:44
};

// but here validation is simply broken and this is the problem i actually having
doStuff({
  customKey: 44
});

function doWeirdStuff<ValModel extends SomeModel = SomeModel>(val:Partial<ValModel>){
  console.log(val);
}

// suddently this one works fine, but it isn't correct for my use-case because forces user to extend default type
doWeirdStuff({
  customKey: 44
});

Output
"use strict";
function doStuff(val) {
    console.log(val);
}
// works as expected (customKey is blocked as it doesn't exist in original type)
const val = {
    customKey: 44
};
// but here validation is simply broken and this is the problem i actually having
doStuff({
    customKey: 44
});
function doWeirdStuff(val) {
    console.log(val);
}
// suddently this one works fine, but it isn't correct for my use-case because forces user to extend default type
doWeirdStuff({
    customKey: 44
});

Compiler Options
{
  "compilerOptions": {
    "noImplicitAny": true,
    "strictNullChecks": true,
    "strictFunctionTypes": true,
    "strictPropertyInitialization": true,
    "strictBindCallApply": true,
    "noImplicitThis": true,
    "noImplicitReturns": true,
    "alwaysStrict": true,
    "esModuleInterop": true,
    "declaration": true,
    "experimentalDecorators": true,
    "emitDecoratorMetadata": true,
    "moduleResolution": 2,
    "target": "ES2017",
    "jsx": "React",
    "module": "ESNext"
  }
}

Playground Link: Provided

Okay it seems this behaviour isn't partial issue because i have the same issues with regular generic defaults
https://www.typescriptlang.org/play?ts=4.1.3#code/C4TwDgpgBAyg9gWwgWTgEwgGygXigbwFgAoKKAawhAC4A7AVwQCMIAnAbhIF8SSAzerQDGwAJZxaUNHBjB6fPgB4AagENMqDNjzwkmrAD4AFADd11NRvRYAlEVJQhEgM5xMEAHSY4Ac1PqbTmIeYhIAejCoAHc4VnJnKFUEiAAPSBEINCgjIXpnYEQAaSooUQSmbyFKLKTS4Ck4CGdaAHJ61LL60UlY0R9u9ShQSBsSJ1p8qDNMal0Ua20CEjJc-KKqagAWTe4g8MimenqACzZoadE0VTEJUoTnUQQwTBAoJlY4SklVWizgY7KdyGpygYA+FQgCFKiRE9HULygx1UJm6PhI0lk8j4RnsKzyBQQxRoUG23ECJCAA
type SomeModel = {
  key:number;
}

function doStuff<ValModel = SomeModel>(val:ValModel){
  console.log(val);
}

// works as expected (customKey is blocked as it doesn't exist in original type)
const val:SomeModel = {
  customKey:44
};

// but here validation is simply broken and this is the problem i actually having
doStuff({
  customKey: 44
});

Expeceted behaviour

if user calls doStuff<CustomModel>(value) with some custom generic type the value should be validated against this type and it works just fine
if user calls doStuff(value) without custom generic model the default one should be enforced (SomeModel in my case) so value will be validated against SomeModel type

Actual behaviour

the first case with custom arguments works just fine doStuff<CustomModel>(value)
the second case with the default one doesn't work at all - it allows user to pass any value he wants like in <ValModel = any> case (but at fact we are using <ValModel = SomeModel>)

Since this is not the Partial issue anymore i don't sure if it is a bug, but also can't find any information on how to achieve the behaviour i want without enforcing user to inherit SomeModel in his custom types.

I don’t totally understand what you want, but the actual behavior you have described is 100% how it’s supposed to work. If you have a question about how to use generics, please ask on StackOverflow and you will get good advice there.


ytsubs error - Unable to download JSON metadata: HTTP Error 400

Error started during last 12 hours:
ERROR: Unable to download JSON metadata: HTTP Error 400: Bad Request (caused by HTTPError());
Verbose output:
[debug] System config: []
[debug] User config: []
[debug] Command-line args: ['-u', u'PRIVATE', '-p', u'PRIVATE', '--download-archive', 'youtube-dl-archive.txt', '--dateafter', 'now-30day', '--output', '%(upload_date)s-%(uploader)s-%(title)s.%(ext)s', '--verbose', ':ytsubs']
[debug] Encodings: locale UTF-8, fs utf-8, out UTF-8, pref UTF-8
[debug] youtube-dl version 2<IP_ADDRESS>
[debug] Python version 2.7.9 - Darwin-14.1.0-x86_64-i386-64bit
[debug] exe versions: ffmpeg 2.5.3, ffprobe 2.5.3, rtmpdump 2.4
[debug] Proxy map: {}
[youtube:subscriptions] Downloading login page
[youtube:subscriptions] Logging in
[youtube:subscriptions] Youtube Subscriptions: Downloading webpage
[youtube:subscriptions] Youtube Subscriptions: Downloading page #1
ERROR: Unable to download JSON metadata: HTTP Error 400: Bad Request (caused by HTTPError()); please report this issue on https://yt-dl.org/bug . Make sure you are using the latest version; type  youtube-dl -U  to update. Be sure to call youtube-dl with the --verbose flag and include its complete output.
  File "/usr/local/bin/youtube-dl/youtube_dl/extractor/common.py", line 308, in _request_webpage
	return self._downloader.urlopen(url_or_request)
  File "/usr/local/bin/youtube-dl/youtube_dl/YoutubeDL.py", line 1611, in urlopen
	return self._opener.open(req, timeout=self._socket_timeout)
  File "/usr/local/Cellar/python/2.7.9/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 437, in open
	response = meth(req, response)
  File "/usr/local/Cellar/python/2.7.9/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 550, in http_response
	'http', request, response, code, msg, hdrs)
  File "/usr/local/Cellar/python/2.7.9/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 469, in error
	result = self._call_chain(*args)
  File "/usr/local/Cellar/python/2.7.9/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 409, in _call_chain
	result = func(*args)
  File "/usr/local/Cellar/python/2.7.9/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 656, in http_error_302
	return self.parent.open(new, timeout=req.timeout)
  File "/usr/local/Cellar/python/2.7.9/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 437, in open
	response = meth(req, response)
  File "/usr/local/Cellar/python/2.7.9/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 550, in http_response
	'http', request, response, code, msg, hdrs)
  File "/usr/local/Cellar/python/2.7.9/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 475, in error
	return self._call_chain(*args)
  File "/usr/local/Cellar/python/2.7.9/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 409, in _call_chain
	result = func(*args)
  File "/usr/local/Cellar/python/2.7.9/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib2.py", line 558, in http_error_default
	raise HTTPError(req.get_full_url(), code, msg, hdrs, fp)

The problem has now stopped.


import utility

I have trouble to import utility from the root of the project due to this
I have modified and added sys.path.append("..")  for myself ch3/map_copy.py
'''
Listing 3.3: Copying and mapping buffer objects
'''

import sys
sys.path.append("..")

import pyopencl as cl
import numpy as np
import utility

as well I have modified project structure
    pyopencl-in-action\
        __init__.py
        utility.py
        ch3\
            __init__.py
            map_copy.py
            buffer_test.py
        ch4\
            __init__.py
            float_config.py
            double_test.py

at least on my side without those modification I run into
(cl) ~/work/pyopencl-in-action/ch3$ python buffer_test.py
Traceback (most recent call last):
  File "buffer_test.py", line 7, in <module>
    import utility
ModuleNotFoundError: No module named 'utility'

due to compatibility with python2 I added into opencl-print-info.py
from __future__ import print_function

The imports are relative to the root directory, and must be run as a module from the top dir.
python3 -m "ch3.buffer_test"

true for python3 but python2?

If I remember correctly, you should be able to do the following in python 2
from ..utility import function

Yeah - but ..
    from ..utility import *
ValueError: Attempted relative import in non-package


Create config file that stores prototype configuration

This PR creates a new config.js file for storing configuration that users may want to edit.
Currently, users can edit:

Service name - used in the header
Port
Whether auth is enabled or not.

NB - I've not mentioned the config file in any docs - not sure where it would go. However, the default service name points the user at the location of the file to edit.

I've updated it so that users can pass {{$serviceName}}Your overridden name{{/serviceName}} to override this config.

@joelanman typo fixed. Anything else to do?

Thanks for this Ed, sorry it's taken a while for me to look at it.
Could we get some documentation for this change? Doesn't have to be loads

@joelanman suggestions for where to put it in the docs?

Possibly as the first item in the getting started list:
https://github.com/alphagov/govuk_prototype_kit/blob/master/docs/getting-started.md
because they'll need to update the name very early on. However I'm worried about throwing people at JSON from the start.

I'm don't think we need to be too worried about json - I hope it's clear you just need to change what's in the quote marks.
Do you think that's needed given the default is Set service name in /app/config.js, and we don't currently provide guidance on how to set the service name?

Updated to put the service name in double-quotes to allow for the case that the service name includes an apostrophe.

Hey @edwardhorsford can you please rebase this branch on top of master, so the Travis checks can run against it.

@gemmaleigh should be done.


Mono: Improve API assembly load error message on exported games

Will print a different message if the reason for the error is an API hash mismatch.

Thanks!


Switch host compiler version

Based on the request in #75
@joker-eph I was simply using the latest clang version Debian testing has to offer: https://packages.debian.org/bullseye/clang
Which one would you recommend instead?
Version 9 from http://apt.llvm.org/?
What would be the rationale for picking the host compiler?
Always use the latest clang release?

I don't have a strong rational to offer here, not sure about the pros/cons :)

I know this is old and closed but shouldn't we be using the minimum version llvm states it supports (clang 3.5)

Our rationale was: The pre-merge tests sound find problems that block other developers and our assumption was that LLVM developers are using a rather fresh version of the tools.
What would be the rationale for the old one?

A rational would be that we want to detect if someone if landing a change with a feature not supported, and building with an old compiler is a good way to figure it out.

A rational would be that we want to detect if someone if landing a change with a feature not supported, and building with an old compiler is a safer testing.

Precisely that. If we give users the option to build llvm from source and they are using an old host compiler(maybe their distro default) but its listed as supported they should be able to build llvm with it. Should a developer try to land a patch that will break on an old but supported version we should block it (or have a long hard discussion about increasing the minimum supported version.)


Custom hasPermission Reply Message

This is probably not the best way to implement this feature but it's been tested and does work so I thought I'd see if it's okay. Basically this allows the hasPermission method to, instead of returning true/false (which do still work and will show the default no permission response) will also allow the user to return a string. The string will be used to send a custom reply when the hasPermission method does not pass. This allows you to more accurately tell your users what they're missing to use the command.
The way I'm doing it is probably disgusting, but it works. Also I had to do a weird method for the hasPermission variable because for some reason when I did return false it was complaining about reading from null.

Wait a minute idk if this would kill the help command or anything else that calls isUsable.

Okay maybe that'll fix that

The help command will need to be updated for the new behaviour.


Sublime Text Vue Syntax Highlighting for File Types

How can i default a .vue extension as Vue Component syntax on sublime

There's an option to "open all with current extension as"


Add support use proxy

Change httpClient from createDefault to createSystem. For support use proxy settings in cli

@destanyinside Please check proxy supporting at v1.1.0 release


Can't update team includes_all_repositories setting via API

Gitea Version
1.15.3
Git Version
No response
Operating System
No response
How are you running Gitea?
K8s via Helm
Database
PostgreSQL
Can you reproduce the bug on the Gitea demo site?
Yes
Log Gist
No response
Description
I'm writing a script that automagically configures a new Gitea instance based on a config file. I want to update the includes_all_repositories property on a team object but it doesn't seem to work.
When I run
curl -X 'GET' \
  'https://gitea.example.com/api/v1/teams/20?access_token=e569***2' \
  -H 'accept: application/json'

I get
{
  "id": 20,
  "name": "devops_users",
  "description": "test users",
  "organization": null,
  "includes_all_repositories": true,
  "permission": "write",
  "units": null,
  "can_create_org_repo": true
}

When I change includes_all_repositories via the api
curl -X 'PATCH' \
  'https://gitea.example.com/api/v1/teams/20?access_token=e569***2' \
  -H 'accept: application/json' \
  -H 'Content-Type: application/json' \
  -d '{
  "includes_all_repositories": false,
"name": "devops_users"
}'

I get
{
  "id": 20,
  "name": "devops_users",
  "description": "test users",
  "organization": null,
  "includes_all_repositories": true,
  "permission": "write",
  "units": [
    "repo.code",
    "repo.issues",
    "repo.ext_issues",
    "repo.wiki",
    "repo.pulls",
    "repo.releases",
    "repo.projects",
    "repo.ext_wiki"
  ],
  "can_create_org_repo": true
}

I'm not able to change the includes_all_repositories property via the API. It does work when I do the change manually. but not via the API. Or is there a special procedure for updating the includes_all_repositories setting?
Screenshots
No response

About Gitea version, did you mean 1.14.1?

I'm sorry 4.1.1 is the version of the Helm chart. The Gitea version is 1.15.3

You must send the permission alongside includes_all_repositories and make sure you are not editing the owners team.
Example:
{
  "includes_all_repositories": true,
  "permission": "read"
}

Or
{
  "includes_all_repositories": true,
  "permission": "admin"
}

We close issues that need feedback from the author if there were no new comments for a month. :tea:


Export extensible classes in ESM compatible way

Resolves most of import incompatibilities between ESM and UMD builds (described by #7647), helpers need to be addressed still.

Helpers can be addressed by mapping them to globals in rollup config:
    globals: (m) => module === 'chart.js' ? 'Chart' : module.startsWith('chart.js/helpers/') ? 'Chart.helpers.' + module.substr(17) : undefined,

Helpers can be addressed by mapping them to globals in rollup config:

core and extras are inlined and not in a separate sub branch. Moreover, collection isn't exported in the UMD case at all

So the helpers global mapping needs to be a bit more complicated or we need to change the exports:
globals: (id) =>
  id === 'chart.js'
    ? 'Chart'
    : id.startsWith('chart.js/helpers/')
      ? ['core', 'color', 'extras'].includes(id.substr(17))
        ? 'Chart.helpers'
        : 'Chart.helpers.' + id.substr(17)
      : undefined,

I created a example repo for this: https://github.com/kurkle/chartjs-chart-mybar, including the dist folder of the rollup results.
A really simple test case extending the Bar controller,  registering that extension and consiming some helpers.
Transpiled to esm and umd.
This does not work with alpha.2 due to the translation of import {BarController} from 'chart.js' to Chart.BarController for the umd version.
previous comments script is used for mapping the helpers, that works fine.

And an ESM example project: https://codesandbox.io/s/still-hooks-xgd8x?file=/src/index.js just to verify the esm version works fine.

looking at https://github.com/kurkle/chartjs-chart-mybar/blob/master/src/index.js
does the ESM version have a default export ?

@sgratzl that's a good point. v3.0.0-alpha.2 does not. I needed to do import { Chart } from 'chart.js'

looking at https://github.com/kurkle/chartjs-chart-mybar/blob/master/src/index.js
does the ESM version have a default export ?

index.js is the entry for UMD bundle. index.esm.js if for ESM.


Hide the quest if the prerequisite is not validated

What does your feature do?
Add an option in the prerequisite menu "hide the quest if the player does not have the prerequisites"
This would allow the continuation of a quest to be hidden, but also to make the quest more realistic.
A npc tells you that he needs your help but in the end he doesn't know you enough to help him.

How would people use it?
When a player clicks on a npc, if he has the prerequisites for example enough quest points, the quest is visible in the list of quests offered.
Otherwise it is hidden

This option already exist in config.yml hide-locked-quests

Would it be possible to hide only certain quests ? (for example if the prerequisite is to have blocks that would allow the player to get them)

You can either hide ALL quests or no. It's based on testRequirement. If player meet req. It does show it, if it doesn't it does not show it.

Ok too bad, you can put the question tag and remove the enhancement and close the post if that is not possible, put the choice for each quest.
thank you for your reply


add always on top in menu

Adds a Float on Top menu toggle item that makes Hyper stay above every other window when enabled.

It's a very handy yet simple feature to have. It's the same that can be found in Quicktime/VLC and other apps.

Seems like you could write a plugin for this:
https://github.com/henrikdahl/hyper/blob/2f8bd25737260c58619501c587734e9e42d89403/app/index.js#L163

I think its far too simple to be a plugin.

A plugin is never too simple 😄
If something can be done as a plugin, it should be a plugin instead of a core Hyper feature

Fair enough, if someone is interested in turning this into a plugin feel free to use this code as reference ✌

Done: https://github.com/chabou/hyper-always-on-top 🎉


vdk-core: add ability to cancel remaining job steps

what: Added the ability to cancel the remaining job/template steps through the job_input interface.
why: This feature is required by users in certain cases e.g: if a data job depends on processing data from a source which has indicated no new entries since last run, then we can skip the execution.
testing: Tested locally with data job/templates and added functional tests.
Signed-off-by: Momchil Zhivkov<EMAIL_ADDRESS>

I think this is  a cool new feature. I've talked with some users in the past who have complained they cannot stop a job in the middle. We should popularize it after releasing it. Thanks for coming up with it.


Lua Cleanup

Added new function getObjectLoop to LuaUtils (shortcut to splitting the variable and stuff)
Majority of the Lua functions that used to split the object tags will now use getObjectLoop. Some functions that didn't originally split will use it for convenience
removeFromGroup now uses Reflect for groups to fix sprite group errors
doTweenColor will now use the sprite's current alpha for the new color IF no alpha value is provided on the hex color. Should fix transparent sprites alpha going back to 1
On colorFromString, if an alpha value is provided on the hex code (and starts with 0x), then it will subtract 8 instead of 6 to account for alpha
Changed leObj's type to FlxBasic on (set/get)ObjectOrder
Fixed startTween not holding the original tag
Added antialiasing as a Lua variable
luaSoundExists now formats the tag
loadSong now mutes opponent vocals

yo thank u larry


[WIP]: fix microRTPS bridge UART link

Currently the microRTPS bridge UART link is broken and it's resulting on continuous CRC errors on the agent side that after some seconds close the link. This is being investigated.
Also, it was verified that a stack increase was required to avoid the micrortps_client of causing and hardfault and rebooting the flight controller.

@AndrewWedemier thanks for your insights and your debugging effort, which ended-up helping me unblock this! Added you as a co-author in one commit, which was the commit that allows to have the bridge usable over UART.
Note that for setups which are to run at baud rates <=1MByte/sec, it's required to throttle the overall publishing using the -s option. So with the current default streams (per 07/20/2020), something like:
micrortps_client start -d /dev/ttyS2 -b 1000000 -v -w 6
./micrortps_agent -d /dev/ttyUSB1 -b 1000000 -v -w 6

works nice without any errors, though it introduces some latency on the link. The alternative is also increasing the baud rate. Found that using 1.5MByte/s with the current default streams is enough to have it work properly.
micrortps_client start -d /dev/ttyS2 -b 1500000 -v
./micrortps_agent -d /dev/ttyUSB1 -b 1500000 -v

Note that with the increase of the number of topics being streamed, and depending on each rates, this might change and might require changes on the stream rates.

Thanks @bkueng!


Initial migration of InfiniteScroll to TypeScript

Summary

Ticket Link
Fixes https://github.com/mattermost/mattermost-server/issues/16723
Related Pull Requests

Has server changes (please link here)
Has redux changes (please link here)
Has mobile changes (please link here)

Screenshots

Hello @djanda97,
Thanks for your pull request! A Core Committer will review your pull request soon. For code contributions, you can learn more about the review process here.

This PR has been automatically labelled "stale" because it hasn't had recent activity.
A core team member will check in on the status of the PR to help with questions.
Thank you for your contribution!
/cc @jasonblais @jfrerich @emilyacook

Hey @djanda97, is this PR still a draft? If so, do you plan on finishing it up for review?

Hi @devinbinnie, this PR can be closed for now. It might be a while until I can get some time to work on it.


Llava models are not consistent in response even after following specified prompt template

Model : llava-llama-3-8b-v1_1-int4.gguf
Clip : llava-llama-3-8b-v1_1-mmproj-f16.gguf
According to [docs](https://llmfarm.tech/docs/prompt_format , I set up the prompt template as follows,
[system](You are a helpful, respectful and honest assistant.)
 If I do the same after I start with only a text input followed by the image, I get response. Even in the latter, if we upload subsequent images, the response is still of the older one.

Hello. Could you please send me  prompt options screenshot. It looks like you have an empty first line.


Projection Pushdown over StreamingTableExec

Which issue does this PR close?

Closes #.
Rationale for this change

ProjectionExec with its input StreamingTableExec can be merged into a single StreamingTableExec, provided there is no evaluation or aliasing in ProjectionExec.
What changes are included in this PR?

projection_pushdown rule for physical plans is extended with StreamingTableExec.
Are these changes tested?

Yes.
Are there any user-facing changes?

I will go ahead and merge this. If there is anything we missed, let us know and we will promptly address with a follow-on PR.


Strict check on dropzone

I have created a new branch cue2 containing all the changes from upstream/master, cue and de7b6fa.


Extra profiling

Add some finer grained profiling to track exactly what time is spent inside of mpi calls.

Looks good.


Introducing list of tags to Keras model card

This PR solves #800
Resulting model card looks like this when given the tags list ["audio", "speech"].

BTW (commenting here because i just glanced at the code): maybe more future proof to create the yaml part of the model card using pyyaml (which is already a dependency of this lib anyways)
I remember that's what we did in transformers

Actually we already have repocard.py which could make things easier for this
https://github.com/huggingface/huggingface_hub/blob/main/src/huggingface_hub/repocard.py

@julien-c thanks for the tip, it looks much cleaner!

I think using pyyaml like this works, I will add some additional suggestions to this PR a bit later

The docs for this PR live here. All of your documentation changes will be reflected on that endpoint.

Merged main into this branch for other docs related changes and aligned docstring with main.

is there any formatter or style checker that can indicate if a docstring is fit? @osanseviero

Not sure, but as you can see at https://github.com/huggingface/huggingface_hub/pull/806#issuecomment-1084464233, the docs are actually built for you :fire:

I left metadata part as dictionary for convenience.
So if the task_name is seen, user receives warning, it's popped from kwargs and passed to metadata. I've also put a test to see if the warning is raised.
save_pretrained_keras(
                model,
                f"{WORKING_REPO_DIR}/{REPO_NAME}",
                tags=["test"],
                task_name="test",
                save_traces=True,
            )

@osanseviero my stupidity, I did fix them after I did a git add and I didn't add changes again apparently 😅😂 I was like "I could swear I changed them previously!!! am I hallucinating? 🥲" very sorry, I do listen to your comments before I resolve them, just saying.

Also, note that we're trying to merge other people's PRs instead of our own on this repo :)
(I should get on writing our policies and their variations for our repos)


Feat/new issuer page

What does this PR do?
Test PR for fixing codecov issue. It will be deleted.
Related ticket
Fixes #
Type of change

[ ] Chore
[ ] Bug fix
[ ] New feature
[ ] Documentation update

Check list

[ ] Unit tests for any smart contract change
[ ] Contracts and functions are documented

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

Project coverage is 94.14%. Comparing base (5bf5526) to head (a5e6754).
Report is 1 commits behind head on dev.

Additional details and impacted files
@@           Coverage Diff           @@
##              dev     #670   +/-   ##
=======================================
  Coverage   94.14%   94.14%
=======================================
  Files          30       30
  Lines         495      495
  Branches      115      115
=======================================
  Hits          466      466
  Misses         28       28
  Partials        1        1

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.


suggestion: Keybind for opening/closing recipe book

since the button moves when the book opens/closes it would be nice if you could just toggle it open/closed with a keybind.
I like to have it always closed in player inventory but always open in crafting table, but it seems like that might take more work to implement, so maybe the keybind would be a good compromise for now 🙏

I like to have it always closed in player inventory but always open in crafting table, but it seems like that might take more work to implement, so maybe the keybind would be a good compromise for now 🙏

vanilla does support per-screen book states but the crafting table and the player inventory are actually the same thing and i dont think it would be too extremely hard and its something i wanna do

Closing in favor of #58


Incorrect preview url generated for single repository multi-site setup

Describe the bug
When using a single repository to deploy multiple sites, Netlify CMS uses an incorrect preview URL in the editor header after saving a draft post.
To Reproduce

Have sites A (https://a.com) and B (https://b.com) on Netlify.
Use a single repository to build these websites. I don't mean have 2 websites in a single repository (2 subfolders), it's a single website (100% shared source code). Site-specific values like target URL change during the build process from environment variables. In Netlify, we do TARGET_URL=a npm run build and TARGET_URL=b npm run build respectively.
Edit an existing post on B and click Save.
Observe the preview URL redirects you to A.

Expected behavior
Preview URLs should point to the correct pull request preview.
Screenshots

N/A
Applicable Versions:

Netlify CMS version: 2.9.1
Git provider: GitHub
OS: Netlify
Browser version Chrome Version 74.0.3729.131 (Official Build) (64-bit)

Node.JS version:
Gatsby plugin Netlify CMS: 3.0.17

CMS configuration

We have configy_a.yml and config_b.yml which defines its collections. The collection definitions don't use any preview path configuration. Shared configuration is done in cms/cms.js like this.
const site = getSite();

init({
  config: {
    backend: {
      branch: 'master',
      name: 'git-gateway',
    },
    display_url: site.displayUrl, // https://a.com or https://b.com
    logo_url: 'path/to/logo.jpg',
    media_folder: 'path/to/media',
    public_folder: 'path/to/public',
    publish_mode: 'editorial_workflow',
    site_url: site.siteUrl, // https://a.com or https://b.com
  },
});

Additional context

Ah - the CMS grabs the first available status check that contains our internal list of keywords: https://github.com/netlify/netlify-cms/blob/9d5dbcde0a49dd50d0b6672bf424c05810eadca5/packages/netlify-cms-backend-github/src/implementation.js#L12
As you can see, the list currently consists of "deploy", so it will match both of the Netlify status checks on your pull requests, and just return the first one. This very repo also has two Netlify sites, so a PR will receive two statuses - notice the unique context strings for each:

I forgot to document this, but you can configure the exact context to look for amongst the statuses via the backend config using preview_context. You'll need to specify the entire context string. Based on the contexts in the image above, for example, I might do:
backend:
  name: github
  preview_context: netlify/netlify-cms-www/deploy-preview

@erquhart Great, thank you! I’ll try and update this issue

Hi @erquhart, I can confirm this fixes the preview issue!
const site = getSite();

init({
  config: {
    backend: {
      branch: 'master',
      name: 'git-gateway',
      preview_context: `netlify/${site.id}/deploy-preview`,
    },
    display_url: site.displayUrl, // https://a.com or https://b.com
    logo_url: 'path/to/logo.jpg',
    media_folder: 'path/to/media',
    public_folder: 'path/to/public',
    publish_mode: 'editorial_workflow',
    site_url: site.siteUrl, // https://a.com or https://b.com
  },
});

However, I observed another issue I have not previously noticed. I wonder if you know how to solve this one, too? Assume we have the same websites A and B and they look the same, just using a different copy. Both A and B use template homepage to render the homepage content. We go into CMS B and create a draft for updated homepage.
The issue:
If we go into CMS A and open the homepage, it shows us the draft from CMS B. When we inspect the pull request in repository, it is obvious it modifies only content from site B. Why does it then show up in CMS A?
Further observations:
Modifying this file from CMS A works as you'd expect. This means we are able to modify files related to site B from site A. Furthermore, in the Workflow tab, we see all of the drafts from site B.
Expected result:
Complete ability to sandbox sites A and B.

CMS instances don't have any special ownership of the content they edit, they're simply driven by their configuration, just like whatever static site generator your using. However the SSG tells the content apart is likely the same way you'll need to configure the CMS to target the right content.
Sent with GitHawk

@erquhart Gotcha, it will be Gatsby/GraphQL related issue I suppose. Thanks a lot!

Generally you'll handle it by keeping site A and B content in separate directories, or by using filter in your collection configuration to only show entries that have a given value, eg. if all site a entries had site: "a" and site b had site: "b" in their frontmatter, you could filter for that: https://www.netlifycms.org/docs/collection-types/#filtered-folder-collections

@erquhart Yes, that's how I handle it! The issue isn't that I see the wrong collections in the CMS, but when I open say page "index" located in src/pages/a/index.md, if there is an existing draft (pull request) from src/pages/b/index.md, that will get previewed in the CMS editor. Any subsequent changes including save/delete are incorrectly performed on this B file. The only thing that could be wrong that comes to mind right now is checking GraphQL frontmatter query.

@erquhart I managed to solved the other issue described above. FYI, the problem was that while I was generating different config.yml file for sites A and B, it used the same name values for index.md, i.e. index. All I had to do was to namespace name keys in config.yml, i.e. site-a-index and site-b-index. Everything works now as expected.


please provide bypass to the site stfly.cc

please provide with a bypass in fastforward for the site https://stfly.cc/5Lq4W

Duplicate of #1222


opencv api multi-threading

I found that this code will open multi-threading when calling OpenCV api when running. How can I close it? Thank you very much.

Could you provide more details? Do you mean there are dead threads not properly closed when the program terminates? What functionality were you using? If you can, can you find the line which opened the threads? I'd like to help with it's difficult to do so without these information.

When I run the code to extract the keyframes of many videos, I will check that the number of threads in the process will increase periodically and suddenly, and there are multiple threads in the sleep. Please find out which code will cause the number of threads to increase abruptly. Thank you very much.

In general, #pragma omp parallel for will spawn multiple threads. Hope this helps.


Support Nvidia Device-Plugin

It is likely to have Nvidia GPU as hardware acceleration on edge devices, in that case, it should be managed as custom resource so that Kubernetes can control those resource with deployment. Usually specific application requires GPU acceleration for AI processing. Cluster administrator should be able to bind Nvidia GPU to those containers.

Reference: https://github.com/NVIDIA/k8s-device-plugin


interpreter.py's _from_binary_external doesn't handle perm errs well.

Python35 has been mis-installed on my dev system. Some of the packages are owned root, read only root. (This is a diff issue which I'll be emailing root about).
However, Pex's interpreter identifier throws a "permission denied" error trying to get versions of those packages at the point it imports "pkg_resources". Which causes it to decide the interpreter as a whole is unusable, causing my python>3.0 requirement to fail to be satisfied...
Should it perhaps not yield a valid interpreter but without the extras portion of the identification data?

(This is a diff issue which I'll be emailing root about).

Hah!

Should it perhaps not yield a valid interpreter but without the extras portion of the identification data?

Perhaps, but its likely code downstream will fail. For example, pkg_resources is part of setuptools, and pex tries to install setuptools for the interpreter it's using and I suspect that step would then fail in your case.
It's not immediately clear to me how to teach pex to check for broken python distributions that are broken little-enough to be viable.
I'm going to mark this as answered but leave the issue open a bit to attach some cleanup PRs to - your prompt got me looking at some code where some dead bits stood out.

Hah!

Root did, in fact, email me back about ten minutes later have done a recursive chmod...
We have no idea why the package update didn't work properly.

Perhaps, but its likely code downstream will fail.

Fair enough!


Merge improvements from Technologicalpizza fork

https://github.com/TechnologicalPizza/lidgren-network-gen3

Hmm I don't think this PR would ever pass as I've done way too many changes for it to conform to the old API.
It would be better if this PR is used as a redirect to the fork directly.
https://github.com/TechnologicalPizza/lidgren-network-gen3
And changing to NET5.0 only kills Unity (though I used Span all over so it is already not viable for Unity).


View BFD neighbors is Routing Diagnostics view

In order to view BFD neighbors today, you would need to go into the shell , vtysh, and run the command 'show bfd peer'.
Is it possible to have an option to view BFD neighbors within the GUI?

I have most of the code for this, but still need to test it.

Thank you. Truly appreciate it.  Because the code is mostly there what is the turnaround time to making it into the next release?

#3487 adds BFD diagnostics for: "show bfd peers brief", "show bfd peers" and "show bfd peers counters".
This has been merged into the master branch.


add toc and notational conventions; split out changes section

Starting my review of the spec.
commit 1: adds an OCI header, toc, and notational conventions. Also simplifies the introduction and scope sections.
commit 2: split out the changes section into a separate document.
commit 3: clean up heading levels..
commit 4: nits
Signed-off-by: Mike Brown<EMAIL_ADDRESS>

Cool. Points addressed for now.
LGTM


align_to_tree_mafft_fasttree with 'auto' for n_threads only uses 1 thread with FastTreeMP

Bug Description
If you specify 'auto' for the n_threads argument in the align_to_tree_mafft_fasttree function, q2-phylogeny sets the OMP_NUM_THREADS environment variable to 0.  FastTreeMP issues a warning and then uses OMP_NUM_THREADS=1.
Steps to reproduce the behavior

Use n_threads='auto' in align_to_tree_mafft_fasttree on a machine with multiple processors.
Check the stderr/stdout messages from the pipeline:

Command: FastTreeMP -quote -nt /tmp/qiime2-archive-uwck28s2/c827dc99-ef57-4c83-abe4-42463c6c441b/data/aligned-dna-sequences.fasta

OMP: Warning #80: OMP_NUM_THREADS="0": value too small.
OMP: Info #104: OMP_NUM_THREADS value "1" will be used.
FastTree Version 2.1.10 Double precision (No SSE3), OpenMP (1 threads)

Expected behavior
The description of the 'auto' option in the docs say all available cores should be used, not just 1.
Computation Environment

OS: Tested on macOS 10.15 with 1.4 GHz Quad-Core Intel Core i5 proc using QIIME 2 2021.4
And Linux CentOS 7 with 16 processors using QIIME 2 2020.11

Comments

The FastTreeMP docs say that you can unset OMP_NUM_THREADS, and then it will use all available cores.

Thanks @pooranis!
When we first implemented this functionality (several years ago), setting OMP_NUM_THREADS=0 in older versions of FastTreeMP fell-back to setting the thread count to the max allowable, but it looks like this has changed in later versions of FastTreeMP to setting to the min:

We will put this on our TODO list to fix up, thanks for the report!


Ensure parsed mobiledocs have a blank marker

This allows a valid mobiledoc with zero sections (or one section with zero markers) to be parsed into an abstract with a text prompt.
It does not address https://github.com/bustlelabs/content-kit-editor/issues/57, but a fix for that should be similar. Spiking on it now, will push here.

@bantic this should fix #57, handling blank mobiledoc documents and blank initial DOM nodes.

:+1: merge at will


wasm: Cast from int to double causes compilation to emit llvm_trap

Add the following to HelloWasm/Program.cs:
    int toDoubleInt = 1;
    double castedDouble = (double)toDoubleInt;
    if (castedDouble == 1d)
    {
        PrintLine("(double) cast test : Ok.");
    }
    else
    {
        PrintLine("expected 1d, but was " + castedDouble.ToString());
        PrintLine("(double) cast test : Failed.");
        return 0;
    }

And it fails to run throwing a trap.  Compiling to asm.js shows in HelloWasm.js at HelloWasm_Program__Main:
$175 = ((($0)) + 177|0);
HEAP8[$175>>0] = 0;
$176 = ((($0)) + 178|0);
HEAP8[$176>>0] = 0;
$177 = ((($0)) + 179|0);
HEAP8[$177>>0] = 0;
_llvm_trap();
// unreachable;
}

It looks like that's not implemented. The implementation can be filled in at
https://github.com/dotnet/corert/blob/26089dafac96e489e132b216c0ddd7aa0f53e5e9/src/ILCompiler.WebAssembly/src/CodeGen/ILToWebAssemblyImporter.cs#L628

I thought I'd have a go at this, not really knowing too much about it so dont laugh.  The else above seems to be doing the reverse:
            else if ((toStoreKind == LLVMTypeKind.LLVMDoubleTypeKind || toStoreKind == LLVMTypeKind.LLVMFloatTypeKind) &&
                valueTypeKind == LLVMTypeKind.LLVMIntegerTypeKind)
            {
                //TODO: keep track of the TypeDesc so we can call BuildFPToUI when the integer is unsigned
                typedToStore = LLVM.BuildFPToSI(builder, source, valueType, "CastIfNecessaryFloat");
            }

So as there was a BuildSIToFP seemed logical to just do that (float on its own compiles so just doing double here for testing):
            else if (toStoreKind == LLVMTypeKind.LLVMIntegerTypeKind && valueTypeKind == LLVMTypeKind.LLVMDoubleTypeKind)
            {
                typedToStore = LLVM.BuildSIToFP(builder, source, valueType, "CastIfNecessarySIToFloat");
            }

But that generates a bunch of errors:
 FPTrunc only operates on FP
           %CastIfNecessaryFloat = fptrunc i64 %ldvalue269 to float
         FPTrunc only operates on FP
           %CastIfNecessaryFloat313 = fptrunc i64 %ldvalue312 to float
         FPExt only operates on FP
           %CastIfNecessaryFloat389 = fpext i16 %ldvalue388 to float
         FPExt only operates on FP
           %CastIfNecessaryFloat425 = fpext i8 %ldvalue424 to float
         FPExt only operates on FP
           %CastIfNecessaryFloat467 = fpext i8 %ldvalue466 to float
         FPExt only operates on FP
           %CastIfNecessaryFloat509 = fpext i16 %ldvalue508 to float
         FPExt only operates on FP
           %CastIfNecessaryFloat = fpext i16 %ldvalue239 to float
         FPExt only operates on FP
           %CastIfNecessaryFloat = fpext i8 %ldvalue to float
         FPExt only operates on FP
           %CastIfNecessaryFloat = fpext i8 %ldvalue to float
         FPExt only operates on FP
           %CastIfNecessaryFloat = fpext i16 %ldvalue to float
         FPExt only operates on FP
           %CastIfNecessaryFloat = fpext i16 %ldvalue to float
         FPTrunc only operates on FP
           %CastIfNecessaryFloat = fptrunc i64 %ldvalue to float

My question I suppose is: is LLVM but being synchronous in its API here and we need to build the conversion from scratch, or have I not understood a bunch of stuff and I'm missing some key things that need to be implemented in ILCompiler.WebAssembly.  Sorry for newbie questions.

It sounds like you're on the right general track. It looks like all of the errors you've shown are cases where the int type isn't 32-bits. Maybe there's some issue with widening/shrinking ints? I'd also suggest looking for a couple of the lines it's showing in tests\src\Simple\HelloWasm\obj\Debug\wasm\native\HelloWasm.txt. That can give you some context of what's happening in the method (was some type supposed to be converted that wasn't or something)?

Thanks, I hadn't seen that.  Sure enough restricting the BuildSIToFP to just int32s removes the problem.  The above FPExt/FPTrunc errors seem to come from other parts of the program as opposed to anything I've added in the Program.Main.  Here's an example:
  %ldvalue269 = load i64, i64* %CastIfNecessaryPtr268
  %CastIfNecessaryFloat = fptrunc i64 %ldvalue269 to float

As I understand FPTrunc, it's for truncation of floating point types hence its an error to be passed an i64.  So the question is how to find out what is generating the above code.  The only call I could find was in CastIfNecessary but that is protected by an if on the parameter types, so don't see how it could be that.

Bit more investigation, I added @hippiehunter change to get more meaningful names and output now starts
FPTrunc only operates on FP
           %CastFloatloc28_ = fptrunc i64 %Loadloc28_ to float

A breakpoint on the relevant line shows that LLVM.BuildFPCast is being called with a source of i64.  Looking then at Core.cpp in LLVM, we see
LLVMValueRef LLVMBuildFPCast(LLVMBuilderRef B, LLVMValueRef Val,
                             LLVMTypeRef DestTy, const char *Name) {
  return wrap(unwrap(B)->CreateFPCast(unwrap(Val), unwrap(DestTy), Name));
}

and then in Instructions.cpp
CastInst *CastInst::CreateFPCast(Value *C, Type *Ty,
                                 const Twine &Name,
                                 Instruction *InsertBefore) {
  assert(C->getType()->isFPOrFPVectorTy() && Ty->isFPOrFPVectorTy() &&
         "Invalid cast");
  unsigned SrcBits = C->getType()->getScalarSizeInBits();
  unsigned DstBits = Ty->getScalarSizeInBits();
  Instruction::CastOps opcode =
    (SrcBits == DstBits ? Instruction::BitCast :
     (SrcBits > DstBits ? Instruction::FPTrunc : Instruction::FPExt));
  return Create(opcode, C, Ty, Name, InsertBefore);
}

Looks to me like we should not be calling BuildFPCast without anything other than 2 floats and should be calling BuildSIToFP or  BuildUIToFP for signed and unsigned ints at least, not sure about other source types.  Does that makes sense?

@yowl, yes, it sounds like you've found the root cause... BuildFPCast is probably the wrong thing to call and we should likely be using BuildSIToFP or BuildUIToFP. It sounds like BuildFPCast does a bitwise coercion from int to float, which I don't think IL supports.

@morganbr thanks.  I'd create a PR but my attempt to create a test for this is causing a problem with a potential new bug.   I've added this simple cast test
        double d1 = 1d;
        double d2 = 1d;
        if (d1 == d2)
        {
            PrintLine("double equality test: Ok.");
        }
        int intToCast = 1;
        double castedDouble = (double)intToCast;
        if (castedDouble == 1d)
        {
            PrintLine("(double) cast test: Ok.");
        }
        else
        {
            if (d1 == 1d)
            {
                PrintLine("non casted double equaltity: Ok.");
            }
            var toInt = (int)castedDouble;
//            PrintLine("expected 1m, but was " + castedDouble.ToString());
            PrintLine($"(double) cast test : Failed. Back to int on next line");
            PrintLine(toInt.ToString());
            return 0;
        }

The relevant bit here that equates false when I'd expect true is
        int intToCast = 1;
        double castedDouble = (double)intToCast;
        if (castedDouble == 1d)
        {
            PrintLine("(double) cast test: Ok.");
        }

The other tests are just trying to narrow things down (little difficult as double.ToString() is not compiling).  Compiling this to asm gives this section
$Local33_ = ((($0)) + 132|0);
 HEAP32[$Local33_>>2] = 1;
 $Local33_879 = ((($0)) + 132|0);
 $Loadloc33_ = HEAP32[$Local33_879>>2]|0;
 $CastSIToFloatloc33_ = (+($Loadloc33_|0));
 $Local34_ = ((($0)) + 140|0);
 HEAPF64[$Local34_>>3] = $CastSIToFloatloc33_;
 $Local34_881 = ((($0)) + 140|0);
 $Loadloc34_ = +HEAPF32[$Local34_881>>2];
 $ceq883 = $Loadloc34_ == 1.0;
 $471 = $ceq883 << 31 >> 31;
 $Local72_ = ((($0)) + 209|0);
 $CastIntcmpop884 = $471&1;
 $CastIntcmpop884$expand_i1_val = $CastIntcmpop884&1;
 HEAP8[$Local72_>>0] = $CastIntcmpop884$expand_i1_val;
 $Local72_885 = ((($0)) + 209|0);
 $Loadloc72_$pre_trunc = HEAP8[$Local72_885>>0]|0;
 $Loadloc72_ = $Loadloc72_$pre_trunc&1;
 $ZExtOrBitCast887 = $Loadloc72_&1;
 $brfalse888 = ($ZExtOrBitCast887|0)==(0);
 if (!($brfalse888)) {
  $LoadAddressOfSymbolNode889 = HEAP32[291]|0;
  $474 = ((($0)) + 400|0);
  HEAP32[$474>>2] = $LoadAddressOfSymbolNode889;
  _HelloWasm_Program__PrintLine($474,0)

What looks odd to me is that here
 $Loadloc34_ = +HEAPF32[$Local34_881>>2];
 $ceq883 = $Loadloc34_ == 1.0

it seems to be comparing to a value of the HEAPF32 array , should it not be from HEAPF64 ?

And if I add to the js
 $Loadloc34_ = +HEAPF32[$Local34_881>>2];
**console.log($Loadloc34_);**

It writes 0

Think the fix is something like this:
        {
            if (kind == StackValueKind.Int32)
                return ValueAsInt32(builder, signExtend);
            else if (kind == StackValueKind.Int64)
                return ValueAsInt64(builder, signExtend);
            else if (kind == StackValueKind.Float)
                return isDouble ? ValueAsType(LLVM.DoubleType(), builder) : ValueAsType(LLVM.FloatType(), builder);
            else if (kind == StackValueKind.NativeInt || kind == StackValueKind.ByRef || kind == StackValueKind.ObjRef)
                return ValueAsInt32(builder, false);
            else
                throw new NotImplementedException();
        }

I've passed in a bool so that the correct first parameter can be passed to ValueAsType, i.e Double or Float.  I'm not that happy as its a bit ugly, I think another method, ValueForStackEntry where the first parameter is not a StackValueKind, but a StackEntry would make things cleaner.  @morganbr Any opinion on that?

You also might want to take a look at the LLILC sources sometime, since they were solving a similar problem, and were a fairly complete translation of MSIL into LLVM IR.
For instance the handling of converts is done here.

@yowl, you've hit an unfortunate intersection of IL and LLVM. In IL, while variables are typed as Float or Double, once they're on the evaluation stack, they're treated as an unspecified internal floating point representation. In other words, this is totally valid IL:
ldfld MyDouble
stfld MyFloat

The good news is that we've already dealt with similar cases for ints, so you should be able to follow similar patterns. Since we don't want to lose precision, we probably need to widen floats to doubles when they get loaded and then truncate when storing floats. That suggests that ValueForStackKind should always just produce Doubles and then CastIfNecessary can handle converting to Floats on store. Does that fix things up?


Fix scopeCausedBy() in Activity model.

Activity::scopeCausedBy() suffers from the same problem as scopeForSubject() brought in #89 - activities should be filtered by both causer_type and causer_id.

👍


200 steps for inference sampling will be quite slow.

I run the inference script for one image on a single piece of V100, but it shows that 7min is needed to generate 4 views. Then I found that the sampling step is 200. I wonder if it is feasible to turn down it as 50 as StableDiffusion does?

Sorry, It produce four sequences each with 16 views.

Hi, Thanks for the advice! I've checked that it's feasible to run SyncDreamer for only 50 steps. I've just updated the codes to include the --sample_steps parameter.


Remove ProtoTypeAdapter for Java JSON code

I think this is unused.
If it is used in the future, I think we would need to change it because
currently it uses java naming style (camel case) for field names. I think we
would need to set the naming scheme with something like:
ProtoTypeAdapter.newBuidler().setFieldNameSerializationFormat(CaseFormat.LOWER_UNDERSCORE, CaseFormat.LOWER_UNDERSCORE).build().

PTAL, fixed build


ENH: User-defined types

This may be hard and require some invasive changes, but we should look into this.

Implemented by https://github.com/metagraph-dev/grblas/pull/177 :tada: 🚀


Normalization

I see that there is reward scaling in FinRL but I am under the impression for RL, you need state and observations normalization (usually via VecNormalize in stable baseline) as well. Am I missing the normalization or is it not needed?
Thanks!

I believe we dit both. Reward scaling helps in training.


freebsd: install opengl

This is not tested, and I'm not sure of the package's name unfortunately :/

Let's give it a go

The mesa-libs package seems to work for opengl
https://github.com/turtlebrowser/turtlebrowser/runs/1523085826?check_suite_focus=true


remove openai key assertion, enable alternate embedding models

This is confirmed working by one of the users hitting the issue. Going to get this in as we've had several reports


Hack the zipkin encoder to preserve span name casing.

The Zipkin Span.Builder lowercases all span names, without an option to disable this behavior. To work around this, we add an extra attribute with the actual span name, and then munge the output of the zipkin V2 Span Encoder implementation to replace the proper span name from the attribute value.

Upstream issue where zipkin maintainers have decided not to support mixed case: https://github.com/openzipkin/zipkin/issues/2438


Refactor tracking parameter removal

Task/Issue URL: https://app.asana.com/0/1200204095367872/1208009677259118/f
Description
Steps to test this PR
Feature 1

[ ]
[ ]

UI changes

Before
After

!(Upload before screenshot)
(Upload after screenshot)

#4879  👈
develop

This stack of pull requests is managed by Graphite. Learn more about stacking.

Join @joshliebe and the rest of your teammates on  Graphite


Use SSL error?

This is a weird issue which I am not able to pinpoint yet.
It goes like this:

On first try to initwebsocket with useSSL = true
Can connect and all is fine
close websocket
2nd time initwebsocket with useSSL = true
Receive error:
(a) draft org.java_websocket.drafts.Draft_10@7847e63f refuses handshake

Do you have any idea why or what happened?

I have found the issue.
On the DDPClient.connect(..), if the conection is closed, it will just

createWsClient(mMeteorServerAddress);
And this is without the
.setWebSocketFactory() to it

<IP_ADDRESS> will have a fix for this. Thanks for finding it.

Good day,
Is the fix for using ws over ssl out yet? I have a ssl based connection but I don't know how to tell MyDDPState class to use ssl.
Thanks for the help

I figured it might help if I paste some code
// My DDPState Class
public class MyDDPState extends DDPStateSingleton {

   protected static String sMeteorServer = "example.com";
   protected static Integer sMeteorPort = 443;

   private static final String TAG = "MyDDPState";

   private MyDDPState(Context context){
       super(context, sMeteorServer, sMeteorPort);
   }

   public static void initInstance(Context context) {
       if(mInstance == null){
           mInstance = new MyDDPState(context);
       }
   }

   public static MyDDPState getInstance() {
       // Return the instance
       return (MyDDPState) mInstance;
   }

   @Override
   protected void createDDPClient() {
       try {
           mDDP = new DDPClient(sMeteorServer, sMeteorPort, true);
       } catch (URISyntaxException e) {
           Log.e(TAG, "Invalid Websocket URL connecting to " + getServerHostname()
                   + ":" + getServerPort());
        }
       getDDP().addObserver(this);
       mDDPState = DDPSTATE.NotLoggedIn;
   }

   public void verifyPhone(String phone) {
       Object[] methodArgs = new Object[1];
       methodArgs[0] = phone;
       getDDP().call("requestPhoneVerification", methodArgs);
   }
}

Also, here is my Application class
public class MyApplication extends Application {
    private static Context sContext = null;

   @Override
   public void onCreate() {
       super.onCreate();
       MyApplication.sContext = getApplicationContext();
       // Initialize the singletons so their instances
       // are bound to the application process.
       initSingletons();
   }

   private void initSingletons() {
       MyDDPState.initInstance(MyApplication.sContext);
   }

   public static Context getAppContext() {
       return MyApplication.sContext;
   }
}


Create "System" Icons

Description
Shoelace creates an internal copy/duplicate of certain icons that are used directly in components. This is done so that if an end user replaces the default icon library, the icons used in components, like checkboxes, remain consistent.
Need to create these icons in the Figma File. Put a prefix on the so they don't collide with other names and are easier to find/search for....."--sl" like the tokens
Source:
https://github.com/shoelace-style/shoelace/blob/next/src/components/icon/library.system.ts

Components that will need an update to point to these icons...these components were created before this set was created.

[ ] Avatar
[ ] Tag


Added "onHover" functionality for legend

core.legend.js

Created an "onHover" property in the legend object that will hold a user defined function (default is null)
Modified the "handleEvent" function of the legend to check if the event passed to it is a "click/mouseup" or a "mousemove" to determine whether to call the "onClick" or the "onHover" event (this is for the sake of reusing the legend hitbox calculations)
The "onHover" event will receive the same parameters as the "onClick" (the "event" itself and the "legendItem" the user is hovering over)

core.controller.js

Added a "mousemove" event to the "eventHandler" of the controller and put the new legend "onHover" logic in it
Also moved the original chart "onHover" functionality under the "mousemove" clause too in order to put the hover events in one place for consistency.

LGTM, I think that Travis is failing because there are some space indents. After fixing it, can you squash your commits?  By the way, what do you mean by squash my commits? I haven't done it before.

I mean, combine all your commits into a single one. After squashing commits, don't forget to force push to your branch (push -f). Then you should only see one commit in the commits tab.
Your last commit is not correct because you compute position before testing if it needs to (it should come after checking event type and callback presence). However you right, opts must be initialized before the checks.

And you will need to update some tests because there is a new options: onHover. Try gulp unittest to see where it's failing.

I am good to merge this once passing

I hope that fixed it. Sorry for the commits have turned out to be such a jungle... I have never before done commit squashing. If there is anything else to fix, please do tell me and i'll try my best.

I think you squashed them correctly but forgot to force push to your branch. Also, I'm not sure why there are these merge commits. But no worries, I will squash them for you when merging :)
Anyway, I realize that I made a small typo in the code example in my previous comment, can you please change:
		var type = e.type;
		type = type === 'mouseup' ? 'click' : type;

by
		var type = e.type === 'mouseup' ? 'click' : e.type;

I was actually thinking about it, but then left it alone because I thought you wanted it like that. I'll fix it right away and push again.

Yeah, that was just example code, I don't mind if it's not exactly the same if it can be better :) I think I edited my comment to merge the mouseup and click events, but initially just defined var type = e.type. Anyway, thanks for your contribution, will merge it really soon.

Happy to hear taht :) This is my first contribution to anything, so I wasn't very sure what was going on. I guess I need to read up some tutorials on indepth repository management and stuff.

Forgot one important thing: can you update the document to add the new onHover callback?

I added the description of the new function to the doc file like you suggestes, and took the liberty of doing a small change to the "onClick" description as well. I copied the "onClick" desccription for the "onHover" function and wassnt sure if I should use teh words "mouse hover" or "mousemove". So I ended up using "...'mousemove' event is registered...", and then did the same for "onClick". Previously it was "...click is registered..." and changed it to "...'click' event is registered...".
I hope thats all right.

I think it's fine, if it's not, we will fix it later when cleaning the doc.


Create Computational Thinking

Thanks for the contribution! Still, I suggest that you select one subject in the "index.html" file and work on it...


Unable to install dbeaver   in Eclipse 4.26

Description
Eclipse complains when I try to instal DBeaver in a vanilla Eclipse 4.26:
Cannot complete the install because of a conflicting dependency.   Software being installed: DBeaver IDE <IP_ADDRESS>212070729 (org.jkiss.dbeaver.ide.feature.feature.group <IP_ADDRESS>212070729)   Software currently installed: Eclipse IDE for Enterprise Java and Web Developers <IP_ADDRESS>21201-1200 (epp.package.jee <IP_ADDRESS>21201-1200)   Only one of the following can be installed at once:      Quick Search 1.1.300.v20211203-1705 (org.eclipse.text.quicksearch 1.1.300.v20211203-1705)     Quick Search 1.1.400.v20221023-0941 (org.eclipse.text.quicksearch 1.1.400.v20221023-0941)   Cannot satisfy dependency:     From: Eclipse IDE for Enterprise Java and Web Developers <IP_ADDRESS>21201-1200 (epp.package.jee <IP_ADDRESS>21201-1200)     To: org.eclipse.equinox.p2.iu; org.eclipse.platform.feature.group [4.26.0.v20221123-2302,4.26.0.v20221123-2302]   Cannot satisfy dependency:     From: Eclipse Platform 4.26.0.v20221123-2302 (org.eclipse.platform.feature.group 4.26.0.v20221123-2302)     To: org.eclipse.equinox.p2.iu; org.eclipse.text.quicksearch [1.1.400.v20221023-0941,1.1.400.v20221023-0941]   Cannot satisfy dependency:     From: DBeaver Local Standalone Application <IP_ADDRESS>212070729 (org.jkiss.dbeaver.app.local.feature.feature.group <IP_ADDRESS>212070729)     To: org.eclipse.equinox.p2.iu; org.eclipse.text.quicksearch [1.1.300.v20211203-1705,1.1.300.v20211203-1705]   Cannot satisfy dependency:     From: DBeaver IDE <IP_ADDRESS>212070729 (org.jkiss.dbeaver.ide.feature.feature.group <IP_ADDRESS>212070729)     To: org.eclipse.equinox.p2.iu; org.jkiss.dbeaver.app.local.feature.feature.group [<IP_ADDRESS>212070729,<IP_ADDRESS>212070729]
DBeaver Version
<IP_ADDRESS>212070729
Operating System
Windows 11
Database and driver
No response
Steps to reproduce
Download Eclipse 4.26
Try  and install DBeaver IDE
Additional context
No response

Looks like duplicate of https://github.com/dbeaver/dbeaver/issues/18475


Please update Svelte to v3.48.0 in peerDependencies

The core's devDependencies from the package.json file has Svelte v3.48.0, but the peerDependencies has Svelte v3.47.0

Fixing this in the next patch!


Feature Request: bestsimilar.com builder

bestsimilar.com could be a great addition to builders, i think (if possible)

their movie and show pages have no TMDb or IMDb IDs therefore i cannot add it


token-swap: Initialize number of pool tokens at geometric mean of provided accounts

Problem
This actually contains two problems with one solution.  When a new token-swap is initialized between token A and B, we assume that the two token accounts have the same quantity without doing a check: https://github.com/solana-labs/solana-program-library/blob/master/token-swap/program/src/processor.rs#L195
Solution
The simplest solution would be to add a check to make sure that token_a.amount == token_b.amount and keep the code as is, but even better would be to use the geometric mean of the two provided accounts, ie. sqrt(token_a.amount * token_b.amount).  This is recommended by Uniswap v2 in the whitepaper https://uniswap.org/whitepaper.pdf section 3.4, to protect the intializer of the swap in the case where the initial provided amounts are off the market.

Since we're going the Balancer route of a fixed starting size for the pool, this won't be done anymore.


Serverless function has crashed

For some reason I get a 500 error for the following url: https://unavatar.io/github/qmcclure?fallback=http%3A%2F%2F<IP_ADDRESS>%3A8000%2Fimages%2Flaravelio-icon-gray.svg
This is because I'm passing a development url for the fallback icon. I'm wondering if instead of the 500 error we could just show the default unavatar fallback?

Hello, it's a nice suggestion.
Unfortunately, it can't be possible with the current implementation:
https://github.com/microlinkhq/unavatar/blob/6572e7ef451b159c7dbb9dcbb2c4dafddb675d52/src/send/index.js#L28
When an error occurred, the response stream is closed, so you can't write the fallback avatar as fallback value.

What I can do is to ping the fallback URL before using it, so in case the fallback URL isn't reachable, the default fallback image can be used.
But I don't want to implement this for now, since that implies a less optimal solution than the current source code (and maybe this is just a nice to have suggesion?

Thanks @Kikobeats, definitely understandable. I think the ping before continuing is a good idea but understand if you don't want to pursue it. I guess I'll live with the broken avatars in development for now 🙂  I actually hardcoded the production url for them for now. Not ideal but workable.


Update is not in the az aks command group.

Trying to enable cluster scaling on my existing AKS instance. Following the commands presented here, I receive an error from the cli.
az aks: 'update' is not in the 'az aks' command group. See 'az aks --help'
Looking in help, it confirms that there is no update command. I'm unsure how to enable or disable auto-scaling if that command doesn't exist.

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

ID: 077f1bb5-2ba9-490c-2c6e-0de292266539
Version Independent ID: 0fd87b4f-88a4-c2eb-3ebc-f2b113ac203c
Content: Use the cluster autoscaler in Azure Kubernetes Service (AKS)
Content Source: articles/aks/cluster-autoscaler.md
Service: container-service
GitHub Login: @mlearned
Microsoft Alias: mlearned

The az-aks-update command is part of the Azure CLI AKS Preview Extension.
You need to Install this extension using the below CLI command to make it work, as described in this section of the document.
az extension add --name aks-preview
Please refer to this for more details: https://github.com/Azure/azure-cli-extensions/tree/master/src/aks-preview
Let me know if you are still seeing any issues.

That appears to have done it. Thanks!
FWIW, I noticed the it's never mentioned in the document that the update command is in preview. I don't know where I would have found this on my own using the documentation provided and the information given by the cli.