Error while debugging locally

Getting below error when trying to execute the sample to test out Cloud Logging.
java.lang.IllegalStateException: Logback configuration error detected:
ERROR in ch.qos.logback.core.joran.spi.Interpreter@24:14 - RuntimeException in Action for tag [appender] java.lang.NullPointerException
	at org.springframework.boot.logging.logback.LogbackLoggingSystem.loadConfiguration(LogbackLoggingSystem.java:179)
	at org.springframework.boot.logging.logback.LogbackLoggingSystem.reinitialize(LogbackLoggingSystem.java:232)
	at org.springframework.boot.logging.AbstractLoggingSystem.initializeWithConventions(AbstractLoggingSystem.java:73)
	at org.springframework.boot.logging.AbstractLoggingSystem.initialize(AbstractLoggingSystem.java:60)
	at org.springframework.boot.logging.logback.LogbackLoggingSystem.initialize(LogbackLoggingSystem.java:132)
	at org.springframework.boot.context.logging.LoggingApplicationListener.initializeSystem(LoggingApplicationListener.java:313)
	at org.springframework.boot.context.logging.LoggingApplicationListener.initialize(LoggingApplicationListener.java:282)```

Currently authenticated using ``` gcloud auth application-default login

I think the issue could be due to MetadataConfig which is using VM Metadata Endpoint which is invalid in standalone machine. How to make it work?

@pvmraghunandan can you please confirm that in your local execution you use the logback configuration which enforces a fixed resource type in opposite to automatically discovered resource?

thanks @minherz for the update

Tried the workaround by removing resourceType parameter, logs are not getting appended to cloud logging

Thank you for the prompt response. I've tried to run a Quickstart sample that can be found in the repo and can see logs stored in Cloud Logging.
Do you receive any error or other indication? It is important to understand that the logs will be appended to a Google Cloud project id that is configured in the Google client logging library. The value of the project id is usually read from GOOGLE_CLOUD_PROJECT environment variable or, if the variable is not set, from Cloud SDK configuration.
You can check what project id is configured on your client by running:
gcloud config get-value core/project

Please, explore logs in the appropriate project to verify that nothing was written to Cloud Logging.

Yes, it worked when I set the env variable GOOGLE_CLOUD_PROJECT from google cloud shell. I am able to see logs in logs explorer. However, this is not working when code is running on my local machine.

Like other SDKs, we are running below command which uses ADC.
gcloud auth application-default login
Should we only use service account to make it work in local?

This should work with client libraries instead of setting the GOOGLE_APPLICATION_CREDENTIALS. However, it still requires setting GOOGLE_CLOUD_PROJECT and to make sure that the credentials you are authenticating using gcloud auth application-default has proper permissions for writing logs to that project.

Can you check whether the problem can be reproduced with the latest versions of the logback (0.122.5) and logging libraries (3.5.1)?
Thank you.

@minherz sure. I will cross check and update the results soon

@minherz works fine with latest SDK. Able to see the logs in Cloud Logging.

Thank you for the confirmation. I am closing the issue then as fixed.


Change terminology from "continuable failure" to "soft failure"

Robot Framework has for long time had support for failures that allow execution it to continue but mark the test failed at the end. This functionality is supported also by many other tools such as TestNG and PyTest via various plugins. For general benefits of this functionality see https://assertless.org/.
We have used our own term "continuable failure" with these failures but a more commonly (albeit not uniformly) used term in our domain is "soft assert". To make this functionality easier to discover, we should use the commonly used term as well. We don't generally use word "assert" as it's more a unit testing term, but using "soft failure" would work very well in our lingo.
What I propose is the following:

Update User Guide section about continuable failures to use the term "soft failure". The current section should probably be split to separate sections about ignoring failures and soft failures.

Leave the existing keyword Run Keyword And Continue On Failure as-is as works just fine even if the overall term for the functionality would be soft failure. This term should be mentioned in the keyword documentation, though.

Leave the special ROBOT_CONTINUE_ON_FAILURE attribute custom exceptions can use to mark they are continuable/soft as-is. Also it works fine even after the terminology change and changing it would require a deprecation period.

Name the planned new special exception activating this functionality SoftFailure. See #3685 for more details about these plans.

In other words, there shouldn't be need for any functional change to existing code.

A small problem is that the term "soft failure" or "soft error" is used with electronics (e.g. RAM) when there's a failure caused by cosmic rays or other such particles:
https://en.wikipedia.org/wiki/Soft_error
I think this is separate enough domain that we using "soft failure" to mean something different is fine.

How about "NonTerminating Failure" or something to that effect. I think both Soft Failure and Continuable Failure would suffer from the same issue of having to explain what that means, particularly to businessy folks such as CTOs or Product Owners. I'm not sure that you gain very much by going to Soft Failure to merit the change but others can surely feel differently.

Decided not to do this change for the following reasons:

There hasn't been that much interest towards the change.
"Continuable falure" may not be the best term but it nevertheless explains the concept more explicitly than "soft failure".
The change would require some extra work and could cause confusion.

This can be considered again in the future if "soft failure" or some other term becomes more widely used. Switching to some other new term like "non-terminating failure" would likely not be worth the effort compared to the current situation.


Image Hashing

Hey, I came across this repo through reddit today and it peeked my interest.
I had a few ideas after going through a lot of articles on image comparison for duplicates. I'll link the sources below.
I have implemented some changes to the codebase including some refractoring and restructure.
I have implemented a basic pHash Algorithm to create a hash for each image which can be parsed to string and the difference between two hashes represents the Hamming Distance between them.
In simple terms, if (hash1 - hash2) == 0 images are exact copies. Difference between 2 hashes can be in the range 0-1 inclusive.
Please go through the code and let me know if some improvement is required or if I missed something.
Sources :

Build an Image Duplicate Finder System: A Guide
Looks Like It - Hacker Factor Blog

Hey, thank you for the PR and your efforts.
I would like to request a small change in the PR.
The project is supposed to also compare and find duplicates even when 2 images are same but of different resolutions (lets say 720p and 4k images for example)
The PR provided compares the images in their actual state so this wont be found.
My implementation was to implement proxies. converting all images to 100*100 would remove resolution and compression issues.
You can propose an alternative method or, according to me, we could create hashes of the proxy objects.
Thank you for your contribution
Happy coding :)

This PR does support finding duplicate images.
For example :
import json
from dataclasses import asdict
from pycompare import get_duplicates

if __name__ == "__main__":

    duplicates = get_duplicates("/home/grayhat/desktop/github/PyCompare/sample")

    with open("duplicated.json", "w+") as f:
        json.dump([[asdict(metadata) for metadata in group] for group in duplicates], f, default=str)

The folder here contains 3 images for this test

samplea
sampleb
samplec

The get_duplicates function is supposed to return a list of duplicate image groups
I am attaching the output of this test run here
[
    [
        {
            "width": 4624,
            "height": 3468,
            "channels": 3,
            "size": 7453282,
            "extension": ".jpg",
            "exiftags": {
                "Image ImageWidth": "3468",
                "Image ImageLength": "4624",
                "Image ImageDescription": "",
                "Image Make": "OnePlus",
                "Image Model": "OnePlus Nord CE 2",
                "Image Orientation": "0",
                "Image XResolution": "72",
                "Image YResolution": "72",
                "Image ResolutionUnit": "Pixels/Inch",
                "Image Software": "MediaTek Camera Application",
                "Image DateTime": "2024:02:01 17:49:41",
                "Image YCbCrPositioning": "Co-sited",
                "Image Tag 0x0220": "0",
                "Image Tag 0x0221": "0",
                "Image Tag 0x0222": "0",
                "Image Tag 0x0223": "0",
                "Image Tag 0x0224": "0",
                "Image Tag 0x0225": "",
                "Image ExifOffset": "450",
                "GPS GPSVersionID": "[2, 2, 0, 0]",
                "GPS GPSLatitudeRef": "N",
                "GPS GPSLatitude": "[22, 36, 5033/2500]",
                "GPS GPSLongitudeRef": "E",
                "GPS GPSLongitude": "[72, 49, 37747/5000]",
                "GPS GPSAltitudeRef": "0",
                "GPS GPSAltitude": "0",
                "GPS GPSTimeStamp": "[12, 3, 45]",
                "GPS GPSProcessingMethod": "[65, 83, 67, 73, 73, 0, 0, 0, 67, 69, 76, 76, 73, 68, 0, 0, 0, 0, 0, 0, ...  ]",
                "EXIF UserComment": "",
                "EXIF SubSecTime": "885",
                "EXIF SubSecTimeOriginal": "885",
                "EXIF SubSecTimeDigitized": "885",
                "EXIF FlashPixVersion": "0100",
                "EXIF ColorSpace": "sRGB",
                "EXIF ExifImageWidth": "3468",
                "EXIF ExifImageLength": "4624",
                "Interoperability InteroperabilityIndex": "R98",
                "Interoperability InteroperabilityVersion": "[48, 49, 48, 48]",
                "EXIF InteroperabilityOffset": "1943",
                "EXIF SensingMethod": "0",
                "EXIF ExposureMode": "Auto Exposure",
                "EXIF WhiteBalance": "Auto",
                "EXIF DigitalZoomRatio": "1",
                "EXIF FocalLengthIn35mmFilm": "0",
                "EXIF SceneCaptureType": "Standard",
                "JPEGThumbnail": "b''"
            },
            "filename": "/home/grayhat/desktop/github/PyCompare/sample/sampleb",
            "filepath": "/home/grayhat/desktop/github/PyCompare/sample/sampleb.jpg",
            "hash": "0x00010x0010a9a46b92aeda264d8970bf41f81e6ba4fc0e3e20f36073c3dcdaeaeb81b4320a"
        },
        {
            "width": 360,
            "height": 360,
            "channels": 3,
            "size": 92549,
            "extension": ".jpg",
            "exiftags": {},
            "filename": "/home/grayhat/desktop/github/PyCompare/sample/samplea",
            "filepath": "/home/grayhat/desktop/github/PyCompare/sample/samplea.jpg",
            "hash": "0x00010x0010a9a56b92ae5a264d8970bf41f81e6ba4fc0e3e30f16063c7d8daeae9a1b4320e"
        }
    ]
]

Here we can see there is one duplicate group containing sampleb and samplea images which are duplicate images but different resolutions. This json contains the metadata of the images along with the hash but you only realistically need the hash to check if images are duplicate.


ci: fix trigger for helm doc update workflow step

Summary
The trigger for the helm docs update is very restricted (only when changes in the docs happen). This is a problem as the semantic release bot creates commits and updates the Chart.yaml version in the background. This doesn't trigger the docs update and we diverge with every commit.
Solution
Edit the trigger for the helm docs update so it runs on any push/pull_request

Relates to #153 and should fix it.


Add falcon-agent addon

Community Note

Please vote on this issue by adding a 👍 reaction to the original issue to help the community and maintainers prioritize this request
Please do not leave "+1" or other comments that do not add relevant new information or questions, they generate extra noise for issue followers and do not help prioritize the request
If you are interested in working on this issue or have submitted a pull request, please leave a comment

What is the outcome that you are trying to reach?
Customer requested falcon-agent addon https://github.com/CrowdStrike/falcon-helm

thank you for the issue - at this time we will not be adding this implementation to the project. if you wish to use Falcon you can utilize the helm_release resource to add support in your environment


Pin Rust to 1.62

By default we get whatever Rust version is installed in the Github Actions image. Pin it to latest Rust so it doesn't change unless we want it to.

Waiting on #2152.


Create initial FreeBSD worker

Using the obuilder FreeBSD PR https://github.com/ocurrent/obuilder/pull/156

The documentation has introduced a dependency on md2mld which makes the deployability checks fail.


Make clear which prompt is for

WHY are these changes introduced?
We show two confirmation prompts, one for functions and one for extensions. It's a bit confusing now because we don't tell the user which is which.
WHAT is this pull request doing?
Customize the label so that the user knows what's going on.

How to test your changes?

Create a new app
Add a function
Add an extension
Deploy

Measuring impact
How do we know this change was effective? Please choose one:

[x] n/a - this doesn't need measurement, e.g. a linting rule or a bug-fix
[ ] Existing analytics will cater for this addition
[ ] PR includes analytics changes to measure impact

Checklist

[x] I've considered possible cross-platform impacts (Mac, Linux, Windows)
[x] I've considered possible documentation changes
[x] I've made sure that any changes to dev or deploy have been reflected in the internal flowchart.

@MeredithCastile do you think that it would make sense to merge the two confirmation prompts into one? If so, do we need to help the user in distinguishing the various extension (or function) types?

I think it'd be nice to have just one prompt with everything


Remove HTTPHeaders from ResponseMetadata in some tests

botocore 1.4.29 started adding this. I'd match against it, but it contains a date object and it's just not worth rewriting the assertions for a key-by-key approach.
If this is acceptable it will eliminate the need for #654

Thanks for working on this, but I would rather we change the tests. I want Moto to resemble the AWS API as closely as possible.

@spulec those headers are an artifact of botocore, not moto. It's not something the API returns and not something you'd have to worry about emulating. You could change the tests but you'd have to pull some crazy monkey patching or find a fuzzy matcher for datetimes.

Oh, okay. I see.

thanks!


Notebook save disconnects session...

Issue Type: Bug

Open new notebook (kernel doesn't matter)
Type some code & execute (ex: select @@spid or print('hello'))
Now, save the notebook
Connection is reset!

This is pretty annoying especially when you try something against pyspark kernel and have to connect again.
Azure Data Studio version: azuredatastudio-insiders 1.12.0-insider (93c9426f25e632e8e3dd6e572d48d559ae07a7bf, 2019-10-10T18:18:16.586Z)
OS version: Windows_NT x64 10.0.18999

System Info

Item
Value

CPUs
Intel(R) Core(TM) i7-7820HQ CPU @ 2.90GHz (8 x 2904)

GPU Status
2d_canvas: enabledflash_3d: enabledflash_stage3d: enabledflash_stage3d_baseline: enabledgpu_compositing: enabledmultiple_raster_threads: enabled_onnative_gpu_memory_buffers: disabled_softwareoop_rasterization: disabled_offprotected_video_decode: enabledrasterization: enabledskia_deferred_display_list: disabled_offskia_renderer: disabled_offsurface_synchronization: enabled_onvideo_decode: enabledviz_display_compositor: disabled_offwebgl: enabledwebgl2: enabled

Load (avg)
undefined

Memory (System)
31.85GB (15.48GB free)

Process Argv

Screen Reader
no

VM
0%

Extensions (8)

Extension
Author (truncated)
Version

ssmskeymap
kev
1.1.0

admin-tool-ext-win
Mic
0.0.2

agent
Mic
0.43.0

azuredatastudio-postgresql
Mic
0.2.2

dacpac
Mic
0.7.0

import
Mic
0.11.0

profiler
Mic
0.10.0

sql-vnext
Mic
0.16.0

This maybe the same bug, so attaching simple video example.  Note there is no issue if the notebook has been saved before.  This only happens when it is the first time the notebook is saved.

During livesite if an engineer is creating a new notebook and has had a long running code cell before they save the notebok for the first time, this would impact their productivity.


Revert "Implement ClangImporter importSourceLoc and importSourceRange"

Reverts apple/swift#40010.
Verifying that this broke the source compatibility test suite.

CC @NuriAmari

Please don't merge until we verify that this was actually the commit that broke the source compatibility test suite.

@swift-ci please test source compatibility

Thanks @zoecarver!

Slightly early to call, but seems that ProcedureKit and SwiftyStoreKit are passing in those two builds of the compatibility suite. Seems that both are related to NSError. I don't see the relation clearly with Nuri's changes, but I think reverting at this point is not a bad idea.

Found the work around, at least for SwiftyStoreKit (ProcedureKit is a little bit more complicated to setup, but I think if it is not because of the same, it might be something related).
If after https://github.com/apple/swift/blob/7afb4752791c3ca00a7e7de24716ec51c21e82ad/lib/ClangImporter/ImportDecl.cpp#L2926 one adds a line errorWrapper->setBraces(loc); (sic) the assert is not hit. StructDecl::getSourceRange() uses the start of the struct, and the end of the braces. But the braces are not initialized in the constructor. Adding that loc (which is the same as the start of the struct) seems to bypass the problem. I imagine that before the changes, both were empty SourceLoc which didn't trigger the assert.

Found the work around, at least for SwiftyStoreKit (ProcedureKit is a little bit more complicated to setup, but I think if it is not because of the same, it might be something related).
If after
https://github.com/apple/swift/blob/7afb4752791c3ca00a7e7de24716ec51c21e82ad/lib/ClangImporter/ImportDecl.cpp#L2926
one adds a line errorWrapper->setBraces(loc); (sic) the assert is not hit. StructDecl::getSourceRange() uses the start of the struct, and the end of the braces. But the braces are not initialized in the constructor. Adding that loc (which is the same as the start of the struct) seems to bypass the problem. I imagine that before the changes, both were empty SourceLoc which didn't trigger the assert.

(Enum|Protocol|Class|Struct)Decl all have brace locations where getRange is made up from the Loc and braces end loc. I handled this in the PR I mentioned (https://github.com/apple/swift/pull/39701/files#diff-d87e42f4d1c72f623a9f9246f244b1ad6f375fa7d1dce3d162ebb302d17f8922) by just checking the braces loc since it seemed a bit weird to set braces to something that isn't braces. Could probably make the argument for using the @whatever and @end ranges though.

@NuriAmari and @drodriguez do you want to fix this or should I revert?

@zoecarver revert with this one. We will resend the other one with whatever fix is needed and test it properly.

Sounds good. Thanks, Daniel!
@swift-ci please smoke test

@swift-ci please smoke test Linux

@swift-ci please smoke test Windows

@swift-ci please test Windows

@NuriAmari I didn't see the original PR, but I'd like to discuss whether we want the original change at all. (This is an awkward place to discuss it, so if you'd rather do that elsewhere, let me know.)
I'm not convinced that it's a good idea to put translated Clang source locations into AST nodes for three reasons:

SourceLocs get used for more than just diagnostics; they are also used for things like availability scoping and occasionally even deciding which declarations are synthesized and don't need to be checked. It's difficult to know what you'll be affecting with this.

We generally assume that a SourceLoc is at the start of a Swift token so that the Swift lexer can lex from there to the end of the token. C lexes similarly enough that we can often get away with translating source locations, but not always. The more we translate, the more we risk hitting one of the exceptions.

When you use the variant of diagnose() that takes a Decl instead of a SourceLoc or DeclNameLoc, Swift will produce a generated interface for the decl and diagnose the error in that interface. For diagnostics that are not specific to clang interop, this is arguably a better user experience because it shows you how Swift imported the declaration, which may be part of the error's cause. When you import a SourceLoc for the decl, Swift will instead diagnose these errors in the C header, which means you have to know Swift's importing rules by heart.

To be sure, in the cases where 3 is involved, it would be helpful to also see the Clang declaration. Perhaps the diagnostic engine could arrange to have an additional note emitted pointing to the imported declaration in the header file. But I don't think we should only emit at that source location.
(This could also avoid eagerly importing source buffers we won't ever use just so that we can create Swift SourceLocs for them.)

@swift-ci please smoke test linux.

@beccadax Thanks for bringing these points to my attention, I wasn't aware of the first two. With this new information, I don't feel strongly that the original change is necessarily desirable. I simply needed a helper to translate Clang source locations for use in diagnostics and figured I would implement these methods rather than create a new one. I do have some questions / thoughts about the matter though.

SourceLocs get used for more than just diagnostics; they are also used for things like availability scoping and occasionally even deciding which declarations are synthesized and don't need to be checked. It's difficult to know what you'll be affecting with this.

We generally assume that a SourceLoc is at the start of a Swift token so that the Swift lexer can lex from there to the end of the token. C lexes similarly enough that we can often get away with translating source locations, but not always. The more we translate, the more we risk hitting one of the exceptions.

I suppose my question is, it is somehow desirable or correct to provide empty SourceLocs, or is it more that providing valid source locations is a risky change, but one that would be an improvement if done correctly? If empty source locations are desired, perhaps it would make sense to replace some (if not all) calls to importSourceLoc with explicit empty SourceLocs created inline. The way it is now, it looks like callers expect the function to be implemented, but no one got around to it. It looks like I'm not the first to try this and I imagine, without a change (even just a comment), I might not be the last.

When you use the variant of diagnose() that takes a Decl instead of a SourceLoc or DeclNameLoc, Swift will produce a generated interface for the decl and diagnose the error in that interface. For diagnostics that are not specific to clang interop, this is arguably a better user experience because it shows you how Swift imported the declaration, which may be part of the error's cause. When you import a SourceLoc for the decl, Swift will instead diagnose these errors in the C header, which means you have to know Swift's importing rules by heart.

Fair enough, my use case is entirely for producing diagnostics where which the ClangImporter fails, so there is no Swift Decl to speak of. I still think a sort of utility method for converting source locations would be helpful, lest the few lines required be repeated for every diagnostics. In another PR I've called this method convertSourceLocation and I would like to introduce such a method in some form. Let me know if you have any thoughts on this, perhaps a comment explaining why we have two methods that seemingly do the same thing would be appropriate.

I actually recently wrote a helper for diagnosing errors in headers, although it's not yet merged (or even code-reviewed): https://github.com/apple/swift/pull/40170/commits/b372ff61afdd993b64dffe13756ff57e16f06673


tests no running, windows 7, 64bits

Hi there,
I cloned and installed the repo successfully but the test is not running. I just updated node.js to the latest version v0.12.2, and the npm version is 2.8.3.
when I run npm test, this is what I get:

@ test C:\workspace\mocha-react
mocha --compilers .:tests/compiler.js tests/*-test.js

CheckboxWithLabel
1) "before all" hook
0 passing (3s)
1 failing

CheckboxWithLabel "before all" hook:
Error: timeout of 2000ms exceeded. Ensure the done() callback is being call
ed in this test.

npm ERR! Test failed.  See above for more details.
Thanks in advance for any suggestion on how to solve this.

A quick update, the failed test happens in the master branch, if I move to the jsx-stubs branch it all works fine.

Thanks for the heads up. I'm seeing this error when I update to node 0.12:
1) CheckboxWithLabel "before all" hook:
   Error: Module did not self-register.
    at Error (native)

Will investigate.

Stack Overflow has the answer. If you've upgraded node, you need to run
sudo npm rebuild

This made the error go away for me.

Somehow I missed that one in StackOverflow.
Thanks!


Remove double requirement

@mrpau-eduard there shouldn't happen to be a reason why this requirement is listed twice and blocking our tests from running? :)

Ohh sorry about that. It should be remove.


new setup receiving CSRF token failure

Symfony\Component\HttpKernel\Exception\BadRequestHttpException CSRF token validation failed on clean install when instructions are followed exactly.
It appears as though the entrypoint ignores environment variables and sets session driver to default.

I'm also having this issue.
Is there a workaround available, or is the Docker version no longer supported?

This is probably related to https://github.com/CachetHQ/Docker/pull/354


:error_logger.add_report_handler documentation issue

We're preparing our upgrade to Sentry Elixir 6.0 at Timber, and we ran into an issue on the usage of :error_logger.add_report_handler/1 with umbrella applications.
Because :error_logger is implemented as a :gen_event manager and :error_logger.add_report_handler/1 is a lightweight wrapper around :gen_event.add_handler/3, report handlers are not unique by module. It is therefore valid to add a report handler multiple times.
This means that if an end-user of Sentry Elixir adds :error_logger.add_report_handler(Sentry.Logger) to the start/2 function in two applications in an umbrella application, there would be two Sentry.Logger instances. With Timber, we ended up calling it in 9 application, and the result was this:
iex(1)> :gen_event.which_handlers(:error_logger)
[Sentry.Logger, Sentry.Logger, Sentry.Logger, Sentry.Logger, Sentry.Logger,
 Sentry.Logger, Sentry.Logger, Sentry.Logger, Sentry.Logger,
 Logger.ErrorHandler, :error_logger]

Following that, a single error would be reported to Sentry 9 times, since the event would be sent to every instance of Sentry.Logger.
There are two solutions to fix this (we use the second):

The easy-but-brittle solution is to only add the report handler in the start/2 of the primary entrypoint application. This ensures that Sentry.Logger will only be added once. However, if at some point the entry-point changes or the end-user switches to a multiple release style, they will need to switch to option 2. (And hopefully have documented this fact in case anyone joins the team later).

The second solution is a bit more robust, but it makes implementation assumptions about :error_logger (notably that it will always be a :gen_event manager registered with the name :error_logger). It works by testing whether Sentry.Logger is already in the list of handlers. With this logic, it can be added to any and every application's start/2 function but only ever be added as a handler once:

if !(Sentry.Logger in :gen_event.which_handlers(:error_logger)) do
  :ok = :error_logger.add_report_handler(Sentry.Logger)
end

@DavidAntaramian This is a great catch, thank you! ❤ 💖
I'll update docs soon.


S2U-43 <IP_ADDRESS> Admin: Ability to enrol, unenrol and disable multiple users in multiple sites.

Same title than in the tools properties

Wow thanks!


Add matchMedia support for responsive capabilities

The size of the viewport is not aligned in CSS and JavaScript (e.g. a CSS media query pixel value and a $(window).width() do not have consistent values). When utilizing the responsive capability for Slick it's difficult to style the breakpoints differently. I hate to suggest adding additional dependencies but it'd be great if you could specify a breakpoint in the configuration and have it align with your CSS like so:
responsive: [
    {
        breakpoint: 991,
        settings: {
            slidesToShow: 1,
            slidesToScroll: 1,
            infinite: true
        }
    }
]

And this CSS:
@media(min-width:992px){
	.slick-styles {
		color:blue;
	}
}

Currently they don't align because the value of the viewport width is not consistent between javascript and CSS. In the checkResponsive method within the for loop the conditional can be modified to use matchMedia (or Modernizr's Modernizr.mq method too) if it's been loaded and that would make the values consistent.

You might want to try Flickity. Flickity uses your own CSS to handle size and positioning, so you can easily use media queries. See demo http://codepen.io/desandro/pen/azqbGV  You can even enable/disable the carousel within CSS with Flickity's watchCSS option


Terra patch 7 - upgrade terra2 to v2.3.2

Thanks for this, @gregnuj . Having two version objects with the same name and same block height I think is going to cause issue with the automation being built. I see that the 'binaries' and 'ibc version' has changed with the new patch. Now, are you of the opinion that we should not merely update the info in the existing v2.3 version object? I think that's what's being used everywhere else and is assumed for upcoming CI, but perhaps we can discuss further if you feel strongly about retaining all the info for multiple patches within the same minor version.
cc @MasterPi-2124

This is the best solution I have without manipulating the schema too much.  So let me describe my use case, I currently have a docker container I use to launch any cosmos chain using cosmovisor, the goal is to be able to launch a node either starting from the Genesis block and syncing fully, or launch using state sync.  Additionally I have to be able to update an existing version.  I want all of this to work automatically to limit the amount of manual changes, so to accomplish this I have an entrypoint script that matches the upgrade name from upgrade-info.json to the values in chain registry.  The problem I have encountered is the on chain upgrade name is too unpredictable and inconsistent to match to the versions listed.   The best example of this is the cosmoshub v9.3.0 upgrade which was a consensus breaking change executed off chain.  Even setting the version appropriately on startup cosmovisor sees the version name does not match the last on chain upgrade and reverts to the old version so to alleviate this I have to have the name match.  Now there is definitely an argument to say the problem is with cosmovisor or that automatic downloads are discouraged, but my opinion is I should be able to start a node and sync from Genesis (or any other block height) and sync without intervention or failure.  Anyway if I set a different block height and retain the name would that be sufficient?

I have removed the duplicate version names

Currently, my strategy is to overwrite the latest version in the list if the name is the same. If not, a new version will be added to the list. The upgrade name is unpredictable and we can not just count on that to handle new upgrades. I have made a version template, and in that, the name is auto-generated from the tag, and what the automation tools like cosmosvisor should check is the tag and block height (if the upgrade is consensus-breaking). I think that the name can be the same, but the height will never be the same, because:

If the version upgrade is consensus-breaking, you have to provide the block-height param, which is never the same as the previous height.
If the version upgrade is not CB, the height should not be provided, and overall,  the version is still correct and consistent with the template


Version info of all packages while running GUI CT

@adathatri We need discussion here before u implement this on.


v0.0.4 breaks examples in documentation that use v0.0.3

I noticed that the Unkpg CDN link in the README:
<EMAIL_ADDRESS>
is for v0.0.4, however the library used in the examples in the README,
//d3js.org/d3-tile.v0.0.min.js

is for v0.0.3 of the library.
If I attempt to use the v0.0.4 version, the examples break. Reading over the API docs for this library I was not able to yet debug why it is breaking them.

Upon further investigation it looks like this is because v0.0.4 changed the data structure returned by tiles.
Previously that data consisted of a two dimensional array, but v0.0.4 returns an array of objects. It would be helpful to update the example blocks that are linked to in the documentation to reflect this change.

Closing in favor of #52


Optimization for the mask edges

Found better implementation for the edge masks. I feel a bit stupid that I didn't find them before 😣 many of them can be reduced to only one gradient!
It seems that looking at my own code after too long is beneficial.

awesome, thanks for contributing the optimizations!


Use metamask account in Accounts page

This is work in progress for metamask accounts in portal.

Closing this one for https://github.com/futureversecom/trn-substrate-portal/compare/main...futureversecom:trn-substrate-portal:integrate/metamask_accounts?expand=1


Create test workflow

Resolves #6

hmmm I was actually testing it locally and playing out with migrating over to pytest since it looks like it's still having issues after installing dependencies. This side of python I'm too familiar with so I'm sort of experimenting here.

alright that should be good for now ... let me know what you think.

I just updated the repo so these checks are now required to merge! ❇

quick update ...


[Event Change] Codeunit 5815 - Undo Sales Shipment Line - OnBeforePostItemJnlLine

Hello,
The event OnBeforePostItemJnlLine published in Codeunit Codeunit 5815 - Undo Sales Shipment Line is missing a var on the DocLineNo variable.
This is needed since the PostItemJnlLine function itself takes the DocLineNo parameter as var, modifies it so that it could be used upward along the chain in the codeunit.
Suggested change:
From
-    local procedure OnBeforePostItemJnlLine(var SalesShipmentLine: Record "Sales Shipment Line"; DocLineNo: Integer; var ItemLedgEntryNo: Integer; var IsHandled: Boolean)
+    local procedure OnBeforePostItemJnlLine(var SalesShipmentLine: Record "Sales Shipment Line"; var DocLineNo: Integer; var ItemLedgEntryNo: Integer; var IsHandled: Boolean)

Thanks for reporting this. We agree, and we’ll publish a fix asap, either in an update for the current version or in the next major release. We will update this issue with information about availability. Please do not reply to this, as we do not monitor closed issues. If you have follow-up questions or requests, please create a new issue where you reference this one.


Ethan: Blacklist quickbooks.com

Ethan requests the blacklist of the website quickbooks\.com. See the MS search here and the Stack Exchange search in text, in URLs, and in code.

quickbooks\.com has been seen in 14 true positives, 0 false positives, and 0 NAAs.

Rejected by Makyen in Charcoal HQ. Reason: 'QuickBooks is a legitimate and widely used accounting application. This website shouldn't be blacklisted, even though spammers use it in their posts.'


Form Validation

I would like to make this useful thing, normally used in forms. Please assign this to me.

I want to work on this under GSSOC2022. Here is my discord profile DHANANJOY DEY | Contributor#7903 can you assign me?

Sure. What should I need to do?
On Fri, Mar 4, 2022, 12:01 PM Dhananjoy Dey @.***>
wrote:

I want to work on this under GSSOC2022. Here is my discord profile
DHANANJOY DEY | Contributor#7903 can you assign me?
—
Reply to this email directly, view it on GitHub
https://github.com/swapnilsparsh/30DaysOfJavaScript/issues/204#issuecomment-1058875737,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/ANGQKUCK6UHYT2VYJL5C2SDU6GU3ZANCNFSM5PZR4QAA
.
Triage notifications on the go with GitHub Mobile for iOS
https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675
or Android
https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.
You are receiving this because you were assigned.Message ID:
@.***>

Sure. What should I need to do?
…
On Fri, Mar 4, 2022, 12:01 PM Dhananjoy Dey @.> wrote: I want to work on this under GSSOC2022. Here is my discord profile DHANANJOY DEY | Contributor#7903 can you assign me? — Reply to this email directly, view it on GitHub <#204 (comment)>, or unsubscribe https://github.com/notifications/unsubscribe-auth/ANGQKUCK6UHYT2VYJL5C2SDU6GU3ZANCNFSM5PZR4QAA . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub. You are receiving this because you were assigned.Message ID: @.>

Make a PR once you have made it.


Image attribute mutability

Fixes #77

These changes isolate cached state to image src (required to support high/low-res versions), allowing all other image attributes (alt, className, tabIndex, etc) to change without also first changing the image source.
Bonus fixed subtle issue with unzoomable images being able to receive keyboard focus.
Relaxed a couple of the lint errors to warnings to make debugging easier.

@joshsloat could you please fixup these commits down to 1 single one, as well?
1 .git rebase -i HEAD~8

change pick to f (for fixup) for the bottom 7 commits
change pick to r (for reword) for the top commit
give the remaining commit a good name

@rpearce - Feedback addressed. Please take another 👁

👀

@rpearce - Implemented discussed changes. Ready for another 👁

Looks great!


Add text-to-image API inference

hi @TimMikeladze it would be great to add text-to-image on the inference package.
I'm not sure if it's well documented on the docs, but it's widely available on all text-to-image models widgets on the hub,
for example https://huggingface.co/prompthero/openjourney?text=mdjrny-v4+style+a+flying+cat
Here a simple example request:
fetch(
  "https://api-inference.huggingface.co/models/stabilityai/stable-diffusion-2",
  {
    method: "POST",
    headers: {
      "content-type": "application/json",
      "X-Wait-For-Model": "true"
    },
    body: JSON.stringify({
      inputs:
        "award winning high resolution photo of a giant tortoise/((ladybird)) hybrid, [trending on artstation]",
      negative_prompt: "blurry",
    }),
  }
)
  .then((res) => res.blob())
  .then((blob) => {
    const tab = window.open((target = "_blank"));
    tab.location.href = window.URL.createObjectURL(blob);
  });

@radames great idea. I sent a PR adding this functionality.
Are there any additional arguments besides inputs and negative_prompt? I couldn't find anything after a brief look over the documentation.

hi @TimMikeladze thanks!
Unfortunately, these are the only inputs allowed atm https://github.com/huggingface/api-inference-community/blob/725e38d34ae8c649b63f37da8bcee62622dc8ac1/docker_images/diffusers/app/pipelines/text_to_image.py#L57
We might have other tasks not documented but in the API, wdyt?
https://github.com/huggingface/api-inference-community/blob/6f39af264188099a8929cd2a0148b85c7690b0c4/api_inference_community/validation.py#L211-L241

Below are the tasks which are currently not implemented within the @hugginface/inference. I'm creating issues to track each and will see about implementing them in the near-future.

[ ] Audio-to-audio
[ ] Speech-segmentation
[ ] Image-to-text
[ ] Sentence-similarity
[ ] Tabular-classification
[ ] Tabular-regression
[ ] Text-to-speech

Two more

Visual Question Answering
Document Question Answering


NCP is in end-device state for more than 2 minutes.

I built border router(BR) using RPi. Sometime what happens is, NCP degrade from router/leader to end-device and packet does not reach BR. I don't know why BR is being degrade to end-device because as name suggest, it should be either leader or router.
Also, I created a time series of NCP state as shown in picture below:

Note:- 1 indicates leader, 2 indicates router and 3 indicates end-device
wpanctl version is wpanctl 0.08.00d (/345bf7d; Jun 27 2019 16:37:52)
PFA for syslog

I see quite a few instances of NCP reset occurring in the log (snippet below). Is this expected for your testing?
Sep 18 14:43:40 BhumikaRPI wpantund[554]: wpantund[554]: [-NCP-]: NCP was reset (RESET_POWER_ON, 112)
Sep 18 14:43:40 BhumikaRPI wpantund[554]: [-NCP-]: NCP was reset (RESET_POWER_ON, 112)
Sep 18 14:44:53 BhumikaRPI wpantund[554]: wpantund[554]: [-NCP-]: NCP was reset (RESET_POWER_ON, 112)
Sep 18 14:44:53 BhumikaRPI wpantund[554]: [-NCP-]: NCP was reset (RESET_POWER_ON, 112)
Sep 18 14:44:58 BhumikaRPI wpantund[554]: wpantund[554]: [-NCP-]: NCP was reset (RESET_POWER_ON, 112)
Sep 18 14:44:59 BhumikaRPI wpantund[554]: [-NCP-]: NCP was reset (RESET_POWER_ON, 112)
Sep 18 14:45:04 BhumikaRPI wpantund[554]: wpantund[554]: [-NCP-]: NCP was reset (RESET_POWER_ON, 112)
Sep 18 14:45:04 BhumikaRPI wpantund[554]: [-NCP-]: NCP was reset (RESET_POWER_ON, 112)
Sep 18 15:29:45 BhumikaRPI wpantund[3346]: wpantund[3346]: [-NCP-]: NCP was reset (RESET_POWER_ON, 112)
Sep 18 15:29:45 BhumikaRPI wpantund[3346]: [-NCP-]: NCP was reset (RESET_POWER_ON, 112)
Sep 18 15:29:45 BhumikaRPI wpantund[3346]: wpantund[3346]: [-NCP-]: NCP was reset (RESET_POWER_ON, 112)
Sep 18 15:29:45 BhumikaRPI wpantund[3346]: [-NCP-]: NCP was reset (RESET_POWER_ON, 112)
Sep 18 15:32:46 BhumikaRPI wpantund[3346]: wpantund[3346]: [-NCP-]: NCP was reset (RESET_POWER_ON, 112)
Sep 18 15:32:46 BhumikaRPI wpantund[3346]: [-NCP-]: NCP was reset (RESET_POWER_ON, 112)

@jwhui No.

@tarunsmalviya, I believe the NCP resets are causing the issues you are seeing.
Can you provide more information about the NCP? Including:

NCP hardware platform
How you built the NCP firmware, including commands used to build
What git commit id are you using for NCP firmware
Output of wpanctl status

@jwhui
Hardware used is nrf52840
nRF5 SDK for Thread and Zigbee v2.0.0 (Release Date: Week 39, 2018)
OpenThread libraries projects are based on the following commit of OpenThread: 704511c96e0d093139e4b80ef0739ed2d701afb1
wpan0 => [
	"NCP:State" => "associated"
	"Daemon:Enabled" => true
	"NCP:Version" => "OPENTHREAD/g591ec62; NRF52840; Sep 19 2018 11:42:29"
	"Daemon:Version" => "0.08.00d (/345bf7d; Jun 27 2019 17:02:59)"
	"Config:NCP:DriverName" => "spinel"
	"NCP:HardwareAddress" => [9F1D6CC6CA7D6DA0]
	"NCP:Channel" => 25
	"Network:NodeType" => "end-device"
	"Network:Name" => "OfficeThread1"
	"Network:XPANID" => 0x1122334455667788
	"Network:PANID" => 0xAB02
	"IPv6:LinkLocalAddress" => "fe80::bcaf:aaca:2765:f52e"
	"IPv6:MeshLocalAddress" => "fd11:2233:4455:0:1c5:fb2c:c2d1:1e50"
	"IPv6:MeshLocalPrefix" => "fd11:2233:4455::/64"
	"com.nestlabs.internal:Network:AllowingJoin" => false
]

@tarunsmalviya, thanks for the additional information. Any chance you could try using a more recent version of the nRF5 SDK or at least a more recent version of OpenThread?
For NCP firmware, you could try building straight from GitHub as described in Pre-Built NCP Firmware.

@jwhui I have updated the openthread and NCP version to most recent but still facing the same problem.
wpan0 => [
	"NCP:State" => "associated"
	"Daemon:Enabled" => true
	"NCP:Version" => "OPENTHREAD/20180926-00632-g2279ef61; NRF52840; May 23 2019 20:44:20"
	"Daemon:Version" => "0.08.00d (/87c90ee; Dec 11 2019 03:46:40)"
	"Config:NCP:DriverName" => "spinel"
	"NCP:HardwareAddress" => [F4CE3616BC6AF3E0]
	"NCP:Channel" => 25
	"Network:NodeType" => "router"
	"Network:Name" => "fbceca7b0fe995b3"
	"Network:XPANID" => 0xFBCECA7B0FE995B3
	"Network:PANID" => 0xFBCE
	"IPv6:LinkLocalAddress" => "fe80::3c22:2a04:cb44:d8e1"
	"IPv6:MeshLocalAddress" => "fdfb:ceca:7b0f:0:4ca0:31e0:b5e0:3a5d"
	"IPv6:MeshLocalPrefix" => "fdfb:ceca:7b0f::/64"
	"com.nestlabs.internal:Network:AllowingJoin" => false
]```

There are 23 FTD and 49 SED spread over 42000 sq. ft. area.

System logs:
[syslog.1.gz](https://github.com/openthread/ot-br-posix/files/3956005/syslog.1.gz)
[syslog.2.gz](https://github.com/openthread/ot-br-posix/files/3956006/syslog.2.gz)

@tarunsmalviya, Jonathan and I looked the logs. NCP resets seems to be all tied to user commands ("reset" or "leave") and expected behavior (from NCP/wpantund point). It may be good to see who/what module is issuing these commands to wpantund:
# Filtering NCP resets and issued dbus commands "Reset" and "Leave".
abtink@abtink ~/Downloads $ cat syslog.2 | grep "wpantund\[8621\]: wpantund\[8621\]" | grep -e "NCP was reset" -e "\"Reset\"" -e "\"Leave\""
Dec 11 05:40:02 Spencers-01 wpantund[8621]: wpantund[8621]: Inbound DBus message for INTERFACE "Reset" from ":1.336"
Dec 11 05:40:02 Spencers-01 wpantund[8621]: wpantund[8621]: [-NCP-]: NCP was reset (RESET_POWER_ON, 112)
Dec 11 05:40:07 Spencers-01 wpantund[8621]: wpantund[8621]: Inbound DBus message for INTERFACE "Leave" from ":1.337"
Dec 11 05:40:07 Spencers-01 wpantund[8621]: wpantund[8621]: [-NCP-]: NCP was reset (RESET_POWER_ON, 112)
Dec 11 05:40:13 Spencers-01 wpantund[8621]: wpantund[8621]: Inbound DBus message for INTERFACE "Leave" from ":1.11"
Dec 11 05:40:13 Spencers-01 wpantund[8621]: wpantund[8621]: [-NCP-]: NCP was reset (RESET_POWER_ON, 112)

The main issue (from syslog.1) seems to be the network being partitioned a lot. Basically a devcie/router looses connection with others, forms its own partition (which would cause to temporary detach and become a leader). Later device may detect other partition and try to merge the partitions and through  this process device would first attach as child and then become a router again (after some random time interval (order of minutes)).
Some suggestions:

Can you increase the number retx in the NCP build OPENTHREAD_CONFIG_MAC_DEFAULT_MAX_FRAME_RETRIES_DIRECT and
OPENTHREAD_CONFIG_MAC_DEFAULT_MAX_FRAME_RETRIES_INDIRECT.
Another config you can enable is the feature OPENTHREAD_CONFIG_MLE_SEND_LINK_REQUEST_ON_ADV_TIMEOUT. This will ensure a router to try a unicast "LinkRequest" to a router if it misses "Link Advertisement" form it (before kicking the neighbor/router out of its neighbor table). This can help a lot with avoiding partitions.

@abtink
We are using nRF5 SDK for Thread and Zigbee v3.2.0 for NCP and router firmware.
Can you help where I can enable this feature in the stack?

These are config parameters for OpenThread core itself. I am not familiar how/if nRF5 SDK exposes the OpenThread config option/header file. Maybe others can help you with this.
In general, OpenThread allows users to provide a custom (project specific) config header file through OPENTHREAD_PROJECT_CORE_CONFIG_FILE.

Closing stale issue.


Mailer: Notification due to location specificity

A Subscription should receive a Notification if a Hackathon's location is, or is within, the subscription's location.
The levels of granularity/specificity are:

country (USA, etc.)
state (California, etc.)
city (Seattle, etc.)

Examples:

Hackathon location
 Subscription location
 Notify?

Seattle, WA
 Seattle, WA
 ✅ Yes

WA
 WA
 ✅ Yes

Seattle, WA
 WA
 ✅ Yes

Seattle, WA
 USA
 ✅ Yes

WA
 Seattle, WA
 ❌ No

Burlington, VT
 Seattle, WA
 ❌ No

The logic for this is handled by https://github.com/hackclub/hackathons-backend/pull/73


Could add stateful checks to WAL recovery code

Data is written to WALs in temporal order.  Mutations are written to a WAL with per tablet sequence numbers.   The sequence numbers do not change until a minor compaction occurs.  The fact of a minor compaction is recorded in the WAL.
Below is an example of a WAL in the order it was written with the following explanation of the contents.

Defines tablet 2<< with id 5.  Everything else the log will use the id 5
A mutation to set row r1 column f1:q1 to v1.  This mutation has a seq of 1 in the WAL.
A mutation setting r1 f1:q2=v2 with a seq of 1
Compaction start event with seq 2
Compaction finish event with seq 3
A mutation setting r1 f1:q1=v3 with a seq of 3
Etc

DEFINE_TABLET 5 1 2<<

MANY_MUTATIONS 5 1
1 mutations:
  r1
      f1:q1 [system]:1529685833137 [] v1

MANY_MUTATIONS 5 1
1 mutations:
  r1
      f1:q2 [system]:1529685833149 [] v2

COMPACTION_START 5 2 hdfs://localhost:8020/accumulo/tables/2/default_tablet/F0000005.rf

COMPACTION_FINISH 5 3

MANY_MUTATIONS 5 3
1 mutations:
  r1
      f1:q1 [system]:1529685849576 [] v3

COMPACTION_START 5 4 hdfs://localhost:8020/accumulo/tables/2/default_tablet/F0000006.rf

COMPACTION_FINISH 5 5

MANY_MUTATIONS 5 5
1 mutations:
  r1
      f1:q1 [system]:1529685856321 [] v4

MANY_MUTATIONS 5 5
1 mutations:
  r1
      f1:q2 [system]:1529685867727 [] v5

Given the example above it would be odd to see mutations in a WAL with sequence numbers X,X+2, and X+4 without seeing corresponding compaction events between the mutations.  So we could add two types of sanity checks to the recovery code :

Check that compaction start and finish events increment in a orderly way.  Should increment by one.  Seeing a them jump by more than one may indicate data is missing.
Check that mutation seq numbers in the WAL are in an expected range.  Not completely sure, but that range may be : [min_compaction_finish-2, max_compaction_finish].

The retry behavior when writing to WALs and its efect on seq numbers, if any, needs to be looked into.

I thought of this while working on #538 and #541.  If something like this were added it would be nice to also add user level tools like mentioned in #535 to help users figure things out if these stateful checks trigger.


question: why is there a paths options to the StackNavigator?

You already can set all the paths when you define the screens, so it's not like you're re-using imported routeConfigs whose paths you may want to change.
What am I missing for the reason that there is 2 ways to set the paths?

I really don't think there's much of a reason to it other than, technically, objects don't have an order whereas arrays do?
Though a good question I'm going to close this to try to clean up issues. Thanks!

At the very least, it lets you have multiple paths mapping to the same screen.  This is useful, for example, if maybe you have a blog or news site and you may have / and /category/:catName both render a list of posts and reuse the same screen.


RP2350: boot_stage2 never run? resulting in incorrect flash config

I recently noticed that PICO_FLASH_SPI_CLKDIV was not having any effect on my project ported to RP2350, whereas it worked fine with RP2040 before.
This reproduced when using the stock Pico 2 and Pimoroni Pico Plus 2 board files, which use the same boot2_w25q080.S boot_stage2. It does get assembled.
The QMI timing values I am seeing on a MCVE (provided below) don't match my expectations reading the boot script.
qmi[0].timing = 60007203
qmi[0].rfmt   = 492a8
qmi[0].rcmd   = 00eb

When ripping out all the code from boot2_w25q080.S, behavior is unchanged! (Adding garbage to it, it fails to assemble, so it is still getting selected somewhere.)
The lower byte of timing should be 2 (the default CLKDIV), the rcmd is missing the upper byte that should have gotten configured, etc. -- so I am assuming it is inheriting whatever the bootrom had configured.
(EDIT: Writing to those regs works fine; I've been doing it.)
I observed this issue both selecting the 2.0.0 tag and the latest develop tip.
Repro:
#include <stdio.h>
#include <hardware/structs/qmi.h>
#include <hardware/structs/xip.h>
#include <pico/stdlib.h>

int main()
{
    stdio_init_all();
    while (true) {
        printf("qmi[0].timing = %04x\n", qmi_hw->m[0].timing);
        printf("qmi[0].rfmt   = %04x\n", qmi_hw->m[0].rfmt);
        printf("qmi[0].rcmd   = %04x\n", qmi_hw->m[0].rcmd);
        sleep_ms(1000);
    }

}

cmake_minimum_required(VERSION 3.13)

include(pico_sdk_import.cmake)

project(pico-sdk-boot2-rp2350-repro LANGUAGES C CXX ASM)
pico_sdk_init()

add_executable(repro main.c)
target_link_libraries(repro pico_stdlib pico_stdio)
pico_enable_stdio_usb(repro 1)
pico_enable_stdio_uart(repro 0)
pico_add_extra_outputs(repro)

#!/bin/bash
set -ex
mkdir build -p
cd build
cmake .. -DPICO_BOARD=pico2 -DPICO_PLATFORM=rp2350-arm-s -DPICO_COMPILER=pico_arm_cortex_m33_gcc -DPICO_SDK_PATH="<whatever_sdk_path_here>"  -GNinja
cmake --build .

Per release notes:

A boot_stage2 is not needed on RP2350, but one can be included via the define PICO_EMBED_XIP_SETUP=1.

Could perhaps be better documented (this is a compile definition).. also perhaps surprising that it builds without it but that is orthogonal

For clarification, by "ripping out all the code" from the stage2 I mostly meant the instructions under _stage2_boot.
But thank you, PICO_EMBED_XIP_SETUP=1 does indeed solve the problem. However, shouldn't that be the default for any non-default flash configuration?

sorry can someone explain where to add the PICO_EMBED_XIP_SETUP=1 command ?

sorry can someone explain where to add the PICO_EMBED_XIP_SETUP=1 command ?

In CMakeLists.txt, after your target is specified:
target_compile_definitions(thenameofyourtarget PRIVATE
		PICO_EMBED_XIP_SETUP=1
)```

Note that I had an issue enabling this where the program would immediately crash when debugging(?), which I haven't tried to test on a standard Pico 2. I haven't tried to debug it further.

I observed a weird issue where i haven't been able to enable continuous reads through the QMI registers, as it would just immediately crash.

If you only care about changing the clock divisor for flash, you can do this at runtime, with something like this (in C++), assuming the Pico 2 flash (including the Pimoroni Pico Plus 2):
#include <hardware/structs/qmi.h>
#include <hardware/structs/xip.h>
#include <hardware/sync.h>

void __no_inline_not_in_flash_func(init_flash_frequency)() {
	uint32_t interrupt_state = save_and_disable_interrupts();

	qmi_hw->m[0].timing = 1 << QMI_M0_TIMING_COOLDOWN_LSB |
	                      2 << QMI_M0_TIMING_RXDELAY_LSB |
	                      3 << QMI_M0_TIMING_CLKDIV_LSB;   // <----- CLOCK DIVISOR HERE
	qmi_hw->m[0].rcmd =
		0xEB << QMI_M0_RCMD_PREFIX_LSB /* | 0xA0 << QMI_M0_RCMD_SUFFIX_LSB*/;

	// dummy read
	*reinterpret_cast<volatile char *>(XIP_NOCACHE_NOALLOC_BASE);

	restore_interrupts(interrupt_state);
}

Call that function before initializing the second core (if you use it at all) and before changing the clock frequency, if this is for core overclocking reasons.

@asumagic your code in the post above works if you just want to read flash after overclocking, but it didn't work for me when I start to write flash.  I suspect the SDK reverts the divider at the end of each call to the write function.  PICO_EMBED_XIP_SETUP=1 does however work for both.
But thanks for raising this, it helped me a lot!

@asumagic your code in the post above works if you just want to read flash after overclocking, but it didn't work for me when I start to write flash. I suspect the SDK reverts the divider at the end of each call to the write function. PICO_EMBED_XIP_SETUP=1 does however work for both.
But thanks for raising this, it helped me a lot!

You are correct: #1983

I suspect the SDK reverts the divider at the end of each call to the write function.

Yeah, the ROM creates a tiny stub for you in boot RAM (where the copy of the XIP setup is stored if you have one) which restores whatever flash parameters it found during startup. The SDK executes that XIP setup from boot RAM after completing a flash operation, to set flash back up again. This is mostly a big improvement over RP2040 since you can just wire up a dual-SPI flash on your board and the ROM will figure things out and boot into your flash application without any configuration.
The intent when modifying the XIP configuration from the parameters found by the ROM is:

you have a small function to set up XIP (XIP setup func, similar to RP2040 boot2 except you call it instead of the ROM calling it)
you execute this function during startup
you make a copy of this function (or a stub that calls it) in boot RAM so that the SDK flash API can call it when it needs to set XIP back up after tearing things down for serial programming operations

PICO_EMBED_XIP_SETUP=1 does exactly this. It just doesn't help you out if you've done raw register accesses.
We could improve the setup-less behaviour, e.g. by creating a new stub that sets your divider if you have specified a PICO_FLASH_SPI_CLKDIV but haven't specified a boot2. Something else I think would ease confusion is making PICO_EMBED_XIP_SETUP=1 be implied by selecting a boot2. I don't think it's going to happen for this upcoming release though.


Increase test coverage for server InstanceImpl

The failed-to-find case of InstanceImpl::getListenSocketFd() was
previously not covered by testing.  This change introduces fixture &
mocking changes required to unit test the server itself (InstanceImpl)
and create a test case that exercises the return -1 case in
getListenSocketFd().

@dnoe please sign CLA if you didn't already do it.

CLA is signed, and I believe I have updated this pull request to parameterize the config path as requested.  I am more familiar with the gerrit workflow so please let me know if I have done anything weird with the PR.

LGTM. A tip for future reviews: I think you might have done a force push to update - it's better to not rewrite history on the GitHub branch and instead provide additional increment commits and push the branch cleanly. This lets the GitHub review system keep track of which comments are stale and allows reviewers to see the diff between commits. It's OK to do a force push before folks have started to review though. The eventual merge rolls up all commits into a single commit.

Nit picks addressed in a second commit that is now part of this PR.


Add option to override standard saving

Add an option opt.save function wich replace the
pdf.save(opt.filename)  by the function you want in order to be able to export the pdf the way you want. If the option is not defined, the behaviour remains the same.
For example, with this solution, you can define the props save method like this :
save(pdf: any) {   resolve(pdf.output('blob'), "my-filename.pdf")); }
In this example, you get the pdf blob (in a promise context)

Hi, I have just pushed a new branch, new-api, which is ready for testing! The readme has all the information on the new API. Please let me know if there are any problems with it - I want to make sure it's stable before merging into master!
For this specific request, there is now a .output method that can be used like so:
html2pdf().from(element).toPdf().output('blob').then(function (blob) {
  // Use your blob as desired!
});

Closing, v0.9.0 added the requested feature.


tmux

Was the issue accidentally submitted before populating the content? Could you expand on what the issue is?


Implement to update all resources periodically on Frontend

What type of PR is this?
/kind feature

What this PR does / why we need it:
Changed frontend to automatically update resource information using /api/v1/listwatchresource API.
Which issue(s) this PR fixes:

Fixes #120
Special notes for your reviewer:
This PR relates to PR #165. That PR implements the /listwatchresource API which is used in this PR.
/label tide/merge-method-squash

/assign @sanposhiho 😃

/assign @sanposhiho
😃

/area web

/hold

/unhold
/remove-approve

@sanposhiho
Thanks! I fixed.

/lgtm


dart2js should not create Isolates with more than 1500 properties

v8 (and probably other engines) have a hard limit for fast properties. In the case of v8 it is 1024+512.
This means that a program that has more static functions (including factories and classes) will run in dictionary mode.
dart2js should (be able to) split its isolate into smaller pieces to make sure this never happens.

note: this bug is still relevant (this is not about dart:isolate support)


Setup ability to provide authenticated ingresses to arbitrary web apps

Setup dex to proivde oidc authentication
JupyterHub provides oauth2, but not oidc. This sucks, but
as with most problems in computer science, we can solve this
with another layer of indirection.
In this case, we use https://dexidp.io to setup an oidc provider
that is itself authenticated via JupyterHub. This is transparent
to the user (because we don't require any consent screens), so in
practice it's gonna look like JupyterHub is providing oidc itself.
Instead of automatically injecting config from the deployer,
we're instead manually copy-pasting config into the .values
files directly. This helps with right to replicate, and keeps our
deployer smaller

Setup oauth2-proxy alongside dex
We'll use nginx-ingress to authenticate against our hub, and we'll
run an oauth2-proxy as a sidecar with dex so it can be used to
authenticate requests!

Add staticSites that can be protected by oauth2-proxy

Uses nginx to serve these, and a 5min git pull to pull a git
repo. Copied from earlier docs_service code
Use ingress provider to specify the path under which the
static site is available, rather than the hub proxy. This is
simpler and allows us to put them anywehere (like
staging.2i2c.cloud/textbook rather than
staging.2i2c.cloud/services/textbook)
Use nginx-ingress to provide authentication for the static
server, via https://kubernetes.github.io/ingress-nginx/examples/auth/oauth-external-auth/

TODO

[ ] Add documentation

Fixes #1500

cc @GeorgianaElena for awareness since this one will be needed for the upcoming #1300.

You can test this out at staging.2i2c.cloud/textbook!

This looks great to me - I created a second issue (linked in the parent issue) to track documenting this as well

@choldgraf i've added docs on how to enable it and how frequently it gets updated. Not user facing though.

I've added support for pulling from private repos, and also added docs on how to do that!
I'm going to mark this as ready to review. Need to write a topic/ help page on how this actually works though, but doesn't need to block this PR

@consideRatio I appreciate the thought you put into keeping things consistent, thank you. I've addressed all your concerns I think.

Need to write a topic/ help page on how this actually works though, but doesn't need to block this PR

Should we open an issue to track this?


Start-AMBARemediation.ps1 fails in Azure Government Environment

The script Start-AMBARemediation.ps1 fails in the Azure Government environment with the following error message:
The given key 'AzureAttestationServiceEndpointSuffix' was not present in the dictionary.

My guess is that the base URI for ARM is different in Gov and not properly set when the script runs.

Azure Public: management.azure.com
Azure Government: management.usgovcloudapi.net

Hello @sdolgin ,
thanks for your feedback. AMBA-ALZ is not officially supported on AzureGov environment and you are rights the the URI is different. However if you were able to deploy it, I would would give the remediation script a try using a private version containing a possible fix/workaround. Let me know if this is ok to you.
Thanks,
Bruno

Hello @sdolgin ,
given the confirmation received via email, I am going to close this issue as resolved.
Feel free to reopen it or to create a new one should it be the case.
Thanks,
Bruno.


Students don't see all Feedback

Describe the bug
Lots of students told us that their complaint was accepted, but nothing happened. When we checked the status there was even Feedback, but they can't see it. In addition to that we were also told that they cannot see single Feedbacks, but General Feedback (That's why they complained in the first place). We were told that this happens for multiple types of exercises. Programming and File Upload.
To Reproduce
It seems like they can only see what's in the green box, but not what's in the red boxes (here for a file upload exercise).

Update: Received Screenshot from student

Fixed in 3.9.5


docs: improve cn readme

docs: improve part of cn readme and keep sync with en readme

Love this, thank you! This file has been languishing for a while and there's no easy way for me to keep it synchronized with the English readme. Here's hoping auto-translation gets good enough soon that this won't been necessary.


Bump version number for 0.4.0 release

Coverage remained the same at 99.779% when pulling 6657c510aae4d8d716606ec2c12f43bcba709201 on wincent:prep-0.4.0 into 784b2278903a9c8617be6af81050ea72d9ce1c8b on graphql:master.


20lab project submission (Attempt #2)

What changed? Why?
20lab project submission, URL changed to Base version, removed tags field and added category + subcategory as per new requirements
Notes to reviewers
How has it been tested?

🟡 Heimdall Review Status

Requirement
Status
More Info

Reviews

🟡
0/1

Denominator calculation

Show calculation

1 if user is bot
0

1 if user is external
0

From .codeflow.yml

1

Additional review requirements

Show calculation

Max
0

0

From CODEOWNERS

0

Global minimum
0

Max

1

1

1 if commit is unverified
0

Sum
1

@AdamK222
Thanks for the update! It seems this still doesn't automatically select Base:

Please let us know once this is resolved.

Since it has been some time without a reply, closing for now. Please let us know when the issue is resolved by opening a new PR. 🙏


Transition to using flake8 for Python linting

With our current use of pylint, style problems are hidden behind a score and there is no real concept of passing or failing, leaving the burden on the code reviewer to point out style corrections.  This ticket begins the transition to using flake8, which while a bit less strict than pylint, dispenses with the notion of a score and will allow us to say that code passes or fails the style check.
ref #1205

Can one of the admins verify this patch?

@mjstealey Please review.

@jbradberry - Could you point me towards which files I should be looking at here? Github barfed with 275 changed files and I'll need to checkout the branch locally to review.

@mjstealey Yeah, it touches a lot of files.  It appears to be possible to examine the diff of each commit in github in its entirety, so that's what I would recommend.  Of particular note is the third commit, where I used the 'aggressive' flag in autopep8.  This performs some potentially dangerous changes, and so would probably have the only code changes that would be of concern.

@mjstealey Oh, and I also need to add a couple of pip installation lines to the Dockerfile in the hs_docker_base repo, to add flake8 and its requirements.

need to add a couple of pip installation lines to the Dockerfile in the hs_docker_base

@jbradberry - There is a Dockerfile that will be picked up in the main repository that you can add your code to: https://github.com/hydroshare/hydroshare/blob/flake8_transition/Dockerfile#L4-L6
This Dockerfile exists for this purpose, and changes will be built and tested against it in the Jenkins jobs. It also much simpler than trying to regenerate a new base image locally which is quite time consuming.
Once it passes there I'll migrate the new bits to the hs_docker_base repository when it comes time to release. The hs_docker_base release numbers are in step with the hydorshare release, so the next one will be 1.6.11.

Ah, excellent.  I'll go ahead and get that submitted in this PR, then.

@jbradberry - Is it expected that there is no output generated?
Have run this locally as:

docker exec -ti hydroshare ./run-pylint which yields no output in the terminal.
docker exec -ti hydroshare ./run-pylint-jenkins which yields an empty pylint.out file.

@mjstealey Yes, it is expected that the output is empty.  Empty output is a pass, non-empty is a fail.  Or go by the return code, zero is a pass, non-zero is a fail.
I do have a considerable number of files currently excluded from being linted, since the remaining work to be done on them is going to need to be done manually.  This is something that should be dealt with gradually, with each developer cleaning things up as they go and removing their files from the exclusion list.  This is something that the code reviewers are going to have to watch out for and bring up in reviews.

@jbradberry and @mjstealey May we should discuss this during the call tomorrow.

@pkdash I am out of the office at PyCon until next week.

Jenkins admin needs to whitelist request for testing.

@jbradberry - Looks like this branch would need to be regenerated against the current develop branch using whichever tooling you used due to the number of files being touched.

@mjstealey yep, that was mostly done until I got hijacked by something else.  Let me get this fixed up, shouldn't be more than about 15 minutes to finish.

@mjstealey This should now be good.

... and now it's not.

@mjstealey All right, it's unreasonable for this to continue to be blocked, so I've taken out the automated cleanup commits.  We can revisit this once the infrastructure has been changed over.


Create cookbook

Is your feature request related to a problem? Please describe.
We need to add a Cookbook with examples of the most common questions. Or even the closed issues/PRs with interesting info, such as: https://github.com/SceneGate/Yarhl/pull/100
Describe the solution you'd like
Add a new article in the docs called Cookbook.

Done! https://github.com/SceneGate/Yarhl/pull/108


Creating tutorial 2 and tutorial 3 in C#, translating from Python

If these look OK, I can continue translating the other tutorials.

Hi @murven, thanks so much for doing this. We've been holding off on doing the C# samples because we're looking for the best cross-platform solution. Ideally we wouldn't be checking in .csproj and .sln files etc, and we'd be able to run the C# samples on all platforms. @timhutton - do you have any thoughts on this?

I see what you mean, I will take a look at converting these examples to .NET Core then.


solved the sign up issue

add google authentication by using firebase
add some other functionality like when user logged in there it will show profile instead of sign in
adding sign out functionality
when your signed in then it will redirect user to home page
when your signed out then it will redirect user to home page
i hope you will like the work and other extra functionality that i add

Okay..will review it..
Thanks for the pr!

hey these are some files need to correct to avoid conflicts......plzz look into this

also first sync the repo, then make a pr!

resolve merge conflicts

Hii @Prashant-2505 I loved your work but unable to merge your branch since it's giving conflicts..Could you pls sync your branch and update or open a new PR?
Thankyou so much for your patience!


Implement std::error::Error for most errors

I added an Error impl for all errors that implement Display. I am planning on making another pull request that implements Display and Error for the remaining errors later.

@kajacx Hey, thank you this is great! I usually forget to add this trait implementation because in no_std mode it is currently unavailable. However, this is hopefully changing very soon.

I will merge this PR so you can do the planned Display and Error impls in a follow-up PR if you like. :)
Thanks again for your contribution!


Hotfix/2.4.5

Many thanks for contributing to QUBE!
PR Checklist
Please fill in the appropriate checklist below (delete whatever is not relevant). These are the most common things requested on pull requests (PRs).

[ ] This comment contains a description of changes (with reason)
[ ] Referenced issue is linked
[ ] If you've fixed a bug or added code that should be tested, add tests!
[ ] Documentation in docs is updated
[ ] CHANGELOG.rst is updated

Description of changes
Please state what you've changed and how it might affect the user.
Technical details
Please state any technical details such as limitations, reasons for additional dependencies, benchmarks etc. here.
Additional context
Add any other context or screenshots here.

I cant find the underlying issue for the boolean write-out. Code looks good. Not sure if this is a bug in the ryaml lib though ...


Email Updation and User Information

Email is not getting updated probably it is commented out in the signals then While inspecting using DEV tools The user information card is not getting displayed. Hope you guys will look on to it.
Thank You Sir

Hi @ShyamSundhar1411 Please check the listed issues, this bug is already registered and being taken care of in the backend.
Existing Issue

#374


Notify user if adding a class has a time conflict (a modal/popup should appear that notifies the user about the time conflict, but still give them the option to add a class.)

Overview
When a user attempts to add a class that has a time conflict, the user should be notified about the time conflict, but should still allow them to keep the overlapped class.
Goal
Display an alert or modal about the time conflict. Should display which classes have a time conflict
Requirements

[x] Design an alert/modal
[x] Algorithm to do a linear search through the classes atom to determine if a time conflict exists

Please see my recent PR,  Add warning for scheduling conflict #100


To do: the upper limit for canvas size

let the upper limit for canvas size be 3000 or so

done at [1.0.1]


need to add script execution env info into db for later report

This info will be filled into db during script env provisioning.

done in 1.0.8


Silver to Diamond balance issues

The Silver to Diamond path (both the block recipe, and the upgrade recipe) seem too cheap for being able to completely skip the need for gold.
I would like to discuss changing the recipes to either

A) Include 3 gold ingots in both recipes (replacing glass blocks)
B) Require 4 diamonds instead of 3

For the sake of discussion, here are the CURRENT recipes for the silver to diamond path:

I ran some numbers this morning on the silver to diamond thing... it doesn't feel balanced at first glance but it actually is pretty good.
To go from normal to diamond using copper and silver takes 4 copper, 4 silver, 3 diamond and 21 glass. From normal to diamond with iron and gold is 4 iron, 4 gold, 2 diamond and 22 glass.
So they're almost identical just different ores, and the slightly more common copper and silver ultimately take one more diamond to get to that level.
I'm going to leave this issue open for a while longer to invite more discussion if anybody has any but I don't plan to make any changes before the 1.0 release.


error: ‘exp’ was not declared in this scope

Hi,
I would like to build the codes in Ubuntu. When I built it, there are some errors:
make -j4
Scanning dependencies of target caffe
[  2%] Building CXX object CMakeFiles/caffe.dir/src/c_api.cpp.o
[  2%] Building CXX object CMakeFiles/caffe.dir/src/net.cpp.o
[  5%] Building CXX object CMakeFiles/caffe.dir/src/common.cpp.o
[  5%] Building CXX object CMakeFiles/caffe.dir/src/blob.cpp.o
[  7%] Building CXX object CMakeFiles/caffe.dir/src/profiler.cpp.o
[  8%] Building CXX object CMakeFiles/caffe.dir/src/syncedmem.cpp.o
[ 10%] Building CXX object CMakeFiles/caffe.dir/src/layers/absval_layer.cpp.o
[ 11%] Building CXX object CMakeFiles/caffe.dir/src/layers/argmax_layer.cpp.o
[ 13%] Building CXX object CMakeFiles/caffe.dir/src/layers/base_conv_layer.cpp.o
[ 14%] Building CXX object CMakeFiles/caffe.dir/src/layers/batch_norm_layer.cpp.o
[ 16%] Building CXX object CMakeFiles/caffe.dir/src/layers/bias_layer.cpp.o
[ 17%] Building CXX object CMakeFiles/caffe.dir/src/layers/bn_layer.cpp.o
[ 19%] Building CXX object CMakeFiles/caffe.dir/src/layers/bnll_layer.cpp.o
[ 20%] Building CXX object CMakeFiles/caffe.dir/src/layers/concat_layer.cpp.o
/home/kang/Documents/py/mini-caffe/src/layers/bnll_layer.cpp: In member function ‘virtual void caffe::BNLLLayer::Forward_cpu(const std::vector<caffe::Blob*>&, const std::vector<caffe::Blob*>&)’:
/home/kang/Documents/py/mini-caffe/src/layers/bnll_layer.cpp:15:35: error: ‘exp’ was not declared in this scope
         bottom_data[i] + log(1. + exp(-bottom_data[i])) :
                                   ^~~
/home/kang/Documents/py/mini-caffe/src/layers/bnll_layer.cpp:15:35: note: suggested alternative: ‘exit’
         bottom_data[i] + log(1. + exp(-bottom_data[i])) :
                                   ^~~
                                   exit
/home/kang/Documents/py/mini-caffe/src/layers/bnll_layer.cpp:15:26: error: ‘log’ was not declared in this scope
         bottom_data[i] + log(1. + exp(-bottom_data[i])) :
                          ^~~
/home/kang/Documents/py/mini-caffe/src/layers/bnll_layer.cpp:15:26: note: suggested alternative: ‘long’
         bottom_data[i] + log(1. + exp(-bottom_data[i])) :
                          ^~~
                          long
CMakeFiles/caffe.dir/build.make:350: recipe for target 'CMakeFiles/caffe.dir/src/layers/bnll_layer.cpp.o' failed
make[2]: *** [CMakeFiles/caffe.dir/src/layers/bnll_layer.cpp.o] Error 1
make[2]: *** Waiting for unfinished jobs....
CMakeFiles/Makefile2:141: recipe for target 'CMakeFiles/caffe.dir/all' failed
make[1]: *** [CMakeFiles/caffe.dir/all] Error 2
Makefile:83: recipe for target 'all' failed
make: *** [all] Error 2

Does anyone know how to solve this problem?

I'm having the same issue. Could you solve it?
nico@Nico:~/Desktop/Proyectos/mini-caffe/build$ cmake .. -DCMAKE_BUILD_TYPE=Release
-- Use OpenBLAS for blas library
-- Configuring done
-- Generating done
-- Build files have been written to: /home/nico/Desktop/Proyectos/mini-caffe/build
nico@Nico:~/Desktop/Proyectos/mini-caffe/build$ make -j4
Scanning dependencies of target caffe
[  2%] Building CXX object CMakeFiles/caffe.dir/src/layers/elu_layer.cpp.o
[  2%] Building CXX object CMakeFiles/caffe.dir/src/layers/bnll_layer.cpp.o
[  4%] Building CXX object CMakeFiles/caffe.dir/src/layers/eltwise_layer.cpp.o
[  5%] Building CXX object CMakeFiles/caffe.dir/src/layers/embed_layer.cpp.o
/home/nico/Desktop/Proyectos/mini-caffe/src/layers/bnll_layer.cpp: In member function ‘virtual void caffe::BNLLLayer::Forward_cpu(const std::vectorcaffe::Blob*&, const std::vectorcaffe::Blob*&)’:
/home/nico/Desktop/Proyectos/mini-caffe/src/layers/bnll_layer.cpp:15:35: error: ‘exp’ was not declared in this scope
bottom_data[i] + log(1. + exp(-bottom_data[i])) :
^~~
/home/nico/Desktop/Proyectos/mini-caffe/src/layers/bnll_layer.cpp:15:35: note: suggested alternative: ‘exit’
bottom_data[i] + log(1. + exp(-bottom_data[i])) :
^~~
exit
/home/nico/Desktop/Proyectos/mini-caffe/src/layers/bnll_layer.cpp:15:26: error: ‘log’ was not declared in this scope
bottom_data[i] + log(1. + exp(-bottom_data[i])) :
^~~
/home/nico/Desktop/Proyectos/mini-caffe/src/layers/bnll_layer.cpp:15:26: note: suggested alternative: ‘long’
bottom_data[i] + log(1. + exp(-bottom_data[i])) :
^~~
long
/home/nico/Desktop/Proyectos/mini-caffe/src/layers/elu_layer.cpp: In member function ‘virtual void caffe::ELULayer::Forward_cpu(const std::vectorcaffe::Blob*&, const std::vectorcaffe::Blob*&)’:
/home/nico/Desktop/Proyectos/mini-caffe/src/layers/elu_layer.cpp:16:20: error: ‘exp’ was not declared in this scope
+ alpha * (exp(std::min(bottom_data[i], static_cast<real_t>(0))) - 1);
^~~
/home/nico/Desktop/Proyectos/mini-caffe/src/layers/elu_layer.cpp:16:20: note: suggested alternative: ‘exit’
+ alpha * (exp(std::min(bottom_data[i], static_cast<real_t>(0))) - 1);
^~~
exit
CMakeFiles/caffe.dir/build.make:566: recipe for target 'CMakeFiles/caffe.dir/src/layers/elu_layer.cpp.o' failed
make[2]: *** [CMakeFiles/caffe.dir/src/layers/elu_layer.cpp.o] Error 1
make[2]: *** Waiting for unfinished jobs....
CMakeFiles/caffe.dir/build.make:350: recipe for target 'CMakeFiles/caffe.dir/src/layers/bnll_layer.cpp.o' failed
make[2]: *** [CMakeFiles/caffe.dir/src/layers/bnll_layer.cpp.o] Error 1
CMakeFiles/Makefile2:141: recipe for target 'CMakeFiles/caffe.dir/all' failed
make[1]: *** [CMakeFiles/caffe.dir/all] Error 2
Makefile:83: recipe for target 'all' failed
make: *** [all] Error 2

I fixed it and pull request, please see: https://github.com/luoyetx/mini-caffe/pull/104

I fixed it and pull request, please see: #104

thanks , it does helps me a lot


Open db file with sqlcipher

I created a DB in my app with SQLitePCLRaw.bundle_e_sqlcipher and works ok, but when I try to open the DB file with SQLCipher version 3.15.2 I got the error "Error: file is encrypted or is not a database"
Is SQLitePCLRaw.bundle_e_sqlcipher incompatible with SQLCipher?

In general, e_sqlcipher and SQLCipher should be compatible.
Note however that there was a breaking change in SQLCipher a year or two ago.  Your "3.15.2" version might have a problem with current e_sqlcipher builds.
See also:
https://github.com/ericsink/SQLitePCL.raw/wiki/Expectation-setting-for-e_sqlcipher


[0.5.1-59-0.6.2-77] randomly sparkle/noise flashing green pixels

In 0.5.1-59 MATE, After updater scripts (pine64, system, and uboot) to fixed flicker backlight brightness problem. I started noticed noise random green pixel (blue, green, and gray color display area) when I plugged power. Unplugged power will slowly stop noise random green pixel.
In 0.6.2-77 MATE, noise random green pixel will show up without plug-in power anytime. It will not be stopped in battery mode.
I requested LCD screen replacement because Armbian 5.32 image caused my laptop got permanent 4th dead green pixel. I got LCD screen replacement today. no sign of permanent dead green pixel and half-dead black pixel excepted randomly sparkle/noise flashing green pixels still show up. I can confirmed LCD screen is not problem itself. I am sure it is kind of software bug.
Here's similar problem & video https://forum.pine64.org/showthread.php?tid=4843
I am planning test 0.7.17 MATE later.

0.7.28 MATE on SDcard seem fixed issues both.


HA beta 2023.5  results in frequent utility_meter warning

System Health details
2023-04-28 11:40:29.766 WARNING (MainThread) [homeassistant.components.utility_meter.sensor] Googlehome hub device energy yearly received an invalid state change coming from sensor.googlehome_hub_device_energy (unavailable > 37.93)
my config for this entity is
      - entity_id: media_player.googlehome_hub
        name: Googlehome hub
        standby_power: 2.8
        fixed:
          states_power:
            playing: 4.1
            paused: 3.3
            idle: 2.8

I suspect this to be related to streaming camera streams to this Hub, and since that doesnt really go well for other reasons, this media_player might turn to an unexpected state not being guarded in this CC?
its a bit hard to debug tbh, so would appreciate any help I could get....
Checklist

[X] I have read the FAQ to see if there is a known solution to my problem.
[X] I have enabled debug logging for my installation.
[X] I have filled out the issue template to the best of my ability.
[X] This issue only contains 1 issue (if you have multiple issues, open one issue for each issue).
[X] This issue is not a duplicate issue of currently previous issues..

Describe the issue
see above: after updating to beta HA 2023.5 this keeps being logged
it might also be a utility_meter issue only, which is choking on 'unavailable' states. However, this entity should not go unavailable all the time, and I cant see why it does that.(well other than the mentioned camera stream)
I do have the ignore_unavailable_state in the main config, but it might not be related to device_energy entities?
Reproduction steps

update to beta

...
Debug logs
will follow suit

Diagnostics dump or YAML config
no GUI

Did you check the state histories of media_player.googlehome_hub and powercalc sensor.googlehome_hub_device_power entities?
The energy sensor sensor.googlehome_hub_device_energy will turn unavailable whenever the power sensor gets unavailable. As a result the utility meter will throw a warning as it cannot calculate the new delta.

see https://discord.com/channels/330944238910963714/427516175237382144/1101868009187983470
in the #beta channel on Discord, it's not an issue with Powercalc, its a utility_meter issue.
closing here, thx for your response nonetheless ;-)


How to use an enumeration?

Hello,
Sorry, if this post is not appropriate for this place, I didn't know where to send it.
So my question is simple, I would like to use the setGameMode method but this method takes as a parameter an enumeration, out when I try to write it as a string or without a string I have an error. So after that, I asked myself this probably silly question, how to use the enumerations?
Thank you in advance for your help.

I would like to add that I have already tried using importClass(), but it didn't work.

All right I found this: var GameMode = Packages.org.bukkit.GameMode;. If anyone knows any other way to do it, please share it with me.

I do it like this in Magikcraft:
const GameMode = Java.type("org.bukkit.GameMode");
const modes = {
    c: GameMode.CREATIVE,
    s: GameMode.SURVIVAL,
    x: GameMode.SPECTATOR
}

Magikcraft uses TypeScript, but it should work in vanilla ScriptCraft if you replace const with var.

Thanks for sharing it works, by searching a little more on Magikcraft, I didn't find a tutorial or page laying the basics to get started, but I still found the API documentation, if you know of a useful link in that sense I would like to. :) . By doing a little research I understood that Java.type() was part of the Nashorn engine out I thought ScriptCraft was using Rhino, I'm a little lost, would you explain it to me please? In addition, I did not find many documents on Rhino except for the few pages on MDN, which I find very poor. However as far as Nashorn is concerned I was able to find the Oracle documentation, but if you know of any interesting resources to read to learn more about Nashorn I would ask you to let me know.

Maybe it's better if I create another topic.
I put this one as resolved.


hybrid mapping struct / map[string]float

Hi,
First of all, thank you very much for contributing this library to the community. It seems to bee quite easy to use.
I am trying to get arbitrary data out from a timescale database and I would like to mix structs and map[string] scanning.
Given those structs:
type Data struct {
	PhConTot float64
	PhGenTot float64
}

type Metric struct {
	Time     time.Time
	DeviceId string
	Data     Data
}

I am correctly scanning data with
	var metrics []*Metric
	if err := pgxscan.Select(ctx, conn, &metrics, `
		select time, device_id, ph_con_tot as "data.ph_con_tot", ph_gen_tot as "data.ph_gen_tot"
		from metrics_computer_wide
		  WHERE device_id = '9d5eaae0-421b-11ec-9949-7f0fdad2c99c' and ph_con_tot is not null and
		  time > '2022-04-01' and time <= '2022-04-05'
		`); err != nil {
		fmt.Fprintf(os.Stderr, "Unable to query database: %v\n", err)
	}

But since Data fields can be a huge list of options, I would like it to be a map[string]float64. For example
type MetricMap struct {
	Time     time.Time
	DeviceId string
	Data     map[string]float64
}

And querying like
	var metricsMap []*MetricMap
	if err := pgxscan.Select(ctx, conn, &metricsMap, `
		select time, device_id, ph_con_tot as "data.ph_con_tot", ph_gen_tot as "data.ph_gen_tot"
		from metrics_computer_wide
		  WHERE device_id = '9d5eaae0-421b-11ec-9949-7f0fdad2c99c' and ph_con_tot is not null and
		  time > '2022-04-01' and time <= '2022-04-05' limit 10
		`); err != nil {
		fmt.Fprintf(os.Stderr, "Unable to query database: %v\n", err)
	}

Then I am getting
Unable to query database: scany: column: 'data.ph_con_tot': no corresponding field found, or it's unexported in main.MetricMap
Is there any way to mix structs and map[string]? or can I extend the scanner?
Thank you very much!

I just found issue #76 and I thought my problem was solved. So I defined:
type CustomMetric struct {
	Time     time.Time
	DeviceId string
	Data     MyData `db:"data.*"`
}

type MyData struct {
	Data map[string]float64
}

And
func (m *MyData) Scan(v interface{}) error {
	fmt.Println(v)
	return nil
}

But it seems that the problem persists: scany: column: 'data.ph_con_tot': no corresponding field found, or it's unexported in main.CustomMetric and Scan is not even called.
I think this should be the way to go, but still something is wrong. Can anybody give me a clue?
Thank you very much!

Hi. Thank you for your issue!
Right now "data.ph_con_tot" and "data.ph_gen_tot" are two distinct columns and there is no way to scan them into the .Data field for scany. You need to combine these two columns into a single JSON object:
		select time, device_id, json_build_object('ph_con_tot', ph_con_tot, 'ph_gen_tot', ph_gen_tot) as data
		from metrics_computer_wide
		  WHERE device_id = '9d5eaae0-421b-11ec-9949-7f0fdad2c99c' and ph_con_tot is not null and
		  time > '2022-04-01' and time <= '2022-04-05' limit 10

This way scany will pass the .Data field map to the underlying library and it will parse the JSON object into it.
Let me know if you have any problems with it!

Yeah, it worked perfectly!
Thank you very much!

Hi Georgy,
I am trying to re-open this issue because I am facing an un expected behaviour. Some days ago I told you that my POC worked correctly, but now I am getting a weird error.
This is my code:
package main

import (
	"context"
	"database/sql"
	"fmt"
	"github.com/georgysavva/scany/pgxscan"
	"github.com/georgysavva/scany/sqlscan"
	"github.com/jackc/pgx/v4"
	_ "github.com/lib/pq"
	"time"
)

type MetricMap struct {
	Time     time.Time
	DeviceId string
	Data     map[string]interface{}
}

func main() {
	fmt.Println("Starting timescale playground")
	ctx := context.Background()
	connStr := "postgres://postgres:postgres@localhost:5430/postgres?sslmode=disable"
	db, err := sql.Open("postgres", connStr)
	if err != nil {
		fmt.Println(err)
		return
	}
	sqlJson := `
		select time, device_id, json_build_object('ph_con_tot', ph_con_tot , 'ph_gen_tot', ph_gen_tot) as "data"
		from metrics_computer_wide
		  WHERE device_id = '9d5eaae0-421b-11ec-9949-7f0fdad2c99c' and ph_con_tot is not null and
		  time > '2022-04-01' and time <= '2022-04-05' limit 10
		`
	sqlJson = "SELECT time, device_id, json_build_object('ph_con_tot',ph_con_tot,'ph_gen_tot',ph_gen_tot) as data FROM metrics_base WHERE device_id = '08c210ca-7077-4907-8ea7-a98b77d4df0c' AND time >= '2022-05-02 13:13:56' AND time <= '2022-05-02 13:14:56'"
	var metrics []MetricMap

	err = sqlscan.Select(ctx, db, &metrics, sqlJson)
	if err != nil {
		fmt.Println(err)
	} else {
		for _, metric := range metrics {
			fmt.Printf("%s %s %f %f\n", metric.Time, metric.DeviceId, metric.Data["ph_con_tot"], metric.Data["ph_gen_tot"])
		}
	}

	// Now with PGX Scan
	dbPgx, _ := pgx.Connect(ctx, connStr)

	pgxscan.Select(ctx, dbPgx, &metrics, sqlJson)
	if err != nil {
		fmt.Println(err)
	} else {
		for _, metric := range metrics {
			fmt.Printf("%s %s %f %f\n", metric.Time, metric.DeviceId, metric.Data["ph_con_tot"], metric.Data["ph_gen_tot"])
		}
	}
}

In both cases the error is:
Scan error on column index 2, name "data": unsupported Scan, storing driver.Value type []uint8 into type *map[string]interface {}
As you can see, the code is identical to the one we discussed earlier, but it seems there is some problem with data conversion now.
Can you give some light on the error?
Thank you very much!

@xorduna I just replied in the new issue.


ci: harden github actions

PR Checklist

[ ] Unit Tests have been added for new changes
[x] API tests have been updated if applicable
[x] All commented code has been removed
[ ] If you've added a dependency, you've ensured license is compatible with Apache 2.0 and clearly outlined the added dependency.

What are you changing?

OSSF Scorecard - Token Permissions - Missing top level minimum permission.
Anything the reviewer should know when reviewing this PR?
If the there are associated PRs in other repositories, please link them here (i.e. open-amt-cloud-toolkit/repo#365 )

replaced by #1516


Sandboxed App for macOS crashing

Code:
    let leftChannel   = AKOscillator()          // log error
    let rightChannel  = AKOscillator()          // log error
    left = AKPanner(leftChannel, pan: -1)       // log error
    right = AKPanner(rightChannel, pan: 1)     // log error
    mixer = AKMixer(left,right)                          // crash

Output:
AKOscillator.swift:init(waveform:frequency:amplitude:detuningOffset:detuningMultiplier:):175:Parameter Tree Failed
AKOscillator.swift:init(waveform:frequency:amplitude:detuningOffset:detuningMultiplier:):175:Parameter Tree Failed
AKPanner.swift:init(_:pan:):79:Parameter Tree Failed
AKPanner.swift:init(_:pan:):79:Parameter Tree Failed
2018-06-23 18:50:14.108436+0300 CoherentMac[67507:2019853] [avae] AVAEInternal.h:70:_AVAE_Check: required condition is false: [AVAudioEngine.mm:393:AttachNode: (node != nil)]
2018-06-23 18:50:14.108892+0300 CoherentMac[67507:2019853] required condition is false: node != nil

I don't know what to do about this. Maybe AudioKit apps can't be sandboxed?  I need more information to go on.

@aure
Sandboxing is mandatory if you need to submit app to the app store.  It limiting access to filesystem, networking, camera, microphone, etc. For example if you caching some files in app's folder it is ok, but if you access file system out of app's folder you need to specify exactly what you need:

If you need any assistance I will be glad to help you.

Can you try checking the microphone?  Even if you're not using it?

enabling of microphone in App Sandbox didn't help.

@aure, @megastep  I did try to debug Sandboxed Hello Word sample from AudioKit.
And have figured out source of problem: AVAudioUnit.instantiate returns nil.
It turns out that sandboxing of audio unit more complicated than turning some checkbox "on".
https://developer.apple.com/library/archive/technotes/tn2312/_index.html
Currently i'm trying to investigate the problem, but i'm not sure if have enough competence in CoreAudio to resolve this issue quick enough. So your help will be highly appreciated.

This entitlements file did work for me, but it doesn't cover all possible cases

com.apple.security.app-sandbox

com.apple.security.device.audio-input

com.apple.security.device.audio-video-bridging

com.apple.security.files.bookmarks.document-scope

com.apple.security.network.client

com.apple.security.temporary-exception.audio-unit-host

com.apple.security.temporary-exception.mach-lookup.global-name

com.apple.midiserver
com.apple.midiserver.io

I'm closing the issue. Please add sandboxing info to your documentation and please check documentation about kAudioComponentFlag_SandboxSafe for  AudioComponentFindNext(,).
I'm sure it will be helpful for someone else.


How to migrate to a new computer?

Issue description
Scenario: I have home-manager running on a laptop and configured to handle most of my setup (bash, profile, xsession, WM, ...). I got a new laptop.
I can't just rsync my HOME directory because this copies many (home-manager managed) symlinks that would be broken on the target machine.
If I start by installing home-manager on the new laptop, I need to copy my home-manager configuration to be able to have my configuration on the new laptop. When I'm done setting up my environment, I still can't copy my old HOME directory to the new laptop because this would override the newly generated configuration file symlinks. (If the home-manager's configuration is exactly the same, you should get identical nix paths between the 2 computers in which case overriding the symlinks is fine).

All I would do is copy your home.nix and related files (or even the entire ~/.config/nixpkgs) to the ~/.config/nixpkgs on your other machine and install home-manager as normal. Is there any reason this wouldn't/doesn't work for you?

All I would do is copy your home.nix and related files (or even the entire ~/.config/nixpkgs) to the ~/.config/nixpkgs on your other machine and install home-manager as normal. Is there any reason this wouldn't/doesn't work for you?

This would work perfectly. And then you need to copy all the data that is not handled by home-manager (e.g., music, documents, photos). You can't just copy your HOME directory from one machine to the other one because this would overwrite the home-manager  generated symlinks.

FWIW I use Unison to synchronize my two main laptops and exclude the HM managed files by interpolating
hmFilesIgnorePatterns =
  concatStringsSep "\n"
  (map (file: "ignore = Path ${file.target}")
  (filter (file: !file.recursive)
  (mapAttrsToList (_: file: file) config.home.file)));

into the generated Unison profile. I imagine something similar should be possible with rsync.

This makes a lot of sense, thank you.


Update to alpine 3.8 for arm support

Tested on amd64 and arm64, could not test on arm if someone wants to try it out.

Tested-by: Lee Jones<EMAIL_ADDRESS>

LGTM

With regards to ARM32, I built my own ARMv7 version of alpine:3.8 and used it as a base for this project.  It worked just fine, thus once Alpine provides ARMv7 images this project should 'just work'.
Just bear in mind that until that point, ARMv7 support will be broken.
One thing you can do in the mean time, is build and push your on version of alpine:3.8 to base on.

ARM32: Looks like Alpine doesn't support ARMv7 at all. Will look into this to try and fix it.

FYI: I spoke with the folks at Alpine.  ARMv7 support should be released by the end of the year. \o/