Scroll listeners can make click events unreliable

Steps to reproduce
Tell us about your environment:
Puppeteer version: 1.12.2
Platform / OS version: Windows 10
URLs: Enterprise Domain so I can't share 😢
Node.js version: v8.12.0
What steps will reproduce the problem?

Be on any page with a significant scroll listener.
await element.click(options).
Click event might not fire, or at least not before a different function runs and moves the scrollbar again.

What is the expected result?
I mean, it's understandable that the click event doesn't fire some time (or, again, just doesn't run in a timely manner), but as things are now, we need some way to be able to do some logic to wait for the page to stabilize between the scroll event and the click event.
For example, using a private property on the element handler can fix this (this is actually what I'm doing in the meantime, while I wait for an alternative):
export default async function safeClick(elHandle = ctx.page, ...args) {
    // an actual private function in the puppeteer api while researching this bug
    await elHandle._scrollIntoViewIfNeeded();
    await myCheckStabilizationFunction();
    await expect(elHandle).toClick(...args);
}

What happens instead?
I have no way to insert stabilization logic between puppeteer attempting to scroll the page and attempting to click the element.

@Aaron-Pool I don't follow - so do you mean that element scrollin might trigger some non-trivial listeners that animate elements and thus clicking fails?
In this case there's nothing much we can help you here. You'll have to scroll element yourself and then wait for the scroll stabilization.
You can avoid using private API though simply with DOM's scrollIntoView:
await page.evaluate(e => e.scrollIntoView({block: 'center', inline: 'center', behavior: 'instant'}), elHandle);

@aslushnikov Your summary is correct.
I was operating under the assumption that puppeteer implemented its own scrollIntoViewIfNeeded with an intersection observer because the scrollIntoViewIfNeeded method implemented by chromium was insufficient. In which case I didn't think I could rely on it, so I was using the private API. That was, more or less, the problem I wanted addressed, perhaps by making that method a part of the public API. Am I misunderstanding the reason the custom _scrollIntoViewIfNeeded was written?

I was operating under the assumption that puppeteer implemented its own scrollIntoViewIfNeeded with an intersection observer because the scrollIntoViewIfNeeded method implemented by chromium was insufficient.

@Aaron-Pool that's accurate. However, chances are high that you don't care about the -IfNeeded part, so I suggested using a non-conditional element.scrollIntoView:
await page.evaluate(e => e.scrollIntoView({block: 'center', inline: 'center', behavior: 'instant'}), elHandle);

@aslushnikov I'm not entirely sure that's true.
I'm writing e2e acceptance test scripts for a web application. I don't so much care about performance, as much as the highest possible reliability and adaptability to changing conditions such as server speed, dom restructuring, implementation changes, etc. To do this I have a wrapper function for all browser interactions that ensures the page is totally stable before attempting the operation, to ensure the operation occurs as expected. But I'm also recording all of these tests so that, if any of the QA engineers have concerns about a false negative or positive, they can watch the test and skip to the relevant portion.
That being said, if the screen is repeatedly jumping around unnecessarily because I called scrollIntoView on every user interaction, it will make it more difficult to understand what's happening.
I understand this isn't really your problem, or anything you're responsible to fix. Just explaining the circumstance that makes manually calling _scrollIntoViewIfNeeded desirable.

That being said, if the screen is repeatedly jumping around unnecessarily because I called scrollIntoView on every user interaction, it will make it more difficult to understand what's happening.

@Aaron-Pool makes perfect sense. I'd steal our implementation then to make sure it doesn't disappear from the private API (there are no plans though).
Let's postpone exposing _scrollIntoViewIfNeeded to public API until there are more requests.


fixes CAB-2633 -

search service observable should be subscribed to in the search page, not in the underlying components

Coverage increased (+0.02%) to 81.229% when pulling ce887d3d7eb0b0ac75e470bc4906a3f7d4aaa586 on feature/CAB-2633 into 851ba7728f147973e21c4382e0be20fa7e67cc81 on develop.


Always getting error

I follow this guide
https://documentation.onesignal.com/docs/react-native-sdk-setup. And after setting up and running the application (real-native run-android), I always get this error.

Could not resolve all files for configuration ':react-native-onesignal:debugCompileClasspath'.
Could not find play-services-base.jar (com.google.android.gms:play-services-base:12.0.1).
Searched in the following locations:
https://dl.google.com/dl/android/maven2/com/google/android/gms/play-services-base/12.0.1/play-services-base-12.0.1.jar

Attaching files
android/build.gradle
// Top-level build file where you can add configuration options common to all sub-projects/modules.

buildscript {
    repositories {
        jcenter()
        google()
    }
    dependencies {
        classpath 'com.android.tools.build:gradle:3.1.0'
        // NOTE: Do not place your application dependencies here; they belong
        // in the individual module build.gradle files
    }
}

allprojects {
    repositories {
        mavenLocal()
        google()
        jcenter()
        maven { url "https://jitpack.io" }
        maven {
            // All of React Native (JS, Obj-C sources, Android binaries) is installed from npm
            url "$rootDir/../node_modules/react-native/android"
        }
    }
}

subprojects {
  project.configurations.all {
     resolutionStrategy.eachDependency { details ->
        if (details.requested.group == 'com.android.support'
              && !details.requested.name.contains('multidex') ) {
           details.useVersion "27.1.0"
        }
     }
  }
}

android/app/build.gradle
buildscript {
    repositories {
        maven { url 'https://plugins.gradle.org/m2/'}
    }
    dependencies {
        classpath 'gradle.plugin.com.onesignal:onesignal-gradle-plugin:[0.10.0, 0.99.99]'
    }
}
apply plugin: 'com.onesignal.androidsdk.onesignal-gradle-plugin'

apply plugin: "com.android.application"

import com.android.build.OutputFile

/**
 * The react.gradle file registers a task for each build variant (e.g. bundleDebugJsAndAssets
 * and bundleReleaseJsAndAssets).
 * These basically call `react-native bundle` with the correct arguments during the Android build
 * cycle. By default, bundleDebugJsAndAssets is skipped, as in debug/dev mode we prefer to load the
 * bundle directly from the development server. Below you can see all the possible configurations
 * and their defaults. If you decide to add a configuration block, make sure to add it before the
 * `apply from: "../../node_modules/react-native/react.gradle"` line.
 *
 * project.ext.react = [
 *   // the name of the generated asset file containing your JS bundle
 *   bundleAssetName: "index.android.bundle",
 *
 *   // the entry file for bundle generation
 *   entryFile: "index.android.js",
 *
 *   // whether to bundle JS and assets in debug mode
 *   bundleInDebug: false,
 *
 *   // whether to bundle JS and assets in release mode
 *   bundleInRelease: true,
 *
 *   // whether to bundle JS and assets in another build variant (if configured).
 *   // See http://tools.android.com/tech-docs/new-build-system/user-guide#TOC-Build-Variants
 *   // The configuration property can be in the following formats
 *   //         'bundleIn${productFlavor}${buildType}'
 *   //         'bundleIn${buildType}'
 *   // bundleInFreeDebug: true,
 *   // bundleInPaidRelease: true,
 *   // bundleInBeta: true,
 *
 *   // whether to disable dev mode in custom build variants (by default only disabled in release)
 *   // for example: to disable dev mode in the staging build type (if configured)
 *   devDisabledInStaging: true,
 *   // The configuration property can be in the following formats
 *   //         'devDisabledIn${productFlavor}${buildType}'
 *   //         'devDisabledIn${buildType}'
 *
 *   // the root of your project, i.e. where "package.json" lives
 *   root: "../../",
 *
 *   // where to put the JS bundle asset in debug mode
 *   jsBundleDirDebug: "$buildDir/intermediates/assets/debug",
 *
 *   // where to put the JS bundle asset in release mode
 *   jsBundleDirRelease: "$buildDir/intermediates/assets/release",
 *
 *   // where to put drawable resources / React Native assets, e.g. the ones you use via
 *   // require('./image.png')), in debug mode
 *   resourcesDirDebug: "$buildDir/intermediates/res/merged/debug",
 *
 *   // where to put drawable resources / React Native assets, e.g. the ones you use via
 *   // require('./image.png')), in release mode
 *   resourcesDirRelease: "$buildDir/intermediates/res/merged/release",
 *
 *   // by default the gradle tasks are skipped if none of the JS files or assets change; this means
 *   // that we don't look at files in android/ or ios/ to determine whether the tasks are up to
 *   // date; if you have any other folders that you want to ignore for performance reasons (gradle
 *   // indexes the entire tree), add them here. Alternatively, if you have JS files in android/
 *   // for example, you might want to remove it from here.
 *   inputExcludes: ["android/**", "ios/**"],
 *
 *   // override which node gets called and with what additional arguments
 *   nodeExecutableAndArgs: ["node"],
 *
 *   // supply additional arguments to the packager
 *   extraPackagerArgs: []
 * ]
 */

project.ext.react = [
    entryFile: "index.js"
]

apply from: "../../node_modules/react-native/react.gradle"

project.ext.vectoricons = [
    iconFontNames: [ 'MaterialIcons.ttf', 'EvilIcons.ttf' ] // Name of the font files you want to copy
]

apply from: "../../node_modules/react-native-vector-icons/fonts.gradle"

/**
 * Set this to true to create two separate APKs instead of one:
 *   - An APK that only works on ARM devices
 *   - An APK that only works on x86 devices
 * The advantage is the size of the APK is reduced by about 4MB.
 * Upload all the APKs to the Play Store and people will download
 * the correct one based on the CPU architecture of their device.
 */
def enableSeparateBuildPerCPUArchitecture = false

/**
 * Run Proguard to shrink the Java bytecode in release builds.
 */
def enableProguardInReleaseBuilds = false

android {
    compileSdkVersion 27
    buildToolsVersion "27.0.3"

    defaultConfig {
        applicationId "com.log"
        minSdkVersion 16
        targetSdkVersion 22
        versionCode 1
        versionName "1.0"
        ndk {
            abiFilters "armeabi-v7a", "x86"
        }
    }
    splits {
        abi {
            reset()
            enable enableSeparateBuildPerCPUArchitecture
            universalApk false  // If true, also generate a universal APK
            include "armeabi-v7a", "x86"
        }
    }
    buildTypes {
        release {
            minifyEnabled enableProguardInReleaseBuilds
            proguardFiles getDefaultProguardFile("proguard-android.txt"), "proguard-rules.pro"
            signingConfig signingConfigs.release
        }
    }
    // applicationVariants are e.g. debug, release
    applicationVariants.all { variant ->
        variant.outputs.each { output ->
            // For each separate APK per architecture, set a unique version code as described here:
            // http://tools.android.com/tech-docs/new-build-system/user-guide/apk-splits
            def versionCodes = ["armeabi-v7a":1, "x86":2]
            def abi = output.getFilter(OutputFile.ABI)
            if (abi != null) {  // null for the universal-debug, universal-release variants
                output.versionCodeOverride =
                        versionCodes.get(abi) * 1048576 + defaultConfig.versionCode
            }
        }
    }
}

dependencies {
    compile project(':react-native-onesignal')
    compile fileTree(dir: "libs", include: ["*.jar"])
    compile "com.android.support:appcompat-v7:27.1.0"
    compile "com.facebook.react:react-native:+"  // From node_modules
}

task copyDownloadableDepsToLibs(type: Copy) {
    from configurations.compile
    into 'libs'
}

@Red967 It looks like your project is trying to download play-services-base-12.0.1.jar instead of play-services-base-12.0.1.aar. Can you let us know all the plugins in your project and their versions.
Can you reproduce the issue in a new project?

@Red967 If possible, can you create new react project reproducing the issue and share it? Some of these build issues are hard to reproduce with just package.json as some other setting may effect the build.

@Red967 Closing due to no response. If you are still having this problem please respond and we'll be happy to reopen + help investigate.

Sorry for not responding. Still have this problem
https://github.com/Red967/onesignaltest

@jkasten2 any updates? Or no solution?


setVolume will get "Uncaught IndexSizeError" when set value below 0

Since there is no way to get the volume, if the value goes below 0, there will be an error.
Uncaught IndexSizeError: Failed to set the 'volume' property on 'HTMLMediaElement': The volume provided (-0.1) is outside the range [0, 1].

Hey @calvintam236 ,
Don't enter a value less than 0 :+1: heh, I'll put some handling in there for that.
You can get the volume from the HTML element itself, but of course it's a floating point rather than the 0-10 range that plyr uses.
document.querySelector(".player").plyr.media.volume would return 0.7 on plyr.io for example.
I'll put some handling in for the out of bounds values.

Pushed a fix for this also improved how the player monitors volume/mute changes. Let me know if there's any problems :+1:

Hey @SamPotts, it seems when you set volume = 10 at setup with v1.1.8, the volume controls shows 0..

I've just pushed some tweaks in 1.1.9 but check your local storage value. The value of the volume is set in local storage (it's an option, defaulted to on) so when a user comes back, they get the same value. If you muted and refreshed, this would be 0.
Run this in your console:
window.localStorage.plyr_volume
If it returns 0, then that's why.

hey @SamPotts I don't think the issue was fixed. Try adding "volume: 10," at docs.js and visit your demo. The volume in the player shows at the bottom (but not mute). Get media.volume value is 1 using console.log.

Check 1.1.10 :+1: I think I've nailed it.

@SamPotts Fixed! Thank you! :+1:

No problem. I'll look at your suggestion for changing track by API asap too.


Add MathDial

Hi,
This PR adds the MathDial (with the downloader, preparer, and mapper). All tests passed successfully.
Note: Since the data format expects only the roles of user or assistant, I've replaced the teacher role (human annotator) with user, and the student role (ChatGPT) with assistant in the prepare function. But, since this is a tutoring dataset that aims to create automatic dialogue tutors, I think the reverse makes more sense.
Tell me if you agree and I'll make the required changes.

Ready to merge.


Bump elixir_sense and use ElixirSense.references/3

Now that https://github.com/elixir-lsp/elixir_sense/issues/42 is fixed (via https://github.com/elixir-lsp/elixir_sense/pull/61) and umbrella support is added via https://github.com/elixir-lsp/elixir_sense/pull/46 we no longer need to maintain a separate implementation of ElixirSense.references/3 and can instead use the implementation provided by ElixirSense. This is good because now we're using less of the private internals of ElixirSense.
Fixes #68
Fixes #39

Yes, we can. Sorry for the confusion.

On 6 Dec 2019, at 06:54, Jason Axelson<EMAIL_ADDRESS>wrote:

@axelson commented on this pull request.
In apps/language_server/lib/language_server/providers/references.ex:

 %{

 "uri" => SourceFile.path_to_uri(file),

 "uri" => SourceFile.path_to_uri(reference.uri),

Yeah :current_buffer is the case that we really need. Where :current_buffer means the reference was found in the text that was passed in.
Based on your "Edit" are you saying that we can make an assumption? (or perhaps I'm reading that incorrectly)
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub, or unsubscribe.

I don’t have an example right now but I remember seeing it somewhere. It could have been with builtin erlang types.

On 6 Dec 2019, at 18:23, Jason Axelson<EMAIL_ADDRESS>wrote:

@axelson commented on this pull request.
In apps/language_server/lib/language_server/providers/references.ex:

 %{

 "uri" => SourceFile.path_to_uri(file),

 "uri" => SourceFile.path_to_uri(reference.uri),

@lukaszsamson do you have an example that would generate a :nofile response? I've tried with a macro generated function but I just get back an empty list from ElixirSense.references/3 when hovering over the macro_a_func() call with these modules:
defmodule ElixirLS.Test.MacroA do
defmacro using(_) do
quote do
def macro_a_func do
:ok
end
end
end
end
defmodule ElixirLS.Test.UsesMacroA do
use ElixirLS.Test.MacroA
def my_fun do
macro_a_func()
end
def my_other_fun do
macro_a_func()
end
end
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub, or unsubscribe.

Haven't had any luck trying to trigger that case with builtin erlang types, but finished up the mapping code to handle nil as a reference to the current file. If you're able to find any cases that the current code doesn't handle that would be great.

@axelson I also tried with no luck. I must have seen it somewhere deeper in the internals of ElixirSense.references. It looks like we dont have to worry about :nofile here. Let's get this merged.

Okay, that makes sense. But I'm not ready to merge this yet because I'm not occasionally getting runaway memory usage in ElixirLS that I believe may be related/triggered by the ElixirSense updates. When it happens I see my OS memory usage grow from 2GB to 8GB plus 4GB swap (and it goes back down to 2GB when I kill ElixirLS). Haven't had a chance to track it down further yet.

Okay, this is what my runaway memory usage looks like in observer:

But it doesn't appear to be a single process using all of the memory (although I'm a little suspicious of this chart):

@axelson Unfortunately this does not help much. What do System and Memory allocators tabs show? Is it binaries, atoms or sth else?. Under what kind of workload are you experiencing this?
I experienced something similar when developing ElixirSense under vs code with elixir-ls plugin. Elixir-ls was compiling modules ElixirSense modules while I was editing & saving them and started calling them (it seemed they were shadowing ElixirSense modules from deps of elixir-ls). I ended up disabling the plugin for ElixirSense and elixir-ls projects. I haven't noticed anything similar happening on other projects.

@lukaszsamson Okay, was finally able to capture a stacktrace before my system became totally unresponsive. Filed the details in https://github.com/elixir-lsp/elixir_sense/issues/67
And yes developing ElixirLS or ElixirSense with elixir-ls is a bit of a pain because the modules you are editing will immediately be loaded and start to run. It kind of happens on other projects but because those modules aren't used by ElixirLS or ElixirSense there is no real effect (except for the jason dependency).

@axelson Great job finding the root root cause. Could you please try the fix from latest master?

Thanks for looking into it. I'm now running the latest version and if I don't encounter any other issues will get this merged down shortly!

Okay, this has been working well for me. Merging!


Plot blocks in verde.BlockReduce

verde.BlockReduce divide the data region into blocks. I want to visualize the blocks at the same time as my data. Is there a simple way to do this?
Thanks

Hi @MGomezN! Good question.
Sadly there isn't a quick and easy method to get the blocks out of verde.BlockReduce since (1) the blocks are defined when calling the filter() and for each particular dataset, and (2) the blocks aren't actually defined, we use a k-d tree to divide the data points instead (Computerphile has a nice video to know more about k-d trees:  https://www.youtube.com/watch?v=BK5x7IUTIyU)
But, we can define another verde.BlockReduce instance with the same arguments, but with center_coordiantes=True.
Then, the output of the filter() method contains the coordinates of the center of each block. We can use them to plot the blocks:
import pyproj
import numpy as np
import pandas as pd
import verde as vd
import ensaio
import matplotlib.pyplot as plt
from matplotlib.patches import Rectangle

# Downlad sample data
fname = ensaio.fetch_southern_africa_gravity(version=1)
data = pd.read_csv(fname)
data

# Project the data
projection = pyproj.Proj(proj="merc", lat_ts=data.latitude.mean())
easting, northing = projection(data.longitude.values, data.latitude.values)

data = data.assign(easting=easting, northing=northing)
data

# Define a BlockReduce instance, specify center_coordinates=True
spacing = 300e3
reducer = vd.BlockReduce(np.median, spacing=spacing, center_coordinates=True)

# Filter the data and get the coordinates of the center of the blocks
blocks, _ = reducer.filter((data.easting, data.northing), data.gravity_mgal)

# Get the actual spacing of the blocks
easting, northing = np.unique(blocks[0]), np.unique(blocks[1])
d_easting, d_northing = easting[1] - easting[0], northing[1] - northing[0]

print(d_easting, d_northing)

# Plot the data points along with the blocks
plt.scatter(data.easting, data.northing, marker=".")

for easting, northing in zip(blocks[0], blocks[1]):
    rectangle = Rectangle(
        (easting - d_easting / 2, northing - d_northing / 2),
        width=d_easting,
        height=d_northing,
        linewidth=2,
        color="purple",
        fill=False,
    )
    plt.gca().add_patch(rectangle)

plt.gca().set_aspect("equal")
plt.show()

Hope it's useful!

Yes, it was! I took your suggestion and adapted it to my data :)
Thank you for your time


EagleEye load more shows the same content

crowd.dev edition
Cloud (hosted)
Version
No response
What happened?
I searched for a few terms in EagleEye and had 100+ results found. I got to the bottom of the list and clicked the load more button and the page was refreshed and showed the same results again.
Command / Request
The load more shows the next batch of results

Relevant log output
No response

Hi 👋🏼! Thanks for raising this. There is indeed a bug with pagination. We will fix this as soon as possible and report back!

Thanks @joanreyero! Loving all the great comms from crowd.dev

@cayden-uw this should be fixed now 😄 You might need to refresh the page. Thanks again for raising the issue!


gdrdrv: fix use-after-free of variable mr in case of error

This used to crash the kernel when something went wrong. Maybe the memset should be done before freeing the object, but anyway I'm not sure why this should be done.

@daniel-k I'd rather move the memset() before kfree(). would you be able to refactor your change?

Sorry for the delay, I somehow missed your first mail. I have now moved the memset before kfree and force-pushed, see 37a2e2f.
Btw: I also added CMake support over here. If you're interested, I can create a PR =)

merged
@daniel-k thank you

@daniel-k I would really appreciate if you could contact me directly at<EMAIL_ADDRESS>


Incorrect Unicode JSON encoding

The JSON output of /messages/:id.json is mangling all UTF-8 characters into \ufffd\ufffd.
In the web application message['source'].encoding is set to 'ASCII-8BIT', likely reflecting the Content-Transfer-Encoding, but breaking .to_json
I don't do Ruby so I wouldn't know what a proper solution would be, but I worked around this by doing the following before message.merge(
message['source'].force_encoding('UTF-8')

Raw email:
From: Testing<EMAIL_ADDRESS>To<EMAIL_ADDRESS>Date: Mon, 18 Aug 2014 17:51:26 +0200
Message-ID<EMAIL_ADDRESS>Subject: =?UTF-8?B?UsOka3Ntw7ZyZ8OlcyE=?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

Hällö tästing räksmörgås!

JSON output:
{
  "id":1,
  "sender":"",
  "recipients":[""],
  "subject":"R\u00e4ksm\u00f6rg\u00e5s!",
  "source":"From: Testing \nTo<EMAIL_ADDRESS>Mon, 18 Aug 2014 17:51:26 +0200\nMessage-ID<EMAIL_ADDRESS>=?UTF-8?B?UsOka3Ntw7ZyZ8OlcyE=?=\nMIME-Version: 1.0\nContent-Type: text/plain; charset=UTF-8\nContent-Transfer-Encoding: 8bit\n\nH\ufffd\ufffdll\ufffd\ufffd t\ufffd\ufffdsting r\ufffd\ufffdksm\ufffd\ufffdrg\ufffd\ufffds!\n\n\n\n",
  "size":"348",
  "type":"text/plain",
  "created_at":"2014-08-18T15:51:26+00:00",
  "formats":["source","plain"],
  "attachments":[]
}

(Also sender and recipients is empty for some reason)

SMTP doesn't natively support UTF-8 over the wire. This message, if transmitted raw, doesn't actually conform to the protocol. Some servers support an SMTP UTF-8 extension, but this must be negotiated with EHLO and mailcatcher doesn't support it.
Instead, your mail client should be encoding your message body with  base64 or similar instead of transferring in straight 8-bit. I suspect the body is actually being munged on read then causing transcoding errors on jsonification. For me, this throws an exception at read time. (Encodings in ruby are awful at the best of times.)
If I send your raw email body with catchmail then the mail gem picks up the content and correctly encodes it as base64 and it comes out as expected:
{
  "id":3,
<EMAIL_ADDRESS><EMAIL_ADDRESS>  "subject":"Räksmörgås!",
  "source":"Date: Mon, 18 Aug 2014 17:51:26 +0200\r\nFrom: Testing<EMAIL_ADDRESS><EMAIL_ADDRESS><EMAIL_ADDRESS>=?UTF-8?Q?R=C3=A4ksm=C3=B6rg=C3=A5s!?=\r\nMime-Version: 1.0\r\nContent-Type: text/plain;\r\n charset=UTF-8\r\nContent-Transfer-Encoding: base64\r\n\r\nSMOkbGzDtiB0w6RzdGluZyByw6Rrc23DtnJnw6VzIQo=\r\n",
  "size":"368",
  "type":"text/plain",
  "created_at":"2015-01-17T05:44:07.000+00:00",
  "formats":["source","plain"],
  "attachments":[]
}


Execute and remote_file resource alternate identity support

was this a PR that you busted up into three, so this one should be closed?

This was completed in https://github.com/chef/chef/pull/5764 and https://github.com/chef/chef/pull/5832.

Thank you @btm !


Updating metadata

Updated metadata of MNT token

you are looking for https://github.com/cardano-foundation/cardano-token-registry ?


[5.8] Initial Requirement 9 Lofi-Prototyping

Description: Prototyping based on Initial Requirement 9.
Goals: Create a Prototype based on the Requirement.
Success or Completion Criteria: Prototype Figma.
Allocated Time: 2 days
Start Date: 31/08/23
End Date: 01/09/23
Main Task :  Create lo-fi prototypes/wireframes based for the initial requirements


Disable back button and gesture only in room

Description
Enable back button for preview screen and disable back gesture for room screen in fishjam-chat.
Motivation and Context
If I make a mistake in credentials for joining room I would like to be able to close the screen and fix it. Currently only the back gesture wasn't disabled and could be used to go back.
Additionally, I could use the gesture to go back from the room screen instead of having to tap end call button.
Types of changes

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

Checklist:

[x] My code follows the code style of this project.
[ ] My change requires a change to the documentation.
[ ] I have updated the documentation accordingly.

I don't think that's the case as joinRoom is only called after tapping Join room button in preview screen. And going to the preview screen doesn't do much besides setting connection error to null and passing some parameters:
setConnectionError(null);
navigation.navigate('Preview', {
  fishjamUrl: fishjamUrl.trim(),
  participantToken: participantToken.trim(),
});

Unfortunately, the API is not clear here. PreviewScreen calls prepareCamera which creates a local video track. This track is not removed until leaveRoom is called. This was the reason for this PR: https://github.com/fishjam-cloud/mobile-client-sdk/pull/121

Ah, I see. In that case I added calling leaveRoom when the preview screen is supposed to close.


Specify Tag Filter Policies as Code

Is there a way to specify image tag filter policies in the control repository? I've only been able to find how to completely ignore a deployment  through an annotation. If it is, then I'm happy to try and put a PR together to update some documentation after I figure out how to use it.
If it's not already a feature, the ability specify the equivalent of fluxctl policy --controller=default:deployment/helloworld --tag-all='prod-*' in the git repository that creates deployment/helloworld would be a welcome addition to an already great tool.

Here is an example with regex, sem ver and glob tag filters:
apiVersion: apps/v1
kind: Deployment
metadata:
  name: app-dev
  annotations:
    flux.weave.works/automated: "true"
    flux.weave.works/tag.init: regex:^1.*
    flux.weave.works/tag.main: semver:~1.2
    flux.weave.works/tag.sidecar: glob:dev-*
spec:
  template:
    spec:
      initContainers:
      - name: init
        image: busybox:1.25
      containers:
      - name: main
        image: quay.io/stefanprodan/podinfo:1.2.0
      - name: sidecar
        image: quay.io/stefanprodan/podinfo:dev-kb9lm91e

Thanks for the help - I've tried to capture this in #1412, though I'm sure it'll need a little editing before it's ready to merge.


fix: LspStop should be only stop the current buffer servers by default

Fix #1781

This broke stopping clients that were manually started with :LspStart but whose filetypes don't match the current buffer.

what is mean?  provide reproduce your issue step

:LspStart foo works, even if foo doesn't list the current buffers filetype in its config. But then :LspStop foo won't stop the client.
The following example doesn't make much sense, but just for you to try out:
vim test.md
:LspStart sumneko_lua
:LspStop 1 (sumneko_lua)


Convert to Relay Modern (but not really)

Lays the groundwork for migrating to React Modern. From the conversion playbook, this switches to the dev version of react-relay and converts existing imports to react-relay/classic. The only gnarly piece is there's an import within react-router-relay outside our control, so I forked it and released a version which uses the classic import.
I'll keep this up to date until relay 1.0.0 final is released, then we can switch. Then comes the hard part: updating to use relay compat, adding a query renderer, ripping out react-router-relay, then switching to relay modern proper.
Things to check:

[x] pipeline pages loads in dynamically OK
[x] go to agents page, refresh, then go to pipelines page
[x] make sure teams sections work (create mutations, etc)
[x] make sure relay preloading still works (go to agents page and keep an eye on XHR requests)
[x] add a "sleep 5" to our backend internal graphql endpoint and double check stuffs

I've had a pretty good poke around after the upgrade, checked all the things in @keithpitt's list, and all seems well. Maybe good to go?

You folks want to have a play as well and make sure it's all working?


Add support for testing that a result-set has no duplicated rows

Currently, you need to use a trick to check if a result-set has some duplicated rows or not. It should be easier and the result should be user-friendly in case of failure.

Syntax:
<assert>

</assert>

Beta available at https://ci.appveyor.com/project/Seddryck/nbi/build/1.16.0-beta.64.build.58


Parallel runner causes duplicate GET, POST, DELETE requests to happen

When using the parallel test runner, multiple POST's get executed. The code below uses the Post Test Server V2 to submit a POST to and you can see that 2 posts are submitted.
Note the test runner is NOT using the @RunWith(Karate.class) annotation and using the junit:4.12 transient dependency from karate-junit4:0.9.3
Karate v0.9.3
Feature file:
    * def REQUEST = {type: 'test-type', name: 'test-name'}
    Given url 'https://ptsv2.com/t/paowv-1563551220/post'
    And request REQUEST
    When method POST
    Then status 200

Parallel Test Runner file:
import static org.junit.Assert.assertTrue;
import com.intuit.karate.Results;
import com.intuit.karate.Runner;
import org.junit.Test;

public class ApiTest {
    @Test
    public void testParallel() {
        Results results = Runner.parallel(getClass(), 5, "target/surefire-reports");
        assertTrue(results.getErrorMessages(), results.getFailCount() == 0);
    }
}

sorry I insist that you submit a full working example, there are reasons: https://github.com/intuit/karate/wiki/How-to-Submit-an-Issue

@ptrthomas I wish you would reconsider this issue. I feel that I have provided you everything needed to demonstrate the behavior.

@kendall-schmidt-sp I wish you would read and understand the link above.
that said, it is quite likely to be this issue: #861 - so try 0.9.5.RC1 and see if that works

@ptrthomas I did read and do understand the link. IMHO I feel it is heavy handed in some cases. I do understand that projects are prone to get poor bug reports - i.e. little to no details on how to reproduce the issue or they simply come across as a "complaint". I don't feel that I've done that.
I will take a look at #861 and give 0.9.5.RC1 a try and let you know if works. I appreciate this info.

@kendall-schmidt-sp I'm sorry you feel that way because I thought "why a working project is needed" was very clear. anyway it is up to you how you want to proceed


"Dependency on Native Libraries" not working?

Prerequisites

[X] Write a descriptive title.
[X] Make sure you are able to repro it on the latest released version
[X] Search the existing issues.
[X] Refer to the FAQ.
[X] Refer to Differences between Windows PowerShell 5.1 and PowerShell.

Steps to reproduce
I don't understand how to use this or it doesn't work?
https://learn.microsoft.com/en-us/powershell/scripting/dev-cross-plat/writing-portable-modules?view=powershell-7.3#dependency-on-native-libraries
Example module https://github.com/ili101/DependencyonNativeLibraries/tree/master/TestDependencies
Using manifest "RequiredAssemblies" or Add-Type in psm1 to load the dll then using the assembly by executing Test-Dependencies results in error:
"Unable to load shared library 'SQLite.Interop.dll' or one of its dependencies." ... "No such file or directory"
When copying the the OS specific dll file to the same folder it works in Windows, Linux and macOS.
So why is this auto detecting feature of PS 7 not working here?
Expected behavior
The correct dependency native dll is loaded.

Actual behavior
It looks for the dependency native dll in the same folder as the main dll and fail to load.
On windows it also work if the dependent dll placed in "x64" folder.

You can see all OSs vs file location results in the GitHub Action https://github.com/ili101/DependencyonNativeLibraries/actions/runs/4328219121
Error details
"Exception calling ".ctor" with "1" argument(s): "Unable to load shared library 'SQLite.Interop.dll' or one of its dependencies. In order to help diagnose loading problems, consider setting the LD_DEBUG environment variable: libSQLite.Interop.dll: cannot open shared object file: No such file or directory""

Environment data
Dlls were generated by https://github.com/ili101/DependencyonNativeLibraries/tree/master/HelloWorld
GitHub Actions uses:
PSVersion             : 7.2.9

Also tested on:
Name                           Value
----                           -----
PSVersion                      7.3.3
PSEdition                      Core
GitCommitId                    7.3.3
OS                             Microsoft Windows 10.0.22621
Platform                       Win32NT
PSCompatibleVersions           {1.0, 2.0, 3.0, 4.0…}
PSRemotingProtocolVersion      2.3
SerializationVersion           <IP_ADDRESS>
WSManStackVersion              3.0

Visuals
No response

What platform are you running this on? The error message says libSQLite.Interop.dll which does not look like Windows
libSQLite.Interop.dll: cannot open shared object file: No such file or directory

If this is Linux, have you tried adding the directory to LD_LIBRARY_PATH environment variable?

It seems 'SQLite.Interop.dll' is not a real native library. On Linux it should have .so extension, on MacOS .dylib.

It seems 'SQLite.Interop.dll' is not a real native library. On Linux it should have .so extension, on MacOS .dylib.

That doesn't matter on Linux or MacOS, it is more of a convention at the linking stage. If the library is the first one being loaded with dlopen it just trusts whatever name it is given, for dependencies, the names are in the NEEDED ELF records.

@rhubarb-geek-nz If you are interesting how this work in PowerShell you can see
https://github.com/PowerShell/PowerShell/blob/476af582d56b25913d1ff9dc8057e1a484f814a9/src/System.Management.Automation/CoreCLR/CorePsAssemblyLoadContext.cs#L239-L246

My hello world example for SQLite, this just uses dotnet. System.Data.SQLite.dll has the dependency on SQLite.Interop.dll
Data in a database
$ sqlite3 test.db
SQLite version 3.34.1 2021-01-20 14:10:07
Enter ".help" for usage hints.
sqlite> select * from MESSAGES;
Hello World

Then using native SQLite.Interop.dll
$ dotnet bin/Release/net6.0/test.dll
Hello World
$ find bin/ -type f
bin/Release/net6.0/System.Data.SQLite.dll
bin/Release/net6.0/test.pdb
bin/Release/net6.0/test.runtimeconfig.json
bin/Release/net6.0/test
bin/Release/net6.0/test.deps.json
bin/Release/net6.0/runtimes/debian.11-arm64/native/SQLite.Interop.dll
bin/Release/net6.0/test.dll
$ grep debian.11-arm64 bin/Release/net6.0/*.json
bin/Release/net6.0/test.deps.json:          "runtimes/debian.11-arm64/native/SQLite.Interop.dll": {
bin/Release/net6.0/test.deps.json:            "rid": "debian.11-arm64",

This looks like how it is supposed to work
Writing Portable Modules

With PowerShell 7, native binaries to load are searched in sub-folders within the managed library's location following a subset of the .NET RID Catalog notation.

This is on Windows with Procmon

I can try to see how to use "strace" on Linux in a few hours when I come back.
But even on Windows the tested subfolders name are not the ones that are mentioned in the PS Document

Is it looking in subdirectories along the PATH using both the RID architecture name and the contents of the PROCESSOR_ARCHITECTURE environment variable?
If so that is rather unfortunate because unless the operating system is included it can't tell the difference between a native module for Windows or Linux, unless the dll/so/dylib extensions are used to discriminate.

I have made a very simple SQLite module to test the native libraries at rhubarb-geek-nz/SQLiteConnection.
I have tried many things but I can't get the native library loading unless it is in the same directory as System.Data.SQLite.dll.

The annotation used in the SQLite source is
[DllImport("SQLite.Interop.dll", CallingConvention = CallingConvention.Cdecl)]

It seems the issue is specific the library. You could look in debugger. Also you could try to remove the dll extension in the DllImport and make and try custom build.

It happily loads the library when it is in one of the places that it looks. The issue is it never looks for the library in a subdirectory of the modules directory with RID or processor architecture. It tries all combinations of with lib prefix and .so suffix. But never looks in a subdirectory called linux-arm64 or debian.11-arm64.
     | Unable to load shared library 'SQLite.Interop.dll' or one of its dependencies. In order to help diagnose loading problems, consider using a tool like
     | strace. If you're using glibc, consider setting the LD_DEBUG environment variable:  /opt/microsoft/powershell/7/SQLite.Interop.dll.so: cannot open shared
     | object file: No such file or directory /home/bythesea/sqlite/powershell/SQLiteConnection/bin/Release/netstandard2.0/SQLite.Interop.dll.so:
     | cannot open shared object file: No such file or directory /opt/microsoft/powershell/7/libSQLite.Interop.dll.so: cannot open shared object file: No such
     | file or directory /home/bythesea/sqlite/powershell/SQLiteConnection/bin/Release/netstandard2.0/libSQLite.Interop.dll.so: cannot open shared
     | object file: No such file or directory /opt/microsoft/powershell/7/SQLite.Interop.dll: cannot open shared object file: No such file or directory
     | /home/bythesea/sqlite/powershell/SQLiteConnection/bin/Release/netstandard2.0/SQLite.Interop.dll: cannot open shared object file: No such file or
     | directory /opt/microsoft/powershell/7/libSQLite.Interop.dll: cannot open shared object file: No such file or directory
     | /home/bythesea/sqlite/powershell/SQLiteConnection/bin/Release/netstandard2.0/libSQLite.Interop.dll: cannot open shared object file: No such file

ili@ILI-Home:~$ strace -e trace=file -p 25497 -f 2>&1 | grep 'Interop\|TestDependencies\|linux-x64'
[pid 25523] stat("/home/ili/git/DependencyonNativeLibraries/TestDependencies", {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
[pid 25523] lstat("/home/ili/git/DependencyonNativeLibraries/TestDependencies", {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
[pid 25523] lstat("/home/ili/git/DependencyonNativeLibraries/TestDependencies", {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
[pid 25523] stat("/home/ili/git/DependencyonNativeLibraries/TestDependencies", {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
[pid 25523] stat("/home/ili/git/DependencyonNativeLibraries/TestDependencies", {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
[pid 25523] openat(AT_FDCWD, "/home/ili/git/DependencyonNativeLibraries/TestDependencies", O_RDONLY|O_NONBLOCK|O_CLOEXEC|O_DIRECTORY) = 151
[pid 25523] lstat("/home/ili/git/DependencyonNativeLibraries/TestDependencies/TestDependencies.psd1", {st_mode=S_IFREG|0644, st_size=4061, ...}) = 0
[pid 25523] lstat("/home/ili/git/DependencyonNativeLibraries/TestDependencies/TestDependencies.psd1", {st_mode=S_IFREG|0644, st_size=4061, ...}) = 0
[pid 25523] openat(AT_FDCWD, "/home/ili/git/DependencyonNativeLibraries/TestDependencies/TestDependencies.psd1", O_RDONLY|O_CLOEXEC) = 151
[pid 25523] stat("/home/ili/git/DependencyonNativeLibraries/TestDependencies/TestDependencies.psm1", {st_mode=S_IFREG|0644, st_size=420, ...}) = 0
[pid 25523] lstat("/home/ili/git/DependencyonNativeLibraries/TestDependencies/TestDependencies.psm1", {st_mode=S_IFREG|0644, st_size=420, ...}) = 0
[pid 25523] stat("/home/ili/git/DependencyonNativeLibraries/TestDependencies/System.Data.SQLite.dll", {st_mode=S_IFREG|0755, st_size=408248, ...}) = 0
[pid 25523] lstat("/home/ili/git/DependencyonNativeLibraries/TestDependencies/System.Data.SQLite.dll", {st_mode=S_IFREG|0755, st_size=408248, ...}) = 0
[pid 25523] readlink("/home/ili/git/DependencyonNativeLibraries/TestDependencies", 0x7f80067f8410, 1023) = -1 EINVAL (Invalid argument)
[pid 25523] stat("/home/ili/git/DependencyonNativeLibraries/TestDependencies/System.Data.SQLite.dll", {st_mode=S_IFREG|0755, st_size=408248, ...}) = 0
[pid 25523] openat(AT_FDCWD, "/home/ili/git/DependencyonNativeLibraries/TestDependencies/System.Data.SQLite.dll", O_RDONLY) = 151
[pid 25523] lstat("/home/ili/git/DependencyonNativeLibraries/TestDependencies/PSGetModuleInfo.xml", 0x7f80067f97c0) = -1 ENOENT (No such file or directory)
[pid 25523] stat("/home/ili/git/DependencyonNativeLibraries/TestDependencies/TestDependencies.psm1", {st_mode=S_IFREG|0644, st_size=420, ...}) = 0
[pid 25523] lstat("/home/ili/git/DependencyonNativeLibraries/TestDependencies/TestDependencies.psm1", {st_mode=S_IFREG|0644, st_size=420, ...}) = 0
[pid 25523] lstat("/home/ili/git/DependencyonNativeLibraries/TestDependencies/TestDependencies.psm1", {st_mode=S_IFREG|0644, st_size=420, ...}) = 0
[pid 25523] openat(AT_FDCWD, "/home/ili/git/DependencyonNativeLibraries/TestDependencies/TestDependencies.psm1", O_RDONLY|O_CLOEXEC) = 153
[pid 25523] lstat("/home/ili/git/DependencyonNativeLibraries/TestDependencies/TestDependencies.psm1", {st_mode=S_IFREG|0644, st_size=420, ...}) = 0
[pid 25523] lstat("/home/ili/git/DependencyonNativeLibraries/TestDependencies/System.Data.SQLite.dll", {st_mode=S_IFREG|0755, st_size=408248, ...}) = 0
[pid 25523] lstat("/home/ili/git/DependencyonNativeLibraries/TestDependencies/System.Data.SQLite.dll.config", 0x7f80067f9690) = -1 ENOENT (No such file or directory)
[pid 25523] lstat("/home/ili/git/DependencyonNativeLibraries/TestDependencies/System.Data.SQLite.dll.altconfig", 0x7f80067f9690) = -1 ENOENT (No such file or directory)
[pid 25523] lstat("/home/ili/git/DependencyonNativeLibraries/TestDependencies/System.Data.SQLite.dll.config", 0x7f80067f97b0) = -1 ENOENT (No such file or directory)
[pid 25523] lstat("/home/ili/git/DependencyonNativeLibraries/TestDependencies/System.Data.SQLite.dll.altconfig", 0x7f80067f97b0) = -1 ENOENT (No such file or directory)
[pid 25523] lstat("/home/ili/git/DependencyonNativeLibraries/TestDependencies/System.Data.SQLite.dll", {st_mode=S_IFREG|0755, st_size=408248, ...}) = 0
[pid 25523] lstat("/home/ili/git/DependencyonNativeLibraries/TestDependencies/System.Data.SQLite.dll.config", 0x7f80067f9760) = -1 ENOENT (No such file or directory)
[pid 25523] lstat("/home/ili/git/DependencyonNativeLibraries/TestDependencies/System.Data.SQLite.dll.altconfig", 0x7f80067f9760) = -1 ENOENT (No such file or directory)
[pid 25523] stat("/home/ili/git/DependencyonNativeLibraries/TestDependencies/x86", 0x7f80067f9688) = -1 ENOENT (No such file or directory)
[pid 25523] stat("/home/ili/git/DependencyonNativeLibraries/TestDependencies/Win32", 0x7f80067f9688) = -1 ENOENT (No such file or directory)
[pid 25523] stat("/home/ili/git/DependencyonNativeLibraries/TestDependencies/x86_64", 0x7f80067f9688) = -1 ENOENT (No such file or directory)
[pid 25523] stat("/home/ili/git/DependencyonNativeLibraries/TestDependencies/x64", 0x7f80067f9688) = -1 ENOENT (No such file or directory)
[pid 25523] stat("/home/ili/git/DependencyonNativeLibraries/TestDependencies/AMD64", 0x7f80067f9688) = -1 ENOENT (No such file or directory)
[pid 25523] stat("/home/ili/git/DependencyonNativeLibraries/TestDependencies/x64", 0x7f80067f9688) = -1 ENOENT (No such file or directory)
[pid 25523] stat("/home/ili/git/DependencyonNativeLibraries/TestDependencies/IA64", 0x7f80067f9688) = -1 ENOENT (No such file or directory)
[pid 25523] stat("/home/ili/git/DependencyonNativeLibraries/TestDependencies/Itanium", 0x7f80067f9688) = -1 ENOENT (No such file or directory)
[pid 25523] stat("/home/ili/git/DependencyonNativeLibraries/TestDependencies/ARM", 0x7f80067f9688) = -1 ENOENT (No such file or directory)
[pid 25523] stat("/home/ili/git/DependencyonNativeLibraries/TestDependencies/WinCE", 0x7f80067f9688) = -1 ENOENT (No such file or directory)
[pid 25523] openat(AT_FDCWD, "/home/ili/git/DependencyonNativeLibraries/TestDependencies/libc.so", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
[pid 25523] openat(AT_FDCWD, "/home/ili/git/DependencyonNativeLibraries/TestDependencies/liblibc.so", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
[pid 25523] openat(AT_FDCWD, "/home/ili/git/DependencyonNativeLibraries/TestDependencies/libc", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
[pid 25523] lstat("/home/ili/git/DependencyonNativeLibraries/TestDependencies/x86_64/SQLite.Interop.dll", 0x7f80067f9850) = -1 ENOENT (No such file or directory)
[pid 25523] lstat("/home/ili/git/DependencyonNativeLibraries/TestDependencies/x64/SQLite.Interop.dll", 0x7f80067f9850) = -1 ENOENT (No such file or directory)
[pid 25523] lstat("/opt/microsoft/powershell/7/x86_64/SQLite.Interop.dll", 0x7f80067f9850) = -1 ENOENT (No such file or directory)
[pid 25523] lstat("/opt/microsoft/powershell/7/x64/SQLite.Interop.dll", 0x7f80067f9850) = -1 ENOENT (No such file or directory)
[pid 25523] lstat("/opt/microsoft/powershell/7/SQLite.Interop.dll", 0x7f80067f9860) = -1 ENOENT (No such file or directory)
[pid 25523] lstat("/opt/microsoft/powershell/7/x86_64/SQLite.Interop.dll", 0x7f80067f9860) = -1 ENOENT (No such file or directory)
[pid 25523] lstat("/opt/microsoft/powershell/7/x64/SQLite.Interop.dll", 0x7f80067f9860) = -1 ENOENT (No such file or directory)
[pid 25523] lstat("/home/ili/git/DependencyonNativeLibraries/TestDependencies/System.Data.SQLite.dll", {st_mode=S_IFREG|0755, st_size=408248, ...}) = 0
[pid 25523] lstat("/home/ili/git/DependencyonNativeLibraries/TestDependencies/System.Data.SQLite.dll.config", 0x7f80067fa080) = -1 ENOENT (No such file or directory)
[pid 25523] lstat("/home/ili/git/DependencyonNativeLibraries/TestDependencies/System.Data.SQLite.dll.altconfig", 0x7f80067fa080) = -1 ENOENT (No such file or directory)
[pid 25523] stat("/home/ili/git/DependencyonNativeLibraries/TestDependencies/x86", 0x7f80067f9fa8) = -1 ENOENT (No such file or directory)
[pid 25523] stat("/home/ili/git/DependencyonNativeLibraries/TestDependencies/Win32", 0x7f80067f9fa8) = -1 ENOENT (No such file or directory)
[pid 25523] stat("/home/ili/git/DependencyonNativeLibraries/TestDependencies/x86_64", 0x7f80067f9fa8) = -1 ENOENT (No such file or directory)
[pid 25523] stat("/home/ili/git/DependencyonNativeLibraries/TestDependencies/x64", 0x7f80067f9fa8) = -1 ENOENT (No such file or directory)
[pid 25523] stat("/home/ili/git/DependencyonNativeLibraries/TestDependencies/AMD64", 0x7f80067f9fa8) = -1 ENOENT (No such file or directory)
[pid 25523] stat("/home/ili/git/DependencyonNativeLibraries/TestDependencies/x64", 0x7f80067f9fa8) = -1 ENOENT (No such file or directory)
[pid 25523] stat("/home/ili/git/DependencyonNativeLibraries/TestDependencies/IA64", 0x7f80067f9fa8) = -1 ENOENT (No such file or directory)
[pid 25523] stat("/home/ili/git/DependencyonNativeLibraries/TestDependencies/Itanium", 0x7f80067f9fa8) = -1 ENOENT (No such file or directory)
[pid 25523] stat("/home/ili/git/DependencyonNativeLibraries/TestDependencies/ARM", 0x7f80067f9fa8) = -1 ENOENT (No such file or directory)
[pid 25523] stat("/home/ili/git/DependencyonNativeLibraries/TestDependencies/WinCE", 0x7f80067f9fa8) = -1 ENOENT (No such file or directory)
[pid 25523] lstat("/home/ili/git/DependencyonNativeLibraries/TestDependencies/x86_64/SQLite.Interop.dll", 0x7f80067fa170) = -1 ENOENT (No such file or directory)
[pid 25523] lstat("/home/ili/git/DependencyonNativeLibraries/TestDependencies/x64/SQLite.Interop.dll", 0x7f80067fa170) = -1 ENOENT (No such file or directory)
[pid 25523] lstat("/opt/microsoft/powershell/7/x86_64/SQLite.Interop.dll", 0x7f80067fa170) = -1 ENOENT (No such file or directory)
[pid 25523] lstat("/opt/microsoft/powershell/7/x64/SQLite.Interop.dll", 0x7f80067fa170) = -1 ENOENT (No such file or directory)
[pid 25523] lstat("/opt/microsoft/powershell/7/SQLite.Interop.dll", 0x7f80067fa180) = -1 ENOENT (No such file or directory)
[pid 25523] lstat("/opt/microsoft/powershell/7/x86_64/SQLite.Interop.dll", 0x7f80067fa180) = -1 ENOENT (No such file or directory)
[pid 25523] lstat("/opt/microsoft/powershell/7/x64/SQLite.Interop.dll", 0x7f80067fa180) = -1 ENOENT (No such file or directory)
[pid 25523] openat(AT_FDCWD, "/opt/microsoft/powershell/7/SQLite.Interop.dll.so", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
[pid 25523] openat(AT_FDCWD, "/home/ili/git/DependencyonNativeLibraries/TestDependencies/SQLite.Interop.dll.so", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
[pid 25523] openat(AT_FDCWD, "/lib/x86_64-linux-gnu/SQLite.Interop.dll.so", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
[pid 25523] openat(AT_FDCWD, "/usr/lib/x86_64-linux-gnu/SQLite.Interop.dll.so", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
[pid 25523] openat(AT_FDCWD, "/lib/SQLite.Interop.dll.so", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
[pid 25523] openat(AT_FDCWD, "/usr/lib/SQLite.Interop.dll.so", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
[pid 25523] openat(AT_FDCWD, "/opt/microsoft/powershell/7/libSQLite.Interop.dll.so", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
[pid 25523] openat(AT_FDCWD, "/home/ili/git/DependencyonNativeLibraries/TestDependencies/libSQLite.Interop.dll.so", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
[pid 25523] openat(AT_FDCWD, "/lib/x86_64-linux-gnu/libSQLite.Interop.dll.so", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
[pid 25523] openat(AT_FDCWD, "/usr/lib/x86_64-linux-gnu/libSQLite.Interop.dll.so", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
[pid 25523] openat(AT_FDCWD, "/lib/libSQLite.Interop.dll.so", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
[pid 25523] openat(AT_FDCWD, "/usr/lib/libSQLite.Interop.dll.so", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
[pid 25523] openat(AT_FDCWD, "/opt/microsoft/powershell/7/SQLite.Interop.dll", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
[pid 25523] openat(AT_FDCWD, "/home/ili/git/DependencyonNativeLibraries/TestDependencies/SQLite.Interop.dll", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
[pid 25523] openat(AT_FDCWD, "/lib/x86_64-linux-gnu/SQLite.Interop.dll", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
[pid 25523] openat(AT_FDCWD, "/usr/lib/x86_64-linux-gnu/SQLite.Interop.dll", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
[pid 25523] openat(AT_FDCWD, "/lib/SQLite.Interop.dll", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
[pid 25523] openat(AT_FDCWD, "/usr/lib/SQLite.Interop.dll", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
[pid 25523] openat(AT_FDCWD, "/opt/microsoft/powershell/7/libSQLite.Interop.dll", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
[pid 25523] openat(AT_FDCWD, "/home/ili/git/DependencyonNativeLibraries/TestDependencies/libSQLite.Interop.dll", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
[pid 25523] openat(AT_FDCWD, "/lib/x86_64-linux-gnu/libSQLite.Interop.dll", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
[pid 25523] openat(AT_FDCWD, "/usr/lib/x86_64-linux-gnu/libSQLite.Interop.dll", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
[pid 25523] openat(AT_FDCWD, "/lib/libSQLite.Interop.dll", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
[pid 25523] openat(AT_FDCWD, "/usr/lib/libSQLite.Interop.dll", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
[pid 25523] openat(AT_FDCWD, "/home/ili/git/DependencyonNativeLibraries/TestDependencies/linux-x64/SQLite.Interop.dll.so", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
[pid 25523] lstat("/home/ili/git/DependencyonNativeLibraries/TestDependencies/System.Data.SQLite.pdb", 0x7f80067f8b40) = -1 ENOENT (No such file or directory)
[pid 25510] openat(AT_FDCWD, "/opt/microsoft/powershell/7/linux-x64/libmsquic.so.2.so", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)
[pid 25510] openat(AT_FDCWD, "/opt/microsoft/powershell/7/linux-x64/libmsquic.so.so", O_RDONLY|O_CLOEXEC) = -1 ENOENT (No such file or directory)

So it first looks at "TestDependencies/x64/SQLite.Interop.dll" like on Windows but then if I put the file there it dosent use it.
So next I saw "TestDependencies/linux-x64/SQLite.Interop.dll.so" so I renamed the dll as mentiond to "SQLite.Interop.dll.so" and it worked
Then I looked again in Procmon and way down I also saw "...\DependencyonNativeLibraries\TestDependencies\win-x64\SQLite.Interop.dll.dll"
So I also renamed it and it worked on windows also.
So valid pathes are:
"./linux-x64/SQLite.Interop.dll.so"
".\TestDependencies\win-x64\SQLite.Interop.dll.dll"
Is this by design or is is this a bug?
Shouldn't it just leave the file names as is without adding the extra extensions?

Well done, I can confirm that works on debian.11-arm64....
I made a symbolic link from SQLite.Interop.dll.so to SQLite.Interop.dll
$ find bin/Release/netstandard2.0/ | xargs ls -ld
drwxr-xr-x 3 foo users    4096 Mar  4 20:41 bin/Release/netstandard2.0/
-rw-r--r-- 1 foo users    3145 Mar  4 19:07 bin/Release/netstandard2.0/SQLiteConnection.deps.json
-rw-r--r-- 1 foo users    5120 Mar  4 19:07 bin/Release/netstandard2.0/SQLiteConnection.dll
-rw-r--r-- 1 foo users    7888 Mar  4 19:07 bin/Release/netstandard2.0/SQLiteConnection.pdb
-rw-r--r-- 1 foo users  370688 Mar  4 19:07 bin/Release/netstandard2.0/System.Data.SQLite.dll
drwxr-xr-x 2 foo users    4096 Mar  4 20:42 bin/Release/netstandard2.0/linux-arm64
-rwxr-xr-x 1 foo users 1733680 Mar  4 19:07 bin/Release/netstandard2.0/linux-arm64/SQLite.Interop.dll
lrwxrwxrwx 1 foo users      18 Mar  4 20:42 bin/Release/netstandard2.0/linux-arm64/SQLite.Interop.dll.so -> SQLite.Interop.dll

I agree, there is no need for appending the .so suffix.
The .so is not need when it is not in the platform specific directory and it is not needed with normal dotnet when it finds it using the *.deps.json file.

That also works on macOS with the symbolic link with dylib added
% find bin/Release/netstandard2.0/ | xargs ls -ld
drwxr-xr-x  7 foo  staff      224 Mar  4 21:55 bin/Release/netstandard2.0
-rw-r--r--  1 foo  staff     3145 Mar  4 18:54 bin/Release/netstandard2.0/SQLiteConnection.deps.json
-rw-r--r--  1 foo  staff     5120 Mar  4 18:54 bin/Release/netstandard2.0/SQLiteConnection.dll
-rw-r--r--  1 foo  staff     7904 Mar  4 18:54 bin/Release/netstandard2.0/SQLiteConnection.pdb
-rw-r--r--  1 foo  staff   370688 Mar  4 18:54 bin/Release/netstandard2.0/System.Data.SQLite.dll
drwxr-xr-x  4 foo  staff      128 Mar  4 21:54 bin/Release/netstandard2.0/osx-x64
-rwxr-xr-x  1 foo  staff  4188286 Mar  4 18:54 bin/Release/netstandard2.0/osx-x64/SQLite.Interop.dll
lrwxr-xr-x  1 foo  staff       18 Mar  4 21:54 bin/Release/netstandard2.0/osx-x64/SQLite.Interop.dll.dylib -> SQLite.Interop.dll

This mechanism doesn't support 'fat' binaries on macOS with multiple architectures, they can't just live in an osx directory.
% lipo -info bin/Release/netstandard2.0/osx-x64/SQLite.Interop.dll
Architectures in the fat file: bin/Release/netstandard2.0/osx-x64/SQLite.Interop.dll are: x86_64 arm64

Ah, that is .... unfortunate. :(
To use the win-x64 directory you have do add the dll extension again. Here it works with a symbolic link.
03/12/2022  08:38 am         1,871,072 SQLite.Interop.dll
04/03/2023  11:09 pm    <SYMLINK>      SQLite.Interop.dll.dll [SQLite.Interop.dll]

Also you could try to remove the dll extension in the DllImport and make and try custom build.

The documentation says to use the DLL with the .dll extension present.
The System.Data.SQLite.dll is an already existing common component so would not want a customised recompilation. Although it is unfortunate, we can solve it by either renaming the actual native file by appending the extension or using symbolic links. At least it is consistent, even the "win-x64" needs an additional ".dll" on the native filename.

Okay, it looks a little odd but it does work
Archive:  SQLiteConnection.zip
  Length      Date    Time    Name
---------  ---------- -----   ----
     3145  03-05-2023 02:48   SQLiteConnection/SQLiteConnection.deps.json
     5120  03-05-2023 02:48   SQLiteConnection/SQLiteConnection.dll
     7904  03-05-2023 02:48   SQLiteConnection/SQLiteConnection.pdb
      371  03-05-2023 02:47   SQLiteConnection/SQLiteConnection.psd1
   370688  11-25-2022 14:09   SQLiteConnection/System.Data.SQLite.dll
  1336544  12-03-2022 08:38   SQLiteConnection/win-arm/SQLite.Interop.dll.dll
  2058472  03-05-2023 02:48   SQLiteConnection/osx-x64/SQLite.Interop.dll.dylib
  1115200  12-03-2022 19:10   SQLiteConnection/linux-arm/SQLite.Interop.dll.so
  1733680  12-03-2022 19:11   SQLiteConnection/linux-arm64/SQLite.Interop.dll.so
  1454304  12-03-2022 08:38   SQLiteConnection/win-x86/SQLite.Interop.dll.dll
  2140286  03-05-2023 02:48   SQLiteConnection/osx-arm64/SQLite.Interop.dll.dylib
  1871072  12-03-2022 08:38   SQLiteConnection/win-x64/SQLite.Interop.dll.dll
  1651120  12-03-2022 19:08   SQLiteConnection/linux-x64/SQLite.Interop.dll.so
  1919200  12-03-2022 08:38   SQLiteConnection/win-arm64/SQLite.Interop.dll.dll
---------                     -------
 15667106                     14 files

There is one oddity
The platforms listed shows linux-x86 which does not have a PowerShell 7 release and not osx-arm64 which does.

There is one oddity
The platforms listed shows linux-x86 which does not have a PowerShell 7 release and not osx-arm64 which does.

/cc @sdwheeler We need update docs.

@iSazonov update what docs with what information. Please file a docs issue.

hi @ili101
The x86 for Linux libraries in my powershell project “kasini3000” include:
https://gitee.com/chuanjiao10/kasini3000/tree/master/cmdb
I want to know where to find the dll file for linux-arm64?
It is better to compile it officially, or nuget

hi @ili101 The x86 for Linux libraries in my powershell project “kasini3000” include: https://gitee.com/chuanjiao10/kasini3000/tree/master/cmdb
I want to know where to find the dll file （SQLite.Interop.dll ）for linux-arm64? It is better to compile it officially, or nuget

I'm not an expert but from what I can find you have to compile it as they supply only Windows/Linux - x86/x64.
See https://github.com/PowerShell/PowerShell/issues/19277#issuecomment-1454961501
@rhubarb-geek-nz how do you compile all those versions for all the OSs? I don't see any GitHub Actions or something like this on the repo, do you use something else?

how do you compile all those versions for all the OSs?

Hi, I use Docker containers running the target OS so the tool chain and libraries are correct for each version. I run the ARM docker containers on a raspberry pi 4. The Windows ARM builds are compiled on an x86_64 machine but tested on a Windows Dev Kit 2023 The macOS ARM builds are tested on a M1 Mac mini.
I don't build a linux-x86 version of SQLite.Interop.dll because there isn't an official version of dotnet or PowerShell that supports that platform so although you could compile it you could not test it. You are welcome to compile it yourself on an i386 docker image. You could try dotnet on i386.
The NuGet version of System.Data.SQLite.dll since <IP_ADDRESS> is problematic for building your own version of SQLite.Interop.dll because they obfuscated the Dll entry point names. I use the NuGet package for the compilation stage but then use the Precompiled Binaries for the .NET Standard 2.0 for running.
I chose to use the builds for debian.11 for general linux, they should work on recent all recent debian derivatives, and also some other distributions.

The SQLite.Interop.dll happily builds on debian.11-x86, but not able to use it.
$ ./package.sh
b9a96a6245284c8a4a24394cf8f1045f1cfedc0ce552fa601868872f23677c1b  sqlite-netFx-source-<IP_ADDRESS>.zip
~/windev-shell/sqlite/<IP_ADDRESS>/src/SQLite.Interop/src/generic ~/windev-shell/sqlite/<IP_ADDRESS>/src/Setup
~/windev-shell/sqlite/<IP_ADDRESS>/src/Setup
-rwxr-xr-x 1 builder users 2915704 Mar  6 05:50 src/bin/2013/Release/bin/libSQLite.Interop.so
-rwxr-xr-x 1 builder users 2915704 Mar  6 05:50 src/bin/2013/Release/bin/SQLite.Interop.dll
-rwxr-xr-x 1 builder users 1516456 Mar  6 05:50 src/bin/2013/Release/bin/SQLite.Interop.dll
  adding: runtimes/debian.11-x86/native/SQLite.Interop.dll (deflated 58%)

Unfortunately the Microsoft dotnet-install.sh script downloads the x86_64 version.
dotnet-install: Attempting to download using aka.ms link https://dotnetcli.azureedge.net/dotnet/Sdk/6.0.406/dotnet-sdk-6.0.406-linux-x64.tar.gz

I have noticed a gotcha, if you use the full core layout so you include Linux and OSX dlls as well then the layout does not work on Windows PowerShell as it is just looking for the dlls under the processor architecture only.

I have noticed a gotcha, if you use the full core layout so you include Linux and OSX dlls as well then the layout does not work on original Windows PowerShell 5 as it is just looking for the dlls under the processor architecture only. ( and with original name, not additional .dll )

Yes I know, this is expected as this only works on PS 7.0+. I also did the same here https://github.com/mithrandyr/SimplySql/pull/111, but in the particular case of System.Data.SQLite as they hard coded the x64 x86 folders you can have support for all PS versions except specifically PS 6 on Linux

I have noticed a gotcha, if you use the full core layout so you include Linux and OSX dlls as well then the layout does not work on original Windows PowerShell 5 as it is just looking for the dlls under the processor architecture only. ( and with original name, not additional .dll )

Yes I know, this is expected as this only works on PS 7.0+. I also did the same here mithrandyr/SimplySql#111, but in the particular case of System.Data.SQLite as they hard coded the x64 x86 folders you can have support for all PS versions except specifically PS 6 on Linux (that is EOL anyway)

My solution is to have two different packages, one for desktop and another for core desktop
https://github.com/rhubarb-geek-nz/SQLiteConnection/releases

A further limitation is that a shared library compiled on debian.11 does not load on rhel.8 due to different GLIBC linkages.
$ ldd .local/share/powershell/Modules/rhubarb-geek-nz.SQLiteConnection/<IP_ADDRESS>/linux-x64/SQLite.Interop.dll.so
.local/share/powershell/Modules/rhubarb-geek-nz.SQLiteConnection/<IP_ADDRESS>/linux-x64/SQLite.Interop.dll.so: /lib64/libm.so.6: version `GLIBC_2.29' not found (required by .local/share/powershell/Modules/rhubarb-geek-nz.SQLiteConnection/<IP_ADDRESS>/linux-x64/SQLite.Interop.dll.so)

So despite what .NET RID Catalog says, linux-x64 for example cannot be truly generic when the binary signature is different between different Linux distributions.
I see no other option than offering different nupkg per operating system.


Feature: pass custom data to commands

Hi,
I'm wondering if it's possible to pass data to commands ?
My goal is to implement TTS using powershell. I would trigger the command from HA and pass the text as data of the command.
But I need a way to get said text in my Powershell script to handle the TTS part.
Is it possible at the moment ? I couldn't find it in the documentation. I know that notifications can accept additional data.
Thanks again for the great tool !

Hey @Growiel, currently that's not possible. There's a request (#31) that, when implemented, would do what you want.
But besides that, being able to send additional data with commands is on my to-do list. No ETA yet (on both) though!

I am aware of #31 and am definitely in support of it (like said in it), but this would be a dependency-free way of doing it.
If Google Translate TTS (or any other integration) is down, or I lose my internet, I know that I least i'll get my TTS on my computer just fine, since it's generated locally.
I don't own any smart speaker, all my TTS-ing will be done through my windows computer pluged into regular speakers. I work from home so the computer is pretty much always on.
Glad to know it's on the todo list :)
You can close this then if you want.

Totally understand, that's a very good attitude to have.
I'm very chaotic, so these tickets serve as an extra reminder - I'll keep it open 'till it's done :)

Passing something to command through Home Assistant would also be very useful in other implemantantions.
i.e. I want to change the volume in Laptop automatically and that should follow a sensor in Home Assistant.
Now I can increase or decrease the volume and not set the volume to a % value.
I'm currently doing this with IOPC and NirCMD


Unify TimeAndDate provider API

TimeAndDate#past methods use minimum input parameter of long type, but TimeAndDate#future methods - of int type. This change unifies API: minimum input parameter is always of long type

:warning: Please install the  to ensure uploads and comments are reliably processed by Codecov.
Codecov Report
All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 91.95%. Comparing base (b37c566) to head (eee4d67).
Report is 202 commits behind head on main.

:exclamation: Your organization needs to install the Codecov GitHub app to enable full functionality.
Additional details and impacted files
@@             Coverage Diff              @@
##               main    #1282      +/-   ##
============================================
- Coverage     92.35%   91.95%   -0.41%
- Complexity     2821     3086     +265
============================================
  Files           292      310      +18
  Lines          5609     6025     +416
  Branches        599      627      +28
============================================
+ Hits           5180     5540     +360
- Misses          275      333      +58
+ Partials        154      152       -2

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

Good point, thanks for this!

I know we just made these date/time changes but technically this breaks the public API (people will have to update their code to accommodate). The methods should have been deprecated and new methods implemented (the old could even call the new and cast the params too long).
[For my two cents, I know others on this project don't see it as strictly as I do 😉]

Hi @kingthorin

people will have to update their code to accommodate

Why would consumers need to change their code? It's a change from an int to a long, from the callers perspective nothing should change (hence no unit tests were changed either).
(and yes, if we'd follow semver to the letter, we'd be on Datafaker 16 by now ;-) )

Nope you're right, Java treats a number as a number in this case. I had been thinking, ex: 3 ➡ 3L, but Java doesn't force that.

It's a good point though. I thought there was something, that if you pass in a Long (or Int), and we change the method signature without recompiling, the code cannot find the signature anymore or so. I don't remember the exact case for this.
I do think one day we should use something like this: https://lvc.github.io/japi-compliance-checker/

In another project I work on they use japicmp.