(archlinux): Ansible could not initialize the preferred locale: unsupported locale setting

Summary
When i open ansible files, is right highlighted but throw the following error.
In Status bar i have Ansible info in red with this message :

Extension version
1.0.90 (and tried 1.0.98)
VS Code version
VSCodium 1.73.1 (release 22314)
Ansible Version
ansible [core 2.14.0]
  config file = /etc/ansible/ansible.cfg
  configured module search path = ['/home/orblazer/.ansible/plugins/modules', '/usr/share/ansible/plugins/modules']
  ansible python module location = /usr/lib/python3.10/site-packages/ansible
  ansible collection location = /home/orblazer/.ansible/collections:/usr/share/ansible/collections
  executable location = /usr/bin/ansible
  python version = 3.10.8 (main, Nov  1 2022, 14:18:21) [GCC 12.2.0] (/usr/bin/python)
  jinja version = 3.1.2
  libyaml = True

OS / Environment
Linux, 5.15.78-1-MANJARO
ansible-lint 6.8.6 using ansible 2.14.0
Relevant log output
cmd 'ansible-lint --version' was not executed with the following error: ' Error: Command failed: ansible-lint --version
Unable to find a working copy of ansible executable.

[Info  - 11:16:34 AM] [ansible-lint] ERROR: Ansible could not initialize the preferred locale: unsupported locale setting
Traceback (most recent call last):
  File "/usr/bin/ansible-lint", line 8, in <module>
    sys.exit(_run_cli_entrypoint())
  File "/usr/lib/python3.10/site-packages/ansiblelint/__main__.py", line 319, in _run_cli_entrypoint
    sys.exit(main(sys.argv))
  File "/usr/lib/python3.10/site-packages/ansiblelint/__main__.py", line 214, in main
    app = get_app(offline=options.offline)
  File "/usr/lib/python3.10/site-packages/ansiblelint/app.py", line 325, in get_app
    app = App(options=default_options)
  File "/usr/lib/python3.10/site-packages/ansiblelint/app.py", line 47, in __init__
    self.runtime = Runtime(isolated=True)
  File "/usr/lib/python3.10/site-packages/ansible_compat/runtime.py", line 96, in __init__
    self.config = AnsibleConfig()
  File "/usr/lib/python3.10/site-packages/ansible_compat/config.py", line 422, in __init__
    config_dump = subprocess.check_output(
  File "/usr/lib/python3.10/subprocess.py", line 421, in check_output
    return run(*popenargs, stdout=PIPE, timeout=timeout, check=True,
  File "/usr/lib/python3.10/subprocess.py", line 526, in run
    raise CalledProcessError(retcode, process.args,
subprocess.CalledProcessError: Command '['ansible-config', 'dump']' returned non-zero exit status 1.

[Error - 11:16:34 AM] An error occurred in 'onDidOpen' handler: [TypeError] Cannot read properties of undefined (reading 'has')
TypeError: Cannot read properties of undefined (reading 'has')
    at /home/orblazer/.vscode-oss/extensions/redhat.ansible-1.0.98-universal/out/server/src/server.js:2:44793
    at Generator.next (<anonymous>)
    at s (/home/orblazer/.vscode-oss/extensions/redhat.ansible-1.0.98-universal/out/server/src/server.js:2:42432)
    at process.processTicksAndRejections (node:internal/process/task_queues:96:5)

Hello,
This is output of CMDs:

ansible-config dump : https://gist.github.com/orblazer/05e6d5f4736d5e6b75803ed1dafa901b

set|grep -E LANG\|LC_ :
LANG=en_US.UTF-8
LC_ADDRESS=fr_FR.UTF-8
LC_ALL=en_US.UTF-8
LC_IDENTIFICATION=fr_FR.UTF-8
LC_MEASUREMENT=fr_FR.UTF-8
LC_MONETARY=fr_FR.UTF-8
LC_NAME=fr_FR.UTF-8
LC_NUMERIC=fr_FR.UTF-8
LC_PAPER=fr_FR.UTF-8
LC_TELEPHONE=fr_FR.UTF-8
LC_TIME=en_150.UTF-8 # This is for have french format

This is also weird because if i run the following command (output from vscode notification) directly in the vscode terminal i don't have any issues.
ansible-lint --offline --nocolor -f codeclimate "./main.yaml"

Are you using execution-environments by any chance with vscode extension? If you do it might explain why it fails as container engine might pass some of the locale senttings to the container and the container does not have them installed so it fails.

No, i never configure some execution-environments in vscode.

If you can reproduce this on a mainstream distribution rhel/centos/fedora/ubuntu/debian/wsl, we can fix it, if not we will likely close it as wontfix.
We would obviously accept a patch it if does not break supported platforms.

@orblazer Does running LC_TIME=en_150.UTF-8 ansible-config dump work? Originally you reported that it was working but I have some doubts.

Yes this is work fine :thinking: that is strange, but i have no longer the issue after i have change LC_TIME.

If you spot a case where only the extension fails but you can call ansible from your terminal and works fine, mention me as this would count as a high priority bug. Probably it worked with ansible 2.13, but in 2.14 that special check for valid locale settings was added, so we would ensure that the tool is working fine.
That means that with 2.13 you would not have known that some bits might not work well due to your locale, giving you the impression that all is ok.

@ssbarnea i seem to run into this problem, but i do not have any weird locale settings afaik.
locale output
LANG=en_US.UTF-8
LC_CTYPE="en_US.UTF-8"
LC_NUMERIC="en_US.UTF-8"
LC_TIME="en_US.UTF-8"
LC_COLLATE="en_US.UTF-8"
LC_MONETARY="en_US.UTF-8"
LC_MESSAGES="en_US.UTF-8"
LC_PAPER="en_US.UTF-8"
LC_NAME="en_US.UTF-8"
LC_ADDRESS="en_US.UTF-8"
LC_TELEPHONE="en_US.UTF-8"
LC_MEASUREMENT="en_US.UTF-8"
LC_IDENTIFICATION="en_US.UTF-8"
LC_ALL=

ansible --version
ansible [core 2.14.1]
  config file = /etc/ansible/ansible.cfg
  configured module search path = ['/home/user/.ansible/plugins/modules', '/usr/share/ansible/plugins/modules']
  ansible python module location = /usr/lib/python3.10/site-packages/ansible
  ansible collection location = /home/user/.ansible/collections:/usr/share/ansible/collections
  executable location = /usr/bin/ansible
  python version = 3.10.8 (main, Nov  1 2022, 14:18:21) [GCC 12.2.0] (/usr/bin/python)
  jinja version = 3.1.2
  libyaml = True

vscodium-bin on arch linux
Version: 1.74.1
Release: 22349
Commit: 13a0ba2641013eb7486bd33a6fa1f0b693177836
Date: 2022-12-15T18:22:01.285Z
Electron: 19.1.8
Chromium: 102.0.5005.167
Node.js: 16.14.2
V8: <IP_ADDRESS>-electron.0
OS: Linux x64 6.0.12-zen1-1-zen
Sandboxed: No

i could not debug this issue further, as i was not able to figure out what locale the ansible extension actually utilizes.
however, i followed the rather crude advice in https://github.com/microsoft/vscode/issues/62623:

uninstall ansible and python extensions
quit vscodium
start vscodium
reinstall both extensions
quit and restart once more

now the error message disappears and ansible extension works as expected.
#ihatecomputers

so it seems this was related to my kde plasmasession locale settings. i had set some European specific things, like currency format, metric system, etc. i've reverted them all to default, which fixed the problem.
alternativly you can start vscode / vscodium like so:
LANG=en_US.UTF-8 LC_CTYPE=en_US.UTF-8  which also fixed it
to figure out what locale your desktop session runs check /proc/(pid of i.e. plasmashell)/environ

i found my culprit: ~/.config/plasma-localerc had set LANG=en_150.UTF-8

@ssbarnea - I have exactly same problem running ansible command inside vscode terminal connected to container ansible installed in. However, when I attach to container's shell without vscode it works fine. I compared environments in-fact vscode pushes many environment variables.
Could you help me with... configuring vscode not to push it's environment when opening/connecting to container.

@ssbarnea - I have exactly same problem running ansible command inside vscode terminal connected to container ansible installed in. However, when I attach to container's shell without vscode it works fine. I compared environments in-fact vscode pushes many environment variables.
Could you help me with... configuring vscode not to push it's environment when opening/connecting to container.

I notice that the langue in my docker desktop is POSIX, but when I use vscdoe container to run it, i found i became en_US.UTF-8, so i just install the en language package and it works well
i use this command to install the package
apt install language-pack-en


fix(type): update heading-03 line-height

Closes https://github.com/carbon-design-system/carbon-website/issues/1604
Changelog
Changed

Updates heading-03 line-height values  to what exists in code

Reviewing
@jeanservaas if you could just verify that the rest of the line-height values are correct for the table, I have another PR up using the values directly from the website (https://github.com/carbon-design-system/carbon/issues/6711)

Hey @joshblack not sure what I'm doing wrong... I'm trying to change all the scale(5) type line height in the .json file. It should be 24px / 30px line height. But in the preview link it doesn't look like it changed at all.
And when I inspect, it still says 125% for the line height, which is what is says on the site currently.


Un-quarantine DataVolume disable/enable

What this PR does / why we need it:
When CDI is installed/removed virt-api and virt-controller are restarted.  Wait for that to complete.
Which issue(s) this PR fixes (optional, in fixes #<issue number>(, fixes #<issue_number>, ...) format, will close the issue(s) when PR gets merged):
Fixes #
https://search.ci.kubevirt.io/?search=test_id%3A3153&maxAge=336h&context=1&type=bug%2Bissue%2Bjunit&name=&excludeName=&maxMatches=5&maxBytes=20971520&groupBy=job
Special notes for your reviewer:
Checklist
This checklist is not enforcing, but it's a reminder of items that could be relevant to every PR.
Approvers are expected to review this list.

[ ] Design: A design document was considered and is present (link) or not required
[ ] PR: The PR description is expressive enough and will help future contributors
[ ] Code: Write code that humans can understand and Keep it simple
[ ] Refactor: You have left the code cleaner than you found it (Boy Scout Rule)
[ ] Upgrade: Impact of this change on upgrade flows was considered and addressed if required
[ ] Testing: New code requires new unit tests. New features and bug fixes require at least on e2e test
[ ] Documentation: A user-guide update was considered and is present (link) or not required. You want a user-guide update if it's a user facing feature / API change.
[ ] Community: Announcement to kubevirt-dev was considered

Release note:

NONE

/test pull-kubevirt-e2e-k8s-1.26-sig-operator
/test pull-kubevirt-e2e-k8s-1.27-sig-operator
/test pull-kubevirt-e2e-k8s-1.28-sig-operator

See https://github.com/kubevirt/kubevirt/pull/10771 and https://github.com/kubevirt/kubevirt/pull/10773

/test pull-kubevirt-e2e-k8s-1.26-sig-operator
/test pull-kubevirt-e2e-k8s-1.27-sig-operator
/test pull-kubevirt-e2e-k8s-1.28-sig-operator

/test pull-kubevirt-e2e-k8s-1.26-sig-operator
/test pull-kubevirt-e2e-k8s-1.27-sig-operator
/test pull-kubevirt-e2e-k8s-1.28-sig-operator

/test pull-kubevirt-e2e-k8s-1.26-sig-operator
/test pull-kubevirt-e2e-k8s-1.27-sig-operator
/test pull-kubevirt-e2e-k8s-1.28-sig-operator

/uncc


function run_file

Hi! Please add a file which has the function definition of run_file or explain it using comments. Thank you.

run_file is from parcelmouth, so you need to install it first. Then call it using,
from parselmouth.praat  import run_file


Exchange the different parts of resume[Feature]

I think it's better that we can exchange the education background to a higher position if I think it's more important

This will be one of the many features in the currently in progress v2 :) Please stay tuned!


What is the correct syntax for enabling python analyzer on jenkins

I tried using this syntax for doing the dependency check on Jenkins but it is not showing up any vulnerabilities for our code.
stage("Dependency Check Vulnerabilities") {
            steps {
                dependencyCheck skipOnUpstreamChange: false, odcInstallation: 'DefaultDependencyCheck', additionalArguments: ''
                dependencyCheckPublisher pattern: '**/dependency-check-report.*'

                archiveArtifacts allowEmptyArchive: true, artifacts: '**/dependency-check-report.html'
                archiveArtifacts allowEmptyArchive: true, artifacts: '**/dependency-check-report.xml'

            }
        }

Then I added https://pypi.org/project/insecure-package/0.1.0/ into the requirements.txt to see if that is picked up. It still showed there are no vulnerabilties. That leads me to believe that this is not working for python code. The same stage worked for Java projects. I looked at the docs and it seems that the python analyzer is enabled by default. Is there a way to do verbose logging to see what is happening here?

You probably need to add --enableExperimental for Python.
https://jeremylong.github.io/DependencyCheck/analyzers/python.html

I remember reading somewhere that this is enabled by default. I can try using this. This would go in additionalArguments as a string?


Error out when REAL_PATH is undefined on a system

Currently when PATH_MAX is undefined realpath will default to using 4096.
There is a potential stack overflow attack that can be mitigated by having
PATH_MAX defined. This change conservatively errors if a system does not
have PATH_MAX defined.
This change also comes with a new header specifically for freeBSD
to ensure that PATH_MAX will be available on that platform.
ref: http://pubs.opengroup.org/onlinepubs/9699919799/functions/realpath.html
ref: https://github.com/nodejs/node/issues/2680#issuecomment-213521708
ref: https://github.com/isaacs/node-glob/pull/259#issuecomment-213367860

/cc @saghul

This change passes the node.js CI --> https://ci.nodejs.org/job/node-test-commit-freebsd/2188/nodes=freebsd10-64/console

LGTM
/cc @libuv/collaborators WDYT?

One question, otherwise LGTM

LGTM

Landed in f617ccc, thanks!

🎉
@saghul should we backport this to node prior to the v6 release? I can't see any past instance of a floating patch from uv -> node

Please, don't. Next libuv release will have and Node will get it, I don't see the need for it as it doesn't solve a real problem found in the wild.

I'm not 100% convinced this fix is correct.  On FreeBSD (and, I think, the BSDs in general), PATH_MAX doesn't have to be defined unless _POSIX_C_SOURCE is defined.  We only define it on Linux currently, and only for the gyp build.

Ouch, mea culpa :-( If I was wrong and this is not the right fix please feel free to revert. I relied on the CI runs since I have no FreeBSD at hand right now, but completely forgot about GYP/autotools, sorry.

Sorry for leaving out context. The new realpath implementation was causing a breakage in glob
--> https://github.com/isaacs/node-glob/pull/259#issuecomment-213367860
@isaacs was hesitant to include a fix as he was worried about how secure the new implementation was and wouldn't land the fix.
tbqh I just wanted to make sure we were being extra safe with the release tomorrow
I do think that if there is any chance this is incorrect and will break builds, as alluded to by @bnoordhuis that this should be reverted. I've closed the PR on node and will not attempt to backport in the future.

No worries.
While the new realpath implementation surfaces some platform differences in some edge cases (IIRC) in glob, this fix does nothing to change that.
Now, if people feel super strongly about this (FTR, I don't) and a proper fix lands today I don't mind cutting a 1.9.1 release this evening. /cc @libuv/collaborators


"Only Email on Mention" settings is broken

Gitea version (or commit ref): 1.12.4
Git version: 2.20.1
Operating system: Debian 10
Database (use [x]):

[ ] PostgreSQL
[x] MySQL
[ ] MSSQL
[ ] SQLite

Can you reproduce the bug at https://try.gitea.io:

[x] Yes (provide example URL)
[ ] No
[ ] Not relevant

Log gist:

Description
When going to your account settings and choosing the “Only Email on Mention” settings, the will be no Emails sent at all, even if mentioned
We tried this on try.gitea.io and had the same problem. EMails are send out if you choose the standard setting to get notified always. And in that case the Emails also says that you have been mentioned.
https://codeberg.org/Codeberg/Community/issues/257

We need a new mock mail sender for tests.

ref #7813

Hi guys, I'm getting this exact issue in 1.13 RC1 as well. I think this patch would be in 1.13, but maybe I'm missing something, or maybe this is a new bug.
Thanks in advance,


Add PowerFx feature flag for User-defined types

Add PowerFx feature flag for User-defined types to show compile error when a function that uses UDT type argument is used when the feature is turned off. This PR also also fixes an error message string
I would also like to cleanup the Parser flag AllowTypeLiteral and use only feature flag, but that needs bit more refactoring and will do in a follow up PR

✅ No public API change.

✅ No public API change.

✅ No public API change.


accounts-db: use smaller thread pool for hash scan

Problem
During account's hash calculation, we are seeing slower block production.
Currently, calculating hash use accounts db clean threadpool to scan and compute account's hash cache.
Accounts-db clean thread pool uses 1/4 of cpus as the number of thread. For a 64 core machine that's 16 threads. 16 parallel threads scanning accounts storage and writing accounts' hash cache causes very heavy disk/io load, which affects foreground block producing process.
Summary of Changes

use a separate smaller thread pool for hash cache scan

Fixes #

I have been running this change on a test node on mnt.
It shows that the disk/io is reduced, from 3.6G to 2.4G.

The accounts hash time increases.
a) full hash time increase from 160s to 220s
b) incremental hash time increase from 3s to 5s.

Overall, I think 8 threads seems to be a good trade off for account's hash thread pool.

I realized the test machine has 48 cpus. So update the max to 6 threads.

yes. disk io reduced. before it was about 3.5G byte/s

I added another node to compare in your dashboard.
compare
It is showing that the replay time is better.

Also, there is no spike for uncleaned roots.

calculate hash takes more time 140M - 220M

tower distance is similar.

I think improvement on one node doesn't help much if the whole network is partitioned.

both machine in the comparison has the same spec: 48cores, 256G ram.

A possible alternative could be using par_chunks() in the code further down the call-stack where:
chunk_size = num_pieces_of_work / desired_thread_count

https://docs.rs/rayon/latest/rayon/slice/trait.ParallelSlice.html#method.par_chunks

A possible alternative could be using par_chunks() in the code further down the call-stack where:
chunk_size = num_pieces_of_work / desired_thread_count

https://docs.rs/rayon/latest/rayon/slice/trait.ParallelSlice.html#method.par_chunks

Yeah. That will be another way. One possible downside is that if the work load is not uniform among the pieces, this may not have a good load balance, i.e. some chunk has much larger work load than others.


[BUG] Cloning the project, and installing causes the pnpm lock-file to be changed

It is an unconfirmed issue, so I need someone else to verify the issue. Just clone the project, and install dependencies using pnpm install. If git detects any changes of pnpm-lock.yaml, send a screenshot, or a verbal report under the issue.

Never mind. Fixed the issue, and it was on my own end. Forgot to sync my fork, and was likely solved with a recent commit a3d67d4. I'm new to this open-source thing, and don't know much about it.


Replace cargo-generate with kickstart

I think it could be better to replace cargo-generate with a similar but more powerful tool kickstart. This tool supports custom template variables. This should free the user of most of the manual actions of replacing {{variables}} that aren't supported by cargo-generate.
If it makes sense to do so, I'll be happy to make a PR for this.

I think I'm on board with this. This seems like a straightforward way to improve the experience.
We are also thinking about making a more elaborate embedded-specific project creation tool, but that's definitely a longer-term project, so this seems like a good intermediate step.


Metaclass prepare executed out of order

According to PEP 3115, the __prepare__ method defined in a metaclass should be executed early, before the main body of the class using that metaclass as its type. But currently __prepare__ is executed after (and twice) so the dictionary-like objects it creates is not being used while the body of the class is being evaluated.
Example:
class Meta(type):
    @classmethod
    def __prepare__(metacls, name, bases):
        print("__prepare__ called")
        return dict(x="metaclass prepared")

class C(metaclass=Meta):
    print("class body executing")
    assert 'x' in dir() # IronPython fails

assert 'x' in dir(C) # passes if the previous assert is commented out

CPython:
__prepare__ called
class body executing

IronPython (after removing the assertions):
class body executing
__prepare__ called
__prepare__ called

Looks like I'm the one to blame for the double __prepare__ calls (https://github.com/IronLanguages/ironpython3/pull/174). Although I seemed to have been aware of the issues with it. 😃


Question: Is thera a way to transform uuid6 or uuid7 into datetime?

Since the value of there UUIDs is derived from time, is there a way to transform it back into datetime?

There's a .time property just like the of standard UUID module has it for UUID v1, which returns the timestamp as an integer. You have to use one of the datetime methods afterwards to convert it to a datetime though. UUID v6 uses the same offset as the standard UUID v1. UUID v7 epoch is the same as Unix epoch.
You can check couple of examples from the tests: https://github.com/oittaa/uuid6-python/blob/dc979a671f4a9112ad0cf1c7850aad8fbb169bde/test/test_uuid6.py#L105-L125

Something like this
import datetime
import uuid6

uuid_7 = uuid6.uuid7()
unixts, nanos = divmod(uuid_7.time, 10**9)
dt = datetime.datetime.utcfromtimestamp(unixts) + datetime.timedelta(microseconds=nanos//1000)

print(dt)

Wow this is amazing! Thanks a lot

I tried using the above example to solve my own issue with a Django model, but I must be doing something wrong.
Here is my code in one of my models:
    import datetime, uuid6

    def date_added_from_uuid7(self):
        # uuid_7 = uuid6.uuid7()
        uuid_7 = self.id

        unixts, nanos = divmod(uuid_7.time, 10**9)

        dtp = datetime.datetime.utcfromtimestamp(unixts) + \
            datetime.timedelta(microseconds=nanos//1000)

        dt = dtp.strftime("%Y-%m-%d")
        return dt

When I use the uuid_7 = uuid6.uuid7() value as provided in the example, the date returned is 1970-01-01
When I use my actual self.id, the date returned is 2005-10-04 but the date expected was 2023-05-30, which is set in a separate date_added column that I am hoping to get rid of, since I have the uuid7 id column already


performance regression in 2.8.0

More of a question than a bug report. There is a significant performance regression from 2.7.3 -> 2.8.0 in situations with lots of data points. It seems to be related to _resolvePointOptions in updateElement.
Codepens demonstrating the performance difference:
2.7.3
2.8.0
(the y-value of the top trace is based on the time taken to update the graph).
A more general question: Is there a more performant route for displaying homogenous, data-heavy traces? (such as a line with 1000 points, all with the exact same properties, other than position)
edit: master is a bit better, but still slower than 2.7.3 in this case, and about 40% of the time appears to be spent in _resolveDataElementOptions.

I've been bothered by this as well and agree it should be possible to improve performance. I had one idea here: https://github.com/chartjs/Chart.js/pull/6266. I'm not actively working on this, so if someone wants to take it over I'd be happy to talk through the design ahead of time and then review the code for any PR


Relax code guide rules about docstrings

https://chat.stackexchange.com/transcript/message/58909173#58909173

Sorry, I shouldn't really keep requesting your review; I should wait until I'm finished

Sorry @Lyxal, I shouldn't really keep requesting your review; I should wait until I'm finished

It's only fair after I requested review from y'all so many times for #218 ;P


Auto clear the character popup text search field

The main character page search box auto clears when returning to the index page. (expected behaviour)
However the popup remembers your last text input which means you have to manually clear it each time.
I don't think there's a reason to retain the previous text search.
https://streamable.com/nvcx4y

Fixed by #1105


Remove flag for CustomAction

hi,
can you please give an example of how to use the Remove flag for CustomAction? I tried it in many ways but it doesn't do anything.
Thanks,

Hi,
You simply need to use Remove="true" and if it doens't work as expected, please file an issue in the PnP-Sites-Core repository. Moreover, in order to have a prompt answer I suggest you to use the Microsoft Tech Community site (https://techcommunity.microsoft.com), instead of this. I will close this item and create another one in the PnP Sites Core repository, referencing this one.


TypeError: Not assignable to parameter of type ZodType<any, any, any>

I've created this schema to use in React Hook Form, but I'm getting an error that I'm not sure how to fix.
import { z } from 'zod';

export const schema = z.object({
  email_domains: z.string().min(1, { message: 'At least one domain is required' }),
  add_to_groups: z.string(),
  expires_at: z.string(),
  language: z.string(),
  name: z.string().min(1),
});

export type FormValuesType = z.infer<typeof schema>;

import { zodResolver } from '@hookform/resolvers/zod';
import { FormProvider, useForm } from 'react-hook-form';

import { defaultExpiresAt, defaultName } from '@/lib/invite-links';

import {
  FormValuesType,
  schema,
} from '@/components/InviteLinkCreatePage/schema';

export default function Form() {
  const methods = useForm<FormValuesType>({
    resolver: zodResolver(schema),
    values: {
      email_domains: '',
      add_to_groups: '',
      expires_at: defaultExpiresAt(),
      language: '',
      name: defaultName(),
    },
  });

  const handleSubmit = (data: FormValuesType) => {
    console.log({ data });
  };

  return (
    <FormProvider {...methods}>
      ...
    </FormProvider>
  );
}

The error coming back is:
Argument of type 'ZodObject<{ email_domains: ZodString; add_to_groups: ZodString; expires_at: ZodString; language: ZodString; name: ZodString; }, "strip", ZodTypeAny, { ...; }, { ...; }>' is not assignable to parameter of type 'ZodType<any, any, any>'.
  The types of 'refine(...)._def.typeName' are incompatible between these types.
    Type 'import("/Users/ernstoarllano/Sites/dispel/packages/cweb/node_modules/zod/lib/types").ZodFirstPartyTypeKind.ZodEffects' is not assignable to type 'Zod.ZodFirstPartyTypeKind.ZodEffects'.
      Property 'ZodReadonly' is missing in type 'Zod.ZodFirstPartyTypeKind'.

I am having the same issue. I think it happened because I updated zod from 3.21.4 to 3.22.1

I am using a monorepo and it appears zod is already included. Removing the extra package did the trick. Was that the case for you as well?

Thanks! I needed zod as a dependency so I just downgraded it to v3.21.4. I think that v3.22.0 and later are not compatible with some dependent libraries (like @hookform/resolvers) due to ZodReadonly.

Thanks! I needed zod as a dependency so I just downgraded it to v3.21.4. I think that v3.22.0 and later are not compatible with some dependent libraries (like @hookform/resolvers) due to ZodReadonly.

Thanks I got exactly the same error in v3.22.1 and v3.22.0 and downgrading to v3.21.4 resolved it

I am having the same issue. Downgrading to v3.21.4 resolved it.

I think a solution for<EMAIL_ADDRESS>was just patched yesterday in react-hook-form/resolvers. https://github.com/react-hook-form/resolvers/commit/e5e73466e0f2e098c022ef9c373d5fa82cea7306#diff-7ae45ad102eab3b6d7e7896acd08c427a9b25b346470d7bc6507b6481575d519L257-R256
It has not been pushed to npm yet.

<EMAIL_ADDRESS>worked for me

In the context of a monorepo my team was able to fix it by adding a nohoist option to the proper workspace for @hookform/resolvers.

<EMAIL_ADDRESS>and @hookform/resolvers: ^3.3.0 worked for me

In the context of a monorepo my team was able to fix it by adding a nohoist option to the proper workspace for @hookform/resolvers.

"workspaces": {

    "nohoist": [

      "@hookform/resolvers"

    ]

}

I don't understand why this fixes it? Although I have not tried your suggestion, all the related package versions in my monorepo have the same version. So this should not be needed, right?

I'm still having this issue on v3.21.0 -> 3.22.1. I'm using Zod with VeeValidate in Nuxt. Example below:
const passwordSchema = z.object({
  currentPassword: z.string(),
  newPassword: z.string().min(8),
  confirmNewPassword: z.string().min(8),
});
const validationSchema = toTypedSchema(passwordSchema);

On the last line, I get a TS error on passwordSchema saying:
Argument of type 'ZodObject<{ currentPassword: ZodString; newPassword: ZodString; confirmNewPassword: ZodString; }, "strip", ZodTypeAny, { currentPassword: string; newPassword: string; confirmNewPassword: string; }, { ...; }>' is not assignable to parameter of type 'ZodType<any, ZodTypeDef, any>'.
  The types of 'refine(...)._def.typeName' are incompatible between these types. ts(2345)

I didn't have this error until recently, so I wonder if it is an issue with a related dependency?

<EMAIL_ADDRESS>and @hookform/resolvers: ^3.3.0 worked for me

this is working for me as well, version 3.22.2 of zod was not. Thanks! 🎉

<EMAIL_ADDRESS>and @hookform/resolvers: ^3.3.0 worked for me

Sane here

<EMAIL_ADDRESS>and @hookform/resolvers: ^3.3.0 worked for me

Same here

Same, but why is it broken on the latest version

Same issue, currently using<EMAIL_ADDRESS>and @hookform/resolvers: ^3.3.1

Same issue, currently using<EMAIL_ADDRESS>and @hookform/resolvers: ^3.3.1

Same issue I am now using<EMAIL_ADDRESS>and @hookform/resolvers: ^3.1.0
Upgrade, reload vscode and it will work

Developer Community Rocks :)
npm install<EMAIL_ADDRESS>
"@hookform/resolvers": "^3.3.1"

<EMAIL_ADDRESS>and @hookform/resolvers: ^3.3.0 worked for me

Same, but why is it broken on the latest version
workarround is downgrade to<EMAIL_ADDRESS>thnks guys

"zod": "^3.21.4"
"@hookform/resolvers": "^3.3.1"

this is what worked here, after restarting vscode, thx

This worked for me
remove node_modules
pnpm store prune
pnpm install

This worked for me remove node_modules
pnpm store prune
pnpm install

This worked for me but wasn't immediately apparent; I had to Reload windows in VS Code.

Zod V3.22.3 is out and I now get no lint errors 😊  Thanks!

const passwordSchema = z.object({
  currentPassword: z.string(),
  newPassword: z.string().min(8),
  confirmNewPassword: z.string().min(8),
});
const validationSchema = toTypedSchema(passwordSchema);

I've upgraded to Zod 3.22.3 and it seems to have fixed the issue (or at least changed the error message). With the example above, I now get the message Type instantiation is excessively deep and possibly infinite.ts (2589)

In case anyone else is being daft like me - I encountered this error in my monorepo (turborepo). I had forgotten to install zod to one of the places I was using it.

Updating to the latest zod 3.22.4 fixed it for me 👍

In my case this is my code
const FormSchema = z.object({
firstname: z.string({
  required_error: "Nombre es requerido",
}).min(3, {
  message: "Nombre debe tener al menos 3 letras",
}),
lastname: z.string({
  required_error: "Apellidos son requeridos",
}).min(3, {
  message: "Nombre debe tener al menos 3 letras",
}),
cc: z.coerce.number({
  required_error: "Documento es requerido",
  invalid_type_error: "El documento debe ser numérico",
}).int().gte(10000000, {
  message: "Cedula debe tener al menos 8 digitos",
}).lte(9999999999, {
  message: "Cedula no puede tener más de 10 digitos",
}),
phone: z.coerce.number({
  required_error: "Teléfono requerido",
  invalid_type_error: "El teléfono debe ser numérico",
}).int().gte(3000000000).lte(3299999999),
contactPhone: z.coerce.number({
  required_error: "Teléfono requerido",
  invalid_type_error: "El teléfono debe ser numérico",
}).int().gte(3000000000).lte(3299999999),
contactName: z.string({
  required_error: "Nombre contacto es requerido",
}).min(3, {
  message: "Nombre debe tener al menos 3 letras",
}),
rh: z.string({
  required_error: "Por favor seleccione un grupo sanguíneo",
}).min(2).max(3),
birthdate: z.date({
  required_error: "Fecha de nacimiento es requerida",
}),
bio: z
  .string()
  .min(10, {
    message: "Información debe tener al menos 10 carácteres",
  })
  .max(160, {
    message: "Información no debe tener más de 160 carácteres",
  }),
eps: z.string({
  required_error: "Por favor seleccione una EPS",
}),
});

const form = useForm<z.infer<typeof FormSchema>>({
  resolver: zodResolver(FormSchema),
})

I'm working with Zod 3.22.4, but still have the issue
 Argument of type 'ZodObject<{ firstname: ZodString; lastname: ZodString; cc: ZodNumber; phone: ZodNumber; contactPhone: ZodNumber; contactName: ZodString; rh: ZodString; birthdate: ZodDate; bio: ZodString; eps: ZodString; }, "strip", ZodTypeAny, { ...; }, { ...; }>' is not assignable to parameter of type 'ZodType<any, any, any>'.
 The types of 'refine(...)._def.typeName' are incompatible between these types.
   Type 'import("C:/Users/hemag/OneDrive/Documents/GitHub/volt-riders/node_modules/.pnpm/zod@3.22.4/node_modules/zod/lib/types").ZodFirstPartyTypeKind.ZodEffects' is not assignable to type 'Zod.ZodFirstPartyTypeKind.ZodEffects'.
     Property 'ZodReadonly' is missing in type 'Zod.ZodFirstPartyTypeKind'.ts(2345)

This worked for me remove node_modules
pnpm store prune
pnpm install

This definitely works even with latest packages version:

"zod": "^3.22.4"
"@hookform/resolvers": "^3.3.2",

3.22.4 and rm -rf node_modules did not fix it for me.
Downgrade to 3.21.4 works.

Downgrading to 3.21.4 works for me, 3.22.4 does not.

3.22.4 not working for me as well

This worked for me remove node_modules
pnpm store prune
pnpm install

thanks, this works

My case was in a monorepo with zod types for an express API used with Sveltekit-Superforms where the package wouldn't have context on the zod schemas as they'd be any, but the v3.21.4 version throughout all packages worked wonders 🎉

"zod": "link:@hookform/resolvers/zod"
This works for me.

**masonbrothers ** commented Aug 16, 2023 •

works thanks 🥲

This happened to me with v3.24.0 and v3.24.1. I was able to avoid it by reverting to v3.23.8.
That helped, thanks.


Any interest in putting this on conda-forge?

First I want to say thanks for a great package! My colleagues and I have gotten great use out of it. We are making our own software package that we would like to make available on conda-forge so it can easily be installed via conda. However, all dependencies have to be packaged by conda-forge as well. smt is the only dependency that we have that is not on conda-forge, so I'm curious if this is of any interest in doing this, and/or if you have the time.
Thanks again!

Happy to hear you find SMT useful. Regarding your request SMT is already available on conda-forge. Only there was a packaging problem with SMT 2.1 and 2.2 releases, but I've just fixed it with the 2.2.1 release, so...

Thank you @relf! I was able to install smt 2.2.1 via conda forge so I'm all set.


Turning off sourcemaps

I would like to turn off sourcemaps. Is there a configuration for it?

There will be shortly: PR #3113

@davidstellini in the case that the PR doesn't get merged soon (or in the next release) an option is to edit node_modules/angular-cli/models/webpack-build-.js you can find the "sourceMap" option, you can also add comments: false if you want to remove those.

Fixed in #3113


GCP: Implement Cross Resource Referencing for resource types

Description of your changes

Fixes https://github.com/crossplaneio/crossplane/issues/888
Checklist

I have:

[x] Run make reviewable to ensure this PR is ready for review.
[x] Ensured this PR contains a neat, self documenting set of commits.
[ ] Updated any relevant documentation, examples, or release notes.
[ ] Updated the dependencies in app.yaml to include any new role permissions.

@negz address your comments along with a few comment fixes.


Fixes #69 : Introduction-Francois-Werbrouck

Introduction of Francois Werbrouck following the onboarding process
Adds: Section about Francois in the team presentation files

I had to solve conflicts and I had issues with the merging of Maxence's PR. This allowed me to better learn about some Git commands. I think the files are now up to date and they should follow the standards set by the company.

Repeteadly running on basic markdown formatting problems.
@FrancoisWerbrouck-CFIA add markdown linter github workflow to catch these:
https://github.com/ai-cfia/github-workflows/blob/main/.github/workflows/workflow-markdown-check.yml
https://github.com/ai-cfia/github-workflows/blob/main/.github/workflows/workflow-markdown-check.md


lua script not working

What is your question?
So I have a lua script that's supposed to make a BG sprite slowly move up and down but has no effect. I'm most likely being a goofy goober and missing something.
here is the code
runTimer('spacerocks', 3, 0);
function onTimerCompleted(tag)
if tag == 'spacerocks' then
if getProperty('spacerocksY') == -65 then
doTweenY('spacerocksY', 'spacerocks', -30, 2.9, 'quadInOut')
else
doTweenY('spacerocksY', 'spacerocks', -65, 2.9, 'quadInOut')
end
end
end

you didn't put runTimer under any function

I just tried that but still didn't work

what did you try

i see what's also wrong
why is it getProperty('spacerocksY') instead of getProperty('spacerocks.y')

Making runTimer have a loop amount of 0 won't work, the loop amount must be 1 or higher for it to work, I found this out the hard way (as in my game crashed when it I tried)
Now that I think about it, that doesn't really make sense, the premade dialogue script runs a timer without loops defined and that works

okay the tag in onTimerCompleted is also wrong

Making runTimer have a loop amount of 0 won't work, the loop amount must be 1 or higher for it to work

no it works just fine

runs a timer without loops defined

that means loop is set to 1


Documentation Improvements

Description
This PR:

Makes the API button direct to correct rustdoc page
Adds a tutorial button for better visibility
Adds blog

Don't think we really need the blog, but it doesn't hurt to put new releases on there.

I agree. That's why I added this in #2312:

Add a blog. Even if there won't be frequent posts, a blog post for release sounds good to have.

I'm going to merge this. CI issues are unrelated.
@voidpumpkin Can you look at why benchmark is messing up clippy?


Fix duplicate keyword

There was a duplicate "ddc-buffer-param-fromAltBuf".

Thank you for the PR! I added new option and forgot to change the param's name...
So I'll fix it.

Ok, thank you.


Write knowledge base article about FREME NER

It should cover how FREME NER works internally.

first draft is available at: http://api-dev.freme-project.eu/doc/knowledge-base/freme-ner.html

Thank you. @m1ci is this the final version? Can we close this issue?

I will extend it with the requirements from https://github.com/freme-project/Documentation/issues/166

the article has been extended with the requirements from https://github.com/freme-project/Documentation/issues/166

Good work! Just one comment: I sometimes get questions why entities are not spottet in a text like "hello world abc berlin". Maybe you can add a paragraph to the tips section that explains that entity spotting and linking works best on clean text which means correct grammar, correct spelling (including capitalization), correct punctuation marks, ...

Good work! Just one comment: I sometimes get questions why entities are not spottet in a text like "hello world abc berlin". Maybe you can add a paragraph to the tips section that explains that entity spotting and linking works best on clean text which means correct grammar, correct spelling (including capitalization), correct punctuation marks, ...

Very valid comment! will definitely add that. Thanks.

done. see Tips section.
https://github.com/freme-project/Documentation/blob/master/_pages/knowledge-base/freme-ner.md

Thanks


Added FS lua optimisation pdf

added to assets so we can link to it in the wiki docs

I think we should just copy paste the content into the wiki to make it more accessible

Good idea


CLOUDP-269299: Update changelog-report to list the spec correction changes

Proposed changes

Jira ticket: CLOUDP-269299
This PR updates the changelog report message to include spec correction (changes that are hidden from the changelog)

where does it way that they are spec corrections in the screenshot?


Console errors: could not evaluate undefined.undefined

Describe the bug
Console errors:
8 Mar 06:31:21 - [error] [time-inject:At sunrise] could not evaluate undefined.undefined
8 Mar 17:36:38 - [error] [time-inject:At dusk start] could not evaluate undefined.undefined
9 Mar 06:29:54 - [error] [time-inject:At sunrise] could not evaluate undefined.undefined

System information (please complete the following information):

Node v15.4.0 (npm 7.6.1)
Node-Red v1.2.9

Additional context

This issue leads to the fact that no output is defined. But this error could also occurs if nomsg output is defined.
I had already fixed this in the version which in in development.
Still, thank you for reporting the bug!

@Hypnos3 thanks for taking a look! In my case, I do not use msg (nomsg) context or anything like that. I just want to trigger my automation when the time happens and my flow looks like this:

Yes, but in Node-RED a valid message should have a payload property, even if it is an empty string.
Anyway, it is still fixed in the dev branch.
Until the next version is released, adding msg.payload as empty string should help to avoid this error.

Hi, just to say that I've also hit this issue.
However, please note that a msg does not need to have a msg.payload at all. I think that you are trying to do something with msg.payload and not allowing for it not being there.
Even the standard inject function no longer needs a payload - in fact, you don't have to set any properties at all.

Also, that message in output is still there, so I assume that dev version wasn’t released yet.

I had already fixed this in the version which in in development.

Is integrated in the 2.0.0-beta and can be installed and tested. See Releases Information on how to install the beta version.


SCons: Fix output with vsproj=yes

A handful of tweaks/fixes all related to passing vsproj=yes to SCons:

Ensure *.vcsproj.filters has a designated section for "Other Files". On live, the files designated to it (.glsl, .natvis) wouldn't appear at all^1.
Ensure *.sln is written with CRLF line-endings.
Fix comment giving the wrong input for generating & building from cl.
Expand cpp.hint defines to include GDVIRTUAL, EXBIND, and MODBIND.
Generate cpp.hint before vsproj; previously wouldn't get built at all unless vsproj_gen_only=no.

As said in godot contributors chat, .glsl files were not referenced in the vs solution.
I confirm that thanks to this PR, they are now.
I can't say for the other aspect of this PR.

CC @shana

Thanks!


Just to be 100% clear - does version 2 stop cookies running if users don't click accept?

As per the subject line really!...
I don't think it is really clear in the docs whether this script is purely to make a nice looking but informative pop-up, or are cookies prevented from being used if the user fails to accept?

It doesn't. We considered adding that functionality, but instead decided to build a solution that is as lightweight as possible, while still complying with the cookie law.
V1 covers this use case so feel free to check it out


Chef 12.2.1 - boostrap fails with Exception: NameError: uninitialized constant Chef::Mixin::Command

$ knife --version
Chef: 12.2.1

DEBUG: Looking for bootstrap template in /opt/chef/embedded/apps/chef/lib/chef/knife/bootstrap/templates
DEBUG: Found bootstrap template in /opt/chef/embedded/apps/chef/lib/chef/knife/bootstrap/templates
ERROR: knife encountered an unexpected error
Adding require 'chef/mixin/command' to the client_builder.rb in /opt/chef/embedded/apps/chef/lib/chef/knife/bootstrap helped me get past the error.  Has anyone encountered an issue before or am I missing something?

12.2.1 is pretty old by now, does the same problem happen if you upgrade to 12.6 (or very shortly 12.7)?

Ok, I tried 12.6.0, but it errored with the same reason.

knife --version
Chef: 12.6.0

DEBUG: Looking for bootstrap template in /opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-12.6.0/lib/chef/knife/bootstrap/templates
DEBUG: Found bootstrap template in /opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-12.6.0/lib/chef/knife/bootstrap/templates
/opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-12.6.0/lib/chef/mixin/deprecation.rb:51:in `const_missing': uninitialized constant Chef::Mixin::Command (NameError)
        from /opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-12.6.0/lib/chef/knife/ssh.rb:533:in `run'
        from /opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-12.6.0/lib/chef/knife/bootstrap.rb:392:in `run'

if you comment out extend Chef::Mixin::Command on line 533 of /opt/chef/embedded/lib/ruby/gems/2.1.0/gems/chef-12.6.0/lib/chef/knife/ssh.rb does it work?

yes, it does. I commented out the line extend Chef::Mixin::Command in ssh.rb


Fix: count clipboard items only on paste action

Fix for https://github.com/Adobe-Consulting-Services/acs-aem-commons/issues/2694

LGTM, can you add a changelog entry to https://github.com/Adobe-Consulting-Services/acs-aem-commons/blob/master/CHANGELOG.md?

@kwin added changelog


Button Component - Design & Usage Guidelines

As a developer for Reaction or a member of the Reaction community, I should be able to get design guidelines on a component level for the button component.

Design guidelines for button.
zpl.io/VYJrP0d

I added two buttons. The drop-down button and I ran into a use case for an outline danger button so I added that. See updates on screen and in zeplin.


Don't pack every list-like fit param

This is an incorrect fix for #319.
Hadcoding list as the only arraylike thing that isn't sent through _indexable isn't right, but I'm not sure what else should be exempted. Mainly because I don't yet understand  the purpose of to_indexable.
cc @jcrist do you have any thoughts here?
Closes #319

Pushed a new approach, which I think fixes it closer to the source of the problem.
The root cause was improperly assuming that every array-like fit_param should be split like X and y. However, only array-likes with the same number of samples as X and y should be split. Others should just pass through.
Do accomplish this, CVCache now knows the length of X and y. When we unpack a parameter, we split it only if its length matches the length of X and y.


Bolt V2 Fixes with latest master

Here are a few fixes for the latest branch as well that I came across earlier. This is compliant with Bolt V2.

Awesome, thanks @Raistlfiren


[MAC OS X] Driver is copying MobileSafari.app to a tmp folder and then copies it back with wrong credentials (Safari)(Refactor Branch)

Hello!
I'm having a weird issue here although I'm sure it's intentional but in my situation it messes up the whole run of the test.
Abstract
So what happens is that the runner for some reason (I'm sure there is an explanation for it) copies the MobileSafari.app away from the Application folder into some temp folder. I'm guessing this is how it works with it? But since it does that the simulator when it starts up will miss the application MobileSafari.app!!!! So it can't start it anymore.
Logs
Here is an output of that happening:
08:09:715 INFO InstrumentsApple.moveMobileSafariAppOutOfInstallDir  temporarily moving MobileSafari out of the install directory, if you need to restore it yourself use:
Question
So after this happens I'm no longer able to use the MobileSafari.app because once it copies it back it will have the wrong credentials and it took me a whole reinstall or something like that to get the simulator to see the app again.
I'm not quite sure why this is happening and what this install folder is and why the safari app gets copied out of it.
Can somebody point me into the right direction please?
Cheers,
Gergely

Irrelevant now. Thanks for all the help though!


script data format when redeemers are empty?

https://github.com/input-output-hk/cardano-ledger/blob/9c3b4737b13b30f71529e76c5330f403165e28a6/eras/alonzo/test-suite/cddl-files/alonzo.cddl#L94
What is the format for constructing script data to get scriptDataHash when there are no redeemers? This is being used by cli which is only adding a datum to the tx, used when embedding a datum to tx with datum hash output, below tx cbor constructed by cli for ex,
84a7008182582060ac17c64f40d8182f8528939583515c72a04703abe893af18bf0dee9f715437000d80018282581d603ffa7225c34af125fd4acaf0cf51a9de98b1e1c5df792e599ad525321a0baf0cd583581d704b8980baf5b09f3573f26e100df813dd24a619d78188b9d56471e51f1a001a4ec45820923918e403bf43c34b4ef6b48eb2ee04babed17320d8d1b9ff9ad086e86f44ec021a00029519031a05f5e0ff0e800b58202f50ea2546f8ce020ca45bfcf2abeb02ff18af2283466f888ae489184b3d2d39a200818258201b949a6f5e0eb3c7d4def14a0301d2ef3d543f9f9c318bdacd5d198f3a3b481758408e80f7f92c2d168469f606d06ac27e9e47380b95948476b9a1647f757fe9bff486b676db4905ddfe8cf0773f5b30be89b6e87df5ef1a6f2393553b60b745bc0e0481d87980f5f6

I tried combination of excluding the redeemer part, langView part, empty array cbor for redeemer, but nothing seemed to produce a valid scriptDataHash that is produced by the cli.
Thanks,

The answer is sad. :disappointed:. The redeemers are contributing 80 to the serialized data for the hash, which is the CBOR encoding of "list of length 0".
I can guess how this happened. Originally we did not allow extraneous datums of any kind. So if the script integrity hash was present, there must be at least one redeemer. Then we later made the decision to allow extraneous datums in one case, namely the creation of outputs that had a datum hash.
The code here: https://github.com/input-output-hk/cardano-ledger/blob/f91a8760711bb66b5ebfedf7867cec1965c924f3/eras/alonzo/impl/src/Cardano/Ledger/Alonzo/Tx.hs#L244-L246
should instead be:
    let dBytes = if nullDats d then mempty else originalBytes d
        mBytes = if nullRedeemers m then mempty else originalBytes m
        lBytes = serializeEncoding' (encodeLangViews l)
     in mBytes <> dBytes <> lBytes

Tried with 80, cbor encoding of []. But that results in a different hash, specifically below is what I am hashing,
redeemerHex = 80
datumHex = 81d87980
lanViewHex = a141005901d59f1a000302590001011a00060bc719026d00011a000249f01903e800011a000249f018201a0025cea81971f70419744d186419744d186419744d186419744d186419744d186419744d18641864186419744d18641a000249f018201a000249f018201a000249f018201a000249f01903e800011a000249f018201a000249f01903e800081a000242201a00067e2318760001011a000249f01903e800081a000249f01a0001b79818f7011a000249f0192710011a0002155e19052e011903e81a000249f01903e8011a000249f018201a000249f018201a000249f0182001011a000249f0011a000249f0041a000194af18f8011a000194af18f8011a0002377c190556011a0002bdea1901f1011a000249f018201a000249f018201a000249f018201a000249f018201a000249f018201a000249f018201a000242201a00067e23187600010119f04c192bd200011a000249f018201a000242201a00067e2318760001011a000242201a00067e2318760001011a0025cea81971f704001a000141bb041a000249f019138800011a000249f018201a000302590001011a000249f018201a000249f018201a000249f018201a000249f018201a000249f018201a000249f018201a000249f018201a00330da70101ff
dataToHash = Buffer of (redeemerHex+datumHex+lanViewHex)
the resulting hash does not match the the one produced by the cli.
IMP to note - the script data hash matches the cli produced one when there are datums. Which can validate the implementation I have is correct when redeemer is present. This is also confirmed by posting tx on chain resulting in a successful plutus script transaction.

lanViewHex should not have the Plutus V1 stuff in it. Since the transaction is using no Plutus scripts, the language views should be empty. Like with the empty redeemers, the correct thing to do would have been to have lanViewHex be the empty bytestring, but unfortunately it is the CBOR empty map, namey A0. So see if hashing 8081d87980A0 matches the CLI.

cc @rooooooooob (I'm not sure if this is the kind of wart you would also like to be aware of)
tl;dr - The serialized data used for the script integrity hash is a bit wonky in the case of the user supplying the optional datum for a newly created transaction output containing a datum hash, and only when no Plutus scripts are used. In particular, the bytes for the datums need to be prepended with 80 and appended with A0. This is sad, and we now need to decide if we want to change it in the next hard fork or not.

@JaredCorduan That is it. That worked. Thanks so much for looking into it, and for your time.


loader still shows if empty array returned from api

the loader  still showing eventhough the api returns empty array. is there any props to show "No Items Found" message when api returns empty array?

Please watch this video for this library
https://youtu.be/c0nKjMnDfG4

Please watch this video for this library https://youtu.be/c0nKjMnDfG4

Is there an English video?

Reference to the video，you can set an expression to hasMore，and all you need just to init totalCount：
const totalCount = 1

And then:

Besides, after data updated, remember to update the value of totalCount.


Connect all line edits to editingFinished signal.

editingFinished is triggered when widget loses focus as well as when return is pressed.
This is an attempt to address #3744.
Type of change

[X] Bug fix

How Has This Been Tested?
I have been unable to reproduce on either windows or linux.
Am relying on @cyrush  to test if this resolves the problem.
Checklist:

[X] My code follows the style guidelines of this project
[X] I have performed a self-review of my own code
[X] I have commented my code, particularly in hard-to-understand areas
[X] I have assigned reviewers

@biagas  I'll try to tackle testing tomorrow (12/4/19)

I tried the changes, but unfortunately they didn't solve the issue.
Following your lead,  issue is with a spinBox sampleDensity[0]. I also tried using the editingFinished signal from the spinbox (creating new slots to do so), but still no luck.
The issue happens when I change the # of samples (sampleDensity[0]) then click on apply.
I have to click apply 2 times.

I pushed a change to the sampleDensityChanged functions, to call GetCurrentValues.
Can you see if that solves your problem?

I'll try again tomorrow and let you know

Still puzzled.
I tweaked a bit more -- using editingFinished() slot.  (I haven't pushed changes)
I verified that the slot is firing as I expect, that I am updating the atts and after the Apply() the atts have expected value.  However I still only get two seeds (instead of 10 from the value) until I hit apply again.

For some reason in the engine, the expected corresponding SetAtts` doesn't happen when I hit the first apply.
This points to the notification not happening, however I looked what I would think is could be obvious causes and still drawing a blank.


Update azure-subscription-service-limits.md

It occurred to me reading this page today that many Microsoft employees and others use the term "soft limit" and "hard limit," but this page never defined those terms.  Given how often they are used, they should have a passing reference at least.  There way be better ways to present this idea in this page.

@MikeBazMSFT : Thanks for your contribution! The author(s) have been notified to review your proposed change.

@MikeBazMSFT - thanks for this addition.

#sign-off


make benchmark to align with real case

Please provide a description of this PR:
Make the 100 svc + 100 dr compose a rds, which is to simulate more real case

@ramaraochavali

Is it possible to add delegates as well?

Delegates can be added, it is just adding more dependencies. The effect is same as service/dr


Question about "Open With" and scoop installed apps.

Hello!
scoop is great!
But app I install with scoop do not appear in "Open With" dialogue.
Is there a way to put them there?

You can add at least some of them manually by selecting (translated from another language) "Open with" -> "Choose another application" -> "More applications" ->  "Find another application in this PC". I was able to register scoop installed OpenShot to handle PNGs that way. But it only helps if you need at most a couple of apps there.
It seems we could add applications automatically from PowerShell: https://superuser.com/a/1462320

As @devdanzin stated above, you can simply add any program by path to the "open with" menu. However, there are some complications.
It is IMPERATIVE that you add the proper program path ($HOME/scoop/apps/mpv/current/mpv.exe), and not the shim path.

(If you do not go through the current shortcut and go through the actual version number, the link association will expire whenever you update the program.)
(Of course, this too does not work well with programs that have unstable executable pathing, like GIMP (bin/gimp-2.10.exe).)

If you add the shim path ($HOME/scoop/shims/mpv.exe), it will spell disaster. The shim will show up as an ugly iconless, nameless blob in the "Open With" menu. It will be impossible to tell between when you have multiple shims registered. The files too will forever be haunted by that icon. Sometimes the shim won't even close itself after launching the program.
What's more, if you add the shim for a program ONCE, Windows will not even let you let you add the proper path for it as an option anymore, presumably because it thinks that a program with the same basename is already registered and so there's no need to add the new path.
I added a few of those by mistake yesterday and almost pulled my hair out trying to undo it. I succeeded in the end, however only after what can be described best as a life-and-death tussle with manual registry editing.
(Maybe I should add this to the wiki?)

(Perhaps I should add this to the wiki?)

Please do :slightly_smiling_face:

@Calinou @ephemerr
https://github.com/lukesampson/scoop/wiki/Open-With-Icons


Adding device seems to timeout?

Hi,
For some reason, adding the integration and adding my device seems to timeout. I fill in the IP-address, the local id and the local key (field labels are missing, so I hope I fill in the right data in the right fields). When saving, it's busy for some time, but doesn't save or whatsoever. I don't know where to find log files (if any), so don't know how to give any more info.
Is this a known problem? Or can I supply more info, and, if so, how?

I think I'm having the same problem - but with the advantage of a working frontend I can see the failure message, which is:
Unable to connect to your device with those details. It could be an intermittent issue, or they may be incorrect.

The log entry:
This error originated from a custom integration.

Logger: custom_components.tuya_local.device
Source: custom_components/tuya_local/device.py:236
Integration: Tuya Local (documentation, issues)
First occurred: 00:39:19 (1 occurrences)
Last logged: 00:39:19

Failed to refresh device state for Test.

I will try again tomorrow given the "intermittent" statement in the error, but I've been trying this for about half an hour with no success. I am able to ping the device from console so it doesn't appear to be a network issue. Would be grateful for any troubleshooting suggestions.

Double check the device ID and key are correct.  If possible, use tuya-cli or tinytuya to test the connection from the command line.
After getting the local key, you cannot re pair the device with another app, as that will cause the local key to change.

Thanks for this. You were clearly onto something when you wrote the error message, because doing the exact same thing 12 hours later worked. Hopefully OP had the same experience.
My device is not being detected as the correct type (it's a dehumidifier but only the simple_switch option is available) - but I will poke around and see if I can get it recognised correctly.

A climate device might be better if the heater can have the target temperature set.

Thankyou, this is useful. I've got a mostly working configuration file but am struggling with a couple of features. I'd be grateful for any suggestions you have.
Here's the config:
name: "ElectriQ Dehumidifier DESD9LW"
primary_entity:
  entity: climate
  dps:
    - id: 1
      name: power
      type: boolean
#      hidden: true
      mapping:
        - dps_val: false
          icon: "mdi:air-humidifier-off"
          icon_priority: 1
          value: "off"
        - dps_val: true
          icon: "mdi:air-humidifier"
          icon_priority: 3
    - id: 2
      type: integer
      name: humidity
      range:
        min: 35
        max: 80
      mapping:
        - step: 5
    - id: 4
      type: string
      name: fan_mode
      mapping:
        - dps_val: "Low"
          constraint: hvac_mode
          conditions:
            - dps_val: "Auto"
              invalid: true
          value: "Low"
        - dps_val: "Medium"
          constraint: hvac_mode
          conditions:
            - dps_val: "Auto"
              invalid: true
          value: "Medium"
        - dps_val: "High"
          constraint: hvac_mode
          conditions:
            - dps_val: "Auto"
              invalid: true
          value: "High"
        - dps_val: "auto"
          value: "Auto"
          invalid: true
    - id: 5
      name: hvac_mode
      type: string
      mapping:
        - value: "off"
        - dps_val: "Auto"
          value: "auto"
          constraint: power
          conditions:
          - dps_val: false
            value_redirect: power
        - dps_val: "Heater"
          value: "heat"
          constraint: power
          conditions:
          - dps_val: false
            value_redirect: power
        - dps_val: "Dehumidity"
          value: "dry"
          constraint: power
          conditions:
          - dps_val: false
            value_redirect: power
        - dps_val: "Fan"
          value: "fan_only"
          constraint: power
          conditions:
          - dps_val: false
            value_redirect: power
          icon: "mdi:air-purifier"
          icon_priority: 2
    - id: 6
      type: integer
      name: current_humidity
      readonly: true
    - id: 7
      type: integer
      name: current_temperature
      readonly: true
    - id: 10
      type: boolean
      name: swing_mode
      mapping:
        - dps_val: false
          value: "off"
        - dps_val: true
          value: "vertical"
    - id: 101
      type: integer
      name: temperature
      range:
        min: 16
        max: 30
      mapping:
        - step: 1
secondary_entities:
  - entity: switch
    name: "UV sanitizer"
    icon: "mdi:solar-power"
    dps:
      - id: 15
        name: switch
        type: boolean
  - entity: switch
    name: "Ioniser"
    icon: "mdi:atom-variant"
    dps:
      - id: 12
        name: switch
        type: boolean

I'm struggling with 3 issues:
Switches
The second switch for the ioniser isn't created in HA. I think I remember reading that multiple switches aren't supported yet, but can't find the thread any more. If that is the case then I'll set the UV light up as a light entity.
Target Humidity
Setting the target humidity in HA throws an error:
Logger: homeassistant.components.websocket_api.http.connection
Source: core.py:362
Integration: Home Assistant WebSocket API (documentation, issues)
First occurred: 13:29:08 (1 occurrences)
Last logged: 13:29:08

[23126175886592] async_set_humidity() got an unexpected keyword argument 'humidity'
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/websocket_api/commands.py", line 185, in handle_call_service
    await hass.services.async_call(
  File "/usr/src/homeassistant/homeassistant/core.py", line 1491, in async_call
    task.result()
  File "/usr/src/homeassistant/homeassistant/core.py", line 1526, in _execute_service
    await handler.job.target(service_call)
  File "/usr/src/homeassistant/homeassistant/helpers/entity_component.py", line 213, in handle_service
    await self.hass.helpers.service.entity_service_call(
  File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 658, in entity_service_call
    future.result()  # pop exception if have
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 856, in async_request_call
    await coro
  File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 689, in _handle_entity_call
    result = hass.async_run_job(partial(getattr(entity, func), **data))  # type: ignore
  File "/usr/src/homeassistant/homeassistant/core.py", line 451, in async_run_job
    return self.async_run_hass_job(HassJob(target), *args)
  File "/usr/src/homeassistant/homeassistant/core.py", line 435, in async_run_hass_job
    return self.async_add_hass_job(hassjob, *args)
  File "/usr/src/homeassistant/homeassistant/core.py", line 362, in async_add_hass_job
    task = self.loop.create_task(hassjob.target(*args))
TypeError: async_set_humidity() got an unexpected keyword argument 'humidity'

HA also displays the max and min humidity correctly in Developer Tools -> States, but doesn't seem to recognise the step value. Not sure what is happening here.
Switching the device off
The device has a physical on/off power button, and a separate mode selection button with 4 options (heater, dehumidifier, air purifier and smart). Using the above config, HA correctly displays the hvac_mode as Off when the power is off, and selecting a different HVAC mode turns the power on, although it restores the previous hvac_mode instead of using the one selected (I don't know why this works).
Unfortunately I haven't been able to figure out a way to turn the power off from HA. I tried to do this using value_redirect but couldn't get a working config. The climate entity also doesn't support a power switch, and I don't think I can set up a separate switch entity as mentioned above.
I think I could work around this by creating a humidifier entity, but that would mean having to use the humidifier card to turn the device on even if the user isn't intending to use the dehumidifier features, which isn't ideal.
Thanks for reading this very long post - please let me know if it would be better to split this off into a new issue(s).

Switches: yes, only one switch is supported currently.  So one of them will need to change to a light.
There are different APIs for setting the humidity. The API that uses keyword arguments s actually a deprecated API for setting the temperature, and currently only accepts the temperature and mode keywords.  It seems internally in HA this API is still used from some unexpected places.
I think if you look at electriq_12wminv_heatpump.yaml you can find some guidance of how the power and hvac_mode dps can be configured into a combined hvac_mode for the HA UI for a multi-function device.

For the issue with humidity, I think it may be fixed by 0.10.0.  The argument to async_set_humidity was named differently than the parent climate component, so when called with keyword arguments as the frontend seems to do, it failed to match.
There is no humidity step in the HA climate API, only temperature step.

Thanks for all the info.
I had a look at the heatpump config and it seems to have the same limitations mine does. The design of this device doesn't include a sleep function so the power boolean is the only way to turn it off, so I have prioritised that for a switch and left the ioniser function unimplemented for now. It would be great to be able to add multiple switches in future so that I can implement this.
The humidity issue is now fixed, thankyou. I'll submit a PR.

This support is now released in 0.10.1
However, the original issue reported by @tricksel  still stands.


Move block processing into wasm

Context

Currently the longest running task in compact block processing is due to json serialization (relevant line).
It is required to do so as our rust code deserializes from json. So we are passing it like so:

js class -> json -> | wasm boundary | -> rust struct

Attempts to serialize through binary have not added any performance gains

js class -> binary -> | wasm boundary | -> rust struct

An idea arose to move more decryption logic into typescript to put less load on serialization requirements. However, it did not have any performance gains.

To do
Given wasm is quite performant, the idea is to move block processing into wasm entirely. This prevents the back-and-forth serialization overhead. It may even simply logic if it only exists in one domain.
== Consideration ==
We are querying from typescript HERE. By default, connectRPC is taking the bytes from the query response and parses them. So our current flow actually looks like this:
bytes -> js class -> json -> | wasm boundary | -> rust struct

We should attempt to simplify this to:
bytes -> | wasm boundary | -> rust struct

This would mean copying over parts of code that allow us to not parse, but pass the UnitArray on. Suggestions:
https://bufbuild.slack.com/archives/CRZ680FUH/p1711072213138009
From bufbuild team:
function toHex(uint8Array) {
    return uint8Array.length === 0 ? '' : '0x' + Array.from(uint8Array).map(i => ('0' + i.toString(16)).slice(-2)).join(', 0x');
}
fetch("https://demo.connectrpc.com/connectrpc.eliza.v1.ElizaService/Say", {
    method: 'POST',
    headers: {
        "Content-Type": "application/grpc-web",
    },
    body: new Uint8Array(5), // Valid zero-length request message in gRPC Web
}).then(async (response) => {
    const header = new Uint8Array(5);
    let headerPos = 0;
    let payload = new Uint8Array(0);
    let payloadRemaining = 0;
    for await (const chunk of response.body) {
        for (let pos = 0; pos < chunk.length;) {
            if (headerPos < 5) {
                while(headerPos < 5 && pos < chunk.length) {
                    header[headerPos++] = chunk[pos++];
                }
                if (headerPos === 5) {
                    payloadRemaining = new DataView(header.buffer).getUint32(1, false);
                }
                console.log(`Header read pos: ${headerPos}`);
            }
            if (payloadRemaining > 0) {
                const chunkLen = Math.min(chunk.length - pos, payloadRemaining);
                const newMessage = new Uint8Array(payload.length + chunkLen);
                newMessage.set(payload);
                newMessage.set(chunk.subarray(pos, pos + chunkLen), payload.length);
                payload = newMessage;
                pos += chunkLen;
                payloadRemaining -= chunkLen;
                if (payloadRemaining === 0) {
                    // Got an entire message.
                    if (header[0]&0x80) {
                        // Trailers frame
                        console.log(`gRPC Web Trailer: flags=${header[0]} payload:\n${new TextDecoder().decode(payload)}`);
                    } else {
                        // Message
                        console.log(`gRPC Web Message: flags=${header[0]} payload=${toHex(payload)}`);
                    }
                    headerPos = 0;
                    payload = new Uint8Array();
                }
                console.log(`Remaining message bytes: ${payloadRemaining}`);
            }
        }
    }
});

Though, we may be able to skip typescript fetching entirely and simplify this to:
bytes -> rust struct

Which would only be possible if we query for blocks directly from Rust using a wasm-compatible grpc client like tonic-web-wasm-client.
Tasks:

[ ] Validate speed of block processing with performance tracing of a smallish subset of block syncing
[ ] Create new rust fetch_and_sync method
[ ] Migrate all typescript logic to this new method

if we query for blocks directly from Rust using a wasm-compatible grpc client

This is possible in theory, but the rabbit hole may be too deep for now (?). We need the rpc feature enabled to get the query clients needed for tonic-web-wasm-client. We also need the proto-compiler's tonic-build dep to exclude the tonic transport impls and re-compiled. Something like:
tonic-build = { version = "0.10.0", default-features = false, features = ["cleanup-markdown"] }
# then run ./deployments/scripts/protobuf-codegen

And then finally, we need to have penumbra-proto package be wasm compatible:
cargo build --lib --release --target wasm32-unknown-unknown

At the moment, we are greeted by an assortment of compile issues relating to required "js" features and exclusion of randomness libs.

we should close this as not planned

the underlying motivation is raw performance, but the primary goal has been identified as parallelization. in fact the compute-heavy tasks of the block processor are already performed in wasm.
at best this issue needs refinement, but i think ultimately it does not represent current understanding of the objectives.
given the present consensus and planning effort, to be issued in the next few days, i'm closing this issue.


Support for batched inference?

Hi, thanks for a very nice library.  Do you support batched inference?  Thanks

Yes, it supports batched inference

Can you point to how? The examples seem to show a single prompt and there
seems to be a call to reset for each prompt. Thanks again.
On Thu, Nov 7, 2024, 10:27 PM Shubham Ugare @.***>
wrote:

Yes, it supports batched inference
—
Reply to this email directly, view it on GitHub
https://github.com/uiuc-focal-lab/syncode/issues/124#issuecomment-2463684527,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/ACNS6QV7TBALNW3UE4W6PBTZ7QVRVAVCNFSM6AAAAABRL5POW6VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDINRTGY4DINJSG4
.
You are receiving this because you authored the thread.Message ID:
@.***>

To clarify,  the reset for each prompt seems to happen in the code to generate per prompt.

You can run something like following for batched inference:
syn_llm = Syncode(model=model_name, grammar='json', parse_output_only=True, max_new_tokens=50, num_return_sequences=5, do_sample=True, temperature=0.7)

prompt = "Please return a json object to represent country India with name, capital and population?"
output = syn_llm.infer(prompt)

for i, out in enumerate(output):
    out = out.strip()
    print(f"SynCode output {i+1}:\n{out}\n")


.error() is deprecated since JQuery 1.8, fix this

before change: http://i.imgur.com/YUEbWbC.png
after: http://i.imgur.com/T5SetSN.png
Thank for the excellent plugin :)

Thanks!


data_table_2 : 2.3.3

Hello.
Is it possible to update to the last realease data_table_2  2.3.3 ?
I tried to add it but it have some issues and can't know where to solve :/ .
Thank you.
regards.

Hi,there just tried to fixed it,not good but works 😁,enough for demo testing and learning.
https://github.com/zlhz/Flutter-Responsive-Admin-Panel-or-Dashboard

brother can you please have a look, why my bug is not being fixed? i am trying o hard but after update it crashes and errors, please it would mean a lot, I will share all details

brother can you please have a look, why my bug is not being fixed? i am trying o hard but after update it crashes and errors, please it would mean a lot, I will share all details

Have you cloned my project? If problems remains,could you show your error logs?

brother can you please have a look, why my bug is not being fixed? i am trying o hard but after update it crashes and errors, please it would mean a lot, I will share all details

Have you cloned my project? If problems remains,could you show your error logs?

It works for me. Can you send a PR ?

Hi,there just tried to fixed it,not good but works 😁,enough for demo testing and learning. https://github.com/zlhz/Flutter-Responsive-Admin-Panel-or-Dashboard

Hello.
Excuse me i was of this week.
I just tested it and it work very good.
Thank you very much !

brother can you please have a look, why my bug is not being fixed? i am trying o hard but after update it crashes and errors, please it would mean a lot, I will share all details

Have you cloned my project? If problems remains,could you show your error logs?

It works for me. Can you send a PR ?

It was already been sent.
https://github.com/abuanwar072/Flutter-Responsive-Admin-Panel-or-Dashboard/pull/50#issue-1288534476

Hi,there just tried to fixed it,not good but works 😁,enough for demo testing and learning. https://github.com/zlhz/Flutter-Responsive-Admin-Panel-or-Dashboard

Hello. Excuse me i was of this week. I just tested it and it work very good. Thank you very much !

Haha,but it still needs to optimize,It's now using with a fixed height,not good ,but should enought for testting or learining.

I do PayPal transfer With No Chargebacks On It, Verified Account With Good And Highly Balance...|
CashApp
Chime transfer
Zelle transfer
Skrill transfer
Venmo transfer
50$btc =250
100$ btc = 550$
I  am selling good ,Cvv Fullz , Dumps+pin,Track1&2,Bank login,YesCards,Gift Cards,WU Transfer and Paypal and am providing bank transfer to uk and usa
You can join My Telegram Platform
Tap on the link below
https://t.me/dark2webb
Telegram ID:@moderatordark2web


Using Assembled Contig Data with Melon: Compatibility and Guidelines

Hi,
Does Melon accept assembled contig data produced from short-read sequencing data using assemblers (e.g., MEGAHIT, metaSPAdes...) ?

Hi,
Melon is a read-based taxonomic profiler so it does not work with contigs.

Hi, Thank you for the clarification.

Hi,
Does Melon work with assembled contigs from long-read data using assemblers like Canu, MetaFlye?

Hi,
no, the main usage of Melon is to estimate the genome copies of different species in a metagenomic sample. Since assembled contigs do not have the coverage information Melon cannot handle them.


Implementation of fetchservice cancellable by requestKey

This resolves issue: https://github.com/exhi/hoist-react/issues/698
There is a corresponding toolbox branch (fetchservice_cancel) which does not need to be merged in, but can be used to test this implementation by cancelling News refreshes.

To me, the question here is do we only want to support the 'autoCancelKey'?  Or do we want to provide additional support for the more general ability to get a handle on the group of requests and cancel them (the way we did before).
I think that someone that really wants to manually, can now just use the AbortController directly and provide a shared signal for the entire group.  That's just about as easy as anything we would build, so need to layer anything more complicated on.


block present when value is 0

Hi! Thanks for creating PyWaffle and the useful examples.
I started using it today and everything is great, except that sometimes I have a value of 0 for some items. But when the waffle chart is generated, a block is still present for the category with a value of 0.

Could you look into making it so that there is no block for a label if the value is 0?

Thanks for pointing out! This is fixed in 0.2.2. Please update the package.


Singularity definition seems to be the one from the example

https://github.com/reprostat/reproa/blob/master/Singularity
I think it can be safely deleted

Done. Than you!


Priority Queue missing

There is no implementation of Priority Queue in this project.
Priority Queue is a very important data structure and it should be included in this project as well.

Tried to implement it and here is the PR
https://github.com/benoitvallon/computer-science-in-javascript/pull/12
@benoitvallon Please have a look at the PR


Handle errors

If bot doesn't have permission to write on destination channel, message is removed from the original channel, but not added to the destination channel.
So it is lost.

Thanks for reporting this. I have some permission-based fixes planned for the next update.


filter matching unexpected

Description
When we have group by file matching the filter text in the file name is unexpected.
Expected behavior
Filter text should be highlighted in the result.
Screenshots

Maybe the filter should work only on search results, ignoring paths ?

It's exactly what Visual Studio does:

And they don't highlight the filter text

But you already have the "Include file" field for that, VS does not.

I'd rather add an option than limit existing functionality.


Escape Templating Tags

I'd like to be able to do something like this:
{% extend "base.html" %}

# This is a Title

and not format the extend tag so that the result is like this:
{% extend "base.html" %}

This is a Title

Is this possible? I understand there are ways to create custom rules, but I'm not sure how to use those either.

http://spec.commonmark.org/0.25/#processing-instruction. CommonMark supports only <? ..... ?> skip (when html enabled).
Other markup should be added via plugins. Good place to start is to read dev docs.


Live messaging fix 📱

This is the eigen side of the work for https://github.com/artsy/auctions/issues/289 . Here's a breakdown of the problem:

We were showing "sold to you for X" but that's not the correct messaging. The correct messaging is "sold for X" and only to show it if the user is the winning bidder.
We were showing the "current price" aka the next increment above the highest bid. The nomenclature around this in eigen could use a revamp, but for now I've added a winningLotValueString that returns the bid amount of the winning bid event, if it exists.

I also added a test for the case that the user won the lot, which we didn't have for this particular view yet.
This is a WIP because I'm currently fighting with Xcode to get this tested on my device first.

Tested this on device, looks 👍


English documentation

Complete documentation in English would be really helpful.
Thanks in advance 🙏

We already provide most docs in english, do you have any specific issue met?


fix edx file imports

What are the relevant tickets?
closes https://github.com/mitodl/hq/issues/6031
Description (What does it do?)
This pr removes duplicate edx content files and cleans up content file content for subtitle files.  We were creating duplicates of edx content files because both the code that was intended to find existing documents to update them instead of creating new ones and the code that unpublished and deleted documents that were no longer in the course folder had bugs.
It also populates the file path and file extension for edx content files and does not attempt to extract content with tilka for non-text files such as csv files or various code file formats.
How can this be tested?
If you don't already have some xpro files in your database run  docker-compose run web ./manage.py backpopulate_xpro_data,  `docker-compose run web ./manage.py backpopulate_xpro_files in the main branch
On this branch
Run docker-compose run web ./manage.py backpopulate_xpro_data , docker-compose run web ./manage.py backpopulate_xpro_files --overwrite
Go to http://api.open.odl.local:8063/api/v1/contentfiles/?platform=xpro and verify that you have 10315 files
From the shell verify that
ContentFile.objects.filter(run__learning_resource__platform__code='xpro' ).filter(file_extension__isnull=True).count() is 0
Find a srt file useing
ContentFile.objects.filter(run__learning_resource__platform__code='xpro').filter(file_extension='.srt').first()
Verify that the content field does not have timestamps

I didn't filter the files with empty content because for ocw we want files with non text content to show up in the search and be searchable by title.  Since we don't have plans for a edx content search, I will update the code to just not save content files without content for edx.


How come net_debug() prints old dns info after dnsc_srv_set()?

Since I didn't get any response to this question on re-devel list, I'll try here.
So how come baresip net_debug() prints old DNS info after call dnsc_srv_set()?
Here is how I tested:
static net_debug_log() {
    char debug_buf[2048];
    int l;
    l = re_snprintf(&(debug_buf[0]), 2047, "%H", net_debug, baresip_network());
    if (l != -1) {
        debug_buf[l] = '\0';
        LOGD("%s\n", debug_buf);
    }
}

LOGI("******** Printing net_debug");
net_debug_log();
LOGI("******** Setting dns server to '<IP_ADDRESS>:53'");
server = "<IP_ADDRESS>:53";
err = sa_decode(&(nsv[0]), server, str_len(server));
if (err) {
    LOGW("dnsc_srv_set: could not decode '%s' (%u)\n", server, err);
    return err;
}
(void)dnsc_srv_set(net_dnsc(baresip_network()), nsv, 1);
LOGI("********* Printing net_debug");
net_debug_log();

And here is what I got:
05-25 15:08:36.408 14063 14063 D Baresip Lib: ******** Printing net_debug
05-25 15:08:36.410 14063 14063 D Baresip Lib: --- Network debug ---
05-25 15:08:36.410 14063 14063 D Baresip Lib:  Preferred AF:  AF_INET
05-25 15:08:36.410 14063 14063 D Baresip Lib:  Local IPv4:    ccmni0 - <IP_ADDRESS>
05-25 15:08:36.410 14063 14063 D Baresip Lib:  Local IPv6:           - ::
05-25 15:08:36.410 14063 14063 D Baresip Lib:  Domain:
05-25 15:08:36.410 14063 14063 D Baresip Lib: net interfaces:
05-25 15:08:36.410 14063 14063 D Baresip Lib:          lo:  <IP_ADDRESS>
05-25 15:08:36.410 14063 14063 D Baresip Lib:      ccmni0:  <IP_ADDRESS>
05-25 15:08:36.410 14063 14063 D Baresip Lib:         ap0:  <IP_ADDRESS>
05-25 15:08:36.410 14063 14063 D Baresip Lib: net routes:
05-25 15:08:36.410 14063 14063 D Baresip Lib:  Destination                                 Next Hop                                 Iface           Type
05-25 15:08:36.410 14063 14063 D Baresip Lib:  <IP_ADDRESS>/8                                  ?                                        ccmni0
05-25 15:08:36.410 14063 14063 D Baresip Lib:  <IP_ADDRESS>/24                             ?                                        ap0
05-25 15:08:36.410 14063 14063 D Baresip Lib:  DNS Servers from Config: (1)
05-25 15:08:36.410 14063 14063 D Baresip Lib:    0: <IP_ADDRESS>:53
05-25 15:08:36.410 14063 14063 D Baresip Lib:
05-25 15:08:36.410 14063 14063 D Baresip Lib: ******** Setting dns server to '<IP_ADDRESS>:53'
05-25 15:08:36.410 14063 14063 D Baresip Lib: ********* Printing net_debug
05-25 15:08:36.413 14063 14063 D Baresip Lib: --- Network debug ---
05-25 15:08:36.413 14063 14063 D Baresip Lib:  Preferred AF:  AF_INET
05-25 15:08:36.413 14063 14063 D Baresip Lib:  Local IPv4:    ccmni0 - <IP_ADDRESS>
05-25 15:08:36.413 14063 14063 D Baresip Lib:  Local IPv6:           - ::
05-25 15:08:36.413 14063 14063 D Baresip Lib:  Domain:
05-25 15:08:36.413 14063 14063 D Baresip Lib: net interfaces:
05-25 15:08:36.413 14063 14063 D Baresip Lib:          lo:  <IP_ADDRESS>
05-25 15:08:36.413 14063 14063 D Baresip Lib:      ccmni0:  <IP_ADDRESS>
05-25 15:08:36.413 14063 14063 D Baresip Lib:         ap0:  <IP_ADDRESS>
05-25 15:08:36.413 14063 14063 D Baresip Lib: net routes:
05-25 15:08:36.413 14063 14063 D Baresip Lib:  Destination                                 Next Hop                                 Iface           Type
05-25 15:08:36.413 14063 14063 D Baresip Lib:  <IP_ADDRESS>/8                                  ?                                        ccmni0
05-25 15:08:36.413 14063 14063 D Baresip Lib:  <IP_ADDRESS>/24                             ?                                        ap0
05-25 15:08:36.413 14063 14063 D Baresip Lib:  DNS Servers from Config: (1)
05-25 15:08:36.413 14063 14063 D Baresip Lib:    0: <IP_ADDRESS>:53

Is this a bug?  If not, what is the explanation?

it is 2 different objects.

the configured name servers is on the struct network object:

	struct sa nsv[NET_MAX_NS];/**< Configured name servers      */

and the other set of name servers is on the struct dnsc dns client.

if you update 2.) then 1.) will (logically) not get updated.

OK, but it make more sense if net_debug would tell what the current name servers are?

I think it is better to use this API to set/change nameserver:
int net_use_nameserver(struct network *net, const struct sa *ns)

the list of DNS nameservers either comes from the system or from the config.
the master list is kept in net.c and the shadow list is kept in the DNS client.

OK, I'll give net_use_nameserver() a try.  Will net_debug() then show the new name servers?

it will not update the list of nameservers in net.c:
int net_use_nameserver(struct network *net, const struct sa *ns)
{
	struct dnsc *dnsc;
	int err;

	if (!net || !ns)
		return EINVAL;

	err = dnsc_alloc(&dnsc, NULL, ns, 1);
	if (err)
		return err;

	mem_deref(net->dnsc);
	net->dnsc = dnsc;

	return 0;
}

I think for you it is probably better to update the nameservers in config:
/** Network Configuration */
struct config_net {
	bool prefer_ipv6;       /**< Prefer IPv6 over IPv4          */
	char ifname[64];        /**< Bind to interface (optional)   */
	struct {
		char addr[64];
	} nsv[NET_MAX_NS];      /**< Configured DNS nameservers     */
	size_t nsc;             /**< Number of DNS nameservers      */
};

and then refresh net, so that it can update the nameservers
(in both net.c and DNS client).

or we can add this to net_use_nameserver:
net->nsv[0] = *ns;
net->nsn = 1;

What if there is more than one nameserver to use?  dnsc_srv_set() takes an array argument allowing up to NET_MAX_NS nameservers.
Background:  since Android does not anymore allow JNI access to the name servers the OS is using, I query the name servers in Kotlin code before baresip starts.  Then I write those name servers to config file and start baresip.  If name servers later get changed, e.g., when network connection changes, Kotlin code gets notifified about the change and makes dnsc_srv_set() call.  All this works fine.  The only issue I have is how to debug what the currently active baresip dns client name servers are.

this function can now be called at any time to set or update the
DNS client with 1 or more nameservers:
int  net_use_nameserver(struct network *net,
			const struct sa *srvv, size_t srvc);

see commit 7801744e929d73feb2c08a33cbf59d4b8a5bf812

Alfred E. Heggestad writes:

this function can now be called at any time to set or update the
DNS client with 1 or more nameservers:
int  net_use_nameserver(struct network *net,
			const struct sa *srvv, size_t srvc);

see commit 7801744e929d73feb2c08a33cbf59d4b8a5bf812

Thanks.  I'll switch to that.


Narrow screen: End exam button next to the Next question button

It's not obvious, once you've finished the last question, how to end the exam - at the moment you have to open the menu.

Here's how it currently looks:

The End Exam button should appear to the right of the greyed-out "Next" button when we're on the last question.

Hi,
I'd like to work on this.

Go for it! The relevant file is themes/default/files/index.html. Copy the existing "End exam" button, and add a visible: data-binding to make it visible only when we're on the last question.

Thanks for the information, what will be the tag following visible (data-bind="visible:____") such that the end button only appears at the last question?

I would like to work on this issue, but it seems like the file structure has changed since posting this issue.
Can you help me with the new location of this issue?

The sidebar and the top nav bar are both in themes/default/templates/nav.html.
You should copy the endBtn from https://github.com/numbas/Numbas/blob/master/themes/default/templates/nav.html#L51 to just after the "next question button" at https://github.com/numbas/Numbas/blob/master/themes/default/templates/nav.html#L67
It might be worth adding the class btn-warning to the new button, to make it look important.
If that looks weird, or we run out of space on small screens, this might need rethinking. Or we could hide the "next question" button when on the last question.


Fix large hex downloads on chrome <=79

fix https://github.com/microsoft/pxt-microbit/issues/3417 - the dataurl was just too long for older versions of chrome to handle it. createObjectURL is listed as a working draft but browser support is good https://caniuse.com/bloburls
~I added a TODO for it, but will want to look at this a bit more and revokeObjectUrl -- as written the blob will persist in memory until refresh most likely~ added handling to revoke url when it goes out of use. Mainly wanted initial thoughts as this part of the code hasn't changed much / in case there is something known that I'm overlooking about createObjectURL
here's a build since I'm using it for browserstack anyways https://makecode.microbit.org/app/662dfecbb1be03dc15f0348e51683672c8e02097-64245805e1

@jwunderl  ready?

Yup, pushed a last cleanup change. I did add the blob url revoke logic to prevent memory leaks since you reviewed if you wanted to look over that, otherwise I'll merge in a few~

ported to stable6.0


js_name does not seem to effect struct values

Describe the Bug
js_name does not affect public values in structs like it affects methods.
Steps to Reproduce
Create a struct
#[wasm_bindgen]
pub struct FooBar {
    #[wasm_bindgen(js_name = "spamEggs")]
    pub spam_eggs: u32,
}

Expected Behavior
Should generate JS/TS with name spamEggs just like for methods.
OR throw an error that this is not possible.
Actual Behavior
Generates JS/TS with name spam_eggs as if the js_name attribute would not have been set.

Should be easy enough to implement, but agreed that this isn't working today!


Sprint 2 Tests, implement #33's TODO

Tests for sprint 2 components.
Depends on at least #21, #22, #23, and #24
Implement #33's TODO: replace filler text with actual descriptions of personality outputs
Add Kenny's bug fix from #34

Note: update travis.yml to run flask init-db

Some definitions from the report we could use for descriptions of the personality output:
Exploratory Excitability" and Extravagance description:

Exploratory excitability refers to one's willingness and desire to seek new things and avoid boredom. Extravagance refers to one's preference for spending money over saving money. Thus, a higher score suggests you like new stimuli, spending money, and portfolios with more growth & large capitalization stocks.

Impulsiveness and Disorderliness description:

Impulsiveness refers to one's willingness to make decisions based on hunches and without necessarily having complete information. Disorderliness refers to one's willing to do things their own way without much regard for routines or rules. Thus, a higher score suggests you take risks, do not follow conventions, and have a portfolio with more growth & small capitalization stocks.

Attachment and Dependence description:

Attachment refers to one's tendency to be generally warm and open with others. Dependence refers to one's willingness and desire to fit into a social group. Thus, a higher score suggests you are more amicable, enjoy interacting with people, and have a portfolio with more small capitalization stocks.

Sentimentality and Empathy description:

Sentimentality refers to one's tendency to be affected by emotional stimuli, whether it be other people or works of art. Empathy refers to one's ability to better understand and share the feelings of others. Thus, a higher score suggests you are more led by your emotions, understand the emotions of others, and have a portfolio with more value and small capitalization stocks.


3.1. Update QuizController to include a method with GetMapping('/edit/{quizId}') request to retrieve a specific quiz by its ID and return the 'editQuiz' frontend form pre-populated with its current information.

Task 3.1 has been completed


Change getter and setter in Class for @Getter and @Setter from lombok

In some Class getter functions are written. It could be better to replace all of them by auto-generated getter/setter from lombok.
See example of Class without
And Class with

Have you thougth about adding @Data to the hole class? According to the specification, it bundles the features of ToString, EqualsAndHashCode, Getter, Setter and RequiredArgsConstructor. You can also tune it if you don´t want some of these. Let me know if I can help with this or your original proposal of refactoring using @Getter.

Added class level and field level(depending upon the requirement) @Getter and @Setter for all classes in module.
pls review the PR https://github.com/meilisearch/meilisearch-java/pull/385

@adolfo-trocoli do you know if we can reduce more code with this change you have in mind?


Windows Auth Scheme

If I want to select the scheme w/ the Authorize attribute for windows auth, I apparently use "Windows".  I stumbled across this SO Post that happened to be using it.
[Route("api/[controller]")]
[Authorize(AuthenticationSchemes = "Windows")]
public class TestController : Controller { ... }

I can't seem to find this documented though.  Is it?
And probably more of a product issue than a doc issue but is there a member I can reference like JwtBearerDefaults.AuthenticationScheme or CookieAuthenticationDefaults.AuthenticationScheme?  Feels "wrong" to use a string like that.

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

ID: ee71441f-471a-89cd-0ef4-9b32b5dd85cf
Version Independent ID: 0096c365-2f4e-5d21-89a0-c4f10fcb0ed9
Content: Authorize with a specific scheme in ASP.NET Core
Content Source: aspnetcore/security/authorization/limitingidentitybyscheme.md
Product: aspnet-core
GitHub Login: @Rick-Anderson
Microsoft Alias: riande

It's not documented because it's won't work as you expect. Windows auth is pretty much all or nothing.

It actually does work. There are three constants (all with the same value) depending on which server you're using.

IIS out of process: Microsoft.AspNetCore.Server.IISIntegration.IISDefaults.AuthenticationScheme
IIS in process: Microsoft.AspNetCore.Server.IIS.IISServerDefaults.AuthenticationScheme
HttpSys: Microsoft.AspNetCore.Server.HttpSys.HttpSysDefaults.AuthenticationScheme

FYI, I previously tried:
using Microsoft.AspNetCore.Server.IISIntegration;
//...
[Authorize(AuthenticationSchemes = IISDefaults.AuthenticationScheme)]

but that yields:

Severity	Code	Description	Project	File	Line	Suppression State
Error	CS0182	An attribute argument must be a constant expression, typeof expression or array creation expression of an attribute parameter type	Windows and Cookie Auth Expirement	C:\Users\mdepouw\source\repos\GitHub\spottedmahn\Experiments\Windows Auth Expirement\Windows and Cookie Auth Expirement\Controllers\HomeController.cs	81	Active

I see it is defined as static readonly not a const:
namespace Microsoft.AspNetCore.Server.IISIntegration
{
    public class IISDefaults
    {
        //...
        public static readonly string AuthenticationScheme;
        //...
    }
}

I got the idea from here: Configure Windows Authentication in ASP.NET Core -> Work with Windows Authentication -> IIS

Microsoft.AspNetCore.Server.IIS.IISServerDefaults.AuthenticationScheme works as it is a constant 👍

Those static readonly have been changed to const in later versions for this reason.

These are documented under windows auth:
https://docs.microsoft.com/en-us/aspnet/core/security/authentication/windowsauth?view=aspnetcore-2.2&tabs=visual-studio#iis

I see, thanks @Tratcher 👍