Pull request preview deploys when there are multiple open PRs

Hi There, this pages gives instructions for Pull Request preview deploys, but it looks like you have to set up a specific Slot or App Service to deploy to. This means that if there is more than one open Pull Request then the last one will overwrite the previous one. Heroku and Netlify (and I'm sure others) create an entirely new deployment for each Pull Request preview. I think that this isn't possible in Azure Dev Ops, but please let me know if I'm mistaken. Thanks, Cedd.

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

ID: 5cbb2877-5e10-4065-e3c6-7883e9df4b3c
Version Independent ID: 58122a19-2258-3cf3-8335-74bb0dad892f
Content: Deploy pull request builds - Azure Pipelines
Content Source: docs/pipelines/release/deploy-pull-request-builds.md
Product: devops
Technology: devops-cicd
GitHub Login: @raiyanalam
Microsoft Alias: moala

@ceddlyburge -- Cedd, here are a couple of options where you might consider asking your question:

Azure DevOps on Stack Overflow
Azure DevOps Support Bot

@raiyanalam -- Raiyan, please look into this potential documentation issue 5986.

@WilliamAntonRohm -- Any update on this?
@ceddlyburge -- Did you get an answer to this? I am also interested in finding out the solution to this problem.

Hi There, I haven't got an answer, and it doesn't look possible from reading the docs, so I'm pretty sure it isn't possible. Hopefully it will be added in the future. In the meantime I can thoroughly recommend Netlify (which does this at the click of a button). Heroku can also do it without much setup.

@ceddlyburge - What we did is that we now have a separate Resource Group in Azure and then while the PR deployment is initialized, the PR number is appended to URL sensitive resources like Web App and then cleaned up once the PR is merged using service hooks. It is indeed a workaround but works.

👍 Hopefully this will be added in the future.
@blueelvis have you considered a write up for your approach to get this working? That would be super helpful if you had any guidance you could share.

After some investigation 🕵, I ended up here as I did not find an easy solution for this. I am forced to use Azure at work, so it is a much needed feature indeed!
To others, :+1: the first comment, so it may get a higher priority.

@ceddlyburge Thank you for your feedback. In order for you to deploy a WebApp for example, you will need to specify an existing app service to deploy to. As a suggestion to your issue you can create 2 deployment environments, pre-production and production. You will need to create a new app service and deploy your other branch to it.
Please checkout Azure DevOps Developer Community If you have any more questions, or you would like to suggest a feature.

Hey @ramiMSFT I’m not sure that quite answers the question. Any chance this could be reopened?

Ok, thanks for letting me know.
Its better to know that pull request previews aren't fully supported, that way people won't waste time trying to make them work in the same way that they do on platforms like netlify and heroku.

I have used a whole day at work on trying to get this work. We are bound to Azure, and really miss this feature to be able to give a link to other team members that contains only the changes if a particular PR. Commenting it back to the PR after it is actually deployed would be even more awesome.


Research procurement debarring lists

Where do they exist? So far, I've seen the World Bank, Moldova.

World bank
US has it all figured out: Exclusions Extract Data Package
Mexico
Moldova
Ghana - empty?
Russia, Simpler (older?) List.
Georgia (.ge): Blacklist, Warnings
Brazil: labour conditions dirty list
Czech Rep: unreliable VAT payers

Only know of Ministry of Housing and Local Government (Malaysia) blacklisted contractors right now:
http://ehome.kpkt.gov.my/index.php/pages/view/43
Translations of the list on the page:

Housing developer without license
Housing developer found in contempt of the Home Buyers Tribunal
Black list of developers that have failed to pay fines
Housing developers in failing projects
Housing developers involved in failed projects

Sinar's converted it to spreadsheets, we will probably have our own public central database later as we find more blacklisted developers for Malaysia for own use and others.

thanks, @kaerumy - that's very cool. Please keep me updated with regards to the database you're building!

UN Development Programme:
http://www.undp.org/content/undp/en/home/operations/procurement/business/protest-and-sanctions/ineligibility-list/
Do you want this scraped?

UNOPS: https://www.unops.org/english/Opportunities/suppliers/Pages/Vendor-sanctions.aspx

@benparkergit sorry saw this pretty late! That looks amazing, if you felt up for a scraper it'd make a cool contribution!

Here is Brazil's consolidated state procurement debarment list: http://www.portaltransparencia.gov.br/ceis/
...and as downloadable data: http://www.portaltransparencia.gov.br/downloads/ under "Sanções" (sanctions).

Panama's list of government procurement debarments: http://panamacompra.gob.pa/portal/EmpresasInhabilitadas.aspx

Bangladesh debarment list: https://www.eprocure.gov.bd/resources/common/DebarmentRpt.jsp

Norway's state-run Norges Bank has a list of excluded companies from receiving any state investment: https://www.nbim.no/en/responsibility/exclusion-of-companies/

U.S. H-1B Debarred/Disqualified List of Employers: https://www.dol.gov/whd/immigration/H1BDebarment.htm

There's a useful list of debarred and conditional-barred firms from World Bank and cross-debarment between World Bank, Asian Development Bank, European Bank for Reconstruction and Development, Inter-American Development Bank, and African Development Bank.
http://www.worldbank.org/en/projects-operations/procurement/debarred-firms

Ok, since we have included all the international development bank lists (cf. https://www.opensanctions.org/datasets/debarment/ ), I'm closing this. Need to think about how to approach national-level datasets, still.


memref-merge optimization

A new pass is required to reduce the total memory footprint and improve the cache locality.
The static memory planner is required to get the total memory size and the map to each tensor during the compilation stage.
The pass is extensible to support different event based ticker and planner.

Is it a dup of https://github.com/intel/graph-compiler/issues/243 ?

Is it a dup of #243 ?

Yeah, I didn't notice this issue in the dashboard. Closing this as duplicated.


The specified resource does not exist.

Which service(blob, file, queue) does this issue concern?
File
What problem was encountered?
I get the following error when I attempt to initialize the FileService class. The following was working fine and then without notice it stopped working and started giving the following error:
Client-Request-ID=bc4ba635-7aef-11e8-be6a-000d3a319612 Retry policy did not allow for a retry: Server-Timestamp=Thu, 28 Jun 2018 16:24:31 GMT, Server-Request-ID=7ee390c2-c01a-0081-0efc-0e9221000000, HTTP status code=404, Exception=The specified resource does not exist.ErrorCode: ResourceNotFoundResourceNotFoundThe specified resource does not exist.RequestId:7ee390c2-c01a-0081-0efc-0e9221000000Time:2018-06-28T16:24:31.0526845Z.
I have verified that I am able to create a share and upload a file through the web interface without issue. Any help would be greatly appreciated
import os
import io
from typing import List
from tempfile import TemporaryFile
import csv

from azure.storage.file import (
    FileService,
    ContentSettings,
)
from azure.storage.common.retry import (
    ExponentialRetry,
    LinearRetry,
    no_retry,
)

ACCOUNT_NAME = '*****'
ACCOUNT_KEY = '*****'

SHARE_NAME = '*****'

class AzureFileShare():
    def __init__(self):
        try:
            self.file_service = FileService(
                account_name=ACCOUNT_NAME,
                account_key=ACCOUNT_KEY
            )

            self.file_service.retry = ExponentialRetry(initial_backoff=30, increment_base=2, max_attempts=30).retry
            # Use a default linear retry policy instead
            self.file_service.retry = LinearRetry().retry
            # Turn off retries
            self.file_service.retry = no_retry
        except Exception as e:
            print(e)
            raise Exception(e)

    def upload_files(self,
                                file_paths: List[str]):
        for f in file_paths:
             self.file_service.create_file_from_path(
                        SHARE_NAME,
                        None,
                        filename,
                        f,
                        content_settings=ContentSettings(content_type=CONTENT_TYPE[file_extension])
             )

        return

    def retrieve_file_in_directory(self,
                                   filename: str) -> io.StringIO:
        f = self.retrieve_file_in_directory_in_bytes(filename)

        return io.StringIO(f.decode('utf-8'))

    def retrieve_file_in_directory_in_bytes(self,
                                            filename: str) -> bytes:
        with TemporaryFile() as t:
            output_stream = io.BytesIO()

            try:
                file = self.file_service.get_file_to_stream(
                    SHARE_NAME,
                    None,
                    filename,
                    output_stream
                )
            except Exception as e:
                raise Exception(e)

            value = output_stream.getvalue()

            t.write(value)
            t.seek(0)

            return t.read()

if __name__ == '__main__':
    fileshare = AzureFileShare()

    files = ["/temp/file.csv"]

    fileshare.upload_files(files)

    file = fileshare.retrieve_file_in_directory("file.csv")

    for row in csv.reader(file, delimiter=','):
        print(row)

Hi @ttelfer, thanks for reaching out.
To clarify, initializing the FileService class cannot produce any such error, because it does not make any network request.
Thanks for providing your code. I see a potential problem in this part:
def upload_files(self,
                                file_paths: List[str]):
        for f in file_paths:
             self.file_service.create_file_from_path(
                        SHARE_NAME,
                        None,
                        filename,
                        f,
                        content_settings=ContentSettings(content_type=CONTENT_TYPE[file_extension])
             )

        return

Where is filename defined? Did you miss a few lines when copy/pasting the code? The error 404 is most likely thrown in your retrieve_file_in_directory method. Please double check that the file you are getting actually exists.

Hi @ttelfer, I'm closing this for now due to lack of response. Please feel free to provide more information if you think there's an issue related to the SDK.


Add functions to get the approximate location of a tileset during runtime

As discussed in the following Cesium community forum thread, there is no API-level support to get the world location of a tileset during runtime from UE blueprints.
https://community.cesium.com/t/get-coordinates-of-cesium3dtileset-spawned-at-unknown-location/33087/4
As suggested by @kring I had a look at the ACesium3DTileset::OnFocusEditorViewportOnThis() function.
With this pull request I added two functions that return an approximate location (Unreal and ECEF) of the tileset calculated using the rootTile.
Disclaimer:

The code might not be in the most suitable locations, I simply lack the overview of the bigger picture of the Cesium for Unreal source code and where to place which kinds of functions
I did not use the center of the bounding Box or Sphere to calculate the location. This is because for one of my own tilesets that I used to test this code with, this would always place me far above the tileset (thousands of meters)
I think calling it "approximate" is necessary because otherwise this would probably fuel expectations that this code cannot fulfill 😄
I was only able to test these functions anecdotally

If there is no root tile returned by this->_pTileset->getRootTile() this currently returns the Zerovector without warning which results in obviously incorrect coordinates.
I'm not sure what causes a tileset to not have a root tile but it seems to be the case for some tilesets.
ACesium3DTileset::OnFocusEditorViewportOnThis() also simply returns if it encounters a nonexisting root tile so I'm not sure how to best handle this here 🤔

Thanks for the PR @arbertrary!
The root tile is part of the tileset.json, which is download when the tileset is first loaded. Until that download / parse completes, we don't know anything about the tileset, not even where it's located.
There's nothing for it other than to give the function a way to return "I don't know yet" as the answer.

I have added a warning and a boolean out value to the function so that this gets propagated and can be checked in blueprints.
Unfortunately this wasn't actually the problem. For some tilesets the function returns 0,0,0 even if the root tile is available. The !prootTile condition was actually never entered.
Tilesets where that was the case:

Nearmap Boston Photogrammetry https://ion.cesium.com/assetdepot/354759
New York City 3D Buildings https://ion.cesium.com/assetdepot/75343

Tilesets where the code does work for me as expected are for example

Melbourne Photogrammetry https://ion.cesium.com/assetdepot/69380
Montreal Pointcloud https://ion.cesium.com/assetdepot/28945

Unfortunately this wasn't actually the problem. For some tilesets the function returns 0,0,0 even if the root tile is available. The !prootTile condition was actually never entered.

Hello,
Thank you for generating this solution! I implemented your solution to my Cesium3DTilset C++ class exactly as you did, but I am unable to see those functions in the unreal editor. Did you also run into this issue / do you have any advice for exposing your functions in the unreal editor if it is not being shown?

@dyllan-aeroai if you're making changes to the plugin, be aware that Unreal Engine will not automatically recompile source files installed with the engine (i.e., in C:\Program Files\Epic Games\UE_5.2\Engine\Plugins\Marketplace\CesiumForUnreal or similar). You'll need to put the plugin into your project instead.

我尝试了您给出的解决方法，是可行的，太棒了，非常感谢！！！

@dyllan-aeroai if you're making changes to the plugin, be aware that Unreal Engine will not automatically recompile source files installed with the engine (i.e., in C:\Program Files\Epic Games\UE_5.2\Engine\Plugins\Marketplace\CesiumForUnreal or similar). You'll need to put the plugin into your project instead.

Thank you so much! This solution is now exposed in the blueprint editor!

Sorry to bother again, but did you ever figure out how to fix the tileset cases in which the function returned 0,0,0. For my program, certain tilesets are not loading such as the ones you pointed out (Nearmap Boston Photogrammetry and New York City 3D Buildings).

No. I haven't been able to figure out what the essential difference is between the tilesets for which this approach works and for those where it doesn't.
Let me know if you do, though 😄


Fix typename for value in map for python gen code

In Python, when using map with enums, the generated code would not output the full path for the enum that was defined in a separate file. This change outputs the full path for the type so that the generated code is correct.
There is a test case the shows the code is properly generated.
Previously the code would output this -
from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
from thrift.protocol.TProtocol import TProtocolException
from thrift.TRecursive import fix_spec
from enum import IntEnum

import sys
from .ttypes import *
typeConversion = {
        TestEnum.TestEnum0:     SharedEnum.SharedEnum0,
        TestEnum.TestEnum1:     SharedEnum.SharedEnum1,
}

And now it outputs this -
from thrift.Thrift import TType, TMessageType, TFrozenDict, TException, TApplicationException
from thrift.protocol.TProtocol import TProtocolException
from thrift.TRecursive import fix_spec
from enum import IntEnum

import sys
from .ttypes import *
typeConversion = {
        TestEnum.TestEnum0:     shared_types.ttypes.SharedEnum.SharedEnum0, # Change
        TestEnum.TestEnum1:     shared_types.ttypes.SharedEnum.SharedEnum1, # Change
}

[ ] Did you create an Apache Jira ticket?  (Request account here, not required for trivial changes)
[ ] If a ticket exists: Does your pull request title follow the pattern "THRIFT-NNNN: describe my issue"?
[x] Did you squash your changes to a single commit?  (not required, but preferred)
[x] Did you do your best to avoid breaking changes?  If one was needed, did you label the Jira ticket with "Breaking-Change"?
[ ] If your change does not involve any code, include [skip ci] anywhere in the commit message to free up build resources.

I just merged https://github.com/apache/thrift/commit/e497030b494b0fbdb662593ac58003a49a26048c to remove the consistently failing python 2 tests (which also prevent python 3 tests from running), can you please rebase your change on top of latest master so we can run the python3 tests?


Block unity3d.com pinpoll.com supl.google.com supl.vodafone.com nielsen.com klisc.or.ke

Lists in use:

Unified Hosts
Fakenews
Gambling
Porn
Social

Client:
Blokada/Android
Domains:
unity3d.com
www.unity3d.com
collect.analytics.unity3d.com
events.mz.unity3d.com
operate-sdk-telemetry.unity3d.com
pls.prd.mz.internal.unity3d.com
sdk-diagnostics.prd.mz.internal.unity3d.com

pinpoll.com
www.pinpoll.com
api.dmp.pinpoll.com

supl.google.com

supl.vodafone.com

nielsen.com
www.nielsen.com

klisc.or.ke

Details:

https://github.com/badmojr/1Hosts/issues/1246
https://github.com/badmojr/1Hosts/issues/1274
https://github.com/badmojr/1Hosts/issues/1277
https://github.com/badmojr/1Hosts/issues/1278
https://github.com/badmojr/1Hosts/issues/1283
https://github.com/badmojr/1Hosts/issues/1286

What evidence do you have to support the need to include these domains? I'm finding it very hard to accept most of these are necessary on any level.

unity3d.com
www.unity3d.com
pinpoll.com
www.pinpoll.com
nielsen.com
www.nielsen.com

All of these are "No" for obvious reasons.

supl.google.com
supl.vodafone.com

If you are unaware, this provides location based services for devices when the more prominent location API is not available (typically Google's API). It's a fall back method primarily used for emergency services (device based GPS). Your carrier can override any blocks in place via their own DNS as these are typically hard coded into the mobile OS... again for emergency purposes. I did a trace on the Vodafone domain and it just points to Google.
Non-authoritative answer:
Name:    supl.google.com
Addresses:  2607:f8b0:400e:c09::c0
          <IP_ADDRESS>
          <IP_ADDRESS>
Aliases:  supl.vodafone.com

It is pointless and ill advised to block either of these.

klisc.or.ke

Is not existent. DNS failure. Tried <IP_ADDRESS> and <IP_ADDRESS>.

api.dmp.pinpoll.com
events.mz.unity3d.com

Generally a bad idea to block APIs without any sort of evidence to support why you think it should be included. There are a handful of network debuggers you can use to do this. Both of these are used to facility server-side functions for services/software.

collect.analytics.unity3d.com
operate-sdk-telemetry.unity3d.com
pls.prd.mz.internal.unity3d.com
sdk-diagnostics.prd.mz.internal.unity3d.com

These are all for analytics. However, Unity MZ domains are used for call back functions. This may present a problem with apps if there is a pop-up consent form that never appears. Resulting in an app that can't or won't progress because there is no acceptance or denial.

Thank you for your input @icedterminal and thanks for the assist Gerd @hagezi
Denis @WebworkrNet I am closing this, and other issues like this, now.


Feedback Request

After using the tool, if you have any questions, comments, and/or feedback please let me know.
I initially implemented to how I think the community may use the tool, but won't know how it's actually being used until it has seen some action in the wild.
Personally, I am in the air about:
Names of nodes

Folder path seems like a good approach. We probably also need to include the entire path as the same folder name can exist in different spots in the file system. Though maybe we can implement a way to find the "common root" across the graph, to simplify the names (i.e. If ALL nodes come from C:/some/path/app/... we could probably remove C:/some/path)

Missing resources

I don't think it's common to include yamls in directories that contain kustomization.yaml files that the kustomization.yaml file does not reference. But maybe it is, or will be. Right now this feature is on by default. I could see it being problematic for graphs if the missing file is actually intended

Feel free to respond here, or open an issue.

looks very useful, should be a part of kustomize itself.


tNeo4jBatchOutput cannot update node properties.

Hello Benoît Simard,
I'm a developer from Talend. Our QA find a bug in component tNeo4jBatchOutput. It's better to fix on both of our repositories.
cf: https://jira.talendforge.org/browse/TDI-39736

Thanks it's corrected !
Do these components will be part of the next TDI version ?

Yes. They will be included in our next version 6.5.1 . Thanks you for providing these excellent components.


Configure the consumer properties programatically

Hi,
I tried to set my consumer properties programmatically instead of using application.yml but couldn't find anyway, I want to follow the example in this ticket https://github.com/spring-projects/spring-kafka/issues/897 which shows how you can do manual wiring in your interceptor. If I define the interceptor like below, it works
spring:
     cloud:
         kafka:
             binder:
                   consumer-properties:
                            interceptor.classes: xxx.yyy.zzz.MyInterceptor

But I couldn't find any way to do set this while creating Bean. I was told by @garyrussell to raise a feature request here.
So what I am trying to do is, having spring boot bean in spring cloud function interceptor.

Specifically: https://github.com/spring-projects/spring-kafka/issues/897#issuecomment-691112316

@ghahramani Unrelated to the core of this issue, but the property prefix you have above is incorrect, it should be spring.cloud.stream.kafka.binder....


Update CSI projects README.md to supported versions

Issue #, if available:
Description of changes:
Update CSI README.md supported versions
To be merged in May 1st once  EKS 1.25 is no longer officially maintained.
By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

@AndrewSirenko we are going to update the readme only after 1.30 official release.

/lgtm
/approve


Programming Exercises: Show build output even for successfull builds

Is your feature request related to a problem?
If builds/tests succeed accidentally, there seems to be no way to show any build output.
Describe the solution you'd like
The code editor should really show "Build Output" not only on failed CI runs.
We used to be able to access build output without the code editor by accessing the bamboo plan. It would be nice to have similar button in the "Course Management > Exercises > My Execise" view near the  template and solution result.
Describe alternatives you've considered
No response
Additional context
No response

Fixed in #8170, according to PR description.


fix otlp exporter test

Codecov Report

Merging #15 (48edf2d) into master (652b49a) will decrease coverage by 0.03%.
The diff coverage is n/a.

@@            Coverage Diff             @@
##           master      #15      +/-   ##
==========================================
- Coverage   94.21%   94.18%   -0.04%
==========================================
  Files         182      182
  Lines        7853     7853
==========================================
- Hits         7399     7396       -3
- Misses        454      457       +3

Impacted Files
Coverage Δ

sdk/include/opentelemetry/sdk/metrics/controller.h
90.32% <0.00%> (-6.46%)
:arrow_down:

sdk/test/common/circular_buffer_test.cc
98.97% <0.00%> (-1.03%)
:arrow_down:


Implement alternate certificate chains

Due to the upcoming transistion to a new intermediate certificate which will remain untrusted by older Android versions, Let's Encrypt will implement two alternate certificate chains. We should select between them somehow.
https://community.letsencrypt.org/t/transition-to-isrgs-root-delayed-until-jan-11-2021/125516

Latest Blog-Post https://letsencrypt.org/2020/11/06/own-two-feet.html
So would be great if we can activate the "legacy" Mode for Let's Encrypt. Otherwise we have a Problem in January!

As an aside, a strategy for sites that must provide connectivity to old versions of android is to switch acme CA to one with an existing established trusted root cert, e.g. ZeroSSL or BuyPass Go. Using the 'preferred chain' method will only defer the problem for a few months.

@webprofusion-chrisc I coudn't find the root cert ZeroSSL is using. Do you know which one they crossign with? Is it old enough for old Android phones?

@BenKmann it's this one, I couldn't tell you if it's actually available in android but it's 10 yrs old.

One last question, I see the milestone, but no PR and you closed the issue. So is this a closed "won't do"? Or a closed because we "added the feature in the next version"?
If it is a "won't do", why does it have a milestone version?
Thanks :)

It's just been released in version 2.1.13 👍


Feature/win

Change list
Add WindowsDriver and WindowsElement for use with https://github.com/appium/appium-windows-driver
Types of changes
What types of changes are you proposing/introducing to .NET client?
Put an x in the boxes that apply

[ ] Bugfix (non-breaking change which fixes an issue)
[x] New feature (non-breaking change which adds functionality)
[ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)

##Details
Some methods throw NotImplementedExceptions due to https://github.com/Microsoft/WinAppDriver/ (and therefore https://github.com/appium/appium-windows-driver) not supporting the functionality.

@yodurr Can you add the AccessibilityID test to this branch please?

what about code like this in WindowsMultiSelectControlTest.cs?  What other Accessibility ID API do you want to test?
AlarmClockSession.FindElementByAccessibilityId("AlarmPivotItem").Click();

@yodurr IFindByWindowsUIAutomation allows for much more complex queries than just locating an element by it's AccessibilityID.  It could also allow for complex interactions.  For example, here is an Android query that would scroll a scrollable view so that a view with a description containing my_description is made visible:
driver.FindElementByAndroidUIAutomator("new UiScrollable(new UiSelector().scrollable(true).instance(0)).scrollIntoView(new UiSelector().descriptionContains(\"my_description\").instance(0));");

@TikhomirovSergey Do you have any thoughts on this and are you happy with @yodurr's proposed AccessibilityId example test?

It looks ok. I want to publish one more (not major) build and then merge this PR.
I would like to ask you for a sample of the windows automation searching (you can post it as a comment).
Later it will be included to integration tests/
PS: I would like to add similar changes to the Java client with @jonstoneman authorship. Is it ok?

@jonstoneman
I'm going to publish the v.<IP_ADDRESS> on this weekend. And then I'm merging this PR.
There are conflicts. Sorry. It is my fault. I will resolve it on my own

@jonstoneman This PR was mergen successfully. Now you are free to develop it further. Also I'm going to improve some thing. Thank you for the contribution. I hope we will cooperate further. :)

Great! - thanks @TikhomirovSergey :)


charts use 1.0.0 image

What type of PR is this?
/kind enhancement
What this PR does / why we need it:
Which issue(s) this PR fixes:

Fixes #
Special notes for your reviewer:

Does this PR introduce a user-facing change?

other Note

/lgtm
/approve


chore(website): add System.Text.Json serialization support in the playground

Description

add System.Text.Json serialization support in the playground

Related issue(s)

Fixes #1175

You still have some outstanding changes that is needed, the website wont currently build 🙂

Pull Request Test Coverage Report for Build<PHONE_NUMBER>

0 of 0   changed or added relevant lines in 0 files are covered.
No unchanged relevant lines lost coverage.
Overall coverage remained the same at 92.196%

Totals

Change from base Build<PHONE_NUMBER>:
0.0%

Covered Lines:
5240

Relevant Lines:
5542

💛  - Coveralls

You still have some outstanding changes that is needed, the website wont currently build slightly_smiling_face

I have indentified some issues, which i'll fix.
Please don't tell me what's the issue yet :smile:
I'd like to try brainstorming and figuring it out on my own.

Also, why's the server even running when there're compilation errors on my local ? 🥲
Can you help me figure this out ?

@jonaslagoni why don't i see these errors when i run npm run build in my local machine ?

Are you running the build command under the website?
Hard for me to pinpoint anything by saying it worked locally 😄 There can be so many reasons why 🙂

@jonaslagoni why don't i see these errors when i run npm run build in my local machine ?

Are you running the build command under the website?
Hard for me to pinpoint anything by saying it worked locally 😄 There can be so many reasons why 🙂

reasonable 🙂
I'll send more context. A screen recording clip or something which you help.

So far it seems like you have all the things in place 🤔

@all-contributors please add @kaushik-rishi for code, design

This was a very great learning experience and i feel beginners will learn a lot about a lot of different things (type system, api routes, component structure, context api) by solving one such issue. I'm thereby attaching some notes :slightly_smiling_face:  which might help others landing here. Thanks @jonaslagoni :heart:

Playground Component

we have a config state, consisting of all the options of that can be given to all the languages, with their default values (type: ModelinaOptions)
render() method, parses the query params for persistence of the state between tab switches (generated code, options) (type: ModelinaQueryOptions)
We have the PlaygroundOptions component, embedded into a tree of components which are basically Context providers for different language options

/playground/options/CSharpGeneratorOptions.tsx Component

implement onChangeIncludeJson function
bind the function to this inside of the constructor for binding the component context
Add the option here and bind it with the onChange function and the state variable

/types/index.ts Type definitions

We add the newly added options into ModelinaCSharpOptions and ModelinaCSharpQueryOptions
the types (interfaces technically) ModelinaOptions and ModelinaQueryOptions extend the types of their respective language choices, so no need to worry about updating those types with your newly added options.

/pages/api/functions/CSharpGenerator.ts NextJS api endpoint

Code to actually generate the models, uses the modelina library and the presets

/helpers/GeneratorCode/CSharpGenerator.ts Component

function used to generate the generator code 🙂 (ik it's funny)
add respective code needed to change the generator code (could be just adding a preset to the template literal)

Might be nice to include these in the website docs 🤔 What do you think @kaushik-rishi?

@kaushik-rishi meant your description of the components in the website for other to get a quick start 😄

@jonaslagoni
Not sure if you'd want to have something of that sort on the website 🙂
Just incase you want to have it, I'll make a better documentation of state management inside the modelina-website and the description of folder structure in a proper manner. If that would help I'd be more than happy to do it 🙂

Not on the website, but here: https://github.com/asyncapi/modelina/blob/master/modelina-website/README.md 🙂


DEV: Update sidebar section selector due to core changes

Dependent on https://github.com/discourse/discourse/pull/20771

Thank you @lis2


Update glpaper to most recent version

Motivation for this change
Updates to most recent version.
Previous version would segfault.
Things done

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

[X] NixOS
[ ] macOS
[ ] other Linux distributions

[ ] Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
[ ] Tested compilation of all pkgs that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review wip"
[X] Tested execution of all binary files (usually in ./result/bin/)
[ ] Determined the impact on package closure size (by running nix path-info -S before and after)
[ ] Ensured that relevant documentation is up to date
[ ] Fits CONTRIBUTING.md.

Result of nixpkgs-review pr 112364 at 08e20420 run on x86_64-linux 1

1 package built:

glpaper

Result of nixpkgs-review pr 112364 at 08e20420 run on aarch64-linux 1

1 package built:

glpaper

Please change the commit message to read glpaper: unstable-2020-03-30 -> newVersion and update the version in the package to be unstable-date-of-the-commit.

Done. Changed version and commit to unstable-2020-10-11

Please change the commit message to read glpaper: unstable-2020-03-30 -> newVersion and update the version in the package to be unstable-date-of-the-commit.

Done. Changed version and commit to unstable-2020-10-11

Perfect! Thanks for the PR!
Will merge as soon as ofborg settles.


KeepAlive doesn't work on pages

Environment

Operating System: Linux
Node Version:     v16.14.2
Nuxt Version:     3.0.0-rc.12
Nitro Version:    0.6.0
Package Manager<EMAIL_ADDRESS>Builder:          vite
User Config:      -
Runtime Modules:  -
Build Modules:    -

Reproduction
https://stackblitz.com/edit/github-8d2nyn?file=app.vue,pages%2Findex.vue,pages%2Ftest.vue

Click toggle value should change to true
Change route to home then go back to test

Describe the bug
Despite of definePageMeta({   keepalive: true, }); test route state isn't cached
Additional context
No response
Logs
No response

 danielroe closed this as not planned

keepalive include/exclude props don't work with


The Google Login/Sign In button doesn't work.

Describe the bug
The google login / sign in button doesn't work. Clicking it just opens a new blank page. No authentication actually occurs
To Reproduce
Steps to reproduce the behavior:

Go to 'the website
Click on 'login
See error

Expected behavior
The google login/sign in thing actually appears. And the user can efficiently log in and sign in into the website.
Screenshots

Additional context
The user gets a better user experience.

Please assign this issue to me under gssoc'24 . Also add the labels level and gssoc.

can you assign this issue to me as I know how it work basiclly we use google auth for this I used in implies in various projects I have some example to dhoe you the google auth function here some example

under gssoc'24 level 3


Helpful functions

Hi!
I've been using this library, but I'm having some problems
Maybe my fixes will help make this library a little better.
Sorry for my bad english

Sorry there is too much going on in this PR, and it looks like some namespace changes got bundled up as well. If you want to get some of this stuff in try to make some smaller PRs and describe the importance of the changes involved


chore(master): release butler 11.1.0

:robot: I have created a release beep boop
11.1.0 (2024-04-08)
Features

license: Monitor high level Qilk Sense license usage across different license types (2c925b7), closes #1041
Scheduled removal of unused user Qlik Sense license (bac1258), closes #1042

Bug Fixes

Better, more complete check of config when starting Butler (1e769dd)
Make handling of reload failed/aborted/succeeded messages more robust (eaf609e), closes #1034
Remove Node.js warnings on Butler startup (e489d4b), closes #1037
startup: More consistent logging during startup (e0cce7b), closes #991
Tidy up formatting of startup info written to logs (c337aa1), closes #991

Miscellaneous

deps: Update dependencies (0c5890e)
deps: Update dependencies (fc4c34c)
master: release butler 11.0.3 (f15dfe5)
Optimize GH Actions for building binaries (cfc024f)
Remove udp client from Butler project, move to its own repo (70817f0)
Sign Win binaries with new signing solution (e8e91d5), closes #1004

This PR was generated with Release Please. See documentation.

:robot: Release is at https://github.com/ptarmiganlabs/butler/releases/tag/untagged-87a7af288ca6a0ccd29e :sunflower:


Laravel 10 support for yajra/laravel-datatables-oracle

Summary of problem or feature request:
In a fresh LARAVEL 10.4.1 project, after only adding composer require laravel/ui and php artisan ui bootstrap --auth, installing the latest yajra/laravel-datatables-oracle according the documentation by issuing the command composer require yajra/laravel-datatables-oracle:"^10.0" throws an error concerning conflicting libraries.
Code snippet of problem:
PS > composer require yajra/laravel-datatables-oracle:"^10.0"
The "10.0" constraint for "yajra/laravel-datatables-oracle" appears too strict and will likely not match what you want. See https://getcomposer.org/constraints
./composer.json has been updated
Running composer update yajra/laravel-datatables-oracle
Loading composer repositories with package information
Updating dependencies
Your requirements could not be resolved to an installable set of packages.

  Problem 1
    - Root composer.json requires yajra/laravel-datatables-oracle 10.0 -> satisfiable by yajra/laravel-datatables-oracle[v10.0.0].
    - yajra/laravel-datatables-oracle v10.0.0 requires illuminate/database ^9 -> found illuminate/database[v9.0.0, ..., v9.52.4] but these were not loaded, likely because it conflicts with another require.

Installation failed, reverting ./composer.json and ./composer.lock to their original content.

System details:
Windows 11 Version 22H2
PHP Version 8.2.4
Laravel Version 10.4.1
Yajra Laravel-Datatables Version 10
Questions:

What is the correct composer command to install the yajra/laravel-datatables-oracle package in Laravel 10?
Can the documentation be adapted to reflect the correct composer require command?

Thanks.

Updated the version constraint to ^10.3.1, thanks!


docs: update readme.RU.md

Improve translation and fix typos.

@php-coder Thank you for taking the time to contribute!


Add managed identities for azure container apps

Add managed identities for Azure Container Apps

Next steps to finalize the task:

Add managed identities to bonus assignments
Update the diagram of the container apps challenged to add managed identities
Update the diagram of the scaling to add managed identities


Test: Private Key feature

Show private key
Import account via private key

Added for AE, ETH, BTC


BUG: Uploading csv with index creates double index and breaks render

When downloading a fresh CSV from the template, Excel adds a row-index by default. Our tool does not check whether an index already exists, so it adds another one, which breaks the mapping between the values and expected column names. Especially the statement type is then not found, which means the nodes are rendered in black and you can't read the text.

Thank you for discovering it!
I see it. I can try to work on it if it sound ok for you.


Ie11 symbol js error

Implementing browserslist with babel and set it to all browsers with over 0.5%, and specifically Internet Explorer 9 and above.

This PR will be incorporated into https://github.com/bring/hedwig/pull/681


Request: Add PureScript grammar

It should be relatively similar to the Haskell formatter.

The core team doesn't have a plan for ongoing development of new syntaxes (typically it's all we can do to keep up with support, issues, PRs, etc) - building support for new languages is all up to the larger community.  If you'd really like to see this language, perhaps you know a developer who'd be willing to put in the time to develop and maintain a grammar for it?

Rather than leave these issues open to languish forever (as we have in the past) we're going to start closing them (to clean up the issues list).
I've moved this request to the wish list:
https://github.com/highlightjs/highlight.js/wiki/Grammar-Requests


Numerical Problem in tf.nn.softmax_cross_entropy_with_logits

The function tf.nn.softmax_cross_entropy_with_logits(logits, labels) is numerical unstable when used in weak labelling scenarios (i.e. there are no labels for some rows of the labels).
The instability does not occure, when using tf.nn.softmax followed by a simple cross_entropy implementation, i.e.:
epsilon = tf.constant(value=0.00001, shape=shape)
logits = logits + epsilon
softmax = tf.nn.softmax(logits)
cross_entropy = -tf.reduce_sum(labels * tf.log(softmax),
                                                 reduction_indices=[1])

I therefore conclude, that this is a bug occurring in the softmax layer. I can not give a a minimal example, as it only occurs in bigger models. Also, I did only observe the Bug when using weakly labeled data, that is, when cases without labels occur. This case however is explicitly mentioned in the documentation.
labels: Each row labels[i] must be a valid probability distribution or all zeros. If all zeros, the corresponding loss will be 0, regardless of the contents of logits[i].
If the unstability occurs, tf.nn.softmax_cross_entropy_with_logits() produces high gradients, causing the training process to diverge. This usually happens after about 450 iterations. Changing the learning rate will not avoid this issue.
Environment info
Operating System: Linux
Installed version of CUDA and cuDNN: CUDA 7.5; CUDNN 7.0
Installed from Pip:

Which pip package you installed. https://storage.googleapis.com/tensorflow/linux/cpu/tensorflow-0.8.0-cp27-none-linux_x86_64.whl
The output from python -c "import tensorflow; print(tensorflow.version)". 0.8.0

Steps to reproduce

Use loss function provided below
Use data containing about 10% unlabeled entries.

What have you tried?

Implementing tf.nn.softmax_cross_entropy_with_logits() myselfe. It works fine.

Logs or other output that would be helpful
(If logs are large, please upload as attachment).
The error occurs, when estimating the loss like below.
def loss(hypes, logits, labels):
    """Calculates the loss from the logits and the labels.
    Args:
      logits: Logits tensor, float - [batch_size, 2].
      labels: Labels tensor, int32 - [batch_size, 2].
    Returns:
      loss: Loss tensor of type float.
    """

    with tf.name_scope('loss'):
        logits = tf.reshape(logits, (-1, 2))
        labels = tf.to_float(tf.reshape(labels, (-1, 2)))
        shape = [logits.get_shape()[0], 2]
        epsilon = tf.constant(value=hypes['solver']['epsilon'], shape=shape)
        logits = logits + epsilon
        cross_entropy = tf.nn.softmax_cross_entropy_with_logits(
            logits, labels, name='xentropy')

        cross_entropy_mean = tf.reduce_mean(
            cross_entropy, name='xentropy_mean')
        tf.add_to_collection('losses', cross_entropy_mean)

        loss = tf.add_n(tf.get_collection('losses'), name='total_loss')
    return loss

When the error occurs my training output looks like this:
2016-05-10 20:20:56,256 root INFO Step 0/10000: loss = 11.98 ( 0.013 sec (per Batch); 74.5 examples/sec)
2016-05-10 20:21:01,804 root INFO Step 10/10000: loss = 11.47 ( 0.028 sec (per Batch); 35.1 examples/sec)
2016-05-10 20:21:07,565 root INFO Step 20/10000: loss = 10.82 ( 0.029 sec (per Batch); 34.7 examples/sec)
2016-05-10 20:21:12,554 root INFO Step 30/10000: loss = 10.32 ( 0.028 sec (per Batch); 35.5 examples/sec)
2016-05-10 20:21:17,317 root INFO Step 40/10000: loss = 9.90 ( 0.028 sec (per Batch); 35.5 examples/sec)
2016-05-10 20:21:22,387 root INFO Step 50/10000: loss = 9.50 ( 0.028 sec (per Batch); 35.4 examples/sec)
2016-05-10 20:21:27,209 root INFO Step 60/10000: loss = 9.27 ( 0.028 sec (per Batch); 35.4 examples/sec)
2016-05-10 20:21:32,134 root INFO Step 70/10000: loss = 8.75 ( 0.028 sec (per Batch); 35.4 examples/sec)
2016-05-10 20:21:37,198 root INFO Step 80/10000: loss = 8.34 ( 0.028 sec (per Batch); 35.3 examples/sec)
2016-05-10 20:21:42,074 root INFO Step 90/10000: loss = 8.10 ( 0.028 sec (per Batch); 35.3 examples/sec)
2016-05-10 20:21:49,483 root INFO Doing Evaluate with Training Data.
2016-05-10 20:22:09,883 root INFO Data: train  Num examples:  200  Num correct:  168.3478 Precision @ 1:  0.8417
2016-05-10 20:22:09,883 root INFO Doing Evaluation with Testing Data.
2016-05-10 20:22:15,032 root INFO Data: val  Num examples:  50  Num correct:  41.3079 Precision @ 1:  0.8262
2016-05-10 20:22:15,323 root INFO Step 100/10000: loss = 8.03 ( 0.003 sec (per Batch); 344.2 examples/sec)
2016-05-10 20:22:20,180 root INFO Step 110/10000: loss = 7.56 ( 0.028 sec (per Batch); 35.2 examples/sec)
2016-05-10 20:22:25,208 root INFO Step 120/10000: loss = 7.13 ( 0.028 sec (per Batch); 35.4 examples/sec)
2016-05-10 20:22:30,053 root INFO Step 130/10000: loss = 6.93 ( 0.028 sec (per Batch); 35.5 examples/sec)
2016-05-10 20:22:34,883 root INFO Step 140/10000: loss = 6.65 ( 0.028 sec (per Batch); 35.3 examples/sec)
2016-05-10 20:22:39,765 root INFO Step 150/10000: loss = 6.34 ( 0.028 sec (per Batch); 35.4 examples/sec)
2016-05-10 20:22:44,741 root INFO Step 160/10000: loss = 6.23 ( 0.028 sec (per Batch); 35.3 examples/sec)
2016-05-10 20:22:49,867 root INFO Step 170/10000: loss = 5.88 ( 0.028 sec (per Batch); 35.3 examples/sec)
2016-05-10 20:22:54,890 root INFO Step 180/10000: loss = 5.70 ( 0.028 sec (per Batch); 35.2 examples/sec)
2016-05-10 20:22:59,822 root INFO Step 190/10000: loss = 5.61 ( 0.028 sec (per Batch); 35.3 examples/sec)
2016-05-10 20:23:07,190 root INFO Doing Evaluate with Training Data.
2016-05-10 20:23:27,775 root INFO Data: train  Num examples:  200  Num correct:  167.6011 Precision @ 1:  0.8380
2016-05-10 20:23:27,776 root INFO Doing Evaluation with Testing Data.
2016-05-10 20:23:32,933 root INFO Data: val  Num examples:  50  Num correct:  42.5874 Precision @ 1:  0.8517
2016-05-10 20:23:33,231 root INFO Step 200/10000: loss = 5.41 ( 0.003 sec (per Batch); 336.0 examples/sec)
2016-05-10 20:23:38,108 root INFO Step 210/10000: loss = 5.36 ( 0.028 sec (per Batch); 35.4 examples/sec)
2016-05-10 20:23:43,053 root INFO Step 220/10000: loss = 5.05 ( 0.028 sec (per Batch); 35.3 examples/sec)
2016-05-10 20:23:48,021 root INFO Step 230/10000: loss = 4.96 ( 0.028 sec (per Batch); 35.4 examples/sec)
2016-05-10 20:23:52,982 root INFO Step 240/10000: loss = 4.70 ( 0.028 sec (per Batch); 35.2 examples/sec)
2016-05-10 20:23:58,049 root INFO Step 250/10000: loss = 4.55 ( 0.028 sec (per Batch); 35.5 examples/sec)
2016-05-10 20:24:03,004 root INFO Step 260/10000: loss = 4.43 ( 0.028 sec (per Batch); 35.1 examples/sec)
2016-05-10 20:24:07,973 root INFO Step 270/10000: loss = 4.32 ( 0.029 sec (per Batch); 35.0 examples/sec)
2016-05-10 20:24:12,886 root INFO Step 280/10000: loss = 4.14 ( 0.028 sec (per Batch); 35.3 examples/sec)
2016-05-10 20:24:17,765 root INFO Step 290/10000: loss = 4.80 ( 0.028 sec (per Batch); 35.3 examples/sec)
2016-05-10 20:24:25,209 root INFO Doing Evaluate with Training Data.
2016-05-10 20:24:45,899 root INFO Data: train  Num examples:  200  Num correct:  156.8744 Precision @ 1:  0.7844
2016-05-10 20:24:45,900 root INFO Doing Evaluation with Testing Data.
2016-05-10 20:24:51,048 root INFO Data: val  Num examples:  50  Num correct:  40.3362 Precision @ 1:  0.8067
2016-05-10 20:24:51,349 root INFO Step 300/10000: loss = 6.08 ( 0.003 sec (per Batch); 333.3 examples/sec)
2016-05-10 20:24:56,176 root INFO Step 310/10000: loss = 136.59 ( 0.028 sec (per Batch); 35.4 examples/sec)
2016-05-10 20:25:01,130 root INFO Step 320/10000: loss = 2029.89 ( 0.028 sec (per Batch); 35.6 examples/sec)
2016-05-10 20:25:05,964 root INFO Step 330/10000: loss = 75585.02 ( 0.028 sec (per Batch); 35.6 examples/sec)
2016-05-10 20:25:10,901 root INFO Step 340/10000: loss = 7492798.00 ( 0.028 sec (per Batch); 35.5 examples/sec)
2016-05-10 20:25:15,863 root INFO Step 350/10000: loss = 50291024.00 ( 0.028 sec (per Batch); 35.4 examples/sec)
2016-05-10 20:25:20,790 root INFO Step 360/10000: loss =<PHONE_NUMBER>.00 ( 0.028 sec (per Batch); 35.4 examples/sec)
2016-05-10 20:25:25,716 root INFO Step 370/10000: loss =<PHONE_NUMBER>.00 ( 0.028 sec (per Batch); 35.4 examples/sec)
2016-05-10 20:25:30,749 root INFO Step 380/10000: loss =<PHONE_NUMBER>28.00 ( 0.028 sec (per Batch); 35.5 examples/sec)
2016-05-10 20:25:35,588 root INFO Step 390/10000: loss =<PHONE_NUMBER>792.00 ( 0.028 sec (per Batch); 35.5 examples/sec)
2016-05-10 20:25:43,335 root INFO Doing Evaluate with Training Data.

When training longer, the loss will eventually become Nan. The error does not occure, when using the following Loss Code:
def loss(hypes, logits, labels):
    """Calculates the loss from the logits and the labels.

    Args:
      logits: Logits tensor, float - [batch_size, 2].
      labels: Labels tensor, int32 - [batch_size, 2].

    Returns:
      loss: Loss tensor of type float.
    """
    with tf.name_scope('loss'):
        logits = tf.reshape(logits, (-1, 2))
        shape = [logits.get_shape()[0], 2]
        epsilon = tf.constant(value=hypes['solver']['epsilon'], shape=shape)
        logits = logits + epsilon
        labels = tf.to_float(tf.reshape(labels, (-1, 2)))

        softmax = tf.nn.softmax(logits)
        cross_entropy = -tf.reduce_sum(labels * tf.log(softmax),
                                       reduction_indices=[1])

        cross_entropy_mean = tf.reduce_mean(cross_entropy,
                                            name='xentropy_mean')
        tf.add_to_collection('losses', cross_entropy_mean)

        loss = tf.add_n(tf.get_collection('losses'), name='total_loss')
    return loss

As stated in the documentation, we require a valid probability distribution.  Unfortunately, for speed reasons, we don't check this precondition.  Therefore, this is expected behavior.  Implementing your own loss in terms of other ops is the right fix.

@girving no, the documentation reads: labels: Each row labels[i] must be a valid probability distribution or all zeros. My data does forfill this condition. (i.e. in cases where a valid probability distribution is not given, all are zero). However, changing the documentation to labels: Each row labels[i] must be a valid probability distribution. might be a solution.


feat: [Example App] keep recording on reboot + allow to delete them

Add getRecordedAudios that fetches m4a audio files from the cache for Android or document for iOS.
Add a delete button to delete all the recordings, ~but an app reboot is required to see the effect!~

Hey, I rebase and revalidate that so that we can see the icon on iOS!

@kuldip-simform do you mind reapproving, 🙏 , I simply rebase from develop to fix a conflict


Update manage-services-using-git-experience.md

Harness Developer Pull Request
Thanks for helping us make the Developer Hub better. The PR will be looked at
by the CODEOWNERS.
What Type of PR is This?

[ ] Issue
[ ] Feature
[ ] Maintenance/Chore

If tied to an Issue, list the Issue(s) here:

Issue(s)

House Keeping
Some items to keep track of. Screen shots of changes are optional but would help the maintainers review quicker.

[ ] Tested Locally
[ ] Optional Screen Shoot.

Please check the Execution Link of the Pipeline for the Website Draft URL. This is located in the Preview Step behind the Harness VPN and also is available in #hdh_alerts. E.g Website Draft URL: https://unique-id--harness-developer.netlify.app. Current Draft URL is: https://65970a9748019a2c0772ccb0--harness-developer.netlify.app

Please check the Execution Link of the Pipeline for the Website Draft URL. This is located in the Preview Step behind the Harness VPN and also is available in #hdh_alerts. E.g Website Draft URL: https://unique-id--harness-developer.netlify.app. Current Draft URL is: https://65970b1bebd0962c6db143ed--harness-developer.netlify.app


feat: add new command info

xst info will gather useful system information.
The output can directly be used to add to eXist issues.
Example output:
❯ xst info
OS: Mac OS X 12.6.2 (aarch64)
Java: 1.8.0_352 (Azul Systems, Inc.)
Build: eXist-6.1.0-SNAPSHOT (89109f644c19482a0f48f7d47619589ba2f14092)

During today's Community Call, I was reminded of some previous scripts I wrote that do similar things:

"Populate version info for the eXist issue tracker": https://gist.github.com/joewiz/6a157163034a3111dcf72346af36470b
"Display all system properties and their values - for eXist-db": https://gist.github.com/joewiz/2506adc9efbeed33c9412b4854e18712

We also noted that it would be useful to display this info in Dashboard > Settings (which already shows the current commit ID). I'll open an issue there.


Preferences

Create a switch to toggle email notifications under profile modal
To test:

Pull preferences branch
In ozp-center directory, open up package.json with any editor
Find whereit says ozp-react-commons and change the github link to your local ozp-react-commons preference branch
Remove ozp-center/node_modules/ozp-react-commons folder
Once removed, do a 'npm install'. Your local copy of ozp-react-commons should be in node_modules now
Start up center and go to profile to see the email preferences. Toggle the email switch.
Do a GET call to http://localhost:8001/api/self/profile/ and check for "email_notification_flag". The switch should represent the same value as the flag.

:+1:


RFC: Styled transformer configuration

Styled components has the withConfig API. I think we can abuse that and use it for compile time features so consumers only opt into them if needed.
.withConfig({
  forwardRef: true,
});

Would then wrap the transform with a forwardRef.

One thing I'd like is to push developers to just use the css prop over styled api if they need advanced thing. Like for example for shouldForwardProp api from Styled Components - just use css prop, man!

We won't do this. Need more configuration? Use css prop.


Set up multitarget projects

Motivation
MS has released .NET 6 RC2 which will be the next version of .NET, and it seems like Kontent Delivery SDK does not support it
yet:
TODO:

[x] Add information about target best practices.

Related to https://github.com/Kentico/kontent-generators-net/pull/126
Proposed solution
Update the SDK to support the latest .NET.
Check out https://github.com/Kentico/kontent-delivery-sdk-net/pull/296

Information about projects targets: https://github.com/Kentico/Home/wiki/Kentico's-best-practices-for-.csproj-files#target-framework


#12, use debian testing repo in addition to being the base system

use debian testing repo in addition to being the base system. The testing system of today has the required version of happy, but "stretch" doesn't

hm, it seems I've misunderstood the docker file in my change so it probably doesn't fix the problem. So I wonder, why is happy < 1.19.10 in the image?

so perhaps this pull request isn't the right thing to do - at least not without the haskell.org repos being updated first.


Getting "You are not logged in" while using ROBLOXSECURITYto sign in

Describe the bug
I've got the ROBLOXSECURITY from the cookies in applications tab after logging in, and trying to use it like this:
noblox.setCookie(process.env.ROBLOXSECURITY)

results in "you are not logged in", and does not let noblox.sendTrade work.
In the above have logged the env variable and that's working.
Expected behavior
Setting the cookie should not result in error.
Screenshots

What host are you using? If you're using a free host such as repl that doesn't support ssh it won't work

@zachariapopcorn Sorry for the late reply, I think this is using an AWS deployed server to make the call?
Anyway this issue can be closed from my end, couldn't solve but not using roblox anymore. Thanks for the reply! :D


Runtime Error : index upvalue 'domain' (a nil value)

I've installed the loa module on my raspberry pi 1 which i'm using as a reverse proxy.
I've tried to protect one of my locations via the oauth2 module:
  location ~ ^/(ifttt|_oauth) {
      set $ngo_client_id         "123demo.apps.googleusercontent.com";
      set $ngo_client_secret     "secret";
      set $ngo_token_secret      "mysecret";
      set $ngo_secure_cookies    "true";
      set $ngo_http_only_cookies "true";
      access_by_lua_file "/etc/nginx/lua/access.lua";
  }

And added the resolver and ssl config for lua.
After getting the request in /_oauth i get a returncode 500 and this error in the errorlog:
error] 4207#4207: *4 lua entry thread aborted: runtime error: /etc/nginx/lua/access.lua:64: attempt to index upvalue 'domain' (a nil value)
stack traceback:
coroutine 0:
        /etc/nginx/lua/access.lua: in function 'check_domain'
        /etc/nginx/lua/access.lua:92: in function 'on_auth'
        /etc/nginx/lua/access.lua:234: in function 'authorize'

I've also tried to specify a domain, but same result.
set $ngo_domainn           "gmail.com";
Is this a config problem or a bug?

set $ngo_domainn "gmail.com";

You have an extra n at the end of ngo_domainn. Fix that and it should work.
It is also possible to set it to an empty string to allow any domain.


Not finding a saved file

Type: Feature Request
Hello,
As I move forward with learning Python I am now stuck with this issue.
Please see the attached screen shot.
I am working on and learning to get and read information from a txt file.
I have creatated said txt.file and saved it within the Python_work folder where all other files are located and stored.
When I write this code (as per screen shot) it cannot find the file within the same folder.
I also am very confused regarding the traceback.
As far as I am aware, I have entered and writen as per Python Crash course Book.
Help would be super appreciated
VS Code version: Code 1.85.1 (0ee08df0cf4527e40edc9aa28f4b5bd38bbff2b2, 2023-12-13T09:49:37.021Z)

OS version: Windows_NT x64 10.0.19045
Modes:

/question

We closed this issue because it is a question about using VS Code rather than an issue or feature request. Please search for help on StackOverflow, where the community has already answered thousands of similar questions. You may find their guide on asking a new question helpful if your question has not already been asked. See also our issue reporting guidelines.
Happy Coding!


[#222] Add new workflow to automate the mason bundle updating process after modifying the bundle config

Solves #222

What happened 👀
After testing the newly generated project has passed, we need a job to generate the Mason bundles, then commit and push in cases there're any changes.
This PR is to create that automated job of the CI workflow.
Insight 📝
According to the requirement, we should create a new workflow (generate_mason_bundle.yml). However, if we create a brand new workflow, we will need to use the workflow_dispatch to trigger the generate_mason_bundle.yml workflow inside the test.yml workflow. That approach still resolves our issue, but it will be overused in this case.
According to this document, I think we just need to define a new job named generate_mason_bundle inside the test.yml workflow:

A workflow run is made up of one or more jobs, which run in parallel by default. To run jobs sequentially, you can define dependencies on other jobs using the jobs.<job_id>.needs keyword.

So technically, I think the approach for this task in the test.yml file is that:
...
jobs:
  test:
  ...
  generate_mason_bundle:
    # The job generate_mason_bundle identify that the job test must complete successfully
    # before this generate_mason_bundle job will run
    needs: test
    ...

Proof Of Work 📹
When the Mason bundle does NOT have changes

Template initializing scripts test had completed then Generate Mason bundle started.
Skip the step Commit & push the sample project changes

When the Mason bundle has changes

Template initializing scripts test had completed then Generate Mason bundle started.
Run the step Commit & push the sample project changes
There is a commit for Mason bundle change:

Hi @nmint8m, there are 2 issues left here 👋


'zhmc partition console' asks for password again although session already created

Copied from zhmcclient/python-zhmcclient#308 (opened by leopoldjuergen):
Actual behavior
$ zhmc cpc list
+----------+------------------+
| name     | status           |
|----------+------------------|
| P000S67B | service-required |
+----------+------------------+
$ zhmc partition console P000S67B UbuntuDemo2
Enter password (for user pedebug at HMC <IP_ADDRESS>):
Expected behavior
No password request
Execution environment

zhmcclient version: zhmc, version 0.13.1.dev40
Operating system (type+version): Ubuntu 14.04
HMC version: 2.13.1
CPC version:

I was able to verify this behavior (cpc list works without prompting for password, partition console asks for password) with zhmc v0.13.1.dev50 (branch andy/fix-find-partition) on RHEL 7.3, with ZHMC_HOST, ZHMC_USERID and ZHMC_SESSION env vars set.

I investigated this and found that there is a reason for the password prompt:
The code establishes a notification listener for the OS message notifications. In order to do that, a password is needed for logging on to the Stomp connection (see NotificationReceiver.__init__()). Because the zhmc command was used with a session stored in the environment, a password was not available and needed to be prompted for.
If the zhmc partition console command is executed with the -p option instead of relying on the ZHMC_SESSION env var, that password is used and no password prompt occurs.
I believe it is not possible to use a saved session ID with Stomp, but it deserves further investigation to be sure.

Reading the HMC API book 2.13.1 reveals this (CHapter 4, section "Connecting to the API message broker"):
In order to connect to the integrated message broker, clients must provide a valid HMC user name and
password in order to identify the HMC user making the connection. This information is validated using
the standard HMC user authentication mechanisms before allowing the connection to succeed. The
integrated message broker does not allow any anonymous or unauthenticated connections.
It does not mention session IDs, so I'm pretty sure it does not support them there.


Generalize the use of constant time ecdh::shared_secret_point

Build up on 629ca8062eaa688a6ce70f75839d5216200d76c1 that removes the use of mul_tweak() and display 2 distincts calculate_shared_point() api in utils, one for sending and the other for receiving. While very similar I think that it will help implementors figure out what argument goes where when you're either on receiver or sender side.

ACK, I think it makes sense and in case we need the full pubkey as byte array. I propose a small improvement: since shared_secret_point() can't fail and guarantee to return a valid point on the curve, I think it's safe to simply expect() the conversion to PublicKey, this way we don't need to return a Result and that can be more confortable for the caller (Result can be annoying in closure for example). But that's just a suggestion, if you'd rather not take the chance just drop the last commit and merge it as it is.


Switch to yarn and make the zip size smaller

By adopting yarn autoclean, I was able to get below 50MB on the latest commit at least, which works pretty well for more tight cloud services like Tencent Cloud.

I've added clean-modules support because it's easier to add than yarn as a dependency. It also has a more extensive list of files it removes (https://github.com/duniul/clean-modules/blob/main/.cleanmodules-default) vs yarns (https://github.com/yarnpkg/yarn/blob/master/src/cli/commands/autoclean.js#L16).
Note that this will only affect the layer zip and if the package is included as a dependency it doesn't do anything

That's super cool, thank you!


jsonnet: 0.16.0 -> 0.17.0

Automatic update generated by nixpkgs-update tools. This update was made based on information from https://github.com/google/jsonnet/releases.
meta.description for jsonnet is: "Purely-functional configuration language that helps you define JSON data"
meta.homepage for jsonnet is: "https://github.com/google/jsonnet"
meta.changelog for jsonnet is: ""
Updates performed

Version update

To inspect upstream changes

Release on GitHub

Compare changes on GitHub

Impact

Checks done (click to expand)

built on NixOS

The tests defined in passthru.tests, if any, passed

0 of 0 passed binary check by having a zero exit code.

0 of 0 passed binary check by having the new version present in output.

found 0.17.0 with grep in /nix/store/rmvjljk9a8cfkp7hl3wbmhabnk2p2n8b-jsonnet-0.17.0

directory tree listing: https://gist.github.com/d49f8cd0f22530d63ba59a7ca635adc0

du listing: https://gist.github.com/33478e0c518540292794cc97b3eeaa88

Rebuild report (if merged into master) (click to expand)

16 total rebuild path(s)

4 package rebuild(s)

4 x86_64-linux rebuild(s)
4 i686-linux rebuild(s)
4 x86_64-darwin rebuild(s)
4 aarch64-linux rebuild(s)

First fifty rebuilds by attrpath
jsonnet
python27Packages.jsonnet
python37Packages.jsonnet
python38Packages.jsonnet

Instructions to test this update (click to expand)

Either download from Cachix:
nix-store -r /nix/store/rmvjljk9a8cfkp7hl3wbmhabnk2p2n8b-jsonnet-0.17.0 \
  --option binary-caches 'https://cache.nixos.org/ https://nix-community.cachix.org/' \
  --option trusted-public-keys '
  nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs=
  cache.nixos.org-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY=
  '

(The Cachix cache is only trusted for this store-path realization.)
For the Cachix download to work, your user must be in the trusted-users list or you can use sudo since root is effectively trusted.
Or, build yourself:
nix-build -A jsonnet https://github.com/r-ryantm/nixpkgs/archive/4cad7f6cfd7729261bf01b964e1a0230487dd981.tar.gz

After you've downloaded or built it, look at the files and if there are any, run the binaries:
ls -la /nix/store/rmvjljk9a8cfkp7hl3wbmhabnk2p2n8b-jsonnet-0.17.0
ls -la /nix/store/rmvjljk9a8cfkp7hl3wbmhabnk2p2n8b-jsonnet-0.17.0/bin

Pre-merge build results
We have automatically built all packages that will get rebuilt due to
this change.
This gives evidence on whether the upgrade will break dependent packages.
Note sometimes packages show up as failed to build independent of the
change, simply because they are already broken on the target branch.
Result of nixpkgs-review 1

4 packages built:

jsonnet
python27Packages.jsonnet
python37Packages.jsonnet
python38Packages.jsonnet

Maintainer pings
cc @benley @copumpkin for testing.

Result of nixpkgs-review pr 104998 run on x86_64-darwin 1

4 packages built:

jsonnet
python27Packages.jsonnet
python37Packages.jsonnet
python38Packages.jsonnet


Feat:Create News Cards #422

Created News Cards
Fixes #422
Type of change
https://github.com/VanshKing30/FoodiesWeb/assets/101548649/87189287-1981-4392-879a-61888dc1cffc
Please mark with an X the type that applies:

[ ] Bug fix (non-breaking change which fixes an issue)
[X ] New feature (non-breaking change which adds functionality)
[ ] Refactor code
[ ] Documentation update
[ ] Other (mentioned in the issue number)

How Has This Been Tested?
Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce them. Please also list any relevant details for your test configuration.
Test A: Describe here
Test B: Describe here (if required)
Screenshots and Videos
Please provide screenshots and videos of the changes you made.
Checklist
Please mark with an X the items that apply:

[X ] My code follows the style guidelines of this project
[ X] I have performed a self-review of my code
[X ] I have commented my code, particularly in hard-to-understand areas
[X ] I have made corresponding changes to the documentation
[X ] My changes generate no new warnings
[X ] I have added tests that prove my fix is effective or that my feature works
[ X] New and existing unit tests pass locally with my changes
[ X] Any dependent changes have been merged and published in downstream modules

hey @hustlerZzZ please assign it level accordingly

Hey @hustlerZzZ can it be considered for level 2 ?


import apkverify error

pkcs7verify could not be import.
$ ls
LICENSE		apkfile.py	apkfile.pyc	apkverify.py	apkverify.pyc	pkcs7verify.py	pkcs7verify.pyc
$ python
Python 2.7.14 (default, Mar 14 2018, 16:20:41)
[GCC 4.2.1 Compatible Apple LLVM 9.0.0 (clang-9<IP_ADDRESS>)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> import apkverify
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "apkverify.py", line 12, in <module>
    from pkcs7verify import check_sig, check_sig_v2
  File "pkcs7verify.py", line 425, in <module>
    class TBSCertificate(univ.Sequence):
  File "pkcs7verify.py", line 440, in TBSCertificate
    explicitTag=tag.Tag(tag.tagClassContext, tag.tagFormatSimple, 3)))
  File "/usr/local/lib/python2.7/site-packages/pyasn1/type/namedtype.py", line 158, in __init__
    self.__tagToPosMap = self.__computeTagToPosMap()
  File "/usr/local/lib/python2.7/site-packages/pyasn1/type/namedtype.py", line 253, in __computeTagToPosMap
    return NamedTypes.PostponedError('Duplicate component tag %s at %s' % (_tagSet, namedType))
  File "/usr/local/lib/python2.7/site-packages/pyasn1/type/namedtype.py", line 49, in __repr__
    representation = '%s=%r' % (self.name, self.asn1Object)
  File "/usr/local/lib/python2.7/site-packages/pyasn1/type/base.py", line 479, in __repr__
    representation += ' %s=%r' % (attr, value)
  File "/usr/local/lib/python2.7/site-packages/pyasn1/type/namedtype.py", line 175, in __repr__
    representation = ', '.join(['%r' % x for x in self.__namedTypes])
  File "/usr/local/lib/python2.7/site-packages/pyasn1/type/namedtype.py", line 49, in __repr__
    representation = '%s=%r' % (self.name, self.asn1Object)
  File "/usr/local/lib/python2.7/site-packages/pyasn1/type/base.py", line 479, in __repr__
    representation += ' %s=%r' % (attr, value)
  File "/usr/local/lib/python2.7/site-packages/pyasn1/type/base.py", line 479, in __repr__
    representation += ' %s=%r' % (attr, value)
  File "pkcs7verify.py", line 306, in __repr__
    if not type:
  File "/usr/local/lib/python2.7/site-packages/pyasn1/type/base.py", line 287, in __nonzero__
    return self._value and True or False
  File "/usr/local/lib/python2.7/site-packages/pyasn1/type/base.py", line 199, in plug
    raise error.PyAsn1Error('Attempted "%s" operation on ASN.1 schema object' % name)
pyasn1.error.PyAsn1Error: Attempted "__nonzero__" operation on ASN.1 schema object
>>>

use pyasn1=0.1.9
Get Outlook for iOShttps://aka.ms/o0ukef

From: fei_cong<EMAIL_ADDRESS>Sent: Wednesday, April 25, 2018 6:21:27 PM
To: shuxin/apk-signature-verify
Cc: Subscribed
Subject: [shuxin/apk-signature-verify] import apkverify error (#1)
pkcs7verify could not be import.
$ ls
LICENSE         apkfile.py      apkfile.pyc     apkverify.py    apkverify.pyc   pkcs7verify.py  pkcs7verify.pyc
$ python
Python 2.7.14 (default, Mar 14 2018, 16:20:41)
[GCC 4.2.1 Compatible Apple LLVM 9.0.0 (clang-9<IP_ADDRESS>)] on darwin
Type "help", "copyright", "credits" or "license" for more information.

import apkverify
Traceback (most recent call last):
File "", line 1, in
File "apkverify.py", line 12, in
from pkcs7verify import check_sig, check_sig_v2
File "pkcs7verify.py", line 425, in
class TBSCertificate(univ.Sequence):
File "pkcs7verify.py", line 440, in TBSCertificate
explicitTag=tag.Tag(tag.tagClassContext, tag.tagFormatSimple, 3)))
File "/usr/local/lib/python2.7/site-packages/pyasn1/type/namedtype.py", line 158, in init
self.__tagToPosMap = self.__computeTagToPosMap()
File "/usr/local/lib/python2.7/site-packages/pyasn1/type/namedtype.py", line 253, in __computeTagToPosMap
return NamedTypes.PostponedError('Duplicate component tag %s at %s' % (_tagSet, namedType))
File "/usr/local/lib/python2.7/site-packages/pyasn1/type/namedtype.py", line 49, in repr
representation = '%s=%r' % (self.name, self.asn1Object)
File "/usr/local/lib/python2.7/site-packages/pyasn1/type/base.py", line 479, in repr
representation += ' %s=%r' % (attr, value)
File "/usr/local/lib/python2.7/site-packages/pyasn1/type/namedtype.py", line 175, in repr
representation = ', '.join(['%r' % x for x in self.__namedTypes])
File "/usr/local/lib/python2.7/site-packages/pyasn1/type/namedtype.py", line 49, in repr
representation = '%s=%r' % (self.name, self.asn1Object)
File "/usr/local/lib/python2.7/site-packages/pyasn1/type/base.py", line 479, in repr
representation += ' %s=%r' % (attr, value)
File "/usr/local/lib/python2.7/site-packages/pyasn1/type/base.py", line 479, in repr
representation += ' %s=%r' % (attr, value)
File "pkcs7verify.py", line 306, in repr
if not type:
File "/usr/local/lib/python2.7/site-packages/pyasn1/type/base.py", line 287, in nonzero
return self._value and True or False
File "/usr/local/lib/python2.7/site-packages/pyasn1/type/base.py", line 199, in plug
raise error.PyAsn1Error('Attempted "%s" operation on ASN.1 schema object' % name)
pyasn1.error.PyAsn1Error: Attempted "nonzero" operation on ASN.1 schema object

—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHubhttps://nam03.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fshuxin%2Fapk-signature-verify%2Fissues%2F1&data=02|01||b07bcb3eb02e4ab0b89f08d5aa964eb7|84df9e7fe9f640afb435aaaaaaaaaaaa|1|0|636602484891718278&sdata=kjellVSJsvoOJ8bQHml3mRWTw223uo8RgPczJxBZ31s%3D&reserved=0, or mute the threadhttps://nam03.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fnotifications%2Funsubscribe-auth%2FAAs1pUIKkK3fTq2c_WY17TkXCEf2hTmDks5tsE4ngaJpZM4TjKDM&data=02|01||b07bcb3eb02e4ab0b89f08d5aa964eb7|84df9e7fe9f640afb435aaaaaaaaaaaa|1|0|636602484891718278&sdata=h6dA05tlvsBppCZMcpD6ywwu%2BJGthcj6wWoVLoZ9tPQ%3D&reserved=0.

thx, it works now.

asn1crypto is easy in use than pyasn1, try my new version.


Investigate scripted tests/fork-parallel

[error] x tests / fork-parallel
[error]  Cause of test exception: {line 2}  Command succeeded but failure was expected

@dwijnand, can you please point me to a failed test? I am trying to reproduce, but all seems to work for me with current 1.1.x head.

is it possible that you have seen https://github.com/sbt/sbt/pull/3802 ?

@eed3si9n mentioned failures at https://github.com/sbt/sbt/pull/3816#discussion_r157337712.
Yes I saw #3802.

OK, I found this travis run:
https://travis-ci.org/sbt/sbt/jobs/317262269
In its log there is a failed tests/fork-parallel. The log refers to sbt's commit 4cae6895. The commit log is here:
https://github.com/sbt/sbt/commits/4cae6895680000bacc6aeab0cc8990a5148d5338
The list of commits includes the fix in #3802, meaning that templateStats() is synchronized. So, there is definitely still an issue lingering somewhere. However, I spent quite a bit of time trying to get the failure on my machine, with no luck. To make things more complicated the commit above is an unreferenced commit in GitHub, meaning that it is not attached to any branch or tag; probably a push -f left it dangling. It turns out that there is no simple way to fetch or to reconnect a dangling commit left in GitHub, so it's difficult to fetch the same commit locally. Related commits, locally, show success for tests/fork-parallel.
What I am trying now is using the GitHub API to create, via REST calls, a new remote branch attached to the dangling commit inside GitHub; that seems to be the only way to retrieve the commit, so that I can test it again using Travis. WIP.

What I originally had was the content of #3789 + https://github.com/sbt/sbt/pull/3816/commits/40b86ae41265c49e6e52fa2ac043413be82bd0cc, which failed the tests/fork-parallel test.

I retrieved the branch, and restarted Travis: it failed at the very same spot again:
https://travis-ci.org/sbt/sbt/jobs/319252979
Yet, it works on my machine.

Gotcha! The Travis test uses a VM that has less than four cores. The tests/fork-parallel, because of how it is written, will always report success when run on less than four cores, rather than failing in one of the two cases as expected. To reproduce, pretending that only two cores are available:
taskset 0x00000003 sbt 'scripted tests/fork-parallel'

So, it's really just the test that needs fixing @eed3si9n, @dwijnand

nice. I am ok with keeping the text commented out with your explanation in the comment then.


Add syncplay feature

Related backend PR jellyfin/jellyfin#2733.
Related web frontend PR jellyfin/jellyfin-web#1011.

Lol, looks like GitHub reads tags from commit messages as well, good to know.

Perfect, thanks a lot @OancaAndrei :+1:


Displaying Color Frame does not work

Required Info

Camera Model
{ L515 lidar }

Operating System & Version
Linux (Ubuntu 20)

Kernel Version (Linux Only)
(5.13.0-40-generic)

Platform
PC

SDK Version
<IP_ADDRESS>

Language
C++

the sample code of Displaying Color Frame returns "terminate called after throwing an instance of 'rs2::error'
what():  Couldn't resolve requests"
if i remove the resolution (640,480,):   cfg.enable_stream(RS2_STREAM_COLOR, RS2_FORMAT_BGR8, 30); it works but i
got big image like this:

please help!

Hi @quangsonle  The color resolution 640x480 was not originally supported on the L515 camera model.  To add support for this resolution, the camera's firmware driver should be updated to the latest firmware version <IP_ADDRESS>
https://dev.intelrealsense.com/docs/firmware-releases-l500#section-l500-series-firmware-downloads

worked after upgrading firmware, closed it


Vertical scroll bar is on entire page instead of house list

Describe the bug
When scrolling through the house list, the vertical scroll bar is on the right-rail of the entire page, instead of just the section.
To Reproduce
Steps to reproduce the behavior:

Go to home
Scroll when there are enough channels to scroll

Expected behavior
Scroll bar should be inline with the section
Screenshots
If applicable, add screenshots to help explain your problem.

What device are you on?
Windows 10, Edge Chromium
Additional context
N/A

This is intentional


Add a jq filter

Modern shell scripts interact often with a REST API or a command line program producing json (kubectl for example). Slicing and dicing the data returned by those APIs is often done with https://stedolan.github.io/jq/.
https://github.com/itchyny/gojq provides a go native implementation of jq.
I propose the following filter:
func (p *Pipe) JQ(query string) *Pipe

An example script:
script.Echo('{"foo": 128}'').JQ(".foo").Stdout()

should return "128" on stdout.
Or to show the IP addresses of the local interface lo a shell user will write:
ip -j a show  | jq '.[] | select(.ifname=="lo") | .addr_info[].local'

With an jq filter in script we can write:
 script.Exec("ip -j a show").JQ('.[] | select(.ifname=="lo") | .addr_info[].local').Stdout)

The same slicing and dicing of data can be done in pure go code, but the jq language provides a well documented and known DSL for this problem.

This is a very neat idea! I can imagine doing something similar with XPath, for example. I'm not sure if JQ is the right name for this—how about JSONQuery, perhaps?

This is a very neat idea! I can imagine doing something similar with XPath, for example. I'm not sure if JQ is the right name for this—how about JSONQuery, perhaps?

I'm fine with renaming it to JSONQuery. However there is a JSONQuery DSL available in the NPM ecosystem: https://www.npmjs.com/package/json-query
Also googling JSONQuery lead to a lot of json query languages not equal to the language implemented by jq.
Providing filters for XPath oder yq (yaml equivalent of jq) adds value too. Do we need all those together in the same design?

I'm fine with renaming it to JSONQuery. However there is a JSONQuery DSL available in the NPM ecosystem: https://www.npmjs.com/package/json-query
Also googling JSONQuery lead to a lot of json query languages not equal to the language implemented by jq.
Providing filters for XPath oder yq (yaml equivalent of jq) adds value too. Do we need all those together in the same design?

Yes, the only problem with JQ is that it doesn't tell you what it does, if you're not already familiar with jq, for example. This is why we have Column, not Cut, and First, not Head. But, like you, I can't think of a better name. JQ is fine for now.
Yes, XPath would be nice, but I'll open a separate issue for that.
Can we write a non-trivial script program which demonstrates the value of a JQ method over, say, just piping stuff through jq using an Exec?

Yes, the only problem with JQ is that it doesn't tell you what it does, if you're not already familiar with jq, for example. This is why we have Column, not Cut, and First, not Head. But, like you, I can't think of a better name. JQ is fine for now.
Yes, XPath would be nice, but I'll open a separate issue for that.
Can we write a non-trivial script program which demonstrates the value of a JQ method over, say, just piping stuff through jq using an Exec?

I included a non-trivial example in my draft PR #72. As you can see, from a coding point of view they do not differ that much. However from a script life-cycle point of view, the pure go variant has only go-library dependencies. Hence the scripts are easier to distribute since my target system either can compile it from source with a common go tool chain, or I can copy standalone binaries of the compiled script to the target system. If we exec to the jq binary, we have to manage that non-go dependency somehow.
// Get all the slide titles from the httpsbin JSON demo and count the uniq titles.
func main() {
	// Golang only with `JQ` function
	script.HTTP("https://httpbin.org/json").
		JQ(".slideshow.slides[].title").
		Freq().
		Stdout()

	// Call the jq binary
	script.HTTP("https://httpbin.org/json").
		Exec("jq -r '.slideshow.slides[].title'").
		Freq().
		Stdout()
}

https://github.com/bitfield/script/pull/72/files#diff-249585151f561a1112ae0df322cc3d33e2691853deaae9832e0f447daeee36bc

I included a non-trivial example in my draft PR #72. As you can see, from a coding point of view they do not differ that much. However from a script life-cycle point of view, the pure go variant has only go-library dependencies. Hence the scripts are easier to distribute since my target system either can compile it from source with a common go tool chain, or I can copy standalone binaries of the compiled script to the target system. If we exec to the jq binary, we have to manage that non-go dependency somehow.
// Get all the slide titles from the httpsbin JSON demo and count the uniq titles.
func main() {
	// Golang only with `JQ` function
	script.HTTP("https://httpbin.org/json").
		JQ(".slideshow.slides[].title").
		Freq().
		Stdout()

	// Call the jq binary
	script.HTTP("https://httpbin.org/json").
		Exec("jq -r '.slideshow.slides[].title'").
		Freq().
		Stdout()
}

https://github.com/bitfield/script/pull/72/files#diff-249585151f561a1112ae0df322cc3d33e2691853deaae9832e0f447daeee36bc

Yes, that's true: not having JQ means that any Go program that wants to use jq has to make sure it's in the environment somehow.
On the other hand, adding JQ means that every Go program depends on the gojq library whether it actually uses JQ or not! I'm not a big fan of that idea, and you'll notice that right now, the entire script library only depends on two non-standard packages, and one of those is only used for tests. You're asking me to expand the non-test dependency set by 100 percent, for a fairly niche use case.
I'm not saying no, you understand, but I want to be clear in my mind that the benefit is worth the cost. I think I need to see a little bit more benefit at the moment.

Yes, that's true: not having JQ means that any Go program that wants to use jq has to make sure it's in the environment somehow.
On the other hand, adding JQ means that every Go program depends on the gojq library whether it actually uses JQ or not! I'm not a big fan of that idea, and you'll notice that right now, the entire script library only depends on two non-standard packages, and one of those is only used for tests. You're asking me to expand the non-test dependency set by 100 percent, for a fairly niche use case.
I'm not saying no, you understand, but I want to be clear in my mind that the benefit is worth the cost. I think I need to see a little bit more benefit at the moment.

 I saw, that I advertised this libraries to my colleagues with the minimal dependency set as a major point :-D
What do you think of the following two filters and sinks:
ExternalFilter(func(p *Pipe) *Pipe) *Pipe
and
ExternalSink(func(p *Pipe) err) err
This allows user to develop there own filters and sinks and still use them in the current fluent interface.
Let's use jq as example.
func JQ(url string) (func (p *Pipe) *Pipe)

External library without ExternalFilter
p := script.File("test.json")
p = JQ(".foo")(p)
p.Stdout()

External library with ExternalFilter
script.File("test.json").ExternalFilter(JQ(".foo")).Stdout()

You argument is perfectly fine. I saw, that I advertised this libraries to my colleagues with the minimal dependency set as a major point :-D
What do you think of the following two filters and sinks:
ExternalFilter(func(p *Pipe) *Pipe) *Pipe
and
ExternalSink(func(p *Pipe) err) err
This allows user to develop there own filters and sinks and still use them in the current fluent interface.
Let's use jq as example.
func JQ(url string) (func (p *Pipe) *Pipe)

External library without ExternalFilter
p := script.File("test.json")
p = JQ(".foo")(p)
p.Stdout()

External library with ExternalFilter
script.File("test.json").ExternalFilter(JQ(".foo")).Stdout()

That's a really interesting idea! It sounds like it would be a bit similar to EachLine, but for the whole pipe. What would an implementation of ExternalFilter/JQ look like in this example?

That's a really interesting idea! It sounds like it would be a bit similar to EachLine, but for the whole pipe. What would an implementation of ExternalFilter/JQ look like in this example?

Updated my draft branch #72 with the ExternalFilter/JQ implementation. The ExternalFilter method is very simple:
func (p *Pipe) ExternalFilter(external func(in *Pipe) *Pipe) *Pipe {
	return external(p)
}

And the corresponding JQ function in the example looks like this:
func JQ(query string) func(in *script.Pipe) *script.Pipe {
	return func(in *script.Pipe) *script.Pipe {
		q, err := gojq.Parse(query)
		if err != nil {
			return in.WithError(err)
		}
		var input map[string]interface{}
		json.NewDecoder(in).Decode(&input)
		output := bytes.NewBuffer(nil)
		iter := q.Run(input)
		for {
			v, ok := iter.Next()
			if !ok {
				return in.WithReader(output)
			}
			if err, ok := v.(error); ok {
				return in.WithError(err).WithReader(output)
			}
			fmt.Fprintf(output, "%v\n", v)
		}
		return in.WithReader(output)
	}
}

The call chain in the example looks like this:
	// Golang only with `JQ` function
	script.HTTP("https://httpbin.org/json").
		ExternalFilter(JQ(".slideshow.slides[].title")).
		Freq().
		Stdout()

Updated my draft branch #72 with the ExternalFilter/JQ implementation. The ExternalFilter method is very simple:
func (p *Pipe) ExternalFilter(external func(in *Pipe) *Pipe) *Pipe {
	return external(p)
}

And the corresponding JQ function in the example looks like this:
func JQ(query string) func(in *script.Pipe) *script.Pipe {
	return func(in *script.Pipe) *script.Pipe {
		q, err := gojq.Parse(query)
		if err != nil {
			return in.WithError(err)
		}
		var input map[string]interface{}
		json.NewDecoder(in).Decode(&input)
		output := bytes.NewBuffer(nil)
		iter := q.Run(input)
		for {
			v, ok := iter.Next()
			if !ok {
				return in.WithReader(output)
			}
			if err, ok := v.(error); ok {
				return in.WithError(err).WithReader(output)
			}
			fmt.Fprintf(output, "%v\n", v)
		}
		return in.WithReader(output)
	}
}

The call chain in the example looks like this:
	// Golang only with `JQ` function
	script.HTTP("https://httpbin.org/json").
		ExternalFilter(JQ(".slideshow.slides[].title")).
		Freq().
		Stdout()

Added a PR with the implementation given here.

Added a PR with the implementation given here.

Don't call something JQ without it actually being 100% compatible and with JQ. Microsoft learned this when they made their powershell http client curl when it wasn't curl.

@bitfield I'm saying I can't tell if it is and I can't tell what they will do with it in the future. If you were to expose this library in your library i'd call it by what it is, gojq and not jq. If there is ever drift between official jq and gojq it could confuse people.

OK, I understand. Yes, that's a good point, thank you.


Implement quick panel for symbol references

Usually the quick panel is better suited for showing symbol references
because you can cycle through the references using the keyboard.
It is also closer to the original Sublime Text behavior.
I chose to make this opt-in to avoid confusing existing users.

Coverage decreased (-0.3%) to 26.834% when pulling 9647311fcedd689e1e08c53f5973bb5da6843d4c on alin23:feature/references-quick-panel into fc804a27115c5f16f1e780b6207e61167d1d82d3 on tomv564:master.

Huge improvement in UX!

I'll add one review question, but I'd like to propose this as a default experience in a future version!

Thanks for the review and for merging! @tomv564
Also thank you for making this tool, it is the final thing I missed from full fledged IDEs like IntelliJ an Xcode.

thanks @alin23 really nice improvement


Lookup behavior

This implements the lookup behavior by exposing the Lookup's internal input value through a .syncable prop (with a corresponding event), and making the selected item bindable via v-model. Naming aside, whether v-model binds the internal <input> value or the selected item seems to be the choice that has to be made when developing a Lookup component. The latter approach made more sense to me, as it seems more intuitive that the value of such a component is what is selected, not what is typed into the search field.
Bug: T265012

(throwing everything into one comment because the answers to the two main points are related. hope that's ok)
Thanks, @itamargiv for the great comments :pray:
I agree that we need to think about adding a loading indicator as soon as we load data asynchronously. What exactly this should look like isn't specified anywhere yet as far as I know but @SaiSan-WMDE already has it in the back of her mind if I remember correctly.
As to how the component knows that it's loading, I think this approach here is in line with that of most the other component libraries' lookup equivalents (buefy, react material ui, vuetify all have some sort of loading prop) which leaves the responsibility of how items are loaded entirely up to the code using the Lookup. With the code already being opinionated about this, I think the loading indicator can be added in a similar way at a later point (but soon!) with a non-breaking change.
I'm curious to hear more about building filtering and caching capabilities into the Lookup. Can this be consolidated with the idea of having the parent component take care of data fetching?

I agree that we need to think about adding a loading indicator as soon as we load data asynchronously. What exactly this should look like isn't specified anywhere yet as far as I know but @SaiSan-WMDE already has it in the back of her mind if I remember correctly.

That's exactly correct, Jakob! Specifying the loading state for dropdown menus is on my to-do list. I have to say, though, that I'm a bit blocked and unsure regarding how and how much of the loader component can/should be specified using tokens (i.e. what to do with all those animation properties?). We should, in principle, use the "three (bouncing) dots" loader in the small (12px) size. There's an existing implementation of it, created by Volker.
Maybe checking the existing component and specs together could be helpful @itamargiv, @jakobw 🙏

I'm curious to hear more about building filtering and caching capabilities into the Lookup. Can this be consolidated with the idea of having the parent component take care of data fetching?

Well first of all, I might have linked to the wrong example before: https://vuetifyjs.com/en/components/autocompletes/#asynchronous-items
As you can see, the component itself employs a filtration mechanism to the menu items passed as props, so that filtration operates "offline" as well. this filtration can be overridden by the filter prop
As for caching, this is an interesting idea I saw in vuetify and elsewhere, where the component itself keeps items after they are fetched. In vuetify it is enabled by a cache-items boolean prop that is inherited from the <v-select> component.

Get it, thanks! The filter prop looks to me like a convenience feature catering to a very specific use case, but I agree that we would want to build something like cache-items into the component to avoid repeatedly implementing it in consuming code when loading data over the network (or some other expensive operation). I'm not necessarily seeing it as a required feature for the initial version of the Lookup component, though.

The filter prop looks to me like a convenience feature catering to a very specific use case,

I'm not suggesting that we add the prop (or anything else for that matter), I was just pondering whether that was the intended use case, as the base functionality I know for autocomplete components like this is that it is intended for filtering from a pre-existing list first (and the asynchronous completion usecase is considered the "specific use case"). But if you say this component doesn't need to have any filtering functionality at all, and it is meant to be exclusively used with filtering functionality that is externalized to it, then sure, I agree.

I rebased the branch on top of master and added the extended comment to the value prop.

Just realized the keyboard navigation PR that is based on this one is not merged.

Let's merge this as it is. As I learned, PRs that are targeting this branch should then be automatically retargeted to master by GitHub. And this branch is already quite large.


New eff dev

I want to get this into master so that @yamaguchi1024 doesn't have to worry about the bug that was manifesting in test_x86.
The changes ought to be reasonably tightly grouped into commits, so it may be easiest to review changes commit-by-commit.

Cool, thanks!


Enhanced volume envelope support

We have a basic ADSR volume envelope supported right now, and the system has been designed to allow for other envelope types to be added.
An alternate volume envelope system could be added that follows a pattern similar to the stepped frequency envelope, which allows for a variable number of phases.  Rather than having fixed "ADSR" phases, we could have variable phases, and definitions of rules as to how the phases should be processed.
At the most basic level, there are three classes of phases that should run sequentially.  Attack, Sustain, and Release.  Each could have multiple sub-phases.  A single phase would be a simple expression of a duration coupled with a target volume level modifier.  The volume level would be a linear transition from the level at the start of the phase to the target level.
The "Sustain" phases could (optionally) repeat, either for a given number of repetitions, or indefinitely (until duration has elapsed).  Some thought is needed about the exact rules for how this should work.
With this type of envelope it would be possible to produce many other volume envelope forms; as one specific example it would be relatively trivial to support Acorn's ADSR variant.

An even more advanced volume envelope system could support "easing rules" - allowing transitions between volume levels to follow non-linear paths.
Arguably however such more sophisticated envelopes could be emulated by just defining more phases.

multi-phase ADSR envelope was added in #132


Query\Builder::whereRaw() doesn't accept parameters

I have the following code and expect to pass $search into the raw query:
$tags = Tag::whereHas('translations', function ($query) use ($search) {
    $query->whereRaw("MATCH(`name`) AGAINST(? IN BOOLEAN MODE)", [$search]);
    echo $query->toSql();
})->get();

SQL dump:
select * from `tag_translation` where `tag_translation`.`tag_id` = `tag`.`id` and MATCH(`name`) AGAINST(? IN BOOLEAN MODE)

The ? is not replaced by $search.
Cannot find useful document about the whereRaw() function. Is here any good way to excute a raw SQL for fulltext index?

Found my problem. The query won't fill ? with bindings until it is executed.


chore(main): release 1.2.4

:robot: I have created a release beep boop
1.2.4 (2024-03-05)
Documentation

Fix typo (91dfb38)

This PR was generated with Release Please. See documentation.

:robot: Release is at https://github.com/pythoninthegrass/gopappy/releases/tag/v1.2.4 :sunflower:


Added BeforeRun option for expensive setup

Implemented the BeforeRun that is available in the Ruby version.  Followed the current code for handling async.  Added a couple simple unit tests at this point to make sure that the method was called if it existed (meaning, not null).

I haven't used NSubstitute before so maybe I'm just missing something obvious, but I'm not seeing how it will prevent the need for storing beforeRunRan since the BeforeRun Action doesn't return anything.
I've changed one test to this to use IControlCandidate<T>, what else were you thinking?  Thanks.
        var beforeRunRan = false;

        // We introduce side effects for testing. Don't do this in real life please.
        var mock = Substitute.For<IControlCandidate<int>>();
        mock.Control().Returns(42);
        mock.Candidate().Returns(42);
        Action beforeRun = () => { beforeRunRan = true; };

        var result = Scientist.Science<int>("beforeRun", experiment =>
        {
            experiment.BeforeRun(beforeRun);
            experiment.Use(mock.Control);
            experiment.Try(mock.Candidate);
        });

        Assert.Equal(42, result);
        Assert.True(beforeRunRan);

You should be able to add a new interface method onto IControlCandidate<T> to account for BeforeRun (it can return void, and take no arguments).  Then when you use mock to define its behavior, you can use:
mock.Received().BeforeRun()

This will make sure that when you pass experiment.BeforeRun(mock.BeforeRun) the system makes a call into the interface (substituted by NSubstitute).  If the system doesn't call into the method, then an exception will be thrown that will turn into a failed test.

Looking good so far. Just need merge master into it or rebase it against master. Sorry for the conflicts!

Okay, I merged the upstream master back into mine and resolved the conflicts and made the small changes needed to integrate it with the comparator logic that was added.

Thank you for your contribution!