Running bleve extensions outside docker on Mac and windows

Is anyone working on this aspect ?
I want to run blast as a standard system service rather than inside docker.
And I need to run on Mac and Windows.
So that brings up the bleve cgo based extensions.

Hi @gedw99
Unfortunately, I don't have a Windows platform, but I can describe you how to build Blast with enabling Bleve Extensions on macOS.
Please try the following steps:

Build and install dependencies

$ brew install \
    icu4c \
    leveldb \
    rocksdb \
    zstd

$ CGO_LDFLAGS="-L/usr/local/opt/icu4c/lib" \
    CGO_CFLAGS="-I/usr/local/opt/icu4c/include" \
    go get -u -v github.com/blevesearch/cld2
$ cd ${GOPATH}/src/github.com/blevesearch/cld2
$ git clone https://github.com/CLD2Owners/cld2.git
$ cd cld2/internal
$ perl -p -i -e 's/soname=/install_name,/' compile_libs.sh
$ ./compile_libs.sh
$ sudo cp *.so /usr/local/lib

Build Blast with enabling Bleve Extensions on macOS

$ git clone git@github.com:mosuka/blast.git
$ cd blast
$ GOOS=darwin \
    CGO_LDFLAGS="-L/usr/local/opt/icu4c/lib -L/usr/local/opt/rocksdb/lib -lrocksdb -lstdc++ -lm -lz -lbz2 -lsnappy -llz4 -lzstd" \
    CGO_CFLAGS="-I/usr/local/opt/icu4c/include -I/usr/local/opt/rocksdb/include" \
    CGO_ENABLED=1 \
    BUILD_TAGS="full" \
    make build

thanks @mosuka
wow that perl in there. Have not seen that in a while :)
Ok so the only way to pull this off is goin to be to make amage script so that all this stuff can be scripted in golang and then run on Windows, Mac and linux locally and in CI.
are you ok with that in your repo though ? It solves a ton is issue with cross platform stuff.
here is a great example.
github.com/elastic/beats
Basically make and make.bat both check for mage and then its all golang from there on in.
its very powerful.
the exact same script can be called in CI too.
anyway let me know your thoughts as getting stuff like this working and handling regressions will be hell without a proper setup like this.

Hi @gedw99,
Thank you for your proposal. It is s great idea. I will consider to using mage for cross platform building.

Ok. I will work on a mage script.
I can see with does is not on the blevex building web page you mentioned, so will try my best to get it working.
I am pretty busy with things so leave this open as it's going to take a while.
Also it's best done in stages

hey @mosuka Sorry about late late reply.
I think that its not possible to run on a desktop on Windows.
Maybe it will require just doing a version without any none golang dependencies.
SO that brings the question of doing some tagging for part of the code tagged as "nodeps" maybe.
Is this something just way too had because there is CGO stuff in the code everywhere ?
I know it will mean reduced functionality. Maybe not handle different written languages properly ? Maybe other things too ?
If its just NUTS, just let me know :)

Did a compromise.
export CGO_ENABLED=0
export GOOS=darwin
make build
works, but i guess i will not have certain functionality.

I think Windows platform is difficult to use plugins required CGO_ENABLED=1. I agree with you.


fix(ui): Disable ability to export data when user does not have the correct permission

SUMMARY
Disables Export to .JSON and Export to Excel from the Download submenu when viewing a chart unless the user has can_csv on Superset permission. The same permission is already required for Download to .CSV.
Disables DOWNLOAD TO CSV and COPY TO CLIPBOARD from the query results pane in SQL Lab unless the user has can_export_csv on SQLLab permission. The permission should be applied to both download to CSV and copy to clipboard functions since both are means of exporting data.
BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF

TESTING INSTRUCTIONS

Verify that a user with the can_csv on Superset permission (for example a user with the Alpha role) is able to export as CSV, JSON and Excel when viewing a chart. Verify that a user without that permission is not able to do any of those.
Verify that a user with the can_export_csv on SQLLab pemission (for example a user with the sql_lab role) is able to download to CSV or copy to clipboard from the SQL Lab query results pane. Verify that a user without that permission is not able to do either of those.
ADDITIONAL INFORMATION

[X] Has associated issue: Fixes #19535
[ ] Required feature flags:
[X] Changes UI
[ ] Includes DB Migration (follow approval process in SIP-59)

[ ] Migration is atomic, supports rollback & is backwards-compatible
[ ] Confirm DB migration upgrade and downgrade tested
[ ] Runtime estimates and downtime expectations provided

[ ] Introduces new feature or API
[ ] Removes existing feature or API

Approving CI 🤞

@rusackas Any chance I could get this PR reviewed please? I've had to update it a couple of times after merge conflicts have arisen due to other change. I'm worried that it will be hard to keep it up to date if any more wide ranging changes get merged.

Thanks for your patience. I was hoping to get a second opinion on this since it messes with permissions and that always makes me nervous, personally ;)
Running CI again, hopefully it passes. I think this looks OK to me in general, so I'll go ahead and approve it. I would still like a second opinion from @dpgaspar or @villebro if possible.
My only other (minor, probably non-blocking) thought is that we're now using can_export_csv and can_csv to control a lot more than csv. From a permissions standpoint, that seems reasonable. From a naming standpoint, I can't help but wonder if there's something more... inclusive. Maybe can_export_data or something similar. But... making that kind of change might be considered a breaking change and would have to wait for 5.0.

Thanks for reviewing. I also felt that the permission name feels wrong however the same permission is already used for controlling export to Excel so it's a logical extension of that. Perhaps this will be improved by the new permission model I saw a SIP for?

@rusackas
Hello,
running Superset 4.0.2 version and still observing COPY TO CLIPBOARD button.
Steps to reproduce:

Revoke can_export_csv on SQLLab permission
Run a query in SQLLab
Button DOWNLOAD TO CSV exists and when clicked results with {"message":"Forbidden"}
Button COPY TO CLIPBOARD exists and when clicked results with copying to clipboard.

So looks like it has half functionality described, and permission is not applied to both download to CSV and copy to clipboard functions.
p.s. also cannot find this: #28429 PR in the CHANGELOG files even though the code was merged and present in 4.0.2 version. Is that intentional ?
TIA

@rusackas
Hello again,
just tested same in Superset 4.1.0rc2 and this issue is no longer present.
Steps to reproduce (tested on local superset instance deployed with docker-compose):

Create new user and add it to sql_lab group
Revoke can_export_csv on SQLLAB permission for sql_lab group
Run a query - both buttons DOWNLOAD TO CSV and COPY TO CLIPBOARD are not present.

So 🤞 for the successful 4.1.0 version release :)
TIA


Not clear how to debug issue with write_sample

Apologies in advance: this problem is potentially quite basic but I am not clear on what's going wrong, or how to debug.
I have created an audio track as follows:
      TrackLocalStaticSample::new(
        RTCRtpCodecCapability {
          mime_type: MIME_TYPE_OPUS.to_owned(),
          ..Default::default()
        },
        "audio2".to_owned(),
        "webrtc-rs".to_owned()
      )
    );

I'm then writing samples to this audio track:
                audio_track.write_sample(
                  &(Sample {
                    data: bytes,
                    duration: sample_duration,
                    ..Default::default()
                  })
                ).await

In theory this works fine, since I always get the Ok on the match. Here's an example of a log I get from the audio track after a successful write:
TrackLocalStaticSample { rtp_track: TrackLocalStaticRTP { bindings: Mutex { data: [TrackBinding { id: "XXXXXXXX", ssrc: YYYYYYYYYYY, payload_type: 111, params: RTCRtpParameters { header_extensions: [RTCRtpHeaderExtensionParameters { uri: "http://www.ietf.org/id/draft-holmer-rmcat-transport-wide-cc-extensions-01", id: 1 }], codecs: [RTCRtpCodecParameters { capability: RTCRtpCodecCapability { mime_type: "audio/opus", clock_rate: 48000, channels: 2, sdp_fmtp_line: "minptime=10;useinbandfec=1", rtcp_feedback: [RTCPFeedback { typ: "transport-cc", parameter: "" }] }, payload_type: 111, stats_id: "" }, RTCRtpCodecParameters { capability: RTCRtpCodecCapability { mime_type: "audio/G722", clock_rate: 8000, channels: 0, sdp_fmtp_line: "", rtcp_feedback: [] }, payload_type: 9, stats_id: "" }, RTCRtpCodecParameters { capability: RTCRtpCodecCapability { mime_type: "audio/PCMU", clock_rate: 8000, channels: 0, sdp_fmtp_line: "", rtcp_feedback: [] }, payload_type: 0, stats_id: "" }, RTCRtpCodecParameters { capability: RTCRtpCodecCapability { mime_type: "audio/PCMA", clock_rate: 8000, channels: 0, sdp_fmtp_line: "", rtcp_feedback: [] }, payload_type: 8, stats_id: "" }] }, write_stream: Some(InterceptorToTrackLocalWriter), sender_paused: false }] }, codec: RTCRtpCodecCapability { mime_type: "audio/opus", clock_rate: 0, channels: 0, sdp_fmtp_line: "", rtcp_feedback: [] }, id: "audio2", stream_id: "webrtc-rs" }, internal: Mutex { data: TrackLocalStaticSampleInternal { packetizer: Some(PacketizerImpl { mtu: 1200, payload_type: 0, ssrc: 0, timestamp:<PHONE_NUMBER>, clock_rate: 48000, abs_send_time: 0 }), sequencer: Some(SequencerImpl(Counters { sequence_number: 21322, roll_over_count: 0 })), clock_rate: 48000.0, did_warn_about_wonky_pause: false } } }

As I do more of these write operations, the sequence_number on the sequencer increases (and the time stamp on the packetizer), which makes it feel like something's happening.
However, I am not getting any audio on the other end (which I am confident is in good shape). The peer connection is state: connected.
I don't see any webrtc logs telling me about successfully uploading audio data to the peer connection. I'd expect something telling me that 2,000 bytes (my typical sample size) have been uploaded. But as far as I can tell, I've done everything I need to upload this audio data. I've broadly speaking followed the example here, with tweaks: https://github.com/webrtc-rs/webrtc/blob/master/examples/examples/play-from-disk-h264/play-from-disk-h264.rs
So I'm wondering:

Any tips on how to debug this further? Ideally, I want to observe my peer connection more closely to see if audio data is being passed through it, but unsure how to. Am also considering using a packet inspector
Any ideas of where this could be going wrong? It is very possible my codecs are mismatched, or durations are wrong etc., but I wouldn't expect total silence on the receiving end - am I wrong in this assumption? (I'd also expect something to complain about the mismatch)

Any luck on this? I'm
running into the same issue.
I'm encoding floating point audio buffer into OPUS then sending it via the sample track. My packets are all getting dropped from the clients. Unsure where to look next.


Propagate BasePath to subdirectory storages for consistency

Hold off merging this one as I reassess https://github.com/ppy/osu/pull/8935 please. Looking at whether we can potentially seal Storage or whether a completely different solution is required.

Closing as this was superseded in the referencing PR.


Add slides for 'Unleashing the power of pathway simulation' Talk

Added link to slides and code for pathway simulation talk from the Friday (2024-11-22_rosser_power_of_pathway_simulation.md).
I've included a couple of extra links to the bottom of the template to make it easier to find key links from the presentation - happy to remove those if preferred!

Links look great 👍🏻 Thanks for adding 😃

Oops, apologies! Thanks for picking that up - should now be fixed.

Closes #18.


A service that expose information about the Party

Description
There is a need in the application to know if the logged in user is a person or an organization, as well as other information about the Party.
We made a solution to this  in our application by adding this service: LoggedInUser.cs, but preferably this should be a service out of the box when creating an app.
More information in slack thread: https://altinn.slack.com/archives/C02FK32SFA4/p1665649425146379
Additional Information
No response

Eksempelkode fra Arbeidstilsynet: https://altinn.studio/repos/dat/bilpleie-soknad/src/branch/master/App/logic/Extensions/IHttpContextAccessorExtensions.cs


hwloc: 2.4.1 -> 2.5.0

Motivation for this change
https://raw.githubusercontent.com/open-mpi/hwloc/v2.5/NEWS
Things done

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

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

[ ] Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
[ ] Tested compilation of all pkgs that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review wip"
[x] Tested execution of all binary files (usually in ./result/bin/)
21.11 Release Notes

[ ] (Package updates) Added a release notes entry if the change is major or breaking
[ ] (Module updates) Added a release notes entry if the change is significant
[ ] (Module addition) Added a release notes entry if adding a new NixOS module

[x] Fits CONTRIBUTING.md.

Result of nixpkgs-review pr 127077 at d04f6dc4 run on aarch64-linux 1

23 packages marked as broken and skipped:

grass
mpich
mvapich
python38Packages.dask-gateway
python38Packages.dask-jobqueue
python38Packages.dask-ml
python38Packages.dask-mpi
python38Packages.dask-xgboost
python38Packages.datashader
python38Packages.fipy
python38Packages.pygmt
python38Packages.streamz
python38Packages.stumpy
python38Packages.tensorflowWithCuda
python39Packages.dask-gateway
python39Packages.dask-jobqueue
python39Packages.dask-mpi
python39Packages.dask-xgboost
python39Packages.fipy
python39Packages.pygmt
python39Packages.streamz
python39Packages.tensorflowWithCuda
qlandkartegt

3 packages failed to build:

openmodelica
python38Packages.pyslurm
python39Packages.pyslurm

90 packages skipped due to time constraints:

apacheHttpdPackages.mod_tile (apacheHttpdPackages_2_4.mod_tile)
cdo
cloudcompare
elmerfem
ezminc
freecad
gdal (python38Packages.gdal)
gdal_2
getdp
globalarrays
...

42 packages built successfully:

EBTKS
bicgl
bicpl
conglomerate
eccodes
hdf5-mpi
highfive-mpi
hpcg
hpl
hwloc
inormalize
ior
libminc
migrate
minc_tools
minc_widgets
mni_autoreg
mpi (openmpi)
n3
netcdf
netcdfcxx4
oobicpl
parmetis
pmix
python38Packages.boltztrap2
python38Packages.fenics
python38Packages.h5netcdf
python38Packages.meshio
python38Packages.mpi4py
python38Packages.netcdf4
python38Packages.wrf-python
python39Packages.boltztrap2
python39Packages.eccodes
python39Packages.fenics
python39Packages.h5netcdf
python39Packages.meshio
python39Packages.mpi4py
python39Packages.netcdf4
python39Packages.wrf-python
scotch
slurm
slurm-spank-x11

Note that build failures may predate this PR, and could be nondeterministic or hardware dependent.
Please exercise your independent judgement. Does something look off? Please file an issue or reach out on IRC.


Calling powershell.exe in PSCore6 on Windows starts Windows PowerShell

On Windows, $env:Path has Windows PowerShell in the path before $PSHOME which means that if you're in PowerShell Core 6 and type powershell, it starts Windows PowerShell 5.1 instead of a nested instance of PowerShell Core 6.  This may be unexpected for end users as it seems that one would expect powershell to refer to the currently running version of PowerShell.
The immediate impact is that partner teams running existing PowerShell script tests in PowerShell Core 6 that spawn powershell will get incorrect results as that process is running Windows PowerShell.
cc @joeyaiello @HemantMahawar

Steps to reproduce
# within PowerShell Core 6
powershell
$psversiontable

Expected behavior
PowerShell Core 6

Actual behavior
Windows PowerShell 5.1

Environment data

Name                           Value
----                           -----
PSVersion                      6.0.0-beta
PSEdition                      Core
GitCommitId                    v6.0.0-beta.3
OS                             Microsoft Windows 10.0.16225
Platform                       Win32NT
PSCompatibleVersions           {1.0, 2.0, 3.0, 4.0...}
PSRemotingProtocolVersion      2.3
SerializationVersion           <IP_ADDRESS>
WSManStackVersion              3.0

@SteveL-MSFT Maybe Area-SideBySide?

If we have some PowerShell versions on system we should think about "default PowerShell" and a way to run specific PowerShell version by -Version parameter.

Based on some internal discussions, I think we agree that on Windows, we should put $PSHOME first in $env:PATH rather than at the end.

What about to enhance -Version?
powershell -Version 5.1
powershell -Version 6.0.0
powershell -Version 6.0.0-Beta.4
powershell -Version UserDefault
powershell -Version SystemDefault

@iSazonov I think you should open a separate issue to discuss that

Done #4199

In my opinion, this is the default value question.
In the shortcut, start the directory settings.

@SteveL-MSFT: other implications of this worry me. E.g. it might mean that anyone who can write to $PSHome can now squat over system binaries from within PowerShell. Let's talk offline.

In my own opinion, we should kept then separately.  As soon the PowerShell Core installation overrides any of the existing Windows variables over the Windows PowerShell it could open issues across the board.
:)

@joeyaiello PSCore6 implicitly trusts binaries in $PSHome so that folder needs to be secure regardless.  The only change being proposed here is to move $PSHome to front of $env:Path (at the process level, not system or user setting) instead of the end so that it takes precedence over Windows PowerShell path.

If we decide to do https://github.com/PowerShell/PowerShell/issues/4214, we don't need to address this one


Rust: enable write conformance tests

Public-Facing Changes

Description

Has this PR gone stale? Do we want to keep it as reference or revisit when we plan to do this?

Very stale - we need to re-vamp the writer so that it can write data section CRCs before doing this. I've left this PR as a reminder, will close it and write up a linear project for this.


Unable to add binding to Nodjs Azure Function Model 4

I have created a NodeJS Azure Function using Model 4. I am not able to add binding in VS code, using context menu (right-click & add binding)
I get this error when adding bindings.
"Add binding is not supported for this project type."

You no longer need to keep a function.json file for each trigger in the new V4 model as bindings are configured in code!
We will look into improving this error message for users in the future.

Thank you for the response. I understand bindings are not maintained in function.json in V4 model.  The option in context menu(right click) suggests developer can add binding (add binding code).

Thank you for the response. I understand bindings are not maintained in function.json in V4 model. The option in context menu(right click) suggests developer can add binding (add binding code).


there is only one file in $_FILES when uploading multiple files

eventhough I'm trying it on the latest chrome, any idea where the problem could be?
                $scope.doSubmit = function() {

                        $upload
                            .upload( {
                                url: '/api/send-fellowship',
                                data: $scope.form,
                                file: $scope.form.files
                            })
                            .progress(function(e) {
                                $scope.progress = parseInt(100.0 * e.loaded / e.total);
                            })
                            .success(function(data, status) {

                            });
                };

$scope.form.files is an array of files

I'm facing the same situation. Don't know if it's related to https://github.com/danialfarid/angular-file-upload/issues/1#issuecomment-22462440 that data cannot be transferred along with multiple files.

you know that the file will not be sent with data: $scope.form, so just remove this or add specific values in your form that you want to actually send or remove the file object from it before sending it. The file should be specified in the 'file option not data.

The file is specified in file option, with $scope.form.files, there are other things in $scope.form, like email and name, how could $scope.form.files value specified in both data and file break this?

Even if I don't write data field, the server script (PHP) still only receives one file data.
But I think Danial's suggestion is right. It's not a good practice to send multiple files along with data when you have to use a loop to upload files one by one. The better solution is separating file uploading with form input data submitting, uploading files immediately, and send back uploaded information to the frontend, where you can combine the uploaded information with form input data.

Wait what, you have to use the loop to be able to upload multiple files? Also uploading files immediately is just anti-ux.

For older browsers IE9 you need to upload files one by one.

Yeah, alright, not using any IE.

I'm facing the same situation here. Only one file makes it through to my upload controller, even though two or more files were actually selected. I don't have any interest in supporting IE9– anymore, so that's why I was investigating the "array of files" method which was much more intuitive to me.
@fxck did you have any success with this issue ?

Yeah I switched to https://blueimp.github.io/jQuery-File-Upload/angularjs.html which is not ideal, I don't like their angular implementation at all.. but better than nothing.

Have you tried setting the option fileFormDataName: 'file[]' or fileFormDataName: ['file[0]', file[1], file[2], ...]

I just tried it yesterday after leaving my comment (found a Stack Overflow answer suggesting this), and it seems to work (even though I'm not really sure how I was supposed to use this). Thanks for your answer. I chose to use the second syntax (fileFormDataName: [ 'file[0]', 'file[1]' ]), was having issues with the other one.
@fxck did you try setting this parameter ?

I am closing this issue. Reopen if fileFormDataName: [ 'file[0]', 'file[1]' ] doesn't fix your problem.

Just to have a feedback for you people, this actually works. The way I made with a dynamic array was:

        var names = [];
        for (var i = files.length - 1; i >= 0; i--)
            names.push(files[i].name);

        files.upload = $upload.upload({
            url: API_BASEURL + '/photo' + $scope.getReqParams(),
            method: 'POST',
            fileFormDataName: names,
            file: files
        });

Attention: increasing max file size in the server would save you lots of troubles.
PHP does not report errors like this, and it turns to an annoying-mysterious bug.
php.ini - default:

upload_max_filesize = 2M

2M is less than the average size of smart phone camera picture.

For IE9, where does the limitation "one file at a time" come from ?
In the FileAPI documentation, it looks like it should be able to upload multiple files in IE with Flash: "Support - Multiupload: all browsers that support HTML5 or Flash"
If there is really nothing to be done to bypass this limitation, shouldn't it be specified in the "Old browsers known issues" documentation part ?

I have 2 file upload controls in my form, it means that I don't want to use same file upload control to upload multiple files.
I want separate control to upload single file from each.
Now please tell me how to handle this situation..?

@kishor10d just don't add multiple or ngf-multiple to the element and it would just let you select one file.

@danialfarid : Actually I have 2 file upload controls in my form and according to the ng-upload plugin, it can handle only one file upload control (for single file or multiple files), from one control, I want to upload image & from other I want to upload pdf.
So how can I handle this..?

What is ng-upload plugin? Are you sure you are on the correct github module?

@danialfarid : sorry, I MISS the middle word. Its ng-file-upload.. I corrected that in my previous comment.
Ok.. But is there any solution for this..?

@rcbytes solution works!
But it has one problem when file name duplication exists.
it means that ,
if files[i].name is same '1.png' for all file, names will be ['1.png', '1.png' ... , '1.png']
In PHP, print_r($_FILES); shows that only $_FILES['1.png'] exists.
Solution :
add index prefix to name
    var names = [];
    for (var i = files.length - 1; i >= 0; i--)
        names.push(i + "_" + files[i].name);

    files.upload = $upload.upload({
        url: API_BASEURL + '/photo' + $scope.getReqParams(),
        method: 'POST',
        fileFormDataName: names,
        file: files
    });

Thanks for @rcbytes solution.

With the new version the fix don't work... because it force the "file" name of the field...
If i try the older version, with the fileFormDataName, i have this error (from angular):
Error: Failed to execute 'setRequestHeader' on 'XMLHttpRequest': 'function (xhr) {.....

Well nothing worked from the above.
The problem is the name that the js object is made.
All have the key "File" so you lose information when you upload it to PHP.
So the solution for me was:
        filesMulti = {};
        for (var i = files.length - 1; i >= 0; i--){
             filesMulti[i]=files[i];
        }

        Upload.upload({
            url: '/upload.php',
            method: 'POST',
            sendFieldsAs: 'form',
            fields: {},
            file: filesMulti
        })

I found now this solution:
Upload.upload({
                    url: apiUrl,
                    fields: params.fields,
                    file: {"files[]": files}
                })

And works well... except that server side i have $_FILES[0], $_FILES[1] etc.... instead of $_FILES["files"][0], $_FILES["files"][1] etc....

viandanteoscuro your solution works but "$_FILES[0], $_FILES[1] etc.... instead of $_FILES["files"][0]"
is a big problem for me.
Maybe any new ideas someone ? : )

请试试 arrayKey: '' ，可是使得服务端接收的 files[0], files[1], files[2] 变成 files数组
请叫我红领巾。

Another solution that works for me is similar to the above except I loop through each field in the single $_FILES file that gets created on the phpserver-side:
// Pass data to server
Upload.upload({
    url: 'path/to/the/php/server/file/or/api',
    data: {
        "patricksName": "twenty-four",
        "type": "starfish",
        "files": data.files
    }
}).then(successCallback, failureCallback);

/**
 * Convert weird structured array files to easy to read files.
 * Files uploaded with the angular-ng-file-upload library arrive to the server mixed up. The following function
 * simply separates each file property into its own object and then place it into an array.
 * @param $files
 * @return array
 */
function convertAngularNgUploadPostFile($files) {
  $numOfFiles = count($files['name']);
  $properFiles = array();
  for ($i = 0; $i < $numOfFiles; $i++) {
    $properFile = array(
      'name' => $files['name'][$i],
      'type' => $files['type'][$i],
      'tmp_name' => $files['tmp_name'][$i],
      'error' => $files['error'][$i],
      'size' => $files['size'][$i]
    );
    array_push($properFiles, $properFile);
  }
  return $properFiles;
}

Hi,
I am trying to use this module, but I am getting this error on Laravel Action:
$this->errors(['message' => 'Not an image.', 'code' => 400]);
This error happens in this if:
if ($validator->fails()) {
	return $this->errors(['message' => 'Not an image.', 'code' => 400]);
}

My image array:
$ngfBlobUrl : "blob:http://ci.dev/e1d8ae23-0ec5-4934-8285-47a956119fe2"
$ngfHeight : 843
$ngfWidth : 1097
lastModified :<PHONE_NUMBER>411
lastModifiedDate : Mon Nov 28 2016 16:27:33 GMT-0200 (Horário brasileiro de verão)
name : "Q2.png"
size : 36338
type : "image/png"
webkitRelativePath : ""
proto : File
My Laravel is returning this error:
Allowed memory size of 134217728 bytes exhausted (tried to allocate 65461749 bytes)
I have already increased my memory_limit from 128M to 512M in php.ini but I am now getting other errors like :
Type error: Argument 1 passed to Illuminate\Routing\Middleware\ThrottleRequests::addHeaders() must be an instance of Symfony\Component\HttpFoundation\Response, null given, called in C:\wamp64\www\cadastroimoveis\vendor\laravel\framework\src\Illuminate\Routing\Middleware\ThrottleRequests.php on line 53
I have just copied the example codes with no changes... I am using laravel 5.3 and angular 1.5.
Thanks.


How to use XRAnchorTransferBatch.ImportAsync(Stream) on Hololens 2

openxr version 1.8.0
I use XRAnchorTransferBatch to export anchors, but when I import anchors using XRAnchorTransferBatch.ImportAsync(Stream), null is returned.

Stream stream = new MemoryStream(anchorData);
stream.Seek(0, SeekOrigin.Begin);
var transferBatch = await XRAnchorTransferBatch.ImportAsync(stream);

anchorData is byte[] transfered.
result: transferBatch  is null

public static async Task ImportAsync(Stream inputStream)
{
AnchorTransferBatch anchorTransfer = new AnchorTransferBatch();
SerializationCompletionReason num = await anchorTransfer.ImportAsync(inputStream);

		if (num == SerializationCompletionReason.Succeeded)
		{
			return new XRAnchorTransferBatch(anchorTransfer);
		}

		return null;
	}

Result: SerializationCompletionReason is UnknownError

Presumably, you're transferring the anchor data over a network connection or something? Have you confirmed that the anchorData isn't being transformed somehow as part of the transfer process? i.e checking the size and doing a checksum on the byte array.

Presumably, you're transferring the anchor data over a network connection or something? Have you confirmed that the anchorData isn't being transformed somehow as part of the transfer process? i.e checking the size and doing a checksum on the byte array.

Hi WikkidEdd, thanks for your reply.
I found the problem inspired by you.
The problem is the anchor data is wrong during the export phase. So the data imported is wrong.

@ChasingD is there still an issue here?  From your last comment, sounds like you discovered an issue with the exported data.

The problem is the anchor data is wrong during the export phase. So the data imported is wrong.

Also, if there is still an issue, are you able to provide a Unity project with an isolated reproduction of the issue?   This will help expediate the investigation on our side.
If you are just in need of API assistance, you can follow-up with our support via https://aka.ms/mrsupport.  In this case, you would select help with "Immersive Headset Programming", concerning an "API" and "Spatial Anchors" issue.

Hi @ChasingD ,
I'm working on something similar but I'm having problems with the export phase of the anchors (I want export anchors on a database)
Can you provide me the piece of code/function that does the export? and the import?
Thanks


Optionally disable endpoints

Hi, I have a service where parts of the final Endpoint can be disabled with configuration switch. Due to each Endpoint[A] having a different type I end up with code like this
    if (Config.appleWebAuth) {
      val webService = (
        coreService
          :+: (Web.web
          :+: Web.webAuthAppleUrl
          :+: Web.webAuthAppleCallback)
        )
      val finalService = if (Config.mode == "test") {
        val devService = (
          webService
            :+: Auth.makeUser
          )
        devService.toService
      } else {
        webService.toService
      }
      server.serve(addr, new Cors.HttpFilter(Cors.UnsafePermissivePolicy).andThen(finalService))
    } else {
      if (Config.mode == "test") {
        val devService = (
          coreService
            :+: Auth.makeUser
          )
        server.serve(addr, devService.toService)
      } else {
        server.serve(addr, coreService.toService)
      }
    }

It's quite ugly and has duplicated code, because I can't just store any service in a variable. I'm sure there should be a better way I'm not aware of, could you please help me with that?

@edvorg I've been dealing with a similar problem to this quite recently. What I ended up with was creating multiple Apps in a repository. Basically multiple executables that can be run. In a development, the dev can just pick the one they want via sbt. For deployments, its a little dependent if you're using something like sbt-pack or sbt-assembly, but the main class has to be specified anyway so the build figures it out. Either way a deployment tool should be able to build a different artifact with pack or assembly based on role or some other attribute.
It looks like you're trying to define it with a config like env vars, ciris, or typesafe config. In which case unfortunately, you have to keep doing what you're doing.
If you could give a little more detail, I might be able to suggest a better solution.

I think you got the idea correctly, on the very basic level I'd like to have switches in application.conf

web frontend (on/off)
apple authentication (on/off)

And in application code instead of snipped above I'd like to do somethink like
var endpoint = ... // core endpoint here
if (Config.webFrontend) {
  endpoint = endpoint :+: webEndpoint
}
if (Config.appleAuth) {
   endpoint = endpoint :+: appleAuthEndpoint
}
server.serve(endpoint.toService)

Though I can't due to type-safety of Endpoint

The simplest way would be to use Either[TestEndpoints, ProdEndpoints] returning Right or Left from corresponding branches and then fold it into Service

@sergeykolbasov that's interesting didn't think about it. I guess the end I would have something like
Either[Either[Endpoint[WithAWithB], Endpoint[WithAWithoutB]], Either[Endpoint[WithoutAWithB], Endpoint[WithoutAWithoutB]]]

Then my problem would reduce to flattening this Either into some particular Service. I'm not quite sure if it's possible though

I tend towards some type-erasure / reflection magic though, because I don't really care about final type of my endpoint, all I need is to get an instance of Service no matter what combination of endpoints I had. It means that all the type-safety could happens somewhere under simple abstraction that allow me to call toService and get a service.

I suspect it can't figure out what Decodes it needs to summon in order to make the toService call. I don't see it in  your example above, but I'm assuming you have io.finch.circe._ and any circe decoders that you need imported somewhere in the file. Even with those I'm not sure if the compiler will be able to figure out the types of the endpoint correctly.
This might be a case where Bootstrap works better. If you are on a version of Finch greater than 0.16.0-M2 you should be able to do something like this:

Thanks, I'll give it a try next week. Seems similar to what I proposed above.

Sorry, for such a long delay. Was occupied with other things. I gave Bootstrap a try and it seems to be very much like the class I introduced above. Though I hit the same problem decoders. I guess this is not something finch can solve for me, so I'm closing this issue.

Eventually refactored in something like this
  private def makeServer(addr: String, server: Http.Server) = {
    implicit val conf: Configuration = Configuration.default.withDiscriminator("status")
    import io.circe.generic.extras.auto._
    if (ApiConfig.appleWebAuth) {
      val finalService = if (Config.mode == "integration") {
        (makeCoreService :+: makeWebService :+: makeTestService).toService
      } else {
        (makeCoreService :+: makeWebService).toService
      }
      server.serve(addr, new Cors.HttpFilter(Cors.UnsafePermissivePolicy).andThen(finalService))
    } else {
      if (Config.mode == "integration") {
        server.serve(addr, (makeCoreService :+: makeTestService).toService)
      } else {
        server.serve(addr, makeCoreService.toService)
      }
    }
  }


Add Windows 9x Flag Logo

Description
Can you add a ascii windows 9x logo

This PR includes many unrelated changes. Please submit another one.


Light theme

The website seems to be dark themed , I would like to add light theme to the website to enhance the visual appeal. Please assign this to me.

assign me this as GSSOC'24 contribution and add lebel

Thanks for your suggestion, but for now, I don't think it would look good on the light theme. It would also be very difficult to implement.


uncaughtException: report more than one exception per test

Description
describe('suite', function() {
  it('should report the first of multiple exceptions', function(done) {
    process.nextTick(() => {
      console.log('first');
      throw new Error('first');
    });
    process.nextTick(() => {
      console.log('second');
      done(new Error('second'));
    });
  });
});

The first error is not reported at all, instead the output shows two copies of the second error.
  suite
first
    1) should report the first of multiple exceptions
second
    2) should report the first of multiple exceptions

  0 passing (10ms)
  2 failing

  1) suite
       should report the first of multiple exceptions:
     Error: second
      [...]

  2) suite
       should report the first of multiple exceptions:
     Error: second
      [...]

Description of the Change

test.err: currently is storing just one error per test, in case of multiple errors it's the last one. I haven't changed its type to Array for backwards compability and instead introduced a new property test.err.multiple to store additional errors. The latter is set within the EVENT_TEST_FAIL event handler.
output: I applied the changes to Base.list() which is part of the epilogue used by most builtin reporters.
Reporters as "json" or "XUnit" which don't rely on the Base#epilogue() remain mostly unchanged and do not list multiple errors per test. They list now the first error instead of the last one.

Applicable issues
#2906 partially

Coverage decreased (-0.06%) to 92.677% when pulling 8b04955b9154fdc70ac583ff3739373fcb4deb22 on juergba/uncaught-double into 5f8df0848aa52bb0f7a0844bcd3715012a6ecfd6 on master.

I'm going to merge this PR within the next few days.


Provide the way of removing PODs along with Replication controller removal

kubectl delete <rep controller name>

deletes the RC as well as all the pods associated with the RC. That's the default kubectl behavior. If only RC needs to be removed, flag --cascade=false should be passed explicitly to the command.
In the UI, PODs always have to be cleaned separately. We should provide a way to cleanup corresponding pod resources the way kubectl does (steps kubectl makes, are listed by the link below):
http://kubernetes.io/docs/user-guide/replication-controller/, "Deleting a Replication Controller and its Pods" section
@vincent99

Duplicate of https://github.com/rancher/rancher/issues/4359


Raise on unexpected metadata values

The existing implementation was causing segmentation fault because
src/ruby/ext/grpc/rb_call.c:358 was trying to convert any value type other than
Array to String. The Array type is handled in first if.
This change will cause the Ruby code that sends non-string values to fail
with a better message: ArgumentError: Header values must be of type string or array
Before this fix, when I was sending metadata which value type was different than Array or String to client_streamer, e.g. client_streamer(@method, @sent_messages, noop, noop, remote_op: true, some_key => true), this would cause a segmentation fail:
ClientStub
  #client_streamer
    via a call operation
      behaves like client streaming
/Users/rafaelsales/data/ws/grpc/src/ruby/lib/grpc/generic/active_call.rb:83: [BUG] Segmentation fault at 0x00000000000000
ruby 2.2.2p95 (2015-04-13 revision 50295) [x86_64-darwin14]

-- Crash Report log information --------------------------------------------
   See Crash Report log file under the one of following:
     * ~/Library/Logs/CrashReporter
     * /Library/Logs/CrashReporter
     * ~/Library/Logs/DiagnosticReports
     * /Library/Logs/DiagnosticReports
   for more details.

-- Control frame information -----------------------------------------------
c:0044 p:---- s:0191 e:000190 CFUNC  :run_batch
c:0043 p:0105 s:0184 e:000183 METHOD /Users/rafaelsales/data/ws/grpc/src/ruby/lib/grpc/generic/active_call.rb:83
c:0042 p:0040 s:0177 e:000176 METHOD /Users/rafaelsales/data/ws/grpc/src/ruby/lib/grpc/generic/active_call.rb:456
c:0041 p:0020 s:0173 e:000172 METHOD /Users/rafaelsales/data/ws/grpc/src/ruby/lib/grpc/generic/active_call.rb:345
c:0040 p:0018 s:0166 e:000165 LAMBDA /Users/rafaelsales/data/ws/grpc/src/ruby/lib/grpc/generic/client_stub.rb:238 [FINISH]
c:0039 p:0057 s:0164 e:000163 METHOD /Users/rafaelsales/data/ws/grpc/src/ruby/spec/generic/client_stub_spec.rb:244

With the implementation of this PR, we now get a proper validation error like the one below, which is easier to understand why the error occurred:

Can one of the admins verify this patch?

Can one of the admins verify this patch?

Can one of the admins verify this patch?

Can one of the admins verify this patch?

I signed it!

Should I add a spec for this? I'm curious because I couldn't find any spec testing the raised errors that validate parameters on the rb_call.rc file.

It'd be great if you could! (and thanks for your efforts so far)
We're in a quiet time for commits currently - I hope it's ok if we delay
merging until early next week?
On Tue, Mar 1, 2016 at 9:44 PM Rafael Sales<EMAIL_ADDRESS>wrote:

Should I add a spec for this? I'm curious because I couldn't find any spec
testing the raised errors that validate parameters on the rb_call.rc file.
—
Reply to this email directly or view it on GitHub
https://github.com/grpc/grpc/pull/5528#issuecomment-191073778.

@ctiller Sure, thanks for your time. Added the spec for this validation, btw.

Can you update this with the latest changes from master so that we can merge it?

@murgatroid99 Thanks for bringing this up. Just rebased the branch. Thanks

This is OK to test.

@murgatroid99 Only test failed is not related to the changes: tests.csharp.coverage
Thanks

Is this LGTM?

Yes, LGTM.


test DragonFlyBSD ci

What does this PR do
Test the DragonFlyBSD CI failure in #2277, theoretically, I should be able to reproduce it in this PR.

Maybe this is not a bug but a feature, such a check was introduced in rust#118297: Merge unused_tuple_struct_fields into dead_code

It looks like those fields only exist in order to keep a slice from dropping while we have a pointer to it. What about changing the function signature so we keep the user's original slice around? Something like:
fn send_file_header_trailer(headers: &Option<Vec<IoSlice<'a>>>, trailers: ...) -> Option<libc::sf_hdtr> {
    ...
}

Ahh, I see now why it was done this way.  Because sf_hdtr needs its headers and trailers to be in the form of a slice of iovec, which has a different layout than &[&[u8]].


Controls not showing

Question
I have a custopm FieldType that display ion buttons. The buttons are loaded from an API and they are changig based on another values of the model
This is html
<ion-input [type]="props.type || 'text'" [formControl]="formControl" [ionFormlyAttributes]="field"></ion-input>
<ion-list>
  <ng-container *ngFor="let action of smActions">
    <ion-button color="{{getColor(action)}}" (click)='executeAction(action)'>{{action.buttonTranslationKey
      |translate}}</ion-button>
  </ng-container>

and the component
import { Component, OnInit, Type } from '@angular/core';
import { FieldType, FieldTypeConfig, FormlyFieldConfig, FormlyFieldProps } from '@ngx-formly/core';
import { FormlyFieldInput } from '@ngx-formly/ionic/input';
import { TranslateService } from '@ngx-translate/core';
import { SmAction } from '../../state-machine/sm-action/sm-action';
import { SmActionService } from '../../state-machine/sm-action/sm-action.service';
import { WrappersModuleLoco } from '../wrappers.module';
interface InputProps extends FormlyFieldProps { }

export interface FormlyInputFieldConfig extends FormlyFieldConfig<InputProps> {
  type: 'input' | Type<FormlyFieldInput>;
}
@Component({
  standalone: true,
  selector: 'app-ionic-sm-buttons',
  templateUrl: './ionic-sm-buttons.component.html',
  styleUrls: ['./ionic-sm-buttons.component.css'],
  imports: [
    WrappersModuleLoco
  ]
})
export class IonicSmButtonsComponent extends FieldType<FieldTypeConfig<InputProps>> implements OnInit {
  smActions: SmAction[]
  objectType: string;
  objectId: string;
  constructor(
    public smActionService: SmActionService,
    public translate: TranslateService) {
    super()
  }
  ngOnInit() {
    this.objectId = this.field.parent.model.id
    this.loadActions();

  }
  executeAction(action: SmAction) {
    // this.smActions = null
    this.smActionService.executeAction(this.objectId,action.actionID)
      .subscribe(
        response => {
          this.model['currentStateId'] = response.currentStateId
          this.loadActions();
        }
      )
    console.log(action);
  }
  loadActions() {
    this.smActionService.getActions(this.objectId).subscribe(
      values => {
        this.smActions = values
      }
    )
  }
  getColor(action: SmAction) {
    if (action.props) {
      return action.props["Color"] ? action.props["Color"] : "";
    }
    return ""
  }

}

When I executeAction the buttons are not redrawn also if I'm changing the model.
If I focus on the input then the buttons are displayed.
What do I have to do to force redraw of the buttons on execute action
In the end I want to remove the input and leave only the buttons

Same here, Formly works with Angular standalone components?

see https://github.com/ngx-formly/ngx-formly/issues/3721#issuecomment-1602401526

see #3721 (comment)

My issue is that my  is not shown when the actions are changing

@atzimot could you please provide a reproduction, here is our stackblitz starter example:
https://stackblitz.com/edit/ngx-formly-ui-bootstrap
Thanks!


Contain eval() in a cage in instrumentation

There are many problems and annoying edge cases with eval(). Solving them all in output code is very tricky (#278), but should at least be possible to simplify handling it in instrumentation.
I made a good attempt to solve it in https://github.com/overlookmotel/livepack/issues/137#issuecomment-1321028223 but the implementation has become tortuously complex.
To prevent eval()'s effects leaking outside of it, and requiring workarounds all over the instrumentation code, it'd be better to try to contain its effects by running it in a global scope "cage" and injecting all external variables into that environment.
e.g. input:
const x = 123;
function f(y) {
  return eval('() => [x, y += 100, this, arguments]');
}
module.exports = f();

Instrumented:
const x = 123;
function f(y) {
  let livepack_temp1;
  return (
    livepack_temp1 = livepack_tracker.evalDirect(
      [ '() => [x, y += 100, this, arguments]' ],
      (eval, livepack_temp2) => eval(livepack_temp2),
      () => eval,
      v => eval = v
    ),
    livepack_temp1.eval && eval(livepack_temp1.eval),
    livepack_temp1.exec()
  );
}
module.exports = f();

evalDirect() would instrument the the eval-ed code as:
(_get, _set, livepack_tracker, livepack_getScopeId) => () => [
  _get('x'),
  _set('y', _get('y') + 100),
  _get('this'),
  _get('arguments')
]

evalDirect() would return an object with .eval and .exec properties.
.eval() is called first to create any bindings in outer scope due to var statements or sloppy function declarations in the eval-ed code (these can be determined statically).
.exec() is called 2nd.

It calls the instrumented function, injecting _get and _set.
The instrumented function can be called with indirect eval ((0, eval)(code)).
_get and _set use the 2rd argument to evalDirect() to execute get/set operations in the surrounding context.
_get and _set use the 3rd + 4th arguments if the code inside eval itself gets or sets an external var eval.
_get and _set can remove themselves from stack traces where there's an error.

Previous attempts to solve the problems of eval() have aimed to make minimal changes to the eval-ed code and use cunning wheezes to inject vars with with (...) {}, and other ploys to inject this, arguments, new.target and super.
The above suggestion takes a different approach. The changes to the eval-ed code are very invasive. However, as both the code inside and outside the eval() is statically analysed, we can know which variables the eval code accesses, so it's possible to translate it in full.
e.g.:

_set() can be passed a third argument for whether the position where _set() is called is strict or sloppy mode, so it can throw an error or fail silently accordingly if the assignment cannot succeed.
var statements in sloppy mode create bindings in the outer function. This can be determined statically and executed.
delete x can also be handled.

Despite the invasiveness, I actually think it's simpler overall than other attempted solutions, because all the actions are confined to within eval() itself.

Actually, there is one case I'm not sure how to handle.
function f() {
  eval('eval("var x = 123")');
  return x;
}

The inner eval() creates a binding in outer scope. But this can't be statically deduced before running the code.
Argh!
Maybe could solve by adding a with () {} to the outer function:
// Instrumented
function f() {
  const livepack_temp1 = Object.create(null);
  with (livepack_temp1) {
    livepack_tracker.evalDirect('eval("var x = 123")', ..., livepack_temp1);
    return x;
  }
}

Any var declarations could be identified when the inner eval() is executed, and added as properties to livepack_temp1 (if eval-ed code fails to run with a syntax error, they could be removed again before they're observable elsewhere).

Yes, actually above idea might be quite good.
Source (original example):
const x = 123;
function f(y) {
  return eval('() => [x, y += 100, this, arguments]');
}
module.exports = f();

Instrumented:
const x = 123;
function f(y) {
  const livepack_dynamicVars = Object.create(null),
    livepack_dynamicVarsEvalOnly = Object.create(null);
  with (livepack_dynamicVars) {
    return livepack_tracker.evalDirect(
      [ '() => [x, y += 100, this, arguments]' ],
      {
        x: () => x,
        y: [ () => y, v => y = v ],
        this: () => this,
        arguments: [ () => arguments, v => arguments = v ],
        'new.target': () => new.target
      },
      livepack_dynamicVars,
      livepack_dynamicVarsEvalOnly
    );
  }
}
module.exports = f();

There are no direct eval() calls left at all. livepack_dynamicVars can also be used in the tracker when serializing functions to determine if the function uses any of these dynamically declared vars.
This could even handle vars created with names which clash with Livepack's internal vars in outer scope e.g. var livepack_tracker. Any such vars can only be accessed within eval()s because if they appeared in the outer code, Livepack's vars would have been named with a higher prefix num so as not to shadow them. So any such vars can be stored in a 2nd object which is only used for eval(), and not included in the with() {} context. This is what livepack_dynamicVarsEvalOnly is for.
Would also integrate nicely with support for with () {} (https://github.com/overlookmotel/livepack/issues/136#issuecomment-1426287482).

In addition to _get and _set, a 3rd function _delete could be used to delete dynamic bindings. i.e. delete x would be replaced with _delete('x').

Function declarations also behave the same as var declarations in sloppy mode eval (including where they're hoisted from an nested block).
(0, eval)('function a() {}');
assert(typeof global.a === 'function');

(0, eval)('{ function b() {} }');
assert(typeof global.b === 'function');

(() => {
  eval('function c() {}');
  assert(typeof c === 'function');
  assert(typeof global.c === 'undefined');

  eval('{ function d() {} }');
  assert(typeof d === 'function');
  assert(typeof global.d === 'undefined');
})();

For indirect eval, need to wrap eval-ed code in a function to inject Livepack's internal vars and then execute the eval-ed code within a direct eval() call to get its completion value.
If eval-ed code is: var x = 123; 456, the code to define this function would be:
(livepack_tracker, livepack_getScopeId, livepack_temp1) => {
  with (livepack_temp1) {
    return eval('var x = 123; 456');
  }
}

Function would be called with:
const nativeEval = global.eval; // Before it's shimmed
const withObj = {
  __proto__: null,
  get eval() {
    delete this.eval;
    return nativeEval;
  }
};
f(tracker, getScopeId, withObj);

The with () {} block serves to temporarily provide the native eval function for the nested eval() call, and then destroys it before the eval-ed code executes, leaving the eval-ed code to run in an unaltered global context.

Just realised, the "cage" approach will prevent super working in eval(). Would require transpiling super or passing in functions which execute super(), super.foo, super.foo(), super.foo = x etc.


AVPRO VIDEO integration with Vimeo SDK

Hi,
I need to integrate AVPro Video in Vimeo SDK for adaptive resolution, but I can't.
Can you help me, please?

Unity version 2018.2.14f1
Operating system Windows 10, but I'm developing for Android

Hello, we are also having this problem when trying to reproduce a live video on AvPro.
We get this link loaded on AvPro but it doesn't work:
https://live.vimeocdn.com/1608749269-0x3fa2cfc6dafe89ffbeffbe30995cb71b608fce7b/33619fe3-18f9-4c7c-b89f-7d49609475f7/manifest_mvtime.mpd
The codecs shown on AvPRO:
.m3u8
.mdp
.ism
MPD is the same as MDP?
[AVProVideo] Error: Loading failed.  File not found, codec not supported, video resolution too high or insufficient system resources.
UnityEngine.Debug:LogError(Object)
Did you get this working savek1986?
It would really help us.
Thanks


TRXBTC symbol for 1M has negative volume

https://github.com/sonvister/Binance/blob/da2967a181212fda937a28ed6fcdd284f0778966/src/Binance/Market/Candlestick.cs#L134
Reprosteps: await _binanceApi.GetCandlesticksAsync("TRXBTC", CandlestickInterval.Month);
Json:

Inner exception: Candlestick: volume must not be less than 0. Parameter name: volume
StackTrace:    at Binance.Candlestick..ctor(String symbol, CandlestickInterval interval, DateTime openTime, Decimal open, Decimal high, Decimal low, Decimal close, Decimal volume, DateTime closeTime, Decimal quoteAssetVolume, Int64 numberOfTrades, Decimal takerBuyBaseAssetVolume, Decimal takerBuyQuoteAssetVolume)
at Binance.Serialization.CandlestickSerializer.<>c__DisplayClass14_0.b__0(JToken item)
at System.Linq.Enumerable.SelectIListIterator2.ToArray()    at System.Linq.Enumerable.ToArray[TSource](IEnumerable1 source)
at Binance.BinanceApi.d__26.MoveNext()

@sguryev, thanks for reporting the exception. I have asked if the data is valid on the official API Telegram. Although, I can't imagine what a negative volume would represent if it is valid data.

@sonvister absolutely agree with you. I'm getting a bunch of symbols for 1M using Task.WhenAll and now have to make a tricky Task.Run() workaround in order to swallow the exception. We can point them to the specific API call and ask for the negative value though

UPDATE: The query (https://api.binance.com/api/v1/klines?symbol=TRXBTC&interval=1M) still returns a negative volume....


Copy-DbaDatabase fails in Get-FilteredRestoreFile

Bug Report

General Troubleshooting steps

[x ] Verified running latest release of dbatools?
[x] Verified errors are not related to permissions?
[x] Can duplicate in new/fresh PowerShell.exe session?

Version Information

Operating System (Name|Version): win 2012 r2
PowerShell Version: 5
SQL Server (Edition|Version): sql 2014

Steps to Reproduce
$source = "sourceserver,port"
$destination = "destinationserver,port"
Copy-DbaDatabase -Source $source -Destination $destination -Database "DBNAME" -verbose -BackupRestore -force -NetworkShare \sharepath
The backup to a share or the destination server works fine.  It errors on [Get-FilteredRestoreFile].  I can see it prints the dbname:
VERBOSE: [Get-FilteredRestoreFile][08:30:38] Find Newest Full backup - DBNAME
VERBOSE: dbname = PORTNUMBER DBNAME
Console output attached.

[ ] Attach any screenshots (if possible/allowed)
[ ] Attach logs generated by dbatools (Get-DbatoolsLog)
[x] Attach output from PowerShell console (if possible/allowed)

Problem to solve
It looks like the split on comma in the code is causing a problem when a port is provided (line 169):
        $ServerName, $databaseName = $Database.Name.split(',').trim()
        Write-verbose "dbname = $databasename"
        $SQLBackupdetails = $AllSQLBackupdetails | Where-Object {$_.ServerName -eq $ServerName -and $_.DatabaseName -eq $DatabaseName.trim()}
        #If we're continuing a restore, then we aren't going to be needing a full backup....
        $TlogStartlsn = 0
        if (!($continue)) {
            $Fullbackup = $SQLBackupdetails | where-object {$_.BackupTypeDescription -eq 'Database' -and $RestoreTime -ge $_.BackupStartDate} | Sort-Object -Property LastLSN -descending | Select-Object -First 1
            $TlogStartlsn = $Fullbackup.LastLsn
            if ($Fullbackup -eq $null) {
                Stop-Function -Message "No Full backup found to anchor the restore" -Continue -Target $database
                break
            }
            #This scans for striped full backups to build the results
            $Results += $SQLBackupdetails | where-object {$_.BackupTypeDescription -eq "Database" -and $_.FirstLSN -eq $FullBackup.FirstLSN -and $_.BackupSetGUID -eq $FullBackup.BackupSetGUID}
        }

this makes the code throw an error:  WARNING: [Get-FilteredRestoreFile][08:45:43] No Full backup found to anchor the restore
I have to pass in servername,port.  This appears to cause a problem in this function.
Additional information

copy database error.txt

I am seeing the same thing with the backup-dbadatabase command.  I am seeing it with servers that have named instances.  Not sure if that is part of the issue or not.
PS E:\Powershell\MaintenancePlan> Get-DbaBackupHistory -SqlInstance ServerName -Database DatabaseName -Last
SqlInstance    Database Type         TotalSize DeviceType Start                   Duration End

ServerName DatabaseName    Full         1.69 GB   Disk       2017-10-19 08:31:19.000 00:04:43 2017-10-19 08:36:02.000
ServerName DatabaseName    Differential 4.77 MB   Disk       2017-10-19 09:48:35.000 00:00:01 2017-10-19 09:48:36.000
PS E:\Powershell\MaintenancePlan> Backup-DbaDatabase -SqlInstance ServerName -Database DatabaseName -BackupDirectory \BackupLocation\SQLBackups1\machinename\DIFF -Type Differential -CreateFolder -Checksum -Verify
WARNING: \BackupLocation\SQLBackups1\ryantms\DIFF\DatabaseName already exists
WARNING: [Get-FilteredRestoreFile][10:02:19] No Full backup found to anchor the restore
WARNING: [Backup-DbaDatabase][10:02:19] Backup Failed:  Cannot index into a null array.
SqlInstance      : ServerName
DatabaseName     : DatabaseName
BackupComplete   : False
BackupFilesCount : 1
BackupFile       : DatabaseName_201710191002.bak
BackupFolder     : \BackupLocation\SQLBackups1\ryantms\DIFF\DatabaseName
BackupPath       : \BackupLocation\SQLBackups1\ryantms\DIFF\DatabaseName\DatabaseName_201710191002.bak
Script           : BACKUP DATABASE [DatabaseName] TO  DISK = N'\BackupLocation\SQLBackups1\ryantms\DIFF\DatabaseName\DatabaseName_201710191002.bak' WITH  DIFFERENTIAL , NOFORMAT, NOINIT, NOSKIP, REWIND, NOUNLOAD,  STATS = 1, CHECKSUM
Verified         : False
Type             : Differential
PS E:\Powershell\MaintenancePlan> Get-DbaBackupHistory -SqlInstance ServerName -Database DatabaseName -Last
SqlInstance    Database Type         TotalSize DeviceType Start                   Duration End

ServerName DatabaseName    Full         1.69 GB   Disk       2017-10-19 08:31:19.000 00:04:43 2017-10-19 08:36:02.000
ServerName DatabaseName    Differential 4.77 MB   Disk       2017-10-19 10:02:16.000 00:00:01 2017-10-19 10:02:17.000

Working on some other bits with restore atm, and hoping to roll the fix for
this in to that.
Potentially pushing up later tonight
Cheers
Stuart
On Thu, 19 Oct 2017 at 16:07 dczarny<EMAIL_ADDRESS>wrote:

I am seeing the same thing with the backup-dbadatabase command. I am
seeing it with servers that have named instances. Not sure if that is part
of the issue or not.
PS E:\Powershell\MaintenancePlan> Get-DbaBackupHistory -SqlInstance
ServerName -Database DatabaseName -Last
SqlInstance Database Type TotalSize DeviceType Start Duration End
ServerName DatabaseName Full 1.69 GB Disk 2017-10-19 08:31:19.000 00:04:43
2017-10-19 08:36:02.000
ServerName DatabaseName Differential 4.77 MB Disk 2017-10-19 09:48:35.000
00:00:01 2017-10-19 09:48:36.000
PS E:\Powershell\MaintenancePlan> Backup-DbaDatabase -SqlInstance
ServerName -Database DatabaseName -BackupDirectory
\BackupLocation\SQLBackups1\machinename\DIFF -Type Differential
-CreateFolder -Checksum -Verify
WARNING: \BackupLocation\SQLBackups1\ryantms\DIFF\DatabaseName already
exists
WARNING: [Get-FilteredRestoreFile][10:02:19] No Full backup found to
anchor the restore
WARNING: [Backup-DbaDatabase][10:02:19] Backup Failed: Cannot index into a
null array.
SqlInstance : ServerName
DatabaseName : DatabaseName
BackupComplete : False
BackupFilesCount : 1
BackupFile : DatabaseName_201710191002.bak
BackupFolder : \BackupLocation\SQLBackups1\ryantms\DIFF\DatabaseName
BackupPath :
\BackupLocation\SQLBackups1\ryantms\DIFF\DatabaseName\DatabaseName_201710191002.bak
Script : BACKUP DATABASE [DatabaseName] TO DISK =
N'\BackupLocation\SQLBackups1\ryantms\DIFF\DatabaseName\DatabaseName_201710191002.bak'
WITH DIFFERENTIAL , NOFORMAT, NOINIT, NOSKIP, REWIND, NOUNLOAD, STATS = 1,
CHECKSUM
Verified : False
Type : Differential
PS E:\Powershell\MaintenancePlan> Get-DbaBackupHistory -SqlInstance
ServerName -Database DatabaseName -Last
SqlInstance Database Type TotalSize DeviceType Start Duration End
ServerName DatabaseName Full 1.69 GB Disk 2017-10-19 08:31:19.000 00:04:43
2017-10-19 08:36:02.000
ServerName DatabaseName Differential 4.77 MB Disk 2017-10-19 10:02:16.000
00:00:01 2017-10-19 10:02:17.000
—
You are receiving this because you were assigned.
Reply to this email directly, view it on GitHub
https://github.com/sqlcollaborative/dbatools/issues/2429#issuecomment-337938140,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AFWoZmAqAeZhRcpWDyQ6ANjVya-oqvv6ks5st2XFgaJpZM4P0D8E
.

Just pushed up #2479 which should fix this. if you could take the restorebits branch for a test drive that'd be great

I tested this and it works now.  Thanks @Stuart-Moore!


Change Nickname field to Primary Name

Change the label of the Nickname field to Primary Name, make sure that documentation and documentation screenshots are updated

PR: #1468

:+1:


"-" aways compiled to "·”. Could you update to latest showdown version please?

ghost 0.11.7
A suggestion: please compiled "-" with spaces before and after "-", even at the start of a line, the "-" should be compiled with a space after. Even the ">", and other rules, if no space after them, don not compiled.
AND
Could you update to latest showdown version please?

I'm not sure what this means. Can you please provide full details? Should this maybe be raised as a bug against Ghost?

OK, I'll raise this bug against Ghost.


feat: Notification page split view layout

Addresses ONYX-623
Description
This PR sets up the new Activity page split view, which displays the activity list on the left and the activity detail view on the right.
On mobile the page displays either only the list or only the detail view depending on the URL:

/notifications -> List view
/notification/$id` -> Detail view

When the user opens /notifications directly, the first activity/notification will be selected and displayed.
Video & Screenshots

https://github.com/artsy/force/assets/4691889/01dbac19-afa1-4a81-8feb-d539826a5e98

Nicely done @olerichter00


FBSnapshot Tests Broken

Looks like the FBSnapshot tests were never functional on CI, but as CI was broken for other reasons we didn't realise! 😞
As part of the work done in #1075 to fix all of the CI issues the tests have been commented out, we should add them back and get them fully functional to start reaping the rewards!
@Austinate - Are you able to help out at all with this?

Hm, that's strange, sorry for that.
Will take a look

After investigation i can say that part of issue was that i forgot to make Freetime scheme a shared one (so i only had 'environment variables' locally).
This is easily fixable.
Another part i realized right now is that for full-VC snapshots we will need snapshot-per-device or we should probably decide which device we will use for snapshot testing. (Also there is a same requirement for 2x/3x snapshots, we would need to make both or lockdown on 1 device probably).

Closing since I'm not sure this is worth the time


Fix EventPattern to be usable in CloudWatch Events Rules

Note: for support questions, please first reference our documentation, then use Stackoverflow. This repository's issues are intended for feature requests and bug reports.

I'm submitting a ...

[X] :beetle: bug report
[ ] :rocket: feature request
[ ] :books: construct library gap
[ ] :phone: security issue or vulnerability => Please see policy
[ ] :question: support request => Please see note at the top of this template.

What is the current behavior?
If the current behavior is a :beetle:bug:beetle:: Please provide the steps to reproduce
I can create a CloudWatch Event Rule that uses a Schedule as follows:

new events.Rule(this, "heartbeat_rule", {
      schedule: events.Schedule.expression("rate(30 minutes)"),
...
    });

But if I try to do that with an EventPattern, it is undefined. Example:
new events.Rule(this, "heartbeat_rule", {
      eventPattern: events.EventPattern.source([...]),
...
    });

events.EventPattern is undefined.

What is the expected behavior (or behavior of feature suggested)?
My expectation is that I should be able to use EventPattern as described in the docs here<EMAIL_ADDRESS>
I can't figure out how to use an EventPattern though.  I think maybe because it is an Interface, but nothing seem to implement that Interface.

What is the motivation / use case for changing the behavior or adding this feature?
I want to create a CloudWatch Events Rule to receive GuardDuty events.

Please tell us about your environment:

CDK CLI Version: 0.35.0
Module Version: aws-events
OS: [all | Windows 10 | OSX Mojave | Ubuntu | etc... ]
Language: [all | TypeScript | Java | Python ]

Other information (e.g. detailed explanation, stacktraces, related issues, suggestions how to fix, links for us to have context, eg. associated pull-request, stackoverflow, gitter, etc)

new events.Rule(this, "heartbeat_rule", {
      eventPattern: events.EventPattern.source([...]),
...
    });

I'm not even sure how the proposed code compiles. EventPattern is an interface, not a class, so this can't work in either TypeScript or JavaScript.
The correct syntax would be:
new events.Rule(this, "heartbeat_rule", {
      eventPattern: {
         source: ['...']
      },
    });

I will admit it's not super obvious that one uses a class constructor and the other one uses an object literal.

Please reopen if you have further questions or remarks.


[PoC] reinstate get_params

Addresses https://github.com/pytorch/vision/pull/7092#issuecomment-1384533260. The core idea is the following:

add two new static methods: get_params and _get_params_internal (name up for discussion)
implement the actual sampling in _get_params_internal
Call that from _get_params and get_params and wrangle it in the respective format there

cc @vfdev-5 @datumbox @bjuncek

i.e. just let _get_params() do 99% of the work and massage what needs to be in the public get_params()? This way when/if we remove get_params() eventually, we won't have to change the other methods.

get_params cannot call _get_params since the former is a static method while the latter is an instance method. The only way to eliminate is to let _get_params call get_params, but for v2 we made a few performance and structure improvements that will be hard to backport. For example, without a third method we can't have extra fields in the return value that we commonly use in v2 to avoid performing an operation in the first place.
Of course we could also create a dummy object that represents self if we want to call _get_params from get_params. IIRC, we only ever access values in there and so a simple namespace would suffice.
As a final note, I don't know if we supported or enforced JIT scriptability on get_params. We need to check that as well.

Of course we could also create a dummy object that represents self if we want to call _get_params from get_params. IIRC, we only ever access values in there and so a simple namespace would suffice.
As a final note, I don't know if we supported or enforced JIT scriptability on get_params. We need to check that as well.

I did a little digging. get_params is old concept that almost dates back to the beginning of the transforms API. It was conceptualized in https://github.com/pytorch/vision/issues/230#issuecomment-324892358, albeit as instance method. Over the course of the PR that addressed the issue, the design changed to the current static method in https://github.com/pytorch/vision/pull/240#issuecomment-329969295. Interestingly, in the beginning get_params was used for all kind of parameter sampling not just random sampling. For example, it was also used for CenterCrop:
https://github.com/pytorch/vision/blob/4390b559afc2774f0b506e59a82a0b1e9c374c52/torchvision/transforms.py#L297-L303
We have similar behavior in v2, although not for CenterCrop since the computation moved into the kernels eventually.
At this point, JIT was non-existent and thus also not part of the design. That changed with #2292, which mostly dealt with unifying the PIL and tensor backend, but also required JIT scriptability. The original plan only comprised deterministic transforms, which makes sense. However, later on the list was extended to also include random transforms. JIT scriptability is useful for inference, but I can't think of a use case of using random transforms for that. Unfortunately, it is unclear from the context whether this was done to achieve full scriptability of the transforms API or if it was backed by an actual use case. cc @vfdev-5 @fmassa
In any case, JIT scriptability of get_params is enforced through our tests. Since the forward of the random transforms call into get_params, scripting the transform covers it as well:
https://github.com/pytorch/vision/blob/c06d52b1c5f6aee36802661c3ebc6347b97cc59e/test/test_transforms_tensor.py#L66-L71
https://github.com/pytorch/vision/blob/c06d52b1c5f6aee36802661c3ebc6347b97cc59e/test/test_transforms_tensor.py#L143-L144
(This is just exemplary. You can find JIT tests for all other transforms as well in the same test module)
In conclusion, JIT scriptability of get_params was intentional and is currently enforced for v1. I can't think of a use case where this is useful, but maybe I'm missing something.
I think we should tie the decision here to our decision for JIT scriptability in general: if we decide to support it (temporarily or permanently) after all, the same should apply to the temporary get_params for BC. Meaning, if we need to support JIT scriptability, we need to go with what I proposed above. If we don't we maybe can get away with a fake self namespace.

In 21946f7f2a76113d9d4157bc6db496a0cbf2ef56 I've added a design that uses a fake self namespace. It just wraps the regular _get_params and thus will be very easy to remove after the deprecation period.

Thanks a lot for the deep dive Philip

I think we should tie the decision here to our decision for JIT scriptability in general: if we decide to support it (temporarily or permanently) after all, the same should apply to the temporary get_params for BC. Meaning, if we need to support JIT scriptability, we need to go with what I proposed above. If we don't we maybe can get away with a fake self namespace.

I agree, let's postpone this decision until we're clearer about the JIT requirements

One option that has slipped my mind so far: if we only want to support get_params until transforms v2 is stable and deprecate and remove it together with v1, we could just simply alias the v1 function:
class MyTransformV2(transforms.Transform):
     ...

     @staticmethod
     def get_params():
         return MyTransformV1.get_params()

A naming nitpick: should this be better called sample_params? To reflect in the naming that in most of cases it will do some calls to randomness (an thus might be a good idea to also allow an optional generator= argument as an idiom)

A naming nitpick: should this be better called sample_params?

Yes, probably, but we're only introducing those for BC - the goal is to be backward-compatible, so we have to keep the same name.

Superseded by #7153.


DistractionListScreen not updating after adding new distraction through CreateDistractionScreen

Currently, when a user adds a new distraction to the application using the CreateDistractionScreen, the DistractionListScreen does not get updated immediately. Instead, the user must close and reopen the app in order to see the new distraction in the list.

Fixed!


Failed to create new container

I have followed the instructions in the tutorial and i get exception of authorization
com.microsoft.azure.storage.StorageException: Server failed to authenticate the request. Make sure the value of Authorization header is formed correctly including the signature.
my code is
val storageConnectionString = "DefaultEndpointsProtocol=https;AccountName=xxx;AccountKey=xxx"
val storageAccount: CloudStorageAccount = CloudStorageAccount.parse(storageConnectionString);
val blobClient: CloudBlobClient = storageAccount.createCloudBlobClient();
val container: CloudBlobContainer = blobClient.getContainerReference("imagesvhd");
container.createIfNotExists()

@LirazRom please don't security sensitive items.


Cow: Watch mindatpeace.in

Cow requests the watch of the watch_keyword mindatpeace\.in. See the MS search here and the Stack Exchange search in text, in URLs, and in code.

mindatpeace\.in has been seen in 1 true positive, 0 false positives, and 0 NAAs.

Approved by Mast in Charcoal HQ


Conflicting paths

Hi everyone, hope you’re all good.
Summary
I’m new to Kong and I’m experimenting generating a declarative yaml file for Kong based on an OpenAPI documentation file.
The problem i’m trying to solve occurs when there are overlapping paths. In my case:

/pets/{id}
/pets/{id}/name/{name}

When I make a request for the endpoint 2, Kong proxies the request as it was for endpoint 1. For example, when I make a request to http://<IP_ADDRESS>:8000/pets/1/name/random the backend responds for http://<IP_ADDRESS>:3001/pets/1 instead of http://<IP_ADDRESS>:3001/pets/1/name/random.
I've the following configuration:
_format_version: "2.1"
_transform: true

services:
- name: pets
  url: http://<IP_ADDRESS>:3001/pets
  routes:
  - name: route-3-3
    methods:
    - GET
    paths:
    - /pets/(?<id>\d+)
    plugins:
    - name: request-transformer
      config:
        replace:
          uri: /pets/$(uri_captures["id"])

  - name: route-3-6
    methods:
    - GET
    paths:
    - /pets/(?<id>\d+)/name/(?<name>[^/]*)
    plugins:
    - name: request-transformer
      config:
        replace:
          uri: /pets/$(uri_captures["id"])/name/$(uri_captures["name"])

From the docs: "When proxying with path prefixes, the longest paths get evaluated first. This allow you to define two Routes with two paths: /service and /service/resource, and ensure that the former does not “shadow” the latter". But the only way to go to the endpoint 2 is by removing the endpoint 1 from the configuration.
Another thing I noticed is that if I send a request to http://<IP_ADDRESS>:8000/pets/a/name/john it gets proxied to http://<IP_ADDRESS>:3001/pets/a/name/john despite the regex in the path that only allows digits.
Also, is my approach with the request-transformer plugin correct, or should I be following another approach?
Thank you all in advance!

I guess I skipped a section of the documentation. regex_priority based on the number of path params solved the issue.

hello, can you please tell me in which way you configure kong? I used admin API,k8s crds.


test: Adding web client testing framework

Looks like there is some issue in the process of terminating the http-server, locally it worked fine. But the CI is stuck in that process, we have tried by re-running and the error persisted.
The error:
Stopping test server...
  1) "after all" hook in "{root}"
  2 passing (11m)
  1 failing
  1) "after all" hook in "{root}":
     Error: Timeout of 600000ms exceeded. For async tests and hooks, ensure "done()" is called; if returning a Promise, ensure it resolves.
      at listOnTimeout (node:internal/timers:569:17)
      at processTimers (node:internal/timers:512:7)

Looks like there is some issue in the process of terminating the http-server, locally it worked fine. But the CI is stuck in that process, we have tried by re-running and the error persisted.
The error:
Stopping test server...
  1) "after all" hook in "{root}"
  2 passing (11m)
  1 failing
  1) "after all" hook in "{root}":
     Error: Timeout of 600000ms exceeded. For async tests and hooks, ensure "done()" is called; if returning a Promise, ensure it resolves.
      at listOnTimeout (node:internal/timers:569:17)
      at processTimers (node:internal/timers:512:7)

I've added what I believe was a missing await that hopefully address it...

Not too familiar with some of the components of the test harness, but overall code LGTM! Left some minor comments as well. Additionally, it seems that the new CI job fails with this error:
[!] (plugin rust) Error: Could not load /home/runner/work/miden-client/miden-client/crates/web-client/Cargo.toml (imported by js/wasm.js): info: syncing channel updates for '1.80-x86_64-unknown-linux-gnu'

Not sure what the way to fix it would be (maybe related to available rust versions or targets?), but let me know if I can help.

I've added a new commit that attempts to fix this. Been trying to get a test environment on my local that mirrors the github workflow to avoid repeatedly posting commits for testing, but the replication ability is limited.
The newest commit seems to get past the above quoted issue and runs into others mid-test, but I believe those issues were isolated to my local docker container and not related to the workflow itself.


Add build profile.

This adds a build profile as discussed at rust-lang/rust#48683. See unstable.md for a brief description.

I implemented a unified deps directory, but ran into some problems dealing with backwards compatibility.  I've been trying a few different approaches, but they all have drawbacks.

No backwards compatibility.  This breaks a few tools and tests.  I tried with rustbuild, and it required a few, small changes.  #5758 will need to be fixed first, as there would be no way for integration tests to find executables.  (I counted about 60 crates on crates.io that use current_exe from tests to find exes.)
A symlink from target/debug/deps to ../deps. However, I don't see a way to create directory links on older versions of Windows.
Hard link everything in target/deps/ to target/debug/deps/. However, I believe some scenarios don't support hard links, so this would end up copying everything.
Some hybrid approach where target/deps contains everything, target/debug contains links to final artifacts, and target/debug/deps contains links to tests.  This will still break some tools like rustbuild, but might minimize the fallout of 5758.

Any ideas?

If we break very old Windows I think that's fine, I thought that symlink_dir in the standard library would be good enough for Windows versions that we support? (you already can't do things like run cargo on XP).
I don't actually know any systems that don't support hard links on the same filesystem, but have we hit some in the wild we wanted to handle?
I think breaking rustbuild is fine (especially if we see the breakage coming!).
Overall I think we definitely need to preserve backcompat to ensure that the current patterns for finding a test binary works somewhat (although we have broken this before...). Otherwise it should be fine to ignore older Windows and I think it's fine to assume hard links for perf (although I may be forgetting something critical there).
If we only hard link/copy the final binaries that could mitigate the impact of systems without hard links perhaps and overall reduce the amount of traffic on the filesystem?

break very old Windows

It is fairly recent. Creating symlinks historically required admin permissions until Windows 10 Creators Update (released mid 2017).  The reason you can run on older systems is because
A. I don't think we every try to link directories on Windows.  I can only think of macos with dSYM.
B. Even if it tries to create a link, it will fall back to fs::copy when it fails.

don't support hard links

I believe some network filesystems do not support it.
Sometime soonish, unless you have any other feedback, I'll try out the hybrid approach and see how it goes.

Oh sorry right yeah symlinks won't work but I think that directory junctions are supported much further back on Windows, right? (I forget if that's what symlink_dir does or if hard_link does this in libstd...
Hm network filesystems is a bummer... I think the hybrid approach would be best there though long-term!

:umbrella: The latest upstream changes (presumably #6687) made this pull request unmergeable. Please resolve the merge conflicts.

:umbrella: The latest upstream changes (presumably #6811) made this pull request unmergeable. Please resolve the merge conflicts.

I'm going to close this PR for now.  I'm still interested in pursuing this, but it will take more work than I have time for now.

I'm going to close this PR for now.  I'm still interested in pursuing this, but it will take more work than I have time for now.


clarification targetsoc/minsoc

fix #436
fix #433
depends on https://github.com/evcc-io/evcc/pull/9685

Danke!


Allow running with ++debug ++local

Original issue: https://charm.cs.illinois.edu/redmine/issues/754

For obscure reasons, launching a Charm++ application with each process under the control of a gdb session in an xterm requires that the launching be done through ssh connections, even if they're all to be run on the local machine. There's no reason charmrun shouldn't be able to just fork()/exec() the corresponding bits directly.

Original date: 2015-09-18 21:09:47

I can shed some light on why this was not supported out of the box.
The ++local feature short circuits the rather intricate launch process that writes a script for execution by remote ssh, to instead use fork and execve.
The presence of a script in the former process vastly simplifies certain aspects of modifying the command line.
Modifying the command line for an execve is orders of magnitude more finicky.  For example, there are several ways to get it wrong which will result in crashing your entire X Desktop session.  I can't even begin to explain how annoying it is to debug code that does that.
Ironically, the most annoying part of it is that the first parameter to execve must be a file.  Which means you not only have to get the absolute path for the xterm binary, you have to do so in a cross platform way.  There is no POSIX standard for that. <-- finding a cross platform solution that where we are currently stuck in this implementation.
Furthermore, in order to pass the arguments through to gdb, you can't just prepend gdb to the command line, you have to reformulate them to pass them through the -ex parameter as set args commands, or write them as set args commands in a file which is then passed as an argument to the -x argument.

Original date: 2015-09-18 21:12:18

For $PATH, special-casing Linux and OS X should be enough. Windows is a second-class development citizen anyway.
For gdb, look at the --args flag.

Original date: 2015-09-18 21:21:09

I've got the gdb thing already solved.  That was only mildly annoying. --args is somewhat newer, new enough that its not in the gdb manpage.  Using the older -ex scheme as I expect it will be better supported for now.  Also we have to pass commands through to gdb to support the ++debug-no-pause functionality, so --args isn't enough regardless.
I'll start with a PATH navigation search and we'll see how far that takes us.h

Original date: 2015-09-18 22:22:12

Pushed implementation to gerrit.

Original date: 2015-09-18 22:22:54

Please link here, to make bi-directional navigation easier.

Original date: 2015-11-11 03:05:19

Set status back to Merged so that we can distinguish whether the code was changed in some way, or the fix was elsewhere. Both are non-open states from Redmine's perspective.


Update of sensor.myfitnesspal_tomas is taking over 10 seconds

Underlying scraping API I use is taking a long time updating. Since it is syncronous it make this warning. I will investigate if there is a better way to code this.

Hi there
How often is this component meant to update? After some change in the myfitnesspal app would I see the update right away on this component in HA?
Thanks.

Hi there
How often is this component meant to update? After some change in the myfitnesspal app would I see the update right away on this component in HA?
Thanks.

It is using "pull" to refresh values at the default refresh intervall for sensors. That is currently 30s. It would not be wise to do it more often since it will be a bad way to use the service and could lead to banned accounts.

Hi there
How often is this component meant to update? After some change in the myfitnesspal app would I see the update right away on this component in HA?
Thanks.

It is using "pull" to refresh values at the default refresh intervall for sensors. That is currently 30s. It would not be wise to do it more often since it will be a bad way to use the service and could lead to banned accounts.

Oh right I see. The trouble I am having is when I update myfitnesspal app I don't see the changes on HA. It will only update once and wont update again at all.


Proposal: Fix Registry and Serialize Return Values

Creating this PR to ensure that roRegistry and roRegistrySection function return values which indicate success/failure of registry calls are passed through to maestro function callers and error logging.
I have not updated the unit tests yet. Wanted to verify that this code change proposal is otherwise acceptable before putting more time into it.

 Not sure if that's on the main repo or not?.

 Not sure if that's on the main repo or not?.

all good, the tests were correct!
fixed the return types

thanks!


Ignoring accents :)

Hi!
I'm just reporting an issue with accents :

This is french by the way.
Have a nice day!

Fixed :)


[RuntimeException] when using widget in recyclerview

Using very simple: create list (recyclerview) of images (SubsamplingScaleImageView). All images are loading from remove server (without cache). So, when view state is visible - I try to load image.
All works fine,  but in one case (fast scrolling down and up) I get:
java.lang.RuntimeException: Canvas: trying to use a recycled bitmap android.graphics.Bitmap@1232b229
at android.graphics.Canvas.throwIfCannotDraw(Canvas.java:1225)
at android.view.GLES20Canvas.drawBitmap(GLES20Canvas.java:589)
at com.davemorrissey.labs.subscaleview.SubsamplingScaleImageView.onDraw(SubsamplingScaleImageView.java:1073)

version of lib:
'com.davemorrissey.labs:subsampling-scale-image-view:3.6.0'

I don't think this is a bug with the library. You'd probably get the same kind of error using an ordinary ImageView. Can you change your code to make sure the view is not loaded with an image that's been recycled?


Please add a changelog that links to the release notes

Over time, I've grown accustomed to a CHANGELOG file. It's cool if you want to use GitHub releases, but it's not immediately obvious that this is where the notes are. A plain text file with a link would be sufficient.

Hi @shepmaster, that sounds good to me. PRs accepted ;)


Laravel-echo-server on LB

Can someone suggest how to use Laravel-echo-server on LB. we are unable to use that getting issues.
"Client can not be authenticated, got HTTP status 419"

What is LB?

@skatetdieu
I think he is referring to Load balancer

@itnazeer I wrote an article explaining that here https://t.co/uV98vc8WSj  good reading

I would mark this solved / closed.
There are plenty of resources to search for. And as I have just found out.
https://github.com/tlaverdure/laravel-echo-server/pull/361


Unknown protocol in s23_clnt.c:794

VSCode Version: Code 1.10.2 (8076a19fdcab7e1fc1707952d652f0bb6c6db331, 2017-03-08T14:02:52.799Z)
OS Version: Windows_NT ia32 10.0.14393
Extensions:

Extension
Author
Version

csharp
ms-vscode
1.3.0

Steps to Reproduce:

Start VSCode
Click the button "Update to 1.8.0" (currently C# 1.3.0)

Results with ERROR:
write EPROTO 0:error:140770FC:SSL routines:SSL23_GET_SERVER_HELLO:unknown protocol:c:\jenkins\workspace\electron-win-ia32\vendor\node\deps\openssl\openssl\ssl\s23_clnt.c:794:

I think it is like #14672 - behind a corporate proxy.
We with our sysadmin had checked http.proxy settings, and now we got connect ECONNREFUSED <IP_ADDRESS>:443
This address is being open in a browser with the SSL certificate warning.
Well, if ignore and continue this, we go to https://marketplace.visualstudio.com/ successfully.
On same computer VS 2015 and 2017 have ability to get updates just using the system proxy settings: same for HTTP, HTTPS, FTP, just as 192.168.x.x:3128 set by GPO.
We continue to try different combinations of proxy settings for VS Code specifically...

User Parameters set to
{
    "http.proxy": "http://192.168.x.x:3128",
    "http.proxyStrictSSL": false
}

The browsing of available extensions list works. But no image nor texts for a selected extension. I think no connectivity to some Internet sites VS Code looking. See the attached screenshot (in Russian).

And I repeat: no problems for VS 2017 or browsers to open <IP_ADDRESS>:443 and https://marketplace.visualstudio.com/. Our sysadmin has made these urls available for my computer.

I have found a solution at #22214. But this required to open additionally the *.vsassets.io/ domain in the white list of allowed urls for me on our proxy. It is very bad in the new era of virus downloaders, to require from proxy admins (and CISO!) to add a huge number of new undocumented(!) sites where modern developers drop their code around the Internet!

To browse extension notes and images I was required to open on the proxy:

gallerycdn.vsassets.io
blob.core.windows.net
travis-ci.org and more for every author's favorite badge...


fix static path for windows environment

I made this PR with the help of @myst729.
Using back slash (\) as file separator is how path.join works in Windows environment, which makes loading of static files failed on my windows machine.

In Mac or Linux it should be slash (/), which works.

We think url.resolve is a better approach here.
(The pictures are from @myst729)

Thanks!


[Chats] Chat textbox appears when go back from journey chat

Environment: Android 9, Samsung SM-A530F, Nexus 5 (appetize.io simulator);
Reproducible: always on OS Android 9
Build found: 1.0.89
Preconditions
Use device with OS Android 9
Steps to reproduce

Go to 'Chats' homepage
Tap on any chat
Tap on 'Back' button in the left top corner OR hard 'Back' button

Actual result
Opens 'Chats' homepage and shortly appears chat textbox in the bottom of page

https://user-images.githubusercontent.com/78938450/111458771-82524680-8722-11eb-97d6-d909238376a5.mp4
Expected result
Opens 'Chats' homepage
Comments
Bug doesn't reproduce on Android 10, 11, iOS 12, 13, 14
User story and test case links
User story #22

Bug is fixed


Remove non-inclusive language

Remove non-inclusive language throughout the documentation as recommended by the Inclusive Naming Initiative.
Use-Case
CNCF is among the organizations spearheading the adoption of more inclusive language in code and documentation.
Specification
The KEDA documentation is relatively free of non-inclusive language, but there are places that could be improved. Examples in KEDA:

In concepts/scaling-deployments.md: "This value can be used to easily distinguish this specific trigger and its metrics ..."
The use of "master" (as in "sentinelMaster") in scalers/redis-sentinel-lists.md. This might be impossible to change without changing the Redis scaler as well.)
In deploy.md: "Deploying KEDA with Helm is very simple".

Thanks! Is this something you can contribute?
In terms of master I am afraid we can only change it once Redis has changed to to not confuse end-users more.

Hi, thanks for raising this issue. Unfortunately the Redis case is not something we can fix, as it depends on Redis itself.
I personally don't think the other cases are non-inclusive, there's nothing harmful or offensive in them. If so, we would need to change half of the website:

@tomkerkhove @zroubalik I understand the need to mirror the parameter names used by Redis. In the text, you can reject the term "master" without losing clarity by using, for example, a parenthetical explanation. For example, you could rewrite this:
"- sentinelMaster - The name of the master in Sentinel to get the Redis server address for."
To this:
"- sentinelMaster - The name of the primary (still referred to as the 'master' in Sentinel) to get the Redis server address for."
In place of "master", you can use "primary", "main", "original", "source", "controller" or any other term that most accurately conveys the function of the referent.
I didn't do an exhaustive search for non-inclusive terms, but I didn't find any tier 1 terms outside the Redis scaler doc. Re terms like "easy" and "simple", these terms aren't in the inclusive naming lists, but they are mentioned in the CNCF assessment criteria. As I understand it, the goal is to avoid ableist language, especially if it sounds dismissive or patronizing, like "Adjusting the threshold is a no-brainer; just change the scaleThresh value in the config file."
While I can't categorically agree with you that this particular ableist language is inoffensive, its usage here doesn't seem egregious. I respectfully take issue with "... we would need to change half of the website" as an argument to leave it as-is. There are cost/benefit tradeoffs to any change; this argument is another way of saying that inclusiveness should remain a low priority. Again, CNCF wants to be a leader in adopting more inclusive language in code and documentation.

To that point, the CNCF isn't mandating any of these changes—projects are always free to pick and choose which of the TechDocs analysis' recommendations to implement—but we do include a review of inclusive language as part of the process to help raise awareness.

I don't have concerns if you open a PR with those recommendations. @zroubalik?

Closed in https://github.com/kedacore/keda-docs/pull/1389


Replace Aws4Signer with AwsV4HttpSigner

Description of changes:
The library is currently using the deprecated Aws4Signer. This PR replaces the implementation with AwsV4HttpSigner
Resolves: 121
Pull Request Checklist:

[X] I have added a contribution line at the top of CHANGELOG.md.

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

@dblock i've had a crack at the UPGRADING.md - hopefully that covers everything but lmk if there is anything else I should add

@GeorgeVincentDepop thanks for the PR. I left a few comments, mostly about line wrapping and indentation. Thanks for the heads up @dblock, I was away on holiday, still jet lagged.

Merged, thanks for hanging in here with us @GeorgeVincentDepop. Let's make a release?


[D3D-2585] Adds debug visualisation shadow

Show both target bbox as computed, and light shadow frustum as computed.

Heeded the comment :

moved everything in osgUtils/Debug.js
"createBoundingBoxGeometry" named 'createBoxDebugLineGeometry'
added createFrustrumDebugGeometry: function( projection, dr ) {...}

( the ability to "autoupdate" doesn't work in shadowmap though because matrix are reused/zero'ed elsewhere  )

it's osgUtils/debug.js not Debug, upper case first letter is for class.
Because there is createAxisGeometry, createGridGeometry  in shape it's better to have createBoundingBoxGeometry in shape to be consistent.
I dont want to expose updateBoundingBoxGeometry and updateBoundingBoxGeometryWithPerspectiveFrustum in debug.js . If you need to update the debug element without reference, then add an update methodGeometry function:
var updateFrustrum =  function( args ) {
do your stuff
};
var createDebugFrustrumGeometry = function() {
var geom = shape.createBoundingBoxGeometry();
geom.updateGeometry = updateFrustrum;
}
could be a simple function assigned to the debug geometry or a prototype switch. Probably we can start only with a function assigned to the geometry.
Also the naming is not consistent
createBoxDebugLineGeometry is not consistent with createFrustrumDebugGeometry.
could simply:

createDebugFrustrumGeometry

ok, will do.
Do I rename Shape.js to shape.js then ?
(maybe I could do a pass on all osgjs file to check consistency)

Hey @Kuranes

Do I rename Shape.js to shape.js then ?
(maybe I could do a pass on all osgjs file to check consistency)

That could break a lot of user code. If you plan to do that please send an advice to the list.

will rename all "functions files" to lowercase then

rebased
made the Renaming

(tested everything; found things broken but not by this PR (tutorial arealight and loadmodel.))

fixed renaming and osgUtil mixin

Shouldn't https://github.com/cedricpinson/osgjs/blob/master/sources/osgUtil/GizmoGeometry.js expose too it's internal debug geoms ? ( plan, line, quad, circle geometrY )

added near/far fix for spotlight shadow bugs

renamed Debug to debug in js code.