Resolution issue with EDF export

Description of the problem
When exporting this BDF file to EDF, the amplitude resolution seems to decrease a lot (amplitude values are clearly discretized). I suspect that maybe this has to do with some physical to digital min/max setting, which by default is set to "auto". Or maybe the range of the original data is too large and cannot be accurately represented with 16 bits (BDF uses 24 bits).
>>> raw.describe()
<RawEDF | S01.bdf, 73 x 1939456 (3788.0 s), ~1.05 GB, data loaded>
ch  name    type  unit        min         Q1     median         Q3        max
 0  Fp1     EEG   µV    -28733.96  -28283.90  -28180.43  -27993.25  -26932.31
 1  AF7     EEG   µV    -22318.10  -21375.51  -20833.26  -20595.17  -19586.39
 2  AF3     EEG   µV    -11227.59  -10846.75  -10493.43   -9618.47   -8873.50
 3  F1      EEG   µV    -19847.79  -19601.29  -19297.20  -18904.51  -18461.83
...
>>> raw_edf.describe()
<RawEDF | S01.edf, 72 x 1939456 (3788.0 s), ~59 kB, data not loaded>
ch  name  type  unit        min         Q1     median         Q3        max
 0  Fp1   EEG   µV    -28733.76  -28283.63  -28182.47  -27995.34  -26933.23
 1  AF7   EEG   µV    -22315.59  -21374.87  -20833.70  -20595.99  -19584.46
 2  AF3   EEG   µV    -11229.21  -10844.83  -10495.85   -9620.87   -8872.34
 3  F1    EEG   µV    -19847.46  -19599.63  -19296.17  -18906.73  -18461.66
...

For channel 0, the range is approximately 52000µV, therefore the resolutions are:
>>> 52000/2**16  # EDF
0.79345703125
>>> 52000/2**24  # BDF
0.0030994415283203125

So yes, it looks like the range is too large for EDF. Should we maybe issue a warning in such cases?
Steps to reproduce
The data set S01.bdf is linked in the first paragraph.
import mne

raw = mne.io.read_raw("S01.bdf")
raw.plot(duration=1, n_channels=1)  # plot 1
raw.export("S01.edf", overwrite=True)
raw_edf = mne.io.read_raw("S01.edf")
raw_edf.plot(duration=1, n_channels=1)  # plot 2

Expected results
The data in the exported EDF file should be identical to the original BDF file.
Actual results
This is a plot of a portion of the original BDF data (plot 1 in the MWE):

And here's the plot of the exported EDF file (plot 2 in the MWE):

@hofaflo what's your take on this issue?
Additional information
Platform             macOS-14.3.1-arm64-arm-64bit
Python               3.12.2 (main, Feb 14 2024, 07:24:33) [Clang 15.0.0 (clang-15<IP_ADDRESS>.5)]
Executable           /Users/clemens/.pyenv/versions/3.12.2/envs/mne/bin/python
CPU                  arm (12 cores)
Memory               32.0 GB

Core
├☑ mne               1.7.0.dev26+g7bf1b4ab7 (devel, latest release is 1.6.1)
├☑ numpy             1.26.4 (OpenBLAS 0.3.23.dev with 12 threads)
├☑ scipy             1.12.0
└☑ matplotlib        3.8.3 (backend=MacOSX)

Numerical (optional)
├☑ sklearn           1.4.1.post1
└☐ unavailable       numba, nibabel, nilearn, dipy, openmeeg, cupy, pandas

Visualization (optional)
└☐ unavailable       pyvista, pyvistaqt, vtk, qtpy, ipympl, pyqtgraph, mne-qt-browser, ipywidgets, trame_client, trame_server, trame_vtk, trame_vuetify

Ecosystem (optional)
└☐ unavailable       mne-bids, mne-nirs, mne-features, mne-connectivity, mne-icalabel, mne-bids-pipeline, neo

Thanks @Teuniz! I think this would be a good option, although I'd not do it automatically. We could either document it or introduce a new parameter.

For channel 0, the range is approximately 52000µV

With the values below, shouldn't that be 23734 - 26932 = 1802?
ch  name    type  unit        min         Q1     median         Q3        max
 0  Fp1     EEG   µV    -28733.96  -28283.90  -28180.43  -27993.25  -26932.31

I think the main issue here is that the export uses the same physical range per channel type. This makes sense for data that was initially recorded into an EDF file, with physical min/max set to the actual amplifier limits. However, I'd argue that it's not the best idea for data coming from a format supporting higher resolution (like BDF), as EDF's resolution might not be enough to cover large DC offsets across all signals.
I suggest to allow setting the physical range individually per signal (in the current (unreleased) version of the export code, pass physical_range=None here). Additionally, if the current behavior is to be kept as the default, it might make sense to issue a warning in case the resulting resolution is below some threshold deemed "too low".

Ah yes, I missed the minus sign for the maximum 😄. But still, the underlying issue is the signal range being too wide due to offsets in the channels.
A combination of your suggestions might be the best way to proceed. Setting physical_range=None can be done in any case, right? Can you let us know when the feature will be available in edfio? In addition, if the range in individual channels is still too large for 16 bits, I'd issue a warning (the threshold has to be decided, but I'd say we need at least 0.01µV?).

If you are not willing to get rid of the DC-offset, then forget about converting BDF to EDF.
It's simply not possible without loosing resolution.
If, for whatever reason, you need to keep the DC-offset, then you need to export to BDF instead.
Most of the time, there's a reason why a recording is made with a resolution >16bit and,
in general, it's better to avoid  the conversion from BDF to EDF.

I agree, but technically the offset is irrelevant if the range of a channel can be represented accurately with 16 bits. It's all about the range.

I agree, but technically the offset is irrelevant if the range of a channel can be represented accurately with 16 bits. It's all about the range.

It cannot, that's why for example Biosemi uses 24 bit adc's. How do you think Biosemi's BDF to EDF converter works?
But feel free to invent the wheel again.

@hofaflo indeed setting physical_range=None fixes the issue with my example data. Why did we not do this in the first place and instead set all channels to the global physical min and max?

Can you let us know when the feature will be available in edfio?

Already is, with "current (unreleased) version of the export code" I meant to refer to the code in mne/export/_edf.py.

Why did we not do this in the first place and instead set all channels to the global physical min and max?

This seems to have been initially introduced in 847f6de as a result of the discussion in #9643. I did not change it in #12218 to avoid breaking existing behavior.

Thanks, let's see if the tests still pass if I change it!

@hofaflo before changing the scaling behavior, I would like to make sure that we don't overlook potential issues. This EEGLAB issue discusses errors that occur when channels are stored with different resolutions (i.e. individual physical min and max) such as not being able to compute a bipolar derivation. However, I think this is due to the subsequent processing steps and not caused by having different resolutions. Furthermore, @Teuniz mentions that the EDF standard mandates that all channels have the same physical min/max, but I did not find this anywhere in the specs.
So I'd really appreciate some insights, and especially maybe a concrete example where channel-specific resolutions can be problematic.


Firecrawl doesn´t work, have to check api key, but key is correct

Description
Signed up for firecrawl. Started off with a free plan to try it out. Got an api key.
In docker compose I added:
  - FIRECRAWL_API_KEY=&FIRECRAWL_API_KEY

In .env file
  - FIRECRAWL_API_KEY=the actualkey from the firecrawl website

When I try to crawl a site I get an error straight away
Import for website failed: Reader Firecrawl failed with: Firecrawl was not able to load any documents, please check your API Key and settings
I should be able to do this with the free 500 credits. It's a site with only a 100 pages or so.
There is no way of setting the key via GUI for firecrawl right? Like you can for OpenAI and Cohere.
btw import from pdf in combination with OpenAI api key does work.
Installation

[ ] pip install goldenverba
[ ] pip install from source
[X] Docker installation

Weaviate Deployment

[ ] Local Deployment
[X] Docker Deployment
[ ] Cloud Deployment

Configuration
Reader: Firecrawl
Chunker: Sentence
Embedder:  OpenAI (this key do work!)
Retriever: Advanced
Generator: OpenAI
Steps to Reproduce
Whenever I click import selected I get an error straight away. But the key is correct.
Additional context

Thanks for the issue! I'll try to reproduce it
If you set environment variables through the .env and Verba detects them on startup, they won't be shown to the UI, but I might change this so that you can always edit those.
I'll let you know once we have an update on this 🚀

Made an typo! Embarrassing :(

FIRECRAWL_API_KEY=&FIRECRAWL_API_KEY

$$$$$


Add function to facilitate reviewing a pull request

Right now the best practice is to simply do a git checkout <branch-name> to test a pull request locally and then when you are done simply checkout your patch stack branch.
Maybe some command could exist to abstract away the concept of the branch here. Maybe in combination with the list command.

Another approach which I have been using lately on my open source projects is cherry-picking the PR's patch into my patch stack, testing it, refining it, signing off on it, and then integrating it.
So it is worth considering if we want to be opinionated about it or not. Food for thought.


[RESOLVED] High ICMP ping loss

Problem started at 07:09:29 on 2023.04.19
Problem name: High ICMP ping loss
Host: HP_iLO
Severity: Warning
Operational data: Loss: 66.67 %
Original problem ID: 18949
Event details in Zabbix: http://<IP_ADDRESS>/tr_events.php?triggerid=23267&eventid=18949

Problem has been resolved in 1m 0s at 07:10:29 on 2023.04.19
Problem name: High ICMP ping loss
Host: HP_iLO
Severity: Warning
Original problem ID: 18949


DANE validation

Hello,
this is a request to review a DANE "email transport security" implementation and maybe add it to simple-java-mail. I (or my company) open-sourced a DANE validation implementation at https://github.com/fwiersENO/java-mail-dane/
The code in that project could be the start for a library that simple-java-mail can use, e.g. as part of the TransportStrategy enum.
The main reason for open-sourcing the java-mail-dane project is to verify the DANE security related code in TrustManagerDane.java. The security related code should be correct (unit tests and such are included in the project) but since it is security related code a second opinion would be beneficial.
Can you, or somebody you know, take a look if you are interested?

Having read a bit more about DANE, I'm very interested in including this in the library. However, Simple Java Mail is build for the Lowest common denominator, meaning it is compiled for Java 7 runtime, whereas your library is made with Java 11.
Also please note I'm not an authority on email security whatsoever. I would just integrate your library and hope it works as intended with some obvious flows tested before releasing. As a single person maintaining Simple Java Mail, I depend on bug reports to mature the library.

Looking at your implementation, it looks like DANE connections are achieved by using a custom SSLSocketFactory, which is already a possibility (of course through "mail.smtp.ssl.socketFactory" as well as mailerBuilder.withCustomSSLSocketFactory(..)).
How would you propose to make DANE part of the Simple Java Mail api?

Thank you for your feedback, good to hear it is of interest.
The project is almost, but not really, a library, I propose you copy/paste/update what you really need.
DNSSEC is indeed a requirement for DANE but also a bit of a hassle. To get around the "auxiliary config details" you can use dnssec-java (https://github.com/ibauersachs/dnssecjava/tree/dnssecjava-1.2.0 ). I have used that library in the past (with success) when only a "normal" DNS server (without DNSSEC capabilities) is available. The 1.2.0 version of dnssec-java is only released in Maven for Java 8 but you can compile the code for Java 7 (see also https://github.com/ibauersachs/dnssecjava/issues/20). When using dnssec-java, make sure the response contains the AD flag (in the readme on the project page shown as response.getHeader().getFlag(Flags.AD))) because that is what makes the response "DNSSEC".
A TransportStrategy.DANE sounds like a good idea, the only "hard part" I can see is that the TrustManagerDane somehow needs to know which DaneRecord to compare to. I am not familiar enough with your project to determine where/when exactly the DANE DNS related functions should be executed. You might be able to maintain a simple (concurrent) map of <email-domain, DaneRecord> and use that in the TrustManagerDane or you might be able to lookup the DaneRecord from within the TrustManagerDane itself.
One note on the bug-reports for maturing the library: when it comes to security related code, this has failed in the past (OpenSSL comes to mind). Some form of warning when using TransportStrategy.DANE should be in place.

Hi @fwiersENO. It's been a while. As I'm slowly bringing down standing issues, I might be able to look into DANE again to see if it's still interesting. Do you have an update for me? I saw the library merged into another project? Anything I can use from there?

I had another look at this. The DANE library you referenced in Java 11 and so out of scope for Simple Java Mail, since in 2023, still a third of all Java usage is Java 8 LTS. It will be another few years before Java 8 falls out of use and Simple Java Mail will move to Java 11 (Java 8 is supported until 2030, so we have time).


Fixed NTS-1 mkII mentioned instead of NTS-3

Thanks for the heads up. There was also another mention of NTS-1 mkii in that README. Fixed upstream and propagated.


#268: added rule to enforce max-lines-length

added rule to enforce max-lines-length
fixed all the existing length issues in the project

Now, ./gradlew spotlessCheck will fail if there is a line over 100 chars.
https://github.com/android/sunflower/issues/268

thx for the review :D
Fixed wrong indentation and rebased/squashed all commits into 1.

Thank you!


Roadmap: Fix flaky tests

This issue is aimed at keeping track of flaky tests.
Rationale: some of existing tests tend to fail randomly, even when the pull request / branch update has nothing do to the tests. Since flaky tests bewilder community contributors and hamper developer productivity, they should be quickly addressed.
Note to maintainers: If you spot a flaky test, please report it here.
List of existing flaky tests

[x] R-package/tests/testthat/test_update.R: Test that model updates work.

Lines 32, 41 and 64 randomly fail for 32-bit Windows + MinGW target.
Build log (AppVeyor): https://ci.appveyor.com/project/tqchen/xgboost/build/1.0.2949/job/7i0d2lim73hhy44f#L2960, https://ci.appveyor.com/project/tqchen/xgboost/build/1.0.2954/job/l2icjm6yq4kc2k3s#L3093

[ ] tests/python/regression_test_utilities.py: Test suite

Randomly throws std::bad_alloc exception due to memory shortage
Build log (Travis CI): https://travis-ci.org/dmlc/xgboost/jobs/427691975#L2250

I could not reproduce the 1st one, but I will need to try with this specific version R-3.5.1patched later.

@khotilov I think the issue only appears for 32-bit R.

For tests/python/regression_test_utilities.py, we could solve it by migrating Python test to Jenkins, where we can use slave workers with more memory.

I ran the test with some debug printouts many times locally and in a personal appveyor, but have never seen it fail :( I'm really curious to see the details for how it fails. How frequently would you estimate the failures were happening?

@khotilov I managed to re-produce the error as follows:

Create a fresh Windows EC2 instance.
Install R and Rtools.
Compile XGBoost from source
Install XGBoost into 32-bit R
Run R tests inside 32-bit R

@hcho3 Another weird test, on XGBoost Travis test:
https://travis-ci.org/dmlc/xgboost/jobs/448105204
On my Travis test:
https://travis-ci.com/trivialfis/xgboost/jobs/155019807
I also have some test failures on my machine but not on Travis, including shougun test and this one  #3622.

Closing in favor of #4234


Adding text for version optional

What are you changing in this pull request and why?
Marking config version as optional for 1.5+
Checklist

[x] Review the Content style guide and About versioning so my content adheres to these guidelines.
[x] Add a checklist item for anything that needs to happen before this PR is merged, such as "needs technical review" or "change base branch."

small content suggestion but mostly added a question about whether we should link to a doc for more details on the 1.5 change.


Decode JWT and put “value” into a request header

Similar to https://discuss.istio.io/t/question-decode-jwt-and-put-sub-into-a-request-header/1213
Looking to do rate limiting off values from JWT
Looking to decode a JWT and put fields into headers; which can then be used by the rate_limit filter when setting descriptors.
Is the only way to approach this in Envoy using Lua scripts?
Thanks

@qbrent - That config was extremely helpful! Thank you so much for sharing!

@qbrent @gramidt Could you explain more about the first filter that you applied? It will be great if you can paste the full YAML file
  - name: envoy.filters.http.jwt_authn
    config:
      providers:
        jwt_auth:
          ....
          payload_in_metadata: jwt_payload

@qbrent I have the same issue..and i try to config it but failed..could you paste the full yaml config. THANKS

I'm also trying to rate-limit based on the token, is there a way to do this WITHOUT validating the token?


$$hashKey issue

I have a problem with this module that I have tryed to explain here:
http://stackoverflow.com/questions/30531007/angularjs-didnt-update-next-hashkey-when-using-angular-drag-and-drop-lists

Just a few things that could be going on:

When saving the object to a database make sure you strip out the $$hash variable. The angular.copy function does this for you (check the docs). It is a good idea to not store the $$hash because it might call problems if it exists because angular might noy create a new one as it already exists (I'm not 100% sure this is correct but it's always better to be safe, plus it doesn't pollute  your data in mongodb)

Using track by is possible, however the the directive needs to be modified slightly. On the drag start event (when it serializes the object data to the copy, you need to add a unique id (the one used by the track by statement in the ng repeat). This is because on a move action the object is copied to the new target before the item at the source is deleted from the array. This happens because the item at the source (of the move) is only hidden, then the new target position is created, then the dropped callback is triggered (when you have the splice call to remove the object from its previous position in the array.

I solve this by just appending "-" to my uuid property (used in my ng-repeat e.g. ng-repeat="item in collection track by uuid")
And on the dropped callback, after my splice call, I remove the "-" from the uuid (because the source item was removed by the splice())
It's a bit hacky but it worked for me.

Thanks mate. This has been really helpful :)


How to use mix link Multi-CPU of parallel computing in chainer v2.1.0 Ask Question

I am sorry I directly put the question here and also I put it in stackoverflow:
https://stackoverflow.com/questions/46901992/how-to-use-mix-link-multi-cpu-of-parallel-computing-in-chainer-v2-1-0
My paper submit deadline is 11.08, which is urgent situation. I am in hurry. so please forgive me to put question here.
In my research . I wrote 2 layers in neural network, the bottom first layer is RNN which runs on GPU, the top second layer is CPU(the algorithm model nature is more suited to CPU), I implemented it in CPU in chainer self-defined Link.
But, the CPU layer is slow , I can't wait for deadline of my paper submit. So I want to use parallel computing of this layer.
What is the best practice and fast way to implement parallel this link?

Hi, Keisuke put comments on your question in stackoverflow. Does it help?


SONARMSBRU-36: Use a generic service endpoint instead of (server url, username, pass)

SONARMSBRU-36

LGTM

Pushed to origin/master manually


BUILD: Clean up dependencies

As title says.

@Samuelopez-ansys @svandenb-dev I fixed the pyedb release issue and did the release today. This PR should cleanup the pyproject.toml and use the latest releast of pyedb.


Receiving websocket payloads larger than ~4K yields garbled data

Here's a minimal reproduction that lets one send arbitrarily-sized websocket payloads to the server; sizes > ~4K results in garbled (seemingly arbitrary) data:
let rec bus_loop ws =
  let open Lwt.Infix in
  receive ws
  >>= function
  | None     -> close_websocket ws
  | Some msg ->
    let open String in
    let len = Int.min 40 (length msg) in
    log "Message (%d) ending with: %s" (length msg) (sub msg (length msg - len) len);
    bus_loop ws

let () =
  Lwt_main.run
  @@ serve ~interface:"<IP_ADDRESS>" ~port:9090
       (router
          [ get "/ws" (fun _req -> websocket bus_loop)
          ; (get "/"
            @@ fun _r ->
            Dream.respond
              {|<html>
           websocket payload size:
           <input type="number" id="file" />
           <button>Send</button>
           <script>
           function send (input) {
             let ws = new WebSocket("ws://localhost:9090/ws");
             ws.addEventListener("open", e => {
               let bt = ws.binaryType;
               let len = parseInt(input.value);
               let data = new Uint8Array(len);
               data.fill(33, 0, len);
               ws.binaryType = 'arraybuffer';
               ws.send(data);
               ws.binaryType = bt;
             });
           }

           document.querySelector("button").addEventListener("click", e => send(document.querySelector("input")));
           </script>
           </html>|}
            )
          ])

A sample output log looks like this (note that the messages being sent by the client consist entirely of exclamation points, just to easily see where the bad data starts):
29.03.22 03:18:38.261                       Message (4000) ending with: !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
29.03.22 03:18:44.169                       Message (4090) ending with: !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!�9
29.03.22 03:21:34.808                       Message (5000) ending with: ����������������������������������������
29.03.22 03:21:37.178                       Message (5000) ending with: wXwXwXwXwXwXwXwXwXwXwXwXwXwXwXwXwXwXwXwX

Of course maybe there's another perfectly reasonable cause, it sure feels like the websocket facility is successfully handling the first "frame" of data (which is probably 4096 bytes, including some header data, yielding something like 4000 bytes of expected data), but then only increases the extent of the resulting string, without actually copying over the payload of websocket "frame" >= 2.

(BTW, I'll also gladly accept the news that I'm somehow running afoul of some necessary yet missing websocket handling :worried:)

When I attempt to send much larger payloads (say, 20MB), more stranger things happen:

a single payload sent (sometimes!) results in multiple messages received, as if the original single payload is not recognized as such
the messages that are received have strange sizes, starting with one larger message, and then a pile of much smaller messages. Example output for that case:

29.03.22 13:11:51.406                       Message (131099) ending with: c=,�c=,�c=,�c=,�c=,�c=,�c=,�c=,�c=,�c=,�
29.03.22 13:11:51.406                       Message (99) ending with: c=,�c=,�c=,�c=,�c=,�c=,�c=,�c=,�c=,�c=,�
29.03.22 13:11:51.406                       Message (99) ending with: c=,�c=,�c=,�c=,�c=,�c=,�c=,�c=,�c=,�c=,�

...with pages and pages of log indicating that, in this case, tons of 99-byte messages were received.
That larger message often seems to be something close to 131000 bytes, which seems just as suspiciously a round number as the ~4K threshold I noted in my original report. :thinking:

(BTW, I'll also gladly accept the news that I'm somehow running afoul of some necessary yet missing websocket handling 😟)

This is almost certainly a problem in Dream or websocket/af. I unfortunately won't be able to look at this immediately, but I am reading the very helpful information and will try to address this soon.

I fished around in both dream and websocketaf hoping to track the specific cause of this down, but without ultimate success. Some tidbits that might be helpful though:

When receiving messages > ~4K, Dream does not receive fragments from the underlying stream when it should; specifically, it sometimes requires 2+ top-level messages being sent before a deluge of fragments come through (with the garbled data as described before).
Chrome's websocket messages panel sometimes reports Received a broken close frame containing a reserved status code. after a number of too-large messages are sent.

My hunch is that websocketaf is what's misbehaving. If Dream's streams were at fault, then things like large multipart form uploads should be breaking too; and that "broken close frame" report is probably not something that Dream's higher-level websocket support could provoke?
Until this is resolved, my workaround is to just add my own (3kb, yeuch lol) framing to known-large websocket messages. Obviously not ideal, but it seems to work well enough in the interim.

I've recently been debugging this and this appears to be an upstream Websocket/af issue, as probably also suggested by https://github.com/anmonteiro/websocketaf/issues/48, because this can be worked around by changing the buffer size in Websocket/af. As far as I can tell, Dream already receives garbled data for fragments after the first, and I don't think Dream is clobbering or can clobber Webscoket/af's internal buffer. So I don't see how Dream can fix the reassembly of these messages.
cc @anmonteiro

Yes, it'd definitely a problem upstream of Dream, and @anmonteiro and I have sporadically gone back and forth on the subject. I think I currently owe him a minimal repro app, which I hope to get to assemble in the next week or so.

Commenting here for both this one and https://github.com/aantron/dream/issues/230
The general situation of my websocketaf fork is that it's an experiment to check whether it could work. Unfortunately, and as you've noticed in Dream, it's not meant to be used at all (unlike h2/httpaf, which are running production workloads).
I suppose that the former doesn't matter when it's indeed used in Dream, and we should strive to make the library better.
Unfortunately I don't have any free time to spare right now on websocketaf – there seems to be other interest in using it too from other community folks. I'm happy to review PRs or otherwise talk about a paid engagement to make websocketaf ready for dream.

I finally found the root cause of this issue and have fixed it in https://github.com/anmonteiro/httpun-ws/pull/68


For completeness, add Google to TOE identification section

The document contains examples from 3 of the 4 major Cloud providers: AWS, Azure and Oracle.  I think it would be more complete to have Google in this section as well.

2/28/2024 - Contacted a Google participant in ISO/IEC SC38 Cloud Computing to see if she could find someone at Google to fill out this section.

For now waiting for Google instructions...then revisit.

Jade will go back and ask for instructions. Once received we will look to incorporate.

Continuing to track, no response yet from Google.

Google is not interested in providing this information so we are closing this issue.


When AD B2C will be available in CSP

When will Azure AD B2C will be available in CSP?

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

ID: 245ef8a4-a811-19b7-676c-aa9b82e2126f
Version Independent ID: ad2ec743-2aa7-b3c7-3350-2986a78d7c90
Content: What is Azure Active Directory B2C?
Content Source: articles/active-directory-b2c/active-directory-b2c-overview.md
Service: active-directory-b2c
Product: unspecified
GitHub Login: @davidmu1
Microsoft Alias: davidmu

@knssub Thanks for your feedback! We will investigate and update as appropriate.

@knssub As per the document The Available Azure services in Azure CSP document  Azure B2C is currently not available in CSP and the estimated launch timeframe is middle of 2018.
@davidmu1 Do you have any idea when will it be available ?

I do not have any information about Azure AD B2C availability in the CSP program. We don't typically put announcement or billing information in the overview for the service.
#please-close

B2C is in CSP. See https://docs.microsoft.com/en-us/azure/cloud-solution-provider/overview/azure-csp-available-services


fixed issue when async route is being used and span opened by camel n…

…ot closed.

Codecov Report

Merging #6 into master will increase coverage by 0.02%.
The diff coverage is 100%.

@@             Coverage Diff              @@
##             master       #6      +/-   ##
============================================
+ Coverage     98.85%   98.87%   +0.02%
  Complexity       35       35
============================================
  Files             5        5
  Lines            87       89       +2
  Branches          6        6
============================================
+ Hits             86       88       +2
  Misses            1        1

Impacted Files
Coverage Δ
Complexity Δ

...a/com.playtika.sleuth.camel/SentEventNotifier.java
100% <100%> (ø)
16 <9> (ø)
:arrow_down:

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 10180dc...8baa9f5. Read the comment docs.


"Build date" prints the time of execution and not the time of the most recent build

The time being supplied to mainVersion comes from getZonedTime, but we should be splicing it in, similar to how the git data is being supplied.
A quick search suggests that this might work: https://hackage.haskell.org/package/th-nowq

We should remove the "build date" entirely because it doesn't provide useful information and it ruins any hope of having a reproducible build.

We should remove the "build date" entirely because it doesn't provide useful information and it ruins any hope of having a reproducible build.

While we are at it, we should:

Note after the commit hash if the repository was clean or dirty using gitDirty.
Provide a way to supply the revision information manually, for the Nix build.

While we are at it, we should:

Note after the commit hash if the repository was clean or dirty using gitDirty.
Provide a way to supply the revision information manually, for the Nix build.


fix: Remove sitemap from static

Thank you for your contribution to the KodaDot - One Stop Shop for Polkadot NFTs.
👇 __ Let's make a quick check before the contribution.
PR Type

[x] Bugfix
[ ] Feature
[ ] Refactoring

Context

[x] Closes #6189
[ ] Requires deployment <snek/rubick/worker>

Did your issue had any of the "$" label on it?

[x] My DOT address: Payout

Copilot Summary

🤖 Generated by Copilot at b88f136
Removed static/sitemap.xml file to avoid conflicts with dynamic sitemap generation.

🤖 Generated by Copilot at b88f136

is_valid checks
refactored for clarity
autumn leaves falling

pay 20 usd

😍 Perfect, I’ve sent the payout
💵 $20 @ 5.03 USD/DOT ~ 3.976 $DOT
🧗 16SjUbGKSdjCdWTy3NNT3JxbRVGGqD4mwkHpc6BD9U2Rp29Z
🔗 0x23c5d6446f6cc7b8407165e4ebfa057d4952e0940d0944f1832198f3611abdaa
🪅 Let’s grab another issue and get rewarded!
🪄 github.com/kodadot/nft-gallery/issues


Add documentation for public items under #[cfg(test)]

Summary
The ' nightly ' build fails with the change in rust-lang/rust#130025.  The commit f374720 temporarily addresses this issue with some dummy documentation.
Solution
Some documentation is needed!

Resolved by 587fff5 in #145


Upgrade Node.js to v16.14.2 (latest LTS version)

This upgrades us from v14 to v16 of Node.js, which adds some nice new JS/TS language features. I’ve also switched to -slim Docker images, but have not really tested out that they work yet. Need to do that before merging.

Verified -slim seems to work well, at least locally. (Wow, been a while since I've developed this with docker.)


homeassistant.exceptions.Unauthorized: Unauthorized

Logger: homeassistant.components.websocket_api.http.connection.178689
Source: helpers/service.py:514
Integration: Home Assistant WebSocket API (documentation, issues)
First occurred: 6:56:48 PM (1 occurrences)
Last logged: 6:56:48 PM
Unauthorized
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/components/websocket_api/commands.py", line 130, in handle_call_service
connection.context(msg),
File "/usr/src/homeassistant/homeassistant/core.py", line 1253, in async_call
task.result()
File "/usr/src/homeassistant/homeassistant/core.py", line 1288, in _execute_service
await handler.func(service_call)
File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 514, in admin_handler
raise Unauthorized(context=call.context)
homeassistant.exceptions.Unauthorized: Unauthorized

this is not the problem with midea_ac components


Graceful errors

Codecov Report

Merging #15 (6e4e196) into main (f9bd84f) will decrease coverage by 2.69%.
The diff coverage is 0.00%.

@@            Coverage Diff             @@
##             main      #15      +/-   ##
==========================================
- Coverage   43.24%   40.55%   -2.70%
==========================================
  Files           6        7       +1
  Lines         511      545      +34
==========================================
  Hits          221      221
- Misses        265      299      +34
  Partials       25       25

Impacted Files
Coverage Δ

pkg/tui.go
0.00% <0.00%> (ø)

pkg/tui_notification.go
0.00% <0.00%> (ø)

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 f9bd84f...6e4e196. Read the comment docs.

Can we update this message as well to notify the user more explicitly of the existence of the -s flag?
❯ cheek ui
Error connecting with cheek server: Error connecting to cheek server and no schedule file specified: Get "http://localhost:8081/schedule": dial tcp [::1]:8081: connect: connection refused

What if we use lower-right side to show errors? If need be we drop the hex thing, with pain in my heart though 💔
Are there actually errors that need user input at this stage? E.g. a "scheduler not available, can't refresh state" is ok to just notify the user about.

Yes, good idea. I was also thinking about handling panics that have a stacktrace, but there we might as well just kill the TUI and print the error after bubbletea has shut down... And we'll make the error messages reported in the TUI more user-friendly then, like the one you mentioned. What if the user sees: "scheduler not available, can't refresh state" and they want to learn more? I'm thinking stacktraces/errors raised by functions. Maybe we can write this to a .log? Because just Printing it won't show it, given that bubbletea replaces stdout

Maybe we can write this to a .log?

Perhaps we should just also show the core scheduler logs in the TUI? They already exist under cheek.core.json.. And from an error you can do something like "press (l) to show logs" and just open the core logs.


[experiment] Extend profiling using tracing

This PR aims to improve profiling using spans from the tracing library. Some observations up to this point:

This is how a flamegraph looks for me on this branch (open in browser for interaction):

When spawning threads, we need to be explicit about recording the work performed by the spawn thread within the current span in the parent thread. See first commit, where before the change the sumcheck::prove_rounds span was a sibling of the TOPLEVEL span in the flamechart, instead of being contained by it.

Span names must be constants. To distinguish between different spans in the same loop we need to use fields:
 let span = entered_span!("commit to iteration", circuit_name=circuit_name);
Unfortunately the flamegraph doesn't include fields in labels. Currently, in this situation it's better to filter after the parent span (in this case commit_to_traces and look at the spans textually. It looks like this:
 Filtering by span name for manual inspections is simple as:
.with(EnvFilter::new("[commit_to_traces]=info"))
I can make it an option.

Filtering spans over fields and field values would be quite powerful (for example for easy granularity flags).. if it worked like the docs said, but I am currently of the opinion that it does not :).

I can apply these improvements in more places if they sound good.

Another thing quite mystery in flamegraph for me is about invisible gap, for example

point to this code
https://github.com/scroll-tech/ceno/blob/master/sumcheck/src/prover_v2.rs#L359-L362
As I can tell this gap should not exist, because there should be neglible workload during this time.
So I am guessing few probablity

this gap imply some context switch (?)
this gap is a false signal and it's due to collapse stacktrace from multi-thread so it's not precisely
there are really some hidden workload (I think less possible...)

But still no clear idea as haven't look into the problem detail.

Thanks for the nice write-up in the PR description!  We should do more of that kind of thing to give context for reviews.

Another thing quite mystery in flamegraph for me is about invisible gap, for example

@hero78119 Yeah so sometimes I think it's due to having code not covered by spans, but other times it's just wrong. I updated the PR description with a case which I think points to a bug in the flame layer.

Running
RUST_LOG="info" cargo run  --release --example riscv_opcodes -- --start 2 --end 5 > logs.txt
to see all spans (unfortunately kind of verbose).
To me it looks like commit_to_traces really takes a small fraction of time in this case: 90ms vs. 3.15s.
2024-11-12T07:14:14.041104Z  INFO TOPLEVEL:ZKVM_create_proof:commit_to_traces: ceno_zkvm::scheme::prover: close time.busy=90.1ms time.idle=1.85µs
2024-11-12T07:14:16.608592Z  INFO TOPLEVEL: riscv_opcodes: close time.busy=3.15s time.idle=2.77µs

Note that:

The span data in the logs should not be interpreted as "uniform samples" as in other profiling methods, but intervals with different lengths (time.busy gives the length). So, for example, a span name can appear many times in the file, but it just means many instances of it were executed; the total time may still be small.
The time is given varyingly in seconds, microseconds or even nanoseconds according to its magnitude.

Another thing quite mystery in flamegraph for me is about invisible gap, for example

@hero78119 Yeah so sometimes I think it's due to having code not covered by spans, but other times it's just wrong. I updated the PR description with a case which I think points to a bug in the flame layer.

Hi @mcalancea when deal with other issue in codebase, I also observed the similar gap even flamegraph already removed , I think the answer for invisible gap is probably due to "Drop" behaviours after function finish, which indicates we have some heavy objects. So probably its not the bug of flamegraph upstream


Pass linting checks

This issue is part of the migration to v3. You can read full details about the various changes here.
The configlet tool has a lint command that checks if a track's configuration files are properly structured - both syntactically and semantically. Misconfigured tracks may not sync correctly, may look wrong on the website, or may present a suboptimal user experience, so configlet's guards play an important part in maintaining the integrity of Exercism.
We're updating configlet to work with v3 tracks, which have a different set of requirements than v2 tracks.
The full list of rules that will be checked by the linter can be found in this spec.
⚠ Note that only a subset of the linting rules has been implemented at this moment. This means that while your track may be passing the checks at this moment, it might fail later. We thus strongly suggest you keep this issue open until we let you know otherwise.
Goal
Ensure that the track passes all the (v3 track) checks defined in configlet lint.
To help verify that the track passes all the linting rules, the v3 preparation PR has added a GitHub Actions workflow that automatically runs configlet lint.
It is also possible to run configlet lint locally by running the ./bin/fetch-configlet (or ./bin/fetch-configlet.ps1) script to download a local copy of the configlet binary. Once downloaded, you can then do ./bin/configlet lint to run the linting on your own machine.
Tracking
https://github.com/exercism/v3-launch/issues/3

⚠ The original issue did not explain that currently only a subset of the linting rules have been implemented. This means that while your track may be passing the checks at this moment, it might fail later. We (the Exercism team) thus strongly suggest you keep this issue open until we let you know otherwise. The issue's text has been updated to reflect this.

@ErikSchierboom and @kytrinyx I am closing this since the Configlet workflow is using the configlet action in exercism/github-actions, which does run configlet lint.
Please correct me if there is still work to be done.


[SR-9887] HTTPCookie on Linux does not accept Substring values

The HTTPCookie  initializer takes values as Any   but fails to create cookie when Substring is passed to it. Casting from Substring to String returns nil due to which the initializer is failing silently.

@swift-ci test

@swift-ci test

@swift-ci test

@swift-ci test


add unit test for plugin settings and list plugin feature/config

Description
[Describe what this change achieves]
Issues Resolved
[List any issues this PR will resolve]
Check List

[ ] New functionality includes testing.

[ ] All tests pass, including unit test, integration test and doctest

[ ] New functionality has been documented.

[ ] New functionality has javadoc added
[ ] New functionality has user manual doc added

[ ] Commits are signed per the DCO using --signoff

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.

Codecov Report

Merging #330 (37290bc) into main (d8f7765) will increase coverage by 14.59%.
The diff coverage is n/a.

@@              Coverage Diff              @@
##               main     #330       +/-   ##
=============================================
+ Coverage     68.34%   82.94%   +14.59%
=============================================
  Files           146       65       -81
  Lines          4571     1829     -2742
  Branches        770      477      -293
=============================================
- Hits           3124     1517     -1607
+ Misses         1262      305      -957
+ Partials        185        7      -178

Flag
Coverage Δ

dashboards-notifications
82.94% <ø> (ø)

opensearch-notifications
?

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files
Coverage Δ

...tions/core/credentials/oss/SnsClientFactoryImpl.kt

...notifications/core/client/DestinationSmtpClient.kt

...fications/action/CreateNotificationConfigAction.kt

...notifications/model/SendTestNotificationRequest.kt

...in/org/opensearch/notifications/metrics/Metrics.kt

...ch/notifications/action/GetPluginFeaturesAction.kt

...fications/spi/model/destination/SmtpDestination.kt

...ifications/spi/model/destination/SesDestination.kt

...arch/notifications/model/ChannelMessageResponse.kt

...tifications/spi/model/SecureDestinationSettings.kt

... and 69 more

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 d8f7765...37290bc. Read the comment docs.


problems with the new Traccar web 3.0:

problems with the new Traccar web 3.0:

With each update it duplicates values in the state field.
When a device is turned off it still continues displaying the online status (green)

I have fixed state fields duplication. Replace this file in your Traccar web directory:
https://github.com/tananaev/traccar/blob/ea0a523ef676310526055b1ae381387868afd738/web/app/view/state/StateController.js
As for green status, it's only color. It doesn't mean that it's online.

Thanks! @Anton
Em sáb, 27 de jun de 2015 às 18:15, Anton Tananaev<EMAIL_ADDRESS>escreveu:

I have fixed state fields duplication. Replace this file in your Traccar
web directory:
https://github.com/tananaev/traccar/blob/ea0a523ef676310526055b1ae381387868afd738/web/app/view/state/StateController.js
As for green status, it's only color. It doesn't mean that it's online.
—
Reply to this email directly or view it on GitHub
https://github.com/tananaev/traccar/issues/1277#issuecomment-116144215.

@guilhermesouza thanks for what? are you confusing me with someone else?

My name is Anton as well.


The unpatchify need a very small step...

Hello, I have a problem when i useing patchify.
In my task, i want divide different size of images to (256, 256), and then input them to a (Deep learning generation) model. Last, I want unpatchify them. This is my code:

def choose_step(num1, num2):
    """Choose the max step, to acclerate the algorithm.
     求长和宽的公约数集合，满足小于256的最大公约数即为最大step。
    """
    num1 = num1 - 256
    num2 = num2 - 256
    cd1 = [a for a in range(1, num1+ 1) if num1 % a==0]
    cd2 = [a for a in range(1, num2+ 1) if num2 % a==0]
    cd = list(set(cd1) & set(cd2))
    cd = sorted(cd, reverse=True)
    for i in range(len(cd)):
        if cd[i] < 256:
            return cd[i]
        else:
            continue
    print("The max cd is 1!")
    return 1

for id in range(len(im_list)):
    # im = Image.open(im_list[id]).convert('RGB')
    im = mpimg.imread(im_list[id])
    im = np.array(im).swapaxes(0, 1)
    f_name = os.path.basename(im_list[id])
    max_step = choose_step(im.shape[0], im.shape[1])
    print(im.shape, max_step)
    im_patches = patchify(im, patch_size=(256, 256, 3), step=max_step)
    trans = transforms.Compose(transforms_)
    for i in tqdm(range(im_patches.shape[0])):
        for j in range(im_patches.shape[1]):
            im_patch = im_patches[i][j][0]
            im_patch = trans(Image.fromarray((im_patch)))
            im_patch = im_patch.unsqueeze(0)
            im_patch = generator(im_patch.cuda())
            im_patch = im_patch.squeeze(0).cpu().detach().numpy()
            im_patch = im_patch.swapaxes(0, 2).swapaxes(0, 1)
            im_patch = (im_patch + 1) * 128
            im_patch = im_patch.astype('uint8')
            im_patches[i][j][0] = im_patch
    out = unpatchify(im_patches, imsize=(im.shape))
    print(out.min(), out.max())
    out = out.swapaxes(0, 1)
    mpimg.imsave(output_path + "/" + f_name, out)
    print("已保存第{}张测试图片".format(id))

But, i found most of the images need a very small step, which causes the algorithm to run very slowly. There will be a lot of extra image parts that need to be synthesized. I think there may be a problem with the algorithm I chose step, but according to the requirements in your document, I can't think of other algorithm implementation methods.

Thank you very much for your suggestion. @antalele


Uninstall script in 0.9.0 has illegal newline.

Hi
It looks like the uninstall script in 0.9.0 does not work under MacOSx due to a wrong new-line Character.
bash: /Users/fm/.vscode/extensions/FunctionalCorrectness.dafny-vscode-0.9.0/scripts/osx/uninstall.sh: /bin/bash^M: bad interpreter: No such file or directory

This error seems to crop up again and again. Would there be a way to eliminate it systematically? e.g. A script that does this conversion for the appropriate OS before an install?
Best regards,
Farhad Mehta

Hi Farhad
Thanks for letting us know.,
This kind of bugs will be gone, end of this week, as soon as we have the native downloading and extracting
implemented.
Cheers
Markus

Great.
Thanks,
Farhad
On 10 May 2017, at 10:45, Markus Schaden <notifications<EMAIL_ADDRESS>wrote:
Hi Farhad
Thanks for letting us know.,
This kind of bugs will be gone, end of this week, as soon as we have the native downloading and extracting
implemented.
Cheers
Markus
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHubhttps://github.com/FunctionalCorrectness/VS-Code-Language-Server-for-Dafny/issues/1#issuecomment-300416532, or mute the threadhttps://github.com/notifications/unsubscribe-auth/ATRccouotdhdQJW0i5haLzk8e7lO-jp5ks5r4XkvgaJpZM4NVQKE.

Fixed with 0.10.0 release


error creating browser on .Net 4.6.2

Simplest console app (copy paste of code from the working console app working in Core 2)
System.InvalidOperationException: 'No process is associated with this object.'
var chromiumRevision = 526987;
        Console.WriteLine("Downloading chromium");
        await Downloader.CreateDefault().DownloadRevisionAsync(chromiumRevision);

        Console.WriteLine("Navigating google");

        //this line throws an error (stack trace below)
        var browser = await Puppeteer.LaunchAsync(new LaunchOptions
        {
            Headless = true
        }, chromiumRevision);

{"No process is associated with this object."}
at System.Diagnostics.Process.EnsureState(State state)
at System.Diagnostics.Process.EnsureState(State state)
at System.Diagnostics.Process.get_Id()
at PuppeteerSharp.Launcher.d__11.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.ValidateEnd(Task task)
at PuppeteerSharp.Launcher.d__7.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at PuppeteerSharp.Puppeteer.d__0.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at System.Runtime.CompilerServices.TaskAwaiter`1.GetResult()
at PuppeteerSharpPdfDemo.MainClass.d__1.MoveNext() in C:\temp\data\puppeteer-sharp-master\puppeteer-sharp-master\demos\ConsoleApp1\Program.cs:line 27

I'm releasing v0.3 in a few days. I believe this will be fixed there.

Could you try now with version v0.3 @cosmaioan ?

I tried v0.3 but got

Exception: Failed to create connection
Inner exception: The Process object must have the UseShellExecute property set to false in order to redirect IO streams.

I tried to set this UseShellExecute to false in the source code of puppeter sharp but has side effects that generate other errors.

Thank you for your feedback @cosmaioan. I was able to reproduce your issue. I was also able to make tests fail. I made the Test project a multitarget project and run the tests against net472.
I'll work on this issue and I'll also add a net471 test on our CI to keep testing this.
Thanks again.
cc @Meir017

@cosmaioan I just published 0.3.1. Could you give it a try?

I think the issue is related to Websocket, upon checking code, it uses websocket to connect to chrome. i also notice this is issue when i deploy it to windows server 2008 r2. but when i run it to my local machine which windows 10 there's no issues.
You may also refer to this link.
https://msdn.microsoft.com/en-us/library/hh159285


add microsoft/graspologic

Hello! I'd like to add graspologic to this list, I am one of the maintainers and we do have a list of good first issues.
Please let me know if there is any feedback, I appreciate any reviews

Of course, @bdpedigo. Thanks very much!

thanks, @jai-deepsource 🎉 !


Change Gender field in Demographic section to a drop-down

The field should only accept certain values.  We will have an easier time mapping values to the PDFs if we can constrain what values this field can take.
The relevant values should be

Female
Male

By default, no value should be selected.

Should also close #165 if this has been resolved.


Cruel angels thesis

Codecov Report

Merging #178 into master will increase coverage by 0.01%.
The diff coverage is n/a.

@@            Coverage Diff             @@
##           master     #178      +/-   ##
==========================================
+ Coverage    90.1%   90.12%   +0.01%
==========================================
  Files          79       79
  Lines        2912     2938      +26
  Branches      609      617       +8
==========================================
+ Hits         2624     2648      +24
- Misses        285      287       +2
  Partials        3        3

Impacted Files
Coverage Δ

src/data/CouplingContainer.ts
98.47% <ø> (-0.74%)
:arrow_down:

src/component/PredictedContactMap.tsx
94.91% <ø> (-1.58%)
:arrow_down:

src/component/NGLComponent.tsx
89.71% <ø> (+1.49%)
:arrow_up:

src/data/BioblocksPDB.ts
62.23% <ø> (-1.34%)
:arrow_down:

src/component/ContactMap.tsx
97.29% <ø> (+1.32%)
:arrow_up:

src/data/AminoAcid.ts
95.83% <0%> (-1.47%)
:arrow_down:

src/component/widget/BioblocksToggleButton.tsx
35.29% <0%> (-0.43%)
:arrow_down:

... and 6 more

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 c5bec2f...cec804e. Read the comment docs.


UnboundLocalError: local variable 'input_image' referenced before assignment

run python scripts/sampling/simple_video_sample.py --version svd_xt, An error message is displayed   UnboundLocalError: local variable 'input_image' referenced before assignment

Hi I had the same issue. Were you able to resolve it?

Hope you figured it out. For people watching this: the input_image is not handled correctly when image.mode != "RGBA".  Just simply change:
if image.mode == "RGBA":
    input_image = image.convert("RGB")

to:
input_image = image.convert("RGB")


CloudEnvironment.Credentials is incompatible with Kitura-Credentials (or the other way around)

If both modules CoudEnvirnment and Kitura-Credentials (Credentials) is imported, the type Credentials is ambiguous for the compiler. It looks like it's a compiler limitation https://bugs.swift.org/browse/SR-6705 so It may be a good idea to address the issue on the source level. Since CloudEnvironment is often used with the Kitura framework, it may be a good idea to clarify the Credentials type.
Kitura-Credentials report: https://github.com/IBM-Swift/Kitura-Credentials/issues/36
import CloudEnvironment
import Credentials

public class App {
    let credentials: Credentials.Credentials
}

Application.swift:18:22: error: 'Credentials' is ambiguous for type lookup in this context
    var credentials: Credentials.Credentials
                     ^~~~~~~~~~~
CloudEnvironment.Credentials:4:14: note: found this candidate
public class Credentials {
             ^
Credentials.Credentials:2:14: note: found this candidate
public class Credentials : RouterMiddleware {
             ^

Hey @krzyzanowskim, an idea to solve this is to define a typealias for example
typealias CloudEnvironmentCredentials = CloudEnvironment.Credentials


Admin tap: supports multiple attached requests

Commit Message:
Additional Description: Currently, admin tap support only single attached request to capture traffic for observation, this feature allow user to attach more request to admin tap until reach the num in max_concurrent_streams  added in AdminConfig API.
Risk Level: Low
Testing: Added unit tests for multiple attached request.
Docs Changes:  tap filter doc example add max_concurrent_streams filed
Release Notes: N/A

/wait

@xu1zhou the //test/extensions/filters/http/tap:tap_filter_integration_test is now failing with SIGSEGV https://source.cloud.google.com/results/invocations/b26cf29d-c4f4-4226-978f-3c7b0bbc6228

/wait


[libharu] init port

@atkawa7,
Thanks for having already signed the Contribution License Agreement. Your agreement was validated by Microsoft. We will now review your pull request.
Thanks,
Microsoft Pull Request Bot

Thanks!
@albertziegenhagel  It's merged!


add sam.yml as another default template name

I expect sam.yml to work by default. Countless examples online use this naming convention. for example: https://github.com/awslabs/aws-serverless-java-container/tree/master/samples/spring/pet-store
this PR maintains backward compatibility and allows sam.yml as an additional default

@AlJohri Thank you for submitting the PR. Unfortunately, we will not be accepting this. Templates can be named however the builder/writer of the template wants to and therefore we can't default to everyone's liking. We have defined the default to be template.[yaml|yml] and any other naming will require the -t or --template parameter to be provided by the caller of the command.
Closing this PR for the reason above.


Added pgid creation for spawning of process

Now when the process is killed due to timeout, all child processes
will get killed as well.

john [15:19]
pick an eng-schools
slackbot [15:19]
@jian http://i.imgur.com/MpFYSDO.gif
thanks in advance jian

hmm..did anyone else verify that we want to use kill -9?

lgtm

sorry, for the late comment, but it is possible to add a test for this?

I've already pushed the code, but I'll create another branch and add a test.


add article mode constants to models

1. Why is this change necessary?
I'm always looking for the numbers. Nobody would expect them in /themes/Frontend/Bare/frontend/checkout/cart_item.tpl. I think the right place is the model.
2. What does this change do, exactly?
Reducing developer pain.
3. Describe each step to reproduce the issue or behaviour.
4. Please link to the relevant issues (if any).
5. Which documentation changes (if any) need to be made because of this PR?
6. Checklist

[ ] I have written tests and verified that they fail without my change
[x] I have squashed any insignificant commits
[ ] This change has comments for package types, values, functions, and non-obvious lines of code
[x] I have read the contribution requirements and fulfil them.

Thanks @buddhaCode, great work. Please make use of the new constants in the entire project to make it consistent. (PHP code and templates)

I added the constants via an interface. This maybe breaks with the OO design. There are other ways:

introduce a new abstract class and let the model classes extend this super class
introduce a trait an use static varibales. Constants are not allowed in traits.

Personally, I think the interface is the most elegant way. But it's open for discussion.

Hello @buddhaCode,
please change your interface to an abstract class and modify every occurrence of the values to use your new constants.

Sorry for the inconvenience. Please move the constants into the article model and remove the changes in the other classes. And still, please use the constants in the project where they are currently hard coded as string/number.

@shopwareBot No problem. I will do so. Any idea how to use the constants in smarty tpls?
{if $mode eq constant('Shopware\Models\Article\Article::MODE_FOO')} feels wrong and introduces dependencies between model and view.

@buddhaCode I would suggest simply assign the constants to the template in the index controller. so they are available everywhere

@buddhaCode still working on this or should we closed this pull request?

I'm on it. I just returned from vacation this week. So i couldn't spare some time on work.

@buddhaCode Still on it? Otherwise this will be closed on Monday.

@buddhaCode Thanks a lot for your pull request, this looks really cool!
One small thing that would make it perfect, would be to use aliased class names, just like you did in:
engine/Shopware/Bundle/CustomerSearchBundleDBAL/Indexing/CustomerOrderGateway.php
Where you used a "use" statement and aliased the class name, I'm talking about the following:
use Shopware\Models\Article\Article; //If you could rename this to ProductModel it would be great.
Then on line 245: $query->setParameter(':articleModeProduct', Article::MODE_PRODUCT);
We would like that you alias in every other file just like you did it in this file.
Again, this is just great and we thank you for your contribution.

@pthreat as you wish ;)

sure thing

Hello,
thank you for creating this pull request.
I have opened an issue on our Issue Tracker for you. See the issue link: https://issues.shopware.com/issues/SW-21575
Please use this issue to track the state of your pull request.

Thanks for your review @pascalheidman-bedarf. I made some changes.

Isn't mode 10 (in your code MODE_BUNDLE_ARTICLE) the bundle rebate? Perhaps the constant could be named accordingly to avoid confusion.

Yes, your absolutly right. Sorry for the mistake. Thanks for the review, @cm-springlane.

Hey @buddhaCode,
can you please rebase your branch to the current 5.5?
We might have a look at it soon. :-)

@PaddyS Puh never rebased something before. But i'll try. I'm on vacation for the next 1,5 weeks. I'll give it a try when I returned.

@PaddyS I tried to squash and rebase today. But there are waaaaaaaay too many changes to fix them all. Sorry. I will close the PR.


download file checked by crc

变更内容

DownloadFile支持CRC64校验

Coverage increased (+0.09%) to 91.046% when pulling 140c0dd49797afca9584720c8a075eebe143dd92 on download-file-crc into f6c21b3f9340703510eb940ad26985e9b7baf088 on master.

Coverage increased (+0.09%) to 91.046% when pulling 140c0dd49797afca9584720c8a075eebe143dd92 on download-file-crc into f6c21b3f9340703510eb940ad26985e9b7baf088 on master.

Coverage increased (+0.09%) to 91.046% when pulling 140c0dd49797afca9584720c8a075eebe143dd92 on download-file-crc into f6c21b3f9340703510eb940ad26985e9b7baf088 on master.

Coverage increased (+0.09%) to 91.046% when pulling 0f00c8b6b9ec4e0ad9154e48e3b8ff1674563f83 on download-file-crc into f6c21b3f9340703510eb940ad26985e9b7baf088 on master.

+2

Coverage increased (+0.09%) to 91.046% when pulling a69bdb7b577b21122c88a0582b665cc7d3af0fc2 on download-file-crc into f6c21b3f9340703510eb940ad26985e9b7baf088 on master.

Coverage increased (+0.2%) to 91.107% when pulling cc100c160792611ab5adc41d4b8ff6bcd76e66bf on download-file-crc into f6c21b3f9340703510eb940ad26985e9b7baf088 on master.


Unit testing example does not work in docker

Issue Title
With this article:
https://github.com/dotnet/core-docs/blob/master/docs/core/testing/unit-testing-with-dotnet-test.md
General
I was able to set up a unit test project and have this restored/running on my Mac but when it came to using the Docker image for Preview 1 or 2 it failed.
Errors in /root/dn/test/project.json
    Unable to resolve 'RateCalc.Engine' for '.NETCoreApp,Version=v1.0'.

The code is available here:
https://github.com/alexellis/dncore-market-rates
I am a bit confused about these two lines in the unit test project:
      "imports": [
        "dotnet5.4",
        "portable-net451+win8"
      ]

The other projects created are using dncore 5.0 - does this mean we need Mono or a full .NET runtime in order to use xunit?

Suggest reviewers

If you know someone who can provide feedback, use '@' to ask them to review.

@BillWagner  / @ Steve Smith
I've also provided a Dockerfile.

@alexellis Thanks for writing the issue, and providing a link to your project.
I think you are seeing the error because your tests are in the 'test' directory, and not it in a subdirectory of 'test'. Can you move that project into a sub-directory (e.g. 'test/EngineTests') and let us know if it works?
We can update the article to make that more clear.
Thanks.

This is my resulting structure: (You can clone it and try it - if you're on Mac or Windows 10 there is a 1-click install for Docker that runs without VirtualBox)
./Dockerfile
./global.json
./LICENSE
./src
./src/RateCalc.App
./src/RateCalc.App/market.csv
./src/RateCalc.App/Program.cs
./src/RateCalc.App/project.json
./src/RateCalc.App/project.lock.json
./src/RateCalc.Engine
./src/RateCalc.Engine/CsvParser.cs
./src/RateCalc.Engine/project.json
./src/RateCalc.Engine/project.lock.json
./src/RateCalc.Engine/Rates.cs
./test
./test/RateCalc.Engine.Tests
./test/RateCalc.Engine.Tests/CsvParserTest.cs
./test/RateCalc.Engine.Tests/project.json
./test/RateCalc.Engine.Tests/project.lock.json
./test/RateCalc.Engine.Tests/Tests.cs

Same issue, works on Mac locally, but not in Docker image.
error: Unable to resolve 'RateCalc.Engine' for '.NETCoreApp,Version=v1.0'.
info : Committing restore...
log  : Writing lock file to disk. Path: /root/dn/test/RateCalc.Engine.Tests/project.lock.json
log  : /root/dn/test/RateCalc.Engine.Tests/project.json
log  : Restore failed in 7406ms.

Errors in /root/dn/test/RateCalc.Engine.Tests/project.json
    Unable to resolve 'RateCalc.Engine' for '.NETCoreApp,Version=v1.0'.

NuGet Config files used:
    /root/.nuget/NuGet/NuGet.Config

Feeds used:
    https://api.nuget.org/v3/index.json

Installed:
    124 package(s) to /root/dn/test/RateCalc.Engine.Tests/project.json
The command '/bin/sh -c dotnet restore' returned a non-zero code: 1

Whatever was installed on my Mac
dotnet --info
.NET Command Line Tools (1.0.0-preview2-003121)

Product Information:
 Version:            1.0.0-preview2-003121
 Commit SHA-1 hash:  1e9d529bc5

Runtime Environment:
 OS Name:     Mac OS X
 OS Version:  10.11
 OS Platform: Darwin
 RID:         osx.10.11-x64

Preview 1 on Docker:
dotnet --info
.NET Command Line Tools (1.0.0-preview1-002702)

Product Information:
 Version:     1.0.0-preview1-002702
 Commit Sha:  6cde21225e

Runtime Environment:
 OS Name:     debian
 OS Version:  8
 OS Platform: Linux
 RID:         debian.8-x64

Preview 2 on Docker
docker run microsoft/dotnet:latest dotnet --info
.NET Command Line Tools (1.0.0-preview1-002702)

Product Information:
 Version:     1.0.0-preview1-002702
 Commit Sha:  6cde21225e

Runtime Environment:
 OS Name:     debian
 OS Version:  8
 OS Platform: Linux
 RID:         debian.8-x64

What is interesting is that the RateCalc.App application compiles without warnings.
Can you also speak to the odd part of the project.json file.. ?
      "imports": [
        "dotnet5.4",
        "portable-net451+win8"
      ]

Thanks for doing that research. Let me do a bit of research, and I'll get back to you.

@alexellis in your Dockerfile, could you test out what happens when you change the WORKDIR to point to the root folder, where the global.json is and not to the actual test folder?
Actually, come to think of it, you could run dotnet restore in the solution folder first and then just WORKDIR into other folders and do dotnet build.

I think @alexellis is missing the global.json in the Docker image. See https://github.com/moq/moq4/issues/168#issuecomment-234120869.

@jeremymeng the Dockerfile in the repo shows that global.json is being added.

It is now working inside Docker, but does a complete restore every build. Is there a way of changing the instruction order to take advantage of the step caching?
I.e. in nodejs with npm you can restore before adding any code.

@blackdwarf @jeremymeng can you help with @alexellis's last question?

@glennc might have some ideas for this scenario (dotnet restore caching in Docker).

@spboyer can you take a look at this one?

@alexellis when you say that it is doing the restore every time, you are stating that each time you build the image?

I'm sure it was not taking 1 second (a lot longer). Let me try to reproduce the issue - I guess this was raised 3 months ago maybe things have changed.

@alexellis - 3 months ago I don't believe we were loading the Nuget cache in the base image, there has been some improvements there.

$ git clone https://github.com/alexellis/dncore-market-rates

@spboyer so please could you clone the repo - do your initial build and then just edit the name of one of the tests in the CsvParserTests.cs file?
$ time docker build -t market-rates .

real	0m41.416s
user	0m0.031s
sys	0m0.032s

Output from editing a unit test name:
Sending build context to Docker daemon 1.154 MB
Step 1 : FROM microsoft/dotnet:1.0.0-preview2-sdk
 ---> 96d122fe36cb
Step 2 : MAINTAINER<EMAIL_ADDRESS> ---> Using cache
 ---> f79361382308
Step 3 : RUN mkdir -p /root/dn/
 ---> Using cache
 ---> c12ccc8b1ed9
Step 4 : WORKDIR /root/dn/
 ---> Using cache
 ---> d7eac690bf40
Step 5 : ADD ./global.json ./
 ---> Using cache
 ---> d64afc65de75
Step 6 : ADD ./src ./src
 ---> Using cache
 ---> 9fd1ce68be73
Step 7 : ADD ./test ./test
 ---> 40868161d6fd
Removing intermediate container f82a6236d2c4
Step 8 : RUN dotnet restore
 ---> Running in be7c12d59a7a
log  : Restoring packages for /root/dn/src/RateCalc.Engine/project.json...
log  : Restoring packages for /root/dn/src/RateCalc.App/project.json...
log  : Installing Microsoft.NETCore.Jit 1.0.2.
log  : Installing Microsoft.NETCore.Runtime.CoreCLR 1.0.2.
log  : Installing Microsoft.NETCore.App 1.0.0.
log  : Writing lock file to disk. Path: /root/dn/src/RateCalc.App/project.lock.json
log  : Writing lock file to disk.  Path: /root/dn/test/RateCalc.Engine.Tests/project.lock.json
log  : /root/dn/test/RateCalc.Engine.Tests/project.json
log  : Restore completed in 10797ms.
 ---> 7c97a9ddad3c
Removing intermediate container be7c12d59a7a
Step 9 : WORKDIR /root/dn/test/RateCalc.Engine.Tests/
 ---> Running in e75557d84379
 ---> c3bc574c578c
Removing intermediate container e75557d84379
Step 10 : RUN dotnet build
 ---> Running in be5bb892aee7
Project RateCalc.Engine (.NETCoreApp,Version=v1.0) will be compiled because expected outputs are missing
Compiling RateCalc.Engine for .NETCoreApp,Version=v1.0

Compilation succeeded.
    0 Warning(s)
    0 Error(s)

Time elapsed 00:00:02.0088077
Project RateCalc.Engine.Tests (.NETCoreApp,Version=v1.0) will be compiled because dependencies changed
Compiling RateCalc.Engine.Tests for .NETCoreApp,Version=v1.0

Compilation succeeded.
    0 Warning(s)
    0 Error(s)

Time elapsed 00:00:01.7288984

 ---> 60b053b9458c
Removing intermediate container be5bb892aee7
Step 11 : RUN dotnet test
 ---> Running in 256918ae4540
Project RateCalc.Engine (.NETCoreApp,Version=v1.0) was previously compiled. Skipping compilation.
Project RateCalc.Engine.Tests (.NETCoreApp,Version=v1.0) was previously compiled. Skipping compilation.
xUnit.net .NET CLI test runner (64-bit debian.8-x64)
  Discovering: RateCalc.Engine.Tests
  Discovered:  RateCalc.Engine.Tests
  Starting:    RateCalc.Engine.Tests
Taking 150 off Alex @ rate of 0.5, left= 50
Taking 50 off Dave @ rate of 1, left= 0
Taking 150 off Alex @ rate of 0.005833333, left= 50
Taking 50 off Dave @ rate of 0.005833333, left= 0
  Finished:    RateCalc.Engine.Tests
=== TEST EXECUTION SUMMARY ===
   RateCalc.Engine.Tests  Total: 14, Errors: 0, Failed: 0, Skipped: 0, Time: 0.666s
SUMMARY: Total: 1 targets, Passed: 1, Failed: 0.
 ---> 7c3124ebfe16
Removing intermediate container 256918ae4540
Step 12 : WORKDIR /root/dn/src/RateCalc.App/
 ---> Running in 6d5e0f8418fc
 ---> f2a0108e1c24
Removing intermediate container 6d5e0f8418fc
Step 13 : CMD dotnet run
 ---> Running in d659664ac735
 ---> 12d1bbce2142
Removing intermediate container d659664ac735
Successfully built 12d1bbce2142

real	0m41.416s
user	0m0.031s
sys	0m0.032s

@alexellis - see the results below. I want to say that given the scenario of restoring and building the application within the application; its pretty good. The Nuget cache is within the base container.
First run - no rates image
real	0m27.870s
user	0m0.021s
sys	0m0.023s

Second run - after change
real	0m22.084s
user	0m0.018s
sys	0m0.022s

@BillWagner It looks like we could close this and replace with an update for 2.0 issue. Am I right?

I recently posted an example for Unit Testing with Multistage dockerfiles:
Repo: https://github.com/SteveLasker/AspNetCoreMultiProject/tree/AddingUnitTests
Example: https://github.com/SteveLasker/AspNetCoreMultiProject/blob/AddingUnitTests/Web/Dockerfile

I think we can close this. The articles have been updated.


Atem pgm+aux combination

Hi I'm a camera controller and like to create a tally when a source is switch on the ppm (me1) of a ATEM and on a specified aux. So I know a camera is active when I'm viewing it on my monitor and don't make big changes in the actual camera.
Example input 2 is actual on PGM (me1) and on aux2 input 2 is switch swell it needs to give a tally.
If for example camera 4 is switched on the PGM and aux2 is watching input 2 there shouldn't be a tally. but when I select input 4 on aux2 the tally go on.
Is this possible?

It's a great idea. I will keep it on the list and let you know if it's something that can be added. Until then, you could possibly work around it by having a Tally client monitoring Input 2, and if you used something like Bitfocus Companion, you could press a button that changes both the Aux assignment on the ATEM to Input 4 and reassigns the Tally Arbiter tally client to Input 4 as well.

This is related to my issue. I'd like tally for Key source in Atem. If Auxes and Keys were exposed as ME1-6 are currently, then a Device with AND logic could solve this issue, as well as allow for Tally of Key contents.

I think I don't understand your workaround. What Scoobie say is right, you need a AND logic. if me1 and aux is the same a tally/gpo need to go on.

I get what you're saying. I'm just proposing a solution that reassigns a tally client on the fly. That's really what you're doing anyway: you have a single tally light device at your shader station, and when you pull Camera 2 up on your station, you want to know if Camera 2 is in PGM or not, and light up the tally light in front of you if it is. So if you reassign what that tally client is looking at when you change what is feeding that Aux, you can get what you want.
Tally Arbiter is based around Device (camera) tally state. To incorporate the "AND" logic would require you to have multiple Devices configured - one that the actual Device/camera uses when they are in PGM (because they might be in PGM whether they are on the Aux or not) and another one that looks for when they are in a PGM bus AND the Aux bus. This can get hard to manage if you have a lot of cameras. Reassigning the tally client on the fly (which you can do today if you want) is easier to maintain long term, in my opinion.
Yes, no problem to run the Tally Arbiter server on a Raspberry Pi. Mine has been running for 8 months (as of this post) on a Pi3B+ with no issues. You can run the blink(1) or GPO clients on a Pi as well. I run my blink(1) clients on Pi Zero W's. They work great. I designed TA to run on Raspberry Pi's.


'Unable to connect to Parse API' since enabling HTTPS

We've added SSL to our AWS-hosted ParseServer, but are receiving this error when running any CloudFunction:
"error": {
    "code": 100,
    "message": "XMLHttpRequest failed: \"Unable to connect to the Parse API\""
  }

We've updated our serverUrl to have https. After a bit of digging around, I ran into ParseServer/middlewares.js#handleParseHeaders, where I logged the req.protocol. It says the protocol is http, even though the requests are sent with https.
Just for more info - we have not yet enabled SSL on the mongolabs database. GET requests work fine.

Need a bit more context.  What type of client is making the request and gets this error?

Sure.
I'm using a chrome plugin called Postman to make the requests. Our ParseServer was created using this AWS-ParseServer guide. Here's the main part of our index.js code:

...

// parseServer
var parseServer = new ParseServer({
    appId: process.env.APP_ID,
    masterKey: process.env.MASTER_KEY,
    databaseURI: process.env.DATABASE_URI,
    cloud: __dirname + '/cloud/main.js',
    serverURL: process.env.SERVER_URL + process.env.PARSE_MOUNT,
    facebookAppIds: process.env.FACEBOOK_APP_IDS,
    fileKey: process.env.FILE_KEY
});

// Node app
var app = express();

// CORS
app.use(cors());

// Server path and setup
app.use(process.env.PARSE_MOUNT, parseServer);

...

The error occurs when I make a https POST request to any cloud function. By changing the request and serverUrl to http, the error goes away.

Any progress? same issue

@daaku @gfosco

We ended up setting serverUrl protocol as http. So whilst our client to server data is still sent via SSL, any self calls made by our server will be unsecure - at least until the issue resolves. Though I must say, we have not tried re-checking this issue since 2.0.7.

@omairvaiyani I wonder if it's because of MongoLab

I looked into the code at the time and am pretty sure it didn't have anything to do with MongoLab. From what I remember, the REST request made by the server never reached back to the server - the HTTP response code was 0. This might indicate some sort of firewall block?
I think the more long-term fix would be to question why a REST call is being made by the server to itself? Should the code not be triggered locally?

@omairvaiyani we are still discussing the best model for how to handle this issue in the long term. In the meantime, you should be able to use localhost in your serverURL to avoid having unencrypted requests on the public internet.

I moved everything over to be running off of https://localhost, install a self singed cert, but my dashboard is not loading the server. I can use the same usrl to interact with my cloud code, and can see the "unauthorized" message at the url on the browser, so i know thats the correct url for the server. the dashboard still errors with, POST https://localhost/msz/parse/serverInfo net::ERR_CONNECTION_REFUSED

+1
Only the parse cloud code cannot connect to the server via https...

@Spacelapp We've set our serverUrl to 'localhost:port' to counter-act this.

I already tried this...but when I use a cloud function in my iOS app I get this error: [Error]: {     code = 100;     message = "XMLHttpRequest failed: {}"; } (Code: 141, Version: 1.13.0)

Could you show us your config parameters in node for ParseServer?

Sure:
var server = new ParseServer({   databaseURI: 'mongodb://USER:PASSWORD@localhost:27017/database',   cloud: __dirname + '/cloud/main.js',   appId: 'APP_ID',   masterKey: 'MASTERKEY',   serverURL: 'localhost:3000/parse',   oauth: {    facebook: {      appIds: "FB_APPID"    }   } });

Where is your server deployed? AWS often defaults to port 8081 and perhaps the url needs to be http://localhost:port/mount as I vaguely remember seeing the error without http://.

selfhosted (express)

this should be reopened again...It's a bug, and it's not fixed with the newest version of parse-server

Well it only works, if I setup http & https server at the same time...not really a good solution

If you refer to my comments earlier, you need to have your server setup
over HTTPS. The serverUrl variable in your dash config should point to your
servers local address.
This way, any direct communication to your server from the app is done over
the HTTPS connection. The dashboard itself only communicates with the
server over the local IP.
On Sun, Apr 17, 2016, 3:43 PM Lukas Kovar<EMAIL_ADDRESS>wrote:

Well it only works, if I setup http & https server at the same time...not
really a good solution
—
You are receiving this because you commented.
Reply to this email directly or view it on GitHub
https://github.com/ParsePlatform/parse-server/issues/411#issuecomment-211095936

FWIW I also had issues without the http:// on my serverUrl. Mine looks ike SERVER_URL=http://localhost:1337/parse

I am using self hosted parse-server and not able to use cloud functions since I have enabled HTTPS, if I revert it back to HTTP it works as expected.
Also he problem is only with those cloud function which have Parse.Query, if i create a function simply return "Hello" as response it works on both HTTP and HTTPS.
I am getting following error message when run a cloud function which have Parse.Query code.
{ "code": 141, "error": "XMLHttpRequest failed: "Unable to connect to the Parse API"--100"}
can anyone tell me how can I fix this?

Have you tried the answers above you? Set SERVER_URL as http://localhost:[port]/[mount], even if your protocol is HTTPS.

yes I have tried that, but it doesn't work for me.

I have fixed this issue. Reason behind this is that node rejects unauthorized TLS.
so just put
process.env.NODE_TLS_REJECT_UNAUTHORIZED = "0";
in my parse server instance file.

Here is what worked for me:
Environment: app deployed on AWS, with the load balancer configured for HTTPS
On the server side, where you configure parse-server, use HTTP in the serverURL configuration parameter.  On the client side, use HTTPS when you initialize the Parse app/library.
My theory is that the load balancer is terminating HTTPS traffic, so from the load balancer to the instance, it might be HTTP traffic.  In this case, if the parse-server is configured for a HTTPS URL, then it might be trying to listen on a different port or something screwy like that?
I'm not an expert on how the AWS architecture works under the hood, so my rationale might be way off or downright incorrect.  If anyone can explain why this would work,  please chime in.

process.env.NODE_TLS_REJECT_UNAUTHORIZED = "0";
I am using Elastic Beanstalk as server and can I use this? May I put this in index.js?

In case anyone is still having this issue, I had the same and managed to fix by changing my Server URL from https://myapp.com/parse to https://www.myapp.com/parse

Thanks @natanrolnik! I resolved the same behavior (in development) changing form
http://docker:1337/parse to http://localhost:1337/parse
There is something wrong with the serverURL. The issue only occurred in beforeSave trigger for me. @gfosco please reopen the issue.

The serverURL is used in cloud code, it should 99% of the time be http://localhost:[port]/[mountPath].
If you're using https in node, i recommend you start a http sever as well listening on any different port from the https server and pass the host parameter to <IP_ADDRESS>. This will allow communications only from the server itself.

I just encountered this response. @flovilmart's response is correct for development (ie running the server locally), but the way I was able to fix it for running on Heroku was by using http instead of https in the serverUrl parameter. @w3care25's fix likely addresses the same issue, tho this is probably a bug.

Just had this issue. For me the problem was solved by replacing cert.pem with fullchain.pem certificate in https server options. It looks like browsers are checking the last certificate, but nodejs checks the full chain. I found the issue by running wget https://mypublicdomain.com:1337/parse which surprisingly returned ERROR: cannot verify mypublicdomain.com's certificate. Solution was inspired by https://github.com/certbot/certbot/issues/2026

We also had this problem for migrating existing Mobile App from parse.com to self Hosted Parse server on AWS but as mentioned by someone in this thread we simply changed the URL from HTTPs to HTTP on load balancer and used HTTPs only on client side this seems working.

I am still having this problem.  I had the parse server set up and both the iOS app and the parse dashboard were able to connect over http.  I then changed the AWS load balancer to accept client side traffic on port 443 and set a valid SSL certificate.  I changed the uri in the parse dashboard and the parse dashboard can connect fine still.  I changed the uri in the iOS app and the iOS app cannot connect.  If I enable port 80 on the AWS load balancer, the iOS app can connect fine regardless of what the uri is set to in the iOS app.  The parse URL is currently defined as https://parse-server.com:443/parse in the iOS app.  The parse iOS library seems to be ignoring both the "https" and the "443".  Inside the parse-server I have serverURL: process.env.SERVER_URL || 'https://parse-server.com/parse'

Was there ever a solution for this? I tried https, http, parse app URL, and localhost in serverURL – none worked. Thoughts anyone?

The way I got it to work was by adding
import os
os.environ["PARSE_API_ROOT"] = "http://db.myserver.co/parse"
to settings.py

My Application is using the perfect storm, SSL, File Storage, Cloud code.
This meant that I couldn't set the server url env variable to localhost as this broke the file urls that were output.
After investigating the function code, I saw the the credentials are set before ever function execution, so
I ended up setting Parse.serverURL at the start of my functions that used Parse.query
This "solved" the issue for me, I added this as an additional env var as above PARSE_API_URL


Add version parameter

Add a parameter to receive the ScanAPI version
Example:
- uses: scanapi/github-action@v1
  with:
    scanapi-version: 2.0.0
    arguments: 'run ./scanapi.yaml'

Can I work on it? Please assign it to me.

@ShubhamSood1406 sure thing! Done ✅
Thanks!

Closed by #4