Instead of converting paths back and forth, just use them as-is.

Fixes build on cygwin.

Mhh. I see now why relative paths are used everywhere: the OCaml is native, so there is a zillion places where the path names would need to be translated back and forth. Using relative paths everywhere neatly sidesteps this issue.

Exactly, there a loads of places that depend on that and make is not always called from the root directory. I'm happy to change that once all of this is merged into master, but until then I prefer to keep it as is.
BTW, I can't reproduce your problem via my cygwin/python/etc. Do you have any symbolic links in your paths?

I think we should refrain from adding python as a dependency to the build system of HACL*. This is likely to make a lot of people at INRIA cringe. And it seems like this ought to be achievable without Python.
How about using cygpath -m and/or a combination of readlink -f? (Possibly with READLINK=$(shell which greadlink >/dev/null 2>&1 && echo greadlink || echo readlink))? That's why we assume that everyone is running within a cygwin terminal: so that we have these tools at our disposal in the Makefiles and don't need to take yet another dependency.

@msprotz Sure, I'm happy with any tool that converts between absolute and relative path.
Originally I used the realpath command line utility, but the version that ships with Ubuntu 14.04 doesn't support the --relative-to option (thus breaking the Travis build, which can't be upgraded to 16.x easily). My main reasons for choosing Python instead are that it's a one-liner and that if/when the move to SCons happens, we would likely have to do exactly the same anyways. I've seen many references to readlink -f, but none that would actually convert to/from relative paths, but then I didn't invest a lot of time either.

Forgot to add: it probably wouldn't be too much of an effort to turn all the relevant paths into absolute ones, at purely aesthetic impact on the build logs.

I use readlink -f to convert from relative to absolute; on OSX, this has to be greadlink and the Everest script already makes sure you have the right utility.
jonathan@chartreuse:~/Code/hacl-star/code (migrating_sts_bis) $ greadlink -f ../../hacl-star/..
/Users/jonathan/Code

In the interest of fixing this soon, and minimizing the impact on other people, do you think:
HACL_HOME=$(shell $(READLINK) -f $(THIS_DIR)/..)

would work? I don't mind absolute paths in the build logs.

But what I don't understand is the semantics of Makefile's include directive.
If code/ed25519/Makefile does include ../Makefile.include, can't Makefile.include use relative paths to itself? Is this why we need to compute an absolute point of reference for the root of the build directory?

Yes, readlink (or realpath) does relative -> absolute, but the other direction isn't that easy. Makefile.include already uses it's own (absolute) path (THIS_DIR) to find the root (HACL_HOME_ABS), but I kept everything relative from there on. The Makefiles previously used relative paths everywhere (not just for ../Makefile.include, but even for ../bin/fstar.exe, etc), so it was easier for me to keep those parts relative while refactoring. $(abspath ...) and $(realpath ...) are native to gnu-make though, thus easily applicable to everything. (And I don't care about build log aesthetics either.)
The trickier situations are where make calls itself via $(MAKE) in a different directory, because from there on everything that was previously relative is not updated and thus not relative to the current directory anymore. So, I just keep HACL_HOME_ABS as a reference, but we could just adopt the convention to keep exclusively absolute paths in variables.

But we have committed to using GNU make everywhere, so you can freely make the assumption that   $(abspath ...) and $(realpath ...) are available, right?

The convention to use absolute paths everywhere in variables seems fine, right? This is what we would get anyhow if we were to use a ./configure-style script?


Wechaty+微信小程序实现群内活动报名

Please make sure to check the following boxes creating your pull request, thank you very much!

[x] Add Blog Header, including title, author, image, categories, tags, etc.
For example:
---
title: Your Great Blog Title
author: your_github_id
categories: project
tags:
  - python
  - padlocal
image: /assets/2021/02-your-blog-slug/teaser.jpg
---

One line bio

Your blog post content Your blog post content
Your blog post content Your blog post content
Your blog post content Your blog post content

It will be easier to start drafting your post by using a existing post file as your template, for example, this one

[x] Keep all filenames lowercase, and use - to connect words instead of space. e.g. 2017-10-06-wechat-pc-impactor.md instead of 2017-10-06-WeChat PC Impactor.md

[x] Embed video/pdf from YouTube/Bilibili/local (if there's any) by using {% include iframe.html src="URL_or_PATH" %}. (Learn more about how to embed file/url in the post by reading this blog post

[x] Save photo to local before publishing, to a folder named by ${MONTH}-${YOUR_BLOG_SLUG}/ under /assets/2021/ directory.

[x] Select a beautiful and meaningful teaser image for your blog

[x] Create your contributor profile (if you are a first time contributor)
For excample:

jekyll/_contributors/lijiarui.md

---
name: Jiarui LI (李佳芮)
site: https://lijiarui.github.io
bio: 句子互动创始人 & CEO，微软人工智能最具价值专家 (AI MVP)
avatar: /jekyll/assets/contributors/lijiarui/avatar.png
email<EMAIL_ADDRESS>twitter: https://weibo.com/u/2175505900
---

Here is the example file:

lijiarui.md: https://github.com/wechaty/wechaty.js.org/blob/master/jekyll/_contributors/lijiarui.md
It will shown like this on wechaty website: https://wechaty.js.org/contributors/lijiarui/

To learn more about the contribute guideline, visit: https://wechaty.js.org/docs/contributor-program/

 Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.atorber seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you have already a GitHub account, please add the email address used for this commit to your account.You have signed the CLA already but the status is still pending? Let us recheck it.

done

Thank you very much for your contribution!
You are welcome to join Wechaty Contributor Program
1. Join Wechaty Organization

You've invited atorber to Wechaty! They'll be receiving an email shortly. They can also visit https://github.com/wechaty to accept the invitation.

I have invited you to join our Wechaty GitHub Organization, please accept it by following the above message.
2. Update Your Wechaty Contributor Profile

Please open Contributor Hall of Fame and add yourself to the end of the list, so that other contributors will know you better!
Please add yourself to our Website Contributors by creating a PR and refer to this PR link as well.

3. Join The Contributor Only WeChat Room
We also have a WeChat room for contributors only which can discuss Wechaty at a deeper level, you are welcome to join and if you are interested.
Please add @lijiarui wechat: ruirui_0914 and send her this pr link. She will invite you into Wechaty Contributor Room
Cheers!


Azure function and Kudu console NODE version mismatch in linux OS azure function.

I had hard time with my azure function when I try to deploy my function with node 18 lts. The configuration and package.json, linuxfxversion has node 18 lts as shown below.

So when I check the kudu console's NODE version, it is 14.19.2

although npm install is completed without any error. But I face NODE_MODULE_VERSION mismatch error when I trigger the function.

I have tried downgrading my azure configuration to node 14 lts and also changed in package.json to 14 lts. Only then I can run my function. This is not proper as we want our function to run in node 18, and its been happening since 2 years back with other older node version as well.
Do azure function hosted by linux support node 18 lts in kudu? Is there any way I can match the node version of kudu with my function which is node 18 lts. why is it showing mismatch NODE MODULE VERSION? Please help me resolve this.
https://github.com/Azure/azure-functions-host/issues/7485 similar to this issue.

Has there been any further traction on this? I can confirm that there is still a Node version mismatch with the a linux machine when using the remote build pipeline.
func azure functionapp publish <function-app-name> --build remote

By having the following value in a post-install script in the package.json file, you can see the following output:
> node -v

v14.19.2

This issue persists even after applying the linuxFxVersion via the following command:
az functionapp config set --linux-fx-version "node|20" --resource-group "<resource-group-name>" --name "<function-app-name>"


Add license type MIT. This is one specified in original source repo

Is it possible to update the License type and update the module in npm please ?

published in 0.0.5


Comments count as hardcoded references

Describe the bug

Lines that are commented out are considered in fct_hard_coded_references. We had two failures in our project triggered by the following comments:
-- SL eligible from 1.2 onward

--prework/start had null develop request id that was then filled
--e.g. select * from analytics.stg_dbt_cloud__ide_refresh_lifecycle
--     where startup_id = '8f9330cc-f76a-4a5e-97fd-a2fb8fc90ea7'`

Steps to reproduce

Include a commented out hardcoded reference like the examples above
Expected results

Commented out code does not count towards hard coded references
Actual results

Commented out code does count towards hard coded references
Screenshots and log output

System information
The contents of your packages.yml file:
Which database are you using dbt with?

[ ] postgres
[ ] redshift
[ ] bigquery
[x] snowflake
[ ] other (specify: ____________)

The output of dbt --version:
<output goes here>

We're on 1.4.6
Additional context

Are you interested in contributing the fix?

I don't think we will be able to fix those and you might have to list those as exceptions with a comment that this is because of the regex matching. Handling this use case is going to be tough with regexes.

Since they were just comments in our project I changed the language to avoid the flag, but I figured I'd raise an issue for y'all.
RE: handling with regexes, could you separate regex by into groups, separating groups by -- or //, and only evaluate the group not proceeded by a comment?


Table with exotic names  may fail to load its columns

On MySQL, there was a table "kön" (meaning gender in Swedish) that failed to load its columns in the UI.

There isn't anything in java that prevents us from generating foreign characters into class names more than good practise. I think the best solution would be to check if characters are alphanumerical, and if so, just let them through.


I can't start the bot

Bug Description
I can't start the bot normally
Steps to Reproduce
I run the bot with this command
java -Dnogui=true -verbose -jar JMusicBot-0.3.8.jar
Expected Result
Can someone help me? Sorry for my bad English.
Debug Output
[14.070s][info][class,load] java.net.StandardSocketOptions source: jrt:/java.base
[14.071s][info][class,load] java.net.StandardSocketOptions$StdSocketOption source: jrt:/java.base
[14.071s][info][class,load] java.net.NetworkInterface source: shared objects file
[14.071s][info][class,load] sun.nio.ch.SocketOptionRegistry source: jrt:/java.base
[14.071s][info][class,load] sun.nio.ch.SocketOptionRegistry$RegistryKey source: jrt:/java.base
[14.071s][info][class,load] sun.nio.ch.SocketOptionRegistry$LazyInitialization source: jrt:/java.base
[14.071s][info][class,load] sun.nio.ch.OptionKey source: jrt:/java.base
[14.071s][info][class,load] sun.nio.ch.ExtendedSocketOption source: jrt:/java.base
[14.073s][info][class,load] sun.nio.ch.ExtendedSocketOption$1 source: jrt:/java.base
[14.073s][info][class,load] sun.security.ssl.Alert source: jrt:/java.base
[14.077s][info][class,load] sun.security.ssl.Alert$AlertConsumer source: jrt:/java.base
[14.078s][info][class,load] sun.security.ssl.Alert$Level source: jrt:/java.base
[33.448s][info][class,load] net.dv8tion.jda.internal.requests.ratelimit.BotRateLimiter$$Lambda$180/0x0000000800e34110 source: net.dv8tion.jda.internal.requests.ratelimit.BotRateLimiter
[33.449s][info][class,load] java.lang.invoke.LambdaForm$DMH/0x0000000800e38000 source: JVM_LookupDefineClass
[33.449s][info][class,load] net.dv8tion.jda.internal.requests.ratelimit.BotRateLimiter$$Lambda$181/0x0000000800e34338 source: net.dv8tion.jda.internal.requests.ratelimit.BotRateLimiter
Additional Info
No response
Checklist

[X] I have looked for information about this within the documentation
[X] I have searched for similar issues on the issues page
[X] I am running the latest version of the bot:

There's not really enough information here to determine what problem you're having and what is going wrong. Also, running with the -verbose flag provides a lot of output that isn't useful to debugging the problem; it would be better to run without that flag.
If you can provide an explanation of what isn't working, as well as standard (non-verbose) console output, feel free to re-open this issue.


Add SElinux Z option to the docker run install command

Description
Addition of the SELinux Z option to the docker run install command.
Fixes
Issues/108

Can one of the admins verify this patch?


Lua 5.3 not detected correctly

I was getting no callstacks in the debugger because the version detection logic didn't work for me for a Lua 5.3 dll. I managed to get it working by just checking if a lua_rotate function is declared.

It looks like real fix is to always use the value from stateAddress instead of trying to use a optimized L in expressions.
long? version = EvaluationHelpers.TryEvaluateNumberExpression($"(int)*((lua_State*){stateAddress})->l_G->version", inspectionSession, thread, frame, DkmEvaluationFlags.TreatAsExpression | DkmEvaluationFlags.NoSideEffects);

Great idea, I've already had a fallback register lookup for state value, but didn't update the other two expressions.

Fixed in e611e404a864a7d5c04f600d869c9f8e43a99533
I will try to update the extension later on July 6th.


Remove unnecessary token from Stable Diffusion CLI

It was the case that we needed to accept terms of use before being able to download the model hence the need for the token. Great it's not required anymore!


serving/xrefs: remove all usages of Slow* functions [phab:D1932]

Created by schroederc at 2017-09-14 17:26:27:

fromberger accepted this revision at 2017-09-14 21:57:46

schroederc closed via commit eb19ab868db47dfab228aa6308ad96ede54e079f at 2017-09-15 10:25:00


Make it clearer if manual Cordon/Drain is requried if AKS node pool is deleted

Make it clearer if manual Cordon/Drain is requried if AKS node pool is deleted.
Many customers are expecting that Azure is taking care of this, if the Azure portal / CLI is used to delete a AKS node pool.

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

ID: e5b5876c-adc5-d81c-6ef7-0f376bb58ff7
Version Independent ID: 0746a217-f5a0-f294-4aa7-ab99df5b33d4
Content: Resize node pools in Azure Kubernetes Service (AKS) - Azure Kubernetes Service
Content Source: articles/aks/resize-node-pool.md
Service: container-service
GitHub Login: @zr-msft
Microsoft Alias: zarhoads

@RicardoNiepel Thank you for your feedback!  We've assigned this to the document author for further review.

Thank you for the feedback.
We've updated the article to address your feedback and the changes should be available soon.


license (and possibly credits) missing for affirmative.mp3 and ready.mp3

https://opengameart.org/content/sci-fi-rts-war-unit-sounds is gpl2, 3 or ccbysa3.
I can't find mention of either license or credits though.

They are mentioned in units.txt

Thanks! It's unclear which files are affected however. I can try to create a pull request to fix that. Would you prefer one txt file per file (affirmative.txt, bg.txt, building.txt etc) or one license.txt file that holds info on all files?
Under GPL my files don't require attribution but some files require attribution (explode, m16, music). Yet there are no credits on https://congusbongus.itch.io/blue-alert . Would you like me to prepare a formatted text block to include credits/license info on that page? (easier than adding a credits view in-game I imagine).

Yes, that sounds great. Either approach for the license files is fine.

After only 5 years… The sound pack is now CC0.
As for consolidated credits, which could be used on the itch page and/or in the README:
Credits
Code, Design
congusbongus [or perhaps use "full name (nickname)"]
Audio
Agony: Agony (https://freesound.org/s/162157/ CC0)
Mediapaja2009
Browning: Air Defense Artillery Avenger Training .50cal (tH4YBTw8vk8).flac (http://freesound.org/s/160355/ CC0)
Tank Fire: Tank Firing (http://freesound.org/s/168707/ CC0)
Units (http://opengameart.org/content/sci-fi-rts-war-unit-sounds CC0)
qubodup
Explode: Various C64 Sid Chip Sound Effects (http://opengameart.org/content/various-c64-sid-chip-sound-effects CC BY-SA 3.0)
Panayiotis Yianni (Amon)
M16: M-16 automatic gun (http://freesound.org/people/Julien Nicolas/sounds/133799/ CC BY 3.0)
Julien Nicolas
Music: Crystalline Refinement (Into This Wired Abyss Vol. 3) (http://www.ektoplazm.com/free-music/into-this-wired-abyss-vol-3 CC BY-NC-SA 4.0)
False Identity
Speech: RTS commands and reports (http://opengameart.org/content/rts-commands-and-reports CC0)
Daniel Stephens (Scribe)
Font
Boxy Bold Regular 12: Boxy Bold - TrueType Font (http://opengameart.org/content/boxy-bold-truetype-font CC0)
Clint Bellanger
Images
BG: Background Set (http://opengameart.org/content/background-set CC BY-SA 3.0)
Dominique Knobben (AquilaSol)
Original (https://opengameart.org/content/large-nature-background) © 2012-2013
Julien Jorge<EMAIL_ADDRESS>Credits HUD: Shiny hud (http://opengameart.org/content/shiny-hud CC0)
Michele Bucelli (Buch)
Cursors: Copyright 2008 (Licensed under CC BY 3.0 https://opengameart.org/content/cursors-arrows-map-markers-ardentryst)
Elle Trudgett (https://github.com/elle-trudgett)
Defeat: Nuclear Mushroom Cloud (http://opengameart.org/content/nuclear-mushroom-cloud CC0)
United States Department of Energy
Jeep Button: Svalbard landscape.jpg (http://commons.wikimedia.org/wiki/File:Svalbard_landscape.jpg CC BY 2.0)
Billy Lindblom
Marine Button: White Plains (http://commons.wikimedia.org/wiki/File:White_Plains.jpg CC BY 2.0)
Kurt Nordstrom (from Ponder, TX, USA)
Truck Button: Autumn Asphalt Road Landscape Forest Birch Tree (http://pixabay.com/p-218127/?no_redirect CC0)
PublicDomainPictures
Units: Blender models for Freeciv units (http://opengameart.org/content/blender-models-for-freeciv-units CC0)
yd
Victory: Flickr - Israel Defense Forces - 188th Brigade Training Day, March 2008-cropped.jpg (http://commons.wikimedia.org/wiki/File:Flickr_-Israel_Defense_Forces-_188th_Brigade_Training_Day,_March_2008-cropped.jpg CC BY 2.0)
Matanya
License Info
CC0 (Creative Commons Zero)
http://creativecommons.org/publicdomain/zero/1.0/
CC BY 2.0 (Creative Commons Attribution 2.0)
http://creativecommons.org/licenses/by/2.0/
CC BY 3.0 (Creative Commons Attribution 3.0)
http://creativecommons.org/licenses/by/3.0/
CC BY-SA 3.0 (Creative Commons Attribution-ShareAlike 3.0)
http://creativecommons.org/licenses/by-sa/3.0/
CC BY-NC-SA 4.0 (Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International)
http://creativecommons.org/licenses/by-nc-sa/4.0/
GPL 2.0 (GNU General Public License, version 2)
http://www.gnu.org/licenses/gpl-2.0.html
Thanks to
ImgBot

Code:
## Credits

### Code, Design
congusbongus [or perhaps use "full name (nickname)"]

### Audio

Agony: Agony (https://freesound.org/s/162157/ CC0)
Mediapaja2009

Browning: Air Defense Artillery Avenger Training .50cal (tH4YBTw8vk8).flac (http://freesound.org/s/160355/ CC0)
Tank Fire: Tank Firing (http://freesound.org/s/168707/ CC0)
Units (http://opengameart.org/content/sci-fi-rts-war-unit-sounds CC0)
qubodup

Explode: Various C64 Sid Chip Sound Effects (http://opengameart.org/content/various-c64-sid-chip-sound-effects CC BY-SA 3.0)
Panayiotis Yianni (Amon)

M16: M-16 automatic gun (http://freesound.org/people/Julien%20Nicolas/sounds/133799/ CC BY 3.0)
Julien Nicolas

Music: Crystalline Refinement (Into This Wired Abyss Vol. 3) (http://www.ektoplazm.com/free-music/into-this-wired-abyss-vol-3 CC BY-NC-SA 4.0)
False Identity

Speech: RTS commands and reports (http://opengameart.org/content/rts-commands-and-reports CC0)
Daniel Stephens (Scribe)

### Font

Boxy Bold Regular 12: Boxy Bold - TrueType Font (http://opengameart.org/content/boxy-bold-truetype-font CC0)
Clint Bellanger

### Images

BG: Background Set (http://opengameart.org/content/background-set CC BY-SA 3.0)
Dominique Knobben (AquilaSol)
Original (https://opengameart.org/content/large-nature-background) © 2012-2013
Julien Jorge<EMAIL_ADDRESS>
Credits HUD: Shiny hud (http://opengameart.org/content/shiny-hud CC0)
Michele Bucelli (Buch)

Cursors: Copyright 2008 (Licensed under CC BY 3.0 https://opengameart.org/content/cursors-arrows-map-markers-ardentryst)
Elle Trudgett (https://github.com/elle-trudgett)

Defeat: Nuclear Mushroom Cloud (http://opengameart.org/content/nuclear-mushroom-cloud CC0)
United States Department of Energy

Jeep Button: Svalbard landscape.jpg (http://commons.wikimedia.org/wiki/File:Svalbard_landscape.jpg CC BY 2.0)
Billy Lindblom

Marine Button: White Plains (http://commons.wikimedia.org/wiki/File:White_Plains.jpg CC BY 2.0)
Kurt Nordstrom (from Ponder, TX, USA)

Truck Button: Autumn Asphalt Road Landscape Forest Birch Tree (http://pixabay.com/p-218127/?no_redirect CC0)
PublicDomainPictures

Units: Blender models for Freeciv units (http://opengameart.org/content/blender-models-for-freeciv-units CC0)
yd

Victory: Flickr - Israel Defense Forces - 188th Brigade Training Day, March 2008-cropped.jpg (http://commons.wikimedia.org/wiki/File:Flickr_-_Israel_Defense_Forces_-_188th_Brigade_Training_Day,_March_2008-cropped.jpg CC BY 2.0)
Matanya

### License Info

CC0 (Creative Commons Zero)
http://creativecommons.org/publicdomain/zero/1.0/

CC BY 2.0 (Creative Commons Attribution 2.0)
http://creativecommons.org/licenses/by/2.0/

CC BY 3.0 (Creative Commons Attribution 3.0)
http://creativecommons.org/licenses/by/3.0/

CC BY-SA 3.0 (Creative Commons Attribution-ShareAlike 3.0)
http://creativecommons.org/licenses/by-sa/3.0/

CC BY-NC-SA 4.0 (Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International)
http://creativecommons.org/licenses/by-nc-sa/4.0/

GPL 2.0 (GNU General Public License, version 2)
http://www.gnu.org/licenses/gpl-2.0.html

Thanks to
ImgBot

Note: the two spaces at the end of many lines are needed by markdown for a line break.


Getting multiple fields in Joins

Hi,
I have googled and not found what I was looking for:
I would like to bring multiple fields out of joins. When I choose one, I would like to fill multiple fields in a form. How can I do that? I could see single field example, but not multiple ones.
Any help would be greatly appreciated.
Thank you.

@innocube I'm not sure I understand your issue... show me that "single field example".

Perak,
In your Join Example,
    {
        "name": "companies",
        "fields": [
            {
                "name": "name",
                "title": "Company name"
            }
        ]
    },
    {
        "name": "employees",
        "fields": [
            {
                "name": "name",
                "title": "Employee name"
            },
            {
                "name": "companyId",
                "join_collection": "companies",
                "join_container": "company",
                "join_fields": ["name"]
            }
        ]
    }

You are getting single field, "name" from company collection. There must be a way to get let's say company address as well as name. I was wondering how to do that.
Thank you in advance for your help!

Let me show you another example. Let's say I want to choose an item from the following:
items - sku, description, price
In my joins, I would like to get price along with what I selected, sku automatically.

@innocube in example you copied, see join_fields array: this is where you define which fields you want from companies collection:
"join_fields": ["name", "address", "phone"]

Perak,
Yes, that's right. And when I select, let's say, just a name among several, how can I populate corresponding address and phone information in my code using meteor-kitchen?

Hum... you are selecting it using  ? Maybe to add "select change" event. There is no automatic way provided by kitchen.

Perak,
Thank you for your responses!
				{
					"name": "itemId",
					"title": "Item",
					"required": true,
					"input": "select",
					"lookup_query_name": "item_list",
					"lookup_field": "description",
					"lookup_key": "_id",
					"show_in_dataview": false,
					"show_in_read_only_form": false,
					"exportable": false,

					"join_collection": "items",
					"join_fields": ["description", "price"],
					"join_container": "item"
				},
				{
					"name": "item.description",
					"title": "Item",
					"show_in_insert_form": false,
					"show_in_update_form": false,
					"exportable": true
				},
				{
					"name": "item.price",
					"title": "Price",
					"type": "float",
					"show_in_insert_form": false,
					"show_in_update_form": false,
					"exportable": true
				},

By using this, now I could successfully display the linked price information (item.price) as I select item.description. However I have learned that there is no way that I could reference that item.price in before_insert_code. Do you have any idea?

@innocube data is joined performing transform http://docs.meteor.com/#/full/mongo_collection
In collection before.* and after.* hooks you got raw data from database (not modified with transform) and that's why you cannot access joined data from there.
However, you can still do var item = Items.findOne({ _id: doc.itemId }); in your hooks.

Perak,
That was exactly what I was looking for!
Thank you so much, my life-saver!

:+1:
Let's close issue if it is solved.


Assume population of 100,000 in manual input.

This reverts commit b5550401b42baf79791d96f3550f51a200f0e16d, restoring f14ad0b9fe9c78b46f81405b9482bdf5a754d9ff.
This change is a re-introduction of #1822.

I realized after proposing this change that the approach needs to be revisited because the latest proposal is to continue to keep the field but default to 100k and warn if it's not.


[5.6][android] Move the string and other tags in pointers to the second byte because Android enabled memory tagging

Cherrypick of #40779
Explanation: Starting with Android 11, AArch64 placed a tag in the top byte of pointers to allocations, which has been slowly rolling out to more devices and collides with Swift's tags. Moving these tags to the second byte works around this problem.
Scope: With the exception of the two KeyPath changes, which @jckarter suggested and said he wanted for all platforms, this pull does not modify any platform other than Android AArch64.
SR Issue: None
Risk: low
Testing: I've been applying most of this pull to the native Swift toolchain which I maintain that runs on Android devices for the last couple months, termux/termux-packages@5d98fde, with the toolchain now finally working on Android 11+ devices with tagging enabled and without any user complaint.
Reviewer: @milseman
Once this is in the official 5.6 compiler build, my Swift 5.6 Android AArch64 SDK should start working on tagged devices too.

@jckarter, if you would approve the compiler side of this pull, I'd like to get it in for the next 5.6 point release.

Once 5.6 was released, the 5.6 branch should only be for major regressions or security fixes, so I don't think we can take this change onto that branch. I understand this unlocks important use cases for an architecture, but given support for this platform is still in bringup mode, it's hard to justify merging this (even if there was a release vehicle for another 5.6 compiler, which it's not clear there will be before 5.7 now that that has branched). I suggest bringing this onto the 5.7 branch.

the 5.6 branch should only be for major regressions or security fixes, so I don't think we can take this change onto that branch. I understand this unlocks important use cases for an architecture, but given support for this platform is still in bringup mode, it's hard to justify merging this

This isn't a regression or security fix, but it fixes a major incompatibility introduced on Android AArch64 since Android 11 for devices that have memory tagging enabled. In my house, that's two out of three devices running Android 11+.

even if there was a release vehicle for another 5.6 compiler, which it's not clear there will be before 5.7 now that that has branched

Historically, the March release ships several point releases till the September release, ie 5.4.3 shipped last Sept. 9. Are you saying that's changing and 5.7 will ship much earlier?
The only reasons I submitted this PR is because most of it is exclusive to Android AArch64 so it doesn't affect any other platform, and I distribute an Android SDK that can be used with the official shipping 5.6 compiler for linux, but this fix requires changes to the compiler.
If you'd like, I can remove the two KeyPath changes that are applied to all platforms and then this patch only affects Android AArch64, with all changes scoped with #if os(Android) && arch(arm64) and if (IGM.Triple.isAndroid() && IGM.Triple.getArch() == llvm::Triple::aarch64).
That would represent zero risk to the 5.6 branch on existing supported platforms, but fix a major incompatibility on Android AArch64. Please let me know what you think.

Ping @airspeedswift, can we get this in? It only affects Android AArch64 now, so represents zero risk to other platforms.

@shahmishal, I'd like to get this into 5.6.3, please let me know what you think.

@swift-ci test

Mac CI failure with Swift Docc is unrelated.

@shahmishal, can we get this merged before the release?

Thanks for getting this in, @shahmishal and @milseman, now I need to update my Swift 5.6 Android SDK to use it.


cannot build native library

I'm following the steps in the README (7. Extend a native application).
I am running the community edition of GraalVM
> java -version
openjdk version "1.8.0_212"
OpenJDK Runtime Environment (build 1.8.0_212-20190523183630.graal2.jdk8u-src-tar-gz-b03)
OpenJDK 64-Bit GraalVM CE 19.1.0 (build 25.212-b03-jvmci-20-b04, mixed mode)

I have been able to run with success the following command:
native-image --no-server -cp sis.jar:. --shared -H:Name=libdistance

However, when I run
clang -I. -L. -ldistance distance.c -o distance

I get the following error:
distance.c:4:10: fatal error: 'libdistance.h' file not found
#include <libdistance.h>
         ^~~~~~~~~~~~~~~
1 error generated.

Do you not have any headers generated from the native-image command? Has it produced any .h files in the current directory?

@chrisseaton It has produced two header files graal_isolate.h and graal_isolate_dynamic.h

Ok I'll try reproducing - may take me a little while to get to it.

Ok. Thanks. If you can help me by the end of the week that'd be great!

I can reproduce.

Yes something is wrong here. Thanks for reporting. The only workaround I can suggest for now is to use 19.0.

We found the bug and fixed it in https://github.com/oracle/graal/commit/f52c6ef6498b948816c828804013ae72d75bd883.
This won't be part of a release for a few weeks though.
Thanks for the report.


Fix Package.swift and Package.resolved

Currently Package.swift refers to the 5.0.0 branch in the Alamofire repository, but this branch doesn't exist. Additionally, Package.resolved doesn't match any of the versions or branches specified in Package.swift. This leads to an error when installing OAuthSwiftAlamofire as a dependency:

🙏 thanks


The input image resolution

Hello,
I could not understand the input image resolutions to the image backbones from the configs of baseline models.
Can you share that information?
Thank you in advance

The images are in H x W except that the front-view image is in W x H.

I understand your point but is there any resizing or 1550x2048 is directly utilized in the image backbone?

Because we need to stack multiview images of a single frame in the same batch for implementation, so they need to be in the same shape.

I understand that all images are in same resolution. We are at the same point there. What I am asking is that are all images in 1550x2048 resolution? I am actually asking what is H and W that is entering to the image backbone.

I think you can just print out the shape of the input tensor.

I am currently not working with mmdet3d, that is why I am asking that. As much as I understand there is not any scaling operation in the baseline implementation of this repo. I just wanted to double check if it is possible. However baselines here https://paperswithcode.com/sota/3d-lane-detection-on-openlane-v2-2 utilize scaling or resizing in their configs in their original repos. I am trying to figure out are these baselines obtained with original image resolution or with the scaling and resizing as indicated in their original repos.

Please just feel free to change the resolution. In my experience, the resolution has a larger impact on memory consumption than model performance.

BTW, for the front-view image, other operations are also possible, such as cropping.


fixed autofill input styling, fixed margins on error messages and add…

…ed text shadow. started working on button disabling. this solves issue #50 and starts working on issue #51

looks great!


Finish New Lsq Assembly

[ ] Allow general weights dictionary
[ ] PR to ACEpotentials to allow AtomsBase data as input to acefit!
[ ] PR to ACEfit to replace the assemble implementation (tbc)

Re point on ACEpotentials: the line
https://github.com/ACEsuit/ACEpotentials.jl/blob/a1dc2e8409113f198ba4003f0c5a6911be53d2f1/src/model.jl#L63
needs to be replaced with a dispatch depending on whether raw_data is JuLIP or AtomsBase


All money in the wallet got unconfirmed!

All money in the wallet just got 'unconfirmed'. All transactions switched to 'receiving'. Additional info says 'Unknown transaction status'. But if I open this transaction on blockchain.info, it says something like '536 confirmation' and so on.
Is it a bug?

See this article: https://multibit.org/en/help/hd0.1/request-bitcoin.html for details on why the "+Unconfirmed" message appears in the "Tracking your payment request's progress" section.

Great! Repair wallet fixed the problem. Another question - why is it happened? I have Mac client (0.3.0). May be it is a side-effect of reserving the wallet in dropbox or using sleep mode on mac. Anyway, the problem is solved, so I'm going to close it.


nerian_sp1: 1.0.2-1 in 'jade/distribution.yaml' [bloom]

Increasing version of package(s) in repository nerian_sp1 to 1.0.2-1:

upstream repository: https://github.com/nerian-vision/nerian_sp1.git
release repository: https://github.com/nerian-vision/nerian_sp1-release.git
distro file: jade/distribution.yaml
bloom version: 0.5.20
previous version for package: 1.0.2-0

nerian_sp1
* Minor fixes to build files

you seem to have problems building, you might want to run pre-releases first no ? http://wiki.ros.org/bloom/Tutorials/PrereleaseTest

Thanks. Sorry for the many releases. I will do that next time.
On 15-08-25 12:07 PM, Vincent Rabaud wrote:

you seem to have problems building, you might want to run pre-releases
first no ? http://wiki.ros.org/bloom/Tutorials/PrereleaseTest
—
Reply to this email directly or view it on GitHub
https://github.com/ros/rosdistro/pull/9273#issuecomment-134545492.

--
Dr. Konstantin Schauwecker
Nerian Vision Technologies
Gotenstr. 9
70771 Leinfelden-Echterdingen
Germany
Phone: +49 711 2195 9414


[LiveComponent] parameter route doesn't exist

On attribute AsLiveComponent, the 'route' parameter doesn't exist but documentation refers to it.

This will also be added in 2.7.


I've modified the links to the official ClubVault site

The links were either going to Priyatham's repo or my repo, so I've modified them so that they all redirect to official repo only, also I've used internal linking wherever possible so that it is easier to manage new events links.

The Git and Github Event folder is also created

Sorry, I forgot to mention link of the session in main readme. I've mentioned the Club Vault link, it won't work now but it will work after merge.


Keep selected function(ish) between editor and block

Is your feature request related to a problem? Please describe.
When I switch between JS and blocks mode, try to keep the position of my selection between the modes.
Describe the solution you'd like
for example. If I clicked on "JavaScript" in this screenshot

Then it would be great to jump to here (and flash the function using a monaco decorator instead of the selection like I'm using)

This is lot of work for us and not going to do in the immediate future. Closing.


(Blog,People,News,Partners) Pages

For pages like (Blog,People,News,Partners) ll be call it from Threefold_data repo?
or ll be embedded inside the website?

in website


Update to 1.19.4

Description
Closes #291

Update extractors to support Minecraft 1.19.4
Update code generators.
Changed generated entity component names to avoid name collisions.
Update glam version.
Added Encode and Decode for glam types in valence_protocol.
Fixed inconsistent packet names and assign packet IDs automatically.
Remove ident and rename ident_str to ident.
Rework registry codec configuration. Biomes and dimensions are configured from BiomeRegistry and DimensionTypeRegistry resources. The vanilla registry codec is loaded at startup.

Test Plan
Steps:

Boot up a vanilla server with online mode disabled.
Run the packet_inspector.
Connect to the vanilla server through the packet inspector to ensure all packets are updated correctly.
Close the vanilla server and try some valence examples.

Not sure I'm happy with this approach to biome and dimension configuration.
In summary, biomes and dimensions exist as entities that can be queried. The main benefit is that user-defined components can be attached. BiomeRegistry and DimensionTypeRegistry contain lookup tables. However, there is the possibility that the tables become stale for a time after biomes/dimensions are added/removed.


Visualize fields of the PODIO subset collections

The current representation of subset collections will only show <collection_name>_objIdx fields. It would be better UX if capybara could detect that this has meaning in PODIO and summarize the referenced objects.

Resolved in b89d7e0df8da0279d8307b2a35f366690414beb5


[TextInput] alignText props does not work with multiline TextInput.

Hi,
when I use alignText props with non-multiline TextInput, it works fine.
But when I use it with multiline TextInput, it doesn't work.
Here is the screenshot.
The upper TextInput has multiline set to false, and textAlign set to 'right'.
The lower one doesn't work with textAlign set to 'right' or 'end'.

Hi there! Multiline TextInput is likely to be re-written to support auto-scaling based on content size: #1229
cc @lukasreichart let's make sure that the rewrite supports this.

@f15gdsy @brentvatne Thanks for reporting. I'll look into this problem.

Thanks @lukasreichart we :heart: you

@lukasreichart also "multiline" does not set the cursor correctly if an initial value is provided. You will start typing in front of the provided text. Tested on iOS only.
Thanks a lot

@dnbrwstr does this fix my mentioned issue from above too? (or was it fixed in some other version by now?)

Looks like the placeholder text still ignores textAlign when multiline is true.
Using RN 0.26.3.


Stripe - A token may not be passed in as a PaymentMethod. Instead, use payment_method_data with type=card and card[token]

What I'm trying to achieve
Complete a checkout with Stripe as the payment method.
Steps to reproduce the problem

Add keys to Stripe plugin
Retrieve token via StripeJS/Elements
Mutation createCheckoutPayment(...)
Mutation completeCheckout(...)

What I expected to happen
Checkout to be completed, instead it throws an error
Screenshots

System information
Operating system:
MacOS Cataline 10.15.5
Running Saleor with Docker

Hi @thomasjiangcy,
Which version of Saleor are you using? I've just tested it with our storefront and everything works correctly. Please send exact mutation with input variables that cause the problem.

Hi I used the latest version of Saleor, and I'm experieincing the same issue version 2.10, I get the same error....

We're also experiencing this checkoutError on 2.10. It's happening after we call the checkoutComplete mutation with a valid checkoutId, which is being called after we await a call to checkoutPaymentCreate which contains a token that we've previously obtained from Stripe.
The specific error we're receiving is ""A token may not be passed in as a PaymentMethod. Instead, use payment_method_data with type=card and card[token]=<% our_valid_stripe_token_here %>."
@IKarbowiak I had a look through the release notes and didn't find mention of a fix for this. When you tested, on which version did you run your tests?

Doesn't the Stripe integration in Saleor expect a paymentMethod.id instead of a token?  Docs here: https://stripe.com/docs/payments/accept-a-payment-synchronously

Hey, for Saleor3.0 we fully rebuild a Stripe plugin. It uses custom payment flow and payment intents. Here you can find more details - code: #7452 docs: mirumee/saleor-docs#277
It has support for 3ds also and async communication with Stripe (Stripe's webhooks)


{@link https...} inside a @remarks causes error TS2304: Cannot find name 'https'

Bug Report
🔎 Search Terms

jsdoc
tsdoc
TS2304: Cannot find name 'https'.
@link
@remarks

🕗 Version & Regression Information

This is the behaviour in every version I tried, and I reviewed the FAQ for entries ✅

I checked on 4.6.4, 4.6.2.
I tried checking on 4.7.0-rc1 but I got unrelated errors.
⏯ Playground Link
I don't understand how to use the 'Bug Workbench', it doesn't seem to pick up the config I enter.
https://www.typescriptlang.org/dev/bug-workbench/?target=99&allowSyntheticDefaultImports=true&explainFiles=true&forceConsistentCasingInFileNames=true&listEmittedFiles=true&listFiles=true&sourceMap=false&traceResolution=true&noImplicitOverride=true&noFallthroughCasesInSwitch=true&types=["typescript-to-lua%2Flanguage-extensions"%2C "lua-types%2F5.2"%2C "typed-factorio%2Fruntime"]&lib=&ts=4.6.2#code/PTAEAEBcEMCcHMCmkBcpEGcB2iAekAoAkCAMwEsAbRLaAW0TQAdoBjAa2iQDoArDAPZYCAbwKhQAIloNJaSXQCeAWlJtIA2OQHK6AgCaSANOKkA3RLAzascqQAZuAVm73jpyUy1nokRHchYAFdEEwlJDFYtJkgMOzEJcIAjIKpDeVjISndEqX1EMztJTMpQZWUAd19WAAtJUwBfMKkaeHIcOLQExOkDf3kAPwBGABZuIYBOcfqJJo98swARRCYafKxWckx4ufD81ax1ze2u03DKIOhlSEVVzqkAPQAmcaHXHJ6bu6jyGOudC7QIpvMYjD7hL6IfSqdSabTA8bvZoQ26YH4xIpjABs3CeM1AuyklHIrBoGH6UgAqgA5AAyAEkAMIAUWpAGVmYsPp5EJZlgcjlt7iJCZIBDEbNBKPy1jRjsLRSlDtR9DLDnKhXYANoAXQIDSIxDA4Ao1BkjFAsVYQgo8D4giwoFEHgAJJEaog6ED5DVIJAmBgUCBYNAKtw2pAakEUuTYNasH4E9xrXRgAAVVFs9GQNMCWmXYBmSJ9a6oyLRSD-ZSA4BejB+WDAK028jwZTuz3Qe1CbkpphUSwAeQlQmFZykMAQyCKmBw+HBRPISW14-Cs7wkHxEh1yKken0QWoRRTeiw-AXCgMh8QACVMAILpAbEUsH0L5D7lrVxOy9mqzXKGgLB4EuJBlA3MkbDiXdzkuUs7mAFw8Rgn9VmhNRWA0LQBGAYIE3IWRxx3cdPAuNosE-b9ulycJzSKD8-xKZQmDI9ot0SA1cmI3JJClSgBAqNlFATD0n1YZY1EPSB6ToJhNFiAJglCEjMAAWSvah6QTSxxUUkJd0kPAWOgdoADEB3uQJ9JI0hNFJRlR3IesaEgRloGsYCtPM6hqXoE5LSUgziXrZk6HIP0oW8-yrOUnjgsgKLLMCkjXxkliSXCgBBLBFD02KelS2TiU2HMaicvKDMEII40QVToCYOw1EoclKsCElNzQGLWq0TDTKCDYnyEDM7gqkj6x6yBqUPShGQ9DgkusnjAjYW970fZ9OuSnjCvSkq70gaqKNG7aBDS4rwsHCxYC0fJjoKgRTL4yNYAEIJ4BqNzyQwLS2QqcLajyxpmmKetslOOLLjTOAkA6qQkPfUGADVLCSARyTu2iBAACUQaB8lgDGpB287IDZRBKFIQnJEBWklzS+SilgRAAEdUiZ-EDQNIgSBNAdzTQeNAgfbhYiIctfkgbghAAfXacKAAp5YASlAABeAA+UBqNAfj4HlgADfdQCc0A8fyfRLQES0PVADBoAsfWlf1J2gA
But when I set up those 3 files in a directory and run npm install then npm build, I get this error
...
Emitting ...
Emit finished!
node_modules/typed-factorio/generated/classes.d.ts:238:3 - error TS2304: Cannot find name 'https'.

238   on_init(f: (() => void) | undefined): void
      ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Process finished with exit code 2

Here's a reproduction inside the TSTL playground. You might have to edit the file to trigger it
https://typescripttolua.github.io/play/#code/PQKhCgAIUhRA7ALgJwJ6QA4HsCWTIBmWykyApgOY4DOiZyeFkZAbmfgBYCG8AJgDb1qAOkgBJRJBqQuAY1llq1HACNBkRB2RYArhQ4aOZSBX5YVXfpHMArMrMnwuAWzK9IAA2qyGGRB+EoCGhIAG8AAX48AGtIDkREDGoALmBgfh0uAFouDBxhAjlEYhwsYVksZ3SuOlpgABlMgCEsLERaZFzheOcrADUcMgB3SF4sWR1XJBrS+ABfIMhw+CwAZTJ+AiDgcDw6ZEKFSEauFraO3LCoSFBgyBDw8mcuZGjqa+gPmHqY6khZHiYXD4YoySAAVQASvVkmFIjE4gkkqlgFRNDoVOVKsBnDgfFhqFgCIhgO0xrIFvdoDt7lh4AB9PA4RAACgIsJZLIAlJAALwAPkgLFwvB5XNhwpwvHAC3AFXgtEg3l8klhJzO7RQl15Vyp1gZTMQHIAHjyBZBjdyZeBwMqcH5hHTGfBmZyzYLQhgGEgWQAiIhYX1cuZc8BAA

💻 Code
An MRE is below, but the error originates in the TSDoc of the Typed Factorio project, in classes.d.ts.
  /**
   * Register a function to be run on mod initialization...
   *
   * {@link https://lua-api.factorio.com/latest/LuaBootstrap.html#LuaBootstrap.on_init View documentation}
   * @param f The handler for this event. Passing `nil` will unregister it.
   * @remarks For more context, refer to the {@link https://lua-api.factorio.com/latest/Data-Lifecycle.html Data Lifecycle} page.
   * @example Initialize a `players` table in `global` for later use.
   *
   * ```
   * script.on_init(function()
   *   global.players = {}
   * end)
   * ```
   */
  on_init(f: (() => void) | undefined): void

If I remove the {@link ...} from the @remarks, then it works!
  /**
   * Register a function to be run on mod initialization...
   *
   * {@link https://lua-api.factorio.com/latest/LuaBootstrap.html#LuaBootstrap.on_init View documentation}
   * @param f The handler for this event. Passing `nil` will unregister it.
   * @remarks For more context, refer to the xxxxxxxxxxxxxxxxxx page.
   * @example Initialize a `players` table in `global` for later use.
   *
   * ```
   * script.on_init(function()
   *   global.players = {}
   * end)
   * ```
   */
  on_init(f: (() => void) | undefined): void

The @remarks and the {@link ...} was added last week:
https://github.com/GlassBricks/typed-factorio/commit/f18205f70d75f88b02c14fff7a70abcc562e721b#diff-9e3b31eca93c33b0d77c73d8688a93f48e81e18d86efdc4c57ac1d5d76ce8845R229
If I revert Typed Factorio to v1.0.0, then again, there's no error.
Minimal, reproducible example

click to expand
./control.ts
script.on_init(() => {
  log(`mod is added to the save`)
})

./package.json
{
  "name": "my-factorio-mod",
  "version": "0.5.0",
  "private": true,
  "scripts": {
    "build": "tstl",
    "dev": "tstl --watch"
  },
  "engines": {
    "node": "~14.19.1"
  },
  "devDependencies": {},
  "dependencies": {
    "lua-types": "^2.11.0",
    "typescript-to-lua": "1.4.4",
    "typed-factorio": "1.1.0",
    "typescript": "4.6.2"
  },
  "license": "UNLICENSED",
  "peerDependencies": {},
  "optionalDependencies": {},
  "bundledDependencies": []
}

./tsconfig.json
{
  "$schema": "https://raw.githubusercontent.com/TypeScriptToLua/vscode-typescript-to-lua/master/tsconfig-schema.json",
  "compilerOptions": {
    "target": "esnext",
    "lib": [
      "esnext"
    ],
    "module": "commonjs",
    "moduleResolution": "node",
    "types": [
      "typescript-to-lua/language-extensions",
      "lua-types/5.2",
      "typed-factorio/runtime"
    ],
    "plugins": [
      {
        "name": "typescript-tstl-plugin"
      }
    ],
    "allowSyntheticDefaultImports": true,
    "esModuleInterop": true,
    "explainFiles": true,
    "forceConsistentCasingInFileNames": true,
    "listEmittedFiles": true,
    "listFiles": true,
    "noImplicitAny": true,
    "noImplicitThis": true,
    "sourceMap": false,
    "strict": true,
    "strictFunctionTypes": true,
    "strictNullChecks": true,
    "traceResolution": true,
    "noImplicitReturns": true,
    "noImplicitOverride": true,
    "noFallthroughCasesInSwitch": true
  },
  "tstl": {
    "luaTarget": "5.2",
    "tstlVerbose": true,
    "noHeader": true,
    "noImplicitSelf": true,
    "luaLibImport": "require"
  }
}

🙁 Actual behavior
TSDoc with a {@link https:...} inside of a @remark block causes an error
   * @remarks For more context, refer to the {@link https://lua-api.factorio.com/latest/Data-Lifecycle.html Data Lifecycle} page.

node_modules/typed-factorio/generated/classes.d.ts:238:3 - error TS2304: Cannot find name 'https'.

238   on_init(f: (() => void) | undefined): void
      ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Process finished with exit code 2

🙂 Expected behavior
TSDoc with a {@link https:...} inside of a @remark block does not cause an error
Workaround
A workaround is to add "skipLibCheck": true to tsconfig.json > compilerOptions.
See also

https://github.com/GlassBricks/typed-factorio/issues/13
https://github.com/microsoft/tsdoc/issues/9
https://github.com/TypeScriptToLua/TypeScriptToLua/issues/1058

This is a tstl issue.

Thanks for investigating @andrewbranch, I appreciate it.
I thought the error was related to TypeScript because TSTL is producing correct LUA code, it's only the TypeScript compiler that complains. Can you provide more information on how you came to think that? What needs to change in TSTL to fix it?

I’m not 100% sure how it’s happening, but I was unable to reproduce the problem with TypeScript alone (whether with tsc or viewing errors in the editor). Also, I know we don’t issue name resolution errors on @link tags because doing so was a feature request we recently discussed that I argued we should decline. And the fact that the error appeared not on the JSDoc tag itself but on the usage of one of the things it decorated is very bizarre, which reads a lot like someone made a mistake leveraging the TS compiler. My investigation was pretty quick so there’s always a chance I’m wrong, but there was enough evidence that I feel comfortable saying you’d need to give a repro that doesn’t use external tools in order for me to believe the issue is not in the external tools.

@andrewbranch I have done some further investigation, this looks to me like we are using the TS API as intended, if not please correct me where we are going wrong:
This diagnostic seems to happen when calling getJsDocTags() on the signature of the CallExpression script.on_init(() =>{ }).
Effectively what we are doing is (where callExpression is the code above):
typeChecker.getResolvedSignature(callExpression).getJsDocTags()

Full stacktrace of my little reproduction scenario is:

Digging a little further with my debugger it seems that getDisplayPartsFromComment is called with the following node:

Node at index 0 seems fine, but the second node seems a bit suspicious. node.kind is 324, which is SyntaxKind.JSDocLink as expected, what is weird that node.name is an identifier 'https'. It then tries to resolve this symbol as if it was referring to a variable in code in using checker.getSymbolAtLocation(link.name) in buildLinkParts which ends up adding the diagnostic via resolveEntityName on this https identifier.
I'm not sure what expected behavior is here, or what we could do to prevent this.

When I change @remarks to remarks then it doesn't trigger the error tstl-playground example
interface LuaBootstrap {
  /**
   * remarks
   *
   * Link {@link https://github.com/microsoft/tsdoc}
   */
  on_init(f: (() => void) ): void
}

const script : LuaBootstrap = {
    on_init: (x) => x()
}

script.on_init(() => { })

When I change remarks back to @remarks it does tstl-playground example (make an incidental edit to trigger the error)
Both examples have the same JSDocLink structure, with a https as an Identifier

The difference between the two is that the @remarks version has a FirstJSDocTagNode, while the other does not.
The error is specifically triggered by an {@link ...} being inside a @remarks block - if the link is in a preceding block, it works tstl-playground example
What does tsc do inside of a @remarks block that's different to a regular JSDoc block?

@andrewbranch Interesting, I was not expecting this order of operations to matter but it seems that at least in our tstl tests we are calling getPreEmitDiagnostics(program) after we are done transforming, which looks like it triggers the issue.
I made the following change which seems to resolve the problem:
     public getLuaResult(): tstl.TranspileVirtualProjectResult {
         const program = this.getProgram();
         const collector = createEmitOutputCollector();
+
+        const preEmitDiagnostics = ts.getPreEmitDiagnostics(program);
+
         const { diagnostics: transpileDiagnostics } = new tstl.Transpiler({ emitHost: this.getEmitHost() }).emit({
             program,
             customTransformers: this.customTransformers,
            writeFile: collector.writeFile,
        });

         const diagnostics = ts.sortAndDeduplicateDiagnostics([
-            ...ts.getPreEmitDiagnostics(program),
+            ...preEmitDiagnostics,
             ...transpileDiagnostics,
         ]);

Seems like we are actually doing the same thing everywhere, so it might be an easy workaround for us to just swap some lines around. This does not strike me as intended/expected behavior from TypeScript side either, but at least we can work around it pretty easily for now.

Yeah, double checked with the team and it’s definitely not supposed to happen, though I don’t find it too surprising.
The call to getSymbolAtLocation from buildLinkParts in src/services/utilities.ts is the first thing in the stack that’s possibly suspicious. That call should never be able to trigger an error that getSemanticDiagnostics doesn’t also trigger. I think the checker should probably know based on the location that it shouldn’t trigger name resolution errors there. JSDoc @link tags can probably just be explicitly exempt from errors in resolveEntityName in checker.ts (@sandersn please correct me if that’s not right).
Why this only happens when the @link tag comes after another tag (not just @remarks, happens for any tag) is a total mystery to me.

I looked briefly at the code and

@link tags are checked the same regardless of whether they're inside a tag or just the top-level comment text.
They are explicitly exempt from errors in resolveEntityName in that code path, which is the one the compiler uses. The one where they're not obviously exempted is only used by the language service -- but editors don't seem to report those? At least I couldn't get them to in a simple test.

Seems like this is not just an API concern, this comes up in the language service in #50341

not working

Not sure if the same issue, but I get the same error message with just @see and @link (no @remarks):
https://typescripttolua.github.io/play/#code/PQKhCgAIUhlB7AtgU0gYySgdgFyhaSAAQGdlUBvIgGwEssBrSACxxwAcSAuYYAc1o5mAVwBGAOgyJgiWmgBO8EvABmOYABUAnu2SwFtdutokSw5CWAAWAJwBGAAw2AvvmDhkAD3bx5OSCrCWGg4tPBYkACyWgBiQSFhWAAUAJSQFK5AA
for some reason, it only shows once you start typing in the editor.

Did anyone find a workaround?

@Andarist recently fixed a few related bugs; I’m not sure if this got fixed as a side-effect.

If this is the same as #50341, which is very likely, then it's still broken as of 5.1 beta.


Intro: Fix mistake "as a teenager 1985"

I'm not a native English speaker, but I believe this a mistake:

to program [...] as a teenager 1985 and [...]

Corrected by adding "in".

Thanks!


[WG] proposal

Please take a look at proposed API endpoints (sheet `“[WG] Proposal"):
https://docs.google.com/spreadsheets/d/1kVIx6GvzVLwNYbcd-Fj8YUlPf4qGrWUlS35uaTnIAVg/edit#gid=1802603696
Feel free to comment here or in sheet if you have questions. I would like you to checkout "Oustanding questions" as well.
API endpoints that aren't being contested will be opened here in form of PR where further things like descriptions, validation, response codes etc will be discussed.
cc-ing interested parties @paulhauner @hwwhww @arnetheduck @mratsim @terencechain @prestonvanloon @AgeManning @wemeetagain @mkalinin @ajsutton @rolfyone @moles1 @skmgoldin

If somebody wants to help out with writing openapi spec for proposed endpoints, please contact me so we don't overlap

Thank you BN working group!!

I would like you to checkout "Oustanding questions" as well.

Yes, in particular please see the open questions. Much of the debate my lie in there.
Also, if there is a particular use case that is entirely not satisfied by this API or overly complicated, please document it here for discussion

I realize that we are coming very late to the party, since Nimbus has delayed introducing the beacon-node / validator-client split until now, but planning out our internal design revealed some questions regarding the API.
Within our codebase, we've tried to prepare for the split from the start by making all signing and RANDAO reveal operations asynchronous. But one key difference from the validator API is that we've assigned the responsibilities in a different way - for us, the beacon node decides what is the best time to produce a block or attestation and the validator client is called on-demand only to perform the operations that depend on the validator keys.
With the proposed APIs here, the validator client must keep track of time and it must determine the best moment to request attestations and blocks for signing, but this seems counter-productive for the goal of profit maximisation. As you may know, determining the optimal set of attestations to aggregate is a hard optimisation problem that the beacon node will be much better equipped to solve unless the validator client significantly increases in complexity.
So, I'm wondering, has this different split of responsibilities been considered? Are there any other requirements that conflict with it?
Admittedly, there are some obvious implications for the needed trust between the beacon node and the validator client, but it seems to me that the trust problem was never solved in a satisfying way and also that we must still provide the most optimal solution for validators who will be running their own beacon nodes (without the need to trust any third-parties).

As you mention, the largest piece of work here is attestation aggregation.  The API is designed to support both low-powered validators that may not have the resources to aggregate as well as high-powered validators that want to do the work themselves.
For low-powered validators they would GET /v1/validator/aggregate_attestation to fetch an aggregate attestation built by the beacon node.  For high-powered validators they would subscribe to the event stream for attestations and carry out their own aggregation.  For both, they would submit the aggregated attestation with a POST to /v1/validator/aggregate_and_proof
Timing is a more generic issue: waiting on proposing a block to potentially put more attestations in to it, for example, could result in more profit for the proposer, but does somewhat fly in the face of the spirit of the validator spec (if not the letter; see the section "Block proposal" for example where it states "A validator is expected to propose a SignedBeaconBlock at the beginning of any slot during which is_proposer(state, validator_index) returns True"; you could argue that "beginning" is a period of time rather than a point in time).  But no, the proposed API doesn't provide functionality for the beacon node to signal the validator client the time at which it should carry out a proposal.
All that said, it sounds like if you're combining the beacon node and validator in to a single process and separating the signing only, so it doesn't sound like the beacon node<->validator API would apply for this situation.  Or am I misunderstanding your architecture?

Yes, you are understanding our architecture correctly. The primary motivation for discussing this different split of responsibilities is that at least for us it leads to a significant reduction of code size and complexity of the validator process.

Chatted to @zah offline and I think this is where we ended up:

it would be nice if support of the /validator endpoints, although desired, wasn't mandatory (nimbus are looking to support these endpoints as long as they don't have a significant impact on their architecture, but are not yet sure if they can do so).  The clear grouping of endpoints can be an aid here
the signals that nimbus sends to tell the signer it is time to do some signing could be considered extensions of the proposed event stream mechanism.  Although we do not want to overburden the mandatory functionality to meet API conformance, having somewhere that such extensions could be recorded would be useful

@zah please correct me if the any of the above is incorrect.

We are committed to supporting the /validator endpoints. What is not completely certain is whether our "simpler" approach will remain and whether it will be recommended as a more robust solution potentially enhancing the profit maximisation algorithms of Nimbus.

has this different split of responsibilities been considered?

We did consider this in some detail. I can't quite remember the details, however the one that stands out is to allow VCs to switch between BNs. If you having timing logic inside the VC then it can determine if the BN is actually doing it's job or not.
If the VC requires the BN to call it, then, in the most naive implementation, if the BN goes down then the VC just sits there doing nothing instead of logging errors or perhaps switching to another BN. Ofc, you can get around this by implementing some logic in the VC to figure out whether or not it's been prodded in a while.. But this is timing logic and when implemented in its entirety roughly ends up replicating the timing logic you implemented in the BN.

determining the optimal set of attestations to aggregate is a hard optimisation problem

I agree. This logic is done in the BN for us.

cc @rauljordan.
At @prysmaticlabs, we are generally not in favor of any duck typing or otherwise ambiguous object unique identifiers.

cc @rauljordan.
At @prysmaticlabs, we are generally not in favor of any duck typing or otherwise ambiguous object unique identifiers.

There is only duck typing between slot and root, but you can always identify root by "0x" prefix so I don't think anyone should have problem coding that in any language though.

There is only duck typing between slot and root, but you can always identify root by "0x" prefix so I don't think anyone should have problem coding that in any language though.

This isn't a question of whether or not we could implement it this way, but whether we ought to implement it this way.
There are 5 different ways to handle a blockId in the current proposal.
"path:blockId" "head"" | ""genesis"" | ""finalized"" | <slot> | <blockRoot>"

While there are only 5 different ways to interpret request data, there are likely more that could be added which would then increase the burden on maintainers.
We would advocate for a more lean, clear, and simple API which doesn't set precedent for more ambiguity. BlockId should have a single, clear interpretation.

BlockId should have a single, clear interpretation.

@prestonvanloon  If we go for a single representation I think we have three options:

pick a single canonical ID, drop the rest
create more endpoints for the separate IDs
have no canonical ID, use query parameters

The first option would reduce functionality, so I'd assume that either 2) or 3) would be the available choices.  Which of these are you considering, or are you thinking of something else?

There are 5 different ways to handle a blockId in the current proposal.
"path:blockId" "head"" | ""genesis"" | ""finalized"" | <slot> | <blockRoot>"

I would argue that head, genesis, finalized arent params they are separate endpoints. Sortof like popular /users/me endpoint

@mcdee I believe the original proposal from @djrtwo and @protolambda had solved this.
Here are a few scenarios I can think of:
Retrieve head, finalized, previous justified, current justified block
GET /beacon/forkchoice/head
{
  "head_block_root": "...",
  "finalized_block_root": "...",
  "previous_justified_block_root" :"...",
  "current_justified_block_root": "..."
}

Now I have the required information to request the particular block by root.
Retrieve block by slot
Given that there may exist multiple blocks per slot in the event of a fork, we could use something like
_GET /v1/beacon/block_root?slot={slot} or _GET /v1/beacon/block_root/{slot}
This would return an array of block roots or block root objects with a "canonical" property, which then can be used to access the single retrieve method.
GET /v1/beacon/blocks/{block_root}
@mpetrunic

I would argue that head, genesis, finalized arent params they are separate endpoints. Sortof like popular /users/me endpoint

This is basically my point. This proposal is asking implementation teams to add and maintain multiple endpoints/routes which could be solved by one or two.

@prestonvanloon

GET /beacon/forkchoice/head

How would you get forkchoice for some past state? /beacon/forkchoice/<stateRoot>?

Now I have the required information to request the particular block by root.

 Whole point of rest api is to have some conventions how data is represented and make it easy to obtain it. I bet even eth2 developers are using fetch by slot to investigate whats going on.

This is basically my point. This proposal is asking implementation teams to add and maintain multiple endpoints/routes which could be solved by one or two.

I hardly think this is issue here. I doubt it takes more than an hour to create those alias endpoints and it will make API a lot more user friendlier for new users/developers to interact with...

How would you get forkchoice for some past state?

Get that state and look.

state.previous_justified_checkpoint.root
state.current_justified_checkpoint.root
state.finalized_checkpoint.root
state.block_roots[state.slot%SLOTS_PER_HISTORICAL_ROOT]

While the last point may not capture the nodes view at the time that state was created, I don't think anyone is advocating for historical forkchoice data so it should be adequate information.

 Whole point of rest api is to have some conventions how data is represented and make it easy to obtain it. I bet even eth2 developers are using fetch by slot to investigate whats going on.

Do we expect to support users that don't or won't read documentation?

I hardly think this is issue here. I doubt it takes more than an hour to create those alias endpoints and it will make API a lot more user friendlier for new users/developers to interact with...

While it might only take an hour to create, an implementation team then has to support and maintain it.
How many convenience methods do allow when the use cases already available with a minimal API?

Regarding about the complexity of "head" | "genesis" | "finalized" | "justified" | <slot> <stateRoot>. As others have suggested, I think we can view each of these tags as an alias for a root: once we've resolved the alias all queries are just targeting a state root.
To help myself think through it, I sketched out the flow for a /v1/beacon/states endpoint (hopefully the match statement is easy enough to interpret):
fn resolve_alias(alias: &str) -> Hash256 {
  let state_root = match alias {
    "head" => get_head_state_root(),
    "genesis" => get_genesis_state_root(),
    "finalized" => get_finalized_state_root(),
    "justified" => get_justified_state_root(),
    other => {
      if other.starts_with("0x") {
        other
      } else {
        get_state_by_slot(other)
      }
    }
  }
}

So we have:

get_head_state_root(): pretty simple, would probably need this in any case.
get_genesis_state_root(): we already store genesis block root on our BeaconChain, could just add the state root too.
get_finalized_state_root(): a bit funkier, have sketched it below.
get_justified_state_root(): also a bit funky, probably the same as the finalized case though.
get_state_by_slot(): pretty straight forward, we already have this functionality. I suspect other clients would too.

fn get_finalized_state_root() -> Hash256 {
  // State reads are costly, hopefully clients can optimize around this.
  let head_state = get_state(get_head_state_root());
  // There's potentially extra state reads in finality > state.state_roots.len()
  head_state.get_state_root(start_slot(head_state.finalized_checkpoint.epoch));
}

This doesn't seem like a massive burden to me, but perhaps I'm missing something. So, I guess we have pros/cons of alias:
Pros:

Easier for users to figure out how to get things that have an alias.
Less API calls for users who want an aliased thing.

Cons:

More work to maintain.

I don't feel super strongly about the aliases, I don't consider them a huge burden. However, if I was designing this I would:

Drop the genesis alias since it's exactly equivalent to slot = 0 (assuming no one has a non-zero genesis slot, out-of-scope IMO).

That being said, an alias that's exactly equivalent to some other thing is basically no maintenance burden so I could 100% take it or leave it here.

Drop the justified alias since I don't think users will frequently care about justification. Those that do can deal with an extra call to head first. If it turns out to be super useful, we add it later.

In summary, this API looks fine to me (thanks to those who put the effort in to produce it). I don't see aliases as a large maintenance overhead, but I also don't feel super strongly about keeping them either. I'm happy to follow the crowd here. If you want a firm statement from me I can do it, but I suspect another chef in the kitchen isn't necessarily helpful.

@paulhauner I would just mention that justified/finalized state roots are present in forkchoice which could be option to avoid expensive state reads^^

There is a No duck typing tab at the end of tab list in the document. It's an example of beacon chain data endpoints with strict object identifiers. In some cases it will result in an extra round-trip to request the same data comparing to the "duck typing" approach.
The other concern regarding "duck typing" endpoints is that HTTP caching policy will have to be set depending on the request parameters. For example:

/v1/beacon/blocks/head -- MUST NOT be cached
/v1/beacon/blocks/slot -- MUST NOT be cached
/v1/beacon/blocks/genesis -- MAY be cached
/v1/beacon/blocks/{blockRoot} -- MAY be cached

Drop the genesis alias since it's exactly equivalent to slot = 0

Not to derail the duck typing debate, but this bring to mind another question: what are we asking for when we want the state at slot x?  We could be asking for the state at the start of slot x or the end of slot x?
There are arguments for both, of course, but we should pick one, as it has implications.  For example, Paul's statement that I quoted above only holds true if we use "start of slot".  I think that "end of slot" (or epoch) is the more intuitive, but if there are any strong arguments for "start of slot" it would be worth hearing them.

Not to derail the duck typing debate, but this bring to mind another question: what are we asking for when we want the state at slot x? We could be asking for the state at the start of slot x or the end of slot x?

I would expect state where state.slot equal to requested slot.

Having genesis alias is nice because when phase1 rolls in the shard chain's genesis slot will most likely not be starting at slot 0. Just my 2c

Hi @paulhauner we absolutely need the genesis alias because otherwise we have no way of differentiating a request that wants slot = 0 or a request that didn't pass in the slot query param at all in Golang

Having genesis alias is nice because when phase1 rolls in the shard chain's genesis slot will most likely not be starting at slot 0. Just my 2c

Makes sense, I didn't consider that :)

Hi @paulhauner we absolutely need the genesis alias because otherwise we have no way of differentiating a request that wants slot = 0 or a request that didn't pass in the slot query param at all in Golang

I'm happy for genesis to stay but I would be hesitant to shape the API under the assumption that servers are unable to determine if a value is uninitialized or set to whatever their default value is.
We have validators and committees identified by 0, would they also need an alias?

We could be asking for the state at the start of slot x or the end of slot x?

I would define it as block_at_slot(slot).state_root, where block_at_slot(slot).slot == slot and block_at_slot(slot) is always in the canonical chain.
It's not clear to me what a "state at the start of slot x" is. Right before you process a block you advance the pre-state to the current slot, but this is inside state_transition so I'd say it's an intermediate value that has no value to the user. We don't even store that state, I would be surprised if other clients do.
Regarding epoch queries, I would advocate for using compute_start_slot_at_epoch since there's already a precedence that state.finalized_checkpoint.epoch refers to the first slot in the epoch.

I've commented on the spreadsheet, but i'll reiterate here:
/v1/beacon/blocks/{blockId} - it would be nice to have the block root at the top level also: its currently offered by lighthouse and prysm, and there's a PR in against teku because it simplifies debugging
/v1/validator/attestation_data
/v1/validator/aggregate_attestation
/v1/validator/blocks/{slot}
in the spreadsheet at least, they seem to be the only endpoints not wrapping their response object with 'data'. I actually prefer not having the wrapping object, but either way, we should probably be consistent unless there's a really good reason?

The state-id format is still painful, and I think splitting it into multiple routes is not a bad idea. Here's a proposal:
In paths
I understand that having extra routes is not pretty, but essential for some tech stacks (Go with GRPC versions of API in particular), so I would go for the following compromise: we spec state ID as "state ID path segment". Every time we would use a state ID in a path, we can have the path segment consist of multiple segments, the first always being a string. The same applies for other options that end up in the path as required argument with different types.
If you want to cover all options in one API handler really badly (JS and python can likely do something like that elegantly), you can, by just matching multiple routes together.
Take state ID as example:
stateId can be any of:

state_root/{hex string}
slot/{slot decimal number}
head
genesis
finalized
justified

E.g. when we spec /v1/beacon/states/{stateId}/committees/{epoch}, it can be:

/v1/beacon/states/state_root/0xabc123def...45deadbeef/committees/{epoch}
/v1/beacon/states/head/committees/{epoch}

ExpressJS and more advanced routers support matching multiple patterns for the same endpoint, and then store the path params in a special dictionary anyway, so there's no problem with typed arguments or default values there, regardless of approach.
This way languages that would want to type the root, slot, validator index, etc. can do so, by simply routing them to a different endpoint. Meanwhile, the spec stays clean, and the other languages can code-golf the API definition to be more minimal all they want.
Also, this solves the http caching problem, since the /head path is now nice and distinct from others, making cache configuration easier.
In queries
Right now the API proposal has no case of a mixed input type in a single query param. If a param can have two types (e.g. a block root and a slot), then it should be part of the path. If the two types are not exclusive, then there should have been two separate query params.

It seems to me that it's expected that validators have to query the beacon nodes for the current fork version in order to perform the signing of blocks for example - in addition to requesting blocks to sign - isn't that a potential for race conditions if there is a change of fork? Perhaps /v1/validator/blocks/{slot} which returns { block: BeaconBlock } should return the fork as well. Maybe such concerns apply to other parts of the API as well.
genesis_validators_root should be unaffected because it should never change, correct? It's basically going to be set in stone... forever - after Eth 2.0 is launched...?

@onqtam the fork schedule is published through the configuration so clients will know in advance when forks are scheduled to occur.
And yes, genesis_validators_root will be constant once the chain has launched.

so are we representing byte data in hexadecimal? I thought we were using base64 encoding?

cc @rauljordan.
At @prysmaticlabs, we are generally not in favor of any duck typing or otherwise ambiguous object unique identifiers.

There is only duck typing between slot and root, but you can always identify root by "0x" prefix so I don't think anyone should have problem coding that in any language though.

Can I assume that there is the same duck typing for <publicKey> | <index> for /v1/beacon/states/{stateId}/validators/{validatorId}?

There is only duck typing between slot and root, but you can always identify root by "0x" prefix so I don't think anyone should have problem coding that in any language though.

@mpetrunic Can I assume that there is the same duck typing for <publicKey> | <index> for /v1/beacon/states/{stateId}/validators/{validatorId} - meaning that I can use 0x as a prefix to distinguish between those two?

yes. I should probably update spec to make it clear here: https://ethereum.github.io/eth2.0-APIs/#/Beacon/getStateValidator
as I did on state_id param


Dubbo spring cloud dynamic service discovery

Fix dubbo spring cloud dynamic service discovery. refer these issues:
https://github.com/alibaba/spring-cloud-alibaba/issues/753, https://github.com/alibaba/spring-cloud-alibaba/issues/770, https://github.com/alibaba/spring-cloud-alibaba/issues/695
@mercyblitz pls review it.

Yes, thank you, I will pay attention to it.


schema is only validation? can we account for coercion too?

It'd be nice to be able to use zod coercion to turn yaml ISO date strings into JS Date objects.
z.string().pipe(z.coerce.date())

z.string().transform((value) => new Date(value))

but these end up creating typeerrors:

You can use coerce or transform, but the output must be a valid JSON object since content collections store documents as JSON files. There is an existing issue addressing the problem with the date (#29).


Change default command for launching minio

Was not working for us: we had to change it like so

Hi, I tried to use web gui of gitlab and have vandalized your branch  . sorry
also it seems update in minio path catched from other pull request. Could you please recheck.
sorry for inconvenience, thanks for help

@oprudkyi Should be good now.
Better later than never right? 😆


Moved Collection to top level namespace

Updated settings to use Collection instead of a raw array
This PR should solve #1563

Moving Collection will make splitting out Slim\Http to its own rep slightly harder later. Not insurmountable, though.


Feat/workflow rename

Requires ansys-dpf-gate newest version

Closing this PR as stale, reopen if necessary


Extracting teacher weights from the final checkpoint

Hi,
I have trained DINOv2 / ViT-S on some custom data. Now I am trying to use the final model checkpoint (model_final.rank_0.pth) to extract teacher backbone weights:
pretrained_weights = 'checkpoints/model_final.rank_0.pth'
state_dict = torch.load(pretrained_weights, map_location="cpu")

# select the model key
state_dict = state_dict['model']
# only teacher backbone keys
state_dict = {key: value for key, value in state_dict.items() if 'teacher.backbone' in key}
# remove 'teacher.backbone.'
state_dict = {k.replace("teacher.backbone.", ""): v for k, v in state_dict.items()}

# load ViT-S
from dinov2.models import vits
model = vits.vit_small(patch_size=16)
# load state_dict into the model
model.load_state_dict(state_dict)

However, this fails due to the key mismatch:
RuntimeError: Error(s) in loading state_dict for DinoVisionTransformer:
	Missing key(s) in state_dict: "blocks.0.0.norm1.weight", "blocks.0.0.norm1.bias", "blocks.0.0.attn.qkv.weight", ...
Unexpected key(s) in state_dict: "blocks.1.norm1.weight", "blocks.1.norm1.bias", "blocks.1.attn.qkv.weight", ...

When going through the state_dict keys, I do find 'blocks.0.norm1.weight' but not 'blocks.0.0.norm1.weight' which DinoVisionTransformer expects.
I am not sure what I am missing. Thank you in advance.

It is easier to use the teacher_checkpoint.pth file inside the evaluation folder for your job; can you try it ?

@qasfb Thank you for the fast reply. It doesn't work unfortunately and I still get the _IncompatibleKeys exception. I've tried the following:
pretrained_weights = 'eval/training_437499/teacher_checkpoint.pth'
state_dict = torch.load(pretrained_weights, map_location="cpu")
state_dict = state_dict['teacher']

# only the backbone keys
state_dict = {key: value for key, value in state_dict.items() if 'backbone' in key}
# remove 'teacher.backbone.'
state_dict = {k.replace("backbone.", ""): v for k, v in state_dict.items()}

model = vits.vit_small(patch_size=16)
# load state_dict into the model
model.load_state_dict(state_dict)

By the way, somehow the checkpoint of the very last iteration (440,800) wasn't saved even though the training ran through.

Can you init your model with your config using this function ?
https://github.com/facebookresearch/dinov2/blob/main/dinov2/models/__init__.py#L39
Essentially there is a "block_chunks" parameter involved there that needs to be passed to the model if you load it.
Otherwise you can work on the names in the state_dict; they have the form:
blocks.blockchunkidx.layeridx.***

@qasfb Thanks. I added the block_chunks=0 argument and now I only have some unexpected keys in the state_dict:
RuntimeError: Error(s) in loading state_dict for DinoVisionTransformer:
Unexpected key(s) in state_dict: "blocks.0.ls1.gamma", "blocks.0.ls2.gamma", "blocks.1.ls1.gamma", ...

They are all of type ls1.gamma and ls2.gamma. Am I missing an argument to the model?

yes, you can put init_values=1, that activates the layerscale layers

You can also simply rerun your training command (if you use dinov2/train/train.py) with --eval_only flag. That will create a teacher_checkpoint.pth from a very last iteration of your training in case it wasn't saved in training time.


Macro to timeout operations that take too long

Hi!
On my Genie app, there are some cases where, if the user inputs unphysical conditions, the solvers will get stuck / take a long time to output an unreasonable result. As such, it would be great to have some sort of macro that will only allow a task to only run for a certain amount of time. There was an example here: https://discourse.julialang.org/t/simple-timeout-of-function/99578/3
The macro they propose looks like this:
macro timeout(seconds, expr_to_run, expr_when_fails="Timed out")
    quote
        tsk = @task $(esc(expr_to_run))
        schedule(tsk)
        Timer($(esc(seconds))) do timer
            istaskdone(tsk) || Base.throwto(tsk, InterruptException())
        end
        try
            fetch(tsk)
        catch _
            $(esc(expr_when_fails))
        end
    end
end

However, I've found that this macro doesn't work for my cases. Here is an MWE (you'll need to install Clapeyron):
using Clapeyron

model = PCSAFT(["water", "carbon dioxide"])

@time bubble_pressure(model,298.15,[0.9,0.1])
# After first compilation, this should take about 0.8s

@timeout 0.01 bubble_pressure(model,298.15,[0.9,0.1])
# Doesn't timeout

Not sure what you are doing in Clapeyron. (Typically for an MWE (MINIMAL workable example) you don't need to install a foreign dependency.)
But the following MWE does work as expected:
@app MyApp begin
    @in a = 12
end

function f(model)
    println("before $(model.a[])")
    sleep(1)
    println("after $(model.a[])")
end

then
julia> model = @init MyApp;
julia> @timeout 2 f(model)
before 12
after 12

julia> @timeout  0.2 f(model)
before 12
"Timed out"

My apologies for not being clearer. I can get it to work for simple examples like the one you've shown. However, once calls to module functions are used, like bubble_pressure, I noticed that @timeout wouldn't actually timeout. In my case, I used Clapeyron since that's the package I'm trying to timeout in Genie. However, I've found this isn't unique to Clapeyron as even 'simple' packages like Roots.jl also don't timeout when they should. For example:
f(x) = exp(-x^2)-sin(x)

@time fzeros(f,-10000,10000);
#  0.074126 seconds (1.39 M allocations: 38.786 MiB, 3.51% gc time)

@timeout 1e-4 fzeros(f,-10000,10000) # Doesn't timeout

Any idea why that would be?

I could reproduce that and still don't know why. Interestingly, it works if you keep the wrapping @time macro
julia> @timeout 0.02 @time(fzeros(f,-10000,10000))
  0.074842 seconds (1.38 M allocations: 38.043 MiB, 5.59% gc time)
"Timed out"

Really weird... Although in the above, it still computed the function and then timed-out. So it didn't do its job...


Enhance VerifiedDoubles cop

This replaces #87 which was accidentally closed.

@andyw8 do we want IgnoreSymbolicName be true by default?

@nijikon I believe so, for the reasons mentioned by @CJBridges in #35 and #36.

I'll be using the option, but I suggest defaulting it to "false" so the cop defaults to its strongest state and behaves obviously.  The rule with its subtleties can be turned on intentionally.

Ok, I've updated the PR to remove that default.

@andyw8 please rebase on top of master

I'll do this after #85 is merged, otherwise I think one of these will end up conflicted again.

@andyw8 done, rebase please

@nijikon rebased.


[AIRFLOW-1164] No example connections if load_examples is False

Dear Airflow maintainers,
Please accept this PR. I understand that it will not be reviewed until I have checked off all the steps below!
JIRA

[X] My PR addresses the following Airflow JIRA issues and references them in the PR title.

https://issues.apache.org/jira/browse/AIRFLOW-1164

Description

[X] Here are some details about my PR, including screenshots of any UI changes:
If core/load_examples is set to false, the example connections are not added to the database when calling airflow initdb

Tests

[X] My PR adds the following unit tests OR does not need testing for this extremely good reason:

Commits

[X] My commits all reference JIRA issues in their subject lines, and I have squashed multiple commits if they address the same issue. In addition, my commits follow the guidelines from "How to write a good git commit message":

Subject is separated from body by a blank line
Subject is limited to 50 characters
Subject does not end with a period
Subject uses the imperative mood ("add", not "adding")
Body wraps at 72 characters
Body explains "what" and "why", not "how"

Codecov Report

Merging #2266 into master will increase coverage by 0.01%.
The diff coverage is 100%.

@@            Coverage Diff             @@
##           master    #2266      +/-   ##
==========================================
+ Coverage   68.91%   68.93%   +0.01%
==========================================
  Files         142      142
  Lines       10975    10982       +7
==========================================
+ Hits         7563     7570       +7
  Misses       3412     3412

Impacted Files
Coverage Δ

airflow/utils/db.py
96.87% <100%> (+0.18%)
:arrow_up:

Continue to review full report at Codecov.

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

Any update on this pull request? Do you guys have any remarks?

@bolkedebruin is this something which could be merged? if you i'll resolve the conflicts

(Not a core contributor)
This possibly already exists in the form of the airflow upgradedb command that will just apply the migrations, but won't create any of the sample connections or reports.

@ashb we're running a docker container which always calls airflow initdb.
Having set load_examples to False we expected the example_connections to also not be loaded. As the documentation says:
Whether to load the examples that ship with Airflow. It's good to
get started, but you probably want to set this to False in a production
environment

@NielsZeilemaker Possibly this change makes sense, or possible the docs (and the docker image) should be updated to say "use upgradedb in production).


refactore update and observe resource

Codecov Report

Merging #14 into master will increase coverage by 1.32%.
The diff coverage is 66.66%.

@@            Coverage Diff             @@
##           master      #14      +/-   ##
==========================================
+ Coverage   48.82%   50.15%   +1.32%
==========================================
  Files          14       14
  Lines         680      658      -22
==========================================
- Hits          332      330       -2
+ Misses        287      271      -16
+ Partials       61       57       -4

Impacted Files
Coverage Δ

local/observeResource.go
0% <0%> (ø)
:arrow_up:

local/getResource.go
77.77% <100%> (+20.63%)
:arrow_up:

local/updateResource.go
77.77% <100%> (+39.68%)
:arrow_up:

Continue to review full report at Codecov.

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


Databricks Workspace Service Install Fails with PutSubnetOperation CanceledAndSupersededDueToAnotherOperation

When deploying the Databricks Workspace service get:
2) Main step for ff51fffc-c2c1-4dfe-a88e-e70766f5bc3c
ff51fffc-c2c1-4dfe-a88e-e70766f5bc3c: Error message: ╷ │ Error: waiting for creation of Subnet: (Name "adb-host-subnet-mrtredemo24-ws-5740-svc-bc3c" / Virtual Network Name "vnet-mrtredemo24-ws-5740" / Resource Group "rg-mrtredemo24-ws-5740"): Code="Canceled" Message="Operation was canceled." Details=[{"code":"CanceledAndSupersededDueToAnotherOperation","message":"Operation PutSubnetOperation (a3d81bf2-68dd-4a93-93bb-3f3ad92059d9) was canceled and superseded by operation PutVirtualNetworkOperation (cc8eb20b-2242-4ae7-a1c2-1e74bbda5bfd)."}] │  │  with azurerm_subnet.host, │  on network.tf line 90, in resource "azurerm_subnet" "host": │  90: resource "azurerm_subnet" "host" { │  ╵ error running command /cnab/app/terraform

@guybartal seen this before?

no, I haven't. looks like it fails on creating the public (host) subnet,
maybe a transient error? did you try to redeploy?

Got this again here:
1f350b8a-736f-4ff8-9a5c-ca3bbc8c459a: Error message: ╷ │ Error: waiting for creation of Subnet: (Name "adb-host-subnet-mrtredemo28-ws-8044-svc-459a" / Virtual Network Name "vnet-mrtredemo28-ws-8044" / Resource Group "rg-mrtredemo28-ws-8044"): Code="Canceled" Message="Operation was canceled." Details=[{"code":"CanceledAndSupersededDueToAnotherOperation","message":"Operation PutSubnetOperation (f0dd77c7-05fd-4208-aa55-f62650568667) was canceled and superseded by operation PutVirtualNetworkOperation (b5f36438-7876-4e51-8e3a-36fc10f79daf)."}] │  │  with azurerm_subnet.host, │  on network.tf line 90, in resource "azurerm_subnet" "host": │  90: resource "azurerm_subnet" "host" { │  ╵ ╷ │ Error: Subnet: (Name "adb-container-subnet-mrtredemo28-ws-8044-svc-459a" / Virtual Network Name "vnet-mrtredemo28-ws-8044" / Resource Group "rg-mrtredemo28-ws-8044") was not found │  │  with azurerm_subnet_network_security_group_association.container, │  on network.tf line 147, in resource "azurerm_subnet_network_security_group_association" "container": │  147: resource "azurerm_subnet_network_security_group_association" "container" { │  ╵ ╷ │ Error: Subnet "adb-container-subnet-mrtredemo28-ws-8044-svc-459a" (Virtual Network "vnet-mrtredemo28-ws-8044" / Resource Group "rg-mrtredemo28-ws-8044") was not found! │  │  with azurerm_subnet_route_table_association.rt_container, │  on network.tf line 157, in resource "azurerm_subnet_route_table_association" "rt_container": │  157: resource "azurerm_subnet_route_table_association" "rt_container" { │  ╵ error running command /cnab/app/terraform /usr/bin/terraform apply -auto-approve -input=false -var address_space=<IP_ADDRESS>/24 -var arm_environment=public -var is_exposed_externally=false -var tre_id=mrtredemo28 -var tre_resource_id=1f350b8a-736f-4ff8-9a5c-ca3bbc8c459a -var workspace_id=14d01527-62d1-4bad-99ad-37d602c08044: exit status 1 Error: error running command /cnab/app/terraform /usr/bin/terraform apply -auto-approve -input=false -var address_space=<IP_ADDRESS>/24 -var arm_environment=public -var is_exposed_externally=false -var tre_id=mrtredemo28 -var tre_resource_id=1f350b8a-736f-4ff8-9a5c-ca3bbc8c459a -var workspace_id=14d01527-62d1-4bad-99ad-37d602c08044: exit status 1 1 error occurred: * mixin execution failed: package command failed

Issue seems to be related to multiple workspace services being deployed/updated in parallel.

Ok, this is down to having two operations in progress on the virtual network. On the virtual network. This can happen if one is adding an address space to a workspace in one operation, when another is adding a subnet to the virtual network at the same time.
We need to limit workspace and workspace service operations to one at a time for each workspace.
As user resources to not typically modify the network, do not believe they are an issue.


add ac unification for maps with at most one map variable

summary: add AC unification for maps when both the subject and the pattern consist of multiple entries and at most one map variable. The algorithm combines the entries in all possible ways, and the some of the combinations may become unsatisfiable later in the simplification process. To enable AC unification, the conversion to map lookups it turned off. The --ac-unification flag must be passed to both kompile and kun.
test plan: breakpoint to check that the 13 solutions are correct for the test file

@andreistefanescu I have added a few things.
First, a hook in MetaK which exposes a #unify function, which returns a BuiltinSet of unifiers (with each unifier represented as a BuiltinMap).
I have also added a directory k-distribution/tests/unification, with a simple testing harness (written in bash). Not sure how to integrate it into the existing testing framework, but I've included the K file, the "program" input (a bunch of unification problems), as well as the expected output. You can run ./test.sh to run the single basic.test test.
I would like you to look over my code for the function unify in MetaK, which exposes the unification to the user. One problem I think it has is that it does not use the FastRuleMatcher codepath, which means that your Map unification code may not be present there. Perhaps it should be adapted to use the FastRuleMatcher code.
The reason for exposing a function to the user and specifying the tests at the K level is so that we can re-use these tests on the K-Haskell backend. It's also easier to write them this way than as a bunch of K proofs (which could have other things going wrong with them instead of just having problems with the unification).

@andreistefanescu I've also exposed the matchable function to the user. Could you please review? I need this functionality for SBC.

Closing. Reopen if it's still required.


custom versioning strategy

I've been messing around with the gradle release plugin for a while now and I'm trying to customise how to determine the version and tag.
I quite like the opinionated configuration but I wanted to make a few tweaks but there aren't enough examples around that make it clear what to do.
What I've been trying to implement is something like the following:

set the default versioning to increment on minor value instead of patch value.
if there are uncommitted changes then do not apply a tag (works by default) and do not allow publishing to artifactory (works in a hacky way)

I've not yet managed to find the option to do 1, and option 2 relies on some clumsy code like this:
artifactory {
    if (grgit.status().clean) {
        // publish to artifactory
    } else {
        logger.error("There appear to be uncommitted changed in the workspace! Aborting")
    }
}

I will accept if 2 is outside the scope of what the gradle release plugin can help me with.
Any tips for me?

For 1, there's not a simple property to set, but it is configurable. Take a look at how DEFAULT is configured, particularly the normalStrategy, which you'd want to modify to end with Normal.useScope(ChangeScope.MINOR) instead of PATCH.
For 2, it's slightly outside the scope, but I think you can do this with the onlyIf method on all Gradle tasks.
artifactory { // presuming this is the task name
  // skip the task if there are any uncommitted changes
  onlyIf { grgit.status().clean }
}

Thanks @ajoberstar. I got the second part working fairly simply with
artifactoryPublish.onlyIf { grgit.status().clean }
But I'm still fumbling around to solve the versioning issue. Basically I want to add my own custom versioning strategy, right? Do you have an example about how to do that? The only one I found is this which looks pretty interesting but I want to start with something more simple first.

Netflix's Nebula plugins are another example of this. See:

NetflixOssStrategies
ReleasePlugin


cuelang.org: add Rust usage guide

@4ad content-related issues live in https://github.com/cue-lang/docs-and-content/issues please.


[BUG] BridgedUSDT has broken Icon on the MyBots page

Also this one: Arbitrum DAI

Fixed with https://github.com/VolumeFi/bot-info-api/pull/105


Added .norainbow command

Please I beg you, even if Kurisu is going to be updated, just this one thing...

that's not how you remove it from a string.

No escape from rainbows

Rip


Unable to change font in SearchView

I've tried via XML or programmatically.
Is it ok thing?

I can't say I have tried the search view. But generally if it doesn't inflate it's TextViews it makes it difficult to hook into, not sure if anyone else on here knows about it.