Add isRelevantForPreferred field to external attribution sources

Summary of changes
Add new isRelevantForPreferred field to external attribution sources. This field has type optional boolean. If set, it indicates that signals from this source may be 'preferred over' using the preference feature.
If no sources have this field set, then the preference feature is disabled.
Context and reason for change
We would like for the preference feature to only apply to signals from certain sources.
How can the changes be tested
See unit tests
I have updated the example files example.opossum & opossum_input.json to include relevant sources. The preferred feature should be enabled on those files. It should be disabled on every other random file you have.

squashed and rebased


azure portal dashboard create uses   "apiVersion": "2015-08-01-preview" and not   "apiVersion": "2022-12-01-preview"

Describe the bug
We have multiple azure environments with our software deployed and would like to use the following workflow to create a dashboard:

Create a dashboard manually in azure portal
Export the dashboard JSON
Use this exported template as input to create dashboards for other environments using az cli.

Related command
az portal dashboard create --input-path ...
Errors
  File "C:\...\.azure\cliextensions\portal\azext_portal\vendored_sdks\portal\operations\_dashboard_operations.py", line 101, in create_or_update
    body_content = self._serialize.body(dashboard, 'Dashboard')
                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "D:\a\_work\1\s\build_scripts\windows\artifacts\cli\Lib\site-packages\msrest/serialization.py", line 624, in body
  File "D:\a\_work\1\s\build_scripts\windows\artifacts\cli\Lib\site-packages\msrest/exceptions.py", line 51, in raise_with_traceback
  File "D:\a\_work\1\s\build_scripts\windows\artifacts\cli\Lib\site-packages\msrest/serialization.py", line 622, in body
  File "D:\a\_work\1\s\build_scripts\windows\artifacts\cli\Lib\site-packages\msrest/serialization.py", line 1406, in _deserialize
  File "D:\a\_work\1\s\build_scripts\windows\artifacts\cli\Lib\site-packages\msrest/serialization.py", line 1415, in _deserialize
  File "D:\a\_work\1\s\build_scripts\windows\artifacts\cli\Lib\site-packages\msrest/serialization.py", line 1637, in deserialize_data
  File "D:\a\_work\1\s\build_scripts\windows\artifacts\cli\Lib\site-packages\msrest/exceptions.py", line 51, in raise_with_traceback
  File "D:\a\_work\1\s\build_scripts\windows\artifacts\cli\Lib\site-packages\msrest/serialization.py", line 1626, in deserialize_data
  File "D:\a\_work\1\s\build_scripts\windows\artifacts\cli\Lib\site-packages\msrest/serialization.py", line 1673, in deserialize_dict
  File "D:\a\_work\1\s\build_scripts\windows\artifacts\cli\Lib\site-packages\msrest/serialization.py", line 1673, in <dictcomp>
  File "D:\a\_work\1\s\build_scripts\windows\artifacts\cli\Lib\site-packages\msrest/serialization.py", line 1639, in deserialize_data
  File "D:\a\_work\1\s\build_scripts\windows\artifacts\cli\Lib\site-packages\msrest/serialization.py", line 1454, in _deserialize
  File "D:\a\_work\1\s\build_scripts\windows\artifacts\cli\Lib\site-packages\msrest/exceptions.py", line 51, in raise_with_traceback
  File "D:\a\_work\1\s\build_scripts\windows\artifacts\cli\Lib\site-packages\msrest/serialization.py", line 1450, in _deserialize
  File "D:\a\_work\1\s\build_scripts\windows\artifacts\cli\Lib\site-packages\msrest/serialization.py", line 1626, in deserialize_data
  File "D:\a\_work\1\s\build_scripts\windows\artifacts\cli\Lib\site-packages\msrest/serialization.py", line 1668, in deserialize_dict
  File "D:\a\_work\1\s\build_scripts\windows\artifacts\cli\Lib\site-packages\msrest/serialization.py", line 1668, in <dictcomp>
azure.core.exceptions.SerializationError: ('Unable to build a model: (\'Unable to deserialize response data. Data: {\\\'0\\\': {\\\'order\\\': 0, \\\'parts\\\': [{\\\'position\\\': {\\\'x\\\': 0, \\\'y\\\': 0, \\\'colSpan\\\': 4, \\\'rowSpan\\\': 3}, \\\'metadata\\\': {\\\'inputs\\\': [{\\\'name\\\': \\\'options\\\', \\\'value\\\': {\\\'chart\\\': {\\\'metrics\\\': [{\\\'resourceMetadata\\\': {\\\'id\\\': \\\'/subscriptions/103e905d-0efe-4e30-aa80-135c0b82faf4/reso

Issue script & Debug output
NA
Expected behavior
The dashboard export generates the file with apiVersion": "2022-12-01-preview" now.
The az cli though expects the imported file to be of the   "apiVersion": "2015-08-01-preview"
The structure of data is different between the two versions:
"apiVersion": "2015-08-01-preview" has the following format.
Note1:  the lenses item is a single element and not an array. Plus the items are elements with numbers "0", etc.
Note2: The parts element is similarly a single object and not an array and items inside them are elements with numbers "0" etc.
{
  "properties": {
    "lenses": {
      "0": {
        "order": 0,
        "parts": {
          "0": {}
        }
      }
    },
    "metadata": {
      "model": {
        "timeRange": {
          "value": {
            "relative": {
              "duration": 24,
              "timeUnit": 1
            }
          },
          "type": "MsPortalFx.Composition.Configuration.ValueTypes.TimeRange"
        }
      }
    }
  },
  "name": "...",
  "type": "Microsoft.Portal/dashboards",
  "location": "INSERT LOCATION",
  "apiVersion": "2015-08-01-preview"
}

apiVersion": "2022-12-01-preview" that azure portal now exports has the following format:
Note1:  the lenses item is an array. Plus the items are just objects inside the array, no "0" named elements.
Note2: The parts element is similarly an array and items inside them are objects in the array, without "0" etc. named elements.
{
  "properties": {
    "lenses": [
      {
        "order": 0,
        "parts": [
           {}
        ]
      }
    ],
    "metadata": {
      "model": {
        "timeRange": {
          "value": {
            "relative": {
              "duration": 24,
              "timeUnit": 1
            }
          },
          "type": "MsPortalFx.Composition.Configuration.ValueTypes.TimeRange"
        }
      }
    }
  },
  "name": "...",
  "type": "Microsoft.Portal/dashboards",
  "location": "INSERT LOCATION",
  "apiVersion": "2022-12-01-preview"
}

The older api version can be imported by following this example: https://stackoverflow.com/a/65435018/987191
The portal exports for a later API version that cannot be used by azure cli to create the dashboard.
I understand the feature is in preview, but it doesn't align with the portal output.
Can the api be changed to import latest api version or allow to take api version as an input if multiple api versions and file formats need to be supported?
Environment Summary
azure-cli: 2.59.0
Additional context
No response

@jsntcy , May I ask why assign this to me? I have no context about this project.


JCB regex wrong

I test card number:<PHONE_NUMBER>195001
Returned: card_type: null

I can confirm this is not registering as a JCB card.  Let me look into this

You can grab the latest one from the /dist folder here: https://github.com/jessepollak/payment/tree/master/dist
Its fixed and thanks for reporting!

OK. Thanks


The log cannot readable

Hi Team,
it's seems that the fluent can not read the containner log. Did you have any idea?
/var/log/containers/air412-worker-2_air412_airflow-worker-adc180a2ec3ce2ff916bc954a6196cc059320c36381f33ba1641a464e1a70906.log unreadable. It is excluded and would be examined next time.
I check the container inside as below.
root@fluentd-krrhv:/home/fluent# ls -lrt /var/log/containers/air412-worker-6_air412_airflow-worker-7f69437e5fa29211e254e6008de9feb61864588810cb43e90c0a209cbe1332ed.log
lrwxrwxrwx 1 root root 94 Feb 12 04:13 /var/log/containers/air412-worker-6_air412_airflow-worker-7f69437e5fa29211e254e6008de9feb61864588810cb43e90c0a209cbe1332ed.log -> /var/log/pods/air412_air412-worker-6_e5256708-ce75-4f26-92ae-cb064e29e343/airflow-worker/0.log
There also no this directory.
root@fluentd-krrhv:/home/fluent# cd /var/log/pods
bash: cd: /var/log/pods: No such file or directory
DaemonSet yaml file as below.
apiVersion: apps/v1
kind: DaemonSet
metadata:
name: fluentd
namespace: kube-system
labels:
k8s-app: fluentd-logging
version: v1
spec:
updateStrategy:
type: RollingUpdate
selector:
matchLabels:
name: fluentd
template:
metadata:
labels:
name: fluentd
spec:
serviceAccount: fluentd
serviceAccountName: fluentd
# Enable tolerations if you want to run daemonset on master nodes.
# Recommended to disable on managed k8s.
# tolerations:
# - key: node-role.kubernetes.io/master
#   effect: NoSchedule
containers:
- name: fluentd
image: fluent/fluentd-kubernetes-daemonset:v1-debian-graylog
imagePullPolicy: IfNotPresent
env:
- name:  FLUENT_GRAYLOG_HOST
value: "graylog-1.graylog.graylog.svc.cluster.local"
- name:  FLUENT_GRAYLOG_PORT
value: "12201"
- name: FLUENT_UID
value: "0"
resources:
requests:
cpu: 200m
memory: 1Gi
limits:
# ===========
# Less memory leads to child process problems.
cpu: 1000m
memory: 1Gi
volumeMounts:
- name: varlog
mountPath: /var/log
- name: varlibdockercontainers
mountPath: /var/log/containers
readOnly: true
terminationGracePeriodSeconds: 30
volumes:
- name: varlog
hostPath:
path: /var/log
- name: varlibdockercontainers
hostPath:
path: /var/log/containers
Levi
Thanks

This seems the problem is not fluentd. Your environment creates symlink to logfile, but no actual logfile. You need to check your application or k8s setting.

@repeatedly
sure, I will check the k8s setting with my team.  BTW, I found pods were running in namespace
kubectl get pods -n kube-system | grep fluentd
fluentd-9ltm6                                          1/1     Running            32         5h27m
fluentd-gz9bw                                          1/1     Running            32         5h27m
fluentd-jdk56                                          1/1     Running            32         5h27m
fluentd-jlzwk                                          1/1     Running            32         5h27m
fluentd-lm5v6                                          1/1     Running            32         5h27m
fluentd-xwvmg                                          1/1     Running            32         5h27m
Did you know the 'journald' for below file inside pod and where the fluent self log?
-rw-r--r--  1 root root       135 Feb 17 01:36 fluentd-journald-docker-cursor.json
-rw-r--r--  1 root root         2 Feb 17 01:36 fluentd-journald-bootkube-cursor.json
Levi
Thanks!


Android Test: ClassCastException: org.mockito.Answers cannot be cast to org.mockito.stubbing.Answer

I'm getting the following exception when I try to run a test that previously worked without mockito-kotlin:
java.lang.ClassCastException: org.mockito.Answers cannot be cast to org.mockito.stubbing.Answer
at com.nhaarman.mockito_kotlin.CreateInstanceKt.uncheckedMock(CreateInstance.kt:178)
at com.nhaarman.mockito_kotlin.CreateInstanceKt.createInstance(CreateInstance.kt:58)
I'm trying to isolate the code that is causing it.
Using version 0.5

Could this have something to do with #35?

Here's a test case to reproduce it:
class KotlinMockitoTest {
    @Test
    fun test() {
        val mock = mock<Func1<String, String>>()
        whenever(mock.call(any())).thenReturn("foo")
        assertEquals("foo", mock.call("bar"))
    }
}

Func1 is any Java interface, like the one from RxJava.
Since the test is run as an android instrumentation test, I should mention that I had to force an older mockito dependency, because mockito 2.0 doesn't work with dexmaker. My dependencies are declared as follows.
androidTestCompile 'org.mockito:mockito-core:1.9.5'
androidTestCompile('com.nhaarman:mockito-kotlin:0.5.0') {
    exclude group: 'org.jetbrains.kotlin'
    exclude group: 'org.mockito'
}
androidTestCompile 'com.google.dexmaker:dexmaker:1.2'
androidTestCompile 'com.google.dexmaker:dexmaker-mockito:1.2'

I believe the older Mockito version is the cause: I also had this issue in a (non-Android) project using an older Mockito version, and resolved by upgrading to Mockito 2.0.

I use Mockito 1.10.19 since Mockito 2 ist still in beta and also face this issue.
Maybe I can find a way to achieve the same functionality in a way compatible to both Mockito 1 and 2 and come up with a patch.

I ended up with something like this
@Suppress("UNCHECKED_CAST")
private fun <T> Class<T>.uncheckedMock(): T {
    // use fallback for pre 2.0 Mockito versions
    val defaultAnswer: Answer<*> =
            if (Answers.RETURNS_DEFAULTS is Answer<*>)
                Answers.RETURNS_DEFAULTS
            else
                GloballyConfiguredAnswer()

    val impl = MockSettingsImpl<T>().defaultAnswer(defaultAnswer) as MockSettingsImpl<T>
    val creationSettings = impl.confirm(this)
    return MockUtil().createMock(creationSettings).apply {
        if (this is Any && this.javaClass.simpleName == "MockAccess") {
            (this as MockMethodInterceptor.MockAccess).mockitoInterceptor = null
        }
    }
}

But unfortunately suddenly I was unable to reproduce the ClassCastException when reverting back to the version without this change, even with your test case from above.
@cypressious Could you check if the above code snippet works for you?

If anyone could make a PR with a solid test that fails with this issue, we could try and tackle it.

I can confirm that this problem exists before Mockito 2.
This is the test case that I used to check
    @Test
    fun verifyTest() {
        open class Klass {
            open fun doIt(list: List<String>) {

            }
        }

        val klass: Klass = mock()

        val c: ArgumentCaptor<List<String>> = argumentCaptor()

        klass.doIt(ArrayList())

        verify(klass).doIt(capture(c))
    }

It looks like this issue and #35 are caused by using Mockito 1.x. This library really focuses on the soon-to-be-released 2.x version.

I believe the randomness of this problem stems from classloaders loading multiple versions of mockito. I had the same problem even after upgrading kotlin_mockito to 0.11. Juckito, another support library for mockito, uses version 1.x of Mockito.
Move the juckito declaration or any other library which pulls in Mockito 1.x to the end of the include list. I add this comment, because google led me here (first hit of my search)


how to caculate the version number of  openssl

I failed to cross compile libcurl , log:
 "curl_ntlm_core.c:167:27: error: unknown type name ‘DES_key_schedule’
                         DES_key_schedule DESKEYARG(ks))"

I grep the symbol DES_key_schedule, and found it
#  if (OPENSSL_VERSION_NUMBER < 0x00907001L)
#    define DES_key_schedule des_key_schedule
#    define DES_cblock des_cblock
#    define DES_set_odd_parity des_set_odd_parity
#    define DES_set_key des_set_key
#    define DES_ecb_encrypt des_ecb_encrypt
#    define DESKEY(x) x
#    define DESKEYARG(x) x
#  else
#    define DESKEYARG(x) *x
#    define DESKEY(x) &x
#  endif

It obvious that the openssl version number should less than 0x00907001L.
And openssl info is that:
/home/libopenss # ./openssl version -a
OpenSSL 1.1.1-pre9-dev  xx XXX xxxx
built on: Fri Jul  6 05:49:37 2018 UTC
platform: linux-armv4
options:  bn(64,32) rc4(char) blowfish(ptr)
compiler: arm-hisiv300-linux-gcc -fPIC  -Wall -O3 -DOPENSSL_USE_NODELETE -DOPENSSL_PIC -DNDEBUG
OPENSSLDIR: "/home/kgbook/tools/libopenssl/ssl"
ENGINESDIR: "/home/kgbook/tools/libopenssl/lib/engines-1.1"
Seeding source: os-specific

The version number is not string but a long integer number, how to figure out my openssl version number?

The problem seems to be that you don't include the proper header files to get DES_key_schedule correctly defined. This line must be present in your source module:
#include <openssl/des.h>

... and looking at the source module in question, it looks like it's done right, so I have no idea what to say... However, it looks to me like you should take the issue to the curl project
Closing

@levitte
Not that.
the lib path I pass to the configure is not right, see https://github.com/curl/curl/issues/2714
Thanks the same.

OK then! I'm glad this got resolved.


Load Open-ephys Neuropixels PXI recording with sync channel appended

The Neuropixels PXI plugin has the option to append the **sync line **  to the data stream as a continuous channel (see documentation). That means that the continuous.dat file now has one channel more than is specified in the probe settings. This causes an error when loading the files as there is a channel count  check done before loading (#L415) because if the probe is already defined set_probe(inplace=True), (which is the case when using the Neuropixels PXI recordings) it assumes the the number of recorded channels must be equal to the number of electrodes on the probe.

    if in_place:
        if not np.array_equal(new_channel_ids, self.get_channel_ids()):
            raise Exception('set_proce(inplace=True) must have all channel indices')
        sub_recording = self
    else:
        if np.array_equal(new_channel_ids, self.get_channel_ids()):
            sub_recording = self.clone()
        else:
            sub_recording = ChannelSliceRecording(self, new_channel_ids)

    sub_recording.set_property('contact_vector', arr, ids=None)

This is a tricky issue (I think) as it comes down to having to change the way the recording is read using the open-ephys extractors. We should do something similar as is done with the spikeglx data, that is checking for a sync channel and separating it off early on. (I think it is done here #L120

Thank you for the issue! Can you share a small test file with the sync channel enabled? Ideally, something super short would be great (like 1s) and it doesn't need to have real data. We use these kind of data in this repo to test multiple cases for different acquisition devices :)

@LiesDec you can send it to us via email and we'll take care of uploading it :) My email in the docs. Also send us the details of who made the recording and in which lab so we'll add those info as "acknowledgments"

No the blacrock sortig is not ported. But if you need it this could be done with a wrapper.

@samuelgarcia Great that you're already on this issue. Do you still need a dataset then? :)
Also, I noticed that I only have the loading error when I have only one neuropixel 2.0 attached to the headstone (one data stream). When I have two and the sync channel appended as continuous channel I do not have the reading error (despite if for sure being registered).  Maybe this is related to this other issue I came across? https://github.com/SpikeInterface/probeinterface/issues/114
For reference, these are the two settings.xml files for a recording with one and two probes attached but both with the sync channel recorded a continuous channel

1 probe, Sync channel appended and error loading
settings_1p.txt

2 probes, Sync channel appended and no error loading
settings_2p.txt

Is the dataset needed and already uploaded ?
If not, I activated sync channel in all of my recordings. Hence I may provide my recordings.

We already have the dataset with sync I think

This is fixed on the SpikeInterface side.
To summarize, the probe will always load the 384 channels (or less is a subset is used) and it will be attached to a recording only if load_sync_channel is False. This is to prevent a wrong usage of the probes when the sync channel is loaded. See https://github.com/SpikeInterface/spikeinterface/pull/1830


Tensorflow Webpage API tab Link error

Description of issue (what needs changing):
The Tensorflow API for 1.13 leads to 1.12 page kindly fix the hyperlink .
Clear description
The change in the API list can cause confusion
Request visuals, if applicable

Fixed in https://github.com/tensorflow/tensorflow/issues/30206


when i click zhe input element three times,zhe datatimepicker cannot show.

first click, datatimepicker show.
secend click,datatimepicker hidden.
third click,no response

Have a look at your browser console for any errors/exceptions!


Suggestion: Rename setNamespace to noConflict

It's fairly typical for methods that reset a library's namespace in order to avoid collision to be called noConflict. See jQuery, Underscore, Lodash, Bootstrap, and even mainly server-side libraries like node-uuid.
I think a setNamespace method is reserved for actually creating a new namespace on or from an object, not changing the object's current global namespace.

Thanks @colindresj
You are right. Listed this one here > https://github.com/arasatasaygin/is.js/issues/44

:+1:


[Bug] I cannot build package from source with the latest release

Describe the bug
I download the repository to my local, switch to the latest version 1.9.4, and then run make r-build. However, it failed. I was able to run make r-build for version 1.9.3 in the same environment.
The errors I got are as follow

[ 24%] Building CXX object _deps/catch2-build/src/CMakeFiles/Catch2.dir/catch2/reporters/catch_reporter_event_listener.cpp.o
/home/tiledbsoma/TileDB-SOMA/libtiledbsoma/src/utils/nanoarrow.c: In function ‘int64_t ArrowSchemaToString(const ArrowSchema*, char*, int64_t, char)’:
/home/tiledbsoma/TileDB-SOMA/libtiledbsoma/src/utils/nanoarrow.c:1779:28: error: null destination pointer [-Werror=format-truncation=]
n_chars_last = snprintf(out, n, ">");
^~~~~
[ 24%] Building CXX object _deps/catch2-build/src/CMakeFiles/Catch2.dir/catch2/reporters/catch_reporter_helpers.cpp.o
cc1plus: all warnings being treated as errors
gmake[6]: *** [src/CMakeFiles/TILEDB_SOMA_OBJECTS.dir/build.make:342: src/CMakeFiles/TILEDB_SOMA_OBJECTS.dir/utils/nanoarrow.c.o] Error 1
gmake[6]: *** Waiting for unfinished jobs....
// skip some logs in between
pp.o
gmake[5]: *** [CMakeFiles/Makefile2:156: src/CMakeFiles/TILEDB_SOMA_OBJECTS.dir/all] Error 2
gmake[5]: *** Waiting for unfinished jobs....
[ 88%] Linking CXX static library libCatch2.a
[ 88%] Built target Catch2
gmake[4]: *** [Makefile:146: all] Error 2
gmake[3]: *** [CMakeFiles/libtiledbsoma.dir/build.make:86: libtiledbsoma-prefix/src/libtiledbsoma-stamp/libtiledbsoma-build] Error 2
gmake[2]: *** [CMakeFiles/Makefile2:113: CMakeFiles/libtiledbsoma.dir/all] Error 2
gmake[1]: *** [Makefile:91: all] Error 2
make: *** [Makefile:21: r-build] Error 2

It seems like the same file is changed by most recent commit and this commit failed TileDB-R-CI. Any advice of how to fix this would be pretty helpful.
To Reproduce
Download repository
switch to 1.9.4
run make r-build
Versions (please complete the following information):

TileDB-SOMA version: 1.9.4
Language and language version (e.g. Python 3.8, R 4.2.2): R version 4.3.2
OS (e.g. MacOS, Ubuntu Linux): Centos stream 8

@angela18199 thank you!
We've reworked nanoarrow.c on some recent PRs. These all had green CI.
When we went do a wheel build (for PyPI) we indeed found the compiler error
/home/tiledbsoma/TileDB-SOMA/libtiledbsoma/src/utils/nanoarrow.c:1779:28: error: null destination pointer [-Werror=format-truncation=]
n_chars_last = snprintf(out, n, ">");

being triggered only within the wheel-build process.
The PR https://github.com/single-cell-data/TileDB-SOMA/pull/2398 was in fact the code change that fixed this build error -- not the one that caused it.
This fix has been included within our 1.9.4 release so I am curious as to how your local copy varies compared to ours.
Can you please show me what lines 1710-1720 of all your local copies of nanoarrow.c look like on your system?

@angela18199 excellent.
So you have
if (out == NULL) {
return 0;
}

which indeed is the fix for the compiler error
/home/tiledbsoma/TileDB-SOMA/libtiledbsoma/src/utils/nanoarrow.c:1779:28: error: null destination pointer [-Werror=format-truncation=]
n_chars_last = snprintf(out, n, ">");

Can you please share, as a gist, the entire output of your make r-build session?

Absolutely!
Here is the entire session.

[root@99423bd2a192 TileDB-SOMA]# make r-build prefix=/tmp/packages/dnf/usr tiledb=/tmp/packages/dnf/usr
Build with TileDB: /tmp/packages/dnf/usr
Building Release build
-- Install prefix is /tmp/packages/dnf/usr.
-- The C compiler identification is GNU 8.5.0
-- The CXX compiler identification is GNU 8.5.0
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: /usr/bin/cc - skipped
-- Detecting C compile features
-- Detecting C compile features - done
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/c++ - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Starting TileDB-SOMA superbuild.
-- Found TileDB: /tmp/packages/dnf/usr/lib64/libtiledb.so.2.17
-- Could NOT find spdlog (missing: spdlog_DIR)
-- Adding spdlog as an external project
-- Not found clang-tidy
-- Not found clang-format
-- Configuring done (0.6s)
-- Generating done (0.0s)
-- Build files have been written to: /home/tiledbsoma/TileDB-SOMA/build
[  6%] Creating directories for 'ep_spdlog'
[ 12%] Performing download step (download, verify and extract) for 'ep_spdlog'
-- ep_spdlog download command succeeded.  See also /home/tiledbsoma/TileDB-SOMA/build/externals/src/ep_spdlog-stamp/ep_spdlog-download-.log
[ 18%] No update step for 'ep_spdlog'
[ 25%] Performing patch step for 'ep_spdlog'
patching file include/spdlog/logger-inl.h
[ 31%] Performing configure step for 'ep_spdlog'
-- ep_spdlog configure command succeeded.  See also /home/tiledbsoma/TileDB-SOMA/build/externals/src/ep_spdlog-stamp/ep_spdlog-configure-.log
[ 37%] Performing build step for 'ep_spdlog'
-- ep_spdlog build command succeeded.  See also /home/tiledbsoma/TileDB-SOMA/build/externals/src/ep_spdlog-stamp/ep_spdlog-build-.log
[ 43%] Performing install step for 'ep_spdlog'
-- ep_spdlog install command succeeded.  See also /home/tiledbsoma/TileDB-SOMA/build/externals/src/ep_spdlog-stamp/ep_spdlog-install-.log
[ 50%] Completed 'ep_spdlog'
[ 50%] Built target ep_spdlog
[ 56%] Creating directories for 'libtiledbsoma'
[ 62%] No download step for 'libtiledbsoma'
[ 68%] No update step for 'libtiledbsoma'
[ 75%] No patch step for 'libtiledbsoma'
[ 81%] Performing configure step for 'libtiledbsoma'
-- Install prefix is /tmp/packages/dnf/usr.
-- The C compiler identification is GNU 8.5.0
-- The CXX compiler identification is GNU 8.5.0
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: /usr/bin/cc - skipped
-- Detecting C compile features
-- Detecting C compile features - done
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/c++ - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Starting TileDB-SOMA regular build.
-- Performing Test HAVE_AVX2
-- Performing Test HAVE_AVX2 - Success
-- Starting TileDB-SOMA build.

Can you please edit scripts/bld in the repo base, changing
# NOTE: set to true to debug the cmake build
if false; then

at line 46 to
# NOTE: set to true to debug the cmake build
if true; then

then re-run -- and on this re-run, please copy-paste into gist.github.com and share that way? Thank you!

@angela18199 Also please share your operating system name and version

Sorry I forgot to do it in gist.
I just realized that in the log, it says the error is from line 1779 in nanoarrow.c not around 1710

/home/tiledbsoma/TileDB-SOMA/libtiledbsoma/src/utils/nanoarrow.c:1779:28: error: null destination pointer [-Werror=format-truncation=]
n_chars_last = snprintf(out, n, ">");

I will provide the log with debug cmake set to true soon.

Operation system is CentOS Stream release 8

Also regarding

It seems like the same file is changed by most recent commit and this commit failed TileDB-R-CI.

In fact fixed the compile error for us. We have redundant CI -- pre-commit, post-commit, and version-tag. Earlier today I cancelled some redundant CI jobs to make room for others, in cases when they were redundant. The red CI you saw above was due not to a fail but a cancellation. To avoid any confusion I've restarted all the cancelled jobs at https://github.com/single-cell-data/TileDB-SOMA/pull/2398/checks. These are now all green. My apologies for any confusion caused here.

I just realized that in the log, it says the error is from line 1779 in nanoarrow.c not around 1710

Correct. The fix made on #2398 -- which was validated -- was to null-check at line 1710 in order to avoid the compiler casting aspersion on the sprintf destination at line 1779. This was a sufficient check on the systems we checked. In particular, we saw the same compiler error you did before #2398, and not after #2398. However, on your system you're experiencing the compiler error after #2398. It appears the check
if (out == NULL) {
  return 0;
}

is not enough to convince your system's compiler that out is non-null at line 1779 🤔

@angela18199 thank you! Can you share your /usr/bin/c++ --version? Or -version as the case may be?

c++ (GCC) 8.5.0 20210514 (Red Hat 8.5.0-21)
cmake version 3.26.5

@angela18199 thank you!
My theory is that while our if-null-then-return at line 1710 was demonstrably able to avoid the compiler error at line 1779 on the systems we've used, it was not enough for c++ 8.0 on Centos 8.
This bears investigating, and thank you for letting us know.
Meanwhile a colleague suggests changing from
# set extra cmake options
# -------------------------------------------------------------------
extra_opts=""

to
# set extra cmake options
# -------------------------------------------------------------------
extra_opts="-DTILEDBSOMA_ENABLE_WERROR=OFF -DTILEDB_WERROR=OFF"

at line 34 of scripts/bld as a workaround for your system at this time.
Can you try this and let us know if this works for you?

Unfortunately, I am still getting the same error :(

@angela18199 can you again:

Please double-check the if true at line 46 of scripts/bld
Please re-run the make r-build
Please gist the full output
?

Thanks for your patience?

I make sure
extra_opts="-DTILEDBSOMA_ENABLE_WERROR=OFF -DTILEDB_WERROR=OFF"
cmake debug is set to true
run make r-build
Here is the log
Thanks!

OK @angela18199 thank you! At the end of the output there is the line (line breaks added by me for clarity)
cd /home/tiledbsoma/TileDB-SOMA/build/libtiledbsoma/src &&
/usr/bin/c++
-DBUILD_COMMIT_HASH=\"1.9.4\"
-DTILEDB_DEPRECATED=""
-DTILEDB_SOMA_OBJECTS_EXPORTS
-D_FILE_OFFSET_BITS=64
-I/home/tiledbsoma/TileDB-SOMA/libtiledbsoma/src
-I/home/tiledbsoma/TileDB-SOMA/libtiledbsoma/src/vendor
-I/home/tiledbsoma/TileDB-SOMA/libtiledbsoma/src/soma
-I/home/tiledbsoma/TileDB-SOMA/libtiledbsoma/src/external/khash
-I/home/tiledbsoma/TileDB-SOMA/libtiledbsoma/src/external/include
-I/tmp/packages/dnf/usr/include
-I/home/tiledbsoma/TileDB-SOMA/build/externals/install/include
-I/home/tiledbsoma/TileDB-SOMA/build/libtiledbsoma/src
-x c++ -O3 -DNDEBUG -std=c++17 -fPIC
-Wall
-Wextra
-Werror
-DNDEBUG
-O3
-Wno-literal-suffix
-D_LIBCPP_DISABLE_AVAILABILITY
-mavx2
-MD
-MT src/CMakeFiles/TILEDB_SOMA_OBJECTS.dir/utils/nanoarrow.c.o
-MF CMakeFiles/TILEDB_SOMA_OBJECTS.dir/utils/nanoarrow.c.o.d
-o CMakeFiles/TILEDB_SOMA_OBJECTS.dir/utils/nanoarrow.c.o
-c /home/tiledbsoma/TileDB-SOMA/libtiledbsoma/src/utils/nanoarrow.c

which shows that -Werror is still making it to nanarrow.c.
I'll circle back & come back with an update on the advice on how to avoid -Werror on this file.

@angela18199 I've looked locally -- there's a disconnect between setting
extra_opts="-DTILEDBSOMA_ENABLE_WERROR=OFF -DTILEDB_WERROR=OFF

(which you've done) and having that make it all the way to lines 190-192 of libtiledbsoma/CMakeLists.txt -- where this is still being seen as having value ON.
While we do need to fix that -- my advice for your workaround now becomes to remove the lines
  if(TILEDBSOMA_ENABLE_WERROR)
    add_compile_options(-Werror)
  endif()

at 190-192 of libtiledbsoma/CMakeLists.txt for your system.

Thank you! I believe it is working. I will do some more tests next week.
I am installing this in docker and if you are planning to test on centos 8, there is one thing to note that gcc 8.5 is missing filesystem library and need to add -lstdc++fs flag to cmake files. If you use gcc 9, then no need to worry about it.

Thank you @angela18199 !

#2408 I believe will address all remaining concerns -- closing this issue -- please let me know if I'm mistaken and we can reopen -- thank you!


Fail to install ros-humble-turtlebot4-desktop

Ubuntu 22.04.2 LTS
ROS Distro HUMBLE installed thru 'sudo apt update && sudo apt install ros-humble-turtlebot4-desktop'
ROS2 Installed snapshot (After the installation):
administrator@vtglnx117:~/.ros$ dpkg -l | grep ros2
ii  ros-humble-demo-nodes-cpp                         0.20.3-1jammy.20230118.004446           amd64        C++ nodes which were previously in the ros2/examples repository but are now just used for demo purposes.
ii  ros-humble-demo-nodes-py                          0.20.3-1jammy.20230117.232639           amd64        Python nodes which were previously in the ros2/examples repository but are now just used for demo purposes.
ii  ros-humble-ros2action                             0.18.5-1jammy.20230117.234634           amd64        The action command for ROS 2 command line tools.
ii  ros-humble-ros2bag                                0.15.4-2jammy.20230118.030752           amd64        Entry point for rosbag in ROS 2
ii  ros-humble-ros2cli                                0.18.5-1jammy.20230117.232935           amd64        Framework for ROS 2 command line tools.
ii  ros-humble-ros2cli-common-extensions              0.1.1-4jammy.20230118.012959            amd64        Meta package for ros2cli common extensions
ii  ros-humble-ros2component                          0.18.5-1jammy.20230118.004321           amd64        The component command for ROS 2 command line tools.
ii  ros-humble-ros2doctor                             0.18.5-1jammy.20230117.233330           amd64        A command line tool to check potential issues in a ROS 2 system
ii  ros-humble-ros2interface                          0.18.5-1jammy.20230117.233637           amd64        The interface command for ROS 2 command line tools
ii  ros-humble-ros2launch                             0.19.4-1jammy.20230117.234435           amd64        The launch command for ROS 2 command line tools.
ii  ros-humble-ros2lifecycle                          0.18.5-1jammy.20230118.012705           amd64        The lifecycle command for ROS 2 command line tools.
ii  ros-humble-ros2multicast                          0.18.5-1jammy.20230117.233732           amd64        The multicast command for ROS 2 command line tools.
ii  ros-humble-ros2node                               0.18.5-1jammy.20230117.233331           amd64        The node command for ROS 2 command line tools.
ii  ros-humble-ros2param                              0.18.5-1jammy.20230117.233714           amd64        The param command for ROS 2 command line tools.
ii  ros-humble-ros2pkg                                0.18.5-1jammy.20230117.233641           amd64        The pkg command for ROS 2 command line tools.
ii  ros-humble-ros2run                                0.18.5-1jammy.20230117.234434           amd64        The run command for ROS 2 command line tools.
ii  ros-humble-ros2service                            0.18.5-1jammy.20230117.233350           amd64        The service command for ROS 2 command line tools.
ii  ros-humble-ros2topic                              0.18.5-1jammy.20230117.233355           amd64        The topic command for ROS 2 command line tools.
ii  ros-humble-sros2                                  0.10.4-2jammy.20230117.234843           amd64        Command line tools for managing SROS2 keys
ii  ros-humble-sros2-cmake                            0.10.4-2jammy.20230117.235240           amd64        CMake macros to configure security
Please provide the following information:

OS: (e.g. Ubuntu 20.04)
ROS Distro: (e.g. Galactic)
Built from source or installed:
Package version: (if from repository, give version from sudo dpkg -s ros-$ROS_VERSION-turtlebot4-PACKAGE_WITH_ISSUE, if from source, give commit hash)

Actual behaviour
The following failures printed after 'sudo apt update && sudo apt install ros-humble-turtlebot4-desktop'
Ign:1 https://download.docker.com/linux/ubuntu jammy InRelease
Ign:2 http://il.archive.ubuntu.com/ubuntu jammy InRelease
Ign:3 http://security.ubuntu.com/ubuntu jammy-security InRelease
Ign:4 https://dl.google.com/linux/chrome/deb stable InRelease
Ign:5 http://packages.ros.org/ros2/ubuntu jammy InRelease
Ign:6 https://packages.microsoft.com/repos/vscode stable InRelease
Ign:7 http://il.archive.ubuntu.com/ubuntu jammy-updates InRelease
Ign:8 http://il.archive.ubuntu.com/ubuntu jammy-backports InRelease
Ign:4 https://dl.google.com/linux/chrome/deb stable InRelease
Ign:6 https://packages.microsoft.com/repos/vscode stable InRelease
Ign:1 https://download.docker.com/linux/ubuntu jammy InRelease
Ign:5 http://packages.ros.org/ros2/ubuntu jammy InRelease
Ign:2 http://il.archive.ubuntu.com/ubuntu jammy InRelease
Ign:3 http://security.ubuntu.com/ubuntu jammy-security InRelease
Ign:7 http://il.archive.ubuntu.com/ubuntu jammy-updates InRelease
Ign:8 http://il.archive.ubuntu.com/ubuntu jammy-backports InRelease
Ign:6 https://packages.microsoft.com/repos/vscode stable InRelease
Ign:1 https://download.docker.com/linux/ubuntu jammy InRelease
Ign:4 https://dl.google.com/linux/chrome/deb stable InRelease
Ign:2 http://il.archive.ubuntu.com/ubuntu jammy InRelease
Ign:3 http://security.ubuntu.com/ubuntu jammy-security InRelease
Ign:5 http://packages.ros.org/ros2/ubuntu jammy InRelease
Ign:7 http://il.archive.ubuntu.com/ubuntu jammy-updates InRelease
Ign:8 http://il.archive.ubuntu.com/ubuntu jammy-backports InRelease
Err:6 https://packages.microsoft.com/repos/vscode stable InRelease
Could not resolve 'proxy-iil.intel.com'
Err:4 https://dl.google.com/linux/chrome/deb stable InRelease
Could not resolve 'proxy-iil.intel.com'
Err:1 https://download.docker.com/linux/ubuntu jammy InRelease
Could not resolve 'proxy-iil.intel.com'
Err:2 http://il.archive.ubuntu.com/ubuntu jammy InRelease
Could not resolve 'proxy-iil.intel.com'
Err:5 http://packages.ros.org/ros2/ubuntu jammy InRelease
Could not resolve 'proxy-iil.intel.com'
Err:3 http://security.ubuntu.com/ubuntu jammy-security InRelease
Could not resolve 'proxy-iil.intel.com'
Err:7 http://il.archive.ubuntu.com/ubuntu jammy-updates InRelease
Could not resolve 'proxy-iil.intel.com'
Err:8 http://il.archive.ubuntu.com/ubuntu jammy-backports InRelease
Could not resolve 'proxy-iil.intel.com'
Reading package lists... Done
W: Failed to fetch http://il.archive.ubuntu.com/ubuntu/dists/jammy/InRelease  Could not resolve 'proxy-iil.intel.com'
W: Failed to fetch http://il.archive.ubuntu.com/ubuntu/dists/jammy-updates/InRelease  Could not resolve 'proxy-iil.intel.com'
W: Failed to fetch http://il.archive.ubuntu.com/ubuntu/dists/jammy-backports/InRelease  Could not resolve 'proxy-iil.intel.com'
W: Failed to fetch http://security.ubuntu.com/ubuntu/dists/jammy-security/InRelease  Could not resolve 'proxy-iil.intel.com'
W: Failed to fetch https://download.docker.com/linux/ubuntu/dists/jammy/InRelease  Could not resolve 'proxy-iil.intel.com'
W: Failed to fetch https://dl.google.com/linux/chrome/deb/dists/stable/InRelease  Could not resolve 'proxy-iil.intel.com'
W: Failed to fetch http://packages.ros.org/ros2/ubuntu/dists/jammy/InRelease  Could not resolve 'proxy-iil.intel.com'
W: Failed to fetch https://packages.microsoft.com/repos/vscode/dists/stable/InRelease  Could not resolve 'proxy-iil.intel.com'
W: Some index files failed to download. They have been ignored, or old ones used instead.
My question :
Why do I have these failures and what is the impact on the next steps ?

Thank you 🙏
From: Hilary Luo @.>
Sent: Wednesday, June 28, 2023 18:25
To: turtlebot/turtlebot4 @.>
Cc: Ben-Haim, Yoram @.>; Author @.>
Subject: Re: [turtlebot/turtlebot4] Fail to install ros-humble-turtlebot4-desktop (Issue #206)
@deebothttps://github.com/deebot please ensure that you have gone through the full ros humble install instructionshttps://docs.ros.org/en/humble/Installation/Ubuntu-Install-Debians.html before attempting to install the turtlebot4 packages.
—
Reply to this email directly, view it on GitHubhttps://github.com/turtlebot/turtlebot4/issues/206#issuecomment-1611646102, or unsubscribehttps://github.com/notifications/unsubscribe-auth/AZGAF32HSQNBXALDVEPKGTLXNREF5ANCNFSM6AAAAAAZSPNRZU.
You are receiving this because you authored the thread.Message ID<EMAIL_ADDRESS>Intel Israel (74) Limited
This e-mail and any attachments may contain confidential material for
the sole use of the intended recipient(s). Any review or distribution
by others is strictly prohibited. If you are not the intended
recipient, please contact the sender and delete all copies.


Rebuild Item Names Database slow and never resets

The button that lets you rebuild the item names database only starts rebuilding the database the first time that it is pressed. This is because the RebuildItemDatabase(...) method is invoked by the constructor of the RebuildNamesDatabaseViewModel, and the viewmodel is only instantiated once for the lifetime of the application.
Besides that, the entire process is kinda slow and could be sped up by using the paginated items endpoint and by handling tasks asynchronously.

Funny, I was just noticing this myself...
See commits 8bcf466abc752e9f38ab42d49718ea13b3c7da42, e2bacc860e911caef0f6e298e69a66dacdc58976, and 423777da010db0e508a20b437bed05d425afd8db.

I'd like to propose a cleaner solution than what you added in 8bcf466abc752e9f38ab42d49718ea13b3c7da42


Create SOS Report to Troubleshoot customer environments

When troubleshooting in large environments, would like some kind of health report (or another name) to get vital signs of an environment.  This is not the same as getting all the logs.
For discussion:

Number of Appliances
ManageIQ version on each appliance
Server Roles enabled on each appliance (and its failover if applicable)
Number of each type of worker on each appliance and its allocated memory
Memory and CPU on Appliance
Appliance Platform
Database size
Replicated Databases

@gtanzillo @blomquisg @dmetzger57 @Fryguy @agrare
Talk amongst yourselves, discuss.

Not sure if appropriate, but first occurrence  of an error in the log?
Recent environmental changes? (I don't think that this can be automated.)

I think this PR, https://github.com/ManageIQ/manageiq/pull/14107, answers the appliances, roles, and workers part of the bullet points:  https://github.com/ManageIQ/manageiq/pull/14107.  If it's helpful, we can add the VERSION, and memory information in the existing rake task or add new ones that we log...
The memory information should be available and updated fairly often in

miq_servers:

system_memory_free
system_memory_used  (this + the above is the total RAM)
system_swap_free
system_swap_used (this + the above is the total swap)

miq_workers:

percent_cpu
cpu_time
os_priority
memory_usage (RSS)
memory_size (VSS)
proportional_set_size (PSS)

See https://github.com/sosreport/sos/wiki/How-to-Write-a-Plugin

We should investigate if that sosreport tool is worth formally plugging into, or if it just makes sense to just create a simple tools script to get what we need as a first pass, or just reuse an existing command like evm:status:full as @jrafanie said.
As a further explanation of the request here, it really isn't about large environments, but is for ANY environment where support is requested.  In other words, this report would be something that support must run/ask for as a first response in every ticket they respond to.  Right now, we always "ask for logs", but that is a very heavy handed request since the logs are huge and need to be parsed and reviewed to find what we are looking for.  Instead, this report is meant to be a single, simple command, with a simple 1-page text output, that can be dumped to a file or copied into an email or bug ticket, which gives support and/or developers the information that they almost always need and always ask for (we even ask for this stuff when we already have the logs, which is kind of silly, but the logs are so onerous).
If rake evm:status:full is the answer, that is fine, and if we want to enhance that, that is fine as well, however in addition to just having the script, we must also update our processes to ask for this report in every support case.

I definitely like the idea of evm:status:full.  Basically, anything we can pack into a one-liner.
And, if it's a one-liner, we could always have sosreport call that if that ends up being the end goal.

Oh, something else to add:
Region, Zone, Provider landscape
Region
|
|-- Zone 1
|   |
|   |-- Provider ABC
|   |   |
|   |   |-- Provider ABC Summary (# of Clusters, Hosts, VMs, Images, Instances, Containers, etc..)
|   |
|   |-- Provider 123
|       |
|       |-- Provider 123 Summary (# of Clusters, Hosts, VMs, Images, Instances, Containers, etc..)
|
|-- Zone 2
    |
    |-- Provider XYZ
    |   |
    |   |-- Provider XYZ Summary (# of Clusters, Hosts, VMs, Images, Instances, Containers, etc..)
    |
    |-- Provider 456
        |
        |-- Provider 456 Summary (# of Clusters, Hosts, VMs, Images, Instances, Containers, etc..)

@gtanzillo @blomquisg @dmetzger57 @Fryguy @agrare
Where are we with this? I do not want to get to the point where we hit another customer and wonder what happened to the SOS report?

Oh, something else to add:
Region, Zone, Provider landscape

There are already the tools/db_printers that do something similar that we can include into the single report.

Things that would be useful:

The provider landscape for all providers is critical as per @blomquisg
Status of connections (Netstat,etc...)
Current status of the Miq_queue (similar to count for states
DB health
I will add more as I think of them.

@bronaghs Can you make traction on a first cut of this.  Once in place, we can iterate and improve it.

@chessbyte - will do.

@miq-bot assign @juliancheal

Some indication to which features are used to allow understanding complexity and load in the environment around:

smartstate analysis
compliance policies - defined/used
chargeback reports / any reports (just how many were run / last timestamp)
auotmation - if/how many defined/used
service catalog items - count/types

@dmetzger57 help

@mfeifer I've done some work on this, but I keep getting delayed.

@juliancheal I'll reach out to you and setup a time when we can chat. I'm going to be dedicating part of my time helping @mfeifer effort to make field engineering faster/better/stronger

Perhaps a simple start is implementing a cli tool for gathering high level configuration / health information, initially providing the following information:

EVM status

Fine release and newer: 'rake evm:status_full'
Pre-Fine release: 'rake evm:status'

Inventory breakdown, see https://github.com/ManageIQ/manageiq/issues/14778#issuecomment-294569128
Miq_queue health

Total number of messages
Message count by method_name & state

Per-Appliance the output of free(1)
Per-Appliance Config

Enabled Roles
Worker counts

Of course taking into account multi-appliance, multi-zone, multi-region fun 😄
An SOS Report contains a massive amount of information, this suggestion looks to provide a light weight tool to begin gaining a perspective on the environment being supported, it can be added to an SOS Report if desired.

An SOS Report contains a massive amount of information

I think the whole point of an SOS Report is something that is relatively small that can be cut/paste in an email to get clarity on the user's environment.  This would precede the set of ManageIQ logs that tend to be massive and are typically shared via attachment or a link to an available storage location.
As @ohadlevy mentioned via email, perhaps we can borrow some ideas from the Foreman project here and here.


Printing broken in IE11 and Firefox

Using the v4 alpha documentation as a case in point, when printing in IE11 only the very first page is printed (instead of 17 or so pages, only 1 page is printed), while printing in Firefox results in all pages after the first one being offset to the left and cut off.

xref: https://github.com/twbs/bootstrap/issues/21083 and https://github.com/twbs/bootstrap/issues/20814#issuecomment-251591737

Printing works correctly in Chrome, Safari and Edge though

The *::first-letter selector in _print.scss is causing the problem in IE11:
https://github.com/twbs/bootstrap/blob/v4-dev/scss/_print.scss#L16
I could not reproduce this issue in Firefox v49.0.2 on Windows.
Related: https://github.com/h5bp/html5-boilerplate/pull/1799

@slavanga the first-letter issue was causing a crash. even after fixing, it in alpha 5, printing itself isn't working correctly in IE. see https://github.com/twbs/bootstrap/issues/20814#issuecomment-250981577

Zeroing in on the issue at least in Firefox, it appears related to flexbox and the sidebar in the docs. As soon as the sidebar isn't there anymore in the printed version (pages 2 and onwards), the main content is moved off-paper by the same width as the sidebar would have taken up in the printout. This may be a bug with Firefox...

As for IE11, initial trial and error suggests that removing
*,
  *::before,
  *::after,
  *::first-letter,
  p::first-line,
  div::first-line,
  blockquote::first-line,
  li::first-line {
    text-shadow: none !important;
    -webkit-box-shadow: none !important;
            box-shadow: none !important;
  }

from the bootstrap.css print styles also makes IE see/print the entirety of the page, rather than just the first page - likely a css parsing bug in IE?

ah, apologies @slavanga ... i got confused with the issue i solved regarding ::first-line. it does indeed seem specifically about *::first-letter in IE. scoping this the same way it was scoped for ::first-line fixes at least the IE issue.

The issue in Firefox appears to be a bug with how floated elements are handled across different pages - filed https://bugzilla.mozilla.org/show_bug.cgi?id=1315994

Firefox bug added to the Wall in f2bc3bec7cce34752ce27ade582dee6d3e060432.


entgql: mixed id types must be type string or implement the graphql.Marshaller/graphql.Unmarshaller interfaces

[x] The issue is present in the latest release.
[x] I have searched the issues of this repository and believe that this is not a duplicate.

Current Behavior 😯
Can I ask you why this error is happening on my project?
running ent codegen error="execute template \"client\": template: node.tmpl:377:16: executing \"client/fields/additional\" at <gqlIDType (filterNodes $.Nodes (skipMode \"type\")) $.IDType>: error calling gqlIDType: entgql: mixed id types must be type string or implement the graphql.Marshaller/graphql.Unmarshaller interfaces"

I'm trying to have some entities with id Uint64 and others with id String and I'm trying to use entgql.
The uint64 with default:
IDType: &field.TypeInfo{Type: field.TypeUint64},

The string one with code like:
field.String("id").NotEmpty().Unique().Immutable(),

Your Environment 🌎

Tech
Version

Go
1.18.3

Ent
entgo.io/contrib v0.2.1-0.20220601200333-78aa88292a62, entgo.io/ent v0.10.2-0.20220606082056-dd4519f935a6

Database
PG

Driver
pgdriver

I updated with the code I'm using.
This is REALLY a blocking issue for use right now. We are mixed ids because the DB is like this now unfortunately. We need to adapt to the DB.
Can you find the reason for this error? Do you already know how to fix it? Is it a quick thing?
Can you tell me how to work-around?

This and https://github.com/ent/ent/discussions/2631 are blocking our migration from Bun. So sad 😢

This is REALLY a blocking issue for use right now. We are using mixed ids because the DB is like this now unfortunately. We need to adapt to the DB.
Can you find the reason for this error? Do you already know how to fix it? Is it a quick thing?

As described in the returned error, I'm pretty sure you can wrap your integer type with a custom type that implemented the graphql.Marshaler interface (you can use the standard gqlgen ones).

This and https://github.com/ent/ent/discussions/2631 are blocking our migration from Bun. So sad 😢

I didn't see it yet tbh. I'll give it a look later.

Hello @frederikhors, I'm pretty sure this example from @giautm should help you get started.

Thanks, @crossworth ❤.
I think this example can also help - https://github.com/ent/contrib/pull/332. The entgql/internal/todogotype package contains multiple node types with different ID types and most of them implement the graphql.Marshaller interface.
I think we can support this use case without custom implementation btw, it will just make the codegen a bit messy, but it will work.

@crossworth @a8m thank you both.
I think I convinced the team to use strings for each ID, even though your suggestion worked.
I am also considering the use of ULID (since UUID 6,7,8) are still in RFC.
I would like to ask you if you know what the prefix that @giautm is using here is for: https://github.com/giautm/workspace-entgo/blob/main/ent/schema/pulid/mixin.go#L25.

It's called prefixed ULID, you can see the example in contrib repo: https://github.com/ent/contrib/blob/bea889a722a805cf78e25ebb939cc10636558d82/entgql/internal/todopulid/ent/schema/todo.go#L32-L33

Ok. Are you using this prefix because of the UNIVERSAL ID problem?

Am I right?

Prefix-based is a common way to extract the GraphQL type from the ID value in case you're using the Node API. It can be something else like base64 encoded with the type inside, but a query like node(id: $id) { ... } (in entgql, and in general) needs some indication of what table it needs to query in case you're using a database that does not support "global ids" (e.g. SQL).

Ok. Thanks, I'd got it right.

I think we can support this use case without custom implementation btw

@a8m, do you think we have to close this or leave it open for the sentence you wrote?

@a8m, do you think we have to close this or leave it open for the sentence you wrote?

I'm fine with closing it atm because I think this use case is not that common, especially when working with Node API. There are issues that can provide more value to the users (like https://github.com/ent/ent/issues/2600) and we prefer to focus on them for the next versions. So, closing this now, and we can consider adding it in the future in case it will be requested again.
Thanks ❤

Hi there
I get the same error:
Error: failed running ent codegen: execute template "client": template: node.tmpl:377:16: executing "client/fields/additional" at <gqlIDType (filterNodes $.Nodes (skipMode "type")) $.IDType>: error calling gqlIDType: entgql: mixed id types must be type string or implement the graphql.Marshaller/graphql.Unmarshaller interfaces
I have use case where some of the ids needs to be ints and others uuids:
// Fields of the User.
func (User) Fields() []ent.Field {
	timestamptzType := map[string]string{
		dialect.Postgres: "TIMESTAMPTZ",
	}
	varchar256Type := map[string]string{
		dialect.Postgres: "VARCHAR(256)",
	}

	return []ent.Field{
		field.UUID("id", uuid.UUID{}).Default(uuid.New),
		field.Time("created_at").SchemaType(timestamptzType).Default(time.Now),
		field.String("display_name").SchemaType(varchar256Type),
		field.String("email").SchemaType(varchar256Type),
		field.String("user_external_id").SchemaType(varchar256Type).Optional(),
		field.Bool("activated").Default(false),
		field.String("activation_code").SchemaType(varchar256Type).Optional(),
	}
}

and
// Fields of the Role.
func (Role) Fields() []ent.Field {
	serialType := map[string]string{
		dialect.Postgres: "SERIAL",
	}
	varchar256Type := map[string]string{
		dialect.Postgres: "VARCHAR(256)",
	}
	return []ent.Field{
		field.Int64("id").SchemaType(serialType),
		field.String("name").SchemaType(varchar256Type).Unique(),
		field.String("display_name").SchemaType(varchar256Type).Default(""),
	}
}

I don't know if i am doing something wrong or i missed something or i am just writing something stupid.


[5.2] If a collection is an indexed array before sorting, return an indexed array after sorting

I, along with some others, have been running into an interesting issue with Collections, specifically operating on sorted collections. The issue is that the sort method is currently maintaining the keys from the unsorted collection, this causes the items array to change from an indexed array to an associative array (if the order actually changes), which causes things like toJSON() to act differently. Note will only happen when the original collection is an indexed array. Here is an example:
$collection = new \Illuminate\Support\Collection([
    ['order' => 1],
    ['order' => 2],
    ['order' => 3]
]);
$collection->toJSON();

Will return:
[{"order":1},{"order":2},{"order":3}]

$sorted_collection = new \Illuminate\Support\Collection([
    ['order' => 1],
    ['order' => 2],
    ['order' => 3]
]);
$sorted_collection->sortBy('order')->toJSON();

Will return:
{"2":{"order":3},"1":{"order":2},"0":{"order":1}}

I believe this inconsistency to be a bug, and this PR will resolve it.

Tests?

@lucasmichot thanks for the feedback, I'll update the code now and add some tests.

This is a breaking change.

@GrahamCampbell Tests seem to be passing? Care to elaborate?

@lucasmichot I've added some tests that will both iterate the problem and showcase the solution, if you'd like to review again.

resubmitted


BUGFIX - Remove double check on passported route

Remove double check on passported route
What
Link to story
Describe what you did and why.
Checklist
Before you ask people to review this PR:

[ ] Tests and rubocop should be passing: bundle exec rake
[ ] Github should not be reporting conflicts; you should have recently run git rebase master.
[ ] There should be no unnecessary whitespace changes. These make diffs harder to read and conflicts more likely.
[ ] The PR description should say what you changed and why, with a link to the JIRA story.
[ ] You should have looked at the diff against master and ensured that nothing unexpected is included in your changes.
[ ] You should have checked that the commit messages say why the change was made.

Maybe just change the helm deploy value for now and we can change the function of the method at a later time?


svgr fails with latest Babel

Hi,
I'm not sure is it your bug or am I missing something, so I open it as a question.
I had it running using svgr v1, webpack v3 and babel v6. I used it only as webpack loader.
Now after upgrading svgr and babel to latest I'm getting this error:
ERROR in ./node_modules/icon-lib/my-icon.svg
Module build failed: .../node_modules/@svgr/core/lib/convert.js:24
async function convert(code, config = {}, state = {}) {
      ^^^^^^^^

SyntaxError: Unexpected token function
    at createScript (vm.js:56:10)
    at Object.runInThisContext (vm.js:97:10)
    at Module._compile (module.js:542:28)
    at Object.Module._extensions..js (module.js:579:10)
    at Module.load (module.js:487:32)
    at tryModuleLoad (module.js:446:12)
    at Function.Module._load (module.js:438:3)
    at Module.require (module.js:497:17)
    at require (internal/module.js:20:19)
    at Object.<anonymous> (.../node_modules/@svgr/core/lib/index.js:7:39)
 @ ./src/components/myComponent.js 41:0-64

I updated configs properly, at least I think so.
Btw, when I reverted it back to v1 (still using latest Babel), then it worked totally fine again. So I tried v2 and v3, and I got errors (a bit different ones tho).
Anyway, I'd really like to use latest svgr. Any advise?

@neoziro, you are right. I was targeting v8, but somehow node was using v6, even tho it was setup to use 8. Probably it was switched/reset somehow during OS update.
Anyway it works now.
Thanks for you input!
Closing it.


sub dependency issue

Trying to build paho-mqtt-cpp which requires paho-mqtt-c to be installed. Both projects are CMake based.
Able to get it to work with building cpp using cpm.make version, when the c version is installed manually.
But I would like to install both using cpm.cmake. here is my first try. but  the compilation of the cpp version fails with error as its not able to find the C version libraries in the library path.
Is it possible to install both versions thru cpm.cmake by linking the  paho-mqtt-c_LIBRARIES to paho-mqtt-cpp
CPMAddPackage(
            NAME paho-mqtt-c
            GIT_REPOSITORY https://github.com/eclipse/paho.mqtt.c.git
            VERSION 1.3.8
            OPTIONS "PAHO_ENABLE_TESTING OFF" "PAHO_WITH_SSL ON" "PAHO_HIGH_PERFORMANCE ON"
    )
#    libpaho-mqtt-3a and libpaho-mqtt-3c are built by the c version and needed for the compilation of paho-mqtt-cpp

    CPMAddPackage(
            NAME paho-mqtt-cpp
            GIT_REPOSITORY https://github.com/eclipse/paho.mqtt.cpp.git
            VERSION 1.2.0
            OPTIONS "PAHO_BUILD_STATIC ON"
    )

@TheLartians, that you for your efforts. I would like to know if something like the above(installing sub dependencies) is possible.

Hey, theoretically it is possible, as CPM creates FindXXX.cmake module files to allow dependencies to use find_package. However we are strongly dependent on library developers to create CMake scripts that work as independent modules - e.g. they should create and export their targets consistently in the CMake lists and module files.
I've done a small test run with your script above and was still running into installation issues after some trying. Maybe you could also open an issue asking for assistance at the paho-mqtt repositories.

@dpower5 did you find a solution to this?

No. I ended up using conan.
On Mon, Jul 25, 2022 at 2:46 PM Mohamed Saad Ibn Seddik <
@.***> wrote:

@dpower5 https://github.com/dpower5 did you find a solution to this?
—
Reply to this email directly, view it on GitHub
https://github.com/cpm-cmake/CPM.cmake/issues/262#issuecomment-1194671254,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/ABVRV3DLXOI74Z37ITS7ZHDVV4DJXANCNFSM46CPJSGA
.
You are receiving this because you were mentioned.Message ID:
@.***>


Remove range constraint on SOFTWARE.PACKAGE.performedBy (see issue 607).

Changes to address #607

[ ] TODO (Abha): generate OWL files (if necessary) based on sequencing with resolution of #600.
[ ] TODO (Abha?): update ScrapingToolKit/AutoGeneration/table.csv

Regarding the first TODO, #600 is merged and working, so no one needs to generate OWL files again :).

Thanks for merging this, @AbhaMoitra .  Did you want me to make a separate issue for the ScrapingToolKit/AutoGeneration/table.csv update or had you already taken care of that?

@kquick : we just discussed and realized that table.csv can be deleted; so no need for you to do anything about it.


fix: add min-width to cmdk menu

Closes #
📝 Description
Add min-width to cmdk menu.
⛳ Current behavior (updates)
The cmdk menu looks smaller than it should when searching some items
🚀 New behavior
Added min-width to cmdk menu so that it won't be shrunk.
💣 Is this a breaking change (Yes/No):
No.
📝 Additional Information
https://github.com/nextui-org/nextui/assets/62743644/99dfdff8-dadc-421a-8783-55851a70feba

Summary by CodeRabbit

Style

Improved layout consistency by updating the base styles of the cmdk component with a minimum width property.

@kuri-sun the width should not change when searching / opening, I mean it should be consistent

@jrgarciadev Sure! Thanks for the review! Alright, I will update this one! 👍

Updated the PR! Here is the demo for that!
https://github.com/nextui-org/nextui/assets/62743644/8b5ff4e2-db6e-40f1-b629-7e43a60d9c6c

It is better to give flex flex-col items-center w-full to this  element but this one is fromreact-aria.
If I have some time, I will contribute to react-aria to fix this so that our modal can have responsiveness without using useIsMobile!
Thank you for the review, @jrgarciadev!!

@kuri-sun could you please check the mobile version


Version 0.8 Release

Updated NuGet Package: https://www.nuget.org/packages/libsodium-net/0.8.0-beta1
Only change is to update to libsodium 1.0.3. If no issues, would like to release soon.
@fraga @bitbeans

Should be good @adacaudill

I tested StreamCryptor with the new beta package.
:+1:

Updated beta with SealedPublicKeyBox:
https://www.nuget.org/packages/libsodium-net/0.8.0-beta2

@adamcaudill are you still signing the releases?

Yes; just renewed my signing cert actually. 0.8.0 will be the first release with the new cert.

Great!

Released: https://github.com/adamcaudill/libsodium-net/releases/tag/v0.8.0


Only works with a specific username and password

I did not realise I had not set it up to work with different usernames or passwords as I was playing around with username and passwords in python so this needs to be fixed as it only uses the hardcoded username and password and will be updated over the next few days

I fixed this issue and added three attempts to get the correct username and password (shown in the readme and in the source code) as there was also an underlying bug that after 2 failed attempts the program would start as if you had inputted the correct credentials! But both are fixed and it is clear to use


Preprocessor introduces compiler error

Hi, new to ino here but grateful for it! Unfortunately, it seems to be introducing a compiler error in my sketch (below). I've attached the whole sketch for reproduction purposes. I simply have a new ino project with this as the only src file (sketch.ino). When I run ino build, it produces sketch.cpp (attached below) which has a clear error due to prepending function declarations to the top of the file. I ran it through cpp and this is not default behavior (obviously, but to be sure), so not sure if this is a bug with ino or my use of it! Please help, I really would like to use an enum in this way to clean things up.
By the way, running w/ Arduino Mega 2560, on Mac OS Yosemite. I've tried removing .build and rebuilding but same error.
Thanks!
#define FALSE         0
#define TRUE          1

/* pins */
#define RED_LED       6
#define BLUE_LED      4
#define GREEN_LED     8
#define PIN1          0
#define PIN2          1
#define POTPIN1       A0
#define POTPIN2       A1

/* misc */
#define ONE_SEC_DELAY 20
#define LED_ON        255
#define LED_OFF       0
#define SLEEP_DUR     15000

/* frequencies */
#define TEN_HERTZ     50
#define FOUR_HERTZ    125
#define TWO_HERTZ     250
#define ONE_HERTZ     500

/* global which tracks diagnostic errors */
int numErrors = 5;

/* contains interrupt state */
int switch1   = FALSE;
int switch2   = FALSE;

/* state computation */
enum states { ON, OFF, RUN, SLEEP, DIAG, MAX_STATES };

/* ---------- STATE FXNS ---------- */

enum states on(void) {
    digitalWrite(RED_LED, HIGH); delay(ONE_HERTZ);
    digitalWrite(RED_LED, LOW);  delay(ONE_HERTZ);

    return DIAG;
}

enum states off(void) {
    return OFF;
}

enum states run(void) {
    if (millis() > SLEEP_DUR) return SLEEP;

    float brightness = LED_ON, pot1Val = 0, pot2Val = 0;
    long prevMillisGreen = millis(),
         prevMillisBlue = millis(),
         currentMillis = 0;
    int fadeAmt = 5, blueLedStatus = 0, freq;

    while (1) {
        currentMillis = millis();

        pot1Val = analogRead(POTPIN1)  / 500.0;
        pot2Val = (analogRead(POTPIN2) / 1023.0) * LED_ON;

        long greenInterval = currentMillis - prevMillisGreen;

        /* flash green LED */
        if (greenInterval > 120 && brightness > 0) {
            prevMillisGreen = currentMillis;
            brightness -= fadeAmt;
            analogWrite(GREEN_LED, brightness);
        }
        else if (brightness <= 0) {
            if (greenInterval > 2000) {
                analogWrite(GREEN_LED, LED_OFF); return RUN;
            }
            else if (greenInterval > 1500) { analogWrite(GREEN_LED, LED_OFF); }
            else if (greenInterval > 1000) { analogWrite(GREEN_LED, LED_ON);  }
            else if (greenInterval > 500)  { analogWrite(GREEN_LED, LED_OFF); }
            else if (greenInterval > 0)    { analogWrite(GREEN_LED, LED_ON);  }
        }

        /* flash blue LED */
        long blueInterval = currentMillis - prevMillisBlue;
        freq = (switch1) ? TEN_HERTZ : ONE_HERTZ;
        freq *= pot1Val;

        if (blueInterval > freq) {
            prevMillisBlue = currentMillis;
            blueLedStatus = (blueLedStatus == 0) ? LED_ON : LED_OFF;
            analogWrite(BLUE_LED, blueLedStatus);
        }

        /* reduce brightness by number between 0 and 255 */
        if (switch2) analogWrite(RED_LED, LED_ON - pot2Val);

    }

    return RUN;
}

enum states sleep(void) {
    int i;
    for (i = 0; i < 4; ++i) {
        analogWrite(BLUE_LED, LED_ON);  delay(FOUR_HERTZ);
        analogWrite(BLUE_LED, LED_OFF); delay(FOUR_HERTZ);
    }

    int brightness = LED_ON, fadeAmt = 5;

    // fade LED
    while (brightness > 0) {
        analogWrite(BLUE_LED, brightness);
        brightness -= fadeAmt;
        delay(20);
    }

    analogWrite(BLUE_LED, LED_OFF);

    return OFF;
}

enum states diag(void) {
    int i;
    for (i = 0; i < numErrors; ++i) {
        digitalWrite(RED_LED, HIGH); delay(TWO_HERTZ);
        digitalWrite(RED_LED, LOW);  delay(TWO_HERTZ);
    }

    return RUN;
}

/* ---------- ISRs ---------- */

void setSwitch1(void) { switch1 = true; }
void setSwitch2(void) { switch2 = switch1; }

/* states fxns */
enum states (* state[])(void) = { on, off, run, sleep, diag };

void setup() {
    pinMode(RED_LED,   OUTPUT);
    pinMode(BLUE_LED,  OUTPUT);
    pinMode(GREEN_LED, OUTPUT);

    pinMode(POTPIN1,   INPUT);
    pinMode(POTPIN2,   INPUT);

    attachInterrupt(PIN1, setSwitch1, RISING); // NOTE should be FALLING
    attachInterrupt(PIN2, setSwitch2, RISING);
}

enum states curState = ON;

void loop() {
    curState = state[curState]();
    if (curState != RUN) digitalWrite(RED_LED, LOW);
}

.build/mega2560/src/sketch.cpp

#include <Arduino.h>

enum states on(void);
enum states off(void);
enum states run(void);
enum states sleep(void);
enum states diag(void);
void setSwitch1(void);
void setSwitch2(void);
void setup();
void loop();
#line 1 "src/sketch.ino"
#define FALSE         0
#define TRUE          1

/* pins */
#define RED_LED       6
#define BLUE_LED      4
#define GREEN_LED     8
#define PIN1          0
#define PIN2          1
#define POTPIN1       A0
#define POTPIN2       A1

/* misc */
#define ONE_SEC_DELAY 20
#define LED_ON        255
#define LED_OFF       0
#define SLEEP_DUR     15000

/* frequencies */
#define TEN_HERTZ     50
#define FOUR_HERTZ    125
#define TWO_HERTZ     250
#define ONE_HERTZ     500

/* global which tracks diagnostic errors */
int numErrors = 5;

/* contains interrupt state */
int switch1   = FALSE;
int switch2   = FALSE;

/* state computation */
static enum states { ON, OFF, RUN, SLEEP, DIAG, MAX_STATES };

/* ---------- STATE FXNS ---------- */

enum states on(void) {
    digitalWrite(RED_LED, HIGH); delay(ONE_HERTZ);
    digitalWrite(RED_LED, LOW);  delay(ONE_HERTZ);

    return DIAG;
}

enum states off(void) {
    return OFF;
}

enum states run(void) {
    if (millis() > SLEEP_DUR) return SLEEP;

    float brightness = LED_ON, pot1Val = 0, pot2Val = 0;
    long prevMillisGreen = millis(),
         prevMillisBlue = millis(),
         currentMillis = 0;
    int fadeAmt = 5, blueLedStatus = 0, freq;

    while (1) {
        currentMillis = millis();

        pot1Val = analogRead(POTPIN1)  / 500.0;
        pot2Val = (analogRead(POTPIN2) / 1023.0) * LED_ON;

        long greenInterval = currentMillis - prevMillisGreen;

        /* flash green LED */
        if (greenInterval > 120 && brightness > 0) {
            prevMillisGreen = currentMillis;
            brightness -= fadeAmt;
            analogWrite(GREEN_LED, brightness);
        }
        else if (brightness <= 0) {
            if (greenInterval > 2000) {
                analogWrite(GREEN_LED, LED_OFF); return RUN;
            }
            else if (greenInterval > 1500) { analogWrite(GREEN_LED, LED_OFF); }
            else if (greenInterval > 1000) { analogWrite(GREEN_LED, LED_ON);  }
            else if (greenInterval > 500)  { analogWrite(GREEN_LED, LED_OFF); }
            else if (greenInterval > 0)    { analogWrite(GREEN_LED, LED_ON);  }
        }

        /* flash blue LED */
        long blueInterval = currentMillis - prevMillisBlue;
        freq = (switch1) ? TEN_HERTZ : ONE_HERTZ;
        freq *= pot1Val;

        if (blueInterval > freq) {
            prevMillisBlue = currentMillis;
            blueLedStatus = (blueLedStatus == 0) ? LED_ON : LED_OFF;
            analogWrite(BLUE_LED, blueLedStatus);
        }

        /* reduce brightness by number between 0 and 255 */
        if (switch2) analogWrite(RED_LED, LED_ON - pot2Val);

    }

    return RUN;
}

enum states sleep(void) {
    int i;
    for (i = 0; i < 4; ++i) {
        analogWrite(BLUE_LED, LED_ON);  delay(FOUR_HERTZ);
        analogWrite(BLUE_LED, LED_OFF); delay(FOUR_HERTZ);
    }

    int brightness = LED_ON, fadeAmt = 5;

    // fade LED
    while (brightness > 0) {
        analogWrite(BLUE_LED, brightness);
        brightness -= fadeAmt;
        delay(20);
    }

    analogWrite(BLUE_LED, LED_OFF);

    return OFF;
}

enum states diag(void) {
    int i;
    for (i = 0; i < numErrors; ++i) {
        digitalWrite(RED_LED, HIGH); delay(TWO_HERTZ);
        digitalWrite(RED_LED, LOW);  delay(TWO_HERTZ);
    }

    return RUN;
}

/* ---------- ISRs ---------- */

void setSwitch1(void) { switch1 = true; }
void setSwitch2(void) { switch2 = switch1; }

/* states fxns */
enum states (* state[])(void) = { on, off, run, sleep, diag };

void setup() {
    pinMode(RED_LED,   OUTPUT);
    pinMode(BLUE_LED,  OUTPUT);
    pinMode(GREEN_LED, OUTPUT);

    pinMode(POTPIN1,   INPUT);
    pinMode(POTPIN2,   INPUT);

    attachInterrupt(PIN1, setSwitch1, RISING); // NOTE should be FALLING
    attachInterrupt(PIN2, setSwitch2, RISING);
}

enum states curState = ON;

void loop() {
    curState = state[curState]();
    if (curState != RUN) digitalWrite(RED_LED, LOW);
}

Ino Build Error:
src/sketch.ino
Scanning dependencies of src
src/sketch.cpp
.build/mega2560/src/sketch.cpp:3: error: use of enum 'states' without previous declaration
.build/mega2560/src/sketch.cpp:3: error: invalid type in declaration before ';' token
.build/mega2560/src/sketch.cpp:4: error: use of enum 'states' without previous declaration
.build/mega2560/src/sketch.cpp:4: error: invalid type in declaration before ';' token
.build/mega2560/src/sketch.cpp:5: error: use of enum 'states' without previous declaration
.build/mega2560/src/sketch.cpp:5: error: invalid type in declaration before ';' token
.build/mega2560/src/sketch.cpp:6: error: use of enum 'states' without previous declaration
.build/mega2560/src/sketch.cpp:6: error: invalid type in declaration before ';' token
.build/mega2560/src/sketch.cpp:7: error: use of enum 'states' without previous declaration
.build/mega2560/src/sketch.cpp:7: error: invalid type in declaration before ';' token
src/sketch.ino: In function 'states on()':
src/sketch.ino:37: error: new declaration 'states on()'
.build/mega2560/src/sketch.cpp:3: error: ambiguates old declaration 'int on()'
src/sketch.ino: In function 'states off()':
src/sketch.ino:44: error: new declaration 'states off()'
.build/mega2560/src/sketch.cpp:4: error: ambiguates old declaration 'int off()'
src/sketch.ino: In function 'states run()':
src/sketch.ino:48: error: new declaration 'states run()'
.build/mega2560/src/sketch.cpp:5: error: ambiguates old declaration 'int run()'
src/sketch.ino: In function 'states sleep()':
src/sketch.ino:100: error: new declaration 'states sleep()'
.build/mega2560/src/sketch.cpp:6: error: ambiguates old declaration 'int sleep()'
src/sketch.ino: In function 'states diag()':
src/sketch.ino:121: error: new declaration 'states diag()'
.build/mega2560/src/sketch.cpp:7: error: ambiguates old declaration 'int diag()'
src/sketch.ino: At global scope:
src/sketch.ino:137: error: invalid conversion from 'int (*)()' to 'states (*)()'
src/sketch.ino:137: error: invalid conversion from 'int (*)()' to 'states (*)()'
src/sketch.ino:137: error: invalid conversion from 'int (*)()' to 'states (*)()'
src/sketch.ino:137: error: invalid conversion from 'int (*)()' to 'states (*)()'
src/sketch.ino:137: error: invalid conversion from 'int (*)()' to 'states (*)()'
make: *** [.build/mega2560/src/sketch.o] Error 1
Make failed with code 2

I think the problem is that ino copies the behaviour of the Arduino IDE and inserts function prototypes at the top. This won't work if the functions use a type declared in the sketch. I think the solution is to define the enum in a header file and include that at the top. Hopefully the prototypes are inserted below the headers.
BTW in C++ states becomes a first class type, so you don't need the enum keyword before its uses.

See http://forum.arduino.cc/index.php?topic=109584.0

Worked great, thank you!


zk server failed

When I use zk server,it returns failed, I used rust 1.66 1.70 1.72 1.74 1.75 1.76
How to compile success?
error[E0277]: the size for values of type [u8] cannot be known at compilation time
--> core/lib/storage/src/chain/operations_ext/mod.rs:1444:15
|
1444 |         .map(|account| (start_account, Address::from_slice(&account)))
|               ^^^^^^^ doesn't have a size known at compile-time
|
= help: the trait Sized is not implemented for [u8]
= note: all function arguments must have a statically known size
error[E0282]: type annotations needed for Vec<T>
--> core/lib/storage/src/chain/state/mod.rs:623:17
|
623 |             let mut account_diff = Vec::new();
|                 ^^^^^^^^^^^^^^^^
...
642 |                 .map(|acc| acc.block_number())
|                                ------------ type must be known at this point
|
help: consider giving account_diff an explicit type, where the type for type parameter T is specified
|
623 |             let mut account_diff: Vec = Vec::new();
|                                 ++++++++
error[E0609]: no field from_block on type &_
--> core/lib/storage/src/ethereum/mod.rs:520:46
|
520 | ...   let (from_block, to_block) = (op.from_block as u32, op.to_block a...
|                                        ^^^^^^^^^^
warning: unused import: num::bigint::ToBigInt
--> core/lib/storage/src/chain/account/mod.rs:24:5
|
24 | use num::bigint::ToBigInt;
|     ^^^^^^^^^^^^^^^^^^^^^
warning: unused import: num::ToPrimitive
--> core/lib/storage/src/misc/mod.rs:9:5
|
9 | use num::ToPrimitive;
|     ^^^^^^^^^^^^^^^^
Some errors have detailed explanations: E0277, E0282, E0609.
For more information about an error, try rustc --explain E0277.
warning: zksync_storage (lib) generated 21 warnings
error: could not compile zksync_storage (lib) due to 319 previous errors; 21 warnings emitted

Try rust 1.77.1 (7cf61ebde 2024-03-27), it works on my machine.

Error about [u8] not being Sized:
You’re trying to use an array slice (&[u8]) in a way that requires its size to be known at compile time, but Rust doesn't know the size of slices ahead of time. To fix this, make sure the function Address::from_slice is expecting a slice (&[u8]) instead of an array. If you can edit Address::from_slice, change its parameter to accept a slice. The corrected function would look something like:

rust
Copy code
impl Address {
pub fn from_slice(slice: &[u8]) -> Self {
// Implementation goes here
}
}
And you’d use it like this in your map:
rust
Copy code
.map(|account| (start_account, Address::from_slice(account)))
2. Error about needing type annotations for Vec:
When you initialize a vector with Vec::new(), Rust needs to know what type of elements it will hold. If the type isn't specified elsewhere, you need to declare it when creating the vector. For example, if your vector is supposed to hold integers:
rust
Copy code
let mut account_diff: Vec = Vec::new();
This specifies that account_diff will hold values of type u32.

Error about no field from_block:
This error means you're trying to access a field (from_block) that Rust doesn't recognize for the given data type. Double-check the type of the variable op. Ensure it’s the correct type that should have the from_block field. If op is indeed the correct type but still causing errors, there might be an issue with how it’s defined or used.

 You can safely remove these imports to clean up your code:

rust
Copy code
// Remove or comment out these lines
// use num::bigint::ToBigInt;
// use num::ToPrimitive;
If any of these issues persist after you make changes, try running cargo check to get a quick overview of errors without compiling the whole project. This can help you catch issues faster.


enhancement: replace sort.Slice with slices.SortFunc to reduce reflection

Expected behavior
replace sort.Slice with slices.SortFunc to reduce reflection in the project, since 1.18 support generic.
And need import golang.org/x/exp package.
https://github.com/golang/exp/blob/master/slices/sort.go#L17
Is it appropriate to do so? if true, i will pr

Yes! Thanks for the suggestion and waiting for the PR.

#2929


Doesnt work

got an error when running this.

Thank you @rain-1 ,
surely with that kind of extensive information and full of details I surely will be able to help :)
Try the Google Colab version for a nearly hassle-free usage

i gave enough information.


Add back-to-top to index template (fixes #3)

After this change, back to top button shows up on the homepage. It was already enabled and showing correctly for tag/category/archive pages. Can delete branch after merge, if all OK.

Merged, thanks!  (I can't delete branches on your fork. :))


[core] feat: render bridge card example values into default values

This change causes the bridge parameter example values
(<input type="placeholder") to be rendered into default values
(<input type="value")
EDIT: This change causes all bridge forms to be filled with the example values. The prior behaviour was to only create a <input placeholder=""> for them.

I think this might break a bunch of things, right?
I think a lot of bridges react to "if XY not empty", which would break if you automatically transform an exampleValue to a defaultValue.
I like the difference in behavior of example and default, so I dont know if this change makes sense.

As I understand the code, this would only affect rendering of the bridge html form. It won't affect existing bridges (bridge urls)

I couldnt find one just now but what happens if there is a required field that needs input and an optional field that has an examplevalue. if you click on "generate feed" from the list view, will it also take in the examplevalue?

Yes the optional field will be filled with the example value. However if the required field is empty, it wont be possible to successfully submit the form.

Then I'm against it. I actually prefer the examplevalues in bridge overviews more than defaultvalues. Why do you want this change?

Here is the diff:
if ($inputEntry['exampleValue'] && !$inputEntry['defaultValue']) {
    $inputEntry['defaultValue'] = $inputEntry['exampleValue'];
}

The example value is copied into the default value, but only if the default value was empty.
This change makes it easier to manually test a bridge because we don't have to manually enter a value.

It's actually not an issue in automated testing. I take either or :)
https://github.com/Bockiii/rss-bridge-tester/blob/main/bridgetester.py#L31

I am against this change but there are some bridges where the example value should be a default value for the reason you mentioned.

I think I am misunderstanding how this works. Can someone give an example where this PR will give unwanted behaviour?

For example, Mozilla Bug Tracker Bridge:
The Bug ID is pretty much always going to be user provided input, so the user will have to manually erase the example -> default value every time, making it more tedious.

The default value is the value attribute on the <input type=text> element. This is initial value of the control.
If the user modifies the text then the browser will remember this state. If the user submits the form and then hits the back button in their browser, the initial value is not rendered into the control. The browser remembers the state and fills in what the user actually submitted.
The same goes for <select> and <option> and you might remember that you have hit refresh (F5) in your browser and the browsers remembers the option you selected.

Afaik this is the difference in behavior:
You have a non-mandatory field "firstname". If you fill this with the examplevalue "Peter" and the user clicks the "generate" button, the field value will be empty for the feed. If you fill this with a defaultvalue, the fieldvalue of "firstname" will be "Peter" for the function of the bridge. This means that bridge writers can never add an examplevalue to an optional field, as it will be picked up unintentionally by the generator (or you would have to delete the value from every pre-filled field).


As a Super Admin I can't edit my own Org details

I get the following error when I try to edit UCOP from the main Organizations list. I can edit all other Orgs, just not my own. This is using my UCOP Shib-enabled account.

working now. thanks @briri . closing issue.


Light domains error since 0.65

Home Assistant release (hass --version):
<IP_ADDRESS>
Python release (python3 --version):
python3 --version`
Component/platform:
light
Description of problem:
Since 0.65 I have a problem with light domain (in package or component).
When I try to define a light I received an configuration error (incomprehensible).
bdr@xenon /srv/homeassistant/conf/packages $ hassctl config
Testing configuration at /srv/homeassistant/conf

# Adding a light in a package (the first one of my configuration) :
bdr@xenon /srv/homeassistant/conf/packages $ vim light_test.yaml

light:
  - platform: yeelight
    devices:
      <IP_ADDRESS>:
        name: kitchen_floorlamp
        transition: 3000

bdr@xenon /srv/homeassistant/conf/packages $ hassctl config | head -n5
Testing configuration at /srv/homeassistant/conf
Failed config
  light:
    - Invalid config for [light]: required key not provided @ data['platform']. Got None. (See ?, line ?). Please check the docs at https://home-assistant.io/components/light/
[...]

Expected:
Working like the previous version (0.64.3)
Traceback (if applicable):
Testing configuration at /srv/homeassistant/conf
Failed config
  light:
    - Invalid config for [light]: required key not provided @ data['platform']. Got None. (See ?, line ?). Please check the docs at https://home-assistant.io/components/light/
[...]

Additional info:

If I add the light in a package, I have an error notification in the UI but the light appears and works correctly.

The following components and platforms could not be set up:
* light

If I configure a light directly in the configuration section of configuration.yaml everything works well.

Have someone information on this ?
Thanks in advance.

Seeing something similar, but not exact.  Since 0.65, yeelight control can turn bulb off, but attempt to turn bulb on results in a log message:
2018-03-13 11:58:00 ERROR (Thread-8) [homeassistant.components.light.yeelight] Unable to turn the bulb on: {'code': -5000, 'message': 'general error'}

I am having the same issue as @brahmafear with my Yeelight. Worked fine on v64.3 but now on v65.6 the light is not being turned on anymore with my [unchanged] automation.
Unable to turn the bulb on: {'code': -5000, 'message': 'general error'}

I don't think @brahmafear 's error is the same as this issue. Please open a new issue for that.


BUG: Problem with drop down option

Is there an existing issue for this?

[X] I have searched the existing issues

What happened?

When click on more link button a drop down box is appeared which is not properly implemented. So, kindly review my Issue and assign me this issue under GSSOC24.
Thank you.
Record

[X] I agree to follow this project's Code of Conduct
[X] I'm a GSSOC'24 contributor
[X] I want to work on this issue

Please assign me this issue.. I would like to work on this issue


Version is wrong in documentation

I'm going to update the documentation so this is probably irrelevant. Also, documentation will always reflect master.


OPA - Add UI information for complex Constraints parameters

What kind of request is this:
Enhancement
Steps to reproduce (least amount of steps as possible):

Add the labels parameter in a constraint using the k8srequiredlabels template with the following:

Key:
labels
Value:
[ { "allowedRegex": "^$|^[a-zA-Z0-9]+", "key": "gatekeeper" } ]
Result:
 { "type": "error", "links": {}, "code": "Invalid", "message": "K8sRequiredLabels.constraints.gatekeeper.sh \"test-labels\" is invalid: spec.parameters.labels: Invalid value: \"string\": spec.parameters.labels in body must be of type array: \"string\"", "status": 422 }

Expectation
We should add a UI information/warning element explaining this limitation in the Edit Form. And ask the user to use the Edit was YAML for complex parameters values.
Environment information

Rancher version: v2.4-head (05/19/2020) 8e20687a4
Installation option (single install/HA): Single

@izaac what was the exact input for parameters? I was able to add what you described, save it and view it.

Sure @codyrancher  I am using it like this using the form (without clicking Edit YAML):

This is the POST payload:
{
    "type": "constraints.gatekeeper.sh.k8srequiredlabels",
    "spec": {
        "match": {
            "excludedNamespaces": ["cattle-system", "gatekeeper-system", "kube-public", "kube-system"],
            "kinds": [{
                "apiGroups": [""],
                "kinds": ["Namespaces"]
            }],
            "labelSelector": {
                "matchExpressions": []
            },
            "namespaceSelector": {
                "matchExpressions": []
            }
        },
        "parameters": {
            "labels": "[ { \"allowedRegex\": \"^$|^[a-zA-Z0-9]+\", \"key\": \"gatekeeper\" } ]",
            "message": "All namespaces must use the `gatekeeper`  label"
        },
        "enforcementAction": "deny"
    },
    "metadata": {
        "name": "test-labels2",
        "annotations": {
            "cattle.io/description": null
        }
    }
}

Response:
{
    "type": "error",
    "links": {},
    "code": "Invalid",
    "message": "K8sRequiredLabels.constraints.gatekeeper.sh \"test-labels2\" is invalid: []: Invalid value: map[string]interface {}{\"kind\":\"K8sRequiredLabels\", \"metadata\":map[string]interface {}{\"annotations\":map[string]interface {}{\"cattle.io/description\":\"\"}, \"generation\":1, \"uid\":\"dff401a2-9a1a-11ea-8c49-0af40943c8e4\", \"name\":\"test-labels2\", \"creationTimestamp\":\"2020-05-19T21:51:20Z\"}, \"spec\":map[string]interface {}{\"enforcementAction\":\"deny\", \"match\":map[string]interface {}{\"kinds\":[]interface {}{map[string]interface {}{\"apiGroups\":[]interface {}{\"\"}, \"kinds\":[]interface {}{\"Namespaces\"}}}, \"labelSelector\":map[string]interface {}{\"matchExpressions\":[]interface {}{}}, \"namespaceSelector\":map[string]interface {}{\"matchExpressions\":[]interface {}{}}, \"excludedNamespaces\":[]interface {}{\"cattle-system\", \"gatekeeper-system\", \"kube-public\", \"kube-system\"}}, \"parameters\":map[string]interface {}{\"labels\":\"[ { \\\"allowedRegex\\\": \\\"^$|^[a-zA-Z0-9]+\\\", \\\"key\\\": \\\"gatekeeper\\\" } ]\", \"message\":\"All namespaces must use the `gatekeeper`  label\"}}, \"type\":\"constraints.gatekeeper.sh.k8srequiredlabels\", \"apiVersion\":\"constraints.gatekeeper.sh/v1beta1\"}: validation failure list:\nspec.parameters.labels in body must be of type array: \"string\"",
    "status": 422,
    "type": "error"
}

So for this it's not clear for a user new to the UI in what cases he should use Edit YAML or use the Input Fields, that's the goal of this issue.

@izaac @maggieliu are we okay with this messaging? If not, let me know what you'd like and I'll update it. I only show the banner when Edit as Form is being used.

@codyrancher this works for me, but will wait on @maggieliu preference.

@codyrancher I am good with the text. But I think this should be more of a @cloudnautique question.

@codyrancher / @maggieliu I'm good with the text.

What if we get rid of the parameters key value form and instead just have a yaml editor with a schema derived from reading the selected template?

@izaac I think we should close this issue in favor of rancher/dashboard#1777

Closing in favor of #1777


[BUG] multi-column sort doesn't respect priority

Describe the bug
From my testing, the sorting priority is determined by the order of the columns, NOT by which column the user sorts first.
First test:
The numbers columns is in the left, so it takes priority even if it has the second sort
https://user-images.githubusercontent.com/38974541/187449750-838a3fb0-e8d7-4475-841f-a174423b0c1d.mov
Second test
The letters columns is in the left, so it takes priority even if it has the second sort
https://user-images.githubusercontent.com/38974541/187449665-6719f94d-b371-4342-be47-649712a8eab8.mov
steps to reproduce

enable DND in developer section
restart obsidian
drag the column to the desired order
restart obsidian
sort the two columns
repeat the last steps and swap the order of the column to confirm behavior

files to reproduce
test15.md
test14.md
test13.md
test12.md
test11.md
test10.md
test9.md
test8.md
testing database.md
test7.md
test6.md
test5.md
test4.md
test1.md
test3.md
test2.md
Expected behavior
The sorting priority should be determined by the order of the sorting, not by the order of the columns in the database.
Desktop and Obsidian

macOS 12.3.1
Obsidian 0.15.9

Thanks @imeed166 as always. Added as subtask of https://github.com/RafaelGB/obsidian-db-folder/issues/127

You can also enable the table state to see which columns are sorted between other thinks

I checked but the behaviour after reordering seems fine for me
https://user-images.githubusercontent.com/11924043/187756317-f782c84e-d413-478e-ba88-00fe4a32f3ea.mov

You can see it in your video https://github.com/RafaelGB/obsidian-db-folder/issues/127#issuecomment-1232899061 at 0:06, the right column can never have the priority in sorting

But it has the second index. Do you mean that new sorts have to obtain the first priority moving +1 to the others?

let's say, for example, you have 3 columns in this order column 1 | column 2 | column 3 and you want to sort by all of them
You should be able to sort by C3 then by C2 then C1
but with current implementation you can only do C1 then C2 then C3 because of the order of the columns

I could reproduce it now, thanks for the explanation
https://user-images.githubusercontent.com/11924043/187871767-d6a81b3b-cbc4-4416-9590-5138ca6a9921.mov

Was a problem with the prev 2.0.0 architecture. Was updated
https://user-images.githubusercontent.com/11924043/187952990-e2b84219-48e6-41b8-9240-27b2a2cafacf.mov

Fixed. It needs a refactor for all the sort logic as inheritance of older versions
https://user-images.githubusercontent.com/11924043/187961149-62a208b5-1d6b-4cea-a4dc-b77a3c85ae6e.mov

The new sort works, but is not persisted (with version 2.3.4)
https://user-images.githubusercontent.com/38974541/188311668-4ba7d137-18f7-44ca-a5ad-cb5306763f00.mov


Extract into own Dockerfile

@lidel this works now and is ready to be merged into your jenkins-ci branch. We end up with a nice little zip file in our artifacts: https://ci.ipfs.team/blue/organizations/jenkins/IPFS Shipyard%2Fipfs-companion/detail/PR-366/5/artifacts


Present linguistic breakdown with stem and spelled out features

This is the suggestion for the first implementation of what is discussed in #99, using option 3 (modified here to include a preverb as well as a different actually attested stem). This does not rule out presenting the same information at the bottom of the full paradigms.

Basic relabeling using stem:
nikî-nitawi-wâpamâw ← √wâpam- + Verb + Preverb: nitawi + Transitive Animate + Independent + Future + Intentional + Actor: 1st Person Singular + Goal: 3rd Person Singular

Besides the normatized form of the search string, present a (?) or (!) radio button that, when clicked, gives the stem as well as the spelled-out version of the linguistic analysis features provided by the FST.
Search with:
nikiwapamaw
Primary result:
nikî-wâpamâw (?)
form of
wâpamêw
Secondary result: pressing (?) yields a pop-up with the following information:
wâpam- + Verb + Preverb: nitawi + Transitive Animate + Independent + Future + Intentional + Actor: 1st Person Singular + Goal: 3rd Person Singular
Tertiary result: preverbs and reduplicative elements are explicitly highlighted and presented
Preverb: nitawi- (?)
Pressing (?) yields:
'go and, go to; engaged in'
The relabeling required by this scheme can be directly implemented based on itwewina.relabel. However, on the longer run we likely will want to have a more robust representation of multiple English and Cree plain/linguistic variants for presenting linguistic features or row/column labels in generated paradigms.

Closing this in favour of #209.


fix path issues

Here's what I did to get this running on Windows. The changes in ClojureRepl.cs are a temporary hack. I think you def want the ones in Initialization.cs

This is being fixed as part of a larger effort to generalize out assumptions, most relevant commit being 560ed827. Integration with config to e.g. customize the load path should be the final nail in the coffin of these bugs.

Excellent. Glad you're working on it again!