MultiplayerSynchronizer doesn't update Texture property

Godot version
4.0 official
System information
SolusOS
Issue description
When setting up the MultiplayerSynchronizer to update TextureRect:Texture or Sprite2D:Texture it fails and may even cause issues.
When testing with two MultiplayerSynchronizers, one for a Label:text and one for a TextureRect:Texture it overwrote the settings IN THE EDITOR that was veeeery weird, I'm going to report this in another issue. You can see the tests in the video below:
https://youtu.be/JOtoQWPdjRU
Steps to reproduce

Setup a server/client using ENetMultiplayerPeer
Create a scene that is dynamically spawned across peers using the MultiplayerSpawner
When spawning the above scene, change its texture
Make sure the above scene has a MultiplayerSynchronizer trying to sync the "Texture" property

It's complex, but that's the gist of it.
Minimal reproduction project

Toggle at least 2 Debug Instances in the Debug Menu
Open the 03.making-lobby-to-gather-players/MainMenu.tscn scene
On one instance, press the "Server" button
On another instance, press the "Client" button
Look at the Server instance as it has a scene with a different texture than the Client instance
Look at the Client instance and notice it has none or the default texture

multiplayer-synchronizer-bug.zip

I don't know the details but I'm not sure the multiplier system sends texture data like that, it can't just figure out that you loaded the file, but I might be mistaken

I don't know the details but I'm not sure the multiplier system can be expected to send texture data like that, it can't just figure out that you loaded the file, but I might be mistaken

Maybe we could filter the properties selection then to only allow "passable" properties?

I don't know if it's intended, a bug, or a limitation, I'd defer to someone more knowledgeable with the internals of multiplayer, just guessed on a possible reason

Cc @Faless maybe

Are there any errors or warnings in the debugger?

Are there any errors or warnings in the debugger?

No errors on the debugger, no :/

Synchronizing "object type properties" (like resources and node references) is indeed not supported, we should add an error or warning in the debugger (and possibly the editor) to clarify that.
A texture is also pretty big in the context of network packet size, so you should not use a synchronizer anyway (even if it was supported, the "sync" would have thrown an error about the packet size and dropped the state).
Using an RPC to send the texture data (get_image().get_data()) might work assuming the avatar is small enough (e.g. 64x64) but keep in mind the Multiplayer API is not suited to transfer assets, which should be done using dedicated protocols like HTTP instead.

Yes digging through the code I noticed the error and was confused at first why it didn't show up but I assume it's because the property is just encoded as an object id and not as actual data

Part of this seems to come from that MultiplayerAPI overwrites encoding flags, causing it to fail to decode objects correctly but I'm not sure will look closer

Looking at some ideas for documenting and fixing this

Looking at some ideas for documenting and fixing this

I think we should see if we can test the properties of a given node in the editor (like we do with the type to show the icon) and add a warning sign for that property if it's of type Variant::OBJECT.
We could possibly also go the hardcore route and add a test_replication_config to MultiplayerSynchronizer which  test the encoding for encoded objects and we only call in tool builds. Though this seems a bit to much for me and I'd lean towards the editor-only solution (which I known, still leave the issue for not @exported variables in scripts).
Maybe though there's a third and better way?

Part of the solution would be to restrict the types in the property selector in the editor, but yeah keeping the silent failure doesn't seem like too big a problem.
Also Variant::RID should probably be excluded as well at least in the editor.
Will look at some ideas for editor-only checks, but maybe I'll just start by adding a basic editor-only solution restricting the types that can be selected and adding to documentation? Got some basic things working already.

My working approach for the moment:

Restrict properties in the editor picker, preventing accidentally picking the wrong types
Add to documentation

To investigate:

Checking properties in the editor and warning on unsupported types
Warn on types that are not guaranteed to work (like arrays and dictionaries), not sure about this one

Alright, thanks a lot for the fast replies and clarifications! @AThousandShips the current approach sounds good. Hiding properties that can't be synced would be ideal. Maybe filtering anything that inherits from Object could work.
Could you guys help me with a workaround for that? I'm thinking about turning the add_avatar() method into an @rpc function so clients create their own AvatarCard based on data provided to the server from other clients.
It's not necessary to pass the whole Texture through the network as each client will have all the files necessary to build other players' avatars. They just need the instructions.

PR open #74443

Why not sync the path of the texture? That way we just pass a string over the network instead of a texture.

Because a texture isn't guaranteed to have a path, this shouldn't be done automatically
Further this kind of property isn't really something that makes sense being synced like this, it'd be better to use RPC to send that information to a dedicated function that loads the texture

I am working on a multiplayer project in which I am dynamically adjusting hitboxes (RectangleShape2D), and I want to sync this data across every client. This didn't appear to be working, at which point I stumbled across this thread. I wouldn't expect a shape's size (2 floats) to be too much data to sync, so I'm curious about why this isn't feasible.
Is the only way to achieve this behaviour just updating the shapes directly with an RPC?

It isn't about the size, it's about the type, a shape isn't simple data, it's a resource, can you try syncing the actual property on the shape instead of the shape itself?
Otherwise you should use an RPC, resources are shared so they are unlikely to be efficient in synchronizing, and objects can't be synchronized because they're not simple data, like a Vector2, they are a whole object that has references etc.

I see, to clarify I was attempting to sync the size property on the shape of a CollisionShape2D:

disabled and position sync properly without errors, but I get the following error when attempting to sync the shape's size:
E 0:00:03:0082   get_state: Property 'Hitbox/CollisionShape2D:shape:size' not found.
  <C++ Error>    Condition "!valid" is true. Returning: ERR_INVALID_DATA
  <C++ Source>   modules/multiplayer/multiplayer_synchronizer.cpp:162 @ get_state()

I validated that this is the correct path, and even compared to the path stored in an Animation player which modifies this same property (Hitbox/CollisionShape2D:shape:size) successfully.

This is a different issue than the OP.
The problem is that CollisionShape2D is a "fake" node, that doesn't exists at runtime, which is why it doesn't work.
I expect the same to happen when trying to modify it with an animation player.
You probably want to use a custom property, which uses setter/getter to operate on the shape, and sync those, e.g.:
extends PhysicsBody2D

var shape_size : Vector2 :
  set(value):
    var shape := shape_owner_get_shape(0, 0)
    shape.size = value

  get:
    var shape := shape_owner_get_shape(0, 0)
    return shape.size

Yes, sorry to hijack the original topic - it seemed at least semi-related and I wasn't sure where else to post.
Interesting what you're saying about CollisionShape2D - I actually am able to modify it properly in an AnimationPlayer though. A difference between the two though is that I'm able to add CollisionShape2D:shape:size in the animation player by keyframing it from the Inspector tab, whereas in the MultiplayerSynchronizer, I have to specify the path directly.
It still seems a bit odd to me (from a UX perspective) that the exact same path (Hitbox/CollisionShape2D:shape:size in my case) works in an AnimationPlayer, but not in a MultiplayerSynchronizer.
Thanks for your recommendation about using a custom getter/setter on the property - it works perfectly. I'm using C#, so I'll post the C# equivalent I'm using in case anyone stumbles across this thread similar to me:
[Export]
	public Vector2 ShapeSize
	{
		get { return ((RectangleShape2D)ShapeOwnerGetShape(0, 0)).Size; }
		set { ((RectangleShape2D)ShapeOwnerGetShape(0, 0)).Size = value; }
	}


Bugfix: Fix broken: UnicodeDecodeError: 'utf-8' codec can't decode

Doesn't this just remove the error? Emoji's still don't work

Doesn't this just remove the error? Emoji's still don't work

Test passed in Chinese, not test Emoji.

Great to see the Chinese fix.

This should fix #57

Very funny indeed.
My vicuna prefers to answer me in Chinese.
With this fix at least it can without erroring out.

Was this resolved Upstream? https://github.com/ggerganov/llama.cpp/commit/aaf3b23debc1fe1a06733c8c6468fb84233cc44f I like the

Fixes #57

@Niek can you confirm that this fixes the bug and gives the same result in streaming vs. regular mode. For example, compare streaming and regular mode for a completion that breaks in streaming mode with a fixed seed and temperature=0.

I just tested, for my own reference:
docker run --rm -it -v /path/to/models:/models -p8000:8000 python:3-buster bash
git clone -b river https://github.com/riverzhou/llama-cpp-python.git /app
cd /app
sed -i -e 's/git@github.com:/https:\/\/github.com\//' -e 's/.git$//' .gitmodules
git submodule update --init --recursive
python -m pip install --upgrade pip pytest cmake scikit-build setuptools fastapi sse_starlette uvicorn
python setup.py develop
HOST=<IP_ADDRESS> MODEL=/models/ggml-vicuna-7b-4bit.bin python3 -m llama_cpp.server

With a prompt like show me 3 emojis, I no longer get an error, but it seems the message returned is empty instead. So doesn't look like a full fix.

@Niek Can you try chaging for i in range(1,4): to for i in reversed(range(1,4)): so instead we're decoding the longest posible sequence? Not sure this would fix it either but worth a try.

I change the code a littie bit, and it works:
_text = ''
try:
_text = text[start:].decode("utf-8")
except UnicodeDecodeError:
for i in range(-2,2): # changed to (-2,2)
try:
_text = text[start+i:].decode("utf-8") # changed to [start+i:]
break
except UnicodeDecodeError:
continue
yield {
"id": completion_id,
"object": "text_completion",
"created": created,
"model": self.model_path,
"choices": [
{
"text": _text,
"index": 0,
"logprobs": None,
"finish_reason": None,

@riverzhou can you check if this bug is still occurs since #118 was merged?

@riverzhou update?

@riverzhou can you check if this bug is still occurs since #118 was merged?

Fine. It's OK now. Thanks.


draftsight: 2017-SP1 to 2017-SP2

Motivation for this change
The Debian package for DraftSight updated silently to 2017-SP2 without changing URLs.
Things done

[X] Tested using sandboxing
(nix.useSandbox on NixOS,
or option build-use-sandbox in nix.conf
on non-NixOS)
Built on platform(s)

[X] NixOS
[ ] macOS
[ ] Linux

[X] Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
[X] Tested compilation of all pkgs that depend on this change using nix-shell -p nox --run "nox-review wip"
[X] Tested execution of all binary files (usually in ./result/bin/)
[X] Fits CONTRIBUTING.md.

Commit message should be: draftsight: 2017-SP1 -> 2017-SP2 as per Nixpkgs Coding Convetions


Missing libxmlsec1-openssl package in Docker image

Environment

Nautobot version (Docker tag too if applicable): 1.5.19-py3.10
Python version: 3.10.11
Database platform, version:
Middleware(s):

Steps to Reproduce

enable SAML SSO
startup Nautobot from Docker image

Note: all Python packages for SSO are installed, this one is missing from system and should be installed too
Workaround: apt-get install libxmlsec1-openssl in the running container

Expected Behavior
Nautobot started

Observed Behavior

Is this a new issue in the 1.5.19 image (i.e. a regression) or has this never worked as intended?

Thanks for the offer! We haven't changed how we install system packages in the Docker build in quite some time so I suspect it's a long-standing issue - possibly as far back as v1.3 and #1620.

Thanks for the offer! We haven't changed how we install system packages in the Docker build in quite some time so I suspect it's a long-standing issue - possibly as far back as v1.3 and #1620.
(edit) I won't ask you to try and go that far back though! :-)

Hi,
Sorry it took me so long, I did not have the time to get to it :/
I tried following previous versions, all showed the package is missing and installing the package to the container fixed the error.

1.5.2
1.4.7
1.3.0
I tried even 1.2.0, but could not get it running due to changes to webserver.

Thank you for going above and beyond! We'll get this fixed.

Hey team! Please add your planning poker estimate with Zenhub @glennmatthews @gsnider2195 @HanlinMiao @jathanism @timizuoebideri1


Plotting large timeseries arrays crashes Spyder

From<EMAIL_ADDRESS>on 2010-09-16T10:57:02Z
plotting a very large array from the variables explorer crashes the graphing widget & variable explorer
Original issue: http://code.google.com/p/spyderlib/issues/detail?id=378

From ccordoba12 on 2011-10-07T13:45:28Z
Summary: Plotting large timeseries arrays crashes Spyder
Labels: Cat-VariableExplorer

From ccordoba12 on 2011-05-02T11:19:40Z
Could you post an example to see if this is still valid?

From pierre.raybaut on 2011-10-29T04:40:38Z
No activity for a very long time, no way to reproduce the bug: let's close this issue.
Status: WontFix


Increase JSRuntimeMemoryUsage for a static script

Hey,
I wrote a simple ChakraCore app where I executed a method over 100K times and I observed JSRuntimeMemoryUsage increase over period of execution.
   public static void Main(string[] arguments)
    {
        using (var runtime = JavaScriptRuntime.Create(JavaScriptRuntimeAttributes.None, JavaScriptRuntimeVersion.VersionEdge, null))
        {
            JavaScriptContext context = runtime.CreateContext();

            //
            // Now set the execution context as being the current one on this thread.
            //

            using (new JavaScriptContext.Scope(context))
            {
                string script = "function GetNumber(){return 1;}";
                string runMethod = "GetNumber();";
                var max = 100000;
                var i = 0;

                JavaScriptValue result;
                try
                {
                    JavaScriptContext.RunScript(script, currentSourceContext++, String.Empty);
                    while (i++ < max)
                    {
                        result = JavaScriptContext.RunScript(runMethod, currentSourceContext++, String.Empty);
                        result.Release();
                        Console.WriteLine(i + "," + runtime.MemoryUsage);
                    }
                }
                catch (JavaScriptScriptException e)
                {
                    PrintScriptException(e.Error);
                }
                catch (Exception e)
                {
                    Console.Error.WriteLine("chakrahost: failed to run script: {0}", e.Message);
                }
            }
        }
    }

Is this expected ? Why does runtime memory usage increase  even though i just call the Javascript method which is doing nothing ? I would really appreciate if anyone help me to understand the background chakracore work.

How much do you see the memory increase? I believe that each time you invoke RunScript the string that you pass in is copied into a new internal buffer and parsed to distinct bytecode, and I think we don't ever free source buffers until the context goes away because we have no way of getting it back and it's always possible that later on you might try to toString a function, etc.
Instead of invoking your function via RunScript, you could instead get a reference to it from the global object (JsGetGlobalObject to get the global object, JsCreatePropertyId to create a JsPropertyIdRef representing the GetNumber property, JsGetProperty to get the value of that property from the global) and then JsCallFunction to invoke the function. That shouldn't have the same kind of memory growth.

Ah, I see you linked to the memory growth. It looks like your memory is growing by ~256 bytes per iteration, and I would believe that comes from the storing the source buffer + bytecode + some slop and other overhead.

Thanks @MSLaguana. After calling JsCallFunction, it looks pretty stable. I did the same test and it looks the memory consumption gets stable around 10000 execution.

      using (new JavaScriptContext.Scope(context))
            {
                string script = "function GetNumber(){return '1';}";
                string runMethod = "GetNumber();";
                var max = 1000000;
                var i = 0;

                JavaScriptValue result;
                try
                {
                    JavaScriptContext.RunScript(script, currentSourceContext++, String.Empty);

                    var globalObject = JavaScriptValue.GlobalObject;
                    var propertyId = JavaScriptPropertyId.FromString("GetNumber");
                    var runMethodValue = globalObject.GetProperty(propertyId);
                    var emprtyJsArray = new JavaScriptValue[0];

                    while (i++ < max)
                    {
                        JavaScriptValue outValue;
                        var error = Native.JsCallFunction(runMethodValue, emprtyJsArray, 1, out outValue);
                        if (error != JavaScriptErrorCode.NoError)
                        {
                            Console.WriteLine("Error : " + error);
                        }
                        Console.WriteLine(i + "," + runtime.MemoryUsage);
                    }
                }
                catch (JavaScriptScriptException e)
                {
                    PrintScriptException(e.Error);
                }
                catch (Exception e)
                {
                    Console.Error.WriteLine("chakrahost: failed to run script: {0}", e.Message);
                }
            }


Add "revision freeze" CI

Issue
Charm metadata have major version "floating" resource tags such as ubuntu/prometheus:2-22.04. This makes it difficult to track airgapped deployments.
Solution
Add workflow for producing a manifest for airgapped deployments.
This CI could be called after successful matrix tests (related: #102).
Context
The output of this new CI (json manifest) could be then used for downloading charms and resources

juju info grafana-k8s --format=json | jq -r '.id'
https://api.charmhub.io/api/v1/resources/download/charm_${charm_id}.${resource_name}_${resource_revision}

See also:

https://discourse.charmhub.io/t/obtain-all-associated-revisions-via-stores-api/13527
https://git.launchpad.net/~qch2012/+git/fce-lab-nebula/tree/scripts/offline/download-charm-resource.sh?h=3-nodes

itest currently fails because of https://github.com/canonical/traefik-k8s-operator/pull/315.

would it make sense to make a release of the bundle and attach the frozen charm revisions to it as a resource?
It could be a single zipfile, so that all that users have to do is:

download the file
unzip it
run setup.sh (or whatever) --> bundle deployed.

would it make sense to make a release of the bundle and attach the frozen charm revisions to it as a resource? It could be a single zipfile, so that all that users have to do is:
* download the file

* unzip it

* run `setup.sh` (or whatever) --> bundle deployed.

Deploying the bundle would theoretically be possible with
juju deploy <(wget -qO- https://raw.githubusercontent.com/.../frozen-bundle.json | frozen2bundle)

where frozen2bundle is a hypothetical script to be authored by the airgapped deployer.
We could attach it as a resource to the bundle itself when the need arises, but in the meanwhile I was thinking a PR in a similar idea to rocks.

@lucabello could you please take a look at the newly created file matrix-edge.yaml?
The idea is to have independent CI jobs per channel:
graph TD

scheduled --> freeze-edge --> edge-quality-gate -->|on-success| publish-pinned/edge
scheduled --> freeze-beta --> beta-quality-gate -->|on-success| publish-pinned/beta
scheduled --> freeze-candidate --> candidate-quality-gate -->|on-success| publish-pinned/candidate
scheduled --> freeze-stable --> stable-quality-gate -->|on-success| publish-pinned/stable

Currently it the quality gate is the same matrix tests, but it doesn't have to be.
Wdyt?

I think to avoid duplication we should turn this into a reusable workflow (probably named something like bundle-matrix.yaml or something (to add in canonical/observability).
We could extract the risk track into a variable and use {{ inputs.release-track }} instead of edge., then have the the caller workflow (in this repo) probably be a matrix on those four inputs!


Update crashpad, add Windows ARM64 support

Hi! Sorry for the late reply - is Conan required for building now? I see it mentioned in the zlib changes.

Oops, sorry, this PR was accidentally opened on the upstream repository. My fork uses conan to build crashpad, but it also contains a lot of fixes which you may want to import. I managed to update the crashpad sources and port it successfully to Windows ARM64.


HDDS-5766. Speed up some OM tests by skipping SCM safemode check

What changes were proposed in this pull request?
Many of the OzoneManager integration tests do not really use SCM or the datanodes. Therefore we can skip the safemode check in SCM and start zero datanodes to make the mini-cluster come up faster.
With just this change, on my laptop:
TestOzoneManagerConfiguration went from 6min -> 3min 40s.
TestOzoneManagerHAMetadataOnly went from 4min 19s -> 1min 9s.
TestOzoneManagerListVolumes went from 40s -> 20s
TestOMMetrics went from 2min 6 -> 39s 55s

The runtime for these tests on Github is:
[INFO] Tests run: 9, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 273.591 s - in org.apache.hadoop.ozone.om.TestOzoneManagerConfiguration

Warning: Tests run: 10, Failures: 0, Errors: 0, Skipped: 2, Time elapsed: 363.67 s - in org.apache.hadoop.ozone.om.TestOzoneManagerHAMetadataOnly

[INFO] Tests run: 5, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 181.937 s - in org.apache.hadoop.ozone.om.TestOmMetrics

[INFO] Tests run: 6, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 50.156 s - in org.apache.hadoop.ozone.om.TestOzoneManagerListVolumes

What is the link to the Apache JIRA
https://issues.apache.org/jira/browse/HDDS-5766
How was this patch tested?
Existing tests.

Updated tests ran in:
[INFO] Tests run: 9, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 65.194 s - in org.apache.hadoop.ozone.om.TestOzoneManagerConfiguration

Warning:  Tests run: 10, Failures: 0, Errors: 0, Skipped: 2, Time elapsed: 72.674 s - in org.apache.hadoop.ozone.om.TestOzoneManagerHAMetadataOnly

[INFO] Tests run: 6, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 21.88 s - in org.apache.hadoop.ozone.om.TestOzoneManagerListVolumes

[INFO] Tests run: 5, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 46.888 s - in org.apache.hadoop.ozone.om.TestOmMetrics

Saving 208 + 291 + 134 + 29 = 662 seconds saved (~ 11 minutes).


Add CSS variables for scrollbar information

Should include:

state
width

Need to comparedocument.documentElement width with window.innerWidth.

Irrelevant since #12


Embed the corresponding thumbnail image of the chapter when splitting chapters instead of the same cover image for all chapters

DO NOT REMOVE OR SKIP THE ISSUE TEMPLATE

[X] I understand that I will be blocked if I remove or skip any mandatory* field

Checklist

[X] I'm requesting a feature unrelated to a specific site
[X] I've looked through the README
[X] I've verified that I'm running yt-dlp version 2023.01.06 (update instructions) or later (specify commit)
[X] I've searched the bugtracker for similar issues including closed ones. DO NOT post duplicates
[X] I've read the guidelines for opening an issue

Provide a description that is worded well enough to be understood
Suggestion: Chapters specific thumbnails embedding
When -split-chapters is used together with --embed-thumbnail the embedded image should not be the same for all chapters. It should be the thumbnail shown by youtube (or any other website supporting chapters) in the chapters list. For example on youtube those thumbnails are shown on the right:

I don't know if youtube or the other websites provides a public url for those images, but I guess that those pictures are the first non black keyframes from each the video chapter. Even if youtube or the other websites do not provide it, it would be easy to extract it with ffmpeg and embed it as a cover in the corresponding chapter. It should also work when using the -x option, but that would require to first download the frames from the online video and then download the audio only file, split it in chapters and finally embed the corresponding frames as thumbs for the chapters files.

Ref https://github.com/yt-dlp/yt-dlp/issues/6225#issuecomment-1432834461

Even if youtube or the other websites do not provide it, it would be easy to extract it with ffmpeg and embed it as a cover in the corresponding chapter.

If youtube didn't provide URLs for the chapter thumbnails, this would be out of scope. But they do.
It can be obtained from traverse_obj(chapter, ('thumbnail', 'thumbnails', ...)). We don't currently have a thumbnails field in chapters specification, but it can be easily added.
However, actually embedding this in split chapters is non-trivial. It may be impossible to implement until progress is made on https://github.com/yt-dlp/yt-dlp/issues/126 due to the current structure of the PP code

@pukkandan That is great news. And about the structure of the PP code, I just commented on the issue. My opinion is that adding more steps is better that creating a generic monolitic function, because for a complex tool like yt-dlp separation of concerns is a much higher priority than performances or SSD wearing. Otherwise debugging and refactoring would become hellish in the long run.

The issue however is that each PP now don't know about the other PPs - i.e, SplitChapters don't know if EmbedThumbnail is being used. We could technically make it look into other PPs, but imo, that causes more complex coupling than if it were a single monolithic PP.
Do you have any alternate ideas on how this feature can be implemented while maintaining the separation?
PS: There is also the issue that the core code don't know whether SplitChapters is being used and hence can't decide whether to download the chapter thumbnails

This seems at least somewhat related to https://github.com/yt-dlp/yt-dlp/issues/951 - maybe there would need to be some backend work that would benefit both issues.


Wrong history version presented

I have 3 consents

I want to check the 3rd one history.
I see history for the first consent

Comitted

all good


Only works with yamler syck

I was getting couldn't parse YAML at line 1 column 175 when running drop = CloudApp::Drop.find slug, so I took a look around, and found a potential solution of setting the yamler to syck:
      require 'yaml'
      YAML::ENGINE.yamler = 'syck'

And what'd ya know, it works. I haven't took too much of a look into things, and if I recall correctly, the trace went up to httparty, crack and then psych. Hopefully I've provided enough details :)

Thanks - this issue is now fixed in the latest release.


quart crashes when port is not in the host header

I have a service using quart. I tried to enable json_logging on it, but it fails every request like this:
Traceback (most recent call last):
  File "/usr/lib/python3.6/logging/__init__.py", line 994, in emit
    msg = self.format(record)
  File "/usr/lib/python3.6/logging/__init__.py", line 840, in format
    return fmt.format(record)
  File "/home/kyle/.local/lib/python3.6/site-packages/json_logging/__init__.py", line 221, in format
    "remote_port": request_adapter.get_remote_port(request),
  File "/home/kyle/.local/lib/python3.6/site-packages/json_logging/framework/quart/__init__.py", line 115, in get_remote_port
    return request.host.split(":", 2)[1]
IndexError: list index out of range

The reason is that the "Host" header does not have a port on it in most cases. Indeed, it is optional according to the standard: https://tools.ietf.org/html/rfc2616?spm=5176.doc32013.2.3.Aimyd7#page-128
Take the example quart service provided in README.md. Modify it to listen on port 80. curl localhost/ will cause it to crash.
Or, keep it at the default port(5000), and run `curl localhost:5000 -H "Host: localhost". It will again crash
Ultimately, we cannot rely on the listening port being in a header. Some options for a fix:

Return "-" if the split fails.
Try to extract the listening port from quart. Note that this may not be the port the client connected to the system on, since there may be a reverse proxy/DNAT in front of the service.
Don't expose the port at all (what value does it give? The service will log where it's listening when it starts).

As it stands, I cannot use this at all for quart, since I can't override the formatter for request context logs.

Sorry I've been super busy, so PR is welcome!

Do you have any recommendations for a preferred fix?

doing splitting in an optimistic manner is kind of bad. I think we better do it like this:

Extract it from env var or Quart app
If not available, try to extract from host
If none available, return "-"


Redirected error messages to stderr

Fixes #143

Okay let's go. @keelan542 Thanks for the contribution!

No problem !  @desyncr


if command does not work with self-defined function

Describe the bug
The if command doesn't recognize functions defined in the code as commands. It appears that if only works with built-in/SDK commands.
To Reproduce
The following code demonstrates the behavior:
# The built-in command `set` is called and returns `false` to the `if`,
# so nothing is printed.
if set false
    echo This will not be printed
end

# The custom function is never evaluated. I think `return_bool`
# is being treated as a string and not a command name, and
# since a string is truthy the text is printed.
function return_bool
    echo This will not be printed
    return ${1}
end
if return_bool false
    echo This will be printed
end

thanks, ya the 'if' command needs more work.
I'll check it.

so i checked this one, seems i never intended to support this.
it will be some effort, and i'll think how.
i can explain the technical issue here... but at a high level:

conditions (like if) invoke only 1 command.
calling a function by name, is actually behind the scenes a goto command to the function start
condition ends after the goto, it looks at the result.... there is nothing there (function commands are not invoked, we only invoke 1 command) and its falsy.

ok, i think i fixed this one.
so both 'if' and 'not' commands should support it now.
however since its risky change, i'm going to bump the sdk to 0.6 (the duckscript runtime still 0.5, it rarely gets changed).
going to investigate one more thing, but you can install duckscript from the 0.6 branch and try it and give me some feedback.
if you need it for cargo-make, since its a bump from 0.5 to 0.6 you will have to wait a bit longer, as i'll have to update cargo-make for it as well.
thanks a lot for opening the issue and for the vim plugin :)

fixed and published.

Thanks! Tried it out and it works. This wasn't blocking me on anything, it just seemed like it could be confusing.

thanks for the feedback


Overlapping glyphs in Times New Roman substitute on Ubuntu 18.04 LTS

Attach (recommended) or Link to PDF file here: https://www.cityofpaloalto.org/civicax/filebank/documents/8700
https://web.archive.org/web/20201111173839if_/https://www.cityofpaloalto.org/civicax/filebank/documents/8700
Configuration:

Web browser and its version: Firefox 87.0
Operating system and its version: Ubuntu 18.04.5 LTS
PDF.js version: v2.7.368 to v2.8.322
Is a browser extension: No

Steps to reproduce the problem:

Create a fresh installation of Ubuntu 18.04 LTS without any additional fonts.
Download and build any version of pdf.js no older than 45d9ab6.
Download the PDF and open it using web/viewer.html.

What is the expected behavior? (add screenshot) The document should render with an appropriate serif font, since Ubuntu does not have Times New Roman by default. The correct behavior occurs on Ubuntu 20.04 LTS; the first page of the document is shown in this screenshot.
What went wrong? (add screenshot) On Ubuntu 18.04 LTS, the glyphs overlap (or at least connect), rendering the text difficult to read. This is illustrated in this screenshot. Note how the letters are placed identically in the two images; however, the substitute font in 18.04 has a higher weight and ex-height, causing this issue.
Link to a viewer (if hosted on a site other than mozilla.github.io/pdf.js or as Firefox/Chrome extension):

The issue also appears to extend to detection of serif vs. sans-serif fonts. minimal-times.pdf attempts to load the system font /Times#20New#20Roman, but with /Flags 32, indicating a sans-serif font. minimal-nonexistent.pdf attempts to load /NonExistentFontName with the same flags. (The font information on these files was derived from a real-world PDF document.) pdf.js on Ubuntu 20.04, as well as Evince and ImageMagick on both OS versions, renders the first file with an appropriate serif font and the second file with the default sans-serif font. However, pdf.js on Ubuntu 18.04 loads the first file with a sans-serif font with overlapping glyphs.
I've done a bisection to find that the issue was originally introduced by commit 45d9ab6. For reference, this screenshot shows the first page of the legal document on Ubuntu 18.04 using 00b4f86, its parent commit. It can be seen that although the kerning of the word Purposes in the top-right corner was corrected, the remainder of the text encounters this issue. 2600e59 attempted to fix certain overlaps caused by the original commit, but it has no effect on this issue.

This is still an issue on my machine and has been for some time.
JS/frontend debugging is a bit over my head so I'm afraid I can't add any developer insight, but I can reproduce the issue using the minimal examples provided by @LegionMammal978 (thanks for those!).
Configuration

Web browser and its version: Firefox 109.0 (64-bit)
Operating system and its version: Gentoo Linux (amd64)
PDF.js version: 3.2.47 (commit feb6f5951)
Is a browser extension: No

Steps to reproduce

Open minimal-nonexistent.pdf in a new tab
Open minimal-times.pdf in a new tab

What is the expected behavior?

minimal-nonexistent.pdf shows a nicely-rendered sans-serif font:

What went wrong?

minimal-times.pdf shows the same sans-serif font with kerning fudged to "match" Times, which comes out very ugly (since the glyphs are intended for a different set of font metrics):

This particular font-selection/metrics mismatch makes reading some PDFs, particularly those generated by Microsoft Word (with Times New Roman fonts) difficult. For example, this conference paper: https://digitalcommons.usu.edu/cgi/viewcontent.cgi?filename=0&article=4666&context=smallsat&type=additional

#16363 might have fixed this, can you still reproduce in latest Firefox Nightly?

I can still reproduce with the pdf.js version included in latest Firefox Nightly. However, I cannot reproduce with pdf.js built from latest master (e738e15aa397ef91b75fcf952abd0d368b232f20, v3.7.27). I bisected the fix to 53134c0c0bb2d19244dd8c31aa4e8e6d01a657e4 (v3.7.18), which is from the PR you're referring to. Now, both the original document and minimal-times.pdf render with an appropriate serif font on Ubuntu 18.04 LTS, with no overlapping glyphs.

Latest Firefox Nightly should contain this fix. Are you sure you are testing on the latest one? (in the about window, you should see 2023-05-12).

No, I was using 2023-05-11; perhaps the PPA I got it from is a bit slow to update.

Alright, I've downloaded Nightly 2023-05-12 directly and confirmed that the issue is fixed there.


Add option to encrypt CA private key with password

Hello,
I think it's better to encrypt the CA private key so that the unencrypted key only exists in memory. Although it wouldn't help at all if the machine is compromised, it can help in cases of misconfiguration or human errors. One less footgun to worry about.
Thanks,
Ofer

@ofer-dev you could try storing the CA private key on encrypted storage, such as an encrypted block volume, and then only mount it when you need to do CA-related tasks (signing new keys, etc).

@ofer-dev you could try storing the CA private key on encrypted storage, such as an encrypted block volume, and then only mount it when you need to do CA-related tasks (signing new keys, etc).

@dmaroulidis That isn't really a solution; it still results in the key being resident in plaintext on the filesystem.
It's certainly better than nothing though :-).

@dmaroulidis That isn't really a solution; it still results in the key being resident in plaintext on the filesystem.
It's certainly better than nothing though :-).

Thanks for the request! I'm closing this issue as a duplicate in favor of #8 which calls out the AEAD requirement.


Warn correctly or don't warn at all about "experimental" CSS features

User story
As an MDN reader or devtools user, I want to be warned correctly about CSS features that are marked "experimental", so I can take necessary steps or avoid using given features. If the warnings are wrong, then I don't want to be warned about "experimental" features at all.
Acceptance criteria
Only CSS features that are worth calling out "experimental" are marked as such in BCD for CSS features and on MDN CSS pages. This might mean that we're deciding to get rid of the concept of "experimental" altogether.
Tasks

[ ] Go through all CSS features marked as experimental. See this gist https://gist.github.com/Elchi3/c11fab36f99e2c1ba2f88b741080d675

[ ] Decide if any features are worth being called out as "experimental".

[ ] Update status.experimental in BCD depending on the outcome of task 2.

[ ] Update / remove any banners (experimental, SeeCompatTable) on MDN CSS pages according to the outcome of task 2.

This needs coordination with devtools folks who have implemented calling out "experimental" CSS features in their latest draft of the web compat tool. See the screenshot here: https://groups.google.com/forum/#!topic/mozilla.dev.developer-tools/U350YHcJZac
The BCD issue about removing the concept of "experimental" altogether (not just for CSS features) is https://github.com/mdn/browser-compat-data/issues/1528

@rachelandrew this is another task that we'd love your help on in the upcoming sprint, depending on how much of your time is needed for it.

I have a proposal for improving how we manage the "experimental" flag. Currently, everything that's experimental is supposed to be marked that way.
My suggestion is  this:

Add an experimental flag to the SpecData.json file (or, better, find a way to add this flag to the BCD repository). If an entire specification is experimental, set that flag. Do not set experimental on any of the API's members in the BCD JSON.
If a non-experimental API has an interface or other "top level" member which is experimental, set the experimental flag on it. Do not set the experimental flag on any of its members in the BCD JSON.
If an API and a member interface or dictionary or whatever are not experimental, but a member of the interface or dictionary is experimental, set the experimental flag on that member.
Update the macros that generate badges or banners based on the experimental flag to check ancestors in addition to the object itself, until either the experimental flag is true or the top of the hierarchy is reached.

Basically, what this boils down to: set the experimental flag on the highest level item that covers the experimental nature of things, and do not set it on any of the lower level items in the hierarchy.
For instance, if the Web Nuclear Fusion API spec is experimental, set experimental on it in SpecData.json (or in BCD if we add this capability there), and you're done. None of the interfaces or other items contained anywhere within the API should be marked experimental.
Or if the Web Toaster API is non-experimental, but its non-experimental interfaceToast has an experimental function, eat(), set the experimental flag to false on the API and the interface, but to true on the eat() method in BCD.
This way, we minimize the amount of maintenance we have to do when managing experimental technologies, since we don't have to change the BCD for every single component of an API if the entire thing is experimental, and when the API "graduates", you only have to change one value.

I'll go through and update any that are definitely not experimental (I think a whole batch are logical properties which are now in 2 browsers), whatever is left I'll come back with so we can work out what to do about them.

This is going to take a bit longer than my optimistic one day, but I've made a pretty good dent in it today. I've put them all into a spreadsheet and am working through the obvious not-experimentals to fix the data/pages and I'll then post a list of ones we might need to make a call on, along with info which might push them one way or the other.
I think the true "shipped in a browser while still experimental" stuff is happening less. The things that are like that are typically quite old. These are features which were implemented in one browser, sometimes prefixed, and the spec is still being worked on, which is why we don't have other implementations.
I think in general that even if we only have one implementation, if the spec is at CR, and there are no issues flagged in the spec of the WG GitHub about that feature we're probably safe to not have it marked as experimental. At that point we're talking about lack of implementation rather than changing spec. Anyway, I shall continue with this.
Couple of PRs below to fix up BDC data.

https://github.com/mdn/browser-compat-data/pull/5147
https://github.com/mdn/browser-compat-data/pull/5151

More updates:

https://github.com/mdn/browser-compat-data/pull/5174
https://github.com/mdn/browser-compat-data/pull/5175
https://github.com/mdn/browser-compat-data/pull/5176
https://github.com/mdn/browser-compat-data/pull/5177
https://github.com/mdn/browser-compat-data/pull/5178

If we’re putting an experimental flag to SpecData, then we should probably do that in mdn‑data once https://github.com/mdn/data/pull/397 is merged.

If we’re putting an experimental flag to SpecData, then we should probably do that in mdn‑data once mdn/data#397 is merged.

We are not doing that.

If we’re putting an experimental flag to SpecData, then we should probably do that in mdn‑data once mdn/data#397 is merged.

We are not doing that.

OK, so what precisely do you propose we do? I don't think it's appropriate to outright get rid of the concept of experimental APIs, because they do exist, and they do get shipped enabled in browsers, even though they probably should not. Developers need to be aware of that when it does happen. So we can't just remove the concept of labeling things as experimental, which was one of the proposals made.

Still ploughing through these:

https://github.com/mdn/browser-compat-data/pull/5207
https://github.com/mdn/browser-compat-data/pull/5208
https://github.com/mdn/browser-compat-data/pull/5209
https://github.com/mdn/browser-compat-data/pull/5210
https://github.com/mdn/browser-compat-data/pull/5211

Added an issue for margin-trim https://github.com/mdn/sprints/issues/2476

@a2sheppy @Elchi3 I think with these CSS ones there are a set of genuine experimental things. Mostly these are due to shipping of stuff in one browser while the spec is being worked on, sometimes behind a flag and sometimes not. The not behind a flag is not happening so much now but in the past a few things did and they still hang around.
If we are going to document things which are behind a flag, and I think it is useful to do so as it helps people offer feedback, then I think it is worthwhile explaining that the spec may well change. Ultimately that's the reason to put something behind a flag in development.
I feel as if it might be good to link to an explanation somewhere about how these things are developed, why we have experimental things in browsers (and why it is helpful to look at them, where to offer feedback) rather than just having an experimental flag with no explanation of the situation.
I kind of have a few groups of things as I work through:

Things which are implemented with a stable spec (Not experimental and I am updating these)
Things with at least two implemenations but a spec still in ED/WD. I think we need to make a call on these case by case.
Things with only one implementation but a spec in CR (good arguments to unflag some of these on a case by case basis)
Things with flagged implementations, unstable specs, issues raised against them in specs (definitely experimental)

So I've made a first pass through these. In this spreadsheet the ones marked in green I think probably are genuinely experimental https://docs.google.com/spreadsheets/d/14Ah74a8rpxtvSHe7T3ivzry5VvwNrL9XZFMeKsKJGPY/edit?usp=sharing
I have already updated the BCD for those that definitely are not. I think in reality most of the others (that I haven't already done, and that are not marked in green) could probably have the flag removed. There are a few that don't have implementations, but there is nothing to indicate them being experimental as such. However given that a spec can't move past CR without there being two independent implementations it is of course possible things could change there. But it might be reasonable to have things marked experimental if they:

have no implementations at all
have issues raised against them in the spec

Anyway, I probably need some other opinions at this point but I've done a lot of BCD updating as part of this!

Thanks for this heroic effort, @rachelandrew :100:
This is definitely a big step towards much saner usage recommendations for CSS features. I'm sure we will get a lot less complains about misused "experimental" banners/flags now. :tada:
Some thoughts on the overall situation:
The two things you list for reasonable "experimental" status generally sound good to me. I wonder, though:
If we have no implementation at all, should just let that speak for itself? Why would we need to also call it "experimental" in addition to have an all red compat table? I think the core problem is that we've coupled implementation status to "experimental" and we then forget to update "experimental" when implementations actually happened.
And for things that have issues raised against them in the spec, should we rather call these features "unstable" and really only mark features as "unstable" when it is the case? Is "experimental" too unspecific? Do you think we should always have an explanation or a link to the spec issues, so that if such issues are resolved we can also resolve the "unstable" / "experimental" state in our data?

I like the idea of "unstable" with links to the spec. Mostly these are going to be features with some history at this point as we don't get half baked stuff implemented so much these days. Even things which have changed after shipping - for example the renaming of grid-gap to just gap get aliased, so if things are in browsers they should probably be classed as usable in most cases.
I'd be happy (if @chrisdavidmills is) to continue this effort and fix up the remaining ones if we have a decision.

I like this idea, and am happy for @rachelandrew to continue to help with this work, but I want her to continue on the learning area assessments work next. I'd like to see a plan for how much work there is to do here, what it would involve, etc., so we can figure out slotting it into our schedule.

@chrisdavidmills I'm on the learning area stuff now. In terms of updating the ones I didnt update because I wasn't sure if we wanted to keep them experimental, it's probably a couple of days, add an extra day if I also need to flag the spec issues as I'll need to go find the exact issue and link to it etc.
It would probably be fastest to do sooner than later just because I've had my head in it recently so I won't have to spin up again and remember where I was.

@rachelandrew OK, that's a fair point. Would it be OK if you just finished the little bits of assessment stuff for the current user stories, then went back to this work, and then after that did some more assessments work?

@chrisdavidmills sure - I think put this in the next sprint and I'll tackle it once I've done the assessments stuff. Would be quite nice to feel it is tidied up having put so much time into it :)

@rachelandrew sounds good; totally agree!

@Elchi3 if we are going to switch to unstable and link to the spec, how should I do this in the data?

I think it would require a change to BCD. Could we maybe first collect these things as a draft in a BCD issue and then discuss how we model it into the data structure? A (diverse) set of examples for "unstable" would help enormously to model this. Does that seem like a sensible approach?

sounds good to me, what I'll do then is I'll go through and fix the BCD for the ones that don't have spec issues and make a list of those that do in an issue with their links and so on as a new issue against BCD.

So, I think I am through these. I have created a set of data as suggested above to list the features that have something sketchy about them: https://github.com/mdn/browser-compat-data/issues/5392
Otherwise pages are updated, BCD is updated, there is a PR for data to fix the sidebars to match the BCD and pages. I think this part of the task is done pending all those PRs being merged.

Rachel, happy new year and thank you so much for this work! This makes me soo happy! :100:
We can now call this done and continue the conversation in https://github.com/mdn/browser-compat-data/issues/5392 where I'm eager to find a better concept for "experimental" or "unstable" features in BCD thanks to your fundamental research! :1st_place_medal:


feat: validator with base stake amount

New Field Added to Validator
Upgrade the current validator pool design by adding a new field called base_stake_amount for each validator, which is needed for scheduling staking to Stake Wars III winners who will have a fixed base stake amount based on the DNP scores the validators get in Stake Wars: Episode III. The field is 0 by default for other validators.
pub struct Validator {
    pub account_id: AccountId,
    pub weight: u16,

    pub staked_amount: Balance,
    pub unstaked_amount: Balance,

+   /// The base stake amount on this validator.
+   pub base_stake_amount: Balance,

    /// the epoch num when latest unstake action happened on this validator
    pub unstake_fired_epoch: EpochHeight,
    /// this is to save the last value of unstake_fired_epoch,
    /// so that when unstake revert we can restore it
    pub last_unstake_fired_epoch: EpochHeight,
}

By adopting the updated model, we will have

formula: target stake amount = base stake amount + dynamic stake amount.
In this model, we ensure the sum of target stake amount is equal to the total staked amount,
and prioritize base stake amount over dynamic stake amount.
If total staked NEAR amount >= total base stake amount,

satisfy the base stake amount set by validator manager;
calculate dynamic stake amount proportional to weight

If total staked NEAR amount < total base stake amount,

set dynamic stake amount to 0;
calculate the base stake amount proportionally

New Function Added
This PR adds a new manager-only function
fn update_base_stake_amount(&mut self, validator_ids: Vec<AccountId>, amounts: Vec<U128>);

which can update the base stake amounts for a list of validators.
How It Works
(1) Stake to Stake Wars III Winners
This will delegate the allocated NEAR amount to the Stake Wars winners.

NEAR Foundation adds the winners' validators into whitelist, so lockup accounts and liquid staking protocols are allowed to stake to these validators.
LiNEAR validator manager adds the winners' validators into LiNEAR's validator pool.
LiNEAR validator manager updates the validators' base stake amount with the target delegation amount for each validator provided by NEAR Foundation.
NEAR Foundation will stake the total target NEAR amount to LiNEAR protocol.
When a new epoch starts, the target stake amount will be delegated to all the validators.

(2) Unstake from Stake Wars III Winners
After the planned delegation period to the winners ends (e.g. after 12 months), NEAR Foundation can unstake the staked NEAR.

LiNEAR validator manager updates the winner validators' base stake amount to 0.
NEAR Foundation starts unstaking the LiNEAR it owns.
When a new epoch starts, the unstake will start on each validator because the target stake amount has been updated.
After 4 epochs, NEAR Founation will be able to withdraw the unstaked NEAR.

(3) Update Rewards
The base stake amount should be updated every epoch by taking into account the accumulated staking rewards.

When updating total balance of each validator, the base stake amount will also be updated proportionally.

(4) Remove Invalid Validators
If a validator is invalid or decided to be removed by NEAR Foundation, the LiNEAR validator manager account could reset the base stake amount, and even remove it from the validator pool.

NEAR Foundation decides to remove some invalid validators, or LiNEAR validator manager finds that some validators are obviously not functioning properly.
LiNEAR validator manager sets the validator's base stake amount to 0.
LiNEAR validator manager drains the validator and removes it if not valid any more.

Notes
State migration is required when upgrading contract with this feature

Should we update bin/commands/set-node.js?

Should we update bin/commands/set-node.js?

Good point. Command bin/commands/set-node-base-amounts.js added.


golioth_on_message inconsistently bounded by mutex

bounded by mutex in get sample:
https://github.com/golioth/zephyr-sdk/blob/ff39bf1c51e8185964c7de8b253ca4d657393ca8/samples/lightdb/get/src/main.c#L59
not bounded in observe sample
https://github.com/golioth/zephyr-sdk/blob/ff39bf1c51e8185964c7de8b253ca4d657393ca8/samples/lightdb/observe/src/main.c#L91

Is this okay?

@mniestroj

This issue will be addressed as part of #132.

golioth_on_message was removed.


Notebook smoke tests failing

  24 passing (2m)
  4 pending
  1 failing

  1) VSCode Smoke Tests (Electron)
       VSCode Smoke Tests (Electron)
         Notebooks
           inserts/edits markdown cell:
     Error: Timeout: get element '.notebook-editor .monaco-list-row.focused .monaco-editor' after 20 seconds.
      at /Users/runner/work/1/s/test/automation/out/code.js:187:23
      at Generator.next (<anonymous>)
      at fulfilled (/Users/runner/work/1/s/test/automation/out/code.js:9:58)

@roblourens this is likely due to the recent changes but I don't even know where to start investigating here...


Setup the url and keys for qt play web update

Refer
https://github.com/bitsuperlab/qt_play/blob/master/WebUpdates.hpp#L16
https://github.com/bitsuperlab/qt_play/blob/master/WebUpdates.hpp#L13
Using tools to pack web update:
https://github.com/bitsuperlab/bitshares_play/blob/develop/programs/utils/pack_web.cpp
https://github.com/bitsuperlab/qt_play/blob/master/MainWindow.cpp#L867

https://github.com/bitsuperlab/qt_play/commit/cdb4f0ce4e4acb406f9c2cc3e87562411d49c077


resolve the dns by parse /etc/resolv.conf file

resolve the dns by parse /etc/resolv.conf file
解决必须在nginx上指定resolver才能请求域名的接口的问题
using the code from the blog behind
用了这个博客的代码
http://hambut.com/2016/09/09/how-to-resolve-the-domain-name-in-openresty/?utm_source=tuicool&utm_medium=referral

It doesn't make sense to me to add this to lua-resty-http. If you wish to resolve host names to IP addresses in a custom way, you're free to do that, and then connect to the IP manually and use the request() method.
If you really need /etc/hosts to be utilised automatically, surely a better way is to use something like dnsmasq as a local resolver, and tell Nginx to use this with the resolver directive?

in fact, I'm NOT doing something to resolve host names by DNS in a custom way
i'm thinking to make the request more like other web script language, AUTO resolve the request domain by using the system's way, not nginx's.
problem 1:

as for now ,if you put a resolver in Nginx, once the DNS server down, you never know, and you need to change to a new address manually.

problem 2:

we have DNS server in the intranet, the operations controls to nginx config and DNS server, once they put a new DNS server online/offline, i suppose they make changes on the core routers and  every machine knows, so a API server using other web script language request a url normally, Openresty can not.

I just don't know how to solve the problems

I didn't mean to suggest you were doing something custom in a bad way, only that you're using a resolver other than the Nginx one, which is the standard way. Something other than this, I would call custom.
It sounds like you have some specific issues which require you to do DNS resolution more dynamically - which is totally fine - but you can do this outside of lua-resty-http, and then connect to the IP you've obtained.
If this method of auto resolution (i.e. not using the Nginx resolver) should be considered a better standard way of working, I'd suggest raising it for discussion more widely on the OpenResty mailing list, because it should affect all cosocket modules really. It doesn't make sense to bury this within just the HTTP driver specifically.
As for your two specific problems (again, this is more a question for the OpenResty or Nginx mailing lists)

It's normal to have more than one DNS resolver available - list them space separated.

Again, if you use dnsmasq, OpenResty can use say <IP_ADDRESS> as its resolver, and you in turn configure dnsmasq to use local config or speak to upstream resolvers etc. I've not used it in years, but I think it might solve some (or potentially all) of your problems.

If not, and you prefer to use a Lua solution, you can still do this outside of the lua-resty-http. Something like this (untested):
local httpc = require("resty.http").new()

local uri = "http://example.com/path/2/something?a=1"
local parts = httpc:parse_uri(uri)
if not parts then
  ngx.log(ngx.DEBUG, "bad uri")
end

local scheme, host, port, path = unpack(parts)
local ip = resolve_dns(host)

local res, err = httpc:connect(ip, port)
local res, err = httpc:request{
    path = path,
    headers = {
        ["Host"] = host,
    },
}

if not res then
  ngx.say("failed to request: ", err)
  return
end

local reader = res.body_reader

repeat
  local chunk, err = reader()
  if err then
    ngx.log(ngx.ERR, err)
    break
  end

  if chunk then
    -- process
  end
until not chunk

local ok, err = httpc:set_keepalive()
if not ok then
  ngx.say("failed to set keepalive: ", err)
  return
end


heif: Unsupported feature: Unsupported codec (4.3000)

Describe the bug
I receive the following error:
heif: Unsupported feature: Unsupported codec (4.3000)
To Reproduce
Link to screenshot below with the following edits
edits: {
toFormat: 'webp',
rotate: null,
resize: { width: 128, withoutEnlargement: true, fit: 'cover', height: 128 },
webp: { quality: 90 }
}
Please complete the following information about the solution:

v5.2.0
us-east-1
No Modifications
No quotas reached

Screenshots
https://filesamples.com/samples/image/heic/sample1.heic

@SNagappan thanks for your feedback. Let me clarify your issue. The sample screenshot is the original image, and you tried to modify the image with the edits you provided?
Unfortunately, we don't support heif or heic currently.

@beomseoklee That is correct.
Can you provide an outline on how I could modify the code to support heif/heic?

@SNagappan you can refer to these ones to support heif/heic:
https://github.com/lovell/sharp/issues/2004
https://github.com/lovell/sharp/issues/1105
Then, you may can modify inferImageType and parseRequestType in image-request.js.
https://github.com/awslabs/serverless-image-handler/blob/c5db6f7efbd6d151c31f2781c9a6c3c3c9d7d299/source/image-handler/image-request.js#L400-L416
https://github.com/awslabs/serverless-image-handler/blob/c5db6f7efbd6d151c31f2781c9a6c3c3c9d7d299/source/image-handler/image-request.js#L278-L282

I ended up using this package to convert heic images to jpg and then resize accordingly.


When first PSM has no isoquant, this crashes

Discovered when Nate and Zhuoheng had CID MS data and few scans had detected TMT. First row with TMT from DB was 1500 or so, so pif variable referenced was not initialized when the while exited immediately. Also problematic if a certain scan has no quant, the PIF will be the previous PSMs!
https://github.com/lehtiolab/msstitch/blob/0eefdc2e6c87dba4a5116cbb5922765c17b7f215/src/app/actions/psmtable/refine.py#L559-L565

Fixed in https://github.com/lehtiolab/msstitch/releases/tag/release_3.14


Make decisions on next steps toward tile server stability

Overall, it seems like there is too much caching going on to really be able to make sense of things. My summary thus far looks something like:

Having no cache performs pretty bad (~44 requests a minute)
Adding a local cache for the attribute store helps a lot (~425 requests a minute)
Adding tile caching without attribute store caching does little (~53 requests a minute)
Enabling all caches tacks on a few more requests per minute vs. attribute store cache and tile cache, but HeapBackedMemcachedClient may not be worth the additional complexity (~754 vs. ~722)

Moving forward, I think that we should look into:

Removing the HeapBackedMemcachedClient client
Comparing the performance of local attribute store cache vs. one backed by Memcached (it would be great to unify the cache store)
Comparing the performance of a local attribute store cache vs. a PostgreSQL backed attribute store with no cache
Tuning S3 HTTP client configuration (enable keep-alives, connection pool, surface any retries that may be happening via metrics)
Fixing https://github.com/azavea/raster-foundry/issues/1808 because loading the project listing often raises Memcached client exceptions that screw up regular tile requests

The Setup
All results below were executed against the staging environment using:

2 x instances of the tile server, load balanced by ALB
2 x Memcached cluster nodes
Project ID 08bab6ab-f09d-456d-b52b-3c136a95f286 (8 scenes)
A collection of ~200 tile requests recorded from my browser session
5 x users simulating the session above
Tile URLs w/ my JWT (no mapToken, no public project)

No cache (Straight up S3 attribute store and S3 tiles)

Only local attribute store cache (No cache for S3 tiles)

Only tile cache in memcached (No local attribute store cache)

Only local attribute store cache and tile cache in memcached (No heap-backed cache)

All caches (More caches, more problems)

Great! Thanks for this summary.

Want to add, that this Saturday i decided to see how staging works (3 flags enabled), and my UX was terrible.
// Before cache warmup it was impossible to use site at all, and it looked broken : D

This may have occurred after a PR was merged that kicked off a Jenkins deployment at 9AM ET. In that case, it would represent all 3 caches disabled.

This is great - it's good to finally have some comparisons and numbers to be able to make some more informed decisions.
Since @pomadchin has done most of the legwork for "a PostgreSQL backed attribute store with no cache" should we try that out too?
I think it would be good to get things in a place where we're still comfortable deploying this to prod. Based on the numbers it seems like

Only local attribute store cache and tile cache in memcached
may be the best option to do by default based on the numbers above. Is that correct?

The new defaults are:

Local attribute store cached enabled (TILESERVER_CACHE_ENABLED )
Memcached backed tile cache enabled (MEMCACHED_ENABLED)
Heap-backed Memcached cache disabled (MEMCACHED_HEAP_ENABLED)

As far as the PostgreSQL attribute store, I am still trying to get it to work in staging. The layer_attributes table from https://github.com/azavea/raster-foundry/pull/2200 was created out-of-band and populated by the migration_s3_postgres based on staging catalogs. Unfortunately, tile requests are timing out without a clear reason. Works OK locally though.

PostgreSQL attribute store (No other caching enabled)

Performs better than local attribute store cache of S3 attribute store JSON
Has a more attractive latency profile due to lack of spikes in latency when retrieving attribute store JSON from S3
Adds an additional step to the ingest process that requires updating the database with attribute store information
Increases database load (slightly, thus far) for all tile interactions

Superseded by https://github.com/azavea/raster-foundry/issues/2306, to a degree.


AdMob Free Plugin on Ionic 3

Hey Everyone, i installed admob free plugin on my ionic 3 project, and typed this code
async showBanner() {
		try {
		const bannerConfig: AdMobFreeBannerConfig = {
			id: 'ca-app-pub-APP_ID',
			isTesting: false,
			autoShow: true,
		};
		this.admobFree.banner.config(bannerConfig);

		const result = await this.admobFree.banner.prepare();
		console.log(result);
		}
		catch (e) {
			console.log(e);
		}
	}

but the ads aren't showing ... i'm deploying on a real device with android version 6.0.
Hope to get some help, thanks !

Are you getting any errors? Ads take up some time to show if they are newly created ad units.

@prantikv no its fixed thanks :D, i reinstalled the plugin and its working fine now !

@hamdanihamza close the ticket if it's working.
Duplicated: https://github.com/ratson/cordova-plugin-admob-free/issues/119


Publish benchmarkdotnet.analyser to nuget.org

Is your feature request related to a problem? Please describe.
Consuming packages from nuget is easier and more streamline. Also, the authentication method is easier.
Describe the solution you'd like
Similar to benchmarkdotnet which is published to nuget.org, can we have the tool published as nuget tool.

Apologies @tomerrt  for not seeing this earlier!  I entirely agree with you, moving to nuget. Please leave this with me.

Do you still have plans to do this?

Absolutely I do. Apologies for the progress on this @PixelByProxy @tomerrt, I need authorisations from our management on this issue.

Not forgotten, nor abandoned: we're looking to move forward with this request.

@PixelByProxy  @tomerrt  - after many, many months, this package is now on Nuget: https://www.nuget.org/packages/bdna/

Once again: apologies for the late delivery. We have some very stringent security gates to adhere to.


Handle conflicting arguments like failed and repeat

Expected behavior
gauge run --failed --repeat should give invalid command. Same as gauge run --repeat specs

should be available in nightly > 30-4-18

should be available in nightly > 06-07-18


deps: Update openal-soft to 1.12.0

This doesn't compile on the latest toolchain available in Arch Linux otherwise because there are const arrays defined in bformatdec.h not marked extern which causes a link error.
Signed-off-by: Joshua Ashton<EMAIL_ADDRESS>

Sorry about this (coincidentally I reinstalled Arch today and ran into this too).  This OpenAL revision appears to have issues on Windows based on the CI failure.  In general, lovr isn't supporting/updating OpenAL right now and efforts are being focused on switching to miniaudio (#302 / miniaudio-new branch).  It's kind of annoying but I'd just recommend applying this fix locally for the time being.

Sorry about this (coincidentally I reinstalled Arch today and ran into this too).  This OpenAL revision appears to have issues on Windows based on the CI failure.  In general, lovr isn't supporting/updating OpenAL right now and efforts are being focused on switching to miniaudio (#302 / miniaudio-new branch).  It's kind of annoying but I'd just recommend applying this fix locally for the time being.

No worries.

No worries.


RBSL

Rewrote all built-in shaders with RBSL, which is an attempt at making shaders easier for the developer to write.
RBSL currently provides the following two things:
0. #include for GLSL
While GLSL already includes this functionality, it is a difficult process to use it, involving the set up of a "virtual file system" within OpenGL in order to set up the files that it is able to load. Thus, RBSL provides this functionality as part of a pre-process.

RBSLU, a uniforms definition file.

This file allows you to define the uniforms that will be used in a shader. Uniforms declared in this file are automatically linked to Mittsu. The uniforms also have a slightly different syntax for declaration, notably:

0. New types `color` and `texture`. The color will be mapped to a vec3 in the shader, but is handled as a `Mittsu::Color` object in Mittsu. Texture is an "umbrella-type" that handles all sampler* types.
0. Array types are declared with the `[]` after the type instead of the name. This is mainly to make parsing it easier.
0. Array values are declared using `[...]` syntax, instead of the standard GLSL way. I think it's easier to declare arrays this way.

These things might change in the future, and more features will be coming in the future. This PR basically sets the stage for RBSL to grow and evolve.

Coverage increased (+0.2%) to 65.589% when pulling cbea00d276ae35c37b9213eed127a946f06ca2a4 on ds-rbsl into b5f78db9f67edf8cdc65dbb7f2350685182bfffa on master.

Coverage increased (+0.2%) to 65.628% when pulling 21ea728888b6cb9adf4ea39cccd7d5d05d045f27 on ds-rbsl into b5f78db9f67edf8cdc65dbb7f2350685182bfffa on master.

Coverage increased (+0.05%) to 65.429% when pulling a16e7be49922badbcc6aacf53973555a5f0dfd9d on ds-rbsl into b5f78db9f67edf8cdc65dbb7f2350685182bfffa on master.

Coverage increased (+0.2%) to 65.562% when pulling ebe8e981626061c22527fb2989b5c96272fc0f27 on ds-rbsl into b5f78db9f67edf8cdc65dbb7f2350685182bfffa on master.


feat: add binding for external vars

External variables binding for https://github.com/nuxt/content/issues/2053
I've implemented a feature that allows for external variable binding within the Nuxt (Content) MDC project. This enhancement enables seamless integration of external variables into the project, thereby enhancing its functionality and flexibility.
To provide a bit of context, I had initially introduced this binding capability to my personal fork of the project before the extraction of MDC from Nuxt Content. https://github.com/maximepvrt/nuxt-content/commit/57d584572d66900a5a49de96c4c390500c7254ae
As of now, I acknowledge that I haven't yet included tests for this feature. I am aware of the importance of testing in ensuring the stability and reliability of the project. However, I've encountered some challenges in devising the appropriate testing strategy, particularly given the specific nature of the binding functionality. Additionally, I've been unable to locate existing tests for the binding aspect within the MDC project.
I remain enthusiastic about contributing to the Nuxt Content MDC project and ensuring its continued growth and improvement.
<template>
  <MDC v-slot="{ data, body }" :value="md">
        <MDCRenderer
          :body="body"
          :data="data"
          :prose="false"
          :vars="mdcVars"
        />
  </MDC>
</template>

<script setup lang="ts">

const mdcVars = ref({ name: 'Maxime'});

const md = `
::alert
Hello {{ $vars.name }}
::
`
</script>

Hey @maximepvrt,
Is there any specific reason for not using data prop to pass external variables to the renderer?

Hey @farnabaz,
Thank you for your feedback. I created a new MR in https://github.com/nuxt/content/pull/2296 used the data props to pass external variables to the renderer.
With this current implementation, external variables are accessible through the $doc object (e.g., $doc.firstname) within the ContentRendererMarkdown component. This behavior may appear unusual.
If you have any suggestions regarding this approach or if you believe there's a more elegant solution, please feel free to share your thoughts.
Best,

Introducing new user-provided source of data for runtime is a tricky thing to support in the module's roadmap.
I know that using $doc may sounds not good but for now it is the only options and note that it might face changes in next major release.
I'll keep this feature pending for now.

@farnabaz did you see my MR https://github.com/nuxt/content/pull/2296


LaunchProjectetile, Item Dropping, and Entities spawned by command do not follow new SpawnCause conventions

Simply put, calling the method "launchProjectile," dropping an item with 'q' or using the /summon Command throw errors that say that the root Cause must be a spawn cause. I'm not sure if this is coming in #502, but I couldn't find an issue, so here you go.
Edit:
Not sure if it's helpful, but the /summon and q actions still complete (the item is dropped, or the entity is summoned), but launchProjectile doesn't actually launch anything.

Can confirm with @Aaron1011.

Taking a look

This is caused by ProjectileLauncher creating the causes wrong. Instead of using a SpawnCause, it creates a named cause with the entity as the root source. There are many ways to patch this, but @gabizou I would like to know what you think is the best solution.
I am leaning towards taking the checkSpawnCause call out of the static doLaunch method and checking if the cause is an instanceof Living then wrapping the cause in a SpawnCause as appropriate. The other possibility is to duplicate similar logic in all the individual ProjectileLogic implementations. I don't really like either approach, since inheritance would be the ideal solution, however the implementation of the class makes the inheritance based approach seemingly impossible.

Going to leave this to https://github.com/SpongePowered/SpongeCommon/pull/502 or at least until that is done. Since there are massive changes there.

This does not occur in latest build.


Workaround for erlenv when invoking to anyenv versions

erlenv uses releases subcommand instead of versions . I always looks following error.
erlenv:
erlenv: no such command `versions'

Thanks!


Modularizing for CLOPS and EPLG Qiskit Qrack benchmarking.

Adding file gate.pyfor common gate-based utilities.
Adding bench.py for common benchmarking runs (right not just Qrack)
Adding parse.py for common command line parsing
Using argparse over sys.argv for cmd-line arg parsing
Adding logging
Updating pyqrack in pyproject.toml file.
Other misc. things (docstrings, comments, uniformizing style, etc.)

Consider this approved once you change the default to 8 shots.


Status of the data

The data is based on a glossary in PDF, which is, however, not easy to digitize. The author shared a spreadsheet with me in the past, with extended data, which we should not share online.
My idea is: take only the languages explicitly mentioned in the official publication (about 8) and extract them from the spreadsheet. Otherwise it would be unfair for the author (and we'd have a hardtime to find sources for the data).

The immediate task is thus to check the concepts by referring to source, i.e., this?
The PDF looks to have been generated in a proper way, so it should not be extremely difficult to parse its textual conversion.
I will be working on the conceptlist meanwhile.

You saw all the material I sent you, right? If there are more questions, have a look there. I sent two emails on this last week, I think. Will check them if I'm in the office (bout 30 min).

Dataset is done.


How to set cookie_flags?

In Firefox I'm getting the following error in the console:
Some cookies are misusing the recommended “SameSite“ attribute
I've tried to set the SameSite attribute to comply, but it doesn't seem to have an effect. This is my current implementation, am I misunderstanding how to set these variables?
Vue.use(VueGtag, {
      config: {
        id: "UA-XXXXXXXX-X",
        cookie_domain: "https://www.mydomain.com",
        cookie_flags: "SameSite=None;Secure",
      },
      enabled: true,
      disableScriptLoad: false,
      bootstrap: false,
      pageTrackerEnabled: true,
    });

Yes the config objects has 2 properties id and params
Try to put those two paraments inside the params object. Should work

Hi @MatteoGabriele, thanks for the clarification. Can confirm that this works.


[EROR] Authorization result: valid

Tested to renew certificates in staging environment.
Certificates were renewed, but during process LEWS output an error on a seemingly no-error situation, see below in bold text.
[DBUG] Renewal period: 55
[VERB] Checking renewals
[INFO] Renewing certificate for (name_removed)
[DBUG] Loading signer from C:\ProgramData\letsencrypt-win-simple\httpsacme-staging.api.letsencrypt.org\Signer
[DBUG] Getting AcmeServerDirectory
[DBUG] Send GET request to https://acme-staging.api.letsencrypt.org/directory
[DBUG] Loading registration from C:\ProgramData\letsencrypt-win-simple\httpsacme-staging.api.letsencrypt.org\Registration
[DBUG] Send POST request to https://acme-staging.api.letsencrypt.org/acme/new-authz
[INFO] Authorizing (name_removed) using http-01 validation (FileSystem)
[INFO] Answer should now be browsable at http://(name_removed)/.well-known/acme-challenge/lhaxArEM4Vk5lSeh-Di4ggeSyDetcF2nTeTze7DhxiA
[DBUG] Submitting answer
[DBUG] Send POST request to https://acme-staging.api.letsencrypt.org/acme/challenge/qYCHZCjHeyOyrNtSF2YDORZvsnGNfV7qYHYenHrJnVs/84083726
[EROR] Authorization result: valid
[DBUG] Deleting answer
Client version : letsencrypt-win-simple.v<IP_ADDRESS>-beta7
Windows version : Windows 10 Pro x64
Command line: letsencrypt.exe --test --renew --forcerenewal --closeonfinish --verbose

The simplest kind of logic bug. Big d'oh from my side, thanks for reporting it!

Now tested with letsencrypt-win-simple.v<IP_ADDRESS>-beta8, otherwise same config as above.
"Authorization result: valid "produces no more error message, but
there is a new error at the end of the log, see below.
Tried several runs, now the certificate fails to renew.
[DBUG] Send POST request to https://acme-staging.api.letsencrypt.org/acme/new-authz
[INFO] Authorizing (removed) using http-01 validation (FileSystem)
[INFO] Answer should now be browsable at http://(removed)/.well-known/acme-challenge/Fcr6g1DbTSD3grBR7HB0ju3GZQr2QPYJT-A3qR6Dh4I
[DBUG] Submitting answer
[DBUG] Send POST request to https://acme-staging.api.letsencrypt.org/acme/challenge/qnGIHmMMisAlMqYVeYlWzK7aD1MZurRBoXCf1wlXWcY/84083779
[INFO] Authorization result: valid
[DBUG] Deleting answer
[DBUG] Additional files or folders exist in d:\http-server-d.well-known, not deleting.
[DBUG] Certificate folder: C:\ProgramData\letsencrypt-win-simple\httpsacme-staging.api.letsencrypt.org
[DBUG] Certificate store: My
[WARN] Using cached certificate for (removed) 2017.12.28 3.04.30 ip.
[DBUG] NullReferenceException: NullReferenceException {Message="Objektin viittaukseksi ei voi määrittää objektiesiintymää.", Data=[], InnerException=null, TargetSite=LetsEncrypt.ACME.Simple.RenewResult OnRenewSuccess(Autofac.ILifetimeScope, LetsEncrypt.ACME.Simple.ScheduledRenewal), StackTrace="   kohteessa LetsEncrypt.ACME.Simple.Program.OnRenewSuccess(ILifetimeScope renewalScope, ScheduledRenewal renewal)", HelpLink=null, Source="letsencrypt", HResult=-2147467261}
[EROR] NullReferenceException: Objektin viittaukseksi ei voi määrittää objektiesiintymää.
[EROR] Renewal for (removed) failed, will retry on next run

I've added some more error handling and better checks around the use of cached certificates, that should hopefully fix this error. There is a new binary in the latest release. https://github.com/Lone-Coder/letsencrypt-win-simple/releases/tag/v<IP_ADDRESS>-beta8

Tested with letsencrypt-win-simple.v<IP_ADDRESS>-beta8.1, otherwise same config as above.
Now log is clean from previous errors, but new certificates are not stored if previous certificate files exist in c:\ProgramData\letsencrypt-win-simple\httpsacme-staging.api.letsencrypt.org\ . If I delete all files except Registration and Signer, then new certificate files are saved.
Here are parts of the log output. As you can see, case 1 does not save certicate, case 2 does.
Case 1) Previous files exist
 [DBUG] Certificate folder: C:\ProgramData\letsencrypt-win-simple\httpsacme-staging.api.letsencrypt.org
 [DBUG] Certificate store: My
 [WARN] Using cached certificate for ht23.dy.fi 2017.12.28 6.01.48 ip.
 [INFO] Installing with Run external script...
 [WARN] No script configured.
 [INFO] Renewal for ht23.dy.fi succeeded
 [INFO] Next renewal scheduled at 2018.2.21 4.01.48 ip.
Case 2) Previous files deleted
 [DBUG] Certificate folder: C:\ProgramData\letsencrypt-win-simple\httpsacme-staging.api.letsencrypt.org
 [DBUG] Certificate store: My
 [DBUG] RSAKeyBits: 2048
 [INFO] Requesting certificate ht23.dy.fi 2017.12.28 6.03.36 ip.
 [DBUG] Send POST request to https://acme-staging.api.letsencrypt.org/acme/new-cert
 [INFO] Saving certificate to C:\ProgramData\letsencrypt-win-simple\httpsacme-staging.api.letsencrypt.org
 [DBUG] Set private key exportable
 [INFO] Installing certificate in the certificate store
 [DBUG] Opened certificate store My
 [INFO] Adding certificate ht23.dy.fi 2017.12.28 6.03.36 ip. to store My
 [VERB] CN=ht23.dy.fi - CN=Fake LE Intermediate X1 (BB7F8F3A9053A5A372CD80899A4AECC682F1FA02)
 [VERB] CN=Fake LE Intermediate X1 - CN=Fake LE Root X1 (4EEE7398C1A3DAF91DA16689DB8243927A271B9A) to CA store
 [VERB] CN=Fake LE Root X1 - CN=Fake LE Root X1 (B3F73C419DAC14711F4B97192BF89C7DEA7A7794) to AuthRoot store
 [DBUG] Closing certificate stores
 [INFO] Installing with Run external script...
 [WARN] No script configured.
 [INFO] Renewal for ht23.dy.fi succeeded
 [INFO] Next renewal scheduled at 2018.2.21 4.03.41 ip.

This is actually expected behaviour now when a cached certificate is used (and also already found in the store). Why re-import something that's already there? The installation plugins should still run though, and it seems like they do.

I'm a bit lost here. For Apache I need updated certificate and key files.
As you say

The installation plugins should still run though, and it seems like they do.

what do you mean?
On previous case 1, where can I find updated cert and key?
Or should I use some script to produce them?

There are a couple of steps to getting a certificate once validation is complete:

Check if a .pfx file already exists in the CertificatePath. If it exists and is less than 24 hours old, then it's used to avoid rate limits. Otherwise a new certificate is requested from Let's Encrypt.
Check if the certificate already exists in the target store. If it doesn't, import it.
Run installation plugins.

In your case the certificate exists in the CertificatePath, in the target store and there are no installation steps, so LEWS basically does nothing (until the 24 hours pass, then you would get a new certificate which would be valid 1 more day into the future),
So you can either change the CertificatePath to a location that Apache can access, or configure an installation step to copy the files you need over to where they're needed.

Ok. now I understand.
I was not aware of the 24 hour limit.
In my test environment, I will delete .pfx file so I can see that certificate and key files are created,
regardless whether 24 hours has passed.
And regarding the original reason for this bug report, you can close it.

Ok, thanks for using LEWS!

One more thing.
It might be a good idea to include your explanation of required step after validation into the Wiki.
I think it is not mentioned there now, and without explanation it might be a bit confusing, because the 24 hour limit overrides --forcerenewal, if I understood correctly.

There are not really any required steps, it all depends on what you want to do with the certificates. If you'd like to contribute, please feel free to add a page with instructions on how to set up LEWS with Apache, because I wouldn't know how to do that exactly myself. I'd also be happy to include a sample .bat / .ps1 script for Apache users in a future release.
The --forcerenewal switch is a fair point, I've updated some code to make that bypass the cache (with a clear warning about the possibility of hitting a rate limit.


how to draw the loss curve of the training process

Simpledet how to draw the loss curve of the training process？
I find log.txt, but how to draw?
Could you provide the code to draw the loss curve of the training process？
Thanks

How to record the loss of the training process in the log so that I can draw the loss curve

If you can access the loss print, maybe somewhere in core/detection_metric.py, then you can record a loss log, I guess.

You can write code to convert this log.txt with regex to json format so that one can directly plot loss(or other metrics) through json format files.


examples should not be installed at the top level of the Python library hierarchy

Describe the bug
I ran pip install --user cvxpy (or rather, it was pulled in by another package), and I found a directory called examples in my Python library directory.
Expected behavior
Such a directory should clearly indicate what it belongs to, either by being called cvxpy_examples or cvxpy/examples, or should not be installed at all, as it is not a necessary part of the package functionality.
Version

OS: Debian testing
CVXPY Version: 1.2.1

As you say, it's really odd.  There's just an examples directory.  I just downloaded all four wheel files for Python 3.10 from PyPI, and they all have an examples directory at the top level. However, building it from source does not include this directory. So maybe it's something about a newer or older version of setuputils or something like that causing this issue? But in this case it's probably fine to ignore it.

In setup.py, the following directories are excluded:
exclude=["doc", "examples", "cvxpy.performance_tests"])

However, since there are subdirectories in examples, these are included again. We need to exclude examples*. I'll create a PR for that.

Closed by #1804.


[python] Use numba<0.58 on release-1.6 branch

Issue and/or context: As on #1733. Until we figure out the feedstock error on https://github.com/TileDB-Inc/tiledbsoma-feedstock/pull/48, we need to stick with numba<0.58.
Changes:
Notes for Reviewer:

Codecov Report

Merging #1939 (4802efa) into release-1.6 (8616aa0) will increase coverage by 26.62%.
The diff coverage is n/a.

:exclamation: Your organization needs to install the Codecov GitHub app to enable full functionality.
Additional details and impacted files
@@               Coverage Diff                @@
##           release-1.6    #1939       +/-   ##
================================================
+ Coverage        63.11%   89.74%   +26.62%
================================================
  Files              106       34       -72
  Lines            10056     3598     -6458
================================================
- Hits              6347     3229     -3118
+ Misses            3709      369     -3340

Flag
Coverage Δ

python
89.74% <ø> (-0.03%)
:arrow_down:

r
?

Flags with carried forward coverage won't be shown. Click here to find out more.

Components
Coverage Δ

python_api
89.74% <ø> (-0.03%)
:arrow_down:

libtiledbsoma
∅ <ø> (∅)

Thanks @eddelbuettel and @nguyenv !


Fix path to kitti devkit in data preparation script

The script seems to assume that files from devkit_object.zip will be uncompressed into a folder devkit however that is not the case when using the archive from KITTI (?).

Woah, you're right. I was working with an old zipfile. Looks like they updated the README and when they recreated the zipfile they forgot the outer directory.

Fix verified. The data zipfiles don't seem to have changed, so it doesn't seem we need to update those.


Picturefill v3 alpha IE8 error

Hey guys,
Getting a  'Object deosnt support this property or method' on IE8. When debugging it's pointing to a function named 'teardownRun'.
cheers,
Ritch

@ritchieanesco Which version of picturefill are you using?

@ritchieanesco
It seems that you use 3.0, I heavily tested the code in IE8 and can not reproduce this.
It is very important that we get a testcase here. Not if this is to heavy to produce, it would be good enough if you would give me a link or a zipped version of your prototype.

@aFarkas no monkey patching, we are initialising the script via requirejs and the error comes on page load, however it seems intermittent.

@ritchieanesco
I think, I fixed your IE8 issue (Still can't reproduce, but remembered something weird IE8 is doing). Beside this error in the console. picturefill should just work fine. Please try the following branch: https://github.com/scottjehl/picturefill/tree/issue-542/dist
The fix itself is this:
https://github.com/scottjehl/picturefill/commit/79f4db48f86ec88b275b10f3ad1b377145ca755a

Picturefill still worked fine after the error. I could have possibly had 2 instances of Picturefill running, as it was required in from one module. Not sure if that would be the cause. Since i've removed the additional picturefill require i am yet to see that error in the console.

@ritchieanesco Alright, I'm gonna close this issue then since it seems fixed. If I've read that wrong, please let us know and we'll re-open this issue. Thanks!


keylime.tpm1 - ERROR

This is probably a documentation issue, not a SW bug.
Environment

OS / version: Ubuntu
Processor architecture: x86
TPM Manufacturer: SW TPM
Keylime version: unknown

Description
keylime_agent seems to default to TPM 1.2.
Expected behavior vs. actual behavior
I expect a way for the agent to target TPM 2.0.
Steps to reproduce problem

Run keylime_agent with no TPM 1.2

Relevant logs
2021-02-17 15:25:29.411 - keylime.tpm1 - INFO - Failed to call TPM 9/10 times, trying again in 1.000000 seconds...
2021-02-17 15:25:30.429 - keylime.tpm1 - ERROR - TPM appears to be in use by another application.  Keylime is incompatible with other TPM TSS applications like trousers/tpm-tools. Please uninstall or disable.
I assume tpm1 means TPM 1.2, right?  Is there a configuration option to tell the agent to use TPM 2.0.?
Is there documentation on how to configure and run the agent?

do you also have trousers and the tpm1 env set up?
Here is the code which sets the tpm version to use (Its based on tooling present)
https://github.com/keylime/keylime/blob/1d0f695c0848b001acb0ab01de46094494884506/keylime/tpm/tpm_obj.py#L22-L37
I don't honestly think the above is a good approach, but shortly TPM1 will be removed and so will this code. If you have trousers etc are you OK to remove them from the machine? If not we can find a temp workaround for you.

Thanks for the reply.  That was the issue.  I just remained getcapability.
I agree that it's not a good way to decide - forcing an uninstall.  Perhaps a command line argument to the program or an entry in the configuration file would be better?

We are just on the verge of removing tpm1 support, so this slip up won't happen again.


Learn Basic JavaScript by Building a Role Playing Game - Step 86 - fu…

…nction passed twice
this commit fixes #53624
Checklist:

[x] I have read and followed the contribution guidelines.
[x] I have read and followed the how to open a pull request guide.
[x] My pull request targets the main branch of freeCodeCamp.
[x] I have tested these changes either locally on my machine, or GitPod.

Closes #XXXXX

This is marked as first timers only.
As such, we are going to close this PR.
If you are interested in contributing, please look at the help wanted issues. 👍


Cut n paste onto a long line upsets the line numbers

should be fixed with https://github.com/csells/flutter_texteditor_linenums/pull/2

Confirmed fixed.


[1.18.2] Items taken from simple compacting drawers are different from non-compacting drawer Items

Functional Storage Version: 1.18.2-1.1.3
Titanium Version: 3.5.8
The title is self-explanatory, but I also recorded me testing it. https://youtu.be/81WNJhszpzk

Another mod is messing with the empty ItemStack and adding nbt to it, causing the drawers to get strange nbt values when moved.


what's the point of YearTwoDigits

If YearTwoDigits is used and we have 95 as input string, it would be parsed to date where year is 95, is it expected? I think most users will expect to get 1995.
i.e. it should work like JS, for example:
new Date(Date.UTC(95,1,1)).getUTCFullYear() // => 1995
but:
new Date(Date.UTC(-17,1,1)).getUTCFullYear() // => -17
Either parsing should have side effect of looking at current century to have similar behavior or otherwise having YearTwoDigits has almost no point.

I use this as more of a printing library than a parsing library so haven't run into this particular problem, but yeah, it is kinda weird. I also agree YearTwoDigits is questionable in general, I can't think of a situation in which I'd ever want to use it, because of its ambiguity.
I don't really know how to resolve it though - whatever choice we make is going to be arbitrary. 40 means what? Year 40, 1940, or 2040? If it means 2040, why is 95 not 2095? We can definitely make some rules up to get more "sensible" behaviour, but they won't suit everyone in all situations.
Call me pessimistic, but I suspect we won't be using this library in the year 2100, so I don't think we need to make it effectful either, we can just hard code the century 😄.

Looks like JS special cases the years 0-99 as being in the 1900s.

If we change
-| YearTwoDigits
+| YearTwoDigits Century

and add with some kind of Century module:
fromCentury :: Year -> Century
setYear :: Year99 -> Century -> Year
getYear99 :: Year -> Year99
getCentury :: Year -> Century

Then we can have implementation which works like this:
parse  [YearTwoDigits (Century 19)] "96" `yearEquals` 1996
parse  [YearTwoDigits (Century 19)] "96" `yearEquals` 1996
parse  [YearTwoDigits (Century 20)] "41" `yearEquals` 2041
parse  [YearTwoDigits (Century 20)] "01" `yearEquals` 2001

print [YearTwoDigits (Century 19)] (dateFromYear 1996) `shouldEqual` "96"
print [YearTwoDigits (Century 19)] (dateFromYear 1996) `shouldEqual` "96"
print [YearTwoDigits (Century 20)] (dateFromYear 2041) `shouldEqual` "41"
print [YearTwoDigits (Century 20)] (dateFromYear 2001) `shouldEqual` "01"

print [YearTwoDigits (Century 20)] (dateFromYear 1996) `shouldEqual` "1996"
print [YearTwoDigits (Century 10)] (dateFromYear 2041) `shouldEqual` "2041"

last 2 cases are a bit wrong, but it's happening because same type is used for print format and for parse format.
another option would be to use higher kinded type thing for format:
data ForamtF f =
...
| YearTwoDigits (f Unit Century)

type PickPrintFormat a b = a
type PickParseFormat a b = a
type PrintFormat = ForamtF PickPrintFormat
type ParseFormat = ForamtF PickParseFormat


tractable buffer stock problem with graph - fixed CRRA parameter

While playing with parameters in Tractable Buffer Stock I noticed that CRRA parameter is fixed in last section  in line :"CRRA = fixed(4),"  In order to allow users to work with different utilities it should be just normal variable

Thanks for posting this issue (I think in response to my request in class).  Having thought about it, I've now realized that leaving out the CRRA was intentional; it was a useful thing to show the class how to add or subtract controls.
But now that you have posted an issue, you know how to do it, so please post other issues if they come to your attention!