[bug]  Only --player-passthrough hls works correctly?

Tried this on different PCs and different streams (summit1g is just one example I used here) and get the same result.
--player-passthrough hls works correctly using mpv, no ads displayed, but unable to use twitch low latency option according to https://github.com/streamlink/streamlink-twitch-gui/wiki/Recommendations. Using anything else (standard input/named pipe/http) shows ads.
Shows ads:
streamlink.exe twitch.tv/summit1g best --twitch-proxy-playlist=http://<IP_ADDRESS>:9595,https://eu.luminous.dev,https://eu2.luminous.dev
Works correctly:
streamlink.exe twitch.tv/summit1g best --twitch-proxy-playlist=http://<IP_ADDRESS>:9595,https://eu.luminous.dev,https://eu2.luminous.dev --player-passthrough hls
Debug output that shows ads
streamlink.exe twitch.tv/summit1g best --twitch-proxy-playlist=http://<IP_ADDRESS>:9595,https://eu.luminous.dev,https://eu2.luminous.dev --loglevel trace
[11:16:54.450769][session][debug] Plugin twitch is being overridden by C:\Users\user\AppData\Roaming\streamlink\plugins\twitch.py
[11:16:54.460554][cli][debug] OS:         Windows 10
[11:16:54.460554][cli][debug] Python:     3.11.1
[11:16:54.461555][cli][debug] Streamlink: 5.1.2
[11:16:54.462394][cli][debug] Dependencies:
[11:16:54.463404][cli][debug]  certifi: 2022.12.7
[11:16:54.464396][cli][debug]  isodate: 0.6.1
[11:16:54.464396][cli][debug]  lxml: 4.9.2
[11:16:54.465398][cli][debug]  pycountry: 22.3.5
[11:16:54.467102][cli][debug]  pycryptodome: 3.16.0
[11:16:54.467102][cli][debug]  PySocks: 1.7.1
[11:16:54.468097][cli][debug]  requests: 2.28.1
[11:16:54.469098][cli][debug]  urllib3: 1.26.13
[11:16:54.469098][cli][debug]  websocket-client: 1.4.2
[11:16:54.475103][cli][debug] Arguments:
[11:16:54.475103][cli][debug]  url=twitch.tv/summit1g
[11:16:54.475103][cli][debug]  stream=['best']
[11:16:54.476111][cli][debug]  --loglevel=trace
[11:16:54.476111][cli][debug]  --player="C:\MPV\mpv.exe"
[11:16:54.478108][cli][debug]  --ffmpeg-ffmpeg=C:\Program Files\Streamlink\ffmpeg\ffmpeg.exe
[11:16:54.478875][cli][debug]  --twitch-proxy-playlist=['http://<IP_ADDRESS>:9595', 'https://eu.luminous.dev', 'https://eu2.luminous.dev']
[11:16:54.479589][cli][info] Found matching plugin twitch for URL twitch.tv/summit1g
[11:16:54.479589][plugins.twitch][debug] Getting live HLS streams for summit1g
[11:16:54.481592][plugins.twitch][info] Using playlist proxy 'http://<IP_ADDRESS>:9595'
[11:16:54.481592][plugins.twitch][debug] Playlist proxy URL: http://<IP_ADDRESS>:9595/playlist/summit1g.m3u8%3Fplayer%3Dtwitchweb%26type%3Dany%26allow_source%3Dtrue%26allow_audio_only%3Dtrue%26allow_spectre%3Dfalse%26fast_bread%3Dtrue
[11:16:54.509221][utils.l10n][debug] Language code: en_US
[11:16:55.403777][cli][info] Available streams: 160p (worst), 360p, 480p, 720p60, 936p60 (best)
[11:16:55.403777][cli][info] Opening stream: 936p60 (hls)
[11:16:55.404778][cli][info] Starting player: "C:\MPV\mpv.exe"
[11:16:55.406672][stream.hls][debug] Reloading playlist
[11:16:55.406672][cli][debug] Pre-buffering 8192 bytes
[11:16:56.072579][stream.hls][debug] First Sequence: 0; Last Sequence: 2
[11:16:56.073580][stream.hls][debug] Start offset: 0; Duration: None; Start Sequence: 0; End Sequence: None
[11:16:56.074581][stream.hls][debug] Adding segment 0 to queue
[11:16:56.075582][stream.hls][debug] Adding segment 1 to queue
[11:16:56.075582][stream.hls][debug] Adding segment 2 to queue
[11:16:56.193679][stream.hls][debug] Writing segment 0 to output
[11:16:56.194641][stream.hls][debug] Segment 0 complete
[11:16:56.195650][cli.output][debug] Opening subprocess: "C:\MPV\mpv.exe" --force-media-title=twitch.tv/summit1g -
[11:16:56.245837][stream.hls][debug] Writing segment 1 to output
[11:16:56.247840][stream.hls][debug] Segment 1 complete
[11:16:56.273031][stream.hls][debug] Writing segment 2 to output
[11:16:56.274034][stream.hls][debug] Segment 2 complete
[11:16:56.699285][cli][debug] Writing stream to output
[11:17:01.079628][stream.hls][debug] Reloading playlist
[11:17:01.148586][stream.hls][debug] Adding segment 3 to queue
[11:17:01.166767][stream.hls][debug] Writing segment 3 to output
[11:17:01.166767][stream.hls][debug] Segment 3 complete
[11:17:01.305830][cli][info] Player closed
[11:17:01.306644][stream.segmented][debug] Closing worker thread
[11:17:01.307642][stream.segmented][debug] Closing writer thread
[11:17:01.307642][stream.segmented][debug] Closing writer thread
[11:17:01.311646][cli][info] Stream ended
[11:17:01.313621][cli][info] Closing currently open stream...

After some more testing, it seems this issue is specifically with luminous-ttv. https://api.ttv.lol works correctly with/without --player-passthrough.

I reproduced this with mpv. I don't know if the bug is here or in luminous but I'm looking into it.

I can't find the bug unfortunately. It doesn't seem to be here or luminous so it may be upstream Streamlink. I have tried requesting the stream in the same exact way as the luminous browser extension and it still happens.
Since we can't really modify core Streamlink this can't be fixed. I'm going to leave this issue open in case someone else has a solution.

Unfortunately not, I'm stumped. I will stop advertising luminous support until when/if I can fix it since it doesn't seem limited to mpv and streamlink is only being used to get the URL.

Luminous works perfect for me without using player passthrough.  No ads on EU, EU2 or AS.  Using VLC

Interestingly this doesn't happen with my other project twitch-hls-client so this must be fixable 🤔


Block delete model requests if an index uses the model

Description
Adds a step in the deleteModel method within ModelDao to check if a model is in use by any indices.  If so, the delete request will fail with a new DeleteModelWhenInUseException containing the model name and the index using it.
Issues Resolved
https://github.com/opensearch-project/k-NN/issues/1343
Check List

[x] New functionality includes testing.

[x] All tests pass

[x] New functionality has been documented.

[x] New functionality has javadoc added

[x] Commits are signed as per the DCO using --signoff

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.

There doesn't seem to be any unit test updates. Does it need one? or are ModelTests unit tests?

It's a singleton node test, which is kind of halfway between a unit test and an integration test.  It's the only file we have other than bwc at the moment for testing models.

There doesn't seem to be any unit test updates. Does it need one? or are ModelTests unit tests?

It's a singleton node test, which is kind of halfway between a unit test and an integration test. It's the only file we have other than bwc at the moment for testing model logic.

I do feel unit and integration test should be there and tests like modelTests which are in a way component tests should be written whenever required. I can't see the coverage right now but please check the coverage considering the parsing of that json is getting complex

There doesn't seem to be any unit test updates. Does it need one? or are ModelTests unit tests?

It's a singleton node test, which is kind of halfway between a unit test and an integration test. It's the only file we have other than bwc at the moment for testing model logic.

I do feel unit and integration test should be there and tests like modelTests which are in a way component tests should be written whenever required. I can't see the coverage right now but please check the coverage considering the parsing of that json is getting complex

@shatejas I forgot to mention the ModelDaoTests class does have unit tests for all the methods, and I did add a unit test there.  We do also have https://github.com/opensearch-project/k-NN/blob/main/src/test/java/org/opensearch/knn/index/FaissIT.java that inherently ensures training works, although it is not specifically focused on ModelDao

I think this approach will be really expensive for clusters with a lot of indices with large mappings.
Instead, we have a couple options:

We create a separate transport action, similar to GetMappingTransportAction, that will perform the check and return true or false.
We use some kind tracking on index creation of the models in use. Did you consider this?

@heemin32 do you have any ideas?

2. We use some kind tracking on index creation of the models in use. Did you consider this?

@jmazanec15 I thought about this initially, but I was worried about potential desynchronization of the indices in use.  To accomplish this solution, we would have to add a variable (either list or set) to the ModelMetadata.  Then, the create index and delete index actions would have to be modified to make an update call to update the model in ModelDao.  I was concerned about multiple indices being created or deleted at the same time, updating the same model, and potentially overwriting an index that was added or removed in that list.  That could theoretically result in a situation where the user has deleted the index, but would be unable to delete the model.

I see, then I think a custom transport action like GetMappingsTransportAction makes sense.

I think this approach will be really expensive for clusters with a lot of indices with large mappings.
Instead, we have a couple options:

We create a separate transport action, similar to GetMappingTransportAction, that will perform the check and return true or false.
We use some kind tracking on index creation of the models in use. Did you consider this?

@heemin32 do you have any ideas?

Current implementation might have two concerns.

Scalability with large number of indices and big mappings.
Race condition. Creating a new index using the model right before the deletion of the model.

The first option won't provide any benefit. The index mapping data is maintained in cluster state metadata and it might already use GetMappingTransportAction behind the seen. For the second option, it could be more problematic when there is a inconsistency between two places where we store index-model mapping: one in new place and another in index mapping.
As 1. delete model won't be called with high frequency and 2. user can delete the index when race condition happen, we can accept those two concerns imo.

The first option won't provide any benefit. The index mapping data is maintained in cluster state metadata and it might already use GetMappingTransportAction behind the seen.

I dont think this is true. Creating our own transport action would allow us to check if the model is in use without requiring the mappings to be sent over the network. So, I think itd be much more efficient.

The first option won't provide any benefit. The index mapping data is maintained in cluster state metadata and it might already use GetMappingTransportAction behind the seen.

I dont think this is true. Creating our own transport action would allow us to check if the model is in use without requiring the mappings to be sent over the network. So, I think itd be much more efficient.

Yes. I will save some network bandwidth. To achieve that, instead of creating transport action, we can make the delete API to be handled only by coordinator node. Then, all will be handled locally.

@heemin32  Im not sure I think its worth moving delete api to cluster manager, but I do think we could just add to https://github.com/opensearch-project/k-NN/blob/main/src/main/java/org/opensearch/knn/plugin/transport/UpdateModelGraveyardTransportAction.java instead of creating a new transport action. This action already has access to the cluster metadata. It would also help provide some safety against race conditions.
@ryanbogan what do you think?

I would lean towards creating a new transport action instead of modifying the existing one, since even though they both access the cluster metadata, the actions have very different goals.  I was able to get it working locally with a new transport action, so my vote is to go with that.

@ryanbogan Right now, the purpose of model graveyard is to basically prevent a model that is in the process of being deleted from being used in the interim. This might not be the exact usage right now, but I think it is the overall purpose (@naveentatikonda correct me if Im wrong). The update to model graveyard happens first: https://github.com/opensearch-project/k-NN/blob/main/src/main/java/org/opensearch/knn/indices/ModelDao.java#L534-L535.
In other words, as long as a model is in the model graveyard, it cannot be used (if it can, it is a bug). So, if we are to add the check if it is actively being used in the graveyard metadata update, we can provide better consistency. Separating into 2 separate actions can lead to inconsistency.

@jmazanec15 so in this case, we would still want the check to happen before it's added to the graveyard so I could add it within the clusterManagerOperation.  I also need to add the indices service to that class and then change the response type to a custom one with two booleans in order to throw the proper exception on failure.

Sounds good. Play around with it a little bit, but checking before adding to model graveyard is right high-level approach from consistency perspective. I think we should do it.

then change the response type to a custom one with two booleans in order to throw the proper exception on failure.

If the index is in use, it should throw an exception. Why do we need to change the response type?

We need to tell the user which index is using the model so they know which one to delete.  The custom response I created for a new transport action had two parameters in the response: a boolean representing if the model is in use, and a string representing the index name using the model.

Why cant the indices be in the exception message?

Ah right I could just use onFailure with the exception message instead.  I was throwing the exception in ModelDao once the response was returned.

@heemin32 Im not sure I think its worth moving delete api to cluster manager, but I do think we could just add to https://github.com/opensearch-project/k-NN/blob/main/src/main/java/org/opensearch/knn/plugin/transport/UpdateModelGraveyardTransportAction.java instead of creating a new transport action. This action already has access to the cluster metadata. It would also help provide some safety against race conditions.
@ryanbogan what do you think?

What I meant by that is, we can just make DeleteModelTransportAction to extend TransportClusterManagerNodeAction and implement the logic inside clusterManagerOperation. I guess we might be talking about same thing though.
In my understanding there is 1:1 mapping between rest api and transport action in general. I cannot quite understand how delete model api can utilize UpdateModelGraveyardTransportAction unless we are going to map delete model and update modelgraveyard api to single UpdateModelGraveyardTransportAction which I don't think what you meant?

In my understanding there is 1:1 mapping between rest api and transport action in general

End-to-end, a rest API may make multiple transport calls and require multiple transport actions. Think about search for instance.

In my understanding there is 1:1 mapping between rest api and transport action in general

End-to-end, a rest API may make multiple transport calls and require multiple transport actions. Think about search for instance.

Yeah. You are right. Was confused with ActionType to Action mapping. Thanks for correction.
Agree that we can check the usage of model before putting the model into graveyard.

@ryanbogan Right now, the purpose of model graveyard is to basically prevent a model that is in the process of being deleted from being used in the interim. This might not be the exact usage right now, but I think it is the overall purpose (@naveentatikonda correct me if Im wrong). The update to model graveyard happens first: https://github.com/opensearch-project/k-NN/blob/main/src/main/java/org/opensearch/knn/indices/ModelDao.java#L534-L535.
In other words, as long as a model is in the model graveyard, it cannot be used (if it can, it is a bug). So, if we are to add the check if it is actively being used in the graveyard metadata update, we can provide better consistency. Separating into 2 separate actions can lead to inconsistency.
So, I actually think that the best place for the check would be in the model graveyard update location.

Sorry for the late response. @jmazanec15 your explanation is correct

Linux tests all passed on my dev desktop

Skipping changelog because release notes for 2.15 are already out.  I update the release notes accordingly


Use Unique Names for Resources in xDS Interop Tests

The diff is pretty large since I had to increase the indent for a large chunk of code, but I didn't change anything within the increased indent -- just around it. If this code were longer for this world, I would suggest we do some refactoring to make it a bit more maintainable but given that we're planning on switching to the xds_k8s framework, it's probably not worth it at this point.

Manually triggered run.


ntree script

Add a ntree script to show the tree of the notes folder in your KN
path. Check to ensure tree is installed within the script.
Also, add tree installation to the install script.

Script created and pushed to main


Adding items to the page with ServerLoad

I cloned the repo and ran the demo and tried to modifie it so that I can ServerLoad items one by one, not just swap the ServerLoad
I modified this block:
https://github.com/pydantic/FastUI/blob/106d6c500acc40d051fcf4ea817ff717c1b1e0c7/demo/components_list.py#L123-L140
... like this:
        c.Div(
            components=[
                c.Heading(text="Server Load SSE", level=2),
                c.Markdown(text="`ServerLoad` can also be used to load content from an SSE stream."),
                c.Button(text="Load SSE content", on_click=PageEvent(name="server-load-sse")),
                c.Div(
                    components=[
                        c.ServerLoad(
                            path="/components/sse",
                            sse=True,
                            load_trigger=PageEvent(name="server-load-sse"),
                            components=[c.Text(text="before")],
                        ),
                    ],
                    class_name="my-2 p-2 border rounded",
                ),
            ],
            class_name="border-top mt-3 pt-1",
        ),

And I modified this block:
https://github.com/pydantic/FastUI/blob/106d6c500acc40d051fcf4ea817ff717c1b1e0c7/demo/components_list.py#L220-L223
... like this:
@router.get("/dynamic-content", response_model=FastUI, response_model_exclude_none=True)
async def modal_view() -> list[AnyComponent]:
    await asyncio.sleep(0.5)
    return [
        c.Paragraph(
            text="This is some dynamic content. Open devtools to see me being fetched from the server."),
        c.ServerLoad(
            path="/components/dynamic-content",
            load_trigger=PageEvent(name="server-load"),
            components=[c.Text(text="before")],
        ),
    ]

It visually works but there is something wrong with the HTML Source Code

It's probably not a "bug" or something like that, it probably works as it should be and I probably using it wrong, just asking how to do it? Do what? This...

What I'm implementing? Let's say a simple TODO app, creating tasks but I don't want to get the entire demo_page and re-render everything, just append the new item...

I'm not clear what you're asking for?

I perhaps I was off-topic a bit at the beginning. Also, I hope I could explain the problem clearly this time. Sorry about my poor English. 🙏
Forget everything I said before this line: "It visually works but there is something wrong with the HTML Source Code".
I have sketched an example here:
from __future__ import annotations as _annotations

import random
import time

from fastapi import FastAPI
from fastapi.responses import HTMLResponse
from fastui import AnyComponent, FastUI, prebuilt_html
from fastui import components as c
from fastui.events import GoToEvent, PageEvent

def Master(*components: AnyComponent, title: str | None = None) -> list[AnyComponent]:
    return [
        c.PageTitle(text="Lotto Numbers Generator"),
        c.Navbar(
            title="Still Lotto Numbers Generator",
            title_event=GoToEvent(url="/"),
        ),
        c.Page(
            components=[
                *((c.Heading(text=title),) if title else ()),
                *components,
            ],
        ),
    ]

app = FastAPI()

@app.get("/api/", response_model=FastUI, response_model_exclude_none=True)
def components_view() -> list[AnyComponent]:
    return Master(
        c.Div(
            components=[
                c.Heading(text="Lotto Numbers Generator", level=2),
                c.Paragraph(text="Generate lotto numbers for your next game."),
                c.Button(text="Generate a lotto number!", on_click=PageEvent(name="add-number")),
                # When the button is clicked, the client will send a request to `/api/add-number`
                # As expected, The response will be rendered in the `ServerLoad` component below.
                c.Div(
                    components=[
                        c.ServerLoad(
                            path="/add-number",
                            load_trigger=PageEvent(name="add-number"),
                            components=[c.Paragraph(text="What are you waiting for?")],
                        ),
                    ],
                    class_name="py-2",
                ),
            ],
            class_name="border-top mt-3 pt-1",
        ),
        title="Quite simple and Understandable Example",
    )

@app.get("/api/add-number", response_model=FastUI, response_model_exclude_none=True)
async def modal_view() -> list[AnyComponent]:
    time.sleep(0.5)
    return [
        c.Paragraph(
            text=f"Your lotto number is {random.randint(1, 99)}!",
        ),
        # We are sending with another `ServerLoad` component.
        # This will help us to keep the previous button working.
        c.ServerLoad(
            path="/add-number",
            load_trigger=PageEvent(name="add-number"),
            components=[c.Paragraph(text="Ready for another one?")],
        ),
    ]

@app.get("/{path:path}")
async def html_landing() -> HTMLResponse:
    """Simple HTML page which serves the React app, comes last as it matches all paths."""
    return HTMLResponse(prebuilt_html(title="FastUI Demo"))

When we run this code, it'll generate the following HTML:

What are you waiting for?

When we click the button, re-rendering will happen and the following HTML will be generated:

Your lotto number is 36!

Ready for another one?

innerHTML of div.py-2 is replaced with the incoming component's HTML.

When we click the button again, re-rendering will happen and the following HTML will be generated:

Your lotto number is 36!

Your lotto number is 13!

Ready for another one?

Ready for another one?
 element from the previous code block is now replaced with the incoming component's HTML.

When we click the button again and again, let's do 10, re-rendering will happen and the following HTML will be generated:

Your lotto number is 36!

Your lotto number is 13!

Your lotto number is 82!

Your lotto number is 87!

Your lotto number is 94!

Your lotto number is 51!

Your lotto number is 48!

Your lotto number is 65!

Your lotto number is 2!

Your lotto number is 90!

Your lotto number is 52!

Your lotto number is 10!

Ready for another one?

As you can see, it's nesting the components. This might be the expected behavior, but I'm not sure since I don't know any react ReactJS and there is no documentation about it. So excited to see the documentation. 🤩

The problem I see is nesting the components over and over. I might be implementing it wrong, but I don't know how to achieve the expected behavior.
The expected behavior is something like this:

Lotto Numbers Generator

Generate lotto numbers for your next game.

    <button class="btn btn-primary">Generate a lotto number!</button>

Your lotto number is 36!

Your lotto number is 13!

Your lotto number is 82!

Your lotto number is 87!

Your lotto number is 94!

Your lotto number is 51!

Your lotto number is 48!

Your lotto number is 65!

Your lotto number is 2!

Your lotto number is 90!

Your lotto number is 52!

Your lotto number is 10!

Ready for another one?

Instead of nesting the elements, I want to add them to the same level. Can you please help me to achieve this behavior?
I hope I could explain the problem clearly. Thank you for your time. 🙏

I think this might be fixed on #61.

I think this might be fixed on #61.

I can see that it's not merged yet.
Is this a bug or an unwanted behavior?

I just found something. Can you run this example, please? If you navigate to the / endpoint, you'll see that there is a loop.
from __future__ import annotations as _annotations

import random
import time

from fastapi import FastAPI
from fastapi.responses import HTMLResponse
from fastui import AnyComponent, FastUI, prebuilt_html
from fastui import components as c
from fastui.events import GoToEvent, PageEvent

def Master(*components: AnyComponent, title: str | None = None) -> list[AnyComponent]:
    return [
        c.PageTitle(text="Lotto Numbers Generator"),
        c.Navbar(
            title="Still Lotto Numbers Generator",
            title_event=GoToEvent(url="/"),
        ),
        c.Page(
            components=[
                *((c.Heading(text=title),) if title else ()),
                *components,
            ],
        ),
    ]

app = FastAPI()

@app.get("/api/", response_model=FastUI, response_model_exclude_none=True)
def components_view() -> list[AnyComponent]:
    return Master(
        c.Div(
            components=[
                c.Heading(text="Lotto Numbers Generator", level=2),
                c.Paragraph(text="Generate lotto numbers for your next game."),
                c.Button(text="Generate a lotto number!", on_click=PageEvent(name="add-number")),
                # When the button is clicked, the client will send a request to `/api/add-number`
                # The response will be rendered in the `ServerLoad` component below, as expected.
                c.Div(
                    components=[
                        c.ServerLoad(
                            path="/add-number",
                            load_trigger=PageEvent(name="add-number"),
                        ),
                    ],
                    class_name="py-2",
                ),
            ],
            class_name="border-top mt-3 pt-1",
        ),
        title="Quite simple and Understandable Example",
    )

@app.get("/api/add-number", response_model=FastUI, response_model_exclude_none=True)
async def modal_view() -> list[AnyComponent]:
    time.sleep(0.5)
    return [
        c.Paragraph(
            text=f"Your lotto number is {random.randint(1, 99)}!",
        ),
        # We are sending with another `ServerLoad` component.
        # This will help us to keep the previous button working.
        c.ServerLoad(
            path="/add-number",
            load_trigger=PageEvent(name="add-number"),
        ),
    ]

@app.get("/{path:path}")
async def html_landing() -> HTMLResponse:
    """Simple HTML page which serves the React app, comes last as it matches all paths."""
    return HTMLResponse(prebuilt_html(title="FastUI Demo"))

0.4.0 fixed this one successfully.


Move ASN parsing from net.Net to new class asn.IPASN

Parsing should be removed from the following, and only return the raw result like the other functions in net.Net:

net.Net.get_asn_dns()
net.Net.get_asn_whois()
net.Net.get_asn_http()

Other changes:

Move net.Net.lookup_asn() to asn.IPASN.lookup() and add inc_raw argument
Create _parse_fields_dns(), _parse_fields_whois(), _parse_fields_http() in asn.IPASN
Change ipwhois.IPWhois.lookup_whois() and ipwhois.IPWhois.lookup_rdap() to use asn.IPASN
Update tests

Labelling this as both a bug and enhancement as net.Net.lookup_asn() always returns a response of None at position 1 of the tuple.

Pending merge with #149

Merged in #159


Production deploy

:tada: This PR is included in version 1.4.0 :tada:
The release is available on GitHub release
Your semantic-release bot :package::rocket:


[Refactor] I want to refactor and add js docs comment inside common/utils methods exclude commonUtils.js

File Name
src/common/utils
Reason for Refactoring the Code
General reasons:

Readability: The code lacks readability due to non-descriptive variable names and a lack of clear structure.
Maintainability: The code is not easily maintainable, as changing the date formatting would require modifications in multiple places.
Performance: The code is not optimized for performance, with potentially costly operations like splitting the date string into an array and incorrect date object instantiation.

Individual file reasons:

In coverImageUtil.js will add the following

error handling
js docs comment missing

In fakeUser.js will add the following

Avoid unnecessary imports: Since faker.image.urlLoremFlickr is deprecated and faker.image provides other image generators, I replaced it with faker.image.nature() for a cleaner solution.
Removed redundant Array.from(Array()): Simplified array generation using Array(THRESHOLD).fill(null).map(...).
js docs comment

In formatCount.ts will add the following

DRY (Don't Repeat Yourself): Avoids repetitive parsing of the viewCount.
Early return in formatViewCount: Added a return for cases where the viewCount is less than 1,000.
Optimized handling for duration: Simplified the construction of the formatted time string.
js docs comment

Record

[X] I have checked the existing issues
[X] I have read the Contributing Guidelines
[X] I agree to follow this project's Code of Conduct
[X] I want to work on this issue
[X] I am a Hacktoberfest contributor

sure assigned to you

Thanks for your contribution @saddamhr 🙌


Ideas to use abstract class replacer in config way

Faster to bootstrap:
# symfony33.yml
rectors:
    ClassReplacer:
        OldClass: NewClass

It would also make change more transparent and easy to scale - adding new class is now easy.
It's not worth writing custom class and tests, since it only uses AbstractClassReplacerRector over and over again.
What do you think @grogy?

This would be the result: https://github.com/RectorPHP/Rector/pull/70/commits/51b06ef2c5dcb32d8a11aa867283b4af360fd9af#diff-9c67ef4593c1275defc61120eff49b2c

Ref #71

Ref #73

Todo

[ ] document in docs: How to write Rectors → Class or method replacement in config


!str Eagerly fails flow if the future is already failed.

If the future is already failed, it will fail the flow even if there is no downstream demands now.
refs: https://github.com/akka/akka/pull/31728
Which was reported first in akka/akka gitter
This is a behavior change, eagarly failing align with the FailedSource.

oops, will close:)


support host

some shadowsocks server providers provide a host as server address.

Hi, @jjm2473 ,
I would suggest just switching to using current rewritten version of luci-app-shadowsocks-libev.  The 17.01 branch is soon to be EOL.
However, if you are still interested in seeing this merged, please consider rewording the commit subject to something like shadowsocks-libev: validate server address as "host" type and sign off the commit.  Thank you.


Is it actually alive project or not?

I tried to run it on Windows, but cannot do it at all.

Which Python version are you using? With Python 3.8 and later it's not working (lower versions I didn't try).
Installing the requirements is kind of impossible task. In general, packages referencing different versions of numpy, scipy, requests...
Tried also forks from the pull requests, but both (Docker and Windows specific build not working)

I met the same problem. I cannot fix the environment with all kinds of versionsof numpy,pillow.....

There is so much error in my environment, I can't run this repo on A100.


Avoid interrupting by Error: stdout maxBuffer exceeded

The(Emitted value instead of an instance of Error) is Error: stdout maxBuffer exceeded.

To verify this issue, you can just set a very small value for the maxBuffer. The default value is 200*1024 according to the node doc, I don't know it is a good idea to set to Infinity. Btw, use child_process.spawn has no such problem.

Published as v1.4.2


Feature: log error custom attributes

Summary
This change allows custom attributes to be passed to the logError function.
Testing Plan
Tests have been added to verify that custom attributes are included on the custom event logged, and that the values are sanitized.

Thanks for the PR @pdeona!  I'll review once I get some time on my plate...appreciate the initiative!

@rmi22186 thanks, let me know if you’d like me to make any changes!


Refactor CI script and use repo as output cache

LGTM

Thanks.

Is this using git-lfs?

No, but then again I don't think any of our noto-* repositories are.


Add Security Settings new API version supporting AlertSyncSettings

MSFT employees can try out our new experience at OpenAPI Hub  - one location for using our validation tools and finding your workflow.

Changelog
Please ensure to add changelog with this PR by answering the following questions.

What's the purpose of the update?

[ ] new service onboarding
[x] new API version
[ ] update existing version for new feature
[ ] update existing version to fix swagger quality issue in s360
[ ] Other, please clarify

When you are targeting to deploy new service/feature to public regions? Please provide date, or month to public if date is not available yet.
When you expect to publish swagger? Please provide date, or month to public if date is not available yet.
If it's an update to existing version,  please select SDKs of specific language and CLIs that require refresh after swagger is published.

[ ] SDK of .NET (need service team to ensure code readiness)
[ ] SDK of Python
[ ] SDK of Java
[ ] SDK of Js
[ ] SDK of Go
[ ] PowerShell
[ ] CLI
[ ] Terraform
[ ] No, no need to refresh for updates in this PR

Contribution checklist:

[x] I commit to follow the Breaking Change Policy of "no breaking changes"
[x] I have reviewed the documentation for the workflow.
[x] Validation tools were run on swagger spec(s) and errors have all been fixed in this PR. How to fix?

If any further question about AME onboarding or validation tools, please view the FAQ.
ARM API Review Checklist

[x] Ensure to check this box if one of the following scenarios meet updates in the PR, so that label “WaitForARMFeedback” will be added automatically to involve ARM API Review. Failure to comply may result in delays for manifest application. Note this does not apply to data plane APIs, all “removals” and “adding a new property” no more require ARM API review.

Adding new API(s)
Adding a new API version
[ ] Ensure to copy the existing version into new directory structure for first commit (including refactoring) and then push new changes including version updates in separate commits. This is required to review the changes efficiently.
Adding a new service

[x] Please ensure you've reviewed following guidelines including ARM resource provider contract and REST guidelines. Estimated time (4 hours). This is required before you can request review from ARM API Review board.

[x] If you are blocked on ARM review and want to get the PR merged with urgency, please get the ARM oncall for reviews (RP Manifest Approvers team under Azure Resource Manager service) from IcM and reach out to them.

Breaking Change Review Checklist
If there are following updates in the PR, ensure to request an approval from Breaking Change Review Board as defined in the Breaking Change Policy.

[ ] Removing API(s) in stable version
[ ] Removing properties in stable version
[ ] Removing API version(s) in stable version
[ ] Updating API in stable or public preview version with Breaking Change Validation errors
[ ] Updating API(s) in public preview over 1 year (refer to Retirement of Previews)

Action: to initiate an evaluation of the breaking change, create a new intake using the template for breaking changes. Addition details on the process and office hours are on the Breaking change Wiki.
Please follow the link to find more details on PR review process.

@ruowan
can you please look at this PR?
opened a ticket about the test that relates to breaking change:
https://msazure.visualstudio.com/One/_workitems/edit/9912842

Hi, You are adding a new api-version. Please wait for arm review

Signed off from ARM side, added ARMSignedOff label.
I see 'Cross Version Breaking Change' check failed for your PR. Please follow up with breaking change team for signoff.

@ruowan Hi ruowan, we got signoff from ARM team and breaking change team.
Is this PR ready for merge once i'll remove the "DoNotMerg" flag? How is the merge process should be? who is responsible for this merge?

@ArcturusZhang  Could you help to take a look at the SDK track2 breaking change.

/azp run


Deploy Checklist: New Expensify 2022-08-26

Release Version: 1.1.92-0
Compare Changes: https://github.com/Expensify/App/compare/production...staging
This release contains changes from the following pull requests:

[x] https://github.com/Expensify/App/pull/10374
[ ] https://github.com/Expensify/App/pull/10478
[x] https://github.com/Expensify/App/pull/10591

Deployer verifications:

[ ] I checked the App Timing Dashboard and verified this release does not cause a noticeable performance regression.
[ ] I checked Firebase Crashlytics and verified that this release does not introduce any new crashes.

cc @Expensify/applauseleads

:rocket: All staging deploys are complete, @Expensify/applauseleads please begin QA on version https://github.com/Expensify/App/releases/tag/1.1.92-0 :rocket:

@sketchydroide https://github.com/Expensify/App/pull/10478#issuecomment-1228553185

@sketchydroide
Regression is completed
Issues logged
https://github.com/Expensify/App/issues/10601
https://github.com/Expensify/App/issues/10602
https://github.com/Expensify/App/issues/10604
https://github.com/Expensify/App/issues/10605
https://github.com/Expensify/App/issues/10606
https://github.com/Expensify/App/issues/10607
https://github.com/Expensify/App/issues/10608
https://github.com/Expensify/App/issues/10609
https://github.com/Expensify/App/issues/10610

@sketchydroide Let's make this your top priority this AM in Europe.

Per discussion https://expensify.slack.com/archives/C03TQ48KC/p1661759463013119, https://github.com/Expensify/App/pull/10478 is now "No QA" so checking it off.

:shipit:


Add CI builds

A CI system should be setup to perform builds of dnsbench for releases. Travis may be a good option.

Replaced by https://github.com/AskMediaGroup/dnsbench/issues/3


New Borders data process: planning issue

Here's what we said in latest scope:

The current approach uses the same method as OSM, consuming borders from Natural Earth as a totally separate, nondiffed process. It would be much better to draw borders directly form OHM, since these are likely to be a main element of interest to OHM mappers. Here's the approach:

Create IMPOSM 3 mapping for borders including generalization
Modify OpenHIstoricalTiles vectiles schema to ingest borders
Use those in carto display, dealing with double overlap borders, so hard to use dashed lines, so skip those
Remove the OSM-borders tool

Seth do you think these are specific enough that we can just treat 1-4 as distinct issues, or should we break down further?

Yes, 4 distinct issues sounds right to me, in that order, too.

Ok, those are made! 47 and 48 I wasn't super sure if those should be yours or Gregors, so left them unassigned for now. Can go whichever way makes most sense.

Sounds good, thanks!!


[$250] LHN-Archived workspace shows green dot in LHN.

If you haven’t already, check out our contributing guidelines for onboarding and email<EMAIL_ADDRESS>to request to join our Slack channel!

Version Number: 9.0.10
Reproducible in staging?: Y
Reproducible in production?: N
If this was caught during regression testing, add the test name, ID and link from TestRail: https://expensify.testrail.io/index.php?/tests/view/4751910
Logs: https://stackoverflow.com/c/expensify/questions/4856
Issue reported by: Applause-Internal team
Action Performed:

Launch app
Tap fab - create a new workspace
Tap on workspace chat
Submit a expense using plus icon near compose
Navite to LHN and note green dot next to workspace chat
Tap profile icon -- workspaces -- workspace
Tap 3 dots next to workspace and delete the workspace
Navigate to LHN

Expected Result:
Archived workspace must not show green dot in LHN.
Actual Result:
Archived workspace shows green dot in LHN.
Workaround:
Unknown
Platforms:

Which of our officially supported platforms is this issue occurring on?

[x] Android: Native
[ ] Android: mWeb Chrome
[ ] iOS: Native
[ ] iOS: mWeb Safari
[ ] MacOS: Chrome / Safari
[ ] MacOS: Desktop

Screenshots/Videos
https://github.com/user-attachments/assets/f98801f1-2905-46ae-b11d-261609611008

View all open jobs on GitHub
Upwork Automation - Do Not Edit

Upwork Job URL: https://www.upwork.com/jobs/~017beae0c789f3f2ea
Upwork Job ID:<PHONE_NUMBER>268923324
Last Price Increase: 2024-07-26

Issue OwnerCurrent Issue Owner: @situchan

We think this issue might be related to the  #vip-vsb

Production
https://github.com/user-attachments/assets/d97f5dcf-f350-46a6-aac6-120b7f259aa9

Discussing here
This is a consequence of the changes we made to archiving reports; when the workspace chat is archived, the expense reports are not closed but only marked as archived. So I think we need to find a solution for this, but it does not have to be a blocker imho

@mountiny is this an external fix?

Still not clear, asked what is the conclusion here https://expensify.slack.com/archives/C01GTK53T8Q/p1721948318212529?thread_ts=1721641499.655229&cid=C01GTK53T8Q

I just checked the code and we do currently check if the report is archived before showing a green dot indicator on the LHN. And we use the isArchived rNVP to do that so I'm not too sure what's going wrong.
Also, I followed the reproduction steps and I'm not able to reproduce this on mac chrome:

I am still able to reproduce this. Sending it to External to hide the GBR when the workspace is deleted and workspace chat is archived.

I was able to reproduce this on Firefox but not on Chrome.

@situchan Do you have an android device? Can you try reproducing this locally either on Android or Firefox?

Proposal
Please re-state the problem that we are trying to solve in this issue.
Archived workspace shows green dot in LHN.
What is the root cause of that problem?
In LHN, we use requiresAttentionFromCurrentUser  function to check whether the user has require action
https://github.com/Expensify/App/blob/750c34eca1531a48ace4fd5aca24caf3398d9176/src/components/LHNOptionsList/OptionRowLHN.tsx#L85
And in this function, we return early if the report is archived
https://github.com/Expensify/App/blob/750c34eca1531a48ace4fd5aca24caf3398d9176/src/libs/ReportUtils.ts#L2400
But isArchivedRoom function only returns true if report. private_isArchived is not empty
https://github.com/Expensify/App/blob/750c34eca1531a48ace4fd5aca24caf3398d9176/src/libs/ReportUtils.ts#L1314
For LHN optionOrReport only has isArchived field so requiresAttentionFromCurrentUser function still returns true
What changes do you think we should make in order to solve the problem?
We should change this function to return true if report.isArchived is true
function isArchivedRoom(report: OnyxInputOrEntry<Report> | OptionData, reportNameValuePairs?: OnyxInputOrEntry<ReportNameValuePairs>): boolean {
    return !!report?.private_isArchived || (report && 'isArchivedRoom' in report && report.isArchivedRoom);
}

https://github.com/Expensify/App/blob/750c34eca1531a48ace4fd5aca24caf3398d9176/src/libs/ReportUtils.ts#L1314
What alternative solutions did you explore? (Optional)

Hm, I'm not sure if that is the optimal solution. Here are my thoughts: optionItem is of type OptionData which includes Report which has the private_isArchived property. I think we might just not be updating it properly based on changes to Onyx. We do update report here but we're passing in optionItem into requiresAttentionFromCurrentUser.

@srikarparsi We can have another solution: we can return an extra field in getOptionData by calling requiresAttentionFromCurrentUser function using the report data.
https://github.com/Expensify/App/blob/1908bd183b8d1953d81b69ce074c172f30826f90/src/libs/SidebarUtils.ts#L238

Updated proposal

Add alternative solution based on this comment https://github.com/Expensify/App/issues/45881#issuecomment-2253613862

Hi @situchan, do you think you could take a look at these proposals. @cretadn22's proposal seems like it would work to me but I haven't tested it.

@srikarparsi we used the report data here to check the report is archived or not and we assign it to isArchivedRoom field of optionItem in LHN so I don't think we need to add an extra field private_isArchived. What do you think about my alternative solution?
https://github.com/Expensify/App/blob/98d8a5ae4bb52539669f79e007246417eb8c8f1e/src/libs/SidebarUtils.ts#L310

Additional information, this bug also reproduces on Web
https://github.com/user-attachments/assets/4b976e6d-a7fd-4ba9-a9de-9b7bb3ed32bd

Hm, I'm not really sure about the alternate solution. I don't think that change is needed?
I feel like the most straightforward solution is changing this line to
result.private_isArchived = report.private_isArchived;
But I'll let @situchan weigh in here before proceeding in case there's something I'm missing.

Thanks for your feedback. As I mentioned above, result.isArchivedRoom is already used ReportUtils.isArchivedRoom(report, reportNameValuePairs) to check whether the report is deleted. So if we want to have a solution to simply check the report is archived or not we can use optionOrReport.isArchivedRoom here and no need to update or add any other field. Updated proposal  to include this solution.
if (
    isArchivedRoom(optionOrReport, getReportNameValuePairs(optionOrReport?.reportID)) || ('isArchivedRoom' in optionOrReport && optionOrReport.isArchivedRoom) ||
    isArchivedRoom(getReportOrDraftReport(optionOrReport.parentReportID), getReportNameValuePairs(optionOrReport?.reportID))
) {
    return false;
}

https://github.com/Expensify/App/blob/98d8a5ae4bb52539669f79e007246417eb8c8f1e/src/libs/ReportUtils.ts#L2418-L2419

reviewing today

@srikarparsi I will let you handle this GH since you seem to have context over it. Thanks.

Add more explanations about my proposal:

If we get isArchivedRoom here we only need to call isArchivedRoom function one time and we can reuse this as we do here.

And requiresAttentionFromCurrentUser also accepts optionOrReport with type OptionData. So we can use isArchivedRoom here if this field exists in optionOrReport otherwise use isArchivedRoom function. With this, we can also reduce the unnecessary calling isArchivedRoom and getReportNameValuePairs function here
https://github.com/Expensify/App/blob/750c34eca1531a48ace4fd5aca24caf3398d9176/src/libs/SidebarUtils.ts#L310

If we only want to accept Report type in requiresAttentionFromCurrentUser function, my alternative solution already suggested this

I don't like passing optionItem to ReportUtils.isArchivedRoom(report: OnyxInputOrEntry<Report>) in current codebase. It's against TS.
result.private_isArchived = report.private_isArchived; - this is risky (might cause unexpected regression) since result.isArchived already used in many places.

using optionItem.isArchivedRoom in requiresAttentionFromCurrentUser is safe and simplest solution

I am 👍 on ^ (@nkdengineer's alternative solution 2)

I will try to get to this tomorrow, in the meanwhile @situchan can you please take a look at @cretadn22's comment?

We're close

Reviewed both and I'm still in favor of @cretadn22's proposal. The OptionData type currently has two properties that both refer to the same data: isArchivedRoom and private_isArchived (from the Report type). We should only have one property for a single piece of data and should have removed isArchivedRoom from OptionData when we introduced private_isArchived to Report because OptionData "extends" Report.
As for the risky and might cause regressions point, we should remove isArchivedRoom from OptionData so that type checks can help and can also search for something on the lines of "isArchivedRoom = ".

@srikarparsi Thanks for your feedback. I still have a concern here. report.private_isArchived is only a temporary here https://github.com/Expensify/App/pull/45568 while isArchivedRoom always correct even we will be removed in the further since it's used isArchivedRoom function.
Finally, I'm happy with your decision.

Yeah I see what you're saying but I don't think we should ever have two properties that point to the same value (private_isArchived and isArchivedRoom in OptionReport). I agree that switching over to private_isArchived will require more changes once we switch private_isArchived to be a part of the reportNameValuePairs collection but I think it's a better approach as it avoids redundant variables.

Thanks.

@situchan @cretadn22 paymetns sent and contracts ended - thank you! 🎉


[add][integrate] prettier for formatting

Nice job with prettier.

Should have used and extended github.com/pavanjadhaw/prettier-config I guess


The terminal shell "my folder" CWD does not exist

Issue Type: Bug
New install of VS Code with Platform IO extension on Win10 with domain connected user account.
Create an ESP32 project from PIO
Try to build project.

Executing task: C:\Users\me\.platformio\penv\Scripts\platformio.exe run <
The terminal shell CWD "\\DOMAINSERVER\RedirectedFolders\me\My Documents\PlatformIO\Projects\WAYO_CD" does not exist

launch.json had

"executable": "/DOMAINSERVER/RedirectedFolders/me/My Documents/PlatformIO/Projects/WAYO_CD/.pio/build/esp32dev/firmware.elf",
"toolchainBinDir": "C:/Users/me/.platformio/packages/toolchain-xtensa32/bin",

I changed /DOMAINSERVER/RedirectedFolders to C:/me :no change
Tried setting terminal.integrated.cwd to c:\temp : no change
Disabled PIO :no change
I can't find where VSC is getting the  /DOMAINSERVER/RedirectedFolders/me from

note DOMAINSERVER and me are redacted names.

VS Code version: Code 1.40.2 (f359dd69833dd8800b54d458f6d37ab7c78df520, 2019-11-25T14:54:45.096Z)
OS version: Windows_NT x64 10.0.17763

System Info

Item
Value

CPUs
Intel(R) Core(TM) i7-7700HQ CPU @ 2.80GHz (8 x 2808)

GPU Status
2d_canvas: enabledflash_3d: enabledflash_stage3d: enabledflash_stage3d_baseline: enabledgpu_compositing: enabledmetal: disabled_offmultiple_raster_threads: enabled_onoop_rasterization: disabled_offprotected_video_decode: enabledrasterization: enabledskia_renderer: disabled_offsurface_control: disabled_offsurface_synchronization: enabled_onvideo_decode: enabledviz_display_compositor: enabled_onviz_hit_test_surface_layer: disabled_offwebgl: enabledwebgl2: enabled

Load (avg)
undefined

Memory (System)
15.82GB (4.57GB free)

Process Argv

Screen Reader
no

VM
0%

Extensions (2)

Extension
Author (truncated)
Version

cpptools
ms-
0.26.2

platformio-ide
pla
1.10.0

I get the same error.

I get the same error.

Why is this, what is going wrong ?

@Brolly0204 What extensions do you have installed ?
@weinand You wouldn't know what extension, since you closed the issue, it must be known what extension ?

The C++ extension "cpptools"

Why do you say "cpptools" is the problem when the Executing task is C:\Users\me.platformio\penv\Scripts\platformio.exe

@weinand I don't even have that extension installed.

Then better explain what the error you are seeing is.

As mentioned here.

The PIO scripts are having problems with windows folder redirections for domain connected users.
A workaround for this problem is when using the PIO wizard to create a new project, untick 'Location' and specifiy a local non user file path such as "c:\pio\myapp"

@alexr00 is this a Task issue or an issue with the platformio-ide extension?

@labnet7 Who are you directly replying to, anyone; or everyone ?

I was replying to myself as the OP. The issue seems to be with platformio-ide not VS-code not being able to correctly parse domain based user folder redirects.
I've described a workaround since some others had said they had the same issue.

@weinand based on @labnet7's response, this looks like an issue with the platformio-ide.


Filter behavior change in 1.3.6

Plunker: http://plnkr.co/edit/HKQwBiVxFh6bxXzP12bB?p=preview
It looks like something changed with filtering by an object expression in 1.3.6.  In the example above no items in the list render until you type in the input bound to the fooFilter model.  If you change back to angular 1.3.5 you'll see that the list of items render prior to any user interaction.
Workaround is to initialize fooFilter to empty string.

@caitp @lgalfaso this issue was closed on Dec 17th, but is still reproducible in 1.3.8 and 1.3.12:

Repro for 1.3.8
Repro for 1.3.12

Can we please re-open?

@cspeper could you please open a new issue with a clear reproduce scenario using plunker or similar?


[webview_flutter] propagate more events back to flutter, allow customization of UserAgent, basic auth

Hi,
I required a few customizations for the platform WebView and wondered if it might be useful for others:

Customization of the User-Agent string (on iOS only since 9).
Getting notifications for page loading, finished and error events.
Handling authorization requests (for basic authorization)

let me know if this is something which makes sense to be contributed back.
thanks,
Herbert

I signed it!

@amirh maybe you could take a look if these are things which fit into the plans for the webview plugin? thanks.

i will split this PR up into smaller once. first one https://github.com/flutter/plugins/pull/1389


Cannot run git commands in CI due to dubious ownership in repository

Describe the bug
I have some code to get the current commit hash and time in my build process. Specifically, I am using SvelteKit and I fetch the commit details in the vite.config.js file.
For a while, this has been silently broken on my site and I have not been able to reproduce the issue locally. After adding some logging to my build process I found that the git commands to fetch these details do not execute successfully because the Azure/static-web-apps-deploy@v1 is getting mounted in the build container (which seems to mess up directory ownership) and the directory is not marked as a safe directory in git.
status: 'rejected',
    reason: Error: Command failed: git describe --tags || git rev-parse --short HEAD
    fatal: detected dubious ownership in repository at '/github/workspace'
    To add an exception for this directory, call:

    	git config --global --add safe.directory /github/workspace

I think an easy way to fix it would be for the container to run git config --global --add safe.directory /github/workspace before actually running the build.
Github workflow file:
name: Azure Static Web Apps CI/CD

on:
  workflow_dispatch:
  push:
    branches:
      - master
    paths:
      - frontend/**

jobs:
  build_and_deploy_job:
    runs-on: ubuntu-latest
    name: Build and Deploy Job
    steps:
      - uses: actions/checkout@v4
        with:
          submodules: true

      - name: Deploy
        id: builddeploy
        uses: Azure/static-web-apps-deploy@v1
        with:
          azure_static_web_apps_api_token: ${{ secrets.AZURE_STATIC_WEB_APPS_API_TOKEN_ICY_BUSH_07607F803 }}
          repo_token: ${{ secrets.GITHUB_TOKEN }} # Used for Github integrations (i.e. PR comments)
          action: "upload"
          ###### Repository/Build Configurations - These values can be configured to match your app requirements. ######
          # For more information regarding Static Web App workflow configurations, please visit: https://aka.ms/swaworkflowconfig
          app_location: "frontend" # App source code path
          api_location: "frontend/build/server" # Api source code path - optional
          output_location: "build/static"
          skip_app_build: false
          ###### End of Repository/Build Configurations ######

To Reproduce
Steps to reproduce the behavior:

Create a sveltekit project
Add replace the contents of the vite.config.js file with the following:

import { sveltekit } from '@sveltejs/kit/vite';
import { exec } from 'child_process';
import { promisify } from 'util';

// Get current tag/commit and last commit date from git
const pexec = promisify(exec);
const promises = (
  await Promise.allSettled([
    pexec('git describe --tags || git rev-parse --short HEAD'),
    pexec('git log -1 --format=%cd --date=format:"%Y-%m-%d %H:%M"'),
  ])
);
console.log('VITE CONFIG: promises', promises);

const [version, lastmod] = promises.map(v => JSON.stringify(v.value?.stdout.trim()));
console.log(`VITE CONFIG: commit hash`, version);
console.log(`VITE CONFIG: commit time`, lastmod);

/** @type {import('vite').UserConfig} */
const config = {
        plugins: [sveltekit({})],
        server: {
                port: 5000
        },
        define: {
                __VERSION__: version,
                __LASTMOD__: lastmod,
        },
};

export default config;

Run the build locally, it succeeds and logs the current commit hash and time
Run the build on github actions, it produces the following output:

VITE CONFIG: promises [
  {
    status: 'rejected',
    reason: Error: Command failed: git describe --tags || git rev-parse --short HEAD
    fatal: detected dubious ownership in repository at '/github/workspace'
    To add an exception for this directory, call:

    	git config --global --add safe.directory /github/workspace
    fatal: detected dubious ownership in repository at '/github/workspace'
    To add an exception for this directory, call:

    	git config --global --add safe.directory /github/workspace

        at ChildProcess.exithandler (node:child_process:419:12)
        at ChildProcess.emit (node:events:514:28)
        at maybeClose (node:internal/child_process:1091:16)
        at Socket.<anonymous> (node:internal/child_process:449:11)
        at Socket.emit (node:events:514:28)
        at Pipe.<anonymous> (node:net:323:12) {
      code: 128,
      killed: false,
      signal: null,
      cmd: 'git describe --tags || git rev-parse --short HEAD',
      stdout: '',
      stderr: "fatal: detected dubious ownership in repository at '/github/workspace'\n" +
        'To add an exception for this directory, call:\n' +
        '\n' +
        '\tgit config --global --add safe.directory /github/workspace\n' +
        "fatal: detected dubious ownership in repository at '/github/workspace'\n" +
        'To add an exception for this directory, call:\n' +
        '\n' +
        '\tgit config --global --add safe.directory /github/workspace\n'
    }
  },
  {
    status: 'rejected',
    reason: Error: Command failed: git log -1 --format=%cd --date=format:"%Y-%m-%d %H:%M"
    fatal: detected dubious ownership in repository at '/github/workspace'
    To add an exception for this directory, call:

    	git config --global --add safe.directory /github/workspace

        at ChildProcess.exithandler (node:child_process:419:12)
        at ChildProcess.emit (node:events:514:28)
        at maybeClose (node:internal/child_process:1091:16)
        at Socket.<anonymous> (node:internal/child_process:449:11)
        at Socket.emit (node:events:514:28)
        at Pipe.<anonymous> (node:net:323:12) {
      code: 128,
      killed: false,
      signal: null,
      cmd: 'git log -1 --format=%cd --date=format:"%Y-%m-%d %H:%M"',
      stdout: '',
      stderr: "fatal: detected dubious ownership in repository at '/github/workspace'\n" +
        'To add an exception for this directory, call:\n' +
        '\n' +
        '\tgit config --global --add safe.directory /github/workspace\n'
    }
  }
]
VITE CONFIG: commit hash undefined
VITE CONFIG: commit time undefined

My personal repo experiencing this issue: https://github.com/biltongza/ldam.co.za
Affected CI run: https://github.com/biltongza/ldam.co.za/actions/runs/6145310617/job/16672439301
Expected behavior
Git commands run normally.
Additional context
See https://github.com/actions/runner-images/issues/6775 for more details, it appears to be a result of a CVE in git.

I have run into the same issue. I am deploying the Hugo app cstate (https://github.com/cstate/cstate), which gets the last-modified info from git history for displaying incident history.
As @biltongza says, since the container is mounting the git directory from outside, it really needs to run the git command to trust the directory as the first step in its containerized workflow.

I forgot I logged this issue, but I also found a workaround. It turns out that you can specify pre build commands via an environment variable. You can add this to your workflow:
env:
    PRE_BUILD_COMMAND: git config --global --add safe.directory /github/workspace


Adaptive learning: Add standardized competencies

Pull Requests
Here all pull requests related to this feature proposal are linked. (Links will be added when PRs are created)

Create standardized competency domain objects #8129
Add standardized competency management #8238
Add knowledge area management #8309
Add import of standardized competencies from .json files #8377
Add import of standardized competencies into courses #8467

Context
Problem
The first problem is that there are very limited possiblities to share and compare competencies across courses in Artemis.  While there is the option to import existing competencies from one course into another, this requires the user to be at least an editor in both courses. This import also simply copies the competencies without a reference to the original.
The second problem is that instructors lack a reference for high-quality competencies and have to create their own competencies by hand. Not only is this a time-consuming task, it might also lead to inconsistent competency quality, or in the worst case, discourage instructors from using the adaptive learning feature altogether.
Motivation
Not being able to compare competencies across courses limits the learning path feature to only be able to operate on the course-level. It might also be more difficult for students to recognize related or equal competencies in different courses, which might cause them to study less effectively.
Standardized competencies being already provided in Artemis saves instructors a significant amount of time and effort when creating competencies for their course. Anzinger already proposed in , that such a change might increase the number of courses that utilize the learning path feature. This is in line with the interview findings, where two instructors answered that they would only consider using the feature if it does not require a lot of effort .

Requirements Engineering
Existing (Problematic) Solution / System
The current system links each competency to a course.  When importing competencies, they are copied from one course into another without a reference.
Proposed System
Admins will be provided with a list of high-quality competencies, based on a document (CS2023), that offers a standardized plan for computer science curricula. They will be able to import those as standardized competencies into Artemis. They are then able to manage those competencies, being able to edit or delete them, or create new ones. They are also able to create/edit/delete knowledge areas (i.e., categories) for the standardized competencies.
Instructors may then import those standardized competencies into their courses. To not disrupt the existing system too much, imported competencies are still copied, but contain a reference to the original standardized competency.
Requirements
Functional:

FR: Parse standardized competencies (not part of Artemis): Write a program that automatically parses the standardized competencies specified in the CS2023 Document into a list of competencies, and automatically flags potentially incorrect/unfitting data. Faulty data is then corrected by hand to ensure a high quality standard.
FR: Standardized competency management: Admins are able to perform multiple tasks to manage the standardized competencies in an Artemis instance.
2.1. FR:  Import standardized competencies from .json: Admins are able to import competencies from a .json file as standardized competencies into an Artemis Instance. This also imports their knowledge areas.
2.2. FR: Create/Edit/Delete standardized competencies: Admins are able to create additional standardized competencies in Artemis, as well as edit or delete existing ones.
2.3. FR: Create/Edit/Delete knowledge areas: Admins are able to create additional knowledge areas in Artemis, as well as edit or delete existing ones.
FR: Import standardized competencies into a course: Editors are able to browse a list of existing standardized competencies, filter them by knowledge area, title, etc., and import a selection of those into their own course. Any competencies imported this way are copies, but still reference the original standardized competency.

Non-functional:

NFR: Usability: The user interface adheres to the Artemis client design guidelines. All new features are documented in the existing Artemis User Guide, where they can easily be looked up by users.
NFR: Reliability: The added functionality does not affect the availability of the Artemis system in a negative way. Errors are displayed to the user with a descriptive and easily understandable error message.
NFR: Performance: The system's response time for loading pages under normal load does not exceed two seconds. Wait time for requests depending on large language models does not exceed 30 seconds under normal load.
NFR: Supportability: The system is designed modularly and all methods are documented. This simplifies the process of maintaining, modifying and extending the system, in particular for other developers. Errors are logged in detail to facilitate easy troubleshooting.
NFR: Implementation Requirements: The implementation adheres to the Artemis coding and design guidelines.

Analysis
Analysis Object Model
In the analysis object model, the new StandardizedCompetency is added. Each of them has a version number and a reference to the original StandardizedCompetency (Version 1.0). Instead of courses, this kind of competency is linked to a Knowledge Area. These areas are implemented as a tree-like structure using the composite pattern.
To reduce code duplication, a new superclass BaseCompetency is introduced. The existing Competency object may now have a link to a StandardizedCompetency (if it was created from one)

Dynamic Behavior
(skipped, since most workflows are relatively simple)

System Design
Subsystem Decomposition
Client:
Most of the client changes are new views for the StandardizedCompetencyManagement for admins. The main view is realized in the StandardizedCompetencyManagementComponent, accessible from the NavBarComponent, under the "Server Administration" tab. From this view, admins can reach the views to import, create and edit standardized competencies, as well as the management for knowledge areas. Most of these views utilize the StandardizedCompetencyService to communicate with the Artemis server.
For the CompetencyManagement for courses, a new view gets added that allows instructors to import standardized competencies (as competencies) into their course.

Server:
On the server-side the new AdminStandardizedCompetencyResource handles all requests related to the management of standardized competencies that admins perform. Any complex logic is performed in the StandardizedCompetencyService.
The CompetencyResource and CompetencyService will also be adjusted due to allow for the import of standardized competencies into a course.

API Changes:
Standardized Competency Management (Admin)

POST /admin/standardized-competencies/import (NEW)

imports a list of standardized competencies and their respective knowledge areas
request body: List competencies,  List knowledgeAreas

POST /admin/standardized-competencies/ (NEW)

creates a new standardized competency
request body: StandardizedCompetency competency

PUT /admin/standardized-competencies/{competencyId}  (NEW)

updates an existing standardized competency
request body: StandardizedCompetency updatedCompetency

DELETE /admin/standardized-competencies/{competencyId}  (NEW)

deletes an existing standardized competency

GET /admin/standardized-competencies/ (NEW)

gets a pageable list of standardized competencies

Knowledge Area Management (Admin)

POST /admin/standardized-competencies/knowledge-areas (NEW)

creates a new knowledge area
request body: KnowledgeArea knowledgeArea

PUT /admin/standardized-competencies/knowledge-areas/{id}  (NEW)

updates a knowledge area
request body: KnowledgeArea updatedKnowledgeArea

DELETE /admin/standardized-competencies/knowledge-areas/{id}  (NEW)

deletes an existing knowledge area

GET /admin/standardized-competencies/knowledge-areas (NEW)

gets a pageable list of knowledge areas

GET /admin/standardized-competencies/knowledge-areas/for-dropdown (NEW)

gets a complete list of knowledge areas (used to filter standardized competencies)

Competency Management (Course)

POST /courses/courses/{courseId}/competencies/import-standardized/ (NEW)

imports a list of standardized competencies into a course (as competencies)
request body: List competencies

Persistent Data Management

table standardized_competency (NEW)

mostly like a competency, but not linked to a course, instead they have a knowledge area
fields: id, title, description, taxonomy, knowledge area

table knowledge_area (NEW)

fields: id, title, parent  (KnowledgeArea, ManyToOne)

table competency (EDITED)

new fields: linked_standardized_competency_id (ManyToOne)

Access Control / Security Aspects
The management of standardized competencies (2.FR) is only available to admins.
The import competencies -> course (3.FR) is only available to (at least) editors for this course.

UI / UX
2. FR: Standardized competency management
The standardized competency management is a tree-like view over all knowledge areas and standardized competencies in the Artemis instance. Admins can expand knowledge areas by clicking on them. They can also click competencies to display more details on the right side. Here they can also edit/delete this competency(see 2.2. FR).
To get a better overview, admins can filter the results by competency name and knowledge area.
Using the buttons in the title bar, they may create a new competency (see 2.2. FR) or switch over to the knowledge area management (see 2.3. FR).

wireframe
2.1. FR: Import standardized competencies from .json
The admin first selects a .json file to import competencies from. The competencies get read from the file and displayed in a table. The user now has the option to (re-)view all competencies and remove any that seem unfit. Finally, they can choose to import those competencies into Artemis.

wireframe
2.2. FR: Create/Edit/Delete Standardized Competencies
The create/edit view for standardized competencies is the same. The admin can enter/edit title, description and knowledge area of the competency. They can then cancel or submit the changes.

2.3. FR: Create/Edit/Delete knowledge areas
The knowledge area management is a tree-like view over all knowledge areas in the Artemis instance. Admins can expand knowledge areas by left-clicking them. This also a detail view on the right side, that allows them to edit or delete the selected knowledge area, as well as to create a new knowledge area under it.
For now the knowledge area and standardized competency management are split, to keep each workflow as simple as possible. Depending on the actual complexity in the application, they might also be combined.

wireframe
4. FR: Import standardized competencies into a course
The import into a course re-uses the same tree structure from the standardized competency management. Instructors can filter the displayed competencies by their name and knowlege area.
By clicking the eye icon, they can get more detailed information about the competency. They then select competencies to import by clicking the checkbox next to them. A text above the import button always displays how many competencies will be imported.
Finally, they press the import button to import all selected standardized competencies as competencies into their course.

wireframe
Future Work
This feature proposal contains a basic version of standardized competencies. In the future this feature may be extended with the following functionality:

Full versioning support for standardized competencies
Import standardized competencies as prerequisites
Relations for standardized competencies
Instructors may propose some of their competencies to be added to standardized competencies
...

All PRs related to this Feature Proposal are merged.


Smart Quotes need escaping

When emitting a quoted value the code currently escapes the ASCII single quotes correctly but it does not do it for the Unicode alternatives that are used as a single quote equivalent:

U+2018
U+2019
U+201A
U+201B

$psd1 = @{foo = "Hello $([char]0x2018)World$([char]0x2018)" } | ConvertTo-Psd1

$psd1
# @{
#     foo = 'Hello ‘World‘'
# }

$psd1 | Invoke-Expression
# Invoke-Expression: Unexpected token 'World‘'' in expression or statement.

CodeGeneration.EscapeSingleQuotedStringContent can be used to correctly escape all the quotes needed to place a value inside a single quoted string
$value = "Hello $([char]0x2018)World$([char]0x2018)"
@"
@{
    foo = '$([System.Management.Automation.Language.CodeGeneration]::EscapeSingleQuotedStringContent($value))'
}
"@

# @{
#     foo = 'Hello ‘‘World‘‘'
# }

Thanks for the catch and proposing a solution.
Fix implemented and released in v1.0.1

Thanks for the speedy fix.


Graph debug mode

Debug mode should make labels node ids.


Add Cereus-Pro Hugo Themes

Does this theme work with NetlifyCMS or does it just deploy to Netlify? If it does not work with NetlifyCMS please change:
cms:
  - NetlifyCMS

to
cms:
  - No Cms

it using NetlifyCMS as CMS.

Awesome! It just wasnt obvious to me from the readme that it was NetlifyCMS ready. Great to see more CMS ready themes.


Codeigniter 3.1.6 Session not working properly with PHP 7.1.7

Hi, session library isn't working fine with PHP 7.1.
It seems to be ok with PHP 5, but still there exist problem on Codeigniter 3.1.6.
Temporary working solution is below.

edit system/libraries/Session/Session.php, comment below codes

//     session_start();

// Security is king
//    ini_set('session.use_trans_sid', 0);
//    ini_set('session.use_strict_mode', 1);
//    ini_set('session.use_cookies', 1);
//    ini_set('session.use_only_cookies', 1);
//    ini_set('session.hash_function', 1);
//    ini_set('session.hash_bits_per_character', 4);

add session_start(); at top of /index.php

this bug seems to be fixed and updated in next release.

can you provide more information? and what's your problem?
if you want activated session, please enable session class in autoload.php and then you dont need to write session_start() anymore

There's plenty of people using CI 3.1.6 on PHP 7.1 and it works just fine ... you can't just say it doesn't work. Even if something doesn't work for you, the details around it are important.
But more importantly, your "temporary working solution" is effectively the same as not using CI_Session. If you won't want to use CI's session library, that's fine, but don't publicly suggest commenting out code from the framework. Not least because this is a bug tracker, not a micro-blogging platform. You can post on our forums if you're just looking for help and/or to help others.
And finally:

this bug seems to be fixed and updated in next release.

There's have been no changes to CI_Session since the 3.1.6 release ... This doesn't make any sense.

I know this type of developer. All they say is "it works for me" and blame and gets mad at their own clients for having the issue. I've been seeing narfbg's comments about this topic on multiple platforms with people mentioning the same error and his comments are pretty much the same.  That's what software do, they just fail someday. At the end of the day, the CI_Session was updated to fix this, for example, http://tekina.info/solving-session-problems-codeigniter-upgrading-php-version/
I was having this same problem and the solution on the first comment worked for me. I don't work with CodeIgniter anymore but this is a particular client that don't want to migrate. And more a Laravel guy.

Yeah? Let's see if you actually know anything ...

All they say is "it works for me" and blame and gets mad at their own clients for having the issue.

First of all, I challenge you to find me saying "it works for me" anywhere. And I do mean anywhere, not just on this repository. Go dig up every comment or statement I've ever written on the internet; you won't find me saying that, because I never do.
What I said here is that there's plenty of other people for whom "it works" as an observation, and as a preface to why one should provide details instead of just saying "it doesn't work".
Secondly, I have never blamed anyone for having any issue and I challenge you to find an instance of that too. What I got mad about is the posting of a random suggestion to modify stock framework code, and a very bad one too - what those modifications do is plain dumb, and there's multiple easier ways to achieve the same effects even if you want the dumb thing.
And finally - I don't have clients. OP is not my client, you're not my client, nobody is my client. I don't get paid for any of this, not even indirectly - no ads, no consulting business on the side, no nothing.
You should keep note of that before expecting anything from me.

I've been seeing narfbg's comments about this topic on multiple platforms with people mentioning the same error and his comments are pretty much the same.

About which topic? About which same error? And if I won't hear anything about it, who fixes all of the bugs? You say that like all issues are the same and I have a magic "fix problem" button at my fingertip that I simply have to press when I feel like it.
I can be harsh towards unreasonable people, but "toxic" is a projection.

At the end of the day, the CI_Session was updated to fix this, for example, http://tekina.info/solving-session-problems-codeigniter-upgrading-php-version/

So, all I do is say it "works for me" and I won't hear anything about "my precious CI_Session library", yet at the end of the day it was updated to fix "this", despite me being the only one able to do such an update and nobody knowing what "this" is?
And the link (which btw, could've just said "do your updates") you referenced was published 3 months before this issue was opened and talks about changes that I made over a year before this issue was opened and released in 3.1.2.
Funny how all of that works.

I was having this same problem and the solution on the first comment worked for me. I don't work with CodeIgniter anymore but this is a particular client that don't want to migrate. And more a Laravel guy.

You don't know if you had the same problem. Nobody knows if they have had the same problem. Nobody knows what the problem here was, because the problem was never described.
And do you even know what "the solution" that "worked for you" (wink, wink) does?
It effectively disables CI_Session; it's the same thing as not loading the library and just calling session_start() instead. So if you had to get that "solution" from here, you have no idea what you're doing and you should be ashamed for charging clients for your incompetence.
 Why is it that it's never a Symfony, ZF, Slim, Yii or any other framework guy? At least those frameworks are based on completely different ideas and so are naturally opposed to what CI does; Laravel is heavily influenced by CI, and I don't know about now, but earlier versions even included CI code (parts written by me too). You had no idea of that either, did you?
 I cant write too long sentences. Because my english so poor. But let me tell you what i feel when i read this.
Thanks for everything
You give me job, you give me (and my family) the money. But i never give you anything, instead of reporting the bug, asking a question, etc. Sorry for this.

I dont know how hard your day, but  in my subjective opinion, at this day

No PHP programmer who not know what is Codeigniter.

we cant make every people happy, even we are doing a good thing. Just ignore them.
And the last. Maybe you dont know how happy i am when my problem solve by you, i jump from my chairs and yelling. "YESSSSS, my problem solved by MASTER". Its like i have problem with my windows then Bill gates answer my question.
Thanks for everything.

That's a good reply plonknimbuzz, thank you!

@plonknimbuzz Thank you, I wasn't looking for praise, but I appreciate that.
You don't need to be sorry for anything (especially not for reporting bugs - that's contributing) and while I'm glad you think highly of me, I really don't want to be thought of as a "master" or some other kind of supreme being. As long as you're being a reasonable person, that's good enough for me.

This is still not fixed are we expecting a fix in the next version?...meanwhile this temporary fix looks like trouble to me

sorry am currently using version 3.1.10 and am still having the issue.

maybe it can help
https://medium.com/@denissetianto/codeigniter-session-data-lost-after-redirect-60809efb689e

I had same issue with php latest version and Codeigniter 3.1.x and i found this solution which worked for me
https://medium.com/@denissetianto/codeigniter-session-data-lost-after-redirect-60809efb689e
if (empty($params['cookie_name'])) { 	//$params['cookie_name'] = ini_get('session.name'); 	$params['cookie_name'] = ini_get('session.id'); } else { 	//ini_set('session.name', $params['cookie_name']); 	ini_set('session.id', $params['cookie_name']); }


ParseSignal: drop add'l check for numeric signals

The kernel will return an error anyway.

There was an associated test :)
--- FAIL: TestParseSignal (0.00s)
    --- FAIL: TestParseSignal/65536/0/true (0.00s)
        signals_test.go:40: ParseSignal(65536) should return error

Whoops, forgot to fix that. Fixed now.


(wip) support examples (formatting and customisation)

Description
Add example formatting and support for customization.
interface TypeDirectiveExample {
  directive: GraphQLDirective; // customize the directive name
  field: string; // customize the directive's field name
  parser?: (value?: unknown) => unknown; // customize the field's value parsing
}

Checklist

[x] My changes follow the contributing guidelines of this project.
[x] I have performed a self-review of my code.
[x] I have made corresponding changes to the documentation.
[x] I have added tests that prove my fix is effective or that my changes work.
[x] New and existing unit tests pass locally with my changes.

coverage: 94.249% (-0.07%) from 94.319%
when pulling 19db1a730fae2fb749a6aca4d214973d538c64f1 on feat/1292-support-examples-2
into 79e34d54b959d01cc06352f88b37f507bc4b780e on main.


Windows issue?

Should this drone work on a Windows system?  I have setup everything as I think I should and still get 2016/02/23 14:17:03 Fatal: Missing username and/or password.
I did
set LAIR_API_SERVER='https://admin@localhost:password@my_ip:1013' (I also tried port 11015.
Assuming Windows is just not supported?

Yes the drone works on windows.
Try to use the port 11013

I do have it set to 11013 the 10013 up top is a typo my bad.

Remove the single quotes, so it should look like:
set LAIR_API_SERVER=https://admin@localhost:password@my_ip:11013

are you still having issues?

Sorry I have been away a few days. Your suggestion solved this issue.  Thank you!


get Error :: add native plateform in your app setting

Plateform: Android
react-native: 0.34.0

when i click on facebook button i get Error "add native plateform in your app setting"

means you most likely have outstanding things to do in your facebook developer settings
the application you created on developer.facebook.com needs to target  android native platform

@lwhiteley thanks buddy. it's working :+1:


[docs] Table component Sort example - Built-in Sort is stable

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

Current Behavior 😯
The Sorting & selecting demo code in the Material-UI docs includes a function stableSort to ensure stable sort.
This is no longer necessary on modern browsers, as the built-in Array.prototype.sort() method is stable (mdn, caniuse).
Expected Behavior 🤔
Ideally the docs would use the built-in method as the recommended approach, and include a note to mention that an approach like the stableSort function is necessary on older browsers.

It's still not supported in IE11, plus this is a demo so we are not adding anything in the bundle size. Thatsaid, I would say we should keep the stableSort, but we may add a note above it, indicating that developers can use Array.prototype.sort() if the don't need to support IE11.
index e014a20c37..ce191b657a 100644
--- a/docs/src/pages/components/tables/EnhancedTable.tsx
+++ b/docs/src/pages/components/tables/EnhancedTable.tsx
@@ -85,6 +85,8 @@ function getComparator<Key extends keyof any>(
     : (a, b) => -descendingComparator(a, b, orderBy);
 }

+// This method is created for cross-browser compatibility, if you don't
+// need to support IE11, you can use Array.prototype.sort() directly
 function stableSort<T>(array: readonly T[], comparator: (a: T, b: T) => number) {
   const stabilizedThis = array.map((el, index) => [el, index] as [T, number]);
   stabilizedThis.sort((a, b) => {

We can likely remove it in v6 too.

Awesome, I'll submit a PR to add the note for now.


[main] Upgrade to latest dependencies

Cron -knative-prow-robot
/cc knative-extensions/eventing-rabbitmq-approvers
/assign knative-extensions/eventing-rabbitmq-approvers
Produced by: knative-extensions/knobots/actions/update-deps

/retest

@ikavgo build issues addressed in #1466. Could you PTAL?


Add X-Envelope-To Column

It would be really helpful to be able to show the X-Envelope-To-Header as a column for Mails received through Catchall, Bcc-Mails and other use cases.
Right now the Recipient coumn of your plugin shows for example "undisclosed-recipients;" there, is simply empty or shows another completely unknown mailadress as recipient because the real recipient is hidden through BCC. As a result i cannot determine the recipient because the mail is received through a CatchAll-Mailbox and i have to open the Source of the Mail to see the real recipient.

I don't think that's possible. Custom column handler/callback receives nsIMsgDBHdr object, which allows access only to some selected properties and headers of the message.


Fix determinism in WithPolarWarping

Codecov Report

Merging #509 into master will decrease coverage by 0.41%.
The diff coverage is 100%.

@@            Coverage Diff             @@
##           master     #509      +/-   ##
==========================================
- Coverage   96.36%   95.95%   -0.41%
==========================================
  Files          36       36
  Lines       12882    12888       +6
==========================================
- Hits        12413    12366      -47
- Misses        469      522      +53


[Feature]: Deploying app without GitHub

Is there an existing issue for this?

[X] I have searched the existing issues

Summary
Sometimes deploying small apps should be done without GitHub repository
Why should this be worked on?
In some cases you don't want to spend time by uploading your small app on GitHub and just want simply to select zip file
For example I have bot written with Python and I don't want for it to create yet another repository

v4 supports this.
I'm closing this issue, because tracking features will be moved to GitHub discussions. Github issues will be only for bugs.
Version 4 is in full focus. v3 related issues will be closed, if it is not a critical bug.
Thanks for your understanding.


1.19.2 Crashing on startup

Just upgraded the server container to the newly released 1.19.2 and the server is in a crash loop.
[14:14:55] [RPAK_FSYS] [info] LoadPakAsync common.rpak 1
[14:14:55] [RPAK_FSYS] [info] Not loading pak ./R2Northstar\mods\Northstar.Custom\paks\mp_weapon_shotgun_doublebarrel.rpak for dedicated server
[14:14:55] [RPAK_FSYS] [info] Not loading pak ui.rpak for dedicated server
[14:14:55] [RPAK_FSYS] [info] Not loading pak particle_scripts.rpak for dedicated server
[14:14:55] [RPAK_FSYS] [info] Not loading pak highlight.rpak for dedicated server
[14:14:55] [RPAK_FSYS] [info] Not loading pak mp_lobby.rpak for dedicated server
[14:14:55] [RPAK_FSYS] [info] Not loading pak mp_lobby_loadscreen.rpak for dedicated server
[14:14:55] [NORTHSTAR] [info] Registering ConCommand find
[14:14:55] [NORTHSTAR] [info] Registering ConCommand findflags
[14:14:55] [NORTHSTAR] [info] Enabling hook _Host_Map_f_CompletionFunc
[14:14:55] [NORTHSTAR] [info] Enabling hook Host_Map_f
[14:14:55] [NORTHSTAR] [info] CDedicatedExports::RunServer(): starting
[14:14:55] [NORTHSTAR] [info] "Z:\tmp\ns1673676050\NorthstarLauncher.exe" -dedicated -port 37015 +setplaylist aitdm +mp_gamemode aitdm +map mp_grave +ns_private_match_countdown_length 0 +net_compresspackets_minsize 64 +net_compresspackets 1 +spewlog_enable 0 +sv_maxrate 127000 +sv_balanceTeams 1 +sv_cheats 0 -enablechathooks +setplaylist private_match -game R2 -nomenuvid -nosound -windowed -nomessagebox +host_preload_shaders 0 +net_usesocketsforloopback 1 +community_frame_run 0
[14:14:55] [NORTHSTAR] [info] Building KeyValues for file playlists_v2.txt
[14:14:55] [NORTHSTAR] [info] Set playlist to Load a map on the command line
[14:14:55] [NORTHSTAR] [info] Set playlist to Load a map on the command line
[14:14:55] [NORTHSTAR] [info] Set playlist to aitdm
nswrap: northstar exited with status 100
nswrap: killing xvfb
nswrap: waiting for children to exit
~~~~~SNIP~~~~~

Just to confirm, going back to
docker pull ghcr.io/pg9182/northstar-dedicated:1-tf<IP_ADDRESS>-ns1.19.1

does not result in a crash, right?

https://github.com/pg9182/northstar-dedicated-ci/actions/runs/6394806680 also observes this issue, so it must be in launcher code.

https://github.com/pg9182/northstar-dedicated-ci/actions/runs/6395262419 works fine.
This is v1.19.2 with https://github.com/R2Northstar/NorthstarLauncher/pull/529 reverted, meaning https://github.com/R2Northstar/NorthstarLauncher/pull/529 is the offending commit.

Running the same launch command as in in the initial issue on Windows dedi
NorthstarLauncher.exe -dedicated -port 37015 +setplaylist aitdm +mp_gamemode aitdm +map mp_grave +ns_private_match_countdown_length 0 +net_compresspackets_minsize 64 +net_compresspackets 1 +spewlog_enable 0 +sv_maxrate 127000 +sv_balanceTeams 1 +sv_cheats 0 -enablechathooks +setplaylist private_match -game R2 -nomenuvid -nosound -windowed -nomessagebox +host_preload_shaders 0 +net_usesocketsforloopback 1 +community_frame_run 0

I cannot reproduce the crash. The server registers just fine. So this is definitely Wine/Docker specific issue IMO.
That being said I still reverted the change upstream for now via https://github.com/R2Northstar/NorthstarLauncher/pull/561, as I do not have the capabilities to debug this and we cannot afford losing Docker support, and I will push out a hotfix soon.

@KallanX should be fixed with the latest Docker image (1-tf<IP_ADDRESS>-ns1.19.3) by reverting a change upstream.
Please retest if you get the change.
I'm gonna leave the issue open still for @pg9182 to see. Maybe he has an idea how to properly fix this in Wine.

Closing as completed via revert and subsequent re-implementation in Northstar with https://github.com/R2Northstar/NorthstarLauncher/pull/564


Extension issue

Issue Type: Bug
Extension Name: php-intellisense
Extension Version: 2.3.14
OS Version: Windows_NT x64 10.0.21364
VS Code version: 1.55.2

:warning: We have written the needed data into your clipboard. Please paste! :warning:

report issue


add redirection to /jams path issue #2

redirection through useEffect and nextJS pages, using next/router useRouter hook.

Before merge, please resolve all build errors.

I will merge when there's no blocking checks. Your changes still didn't resolve the problem.

Hello, any progress you've made?
Should i mark this issue as salvageable?

salvageable.


Login error on Android

I am able to use the plugin fine on MacOS, but I got an error when I tied recently to publish on Android. It may have worked previously, but I don't recall—I'm picking up again after a longish pause.
I logged out of micro.blog from the plugin, generated a new app token, and tried to log in again. I'm consistently getting a login error now..I'm able to log in via Chrome and other apps on the same device and from the plugin on my MacBook—my only issue is via the plugin on Android.
Any ideas?

I'm also experiencing this issue.
Did you ever get it figured out?

I haven't tried recently—I just post from my MacBook, which doesn't have the issue. I'm mostly in the Apple ecosystem, and I use my (Android) Samsung tablet as an ereader because it was way more affordable than an iPad mini.

Just confirmed I can’t sign in on Android. Browser works, just not the Obsidian plugin.

This is what I get when I try to publish a post from the Android app.

The same thing is happening here.


replace puppet lint rule unquoted_resource_title

http://puppet-lint.com/checks/unquoted_resource_title/
https://docs.puppetlabs.com/guides/style_guide.html#resource-names

Fixed in https://github.com/iwarapter/sonar-puppet/pull/91


✨ Added format option to img-url helper

no issue

Added support for resizing images from Unsplash using the img-url helper
Added support for setting the format of images, with a new  format option:

E.g. to convert an image to webp (only works in combination with size for now, except for Unsplash where you can use it without size):
{{img_url @site.cover_image size="s" format="webp"}}

This can help improve the performance of a theme, by serving assets in <picture> elements with webp and fallback image formats.

Since this is targeted at Unsplash, there is a alternative that would be less work for theme developers and also Ghost. Instead of asking Unsplash for a specific format, Unsplash in turn uses the Imgix API and it supports auto=format.
This allows the potential that the Unsplash API might return the AVIF format if the browser supports it, which could be even smaller than webp while having higher visual "appeal". Here's what the Imgix API docs say:

If auto=format is set and the browser does not support the AVIF format, we'll first fallback to WebP if it is supported. If WebP is not supported, imgix will fall back to the source image type.

https://docs.imgix.com/apis/rendering/format/fm#avi
And here's where the Unsplash API docs mention support for auto=format:
https://unsplash.com/documentation#dynamically-resizable-images
Related: there's an open "Idea" for Ghost to improve support for the AVIF format. Improving the Unsplash integration could a first step.

Sounds good, @SimonBackx


Python 3

Lots of inquiries to why Python 2 over Python 3. Might just install both next to each other and provide some aliases like mkvirtualenv2.7 and mkvirtualenv3.3.
If anyone has a better setup for development with both versions, ideas are welcome.

This is what I do
function mkvirtualenv2() {
    mkvirtualenv $1 --python=/usr/local/bin/python
}

function mkvirtualenv3() {
    mkvirtualenv $1 --python=/usr/local/bin/python3
}

function mkvirtualenvpypy() {
    mkvirtualenv $1 --python=/usr/local/bin/pypy
}

A couple of people also suggested https://github.com/yyuu/pyenv