A "declaration has metavariables" error

Prerequisites
Please put an X between the brackets as you perform the following steps:

[x] Check that your issue is not already filed.
[x] Reduce the issue to a minimal, self-contained, reproducible test case.
[x] Test your test case against the latest nightly release.

Description
The following code
structure ValVar (D: Type) where
  d: D
  x: Nat

def Set (T : Type) := T → Prop

structure Salg where
  D: Type
  I: Nat

def natSalg: Salg := { D := Nat, I := 42 }

inductive HasMem (salg: Salg): Set (Set (ValVar salg.D))
| hasMem
  (set: Set (ValVar salg.D))
  (isElem: set ⟨d, x⟩)
:
  HasMem salg set

def valVarSet: Set (ValVar Nat) :=
  fun ⟨d, x⟩ => x = 0 ∧ d = 0 ∧ d ∉ []

def valVarSetHasMem: HasMem natSalg valVarSet :=
  HasMem.hasMem
    valVarSet
    (show valVarSet _ from ⟨rfl, rfl, nofun⟩)

throws (kernel) declaration has metavariables 'valVarSetHasMem'.
There is a list of things that make the issue go away (which is also why I couldn't come up with a more specific title -- I've no idea what the underlying cause is :sorry:):

removing x from ValVar, along with its occurences in the rest of the program
removing I from Salg
removing the salg param from HasMem & replacing occurences with natSalg
removing d ∉ [] from the definition of valVarSet
replacing HasMem.hasMem valVarSet with HasMem.hasMem _ in valVarSetHasMem.
replacing show valVarSet _ from with show _ from, show valVarSet ⟨0, 0⟩ from, or removing it entirely.

Expected behavior: The code throws no errors.
Versions
Version: Lean 4.14.0-nightly-2024-11-01
Platform: live.lean-lang.org
Impact
Add :+1: to issues you consider important. If others are impacted by this issue, please ask them to add :+1: to it.

We have the similar issue:
open Function

theorem my_mul_right_injective {M₀ : Type} [Mul M₀] [Zero M₀] {a : M₀} (ha : a ≠ 0) :
  Injective fun (x : M₀) ↦ a * x := sorry

-- (kernel) declaration has metavariables 'mul2'
def mul2 : { f : Nat → Nat // Injective f } := ⟨fun x : Nat ↦ 2 * x, mul_right_injective nofun⟩

Note: this issue's example doesn't typecheck on a recent Lean, I think because of the changes in #6024. In the tests for #6414 I added the following unification hint to make up for the difference:
unif_hint (s : Salg) where
  s =?= natSalg
  |-
  Salg.D s =?= Nat

Unfortunately, this covers up the issue in 4.14. I figure it's still worth including the example in #6414 as a regression test, but it would be better if we could observe that this issue has been fixed.
testing on stable mathlib live-lean, which is currently 4.14

While updating Lean to v4.15.0-rc1, I noticed this issue is still present in my project. So here's another (less successfully) minified example that reproduces on latest Mathlib. It no longer reproduces on Lean nightly, so we have a confirmation the issue us gone.
def Set (D: Type) := D → Prop

structure ValVar where
  d: Empty
  x: Nat

structure Salgebra where
  D: Type
  I: Empty → Empty

def pairSalgebra: Salgebra := ⟨Empty, nofun⟩

structure Cause (D: Type) where
  contextIns: Set Nat

mutual
inductive Ins (salg: Salgebra): Prop

inductive IsCauseInapplicable (salg: Salgebra):
  Cause salg.D → Prop

| blockedContextIns
  (cause: Cause salg.D)
  (inContextIns: cause.contextIns 0)
:
  IsCauseInapplicable salg cause
end

def IsVarFree (x: Nat): Prop := ∀ d, ValVar.mk d x ∉ []

def extOfIntCause
  (internalCause: Cause Empty)
:
  Cause Empty
:= {
  contextIns :=
    fun _ => ∃ vvI, internalCause.contextIns vvI ∧ IsVarFree vvI
}

def insInternalToInsExternal
  (isInapp: IsCauseInapplicable pairSalgebra internalCause)
:
  IsCauseInapplicable pairSalgebra (extOfIntCause internalCause)
:=
  isInapp.rec
    (motive_1 := fun _ => True)
    (motive_2 :=
      fun cause _ =>
        IsCauseInapplicable pairSalgebra (extOfIntCause cause))
    (fun cause inCins =>
      IsCauseInapplicable.blockedContextIns
        (salg := pairSalgebra)
        (extOfIntCause cause)
        (⟨_, inCins, nofun⟩))


[Defect] World Scripts Explorer

Cursor click position problem prevention then replace all content #1
Writing multiple-scripts typing direction per script to be managed #8
Bousphorden & Reverse-Bousphorden to be better resolved
Capability of ISO 105 & ANSI 104 Keyboard standard to be allowed
Pasting contents from outside to be allowed
Allow increase of size of non-Unicode images within editor
When QWERTY does not exist how to switch back to Orthography type when multiple tabs are opened
Typing with Noto-Fonts for Unicode v15.0 adds � #79
Resolve accessibility as per check-list #9
Remove unused CSS, translations #17

Completed Defects ✅

Size of Image should be similar to characters #75
AltGr does not get activated for linked physical and virtual keyboard
Word Suggestions should show up (from client-side)
Hovering of keyboard shows in browser
Mapping of keys should be allowed first time as linking
Favourites of keyboard should function on click
Remove 'server-side' call and logos
Script going from top-bottom going right-to-left resolution


try linking info about cache types

(though one potential trap is that example at tagged commit will still link latest docs)

This would be normally fine. I just happen to be in the middle of a complete overhaul of the documentation, so don't want to add links at this point which will be invalid very soon.
Thank you nonetheless.


[HUDI-4894] Fix ClassCastException when using fixed type defining dec…

when use fixed type to define decimal column, hudi will throw a ClassCastException
Caused by: java.lang.ClassCastException: java.lang.Double cannot be cast to java.util.List
at org.apache.hudi.avro.MercifulJsonConverter$9.convert(MercifulJsonConverter.java:254)
at org.apache.hudi.avro.MercifulJsonConverter$JsonToAvroFieldProcessor.convertToAvro(MercifulJsonConverter.java:151)
at org.apache.hudi.avro.MercifulJsonConverter.convertJsonToAvroField(MercifulJsonConverter.java:140)
at org.apache.hudi.avro.MercifulJsonConverter.convertJsonToAvro(MercifulJsonConverter.java:107)
at org.apache.hudi.avro.MercifulJsonConverter.convert(MercifulJsonConverter.java:96)
at org.apache.hudi.utilities.sources.helpers.AvroConvertor.fromJs

schema for decimal column
{
    "name": "column_name",
    "type": ["null", {
        "type": "fixed",
        "name": "fixed",
        "size": 5,
        "logicalType": "decimal",
        "precision": 10,
        "scale": 2
    }],
    "default": null
}

Change Logs
Describe context and summary for this change. Highlight if any code was copied.
Impact
Describe any public API or user-facing feature change or any performance impact.
Risk level: none | low | medium | high
Choose one. If medium or high, explain what verification was done to mitigate the risks.
Contributor's checklist

[ ] Read through contributor's guide
[ ] Change Logs and Impact were stated clearly
[ ] Adequate tests were added if applicable
[ ] CI passed

@hudi-bot run azure

cancelling all azure CI runs for now to investigate CI flakiness. will retrigger build once we are in stable state. sorry about the inconvenience.

@shenh062326  can you also take a look at this ?

@xushiyan : PR is assigned to you. Will you be following up?


Categories don't show up in menu

Hey there, I'm trying your theme, but I can't get categories to display in the menu. Pages do show up. I tried the settings you provide in the wiki and entered categories in the posts. I also tried turning categories by folder on and moved posts in folders. No success. Did I miss something? Categories do correctly show up in the post meta.

I figured it out. You can either display categories or pages. I don't see why that should be so as all scenarios can easily be configured anyway. So I sent a patch.


h3 integration

The h3 is an HTTP server framework behind Nitro, which is again behind Analog and Vinxi.  Vinxi is behind SolidStart and TanStack Start, so if Fedify can integrate with h3, it lets Fedify integrate with many web frameworks.

Created @fedify/h3 package.


Fix endpoint reinitialize

Summary
Here is an example of code that causes an exception.
tour = client.tournament 7798
requests = tour.requests
appeals = tour.appeals

In that case library is trying to access /tournaments/7798/requests/appeals endpoint instead of /tournaments/7798/appeals
Proposed solution is to store the initial endpoint query instead of infinitely add strings to query_params.

Good stuff 👍


Chat History auto deleting

Hi, Can you please help me resolve this issue when I am going from one section to another, e.g., chat and learn to ask a question or ask a question to fact check the chat history, along with developer settings, are getting deleted; please tell me me how to fix this?
I suppose it can refresh as the user clears chat or refreshes the browser; I tried solving it myself, but I faced a lot of errors as this is not my expertise. Any help will be appreciated; thank you.

Please provide us with the following information:

This issue is for a: (mark with an x)
- [ ] bug report -> please search issues before submitting
- [ ] feature request
- [ ] documentation issue or request
- [ ] regression (a behavior that used to work and stopped in a new release)

Minimal steps to reproduce

Ask a question in chat
Go to ask a question
return to chat. The message/chat history is cleared without clicking on clear chat along with developer tools settings.

Any log messages given by the failure

Expected/desired behavior

The chat should be there unless I refresh (chat being on local storage) or click on clear chat.
If possible, also guide me on how I can apply this to the developer setting as the override prompt template and other settings get factory reset every time we switch from chat and learn to ask a question or vice versa.

OS and Version?

Windows 7, 8 or 10. Linux (which distribution). macOS (Yosemite? El Capitan? Sierra?)

azd version?

run azd version and copy paste here.

Versions

Mention any other details that might be useful

Thanks! We'll be in touch soon.

This is currently by design, there is no persistence of either chat history or settings. Here's a feature request where we discuss persistance of developer settings:
https://github.com/Azure-Samples/azure-search-openai-demo/issues/1791
And here's a PR on a much older version of the repo that adds conversation history persistance:
https://github.com/Azure-Samples/azure-search-openai-demo/pull/259
I hope to get that PR updated to work with the latest version of the repo sometime this month.
I'll close this issue, since we have the same requests filed elsewhere, please inquire on those threads/PRs as needed.


Generated JS resolves scope in a weird way, resulting in a crash

Definition order matters in an unexpected way for mutually recursive declarations.
Here's an example: http://share-elm.com/sprout/55c4da64e4b06aacf0e8bcfe
By switching main's definition, you'll cause a crash. This seems to be due to how JS scope works, but we've not narrowed down a good fix. There's some more discussion in Dandandan/parser#15.

Sorry for the vagueness in the description! Hopefully the example is clear.

Sorry, I should have linked this back in the thread on the parser page. This was discussed and closed in https://github.com/elm-lang/elm-compiler/issues/999, which was a duplicate of https://github.com/elm-lang/elm-compiler/issues/873.

If I understand correctly, this will be fixed by #873, so let's follow along there!

Great! Thanks!

No problem, thanks for reporting!


fix: Better error message on schema mismatch

Description
This helps debug an issue when schema changes occur.
Also, fixing a deprecated error message parsing.
Checklist

[x] I have run this code in development and it appears to resolve the stated issue.
[x] This PR includes tests, or tests are not required/relevant for this PR.
[x] I have run changie new and committed everything in .changes folder
[x] I have removed any print or log calls that were added for debugging.
[x] I have verified that this PR contains only code changes relevant to this PR.
[ ] If further integration tests are now passing I've edited tests/functional/adapter/* to account for this.
[ ] I have pulled/merged from the main branch if there are merge conflicts.
[ ] After pulling/merging main I have run pytest on the included or updated tests/functional/adapter/.

Tests are passing


Provide a manual and example to update the Ingress hostnames programmatically

In order to enable management of hostnames in the web console a programmatic way of updating Ingress names, including automation of the HTTPS certificates is needed.
Make a step by step manual and an example for this.

@ToshKoevoets Initial version of documentation description is added to [docs/update_ingress.md]. An example has been added to k8s/ingress-edit.
Will check the whole flow including sample in Node.js and add this to the example


SVG animateTransform tag missing

Animation tag was missed in <svg-icon-sprite [src]="'spin'" ></svg-icon-sprite>.
The sprite SVG output had animateTransform. But using "svg-icon-sprite", the animateTransform tag was missing. Transform animation missing and show single snap image-only,
I have download from internet and used for render, transform missing
<?xml version="1.0" encoding="utf-8"?>
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" style="margin: auto; background: none; display: block; shape-rendering: auto;" width="200px" height="200px" viewBox="0 0 100 100" preserveAspectRatio="xMidYMid">
<circle cx="50" cy="50" r="32" stroke-width="8" stroke="#fe718d" stroke-dasharray="50.26548245743669 50.26548245743669" fill="none" stroke-linecap="round" transform="rotate(311.837 50 50)">
  <animateTransform attributeName="transform" type="rotate" repeatCount="indefinite" dur="1s" keyTimes="0;1" values="0 50 50;360 50 50"></animateTransform>
</circle></svg>

Plz, suggest how to use animate SVG to convert sprite.
Thanks.

As I understand you correct, running the 'generate:sprite' npm task removes the animateTransform tag from your sprite file containing the symbols, correct?

No. <svg-icon-sprite [src]="'spin'" ></svg-icon-sprite> While access the sprite file and render time only the was tag removed.

Anybody have a solution for this issue: https://stackoverflow.com/questions/46981649/svg-animatetransform-tag-is-lost-when-using-svg-use

@sbala69gmail for sure it is already a bit to late, however if someone else comes across this: Svg animations don't work here as the sprite is loaded from an external file. This is not caused by this lib, this is how the browsers behave. In order to fix it you would need to inline/embed the sprite in e.g. you index.html file. I found a good example here where you can easily check the DOM element in the browser http://bl.ocks.org/bertspaan/6182774. You can see there that also just with plain HTML the animateTransform nodes got removed by the browser.

@gasfab999 thank you for clarifying this issue and providing an example. I consider the issue closed.


firefox-bin: update to version 39.0

Various security fixes
Share Hello URLs with social networks
Support for 'switch' role in ARIA 1.1 (web accessibility)
SafeBrowsing malware detection lookups enabled for downloads (Mac OS X and Linux)
Support for new Unicode 8.0 skin tone emoji
Removed support for insecure SSLv3 for network communications
Disable use of RC4 except for temporarily whitelisted hosts

https://www.mozilla.org/en-US/firefox/39.0/releasenotes/

Rename commit as it said in CONTRIBUTING.md.


build(update-simulator-data): added simulator update script

Closes #151
Signed-off-by: Lukas Mertens<EMAIL_ADDRESS>
Stack:

#164
#161
#160
#154
#153 ⬅
#140
#139
#138
#136
#148
#135
#147
#134
#132
#129
#130
#128
#127
#126
#125
#146

⚠ Part of a stack created by spr. Do not merge manually using the UI - doing so may have unexpected results.

✓ Commit merged in pull request #164


CI: run e2e tests for libvirt with CRI-O

This is the minimum required to run e2e tests for libvirt on k8s configured with CRI-O.

libvirt/kcli_cluster.sh can now provision k8s configured with CRI-O. Just need to export CONTAINER_RUNTIME=crio
The e2e framework will handle the container_runtime=crio property in libvirt.properties
Finally the changes on workflows to add a new job were made. Notice that the CRI-O will run with continue-on-error enabled for a while as we will be to fully check its stability by running on CI env.

Fixes #1981

Putting on hold because some tests are failing and I didn't run the attestation ones yet. But I appreciate any feedback on these changes.
The preliminary tests execution:
=== RUN   TestLibvirtCreateSimplePod
=== RUN   TestLibvirtCreateSimplePod/SimplePeerPod_test
    assessment_runner.go:264: Waiting for containers in pod: simple-test are ready
=== RUN   TestLibvirtCreateSimplePod/SimplePeerPod_test/PodVM_is_created
=== NAME  TestLibvirtCreateSimplePod/SimplePeerPod_test
    assessment_runner.go:617: Deleting pod simple-test...
    assessment_runner.go:624: Pod simple-test has been successfully deleted within 60s
--- PASS: TestLibvirtCreateSimplePod (105.08s)
    --- PASS: TestLibvirtCreateSimplePod/SimplePeerPod_test (105.08s)
        --- PASS: TestLibvirtCreateSimplePod/SimplePeerPod_test/PodVM_is_created (0.02s)
=== RUN   TestLibvirtCreatePodWithConfigMap
=== RUN   TestLibvirtCreatePodWithConfigMap/ConfigMapPeerPod_test
    assessment_runner.go:264: Waiting for containers in pod: busybox-configmap-pod are ready
=== RUN   TestLibvirtCreatePodWithConfigMap/ConfigMapPeerPod_test/Configmap_is_created_and_contains_data
    assessment_runner.go:435: Output when execute test commands:
=== NAME  TestLibvirtCreatePodWithConfigMap/ConfigMapPeerPod_test
    assessment_runner.go:560: Deleting Configmap... busybox-configmap
    assessment_runner.go:617: Deleting pod busybox-configmap-pod...
    assessment_runner.go:624: Pod busybox-configmap-pod has been successfully deleted within 60s
--- PASS: TestLibvirtCreatePodWithConfigMap (145.17s)
    --- PASS: TestLibvirtCreatePodWithConfigMap/ConfigMapPeerPod_test (145.17s)
        --- PASS: TestLibvirtCreatePodWithConfigMap/ConfigMapPeerPod_test/Configmap_is_created_and_contains_data (5.07s)
=== RUN   TestLibvirtCreatePodWithSecret
=== RUN   TestLibvirtCreatePodWithSecret/SecretPeerPod_test
    assessment_runner.go:264: Waiting for containers in pod: busybox-secret-pod are ready
=== RUN   TestLibvirtCreatePodWithSecret/SecretPeerPod_test/Secret_has_been_created_and_contains_data
    assessment_runner.go:435: Output when execute test commands:
=== NAME  TestLibvirtCreatePodWithSecret/SecretPeerPod_test
    assessment_runner.go:567: Deleting Secret... busybox-secret
    assessment_runner.go:617: Deleting pod busybox-secret-pod...
    assessment_runner.go:624: Pod busybox-secret-pod has been successfully deleted within 60s
--- PASS: TestLibvirtCreatePodWithSecret (105.16s)
    --- PASS: TestLibvirtCreatePodWithSecret/SecretPeerPod_test (105.16s)
        --- PASS: TestLibvirtCreatePodWithSecret/SecretPeerPod_test/Secret_has_been_created_and_contains_data (5.08s)
=== RUN   TestLibvirtCreatePeerPodContainerWithExternalIPAccess
=== RUN   TestLibvirtCreatePeerPodContainerWithExternalIPAccess/IPAccessPeerPod_test
    assessment_runner.go:264: Waiting for containers in pod: busybox-priv are ready
=== RUN   TestLibvirtCreatePeerPodContainerWithExternalIPAccess/IPAccessPeerPod_test/Peer_Pod_Container_Connected_to_External_IP
    assessment_runner.go:435: Output when execute test commands: command terminated with exit code 1
    assessment_runner.go:437: command terminated with exit code 1
=== NAME  TestLibvirtCreatePeerPodContainerWithExternalIPAccess/IPAccessPeerPod_test
    assessment_runner.go:617: Deleting pod busybox-priv...
    assessment_runner.go:624: Pod busybox-priv has been successfully deleted within 60s
--- FAIL: TestLibvirtCreatePeerPodContainerWithExternalIPAccess (115.15s)
    --- FAIL: TestLibvirtCreatePeerPodContainerWithExternalIPAccess/IPAccessPeerPod_test (115.15s)
        --- FAIL: TestLibvirtCreatePeerPodContainerWithExternalIPAccess/IPAccessPeerPod_test/Peer_Pod_Container_Connected_to_External_IP (15.08s)
=== RUN   TestLibvirtCreatePeerPodWithJob
=== RUN   TestLibvirtCreatePeerPodWithJob/JobPeerPod_test
=== RUN   TestLibvirtCreatePeerPodWithJob/JobPeerPod_test/Job_has_been_created
    assessment_helpers.go:300: SUCCESS: job-pi-72kdq - Completed - LOG: 3.14156
    assessment_runner.go:336: Output Log from Pod: 3.14156
=== NAME  TestLibvirtCreatePeerPodWithJob/JobPeerPod_test
    assessment_runner.go:600: Deleting Job... job-pi
    assessment_runner.go:607: Deleting pods created by job... job-pi-72kdq
--- PASS: TestLibvirtCreatePeerPodWithJob (90.13s)
    --- PASS: TestLibvirtCreatePeerPodWithJob/JobPeerPod_test (90.13s)
        --- PASS: TestLibvirtCreatePeerPodWithJob/JobPeerPod_test/Job_has_been_created (0.02s)
=== RUN   TestLibvirtCreatePeerPodAndCheckUserLogs
    common_suite.go:165: Skipping Test until issue kata-containers/kata-containers#5732 is Fixed
--- SKIP: TestLibvirtCreatePeerPodAndCheckUserLogs (0.00s)
=== RUN   TestLibvirtCreatePeerPodAndCheckWorkDirLogs
=== RUN   TestLibvirtCreatePeerPodAndCheckWorkDirLogs/WorkDirPeerPod_test
=== RUN   TestLibvirtCreatePeerPodAndCheckWorkDirLogs/WorkDirPeerPod_test/Peer_pod_with_work_directory_has_been_created
    assessment_runner.go:366: Log output of peer pod:/other
=== NAME  TestLibvirtCreatePeerPodAndCheckWorkDirLogs/WorkDirPeerPod_test
    assessment_runner.go:617: Deleting pod workdirpod...
    assessment_runner.go:624: Pod workdirpod has been successfully deleted within 60s
--- PASS: TestLibvirtCreatePeerPodAndCheckWorkDirLogs (105.09s)
    --- PASS: TestLibvirtCreatePeerPodAndCheckWorkDirLogs/WorkDirPeerPod_test (105.09s)
        --- PASS: TestLibvirtCreatePeerPodAndCheckWorkDirLogs/WorkDirPeerPod_test/Peer_pod_with_work_directory_has_been_created (5.01s)
=== RUN   TestLibvirtCreatePeerPodAndCheckEnvVariableLogsWithImageOnly
=== RUN   TestLibvirtCreatePeerPodAndCheckEnvVariableLogsWithImageOnly/EnvVariablePeerPodWithImageOnly_test
=== RUN   TestLibvirtCreatePeerPodAndCheckEnvVariableLogsWithImageOnly/EnvVariablePeerPodWithImageOnly_test/Peer_pod_with_environmental_variables_has_been_created
    assessment_runner.go:366: Log output of peer pod:KUBERNETES_SERVICE_PORT=443
        KUBERNETES_PORT=tcp://<IP_ADDRESS>:443
        HOSTNAME=env-variable-in-image
        SHLVL=1
        HOME=/root
        TERM=xterm
        KUBERNETES_PORT_443_TCP_ADDR=<IP_ADDRESS>
        PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
        KUBERNETES_PORT_443_TCP_PORT=443
        KUBERNETES_PORT_443_TCP_PROTO=tcp
        KUBERNETES_SERVICE_PORT_HTTPS=443
        KUBERNETES_PORT_443_TCP=tcp://<IP_ADDRESS>:443
        ISPRODUCTION=false
        KUBERNETES_SERVICE_HOST=<IP_ADDRESS>
        PWD=/
=== NAME  TestLibvirtCreatePeerPodAndCheckEnvVariableLogsWithImageOnly/EnvVariablePeerPodWithImageOnly_test
    assessment_runner.go:617: Deleting pod env-variable-in-image...
    assessment_runner.go:624: Pod env-variable-in-image has been successfully deleted within 60s
--- PASS: TestLibvirtCreatePeerPodAndCheckEnvVariableLogsWithImageOnly (100.08s)
    --- PASS: TestLibvirtCreatePeerPodAndCheckEnvVariableLogsWithImageOnly/EnvVariablePeerPodWithImageOnly_test (100.08s)
        --- PASS: TestLibvirtCreatePeerPodAndCheckEnvVariableLogsWithImageOnly/EnvVariablePeerPodWithImageOnly_test/Peer_pod_with_environmental_variables_has_been_created (5.03s)
=== RUN   TestLibvirtCreatePeerPodAndCheckEnvVariableLogsWithDeploymentOnly
=== RUN   TestLibvirtCreatePeerPodAndCheckEnvVariableLogsWithDeploymentOnly/EnvVariablePeerPodWithDeploymentOnly_test
=== RUN   TestLibvirtCreatePeerPodAndCheckEnvVariableLogsWithDeploymentOnly/EnvVariablePeerPodWithDeploymentOnly_test/Peer_pod_with_environmental_variables_has_been_created
    assessment_runner.go:366: Log output of peer pod:KUBERNETES_SERVICE_PORT=443
        KUBERNETES_PORT=tcp://<IP_ADDRESS>:443
        HOSTNAME=env-variable-in-config
        SHLVL=1
        HOME=/root
        TERM=xterm
        KUBERNETES_PORT_443_TCP_ADDR=<IP_ADDRESS>
        PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
        KUBERNETES_PORT_443_TCP_PORT=443
        KUBERNETES_PORT_443_TCP_PROTO=tcp
        KUBERNETES_PORT_443_TCP=tcp://<IP_ADDRESS>:443
        KUBERNETES_SERVICE_PORT_HTTPS=443
        ISPRODUCTION=true
        KUBERNETES_SERVICE_HOST=<IP_ADDRESS>
        PWD=/
=== NAME  TestLibvirtCreatePeerPodAndCheckEnvVariableLogsWithDeploymentOnly/EnvVariablePeerPodWithDeploymentOnly_test
    assessment_runner.go:617: Deleting pod env-variable-in-config...
    assessment_runner.go:624: Pod env-variable-in-config has been successfully deleted within 60s
--- PASS: TestLibvirtCreatePeerPodAndCheckEnvVariableLogsWithDeploymentOnly (100.09s)
    --- PASS: TestLibvirtCreatePeerPodAndCheckEnvVariableLogsWithDeploymentOnly/EnvVariablePeerPodWithDeploymentOnly_test (100.09s)
        --- PASS: TestLibvirtCreatePeerPodAndCheckEnvVariableLogsWithDeploymentOnly/EnvVariablePeerPodWithDeploymentOnly_test/Peer_pod_with_environmental_variables_has_been_created (5.02s)
=== RUN   TestLibvirtCreatePeerPodAndCheckEnvVariableLogsWithImageAndDeployment
=== RUN   TestLibvirtCreatePeerPodAndCheckEnvVariableLogsWithImageAndDeployment/EnvVariablePeerPodWithBoth_test
=== RUN   TestLibvirtCreatePeerPodAndCheckEnvVariableLogsWithImageAndDeployment/EnvVariablePeerPodWithBoth_test/Peer_pod_with_environmental_variables_has_been_created
    assessment_runner.go:366: Log output of peer pod:KUBERNETES_PORT=tcp://<IP_ADDRESS>:443
        KUBERNETES_SERVICE_PORT=443
        HOSTNAME=env-variable-in-both
        SHLVL=1
        HOME=/root
        TERM=xterm
        KUBERNETES_PORT_443_TCP_ADDR=<IP_ADDRESS>
        PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
        KUBERNETES_PORT_443_TCP_PORT=443
        KUBERNETES_PORT_443_TCP_PROTO=tcp
        KUBERNETES_SERVICE_PORT_HTTPS=443
        KUBERNETES_PORT_443_TCP=tcp://<IP_ADDRESS>:443
        ISPRODUCTION=true
        KUBERNETES_SERVICE_HOST=<IP_ADDRESS>
        PWD=/
=== NAME  TestLibvirtCreatePeerPodAndCheckEnvVariableLogsWithImageAndDeployment/EnvVariablePeerPodWithBoth_test
    assessment_runner.go:617: Deleting pod env-variable-in-both...
    assessment_runner.go:624: Pod env-variable-in-both has been successfully deleted within 60s
--- PASS: TestLibvirtCreatePeerPodAndCheckEnvVariableLogsWithImageAndDeployment (100.09s)
    --- PASS: TestLibvirtCreatePeerPodAndCheckEnvVariableLogsWithImageAndDeployment/EnvVariablePeerPodWithBoth_test (100.09s)
        --- PASS: TestLibvirtCreatePeerPodAndCheckEnvVariableLogsWithImageAndDeployment/EnvVariablePeerPodWithBoth_test/Peer_pod_with_environmental_variables_has_been_created (5.01s)
=== RUN   TestLibvirtCreateNginxDeployment
=== RUN   TestLibvirtCreateNginxDeployment/Nginx_image_deployment_test
    nginx_deployment.go:106: Creating nginx deployment...
    nginx_deployment.go:163: Current deployment available replicas: 0
    nginx_deployment.go:163: Current deployment available replicas: 0
    nginx_deployment.go:163: Current deployment available replicas: 0
    nginx_deployment.go:163: Current deployment available replicas: 0
    nginx_deployment.go:163: Current deployment available replicas: 0
    nginx_deployment.go:163: Current deployment available replicas: 0
    nginx_deployment.go:163: Current deployment available replicas: 0
    nginx_deployment.go:163: Current deployment available replicas: 0
    nginx_deployment.go:163: Current deployment available replicas: 0
    nginx_deployment.go:163: Current deployment available replicas: 0
    nginx_deployment.go:163: Current deployment available replicas: 0
    nginx_deployment.go:163: Current deployment available replicas: 0
    nginx_deployment.go:163: Current deployment available replicas: 2
    nginx_deployment.go:111: nginx deployment is available now
=== RUN   TestLibvirtCreateNginxDeployment/Nginx_image_deployment_test/Access_for_nginx_deployment_test
=== NAME  TestLibvirtCreateNginxDeployment/Nginx_image_deployment_test
    nginx_deployment.go:136: Deleting webserver deployment...
    nginx_deployment.go:141: Deleting deployment nginx-deployment...
    nginx_deployment.go:148: Deployment nginx-deployment has been successfully deleted within 120s
--- PASS: TestLibvirtCreateNginxDeployment (135.08s)
    --- PASS: TestLibvirtCreateNginxDeployment/Nginx_image_deployment_test (135.08s)
        --- PASS: TestLibvirtCreateNginxDeployment/Nginx_image_deployment_test/Access_for_nginx_deployment_test (0.03s)
=== RUN   TestLibvirtDeletePod
=== RUN   TestLibvirtDeletePod/DeletePod_test
    assessment_runner.go:264: Waiting for containers in pod: deletion-test are ready
=== RUN   TestLibvirtDeletePod/DeletePod_test/Deletion_complete
=== NAME  TestLibvirtDeletePod/DeletePod_test
    assessment_runner.go:617: Deleting pod deletion-test...
    assessment_runner.go:624: Pod deletion-test has been successfully deleted within 60s
--- PASS: TestLibvirtDeletePod (100.06s)
    --- PASS: TestLibvirtDeletePod/DeletePod_test (100.06s)
        --- PASS: TestLibvirtDeletePod/DeletePod_test/Deletion_complete (0.01s)
=== RUN   TestLibvirtPodToServiceCommunication
=== RUN   TestLibvirtPodToServiceCommunication/TestExtraPods_test
    assessment_runner.go:264: Waiting for containers in pod: test-server are ready
    assessment_runner.go:297: webserver service is available on cluster IP: <IP_ADDRESS>
    assessment_runner.go:301: Provision extra pod test-client
    assessment_helpers.go:393: Waiting for containers in pod: test-client are ready
=== RUN   TestLibvirtPodToServiceCommunication/TestExtraPods_test/Failed_to_test_extra_pod.
    assessment_runner.go:532: Output when execute test commands:command terminated with exit code 1
    assessment_runner.go:534: command terminated with exit code 1
=== NAME  TestLibvirtPodToServiceCommunication/TestExtraPods_test
    assessment_runner.go:617: Deleting pod test-server...
    assessment_runner.go:624: Pod test-server has been successfully deleted within 60s
    assessment_runner.go:630: Deleting pod test-client...
    assessment_runner.go:636: Pod test-client has been successfully deleted within 60s
    assessment_runner.go:652: Deleting Service... nginx-server
--- FAIL: TestLibvirtPodToServiceCommunication (250.30s)
    --- FAIL: TestLibvirtPodToServiceCommunication/TestExtraPods_test (250.30s)
        --- FAIL: TestLibvirtPodToServiceCommunication/TestExtraPods_test/Failed_to_test_extra_pod. (15.10s)
=== RUN   TestLibvirtPodsMTLSCommunication
=== RUN   TestLibvirtPodsMTLSCommunication/TestPodsMTLSCommunication_test
    assessment_runner.go:264: Waiting for containers in pod: mtls-server are ready
    assessment_runner.go:297: webserver service is available on cluster IP: <IP_ADDRESS>
    assessment_runner.go:301: Provision extra pod mtls-client
    assessment_helpers.go:393: Waiting for containers in pod: mtls-client are ready
=== RUN   TestLibvirtPodsMTLSCommunication/TestPodsMTLSCommunication_test/Pods_communication_with_mTLS
    assessment_runner.go:532: Output when execute test commands:command terminated with exit code 6
    assessment_runner.go:534: command terminated with exit code 6
=== NAME  TestLibvirtPodsMTLSCommunication/TestPodsMTLSCommunication_test
    assessment_runner.go:560: Deleting Configmap... nginx-conf
    assessment_runner.go:567: Deleting Secret... server-certs
    assessment_runner.go:586: Deleting extra Secret... curl-certs
    assessment_runner.go:617: Deleting pod mtls-server...
    assessment_runner.go:624: Pod mtls-server has been successfully deleted within 60s
    assessment_runner.go:630: Deleting pod mtls-client...
    assessment_runner.go:636: Pod mtls-client has been successfully deleted within 60s
    assessment_runner.go:652: Deleting Service... nginx-mtls
--- FAIL: TestLibvirtPodsMTLSCommunication (230.41s)
    --- FAIL: TestLibvirtPodsMTLSCommunication/TestPodsMTLSCommunication_test (230.41s)
        --- FAIL: TestLibvirtPodsMTLSCommunication/TestPodsMTLSCommunication_test/Pods_communication_with_mTLS (10.09s)
=== RUN   TestLibvirtKbsKeyRelease
    libvirt_test.go:113: Skipping kbs related test as kbs is not deployed
--- SKIP: TestLibvirtKbsKeyRelease (0.00s)
=== RUN   TestLibvirtRestrictivePolicyBlocksExec
=== RUN   TestLibvirtRestrictivePolicyBlocksExec/PodVMwithPolicyBlockingExec_test
    assessment_runner.go:264: Waiting for containers in pod: policy-exec-rejected are ready
=== RUN   TestLibvirtRestrictivePolicyBlocksExec/PodVMwithPolicyBlockingExec_test/Pod_which_blocks_Exec_Process
=== NAME  TestLibvirtRestrictivePolicyBlocksExec
    common_suite.go:639: Exec process was allowed: Internal error occurred: error executing command in container: cannot enter container fefd98401f1e1ee9a472a2d15be13844dbbd13c7c3e0a691d9159e7a4f701a9c, with err rpc error: code = PermissionDenied desc = "ExecProcessRequest is blocked by policy: ": unknown
=== NAME  TestLibvirtRestrictivePolicyBlocksExec/PodVMwithPolicyBlockingExec_test/Pod_which_blocks_Exec_Process
    assessment_runner.go:435: Output when execute test commands: Internal error occurred: error executing command in container: cannot enter container fefd98401f1e1ee9a472a2d15be13844dbbd13c7c3e0a691d9159e7a4f701a9c, with err rpc error: code = PermissionDenied desc = "ExecProcessRequest is blocked by policy: ": unknown
    assessment_runner.go:437: Command [ls] running in container busybox produced unexpected output on error: Internal error occurred: error executing command in container: cannot enter container fefd98401f1e1ee9a472a2d15be13844dbbd13c7c3e0a691d9159e7a4f701a9c, with err rpc error: code = PermissionDenied desc = "ExecProcessRequest is blocked by policy: ": unknown
=== NAME  TestLibvirtRestrictivePolicyBlocksExec/PodVMwithPolicyBlockingExec_test
    assessment_runner.go:617: Deleting pod policy-exec-rejected...
    assessment_runner.go:624: Pod policy-exec-rejected has been successfully deleted within 60s
--- FAIL: TestLibvirtRestrictivePolicyBlocksExec (105.10s)
    --- FAIL: TestLibvirtRestrictivePolicyBlocksExec/PodVMwithPolicyBlockingExec_test (105.10s)
        --- FAIL: TestLibvirtRestrictivePolicyBlocksExec/PodVMwithPolicyBlockingExec_test/Pod_which_blocks_Exec_Process (5.03s)
=== RUN   TestLibvirtPermissivePolicyAllowsExec
=== RUN   TestLibvirtPermissivePolicyAllowsExec/PodVMwithPermissivePolicy_test
    assessment_runner.go:264: Waiting for containers in pod: policy-all-allowed are ready
=== RUN   TestLibvirtPermissivePolicyAllowsExec/PodVMwithPermissivePolicy_test/Pod_which_allows_all_kata_agent_APIs
    assessment_runner.go:435: Output when execute test commands:
=== NAME  TestLibvirtPermissivePolicyAllowsExec/PodVMwithPermissivePolicy_test
    assessment_runner.go:617: Deleting pod policy-all-allowed...
    assessment_runner.go:624: Pod policy-all-allowed has been successfully deleted within 60s
--- PASS: TestLibvirtPermissivePolicyAllowsExec (105.14s)
    --- PASS: TestLibvirtPermissivePolicyAllowsExec/PodVMwithPermissivePolicy_test (105.13s)
        --- PASS: TestLibvirtPermissivePolicyAllowsExec/PodVMwithPermissivePolicy_test/Pod_which_allows_all_kata_agent_APIs (5.07s)
=== RUN   TestLibvirtCreatePeerPodWithAuthenticatedImageWithoutCredentials
    libvirt_test.go:152: Authenticated Image Name not exported
--- SKIP: TestLibvirtCreatePeerPodWithAuthenticatedImageWithoutCredentials (0.00s)
=== RUN   TestLibvirtCreatePeerPodWithAuthenticatedImageWithValidCredentials
    libvirt_test.go:161: Registry Credentials, or authenticated image name not exported
--- SKIP: TestLibvirtCreatePeerPodWithAuthenticatedImageWithValidCredentials (0.00s)

Cc: @littlejawa
Ok, I'm going over the tests that failed, starting with:
--- FAIL: TestLibvirtPodToServiceCommunication (250.30s)
    --- FAIL: TestLibvirtPodToServiceCommunication/TestExtraPods_test (250.30s)
        --- FAIL: TestLibvirtPodToServiceCommunication/TestExtraPods_test/Failed_to_test_extra_pod. (15.10s)

That test fails consistently with CRI-O, but passes with containerd.
The test (implemented here) checks that from within a podvm client it can access a service deployed in another podvm, accessing by the service's name. It sets up nginx on the podvm server, configure a nginx-server service, and finally tries to wget -O- "nginx-server from podvm client that should return nginx's welcome HTML page.
Below is how I can get the error message of wget (as the e2e test framework is given the full messages):
$ kubectl exec test-client -n coco-pp-e2e-test-2777a729 -- wget -O- nginx-
server
wget: bad address 'nginx-server'
command terminated with exit code 1

From test-client it can access the service as long as I pass the cluster IP:
$ kubectl exec test-client -n coco-pp-e2e-test-2777a729 -- wget -O- <IP_ADDRESS> | grep "Thank you for using nginx"
Connecting to <IP_ADDRESS> (<IP_ADDRESS>:80)
writing to stdout
-                    100% |********************************|   615  0:00:00 ETA
written to stdout
<p><em>Thank you for using nginx.</em></p>

Cc: @littlejawa
Ok, I'm going over the tests that failed, starting with:
--- FAIL: TestLibvirtPodToServiceCommunication (250.30s)
    --- FAIL: TestLibvirtPodToServiceCommunication/TestExtraPods_test (250.30s)
        --- FAIL: TestLibvirtPodToServiceCommunication/TestExtraPods_test/Failed_to_test_extra_pod. (15.10s)

That test fails consistently with CRI-O, but passes with containerd.
[...]

Hey @wainersm,
I've just tried here manually to make sure it's not plain broken, and I could see it work.
This is with OCP 4.16 and OSC 1.7, so definitely not the same test environment, but I wanted to make sure :)
Maybe something to do with the way we install/configure crio or the network plugins. I guess we're using kata-deploy here?
I'll need to build myself an environment similar to what we use in the CI job, so that I can dig further.

Cc: @littlejawa
Ok, I'm going over the tests that failed, starting with:
--- FAIL: TestLibvirtPodToServiceCommunication (250.30s)
    --- FAIL: TestLibvirtPodToServiceCommunication/TestExtraPods_test (250.30s)
        --- FAIL: TestLibvirtPodToServiceCommunication/TestExtraPods_test/Failed_to_test_extra_pod. (15.10s)

That test fails consistently with CRI-O, but passes with containerd.
[...]

Hey @wainersm, I've just tried here manually to make sure it's not plain broken, and I could see it work. This is with OCP 4.16 and OSC 1.7, so definitely not the same test environment, but I wanted to make sure :)

It's okay not same environment; indeed I was worried about it be a problem on OCP + OSC, I'm glad it's not the case :)

Maybe something to do with the way we install/configure crio or the network plugins. I guess we're using kata-deploy here? I'll need to build myself an environment similar to what we use in the CI job, so that I can dig further.

I talked with @littlejawa in pvt; it turns out that the same client/server test fails with cri-o + runc. So definitively it seems like a problem on the configuration of the kcli cluster but we still don't know what...
TestLibvirtPodsMTLSCommunication is also a client/server style test that relies on the service name, so I'm assuming it's the same root cause. Thus, I won't investigate that test further.
I need to figure out how to skip TestLibvirtPodToServiceCommunication and TestLibvirtPodsMTLSCommunication when CRI-O only. That's the plan for now.
Hey, thanks @littlejawa for promptly checking it!

I was looking at TestLibvirtCreatePeerPodContainerWithExternalIPAccess fail, it seems same root cause of TestLibvirtPodToServiceCommunication and TestLibvirtPodsMTLSCommunication.
The error is like:
$ kubectl exec pod/busybox-priv -n coco-pp-e2e-test-f7c5cc73 -- ping -c 1 www.google.com
ping: bad address 'www.google.com'
command terminated with exit code 1

Updates:

New commit to fix TestLibvirtRestrictivePolicyBlocksExec. Now passing.
Addressed all comments of @ldoktor
As well as @stevenhorsman 's

Tested with KBS=true, and TestLibvirtKbsKeyRelease is passing.

I've tried this out on a test VM - it doesn't seem to be working on s390x as the cc-operator-controller-manager doesn't start due to an CNI issue:
Events:
  Type     Reason                  Age   From               Message
  ----     ------                  ----  ----               -------
  Normal   Scheduled               98s   default-scheduler  Successfully assigned confidential-containers-system/cc-operator-controller-manager-6d6b78b7f5-qc8x2 to peer-pods-worker-0
  Warning  FailedCreatePodSandBox  97s   kubelet            Failed to create pod sandbox: rpc error: code = Unknown desc = failed to create pod network sandbox k8s_cc-operator-controller-manager-6d6b78b7f5-qc8x2_confidential-containers-system_44ca7518-3ab7-4b49-ab7e-0dc244787ce8_0(1bffd2367a0a8451eb22612389e914de79c98bbae11d0f9f42a2b65e95349286): error adding pod confidential-containers-system_cc-operator-controller-manager-6d6b78b7f5-qc8x2 to CNI network "cbr0": plugin type="flannel" failed (add): failed to set bridge addr: "cni0" already has an IP address different from <IP_ADDRESS>/24
  Warning  FailedCreatePodSandBox  71s   kubelet            Failed to create pod sandbox: rpc error: code = Unknown desc = failed to create pod network sandbox k8s_cc-operator-controller-manager-6d6b78b7f5-qc8x2_confidential-containers-system_44ca7518-3ab7-4b49-ab7e-0dc244787ce8_0(468f1b4438a944e52da37454488396a2d8a7742a59ddd151c19a224f03db558c): error adding pod confidential-containers-system_cc-operator-controller-manager-6d6b78b7f5-qc8x2 to CNI network "cbr0": plugin type="flannel" failed (add): failed to set bridge addr: "cni0" already has an IP address different from <IP_ADDRESS>/24

That might not be a fair test though, so I can try out x86

on x86 the TestLibvirtCreatePeerPodContainerWithExternalIPAccess, TestLibvirtPodsMTLSCommunication and TestLibvirtPodToServiceCommunication failed. TestLibvirtKbsKeyRelease/KbsKeyReleasePod_test also did. I'm not sure if it's worth digging into these too much before merging as some are skipped in the CI

I've tried this out on a test VM - it doesn't seem to be working on s390x as the cc-operator-controller-manager doesn't start due to an CNI issue:
Events:
  Type     Reason                  Age   From               Message
  ----     ------                  ----  ----               -------
  Normal   Scheduled               98s   default-scheduler  Successfully assigned confidential-containers-system/cc-operator-controller-manager-6d6b78b7f5-qc8x2 to peer-pods-worker-0
  Warning  FailedCreatePodSandBox  97s   kubelet            Failed to create pod sandbox: rpc error: code = Unknown desc = failed to create pod network sandbox k8s_cc-operator-controller-manager-6d6b78b7f5-qc8x2_confidential-containers-system_44ca7518-3ab7-4b49-ab7e-0dc244787ce8_0(1bffd2367a0a8451eb22612389e914de79c98bbae11d0f9f42a2b65e95349286): error adding pod confidential-containers-system_cc-operator-controller-manager-6d6b78b7f5-qc8x2 to CNI network "cbr0": plugin type="flannel" failed (add): failed to set bridge addr: "cni0" already has an IP address different from <IP_ADDRESS>/24
  Warning  FailedCreatePodSandBox  71s   kubelet            Failed to create pod sandbox: rpc error: code = Unknown desc = failed to create pod network sandbox k8s_cc-operator-controller-manager-6d6b78b7f5-qc8x2_confidential-containers-system_44ca7518-3ab7-4b49-ab7e-0dc244787ce8_0(468f1b4438a944e52da37454488396a2d8a7742a59ddd151c19a224f03db558c): error adding pod confidential-containers-system_cc-operator-controller-manager-6d6b78b7f5-qc8x2 to CNI network "cbr0": plugin type="flannel" failed (add): failed to set bridge addr: "cni0" already has an IP address different from <IP_ADDRESS>/24

That might not be a fair test though, so I can try out x86

hmmm... might it be a bug on kcli for s390x?

on x86 the TestLibvirtCreatePeerPodContainerWithExternalIPAccess, TestLibvirtPodsMTLSCommunication and TestLibvirtPodToServiceCommunication failed. TestLibvirtKbsKeyRelease/KbsKeyReleasePod_test also did. I'm not sure if it's worth digging into these too much before merging as some are skipped in the CI

As for TestLibvirtKbsKeyRelease, it passed here. First I ran with containerd to ensure I had everything proper set; deleted the cluster then re-ran the test with cri-o. The new job won't fail the containerd counterpart, so maybe we should merge to see who is right by CI? :)
@littlejawa has helped with debugging TestLibvirtCreatePeerPodContainerWithExternalIPAccess, TestLibvirtPodsMTLSCommunication and TestLibvirtPodToServiceCommunication when the time permits. That will take a time and as they are skipped in the CI, I think we can get this merged as is.
Side-note: I was looking for a way to skip these tests when not running on CI (i.e. locally) but I didn't find (yet) a good solution for the fact that from the tests, it cannot access the provision object so it cannot get access to the libvirt.properties, thus, not able to check whether is cri-o or containerd. I thought in query the k8s directly, but ran into another problem which is to get an k8s CLI object from the tests code too. I might be missing something so I plan to have a look at this again later.

I finally made it working as well, my problem was a bad podvm image :-) I'm getting failures only for:

TestLibvirtCreatePeerPodContainerWithExternalIPAccess
TestLibvirtPodToServiceCommunication
TestLibvirtPodsMTLSCommunication

the TestLibvirtRestrictivePolicyBlocksExec is passing on my laptop (tested without KBS)

Side-note: I was looking for a way to skip these tests when not running on CI (i.e. locally) but I didn't find (yet) a good solution for the fact that from the tests, it cannot access the provision object so it cannot get access to the libvirt.properties, thus, not able to check whether is cri-o or containerd. I thought in query the k8s directly, but ran into another problem which is to get an k8s CLI object from the tests code too. I might be missing something so I plan to have a look at this again later.

Pradipta added an isTestOnCrio() method, so can we just use that and then skip, or is it not working?

Hi @ldoktor !

I finally made it working as well, my problem was a bad podvm image :-) I'm getting failures only for:
* TestLibvirtCreatePeerPodContainerWithExternalIPAccess

* TestLibvirtPodToServiceCommunication

* TestLibvirtPodsMTLSCommunication

the TestLibvirtRestrictivePolicyBlocksExec is passing on my laptop (tested without KBS). I'd suggest creating issues for those and add skip there.

Thanks for testing it! I created the issue confidential-containers/cloud-api-adaptor#2100 as you suggested.

Side-note: I was looking for a way to skip these tests when not running on CI (i.e. locally) but I didn't find (yet) a good solution for the fact that from the tests, it cannot access the provision object so it cannot get access to the libvirt.properties, thus, not able to check whether is cri-o or containerd. I thought in query the k8s directly, but ran into another problem which is to get an k8s CLI object from the tests code too. I might be missing something so I plan to have a look at this again later.

Pradipta added an isTestOnCrio() method, so can we just use that and then skip, or is it not working?

hmm... I overlooked that function. Ok, I will use it to disable the tests on local runs. Thanks @stevenhorsman

Rebased the code and sent a new commit that disable those failing tests when CRI-O. With that the poor remaining tests are all passing. It's ready to be merged, if not more suggestions.

@wainersm - do you think we can rebase this and merge it now, or are you waiting for anything else?

pinging @wainersm again ;)

Hi @stevenhorsman @bpradipt !
I rebased it and resolved the conflicts. One issue arose since last time I tried it: webhook's cert-manager installation has failed.
In https://github.com/wainersm/cc-cloud-api-adaptor/actions/runs/12011685522/job/33484069022 :
2024-11-25T15:05:04.2264631Z time="2024-11-25T15:05:04Z" level=info msg="Error  in install cert-manager: exit status 2: make[1]: Entering directory '/home/runner/work/cc-cloud-api-adaptor/cc-cloud-api-adaptor/src/webhook'\ncurl -fsSL -o cmctl https://github.com/cert-manager/cmctl/releases/latest/download/cmctl_linux_amd64\nchmod +x cmctl\n# Deploy cert-manager\nkubectl apply -f https://github.com/jetstack/cert-manager/releases/download/v1.15.3/cert-manager.yaml\nnamespace/cert-manager created\ncustomresourcedefinition.apiextensions.k8s.io/certificaterequests.cert-manager.io created\ncustomresourcedefinition.apiextensions.k8s.io/certificates.cert-manager.io created\ncustomresourcedefinition.apiextensions.k8s.io/challenges.acme.cert-manager.io created\ncustomresourcedefinition.apiextensions.k8s.io/clusterissuers.cert-manager.io created\ncustomresourcedefinition.apiextensions.k8s.io/issuers.cert-manager.io created\ncustomresourcedefinition.apiextensions.k8s.io/orders.acme.cert-manager.io created\nserviceaccount/cert-manager-cainjector created\nserviceaccount/cert-manager created\nserviceaccount/cert-manager-webhook created\nclusterrole.rbac.authorization.k8s.io/cert-manager-cainjector created\nclusterrole.rbac.authorization.k8s.io/cert-manager-controller-issuers created\nclusterrole.rbac.authorization.k8s.io/cert-manager-controller-clusterissuers created\nclusterrole.rbac.authorization.k8s.io/cert-manager-controller-certificates created\nclusterrole.rbac.authorization.k8s.io/cert-manager-controller-orders created\nclusterrole.rbac.authorization.k8s.io/cert-manager-controller-challenges created\nclusterrole.rbac.authorization.k8s.io/cert-manager-controller-ingress-shim created\nclusterrole.rbac.authorization.k8s.io/cert-manager-cluster-view created\nclusterrole.rbac.authorization.k8s.io/cert-manager-view created\nclusterrole.rbac.authorization.k8s.io/cert-manager-edit created\nclusterrole.rbac.authorization.k8s.io/cert-manager-controller-approve:cert-manager-io created\nclusterrole.rbac.authorization.k8s.io/cert-manager-controller-certificatesigningrequests created\nclusterrole.rbac.authorization.k8s.io/cert-manager-webhook:subjectaccessreviews created\nclusterrolebinding.rbac.authorization.k8s.io/cert-manager-cainjector created\nclusterrolebinding.rbac.authorization.k8s.io/cert-manager-controller-issuers created\nclusterrolebinding.rbac.authorization.k8s.io/cert-manager-controller-clusterissuers created\nclusterrolebinding.rbac.authorization.k8s.io/cert-manager-controller-certificates created\nclusterrolebinding.rbac.authorization.k8s.io/cert-manager-controller-orders created\nclusterrolebinding.rbac.authorization.k8s.io/cert-manager-controller-challenges created\nclusterrolebinding.rbac.authorization.k8s.io/cert-manager-controller-ingress-shim created\nclusterrolebinding.rbac.authorization.k8s.io/cert-manager-controller-approve:cert-manager-io created\nclusterrolebinding.rbac.authorization.k8s.io/cert-manager-controller-certificatesigningrequests created\nclusterrolebinding.rbac.authorization.k8s.io/cert-manager-webhook:subjectaccessreviews created\nrole.rbac.authorization.k8s.io/cert-manager-cainjector:leaderelection created\nrole.rbac.authorization.k8s.io/cert-manager:leaderelection created\nrole.rbac.authorization.k8s.io/cert-manager-webhook:dynamic-serving created\nrolebinding.rbac.authorization.k8s.io/cert-manager-cainjector:leaderelection created\nrolebinding.rbac.authorization.k8s.io/cert-manager:leaderelection created\nrolebinding.rbac.authorization.k8s.io/cert-manager-webhook:dynamic-serving created\nservice/cert-manager created\nservice/cert-manager-webhook created\ndeployment.apps/cert-manager-cainjector created\ndeployment.apps/cert-manager created\ndeployment.apps/cert-manager-webhook created\nmutatingwebhookconfiguration.admissionregistration.k8s.io/cert-manager-webhook created\nvalidatingwebhookconfiguration.admissionregistration.k8s.io/cert-manager-webhook created\n# Wait for service to be up\nkubectl wait --timeout=90s -n cert-manager endpoints/cert-manager --for=jsonpath='{.subsets[0].addresses[0].ip}'\nendpoints/cert-manager condition met\nkubectl wait --timeout=90s -n cert-manager endpoints/cert-manager-webhook --for=jsonpath='{.subsets[0].addresses[0].ip}'\nendpoints/cert-manager-webhook condition met\n# Wait for few seconds for the cert-manager API to be ready\n# otherwise you'll hit the error \"x509: certificate signed by unknown authority\"\n# Best is to use cmctl - https://cert-manager.io/docs/installation/kubectl/#2-optional-wait-for-cert-manager-webhook-to-be-ready\n./cmctl check api --wait=2m\nError from server (InternalError): Internal error occurred: failed calling webhook \"webhook.cert-manager.io\": failed to call webhook: Post \"https://cert-manager-webhook.cert-manager.svc:443/validate?timeout=30s\": dial tcp <IP_ADDRESS>:443: connect: no route to host\nmake[1]: *** [Makefile:137: deploy-cert-manager] Error 124\nmake[1]: Leaving directory '/home/runner/work/cc-cloud-api-adaptor/cc-cloud-api-adaptor/src/webhook'\n"
2024-11-25T15:05:04.2321654Z F1125 15:05:04.222490   18284 env.go:369] Setup failure: exit status 2

I suspect it's some misconfiguration on kcli with cri-o. I will be reporting to kcli and let you posted.

Hi @stevenhorsman @bpradipt !
I rebased it and resolved the conflicts. One issue arose since last time I tried it: webhook's cert-manager installation has failed.
In https://github.com/wainersm/cc-cloud-api-adaptor/actions/runs/12011685522/job/33484069022 :
2024-11-25T15:05:04.2264631Z time="2024-11-25T15:05:04Z" level=info msg="Error  in install cert-manager: exit status 2: make[1]: Entering directory '/home/runner/work/cc-cloud-api-adaptor/cc-cloud-api-adaptor/src/webhook'\ncurl -fsSL -o cmctl https://github.com/cert-manager/cmctl/releases/latest/download/cmctl_linux_amd64\nchmod +x cmctl\n# Deploy cert-manager\nkubectl apply -f https://github.com/jetstack/cert-manager/releases/download/v1.15.3/cert-manager.yaml\nnamespace/cert-manager created\ncustomresourcedefinition.apiextensions.k8s.io/certificaterequests.cert-manager.io created\ncustomresourcedefinition.apiextensions.k8s.io/certificates.cert-manager.io created\ncustomresourcedefinition.apiextensions.k8s.io/challenges.acme.cert-manager.io created\ncustomresourcedefinition.apiextensions.k8s.io/clusterissuers.cert-manager.io created\ncustomresourcedefinition.apiextensions.k8s.io/issuers.cert-manager.io created\ncustomresourcedefinition.apiextensions.k8s.io/orders.acme.cert-manager.io created\nserviceaccount/cert-manager-cainjector created\nserviceaccount/cert-manager created\nserviceaccount/cert-manager-webhook created\nclusterrole.rbac.authorization.k8s.io/cert-manager-cainjector created\nclusterrole.rbac.authorization.k8s.io/cert-manager-controller-issuers created\nclusterrole.rbac.authorization.k8s.io/cert-manager-controller-clusterissuers created\nclusterrole.rbac.authorization.k8s.io/cert-manager-controller-certificates created\nclusterrole.rbac.authorization.k8s.io/cert-manager-controller-orders created\nclusterrole.rbac.authorization.k8s.io/cert-manager-controller-challenges created\nclusterrole.rbac.authorization.k8s.io/cert-manager-controller-ingress-shim created\nclusterrole.rbac.authorization.k8s.io/cert-manager-cluster-view created\nclusterrole.rbac.authorization.k8s.io/cert-manager-view created\nclusterrole.rbac.authorization.k8s.io/cert-manager-edit created\nclusterrole.rbac.authorization.k8s.io/cert-manager-controller-approve:cert-manager-io created\nclusterrole.rbac.authorization.k8s.io/cert-manager-controller-certificatesigningrequests created\nclusterrole.rbac.authorization.k8s.io/cert-manager-webhook:subjectaccessreviews created\nclusterrolebinding.rbac.authorization.k8s.io/cert-manager-cainjector created\nclusterrolebinding.rbac.authorization.k8s.io/cert-manager-controller-issuers created\nclusterrolebinding.rbac.authorization.k8s.io/cert-manager-controller-clusterissuers created\nclusterrolebinding.rbac.authorization.k8s.io/cert-manager-controller-certificates created\nclusterrolebinding.rbac.authorization.k8s.io/cert-manager-controller-orders created\nclusterrolebinding.rbac.authorization.k8s.io/cert-manager-controller-challenges created\nclusterrolebinding.rbac.authorization.k8s.io/cert-manager-controller-ingress-shim created\nclusterrolebinding.rbac.authorization.k8s.io/cert-manager-controller-approve:cert-manager-io created\nclusterrolebinding.rbac.authorization.k8s.io/cert-manager-controller-certificatesigningrequests created\nclusterrolebinding.rbac.authorization.k8s.io/cert-manager-webhook:subjectaccessreviews created\nrole.rbac.authorization.k8s.io/cert-manager-cainjector:leaderelection created\nrole.rbac.authorization.k8s.io/cert-manager:leaderelection created\nrole.rbac.authorization.k8s.io/cert-manager-webhook:dynamic-serving created\nrolebinding.rbac.authorization.k8s.io/cert-manager-cainjector:leaderelection created\nrolebinding.rbac.authorization.k8s.io/cert-manager:leaderelection created\nrolebinding.rbac.authorization.k8s.io/cert-manager-webhook:dynamic-serving created\nservice/cert-manager created\nservice/cert-manager-webhook created\ndeployment.apps/cert-manager-cainjector created\ndeployment.apps/cert-manager created\ndeployment.apps/cert-manager-webhook created\nmutatingwebhookconfiguration.admissionregistration.k8s.io/cert-manager-webhook created\nvalidatingwebhookconfiguration.admissionregistration.k8s.io/cert-manager-webhook created\n# Wait for service to be up\nkubectl wait --timeout=90s -n cert-manager endpoints/cert-manager --for=jsonpath='{.subsets[0].addresses[0].ip}'\nendpoints/cert-manager condition met\nkubectl wait --timeout=90s -n cert-manager endpoints/cert-manager-webhook --for=jsonpath='{.subsets[0].addresses[0].ip}'\nendpoints/cert-manager-webhook condition met\n# Wait for few seconds for the cert-manager API to be ready\n# otherwise you'll hit the error \"x509: certificate signed by unknown authority\"\n# Best is to use cmctl - https://cert-manager.io/docs/installation/kubectl/#2-optional-wait-for-cert-manager-webhook-to-be-ready\n./cmctl check api --wait=2m\nError from server (InternalError): Internal error occurred: failed calling webhook \"webhook.cert-manager.io\": failed to call webhook: Post \"https://cert-manager-webhook.cert-manager.svc:443/validate?timeout=30s\": dial tcp <IP_ADDRESS>:443: connect: no route to host\nmake[1]: *** [Makefile:137: deploy-cert-manager] Error 124\nmake[1]: Leaving directory '/home/runner/work/cc-cloud-api-adaptor/cc-cloud-api-adaptor/src/webhook'\n"
2024-11-25T15:05:04.2321654Z F1125 15:05:04.222490   18284 env.go:369] Setup failure: exit status 2

I suspect it's some misconfiguration on kcli with cri-o. I will be reporting to kcli and let you posted.

ok, problem was reported in https://github.com/karmab/kcli/issues/744
I figured flannel+crio seems to lack some configuration for networking services, I don't know exactly what's the problem. I tried calico then cilium; the later worked out (i.e. cert-manager installed successfully). Hence, I added a conditional to kcli_cluster.sh to instruct kcli to configure the cluster with cilium if cri-o.
I'v run a couple of times before end up with a green execution. For the records:

https://github.com/wainersm/cc-cloud-api-adaptor/actions/runs/12040569338/job/33571256092:

=== RUN   TestLibvirtImageDecryption/TestImageDecryption_test
    assessment_runner.go:274: timed out waiting for the condition
--- FAIL: TestLibvirtImageDecryption (600.27s)
    --- FAIL: TestLibvirtImageDecryption/TestImageDecryption_test (600.03s)

https://github.com/wainersm/cc-cloud-api-adaptor/actions/runs/12040569338/job/33574620944 :

=== RUN   TestLibvirtCreatePeerPodWithJob/JobPeerPod_test/Job_has_been_created
--- FAIL: TestLibvirtCreatePeerPodWithJob (600.02s)
    --- FAIL: TestLibvirtCreatePeerPodWithJob/JobPeerPod_test (600.02s)
        --- FAIL: TestLibvirtCreatePeerPodWithJob/JobPeerPod_test/Job_has_been_created (0.00s)
panic: runtime error: invalid memory address or nil pointer dereference [recovered]
	panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x8 pc=0x24900f2]

https://github.com/wainersm/cc-cloud-api-adaptor/actions/runs/12040569338/job/33575565872:

=== RUN   TestLibvirtImageDecryption/TestImageDecryption_test
    assessment_runner.go:274: timed out waiting for the condition
--- FAIL: TestLibvirtImageDecryption (600.27s)
    --- FAIL: TestLibvirtImageDecryption/TestImageDecryption_test (600.03s)

I think it's now ready to be merged if the approvals stand. But I will keep it on 'hold' until the 0.11 release is out.

I think it's now ready to be merged if the approvals stand. But I will keep it on 'hold' until the 0.11 release is out.

I will also wait on https://github.com/confidential-containers/cloud-api-adaptor/pull/2019 be merged first. Then I can resolve any conflict.

Rebased & resolved conflicts only. I tested on my fork in https://github.com/wainersm/cc-cloud-api-adaptor/actions/runs/12166242896/job/33932711190 (PASS). It is using the packer built podvm image, at some point we should switch to mkosi as discussed on the meeting today.


Update MD file on new branch 2017-32-10_03-12-41

:white_check_mark: Validation status: passed

File
Status
Preview URL
Details

split/updateTestRef.md
:white_check_mark:Succeeded

For more details, please refer to the build report.
Note: If you changed an existing file name or deleted a file, broken links in other files to the deleted or renamed file are listed only in the full build report.


Cannot call method "indexOf" of undefined on any DB error

Getting the error "Cannot call method "indexOf" of undefined" for any error. It apparently fails to execute err.stack.indexOf where err.stack is not set.
"Cannot call method "indexOf" of undefined": TypeError: Cannot call method "indexOf" of undefined at /node_modules/rds/node_modules/mysql/lib/protocol/sequences/Sequence.js:63 at /node_modules/rds/node_modules/mysql/lib/protocol/sequences/Sequence.js:78 at /node_modules/rds/node_modules/mysql/lib/protocol/sequences/Query.js:94 at /node_modules/rds/node_modules/mysql/lib/protocol/Protocol.js:274 at /node_modules/rds/node_modules/mysql/lib/protocol/Parser.js:77 at /node_modules/rds/node_modules/mysql/lib/protocol/Protocol.js:39 at write (_stream_readable.js:601) at flow (_stream_readable.js:610) at pipeOnReadable (_stream_r
When I printed the error packet: {"fieldCount":255,"errno":1062,"sqlStateMarker":"#","sqlState":"23000","message":"Duplicate entry 'xxxxxx' for key 'xxxxxx'"}

Hi! Unfortunately I don't seem to be able to reproduce. Is there a way you could put together a very simple file that, when I run it, produces the error above?

Hi,
The issue seems to be because of different Javascript engine being used.
We are using rhino and that apparently does not seem to add 'stack' when
you do 'new Error()'.  It seems it is v8's feature.  So in Sequence.js,
in _addLongStackTrace() it fails on the following line, because err.stack
is undefined:
if (err.stack.indexOf(delimiter) > -1) {
return;
}
Would it be possible to add a check whether err.stack exists?
Thanks & Regards,
Muthu
On Thu, Aug 13, 2015 at 7:51 PM, Douglas Christopher Wilson <
<EMAIL_ADDRESS>wrote:

Hi! Unfortunately I don't seem to be able to reproduce. Is there a way you
could put together a very simple file that, when I run it, produces the
error above?
—
Reply to this email directly or view it on GitHub
https://github.com/felixge/node-mysql/issues/1179#issuecomment-130693766
.

Ah, I see. This library has various issues with Rhino in general, and only fully functions in Node.js (v8). Adding this would get you past this issue, but not others. Can you run our entire test suite in Rhino and validate what does and doesn't work before we make any effort to support Rhino?

Here is a link to the issue in Rhino regarding new Error().stack, if it help as well: https://github.com/mozilla/rhino/issues/153


Readiness probe

I've made 1 more force-push to make the test less confusing. The "fake" osbuild-composer now returns:
fmt.Fprint(w, "{\"version\":\"fake\"}")

which does not have any impact given that I don't even check the body of the response, but I use a request to /version endpoint so this makes more sense.

Thanks, looks good!


Automatically reconnect over WS on ethernet disconnect

Trying to figure out how to reconnect to WS, when ethernet connection goes down (physical disconnect, server restart, etc.)

HI @ivanjermakov,
You could reconnect in onClose callback, I used something similar here


Simple Request for new library

Hi, I'm Vincenzo and I'm new to arduino word.
In my first job with Arduino I used your Modbus Slave RTU library and it is truly exceptional, simple and effective; compliments.
I have to implement the ModBus TCP slave communication and I found your library for ESP32, but unfortunately I can't adapt it for arduino with ethernet (actually I use Teensy 4.1 with "NativeEthernet.h" but it is similar to arduino "Ethernet.h") . Could you help me?
I tried to search on the internet for other libraries (for example "ArduinoModbus.h") but in my opinion they are too complicated, especially as regards the data management of the Modbus server. You in your libraries ask that there are dedicated functions for each modbus function and so it is simple and intuitive to analyze / update the data.
Thanks in advance
PS: sorry for my elementary english

Same situation here...
I have an application developed with ModbusSlave over serial RS485
I need to adapt this to ModbusSlaveTCP on a MEGA with an Ethernet shield v2
with the W5500
My understanding is that the current incarnation of ModbusSlaveTCP is
targeted for / dependent on ESP32.
My question is how to best to substitute the current Ethernet.h support
for the ESP32 specific support


WebRTC Support

Using gstreamer because it seems that's mandatory even if you use a more lightweight WebRTC signalling library. For WebRTC, needs the gst-plugins-rs package. Test program in make test/gstreamer shows a PNG at http://localhost:4273/gst-image/.

[X] basic gstreamer playback into images on DB
[x] start a gst-webrtc-signalling-server instance
[ ] figure out what happens when a stream fails to start or ends

does it just silently retry until it starts working (again)? tie into folk's error system somehow?
could use some help with this

[x] vendor the gstwebrtc-api JS bundle and implement a web route that allows streaming

stretch goals:

[ ] gstreamer seeking (for non-live streams)?
[ ] gstreamer publishing (or specifically webrtc publishing)

of a region?

[ ] replace a big chunck of camera.folk with gstreamer

uridecodebin uri=v4l2:///dev/video0 has strong screen tearing for me, need to investigate

Hello @s-ol
I wanted to try this out, and when I do make test/gstreamer.tcl I get:
Warning: Unable to generate getter for `pipeline_t pipeline`: Unrecognized rtype GstElement
Warning: Unable to generate getter for `pipeline_t sink`: Unrecognized rtype GstElement
Warning: Unable to generate getter for `pipeline_t bus`: Unrecognized rtype GstBus
DEBUG(cflags): -I/usr/include/tcl8.6 -ltcl8.6 -I/usr/include/gstreamer-1.0 -I/usr/include/glib-2.0 -I/usr/lib/x86_64-linux-gnu/glib-2.0/include -pthread -I/usr/include/x86_64-linux-gnu -lgstreamer-1.0 -lgobject-2.0 -lglib-2.0
gstreamer-1: Error in match m1:0: couldn't load file "/tmp/cfile_Vzy94y.so": /tmp/cfile_Vzy94y.so: undefined symbol: gst_sample_get_caps
couldn't load file "/tmp/cfile_Vzy94y.so": /tmp/cfile_Vzy94y.so: undefined symbol: gst_sample_get_caps
    while executing
"load [file rootname $cfile][info sharedlibextension] cfile"
    (procedure "::Pipeline::c9::compile" line 34)

(Note that I'm printing the value of $cflags just before the compile step to see if everything looks right)
These problems may be related, but not sure how to proceed:

I don't know what to do about Warning: Unable to generate getter for ...

It also looks like there is a linking issue: I have the right gstreamer library, but the object file doesn't have that dependency somehow:

nm -D /usr/lib/x86_64-linux-gnu/libgstreamer-1.0.so | grep gst_sample_get_caps
00000000000acbd0 T gst_sample_get_caps

ldd /tmp/cfile_Vzy94y.so
	linux-vdso.so.1 (0x00007ffe2268f000)
	libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x0000705ed9600000)
	/lib64/ld-linux-x86-64.so.2 (0x0000705ed9944000)

Any ideas?

hey @berkan!

The rtype warnings are unrelated, probably could be avoided somehow but are safe to ignore.

The library was supposed to be included via -l switch in cflags in this line:
cc cflags {*}[exec pkg-config --cflags --libs gstreamer-1.0]

This was the best way I found for making this portable across ArchLinux and Ubuntu in my testing, but folk has also changed since. I immediately have two hypotheses: either cflags is not applied to the linking phase (maybe change to the c interface?) or your pkg-config doesn't produce linking switches (no idea why that would be).
In any case you can probably use some variation of c loadLib / c loadLibLd to explicitly load the library as a workaround.


⚠ PrivateHD has degraded performance

In 3d4b447, PrivateHD ($PHD) experienced degraded performance:

HTTP code: 200
Response time: 1780 ms

Resolved: PrivateHD performance has improved in 0eb61b9.


Added support for projective warp via full homogeneous coordinates.

I needed the ability to learn projective warping for my project so I'm giving back to help others (as I haven't found another implementation that offers more than affine transforms).
This adds support for full 3x3 transform matrices but still supports the old 2x3 matrices through the same API by padding any remaining parameters with the identity matrix.
I've also updated the readme to reflect the changes, feel free to reject/edit these.

@robotrory hey Rory, thanks for taking the time :) I'll take a look over the weekend. Cheers

Hi @kevinzakka , thank you for the contribution. I was wondering if this pull request has been reviewed. It would be a good addition since even I could not find any other implementation like @robotrory mentioned.


Allowing other extensions in file upload

Hey, I've a snippet with a singleton files field and I wonder how can I allow to upload other extensions beside rtf pdf office txt (which is default) !?
thanks!

Closing this and opening #193 to track progress of adding this into apostrophe-files in the unstable branch.

I wrote a nice HOWTO for this that doesn't require you to restate all the
existing settings:
http://apostrophenow.org/howtos/adding-file-types-in-the-media-library.html
On Fri, Feb 20, 2015 at 5:32 PM, benirose<EMAIL_ADDRESS>wrote:

Closing this and opening #193
https://github.com/punkave/apostrophe/issues/193 to track progress of
adding this into apostrophe-files in the unstable branch.
—
Reply to this email directly or view it on GitHub
https://github.com/punkave/apostrophe/issues/145#issuecomment-75331923.

--
*THOMAS BOUTELL, *DEV & OPS
P'UNK AVENUE |<PHONE_NUMBER>  |  punkave.com

Thanks Tom! Your note at the bottom of the HOWTO might not be applicable any longer, and definitely isn't future proof: https://developer.mozilla.org/en-US/docs/Web/HTML/Element/img
Scroll down to "Supported image formats". However, the ones we support are known to be supported in all browsers.

Yeah, you could tweak the language if you like to indicate it doesn't make
sense to add a format unless it is supported in all browsers, and leave
it at that.
On Mon, Feb 23, 2015 at 3:41 PM, benirose<EMAIL_ADDRESS>wrote:

Thanks Tom! Your note at the bottom of the HOWTO might not be applicable
any longer, and definitely isn't future proof:
https://developer.mozilla.org/en-US/docs/Web/HTML/Element/img
Scroll down to "Supported image formats". However, the ones we support are
known to be supported in all browsers.
—
Reply to this email directly or view it on GitHub
https://github.com/punkave/apostrophe/issues/145#issuecomment-75627187.

--
*THOMAS BOUTELL, *DEV & OPS
P'UNK AVENUE |<PHONE_NUMBER>  |  punkave.com

Ya that makes sense.


OfflineAudioContext

https://developer.mozilla.org/en-US/docs/Web/API/OfflineAudioContext

Looks like this is now covered by MDN data:
https://caniuse.com/mdn-api_offlineaudiocontext
(via mdn/browser-compat-data#551)


workflows:pin node versions to lts

Seems like I spoke too early. Let’s cut it at v20+ and cut a major then.


Add new issue template

@deepak2431 Can I work on this?

@nimishgo Sure, have a go.

@deepak2431 What's the status? Shall I work on this?

@Sai-Adarsh Until it's open you can work on this.

@nimishgo @Sai-Adarsh Are you working on this? As this issue won't require more than 1 days I think.


Configurable project-wide and global-wide default values

Godot has a default value for every option, but I didn't see any way to configure it. It would be veeeery useful if we had a way to specify custom defaults for the whole project or even all projects.
For example, I'm making a game where grid is always 30x30. That project has lots of scenes and every single time I edit a new scene, I need to specify the grid, because default is 10x10. It's terribly annoying and if I could just make the 30x30 grid default for the project, that would be nice.
Another example is default script template. You just need to set it once per project, but I tend to start many projects, be it prototypes, or sandboxes for weird stuff. And whenever I create a new script, I have to remember to change the template, because default one is full of garbage comments (XD). Well, unlike previous example, this is more disposable "QoL" thing, but it's frustrating when I create a wrong script again... and again :/
Anyways, you see the point. Other case where I needed these was animation snaps, which I always set to 1. So maybe there's some way to make it universal, e.g. a shortcut key for every editor control to override its default.
And going further, it's a bit related to #21052. The defaults could be configurable for nodes and things like signal method names (I never use the default name, but e.g. generic on_collide() for collisions) and probably more.

The grid issue (which was the one made me post this) is fixed, i.e. when creating new scene the grid is somehow "inherited" by default, so it's ok now.
Other examples are minor things and creating such (likely) complex system just for this is not worth it IMO.


[WIP] Implemented ITypeCatalog and IAssemblyCatalog

This is meant to be a pre-requisite for the instance based scanning (#1846) change that we want to replace the AppDomainAssemblyTypeScanner

Adds ITypeCatalog and the ´DefaultTypeCatalog`. This default implementation uses a cache internally because once Nancy is booted up, it should be treated as immutable anyway.
Adds IAssemblyCatalog and the AppDomainAssemblyCatalog. This implementation mimics a lot of the assembly functionality in AppDomainAssemblyTypeScanner by means of ensuring that Nancy referencing assemblies are loaded and it looks the bin paths for it.
Replaces ScanMode with a strategy based approach. The strategy is defined by the TypeResolveStrategy delegate and there are implementations, in TypeResolveStrategies that represent the ScanMode members. This is a better approach because you can add strategies if you need them in your Nancy application.
Includes ITypeCatalogExtension which adds a couple of ITypeCatalog.GetTypesAssignableTo overloads which uses TypeResolveStrategies.All

Discussion point
The AppDomainAssemblyCatalog only scans over

Nancy assembly,
Any Nancy referencing assemblies
Ignored Nancy.Testing assembly

But has no means of letting someone bring more assemblies to its attention.  However I think this design is bad and needs a bit of rethinking. In my opinion, these should be no runtime modification of this catalog, because most parts of Nancy is unable to react to the changes and make use of the new types anyway.
So I thought about adding something like
public virtual IEnumerable<string> AddtionalAssembliesToScan()
{
   return Enumerable.Empty<string>();
}

To the AppDomainAssemblyTypeScanner implementation. So if you wanted to include more assemblies, you would simply derive a new class, override AddtionalAssembliesToScan (naming suggestions are welcome!) and tell Nancy to use this assembly catalog instead.
I thought about adding it as a ctor overload instead, but it just gets ugly quick. Supporting both is not something I would like to do.
Thoughts?

Add in what youve done with the ability to add extra assemblies due to the shit .net linker

@jchannon I really did try to make sense of what you said, but I failed :D

get rid of AppDomainAssemblyTypeScanner but make AddtionalAssembliesToScan  visible somewhere

@jchannon oh you're saying that the virtual member is a good approach? =D

My thinking around this was to have strategies for assembly loading / discovery and scanning of the types, so no virtual property needed, then we ship some defaults in the box, including the "things referencing Nancy" one.

@grumpydev so break out the IsNancyReferencingAssembly method into a strategy, keep EnsureNancyReferencingAssembliesAreLoaded in the class and perhaps add some per-strategy caching ?

Had a quick chat with @grumpydev and we came up with the idea that it might be a good idea to create a base class for IAssemblyCatalog that takes care of caching and strategy application. It would have a virtual GetAvailableAssemblies method on it that you would implement. For .NET Framework it would get them from the app domain, while on Core it would use the LibraryManager

Implemented AssemblyCatalogBase and updated AppDomainAssemblyCatalog to inherit from it


Repair wallet looks like it is not including fully spent tx

If you do a repair wallet tx that are fully spent are not appearing.
This may very well be a design choice in bitcoinj to avoid wallet bloat.

Haven't seen this in the last month or more. Closing.


executor: optimize NestedLoopJoin's memory usage

https://github.com/risinglightdb/risinglight/blob/7c5e0d5193708c50b14c98f3efdddfcefbe445cd/src/executor/nested_loop_join.rs#L26-L32
Currently, NLJ will pull all data into memory before start processing data. This would make memory usage high.
Optimally, NLJ should work like...
for chunk in left {
  for chunk in right {
    // process chunk
  }
}

However, this requires us to support restarting a child executor (restart the right child), which is not possible in our system. Therefore, for the first step, we'd like to optimize NLJ like...
let bufferred_left = pull all data from left side
for chunk in right {
  for chunk in bufferred_left {
    // process chunk
  }
}

hello, may i try this?

I have a question about this. Now, NLJ is waiting for enough row(one DataChunk) to eval and filter(this is deferred),
but when one right_chunk is obtained from right_child, it must be processed immediately(right outer join).

I have a question about this. Now, NLJ is waiting for enough row(one DataChunk) to eval and filter(this is deferred),
but when one right_chunk is obtained from right_child, it must be processed immediately(right outer join).
Maybe should hold a HashMap to record the right_row's state(Whether there is a match left_row)?

I think for the first step, we can choose to support join of only one direction (either left join or right join)? The optimizer can rewrite left join to a right join, and back forth.

we can choose to support join of only one direction (either left join or right join)

this is easy work, but maybe the optimizer is hard work( how to support full outer join and multi-table join)?
Is it necessary to complete the optimizer part before continuing this issue or synchronization?

how to support full outer join and multi-table join

I think we can have some regression in tests (maybe we need to disable some of the test cases in https://github.com/risinglightdb/risinglight/blob/main/tests/sql/join.slt)? Just took a look at the current plan, it seems that for outer join and right outer join, optimizer will always choose NLJ. Therefore, we can disable some test cases in join.slt.

Is it necessary to complete the optimizer part before continuing this issue or synchronization?

I think we can optimize NLJ's memory usage first, and support only inner and left outer join. Some fun facts: SQLServer's NLJ also doesn't support full outer join and right outer join...
For the next step, we can add full outer join support to HashJoin, and enable the optimizer to rewrite right outer join to left outer join in NLJ, so as to enable all test cases again. So after all these have been done, we will require at least one equal condition in full outer joins, and the NLJ will only need to support inner join and left outer join.
Does this sound good? Also thanks for your contribution!

This sound good!

Sounds good!


Passport does not get shown after adding stamp

I just added a stamp and after this only a black screen gets shown, in the browser console I get the following error:
Uncaught TypeError: Cannot read properties of undefined (reading '4')
    at Stamp (Stamp.tsx:25:42)

resolved


Feature request: Add a progress indicator

It would be nice to know how far along things are when uploading assets with a release.
I ended up staring at the screen for a while with fingers crossed...

This one looked kinda cool https://github.com/gagle/node-status-bar
I could maybe try to add that.

Sounds good, PR welcome if I don't get to it first!

@zeke I invited you as a collaborator (open open source rules) -- feel free to improve this module as you see fit (same goes for @bcomnes who is already a collaborator). 😁

Forgot to mention the assets stuff is managed by a separate module made by fellow collaborator @paulcpederson -- https://github.com/paulcpederson/gh-release-assets

Maybe hypermodules?

👍

Took a quick look:

gh-release-assets also emits the following events:

upload-asset - {name} - Emits before an asset file starts uploading. Emits the name of the file.
upload-progress - {name, progress} - Emits while a file is uploading. Emits the name of the file, and a progress object from progress-stream.
uploaded-asset - {name} - Emits after an asset file is successfully uploaded. Emits the name of the file.

Should be pretty easy to add handlers to these events (see https://github.com/paulcpederson/gh-release-assets/blob/ab4e6d5dcf16ee124aef77276b3b7a2c4a06a5e3/test/index.js#L53-L61 for example)

Hey @bcomnes or @ungoldman can you add me to the hypermodules org? 🙏

Oh yeah definately

Sent

Will take this on when I get some free time, should be a nice enhancement!

Did a bit of research on this over the weekend, it looks like using something like gauge or cli-progress would be easiest as it allows you to easily update the progress bar without needing to use a stream (which node-status-bar needs).  gauge looks to be really easy to use, and it's used by npm itself, so it might be nice to go with that.  Anyone have any other thoughts or ideas on this?  If not, I should be able to get a PR for this sometime this week 😃

👌

Stream progress bars are difficult without knowing the total size of the stream operation in advance.  I've been brainstorming a folder-walker with progress lookahead for folder walking based operations.  Haven't had time yet though.

@tjaneczko gauge looks fine, let's go with that

Unfortunately I've been super busy these past couple of weeks and haven't had a chance to finish this up yet, but I should hopefully have a PR ready soon!

@tjaneczko story of my life 😉

Finally was able to get some free time and got this working in PR #80 .  Looks really slick when uploading multiple assets or large assets :smile:

Resolved in #80, released in 3.4.0. Thanks @tjaneczko!


CI hasn't been run

Describe the Bug
The homepage of the rustwasm.github.io still shows version 0.10.0 (while 0.10.3 is the latest) as the latest and hasn't been updated since 9th of July 2021
Also, no github action seems to be triggered to update the website

@daxpedda It looks like the Github Action for this repo builds & deploys the (currently outdated) release guides from the most recent tagged commits of https://github.com/rustwasm/wasm-pack & https://github.com/rustwasm/wasm-bindgen.  I ran the tag command git describe --abbrev=0 --tags in those repos, and the tags match the releases on crates.io.
Do you have access to Github Settings in this repo?  If you can reenable Actions and kick one off manually, I think that might be enough to update the website.  Or if there are errors in the GH Action, I'll take a look at those.

I see, thank you!

Do you have access to Github Settings in this repo?

I don't, but I've requested it.

I did restart the CI and fixed the GitHub Actions used, but there seems to be some other issue with Ruby:
https://github.com/rustwasm/rustwasm.github.io/actions/runs/7857911355/job/21442294826

continued in https://github.com/rustwasm/rustwasm.github.io/pull/62

That seems to have worked, thank you very much!


Increase golangci-lint timeout

I'm increasingly running into golangci-lint timeouts; increasing it to
10 minute would avoid these.
Signed-off-by: Stephen Kitt<EMAIL_ADDRESS>

It would be better to also increase it here: https://github.com/submariner-io/shipyard/blob/master/Makefile.inc#L47

It would be better to also increase it here: https://github.com/submariner-io/shipyard/blob/master/Makefile.inc#L47

Indeed, done! (I’ll leave the clean-up for another PR.)


add shortlink to backcompat classes

Discussed in snarfed/bridgy#173
And based on http://microformats.org/wiki/rel-shortlink#Abstract
we should add rel=shortlink like rel=bookmark to the hentry-scoped rel-properties, and also backcompat support for interpreting class=shortlink as class=u-shortlink.

snarfed/bridgy#173

oops, sorry, thank you for catching

Neither http://microformats.org/wiki/h-entry#Backward_Compatibility nor http://microformats.org/wiki/rel-shortlink defines any backcompat parsing for rel-shortlink

I am going to close this issue since it has been inactive for a long period of time without discussion. If this issue is still relevant, feel free to re-open it and we can continue discussing it. Thanks!


Tdr 319 keycloak realm import

Requires PR: https://github.com/nationalarchives/tdr-configurations/pull/11

Looks like the Jenkins build is failing:
cp: cannot stat 'tdr-configurations/keycloak/tdr-realm-export.json': No such file or directory


fix: old unique constraint remnance

SUMMARY
closes https://github.com/apache/incubator-superset/issues/8871
When constraints names aren't defined in sqlalchemy/alembic, they are non-deterministic, and it makes it hard/impossible to delete them in subsequent migrations. Here a bad constraint was created originally without a name, and some other migration tries to re-create it, and may fail on a subset of database engines. Also I think sqlite doesn't support constraint making the whole thing more of a headache.
I decided to go back to the first migration and prevent the constraint to be created in the first place. Try to delete the constraint in the subsequent migrations, and finally create the appropriate one.
TODO: We should squash [at least a subset of] migrations eventually.

Codecov Report

Merging #9882 into master will decrease coverage by 11.80%.
The diff coverage is n/a.

@@             Coverage Diff             @@
##           master    #9882       +/-   ##
===========================================
- Coverage   71.24%   59.44%   -11.81%
===========================================
  Files         584      400      -184
  Lines       30790    12717    -18073
  Branches     3238     3142       -96
===========================================
- Hits        21936     7559    -14377
+ Misses       8744     4973     -3771
- Partials      110      185       +75

Flag
Coverage Δ

#cypress
?

#javascript
59.44% <ø> (ø)

#python
?

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

@villebro regarding the the naming conventions I agree we should explicitly define constraints (per the naming conventions) when we define the models to ensure consistency. Note there are a number of migrations (example) which leverage this logic. Note we also have utility functions (generic_find_fk_constraint_name, generic_find_uq_constraint_name, etc.) to obtain the constraints.

Question: Will this PR fix bugreport: https://github.com/apache/incubator-superset/issues/8871?
If yes, when will this PR be merged?

Maybe. Though one solution is to just go and DROP the bad constraint in your database. It's a one time fix to any environment. Of course we should fix it so people don't run into it anymore, but as highlighted here, it's not trivial

@mistercrunch Hi there, what do you mean by "manually delete the constraint using DML against your database"? How am I going to do it in superset?


global: migrate templates/assets to Semantic-UI

I've checked and there's nothing to do for this one. The templates in Invenio-IIIF are compatible with both Boostrap3 and Semantic UI (basically it's an image tag)


0.3.7 candidate. Allow globalData as props. Hot fix.

Missed this during the refactor. Need to add globalData to component props

@topicus

Closing will not merge


Add root_subfolder to FileDialog

Closes https://github.com/godotengine/godot-proposals/issues/3929
root_subfolder will make the specified sub-folder into a "fake root" of the FileDialog. You won't be able to go to parent directory and the path display changes.
Without root_subfolder:

root_subfolder set to Test:

I can still go up by typing .. in the Path box, or select a parent directory file directly by typing ../filename in the File box :stuck_out_tongue:
Kind of the same issue as #34194. Although that is about the real root, and this one is about the fake root.

I can still go up by typing .. in the Path box

How? I tested that, you can even see on the GIF it's not possible.

select a parent directory file directly by typing ../filename in the File box 😛

Meh, if you don't know filename, then you can't select it. So blocking folder access is enough.

How? I tested that, you can even see on the GIF it's not possible.

I don't know why, but .. works for me...

Meh, if you don't know filename, then you can't select it. So blocking folder access is enough.

That makes sense for "Open". But the restriction leaks for "Save". The user don't have to know about .., mistyping the filename with a leading / breaks it...

Thanks!


mssql odbc - otherDb..otherTable

I use mssql db through odbc connection.
It is work when i query same db tables.
Same DB Work:
engine2.ShowSQL = true
err = engine2.Table("TSO_Values").Select("Part_Status_Id as id, Part_Status as name ").Limit(10, 0).Find(&users)
However not work for below:
err = engine2.Table("OtherDb..OtherTable").Select("Part_Status_Id as id, Part_Status as name ").Limit(10, 0).Find(&users)
It show error like below
Invalid object name...
SELECT  TOP 10 Part_Status_Id as id, Part_Status as name  FROM "OtherDb..OtherTable"
The reason is I find " in above sql, it is wrong, we need below.
SELECT  TOP 10 Part_Status_Id as id, Part_Status as name  FROM OtherDb..OtherTable
Please fix it. I think you can check .. when generate sql, thanks.

Hi, I think maybe you should use only one dot between dbname and table name. Could you change the code to
err = engine2.Table("OtherDb.OtherTable").Select("Part_Status_Id as id, Part_Status as name ").Limit(10, 0).Find(&users)

And try again?

No, it do not work.
The key issue is mssql do not recognize quotation marks in the sql which generate by xorm.
Wrong: select * from "Otherdb.OtherTable"
Wrong: select * from "Otherdb..OtherTable"
Correct: select * from Otherdb..OtherTable
So, why xorm add additional " for the table name??
Thanks.

Because sometimes maybe your table's name is conflict with the database keyword. So currently xorm will add single qutoe on any table name and column name.

You can try
err = engine2.Table("`OtherDb`..`OtherTable`").Select("Part_Status_Id as id, Part_Status as name ").Limit(10, 0).Find(&users)

before I try to fix this issue.

Thanks for reply, it did not work.
It will generate SQL like : select * from "OtherDB".."OtherTable"
The show SQL flag tell me xorm add double quote instead of single quote.
MSSQL do not accept 'OtherDB..OtherTable' format too.
So, the best way is not add quote for table name.  Or remove quote in case find .. in the table.
Btw, in case some people's table name conflict with database keyword, it still can work, since he/she able create that table in his/her database, no need to worry about. Or that people can use below:
select * from KeyWordTable as NormalWordTable
Please review my proposal, thanks.

Yes. I think we can add one function NoQuote to stop adding quote automatically.

resolved by 15f11df


Superset API return 401 Access Denied: Invalid Credential even when using admin account

Bug description
Hi, as the title said, I am using Superset API to do things like create DB connection, create users, ...
The login, get csrf token endpoints is fine, and I am also be able to call GET endpoints like get all DB connection, get all users, ... using the access token and csrf token of successful admin login
But when using POST endpoints, like create DB connection, it return 401 error
How to reproduce the bug

Call login and get csrf token endpoint to get access token and csrf token for later use
Call /api/v1/database/ endpoint, method POST, to create new connection
Get error

Screenshots/recordings

Superset version
3.1.2
Python version
3.9
Node version
16
Browser
Firefox
Additional context
No response
Checklist

[X] I have searched Superset docs and Slack and didn't find a solution to my problem.
[X] I have searched the GitHub issue tracker and didn't find a similar bug report.
[ ] I have checked Superset's logs for errors and if I found a relevant Python stacktrace, I included it here as text in the "additional context" section.

A few diagnostic questions:

Does it work via the UI, or is it throwing errors there, too?
Are all POST endpoints not working, or is it just this one?

I'm not sure, but it looks like maybe the db connection is throwing the error, not the  API... this makes me ask the two questions above, and I wonder if the URI indeed contains the right credentials for the db.

A few diagnostic questions:
1. Does it work via the UI, or is it throwing errors there, too?

2. Are _all_ POST endpoints not working, or is it just this one?

No, the UI is not working to, throwing the same error
I am working with db create api and login only, so I can't test other endpoint, but login is also POST and its fine

I'm not sure, but it looks like maybe the db connection is throwing the error, not the API... this makes me ask the two questions above, and I wonder if the URI indeed contains the right credentials for the db.

You mean the credentials and DB for login Superset? or credential and DB for the connection that I am creating?


Modified Documentation on withSelectable

The Java doc was misleading. It is actually required to set withSelectable to true to allow multi selection and by default, no items are selectable.

Thank you very much


Update sql-database-security-overview.md

Update Threat Detection text and the fact Threat Detection will start incurring charges once it becomes Generally Available.

@rmatchoro,
Thanks for your contribution as a Microsoft full-time employee or intern. You do not need to sign a CLA.
Thanks,
Microsoft Pull Request Bot

@rmatchoro : Thanks for your contribution to the Azure documentation! The author, @tmullaney, has been notified to review your proposed change.

#sign-off

@rmatchoro,
Thanks for your contribution as a Microsoft full-time employee or intern. You do not need to sign a CLA.
Thanks,
Microsoft Pull Request Bot

#1543

@rmatchoro,
Thanks for your contribution as a Microsoft full-time employee or intern. You do not need to sign a CLA.
Thanks,
Microsoft Pull Request Bot

please merge and publish

#sign-off

#sign-off


[Request] Eloquent order by related field

I think a lot of us need to sort a collection of models by a related field. A common scenario for me is when I want things ordered by their translated name.
As I know, there is no possibility to do this in Eloquent without hacking the query: joining related tables, adding the order by clause then filtering selected fields.
I could imagine a solution where you can pass an array as the $column argument of the Model::orderBy($column, $direction) method where the last item defines the related field and all the other elements define a chain of relationships where the related field can be found. E.g.: array("translation", "name");
Of course this feature can be implemented with PHP after performing the query, but if you want to add LIMIT or OFFSET constraints too, your result will be nonsense as limiting takes place before ordering.

sort by related table attribute is very tricky, take a look on this package for more info https://github.com/fico7489/laravel-eloquent-join