Meta shim

I think, we may add default shim for Meta plugin. Something like
declare module 'vue/types/options' {
  interface ComponentOptions<V extends Vue> {
    meta?: any;
  }
}

Thanks for this idea. We'll be looking into it today.

We're actually working on removing ALL shims, but I'll leave this issue open until we are able to provide that in beta.

Shims are now a thing of the past.


Volvo on Call not loading

Make sure you are running the latest version of Home Assistant before reporting an issue.
You should only file an issue if you found a bug. Feature and enhancement requests should go in the Feature Requests section of our community forum:
**Home Assistant release (hass --version):0.39.3
**Python release (python3 --version):Python 3.5.2
**Component/platform:Volvo on Call
**Description of problem:
17-03-05 11:27:24 INFO (MainThread) [homeassistant.components.device_tracker] Setting up device_tracker.volvooncall
17-03-05 11:27:24 ERROR (MainThread) [homeassistant.components.device_tracker] Error setting up platform volvooncall
Expected:
Problem-relevant configuration.yaml entries and steps to reproduce:

Traceback (if applicable):

Additional info:

No other error messages?
Can you please turn on debug logging for the component and the library?
logger:
  default: info
  logs:
    volvooncall: debug
    homeassistant.components.volvooncall: debug

Worked fine. Thanks. Component page needs to be updated with this info:
Example configuration.yaml entry
device_tracker:

platform: volvooncall
username: username
password: password

You är right. Feel free to help out by providing an updated version (I believe the pages contain an edit-link at the top)


Add extra tests for the method getEntryFromPDFContent in PdfContentImporterTest.java

Add two additional tests to improve branch coverage of the function.

This is interesting. Please use open access PDFs from IEEE, ACM, Springer.
Maybe, even better, create the PDFs using LaTeX and Word templates. See https://github.com/latextemplates/ for an index.
See https://github.com/JabRef/jabref/tree/main/src/test/resources/org/jabref/logic/search how we recently did this in JabRef...


Slackbot custom commands don't display on IRC

I've created some custom responses for Slackbot (the native bot included with all Slack teams) and for some reason it won't display any of the responses in IRC. Although it does show the command send by <user> when the custom response is triggered from Slack.
I have included the proper lines in my JSON config but it still will not display on IRC.
    "commandCharacters": ["!", "."],
    "muteSlackbot": false

This is because of #50.

Maybe an easier solution might be to include optional commands within the slack-irc bot that are written to IRC? So long as the bridge is connected the returned commands will display on Slack. Unless this is already a feature and I'm totally missing it within the source.


ENH: Load futures from bundles.

Currently only equities can be loaded from bundles. There are at least two
reasons for this. First, on write zipline/data/bundles/core.py ingest()
does not distinguish between equities and futures; instead all ingestions
are made into folders daily_equities.bcolz and minute_equities.bcolz.
Second, on read only equities readers are being passed into DataPortal.
This commit addresses the second issue.
This works well for data bundles containing futures exclusively. It does
not fix the bigger issue of supporting bundles which contain both equities
and futures.

Coverage remained the same at 87.196% when pulling 268bc9b99d9035579728e81c9b5d755d1d2dc151 on JoaoAparicio:futures_readers into c9262a8cb2a723d4ae150f3ae75b1892f6b3c5ae on quantopian:master.

Hey @JoaoAparicio, thanks, this looks great! Would you be willing to tackle the first issue as well to make this a complete solution?
I believe the main fix would be to update the ingest step here to have futures analogs for the directories and writers created for equities, as well as updating the ingest functions for the existing bundles, (e.g. https://github.com/quantopian/zipline/blob/master/zipline/data/bundles/quandl.py#L280-L281).

@yankees714 Please see https://github.com/quantopian/zipline/pull/1982

@yankees714 Could you clarify how you expect this to be done? You linked to the ingest function in core.py. Now look at this line, where this function actually calls bundle.ingest. Two writers (minute_bar_writer and daily_bar_writer) are passed in that call. So, should we be passing two writers per asset class?
I see two options.
A) If for now we assume that a bundle contains only one asset class (either equities or futures) then the current commit works fine as it is, and the folder name where the data is written to is irrelevant, and I say we merge this as it is.
B) On the other hand, for a bundle to handle multiple asset classes then we have to modify that function call to pass 4 writers. However I'm expecting that a lot more code would have to be changed elsewhere for the backtester to support multiple asset classes simultaneously. Consider that even in quantopian you can't do both equities and futures simultaneously (when backtesting you have to either pick equities calendar, or futures calendar).

@JoaoAparicio The backtester supports both equities and futures in the same backtest – the calendar specifies when you can trade, but doesn't impact what you can trade. On Quantopian, we disallow trading futures on the equities calendar since there's not really a good reason to do it, but zipline shouldn't have an issue.
The part of this current solution that concerns me is that we're feeding the same data into both the futures and equities readers (here), which I think could cause confusion.
I wouldn't expect B) to be a huge chunk of work, just, as you say, expanding the ingest step to have 2 writers per asset class. Think you'd be up for taking a look at that?

@yankees714 Yes, I'll do it.

@yankees714 I think I've addressed everything we talked about. The only thing remaining is getting the tests to pass. Let me know if everything is OK before I start working on the tests.

@yankees714 Fixed the typos you mentioned and rebased-out spurious commits. Gonna work on the tests now.

Modified tests.data so that it's consistent with ingest() taking 2 writers per asset class (total 4 writers).
Next need to modify tests.test_example to do the same.

@yankees714 Should a bundle that uses equities data but not futures data create empty futures folders?

I think that sounds fine, that's what you have now, correct?

No. data/bundles/core.py and quantopian-quandl have futures writers on the ingest function, but for some reason the quantopian-quandl bundle doesn't create empty futures folders. I expected it to, and apparently so does the test.test_example which looks at what writers the bundle has to know what folders to expect and is currently failing.
I think this is some idiosyncrasy specific to the quantopian-quandl bundle, the reason for which I haven't been able to identify so far. In comparison, my own futures-only bundle (that I also shared in a different PR) has no equities, but automatically zipline knows that it should create empty equities folders.

I think the issue here is not that the directories don't exist, but that here we're attempting to open bcolz file with futures pricing data, and that file doesn't exist. That makes sense, as in the past, the example have only ingested equities data.
Want to try adding a check to zipline.data.bundles.core.load that the futures minute/daily files exist before trying to construct readers around them? If the files don't exist, I think we can just set the reader to None.

Closing since it looks like this PR has gone stale. Please feel free to reopen if this is something you are still interested in. To be completely transparent, improving futures support is currently not in our short term roadmap.


PROTO-3028: revised reputer stake timeseries [DO NOT MERGE]

This is a corrected ticket from PROTO-2838
as a result of miscommunication.

Closing for a better solution using RPC endpoints directly.


[SPARK-35338][PYTHON] Separate arithmetic operations into data type based structures

What changes were proposed in this pull request?

The PR is proposed for pandas APIs on Spark, in order to separate arithmetic operations shown as below into data-type-based structures.
__add__, __sub__, __mul__, __truediv__, __floordiv__, __pow__, __mod__, __radd__, __rsub__, __rmul__, __rtruediv__, __rfloordiv__, __rpow__,__rmod__
DataTypeOps and subclasses are introduced.
The existing behaviors of each arithmetic operation should be preserved.
Why are the changes needed?

Currently, the same arithmetic operation of all data types is defined in one function, so it’s difficult to extend the behavior change based on the data types.
Introducing DataTypeOps would be the foundation for pandas APIs on Spark: Separate basic operations into data type based structures..
Does this PR introduce any user-facing change?

No.
How was this patch tested?

Tests are introduced under pyspark.pandas.tests.data_type_ops. One test file per DataTypeOps class.

Test build #138639 has started for PR 32469 at commit 578ac9f.

Test build #138639 has finished for PR 32469 at commit 578ac9f.

This patch passes all tests.
This patch merges cleanly.
This patch adds no public classes.

Kubernetes integration test unable to build dist.
exiting with code: 1
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/43159/

Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/138639/

Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/43159/

Test build #138648 has started for PR 32469 at commit 86e2809.

Test build #138648 has finished for PR 32469 at commit 86e2809.

This patch fails Python style tests.
This patch merges cleanly.
This patch adds no public classes.

Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/138648/

Kubernetes integration test starting
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/43168/

Kubernetes integration test status success
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/43168/

Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/43168/

Test build #138656 has started for PR 32469 at commit 114908a.

Kubernetes integration test starting
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/43176/

Kubernetes integration test status success
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/43176/

Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/43176/

Test build #138656 has finished for PR 32469 at commit 114908a.

This patch passes all tests.
This patch merges cleanly.
This patch adds no public classes.

Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/138656/

Test build #138688 has started for PR 32469 at commit 4a0f272.

Kubernetes integration test starting
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/43209/

Kubernetes integration test status success
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/43209/

Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/43209/

Test build #138688 has finished for PR 32469 at commit 4a0f272.

This patch passes all tests.
This patch merges cleanly.
This patch adds no public classes.

Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/138688/

Test build #138694 has started for PR 32469 at commit 9cfb617.

Kubernetes integration test starting
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/43215/

Kubernetes integration test status success
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/43215/

Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/43215/

Test build #138694 has finished for PR 32469 at commit 9cfb617.

This patch passes all tests.
This patch merges cleanly.
This patch adds no public classes.

Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/138694/

Thanks! merging to master.


refactor(delayWhen): use subscribeToResult with outerSubscriber

This PR correctly applies outerSubscriber into delayWhen operator.

Merged with 621ec68.


[wip] testing mermaid generated svg

Investigating mermaid live editor and plugin options to generate SVG files from mermaid code.
Here is an SVG generated from the mermaid code in PR #23283 .
Thinking:
create a directory in repo for mermaid source files
generate SVGs from mermaid source and link SVG to page include location
save SVGs in static/images/docs
include SVG image on page

Page which includes mermaid generated SVG file:
/docs/concepts/services-networking/ingress/

👋 @sftim, Any thoughts?

Closed.

The generated diagram looks OK to me @kbhawkey
(and it's fine to tidy it further up later)

Testing the sizing/resizing of the generated image compared to dynamically generated
image on the page.
/close


Koa or Express

I noticed the demo leto page suggests the application serving is being done via Koa but on Github it suggests Express. Should make that consistent.

There is server.ts  that uses expressjs and there is server-koa.ts  That are both basic servers, but server-koa.ts does not support server side rendering. I will update the demos and add some documentation

45683e7


[BUG] FIX pep8 conflicts

python files are not yet written clean. I want it to support pep8.
A PR doing it is appreciated.

hey, @satyammittal  I would like to try this issue as my first contribution.  How do you propose i approach it

Hi @tush05tgsingh , I will suggest to follow these steps:
a) Install pep8 and read about its usage using https://pypi.org/project/pep8/.
b) Read about pep8 in https://pymbook.readthedocs.io/en/latest/pep8.html.
c) Try to run pep8 on our code.
Hint: There is a tool that automatically formats Python code to conform to the PEP 8 style guide.


@Subscribe in interface

Hi, i want to know how i can use the Subscribe annotation in interfaces.
I want to have something like this:
public interface DeviceManagerEvents {

    class DeviceEvent {
        private VSMDevice device;

        DeviceEvent(VSMDevice device) {
            this.device = device;
        }

        public VSMDevice getDevice() {
            return device;
        }
    }

    class DeviceConnectedEvent extends DeviceEvent {

        DeviceConnectedEvent(VSMDevice device) {
            super(device);
        }
    }

    class DeviceDisconnectedEvent extends DeviceEvent {

        DeviceDisconnectedEvent(VSMDevice device) {
            super(device);
        }
    }

    class DeviceFoundEvent extends DeviceEvent {

        DeviceFoundEvent(VSMDevice device) {
            super(device);
        }
    }

    @Subscribe(threadMode = ThreadMode.MAIN)
    public void onDeviceConnected(DeviceConnectedEvent event);

    @Subscribe(threadMode = ThreadMode.MAIN)
    public void onDeviceDisconnected(DeviceDisconnectedEvent event);

    @Subscribe(threadMode = ThreadMode.MAIN)
    public void onDeviceFound(DeviceFoundEvent event);
}

and then implement this interface where i want to receive the events.
The problem is that EventBus can't find the Subscribe declared in interfaces...

AFAIK Java does not support inheritance of annotations. With the exception of the @Inherited annotation, but this works only for annotations on classes.


Boot loop after enable hide jailbreak feature

hello
my iPhone 13 pro max iOS 15.1 now is stuck in infinite boot loop (jailbroken with dopamine latest version )
what i did is:

I enabled hide jailbreak feature to do something with bank app
pressed reboot userspace button
device refreshed then worked normally then I used bank app normally
I disabled hide jailbreak feature ( by pressing unhide jailbreak button )
pressed reboot userspace button
6.device stuck in apple logo boot loop

i tried rebooting my iPhone enter recovery mode and dfu mode and exit
nothing helped me
is there any chance to fix boot loop without losing my iOS version ?
i noticed something : if someone called me the device vibrates and I can hear my ringtone while apple logo still exist

you advice me to wait for any possible solution or to upgrade and lose my iOS version and jailbreak

Your icon cache is probably corrupted, which triggers a stock SpringBoard crash loop. I don't think this is fixable unfortunately, I also cannot see how this happened.
What you could try is using iCloud to reset your device, if that works it'd save the version but loose the data.

what do you mean by using icloud to reset my device

If your device is logged into iCloud there is an option to trigger a remote device wipe when logged in on icloud.com.

about loosing my data , you mean i will loose it permenantly ? or i can restore it from iCloud after fixing the problem

my question is : wiping the device from icloud site will only wipe the local data in the device but will keep the date stored in icloud storage such as ( photos and whatsapp backup) , so i can restore it after the phone works again

i cant even erase my iphone from icloud site

erased successfully after putting Sim card with cellular data internet enabled

it worked and I didn't lose my iOS version.
you are a hero.
thank you very much.

No problem, glad it worked!
I'm currently looking into options of redirecting the problematic file to a different location while jailbroken so the issue can't trigger, unfortunately it causes issues when you install apps while jailbroken where they won't appear when not jailbroken :/. So not yet sure how to solve this.


feat: Add brand colour names & replace darts with point

I tried to preserve contrast & maintain branding.
Not sure if we should delete the unused stuff or keep here for ref for pairs and colouring.
https://github.com/wearedarts/games/pull/10

Should the footer link stay as darts, or change to the point?

Not sure... maybe both? Let's make a point to ask them what they want in the footer - after alpha.

Is this OK to go in?


Changed space indenting to tab indenting for SoftRealTimeLoop

I used vscode to update the indentation. It looks good on my end but can you double check?

Looks good. I think the old one had two spaces for indentation and the rest of the libraries look like they have 4 spaces for indentations. Sorry for misleading you and saying to go tabs. I swapped back to spaces, but 4 of them. I think now you need to review it before I can merge the PR.


Add homepage channels

Will require a new API endpoint: https://github.com/Glimesh/glimesh.tv/issues/719 and then can reuse the existing ChannelList components.

Going to start having a look at this if that's alright now that Glimesh/glimesh.tv#748 is merged

This is working now with #14 -- Going to close this issue, we can make more issues for specific features.


React - Navbar Toggler

Hello,
I'm coding a website using React. I tried to use a Bootstrap navbar, a responsive one. I copied the code from your website, and change class for className, to adapt it to React. This is the code:
import React from 'react'
import { NavLink } from 'react-router-dom'

import '../ui/Navbar.css'

export const Navbar = () => {
    return (

                <button className="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbarNav" aria-controls="navbarNav" aria-expanded="false" aria-label="Toggle navigation">

                </button>

                        Home

                        Link

                        Disabled

    )
}

The navbar is shown, and it collapses, but when I click on the collapsed button, nothing happens.
I tried it on my PC Intel, using Google Chrome Versión 88.0.4324.190 (Build oficial) (64 bits)
Please, could you help me? If you need more info just ask me. Thank you in advance.

Use the following link to help you out - https://react-bootstrap.netlify.app/components/navbar/

Thank you a lot for your help, it was very usefull.


Adapter "cannot find module" as of upgrade to recent version

Describe the bug
I have an error that has cropped up in<EMAIL_ADDRESS>and<EMAIL_ADDRESS>I have a component that uses an OpenLayers map and I get the following from the adapter portion of the build:
Run npm run preview to preview your production build locally.

Using @sveltejs/adapter-node
Error [ERR_MODULE_NOT_FOUND]: Cannot find module '<monorepo_project>/node_modules/ol/Feature' imported from <monorepo_project>/packages/app/.svelte-kit/output/server/entries/pages/search.svelte.js
Did you mean to import ol/Feature.js?
    at new NodeError (node:internal/errors:371:5)
    at finalizeResolution (node:internal/modules/esm/resolve:416:11)
    at moduleResolve (node:internal/modules/esm/resolve:932:10)
    at defaultResolve (node:internal/modules/esm/resolve:1044:11)
    at ESMLoader.resolve (node:internal/modules/esm/loader:422:30)
    at ESMLoader.getModuleJob (node:internal/modules/esm/loader:222:40)
    at ModuleWrap.<anonymous> (node:internal/modules/esm/module_job:76:40)
    at link (node:internal/modules/esm/module_job:75:36)

This worked as of 193/55, I first saw the error in 202/56, and still see it in 215/60. I do not think it is specific to that import, since if I remove it, it just complains about another file from OpenLayers instead. <monorepo_project>/node_modules/ol/Feature.js exists, so I do not know why it is having trouble finding that.
I should note that npm run dev works fine and does not complain about anything
Reproduction
See minimal reproduction at https://github.com/wallw-bits/svelte-kit-ol-issue-repro and npm i followed by npm run build.
Logs
No response
System Info
System:
    OS: Linux 5.11 Ubuntu 20.04.3 LTS (Focal Fossa)
    CPU: (16) x64 Intel(R) Core(TM) i9-9980HK CPU @ 2.40GHz
    Memory: 6.19 GB / 31.11 GB
    Container: Yes
    Shell: 5.0.17 - /bin/bash
  Binaries:
    Node: 16.13.0 - ~/.nvm/versions/node/v16.13.0/bin/node
    Yarn: 1.22.17 - ~/.nvm/versions/node/v16.13.0/bin/yarn
    npm: 7.24.2 - ~/workspace/saffire/ui/node_modules/.bin/npm
  Browsers:
    Chrome: 96.0.4664.110
    Firefox: 95.0.1
  npmPackages:
    @sveltejs/adapter-node: ^1.0.0-next.60 => 1.0.0-next.60
    @sveltejs/kit: ^1.0.0-next.215 => 1.0.0-next.215
    svelte: ^3.44.3 => 3.44.3

Severity
blocking an upgrade
Additional Information
No response

I ran a bisection and it appears that this first shows up with the upgrade to Vite 2.7 in 09e453f1

It looks like I can work around this by doing dynamic imports inside of onMount:

{#if feature}

It worked!

{/if}

That's still really ugly though. Why does the tree shaking not know that the Feature import is unused in SSR?

NODE_OPTIONS='--es-module-specifier-resolution=node' npm run build is a cleaner workaround

This code is invalid:
import Feature from "ol/Feature";

Change it to:
import Feature from "ol/Feature.js";

If you'd like to leave off the extension then the ol package would need to define exports in its package.json

It is curious that the non-spec compliant code worked in an older version of Vite. If you'd like that support to be added back, I'd recommend filing an issue there.

Yup, I understand why that is not valid per the ES spec. However, why doesn't the rest of the tooling have an issue with it?

No idea. The Vite folks might know better

Similar as https://github.com/vitejs/vite/issues/6193. But this is an issue within Openlayers itself, not Vite, as the error is coming from node. Since ol is using type: module, they should use exports to support the ol/Feature syntax, otherwise ol/Feature.js is required. I'm not sure how it used to work pre Vite 2.7 though, perhaps there were changes that surfaced the issue within Openlayers.


Refactor to get rid of className prop on components

For justification, see this article.
This eslint rule can prevent it. I have it disabled atm since I'm using className 🙈

The errors are: (click to expand)
/Users/jmeas/WebDev/moolah/client-src/common/components/landing-page-header/index.js
   9:24  error  Prop `className` is forbidden on Components  react/forbid-component-props
  14:29  error  Prop `className` is forbidden on Components  react/forbid-component-props
  17:28  error  Prop `className` is forbidden on Components  react/forbid-component-props

/Users/jmeas/WebDev/moolah/client-src/common/components/logged-in-header/index.js
  72:26  error  Prop `className` is forbidden on Components  react/forbid-component-props

/Users/jmeas/WebDev/moolah/client-src/common/components/nav/index.js
  52:15  error  Prop `className` is forbidden on Components  react/forbid-component-props
  61:15  error  Prop `className` is forbidden on Components  react/forbid-component-props
  70:15  error  Prop `className` is forbidden on Components  react/forbid-component-props
  79:15  error  Prop `className` is forbidden on Components  react/forbid-component-props

/Users/jmeas/WebDev/moolah/client-src/common/components/profile-dropdown/index.js
  12:13  error  Prop `className` is forbidden on Components  react/forbid-component-props

/Users/jmeas/WebDev/moolah/client-src/transactions/components/date-menu/index.js
  22:13  error  Prop `className` is forbidden on Components  react/forbid-component-props
  32:13  error  Prop `className` is forbidden on Components  react/forbid-component-props

nvm. I prefer allowing classNames + convention to ensure it isn't misused, rather than adding lots of surface area to my components.


Update logical replication security section

Checklist

[ ] Added an entry in CHANGES.txt for user facing changes
[ ] Updated documentation & sql_features table for user facing changes
[ ] Touched code is covered by tests
[ ] CLA is signed
[ ] This does not contain breaking changes, or if it does:

It is released within a major release
It is recorded in CHANGES.txt
It was marked as deprecated in an earlier release if possible
You've thought about the consequences and other components are adapted
(E.g. AdminUI)

While on this, could you also please fix the name of the referenced setting in the section? https://github.com/crate/crate/blob/master/docs/admin/logical-replication.rst?plain=1#L63
It currently is named setting while the referenced setting should be rendered.
Thanks!

noticed not related to docs (but related to LR) failure https://jenkins.crate.io/job/CrateDB/job/crate_on_pr/616/testReport/junit/io.crate.integrationtests/MetadataTrackerITest/test_deleted_partition_is_replicated/

fyi: references must not have a label if the original name is fine. labels inside references are useful to give the link a different name. Sorry, but can you also make replication.logical.reads_poll_duration a reference by :ref:replication.logical.reads_poll_duration?

thx for the trick, removed names in SEE ALSO section as well in https://github.com/crate/crate/pull/12265/commits/a4daa56316a50ffc8cf1b235459142067ab02649

some reference seem to be wrong a sphinx is failing...

some reference seem to be wrong a sphinx is failing...

yep, cannot figure it out - for example, file contains 2
:ref:`replication.logical.reads_poll_duration`

entries, one is rendered properly and one is not. Seems like has something to do with one link being inside SEE ALSO - trying currently different fixes

@BaurzhanSakhariev seems like labels containing dots cannot be referenced without a name, so
:ref:`replication.logical.reads_poll_duration`

fails while:
:ref:`replication.logical.reads_poll_duration<replication.logical.reads_poll_duration>
succeeds.
Either use this, or change the label, eg. replace dots with _

retest this please


[Feature]: adopt cnpg.io/instanceRole in service selector

Is there an existing issue already for this feature request/idea?

[X] I have searched for an existing issue, and could not find anything. I believe this is a new feature request to be evaluated.

What problem is this feature going to solve? Why should it be added?
We still use the deprecated role label in the service selector. Given that we are adding managed services, we should use this opportunity to switch entirely the new service selectors to the cnpg.io/instanceRole label.
Describe the solution you'd like
Replace role with cnpg.io/instanceRole in the service selector. Given that pods will still have both labels, the change will not break any existing cluster.
Describe alternatives you've considered
N/A
Additional context
No response
Backport?
No
Are you willing to actively contribute to this feature?
Yes
Code of Conduct

[X] I agree to follow this project's Code of Conduct

Duplicates #3943


This typo is not a problem on the master branch because it was fixed in #800.

Closing this PR as I accidentally opened it against master branch instead of against 2.1_branch.


Demo url not working

Hi I was interested in seeing this in action quickly but the demo wasn't working.

Thanks.  Corrected.  May take a few hours for DNS to propagate.


notebook2script fails on notebooks saved by VS Code native editor

Since the recent VS Code update I've started using the native notebook editor with VS Code keybindings etc. It's great, but apparently changes the notebook saved format a bit (I noticed that metadata for the notebook is now saved at the end).
This appears to confuse nbdev notebook2script - it still runs without errors, but the created python files are mostly empty, skipping most or all #export cells. (notebook2script worked fine before with the old jupyter notebook editor on the same notebooks).
This is with fastai 2.4 and nbdev 1.1.14. NB The instructions in the contributing guidelines for show_install don't work anymore.

I am having the same issue. The worst part is if one installs the new Pylance release on VSCode, it updates the notebook editor and breaks the script.
As far as I can tell, the new native editor changes the cell data of notebooks.
I noticed that the cell structure used to be:
"cells": [
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": [
"# default_exp rpl_summarise"
]
},
But after editing the cell with VSCode's new notebook editor, it is:
{
"cell_type": "code",
"execution_count": 1,
"source": [
"# default_exp rpl_summarise"
],
"outputs": [],
"metadata": {}
},
Note that "outputs" and "metadata" are now after "source", not before.  ALso, their order is now inverted.
I re-runned the script after manually reorganising the elements, and it seems to correct the problem in the case of the file's first, cell. But the same solution did not work with a cell in the middle of the document, past other cells that have been edited.

Here is a nbdev project that I created using VSCode. As anyone can see, it does not build the core module.
This might help reproduce the problem. I looked at the 00_export.ipynb of nbdev as hard as I could, but I couldn't hack it.
I have the filling that something in the new notebook structure may be braking the regex generated by _mk_flag_re but I am not sure.
vsc_test.zip

Should be fixed in v2


Nested content support

Hey Matt
Right now you can wrap a Nested Content with a Vorto, but you can't use Vorto inside a Nested Content, so this basically allows to do that.
Cheers,
Cristhian.

Oops, meant to do this in develop.


Linked Data(sette)

I've a radical feature idea (possible first as an extension in order to experiment?):
I'd like to link to a remote table from a remote database, e.g. with a function "linked_datasette()". So one could do following query:
SELECT foo.id, foo.a, remote_party.b
FROM foo
JOIN linked_datasette("https://parlgov.datasettes.com/parlgov-b42a2f2") AS remote_party
  ON foo.id=remote_party.id

This is inspired by SPARQL's SERVICE keyword for remote RDF "endpoints".
There's a foundation in the SQL Standard called SQL/MED (https://rhaas.blogspot.com/2011/01/why-sqlmed-is-cool.html ).
And here's an implementation from me in Postgres FDW to connect another Postgres "endpoint": https://pastebin.com/Fz2v64Cz .

I've been thinking about how Datasette instances could query each other for a while - it's a really interesting direction.
There are some tricky problems to solve to get this to work. There's a SQLite mechanism called "virtual table functions" which can implement things like this, but it's not supported by Python's sqlite3 module out of the box.
https://github.com/coleifer/sqlite-vtfunc is a library that enables this feature. I experimented with using that to implement a function that scrapes HTML content (with an eye to accessing data from other APIs and Datasette instances) a while ago: https://github.com/coleifer/sqlite-vtfunc/issues/6
The bigger challenge is how to get this kind of thing to behave well within a Python 3 async environment. I have some ideas here but they're going to require some very crafty engineering.

Does this also relate to https://github.com/simonw/datasette/issues/283 and the ability to ATTACH DATABASE?


Update netlink to self-maintained latest version

it would be nice to get rid of the package replacement for netlink. But before the maintainers of netlink respond to the new request to merge the change, it would be necessary to keep the self-maintained netlink lib up-to-date.

Thanks @byteocean . Looks like the new version doesnt contain the commit which changes the go version in go.mod. (commit id: 1ca7c35)
When you are at it, the go version can be bumped to 1.21 in this self maintained repo as well.
The functionality we use in this netlink library somehow (re-)tested after being rebase to its main branch ? I see that you have a test case in the self maintained repo exercising this part, I assume that it was run successfully ?

This corresponding change has been merged to the upstream netlink, but a new release still needs to be published by them. We can finally get rid of the package replacement statement.

Great news !!


CODE_OF_CONDUCT

I would like to add code of conduct file . Please assign this to me

Please be as specific as possible. What would you like to add ?

Guidelines to be followed , Scope of the program , pledge ,  warning , standards with detailed description

@swathi-469 If you could improvise the current state of the guidelines with much more detailed descriptions and adding images and stuff wherever necessary please go for it.
One project can never run out of good documentation! But please make sure you are not changing too many files in one PR. As it gets hard to review. Work on one file at a time, and make separate issues if you want to contribute to multiple files.

Yeah sure

I have made my pull request please look over it


Add Random Alphanumeric String generation

Add the ability to generate a random String that contains alphanumeric characters. Users can also specify how many characters should be in the String.

Could you modify the README.md?
Also I think it'd be nice if there were both String.random(5) and String.randomUnicode(10) which would include weird characters like ę, ç, æ, :1st_place_medal: (emojis) etc.


Dropped PyQt because of its license restrictions.

Fixes #373

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


Allow exact versions with 3 or 4 digits

Fixes #2

Coverage remained the same at 100.0% when pulling<PHONE_NUMBER>272a03f77e8d58a5b003bfd3df24d4 on 2-fix-version-restricted-3-digits into 98662f88cb9e1e5704dba843d24b946f9fa32add on master.


sdf-facto models not learning well, while nerf-facto does

I am trying to train a model on a camera sequence around the head of the person.
In short, it seems to work well for NeRF methods (e.g nerfacto), screenshots attached. This makes me confident to rule out coordinate system issues.
When I run neuSfacto, while the losses are going down (screenshot attached) the RGB images look ok, but when looking at normals/depths, the learned shape is very flat.
neus facto graphs:
tensorboard:

rgb:

depth:

normals:

cameras:

nerf facto graphs:
depth:

normals:

rgb:

Appreciate any suggestions...Thanks!

Hi thanks for your quick response!
Yeh, I followed this post, and tried both centering cameras and the object to be at the origin. I.e, one- such that the cameras mean poses will be at the origin and two- the object is at the origin.
None of them worked

Could you also try MLP without hash grid features --pipeline.model.sdf-field.use-grid-feature False?

Hi,
Thanks again!
I just now tried (use_grid_feature=False). No real difference:
rgb:

depth:

normal:

Hi, Can you share your full command to train the model?

Hi,
Actually, I'm not using the CLI directly but rather just running it from python.
It should be similar to:
ns-train neus-facto --pipeline.model.sdf-field.inside-outside False --vis viewer

Hi, that's strange. Could you maybe check how the near and far plane are set for your dataset?

Sorry didn't saw your message.
collider_type = 'box' (at SceneBox) which then set the collider at the base_surface_model as follows:
self.collider = AABBBoxCollider(
self.scene_box, near_plane=self.scene_box.near
)
where near is 0.1 and far is 6


Insteon local update

Description:
Update to the Insteon Local Component to fix some bugs and improve the component.
I've redone it so the main component will do discovery (get linked) and then pass the list of devices to the three platforms (switch, light (dimmer), fan). There is no longer any config other than the hub config.
It won't ask for names or use the configurator since the core team told us to stop that. Should be able to set friendly names later in the interface or via https://home-assistant.io/docs/configuration/customizing-devices/
With this update the names of the insteon devices will change to the insteon address of the device.
Related issue (if applicable): fixes #7373 #6842
Pull request in home-assistant.github.io with documentation (if applicable): home-assistant/home-assistant.github.io#4198
Example entry for configuration.yaml (if applicable):

Checklist:
If user exposed functionality or configuration variables are added/changed:

[x] Documentation added/updated in home-assistant.github.io

If the code communicates with devices, web services, or third-party tools:

[x] Local tests with tox run successfully. Your PR cannot be merged unless tests pass
[ ] New dependencies have been added to the REQUIREMENTS variable (example).
[ ] New dependencies are only imported inside functions that use them (example).
[ ] New dependencies have been added to requirements_all.txt by running script/gen_requirements_all.py.
[ ] New files were added to .coveragerc.

If the code does not interact with devices:

[ ] Local tests with tox run successfully. Your PR cannot be merged unless tests pass
[ ] Tests have been added to verify that the new code works.

This is an update/ clean up of #10137 @armills requested. I will request a PR on the hass.io side here in a few.

@wardcraigj With this version I am having an issue where it is not actually adding any devices. Can you help look through the code and see if you see any issues?

@armills this is now functioning and looks to have passed all tests.


Is there a way to feed a BSON file directly into Keras?

https://stackoverflow.com/questions/46311506/feed-bson-files-directly-into-keras-python

Hi
If you think this is a feature request/enhancement, please open the issue with clear information on what is expected or required.
To ask questions, please see the following resources :
https://keras.io/
https://keras.io/#support
https://gitter.im/Keras-io/Lobby
Thanks!


Update 1910-release-notes.md

Change deprecated to removed

@ameltzerMSFT : Thanks for your contribution! The author(s) have been notified to review your proposed change.

Closing, will publish the change via MicrosoftDocs/sccm-docs-powershell#223


OpenCV Error: Bad argument (Can not get new positive sample. The most possible reason is insufficient count of samples in given vec-file.

hello, I begin to train the model. In your example, you use -numPos 68 -numNeg 140, so I use 25 for the number of pos and 55 for the number of neg. But it shows error:
---------------------------------------------------------------------------------
Training parameters are pre-loaded from the parameter file in data folder!
Please empty this folder if you want to use a NEW set of training parameters.
---------------------------------------------------------------------------------
PARAMETERS:
cascadeDirName: /home/ysju/cascade-trainer-master/classifier
vecFileName: /home/ysju/cascade-trainer-master/vec.bin
bgFileName: /home/ysju/cascade-trainer-master/negatives.txt
numPos: 25
numNeg: 55
numStages: 5
precalcValBufSize[Mb] : 1024
precalcIdxBufSize[Mb] : 1024
acceptanceRatioBreakValue : -1
stageType: BOOST
featureType: HAAR
sampleWidth: 24
sampleHeight: 24
boostType: GAB
minHitRate: 0.995
maxFalseAlarmRate: 0.5
weightTrimRate: 0.95
maxDepth: 1
maxWeakCount: 100
mode: BASIC
Number of unique features given windowSize [24,24] : 162336

Stages 0-3 are loaded

===== TRAINING 4-stage =====
<BEGIN
OpenCV Error: Bad argument (Can not get new positive sample. The most possible reason is insufficient count of samples in given vec-file.
) in get, file /home/ysju/opencv-3.2.0/apps/traincascade/imagestorage.cpp, line 158
terminate called after throwing an instance of 'cv::Exception'
  what():  /home/ysju/opencv-3.2.0/apps/traincascade/imagestorage.cpp:158: error: (-5) Can not get new positive sample. The most possible reason is insufficient count of samples in given vec-file.
 in function get

Aborted (core dumped)4

I google this error and find the common solution is about reducing  the number of positive sample like link1  and link2 said. So now I am confused about the configuration of numPos and numNeg. how to solve my this error? can you give some advises?
look forward to your reply.
thank you very much~~

Hi IvyGongoogle, did you ever solve this training classifier problem? I am having the same error thrown. Thanks

I am getting very similar error but quite weird. I am passing argument as 110 but still it takes numPos value as 2000.
`mayank@mayank-Aspire-A515-51G:~/programs/opencv/CSS/homework/HAAR_classifier/dataset$ opencv_traincascade -data data -vec positives.vec -bg neg.txt numPos 110 -numNeg 3000 -numStages 10 -w 40 -h 40 -featureType LBP
PARAMETERS:
cascadeDirName: data
vecFileName: positives.vec
bgFileName: neg.txt
numPos: 2000
numNeg: 3000
numStages: 10
precalcValBufSize[Mb] : 1024
precalcIdxBufSize[Mb] : 1024
acceptanceRatioBreakValue : -1
stageType: BOOST
featureType: LBP
sampleWidth: 40
sampleHeight: 40
boostType: GAB
minHitRate: 0.995
maxFalseAlarmRate: 0.5
weightTrimRate: 0.95
maxDepth: 1
maxWeakCount: 100
Number of unique features given windowSize [40,40] : 67600
===== TRAINING 0-stage =====
<BEGIN
POSOpenCV(3.4.1) Error: Bad argument (Can not get new positive sample. The most possible reason is insufficient count of samples in given vec-file.
) in get, file /home/mayank/programs/opencv/opencv-3.4.1/apps/traincascade/imagestorage.cpp, line 158
terminate called after throwing an instance of 'cv::Exception'
what():  OpenCV(3.4.1) /home/mayank/programs/opencv/opencv-3.4.1/apps/traincascade/imagestorage.cpp:158: error: (-5) Can not get new positive sample. The most possible reason is insufficient count of samples in given vec-file.
in function get
Aborted (core dumped)
`

@ChrisTayl2018 have u solved the error and could you help me.

i got same error did u solve it or not?

I got the same error pls help

To fix this, you need to increase the number of samples in the vec file, the num parameter is responsible for this.
opencv_createsamples -info positive/info.txt -vec vector/vector.vec -num 100000 -w 24 -h 24

To fix this, you need to increase the number of samples in the vec file, the num parameter is responsible for this.
opencv_createsamples -info positive/info.txt -vec vector/vector.vec -num 100000 -w 24 -h 24

This worked for me. Thank you

To fix this, you need to increase the number of samples in the vec file, the num parameter is responsible for this.
opencv_createsamples -info positive/info.txt -vec vector/vector.vec -num 100000 -w 24 -h 24

This worked for me. Thank you

ME PUEDES DECIR COMO LO HICISTE?


New PR to test SignCLA at 2019-07-16 11:32:26.644997752 -0700 PDT m=+12.398986221

Body of PR

corp-pass-staging: test succeeded


install-complete.txt similarities in db

I have dbpop populating data in k8s environment. However, if the instance is upgraded dbpop runs again.  it would be nice if dbpop stored metadata inside the db.  I could then check if the schema exists to know whether dbpop has already ran.
I run the process as:
init schema
start dbpop
run flyway <-- this is here to support more than just the dbpop environment.
For now I can accomplish this with a flyway script, however, a universal solution would be something maintained inside dbpop.
Thanks,

my current workaround:
            /opt/mssql-tools18/bin/sqlcmd \
              -C -b -S "$MSSQL_SERVER" -U "$TARGET_USERNAME" -P "$TARGET_PASSWORD" \
              -Q "CREATE SCHEMA [DbPop];"

            result=$?
            if [ $result -ne 0 ] ; then
              echo "do not rerun dbpop";
              exit 0;
            fi

If DbPop does not run, how does the developer reset the data?

this needs to run as part of headless non user interactive also.
In headless non interactive environment how do I know dbpop failed ?  most apps would exit 1 or similar.
Example:

right now the only hook i know of is watching: /var/opt/dbpop/setup/install-complete.txt
what about errors?

After startup, DbPop starts a background task to load the base dataset.
It does that so the developer has a populated database to work with, without having to load the dataset from the DbPop UI.
What you call an headless environment is most likely a build environment for automated tests. In that case it would make sense to not load a dataset at all since every automated test would start by reloading the data.
To disable that behavior, define an environment variable: dbpopd.startup.loadDatasets=false.
If you want to test if a specific dataset can be loaded, you can use the API. See http://localhost:7104/swagger-ui/#/populate/populate.
DbPop becomes functional only when it can connect to the database, and SQL Server may take a while to startup, especially when the container starts for the first time.
You can check of DbPop is connected to the database using the API. See http://localhost:7104/swagger-ui/#/default/site.


Make sure the user is signed out of the Google API when they signed out from the website

As of right now, the user will stay signed in the Google API even though they signed out from the website. This makes it so that when you log out from a Gmail account and connect with a normal email account, you're still connected to the Google API and can still export to your calendar. This is unintended.

This was a duplicate issue to #125 . Therefore this was removed.


Run tests on push to any branch

Hello.
I've made few improvements of testing workflow, each of them is described in the comments below.

Thanks!


JWT error using example from the home page

Reading this and implementing the examples from that page...
https://bitzart.github.io/Blazor.Auth/01.introduction.html
I am trying to use this excellent system, and have coded up your example server side service for authentication using your example. However, when signing in I get an error message in the browser. I am zero experienced on this, I have no experience in Authorization ... this is all new to me as is Blazor as is NET. I am using NET 8 with Blazor and Radzen in a Web App  from the 'new project' template in Visual Studio. All I want to do really is authenticate against a list of users I have in a database, i was going to add that bit in the service, but I have'nt got that far !
SecurityTokenMalformedException: IDX12709: CanReadToken() returned false. JWT is not well formed. The token needs to be in JWS or JWE Compact Serialization Format. (JWS): 'EncodedHeader.EncodedPayload.EncodedSignature'. (JWE): 'EncodedProtectedHeader.EncodedEncryptedKey.EncodedInitializationVector.EncodedCiphertext.EncodedAuthenticationTag'.
followed by
System.IdentityModel.Tokens.Jwt.JwtSecurityTokenHandler.ReadJwtToken(string token) BitzArt.Blazor.Auth.IdentityClaimsService.BuildClaimsPrincipal(string accessToken) BitzArt.Blazor.Auth.BlazorAuthenticationStateProvider.GetAuthenticationStateAsync() Microsoft.AspNetCore.Components.Authorization.AuthorizeViewCore.OnParametersSetAsync() Microsoft.AspNetCore.Components.ComponentBase.CallStateHasChangedOnAsyncCompletion(Task task) Microsoft.AspNetCore.Components.ComponentBase.RunInitAndSetParametersAsync() Microsoft.AspNetCore.Components.RenderTree.Renderer.HandleExceptionViaErrorBoundary(Exception error, ComponentState errorSourceOrNull) Microsoft.AspNetCore.Components.RenderTree.Renderer.AddToPendingTasksWithErrorHandling(Task task, ComponentState owningComponentState) Microsoft.AspNetCore.Components.Rendering.ComponentState.SupplyCombinedParameters(ParameterView directAndCascadingParameters) Microsoft.AspNetCore.Components.Rendering.ComponentState.SetDirectParameters(ParameterView parameters) Microsoft.AspNetCore.Components.RenderTree.RenderTreeDiffBuilder.InitializeNewComponentFrame(ref DiffContext diffContext, int frameIndex) Microsoft.AspNetCore.Components.RenderTree.RenderTreeDiffBuilder.InitializeNewSubtree(ref DiffContext diffContext, int frameIndex) Microsoft.AspNetCore.Components.RenderTree.RenderTreeDiffBuilder.InsertNewFrame(ref DiffContext diffContext, int newFrameIndex) Microsoft.AspNetCore.Components.RenderTree.RenderTreeDiffBuilder.AppendDiffEntriesForRange(ref DiffContext diffContext, int oldStartIndex, int oldEndIndexExcl, int newStartIndex, int newEndIndexExcl) Microsoft.AspNetCore.Components.RenderTree.RenderTreeDiffBuilder.ComputeDiff(Renderer renderer, RenderBatchBuilder batchBuilder, int componentId, ArrayRange<RenderTreeFrame> oldTree, ArrayRange<RenderTreeFrame> newTree) Microsoft.AspNetCore.Components.Rendering.ComponentState.RenderIntoBatch(RenderBatchBuilder batchBuilder, RenderFragment renderFragment, out Exception renderFragmentException) Microsoft.AspNetCore.Components.RenderTree.Renderer.RenderInExistingBatch(RenderQueueEntry renderQueueEntry) Microsoft.AspNetCore.Components.RenderTree.Renderer.ProcessRenderQueue() Microsoft.AspNetCore.Components.RenderTree.Renderer.ProcessRenderQueue() Microsoft.AspNetCore.Components.RenderTree.Renderer.ProcessPendingRender() Microsoft.AspNetCore.Components.RenderTree.Renderer.AddToRenderQueue(int componentId, RenderFragment renderFragment) Microsoft.AspNetCore.Components.RenderHandle.Render(RenderFragment renderFragment) Microsoft.AspNetCore.Components.ComponentBase.StateHasChanged() Microsoft.AspNetCore.Components.ComponentBase.CallOnParametersSetAsync() Microsoft.AspNetCore.Components.ComponentBase.RunInitAndSetParametersAsync() Microsoft.AspNetCore.Components.RenderTree.Renderer.HandleExceptionViaErrorBoundary(Exception error, ComponentState errorSourceOrNull) Microsoft.AspNetCore.Components.RenderTree.Renderer.AddToPendingTasksWithErrorHandling(Task task, ComponentState owningComponentState) Microsoft.AspNetCore.Components.Rendering.ComponentState.SupplyCombinedParameters(ParameterView directAndCascadingParameters) Microsoft.AspNetCore.Components.Rendering.ComponentState.SetDirectParameters(ParameterView parameters) Microsoft.AspNetCore.Components.RenderTree.Renderer.RenderRootComponentAsync(int componentId, ParameterView initialParameters) Microsoft.AspNetCore.Components.HtmlRendering.Infrastructure.StaticHtmlRenderer.BeginRenderingComponent(IComponent component, ParameterView initialParameters) Microsoft.AspNetCore.Components.Endpoints.EndpointHtmlRenderer.RenderEndpointComponent(HttpContext httpContext, Type rootComponentType, ParameterView parameters, bool waitForQuiescence) System.Threading.Tasks.ValueTask<TResult>.get_Result() Microsoft.AspNetCore.Components.Endpoints.RazorComponentEndpointInvoker.RenderComponentCore(HttpContext context) Microsoft.AspNetCore.Components.Endpoints.RazorComponentEndpointInvoker.RenderComponentCore(HttpContext context) Microsoft.AspNetCore.Components.Rendering.RendererSynchronizationContext+<>c+<<InvokeAsync>b__10_0>d.MoveNext() Microsoft.AspNetCore.Authorization.AuthorizationMiddleware.Invoke(HttpContext context) Microsoft.AspNetCore.Authentication.AuthenticationMiddleware.Invoke(HttpContext context) Microsoft.AspNetCore.Diagnostics.DeveloperExceptionPageMiddlewareImpl.Invoke(HttpContext context)
Server side service (same as your example)
using BitzArt.Blazor.Auth;
using Licensing.Auth.Data;

namespace Licensing.Auth.Services
{
    // Example Authentication Service
    public class AuthenticationService
        : ServerSideAuthenticationService<SignInPayload, SignUpPayload>
    {
        protected override Task<AuthenticationResult> GetSignInResultAsync(SignInPayload signInPayload)
        {
            var jwtPair = CreateSampleJwtPair(); // Replace this with your actual authentication logic

            var authResult = AuthenticationResult.Success(jwtPair);

            return Task.FromResult(authResult);
        }

        protected override Task<AuthenticationResult> GetSignUpResultAsync(SignUpPayload signUpPayload)
        {
            var jwtPair = CreateSampleJwtPair(); // Replace this with your actual authentication logic

            var authResult = AuthenticationResult.Success(jwtPair);

            return Task.FromResult(authResult);
        }

        public override Task<AuthenticationResult> RefreshJwtPairAsync(string refreshToken)
        {
            var jwtPair = CreateSampleJwtPair(); // Replace this with your actual authentication logic

            var authResult = AuthenticationResult.Success(jwtPair);

            return Task.FromResult(authResult);
        }

        private JwtPair CreateSampleJwtPair()
        {
            return new JwtPair
            {
                AccessToken = "my-access-token",
                RefreshToken = "my-refresh-token"
            };
        }
    }

}

Payload:
namespace Licensing.Auth.Data
{
    // Example Sign-In payload
    public class SignInPayload
    {
        public string Email { get; set; }
        public string Password { get; set; }
    }
}

And the login ... here OnLogin is getting called from a login form, which then calls SignInAsync
namespace Licensing.Auth.Pages;

using Licensing.Auth.Data;
using Microsoft.AspNetCore.Components;
using Licensing.Auth.Services;
using BitzArt.Blazor.Auth;
using Radzen;

public partial class AuthLogin
{
    [Inject] NavigationManager NavigationManager { get; set; } = null!;
    [Inject] IUserService UserService { get; set; } = null!;

    public string userName = "admin";
    public string password = "admin";
    public bool rememberMe = true;

    async void OnLogin(LoginArgs args, string name)
    {
        Console.WriteLine($"{name} -> Username: {args.Username}, password: {args.Password}, remember me: {args.RememberMe}");
        await SignInAsync();
    }

    void OnRegister(string name)
    {
        Console.WriteLine($"{name} -> Register");
    }

    void OnResetPassword(string value, string name)
    {
        Console.WriteLine($"{name} -> ResetPassword for user: {value}");
    }

    private async Task SignInAsync()
    {
        var payload = new SignInPayload();
        var authenticationResult = await UserService.SignInAsync(payload);
        NavigationManager.NavigateTo("/", true);
    }

    private async Task SignOutAsync()
    {
        await UserService.SignOutAsync();
        NavigationManager.NavigateTo("/", true);
    }
}

Hello @DrHoneyBear
That sample code is there purely for demonstration purposes, and not exactly supposed to be a real working solution. It is expected that you would replace the JWT pair in that sample with your actual JWTs.
Blazor.Auth is trying to read the access token as if it was an actual JWT but it is just a sample string there. So that's why you are getting this exception about it not being able to parse that access token.
If you are looking for an actual working sample application, you can find one here.
Let me know if this helps 🙏

Ahhh. I see.
Ok from ..
https://github.com/BitzArt/Blazor.Auth/blob/main/sample/BitzArt.Blazor.Auth.SampleApp/BitzArt.Blazor.Auth.SampleApp
... I took your server side service, your jwt service, updated Program.cs to register them, and re-built. VOILA. Runs and "authenticates". But that is without any db access. Clearly I need to add some db work to read username and password from the payload ... but what is this 'authentication' ... does it have authorisation and roles? if not how might I add this please.
THANK YOU for getting me working.

@DrHoneyBear
Take a look at the sample JWT service in the server side of the app. It builds example JWTs but you now need to build an actual JWT for the user and populate it with the user's claims.
You can put any information you deem necessary into the claims, and you will then be able to see that same information when the user uses those JWTs to access your app. Think UserId, Email, Name, Roles, etc.
The information you encode into a JWT will be accessible by injecting the AuthenticationStateProvider anywhere in the Blazor app and then calling it's GetAuthenticationStateAsync method. The resulting object will contain the user's claims.
As for the Authorization side of things, Blazor.Auth integrates with what is provided by the Blazor's framework for this. So you can refer to the Blazor's documentation on the topic.

Sorry, please can you help a little more. Example...pointer...files you refer to. I am only 3 months into learning Visual Studio , NET Core, SDK, Blazor, Radzen and web app development. We all had to learn somewhere and ask questions. Just a bit more help please. It's 17:10 GMT so going home now and will pick this up ( hopefully :) ) tomorrow 08:00. Thank you for sticking with me.

Sure no worries 👌

p.s. Where is AuthenticationStateProvider ?? this isnt compling...
[Inject] AuthenticationStateProvider myASP{  get; set; }

EDIT. Did you mean BlazorAuthenticationStateProvider.cs , the one in your source tree ?

We can continue with this conversation on our Discord server

Hi. it's fine. I figured it out from reading that link to Microsoft. Didn't
know it was integrated so I can use Blazor / ASP attributes and
directives.. all good now. give thanks to you the main man
On Thu, 7 Nov 2024, 18:20 Yuriy Durov, @.***> wrote:

We can continue with this conversation on our Discord server
https://discord.gg/G2BHM8jP
—
Reply to this email directly, view it on GitHub
https://github.com/BitzArt/Blazor.Auth/issues/25#issuecomment-2462931378,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AO5LT6MUYBJME2JZUED52I3Z7OVORAVCNFSM6AAAAABRLNUXRCVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDINRSHEZTCMZXHA
.
You are receiving this because you were mentioned.Message ID:
@.***>

Hi.
I do but want to use Discord because it wants me to verify by my phone
number. I do but share my phone number at all.
May I ask you please one more...
How can I use your library to use ROLES not Claims. So that I can use for
example...

User: @context.User
You have the 'Admin' role claim.

User: @innerContext.User
You have both 'Admin' and 'Superuser' role claims.

I only see how Claim is set in your sharing project.
regards
Dr.
On Thu, 7 Nov 2024, 18:20 Yuriy Durov, @.***> wrote:

We can continue with this conversation on our Discord server
https://discord.gg/G2BHM8jP
—
Reply to this email directly, view it on GitHub
https://github.com/BitzArt/Blazor.Auth/issues/25#issuecomment-2462931378,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AO5LT6MUYBJME2JZUED52I3Z7OVORAVCNFSM6AAAAABRLNUXRCVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDINRSHEZTCMZXHA
.
You are receiving this because you were mentioned.Message ID:
@.***>

@DrHoneyBear
Hey there!
Yep, I just checked and this seems to work:
var accessToken = _tokenHandler.WriteToken(new JwtSecurityToken(
    claims:
    [
        new Claim(ClaimTypes.Role, "Admin")
    ],
    notBefore: now,
    expires: accessTokenExpiresAt,
    signingCredentials: _signingCredentials
));

And then
<AuthorizeView Roles="Admin">

You are an admin.

</AuthorizeView>


I'm creating a plugin to export a spreadsheet file (.ods or .xlsx)

Hi,
I have started developing a plugin to export records as a spreadsheet file. It could be ods or xlsx, whatever is easier.
I have spotted the following packages:

ods files: https://pypi.org/project/odswriter/
xlsx files: https://openpyxl.readthedocs.io/en/stable/index.html (quite powerful) or https://xlsxwriter.readthedocs.io/ (faster)

This is the code I have so far, I test it with the --plugins-dir option:
from datasette import hookimpl
from datasette.utils.asgi import Response
import odswriter as ods

def render_spreadsheet(rows):
    with ods.writer(open("test.ods","wb")) as odsfile:
        for row in rows:
            odsfile.writerow(["String", "ABCDEF123456", "123456"])
        return Response(odsfile, content_type="application/vnd.oasis.opendocument.spreadsheet", status=200)

@hookimpl
def register_output_renderer():
    return {"extension": "ods", "render": render_spreadsheet}

I get the following error:
Traceback (most recent call last):
  File "/home/colin/.local/lib/python3.8/site-packages/datasette/app.py", line 1128, in route_path
    await response.asgi_send(send)
  File "/home/colin/.local/lib/python3.8/site-packages/datasette/utils/asgi.py", line 339, in asgi_send
    body = body.encode("utf-8")
AttributeError: 'ODSWriter' object has no attribute 'encode'
ERROR:    Exception in ASGI application
Traceback (most recent call last):
  File "/home/colin/.local/lib/python3.8/site-packages/datasette/app.py", line 1128, in route_path
    await response.asgi_send(send)
  File "/home/colin/.local/lib/python3.8/site-packages/datasette/utils/asgi.py", line 339, in asgi_send
    body = body.encode("utf-8")
AttributeError: 'ODSWriter' object has no attribute 'encode'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/home/colin/.local/lib/python3.8/site-packages/uvicorn/protocols/http/h11_impl.py", line 396, in run_asgi
    result = await app(self.scope, self.receive, self.send)
  File "/home/colin/.local/lib/python3.8/site-packages/uvicorn/middleware/proxy_headers.py", line 45, in __call__
    return await self.app(scope, receive, send)
  File "/home/colin/.local/lib/python3.8/site-packages/datasette/utils/asgi.py", line 161, in __call__
    await self.app(scope, receive, send)
  File "/home/colin/.local/lib/python3.8/site-packages/datasette/tracer.py", line 75, in __call__
    await self.app(scope, receive, send)
  File "/home/colin/.local/lib/python3.8/site-packages/asgi_csrf.py", line 107, in app_wrapped_with_csrf
    await app(scope, receive, wrapped_send)
  File "/home/colin/.local/lib/python3.8/site-packages/datasette/app.py", line 1086, in __call__
    return await self.route_path(scope, receive, send, path)
  File "/home/colin/.local/lib/python3.8/site-packages/datasette/app.py", line 1133, in route_path
    return await self.handle_500(request, send, exception)
  File "/home/colin/.local/lib/python3.8/site-packages/datasette/app.py", line 1267, in handle_500
    await asgi_send_html(
  File "/home/colin/.local/lib/python3.8/site-packages/datasette/utils/asgi.py", line 217, in asgi_send_html
    await asgi_send(
  File "/home/colin/.local/lib/python3.8/site-packages/datasette/utils/asgi.py", line 237, in asgi_send
    await asgi_start(send, status, headers, content_type)
  File "/home/colin/.local/lib/python3.8/site-packages/datasette/utils/asgi.py", line 246, in asgi_start
    await send(
  File "/home/colin/.local/lib/python3.8/site-packages/asgi_csrf.py", line 103, in wrapped_send
    await send(event)
  File "/home/colin/.local/lib/python3.8/site-packages/uvicorn/protocols/http/h11_impl.py", line 482, in send
    raise RuntimeError(msg % message_type)
RuntimeError: Expected ASGI message 'http.response.body', but got 'http.response.start'.

I tried with AsgiFileDownload like in DatabaseDownload to deal with the binary nature of the ods file, but the renderer expects a Response:

<datasette.utils.asgi.AsgiFileDownload object at 0x7f5b9bd503d0> should be dict or Response

However, the Response class only supports the following methods, not binary:

html
text
json
redirect

How would you suggest me to proceed to have my ods file downloaded?

Apparently, beside a string, Reponse could also work with bytes.

I made it work with openpyxl:
from datasette import hookimpl
from datasette.utils.asgi import Response
from openpyxl import Workbook
from openpyxl.writer.excel import save_virtual_workbook
from openpyxl.cell import WriteOnlyCell
from openpyxl.styles import Alignment, Font, PatternFill

def render_spreadsheet(rows):
    wb = Workbook(write_only=True)
    ws = wb.create_sheet()
    ws = wb.active
    ws.title = "decp"

    columns = rows[0].keys()
    headers = []
    for col in columns :
        c = WriteOnlyCell(ws, col)
        c.fill = PatternFill("solid", fgColor="DDEFFF")
        headers.append(c)
    ws.append(headers)

    for row in rows:
        wsRow = []
        for col in columns:
            c = WriteOnlyCell(ws, row[col])
            if col == "objet" :
                c.alignment = Alignment(wrapText = True)
            wsRow.append(c)
        ws.append(wsRow)
    return Response(
        save_virtual_workbook(wb),
        headers={
            'Content-Disposition': 'attachment; filename=decp.xlsx',
            'Content-type': 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet'
        }
    )

@hookimpl
def register_output_renderer():
    return {"extension": "xlsx",
    "render": render_spreadsheet,
    "can_render": lambda: False}

The key part was to find the right function to wrap the spreadsheet object wb. save_virtual_workbook() did it!


bindvar for MSSQL

MSSQL bind vars doesn't seem to work properly without a workaround (will describe further down).  The writeup at https://jmoiron.github.io/sqlx/ says

Named query support is implemented by parsing the query for the :param syntax and replacing it with the bindvar supported by the underlying database, then performing the mapping at execution, so it is usable on any database that sqlx supports

I tried Query, NamedQuery, and looks like ? is generated instead of @ for MSSQL, since the error is:
err=mssql: Incorrect syntax near '?'.
I also tried the example with sqlx.Named (since it's "named" the same as sql's Named) but that says it specifically uses the ? bind variable, and yes, it also threw the same incorrect syntax near '?' error.
[edit]
I also tried db.Rebind, but again, same problem:

	db, err := sqlx.Open(azuread.DriverName, connectString)
	query := "select * from test where region=:region"
	arg := map[string]interface{}{
		"region": region,
	}
	query, args, err := sqlx.Named(query, arg)
	query = db.Rebind(query)
	rows, err = db.Queryx(query, args...)

again same error: mssql: Incorrect syntax near '?'
NB just realised I am using an azure SQL Server instance, maybe this makes a difference?  azuread is from 	"github.com/microsoft/go-mssqldb/azuread"
To workaround this, I had to do something like:
import 	(
	sqll "database/sql"
	"github.com/jmoiron/sqlx"
)
...
	query := "select * from test where region=@region"
	rows, err = db.Queryx(query, sqll.Named("region", region))
...

Is there a better way to do this, or this is a known issue and correct solution?

I did some digging around and found that in bind.go:
var defaultBinds = map[int][]string{
	DOLLAR:   []string{"postgres", "pgx", "pq-timeouts", "cloudsqlpostgres", "ql", "nrpostgres", "cockroach"},
	QUESTION: []string{"mysql", "sqlite3", "nrmysql", "nrsqlite3"},
	NAMED:    []string{"oci8", "ora", "goracle", "godror"},
	AT:       []string{"sqlserver"},
}

But db.DriverName() returns "azuresql", which means it gets "UNKNOWN" instead from func BindType.

adding azuresql solved the problem, i.e. vi bind.go and:
AT:       []string{"sqlserver", "azuresql"},

closing as  #927 has been merged


faq visible in dark  mode

issue number #356
the faq section is now visible in dark mode

please review this pr @Anuj3553

Well done @AyushSharma72


I cannot set the value ref in render function

Version
3.0.7
Reproduction link
https://codesandbox.io/s/use-ref-in-render-gnojw?file=/src/main.js
Steps to reproduce
I cannot set ref in render function,
What is expected?
The value of ref object should be set
What is actually happening?
The value of ref object is not set

What if the ref object is created outside of the setup funciton?

The stuff you return from setup is not part of $props, it becomes part of this.
For further support please use the discord community at chat.vuejs.org

Binding the `this.elRef, I got the same result.
import { defineComponent, onMounted, ref, toRaw, h, createApp } from "vue";

const Test = defineComponent({
  name: "test",
  setup() {
    const elRef = ref("test");
    // should log out the div html element
    // but I got 'test'
    onMounted(() => console.log('>>', elRef.value));
    return { elRef };
  },
  render() {
    return h("div", { ref: this.elRef }, "ok");
  }
});

createApp(Test).mount("#app");

return h("div", { ref: 'elRef' }, "ok");

It works, thanks, I didn't find it in the Render function doc.
By the way, I found if I watch a reactive object which has a ref to DOM element with deep: true option, the traverse function will search all properties of the DOM element, and because of something like parentNode, vue will traverse up to the window object. Therefore, the web page cannot response any event.
use markRaw with ref cannot avoid the loop.
It will be nice if the watch function ignore all the DOM elements

https://v3.vuejs.org/api/special-attributes.html#ref

Expects: string | Function

By the way, I found if I watch a reactive object which has a ref to DOM element with deep: true option, the traverse function will search all properties of the DOM element, and because of something like parentNode, vue will traverse up to the window object. Therefore, the web page cannot response any event.

use markRaw with ref cannot avoid the loop.
It will be nice if the watch function ignore all the DOM elements
Please open an issue. Thanks.,


script not working

The script not working, it's possible to update please?

https://github.com/ohari5336/WhatsAllApp-Mod/issues/16#issuecomment-1050961369


Controller Manager fails to start on GKE

Hi,
we are trying to set up the SAP BTP Service Operator on our Kubernetes Cluster on GKE. The cluster was created with default settings.
We were trying follow the instructions in the Setup part of  your README (https://github.com/SAP/sap-btp-service-operator?tab=readme-ov-file#setup) step by step but unfortunately ran into issues.
What we did (after freshly creating the cluster):

Install cert-manager. We followed the steps described on https://cert-manager.io/docs/installation/helm/#steps

helm repo update
helm repo add jetstack https://charts.jetstack.io --force-update
helm install \
  cert-manager jetstack/cert-manager \
  --namespace cert-manager \
  --create-namespace \
  --version v1.14.3 \
  --set installCRDs=true

Create a Service Manager instance on BTP with plan service-operator-access and create a service binding to it.
Add the repo (step 3 in your guide)
Install the service operator

helm upgrade --install sap-btp-operator-1 sap-btp-operator/sap-btp-operator \
    --create-namespace \
    --namespace=sap-btp-operator \
    --set manager.secret.clientid=<clientid> \
    --set manager.secret.clientsecret=<clientsecret> \
    --set manager.secret.sm_url=<sm_url> \
    --set manager.secret.tokenurl=<auth_url>

where we replaced the values with those from the binding.
Output of this command (retry):
W0229 15:20:55.769973    7644 warnings.go:70] autopilot-default-resources-mutator:Autopilot updated Deployment sap-btp-operator/sap-btp-operator-controller-manager: defaulted unspecified resources for containers [kube-rbac-proxy] (see http://g.co/gke/autopilot-defaults), and adjusted resources to meet requirements for containers [manager] (see http://g.co/gke/autopilot-resources)
Release "sap-btp-operator" has been upgraded. Happy Helming!
NAME: sap-btp-operator
LAST DEPLOYED: Thu Feb 29 15:20:52 2024
NAMESPACE: sap-btp-operator
STATUS: deployed
REVISION: 3
TEST SUITE: None

The issue we experience:

The BTP service operator controller pod is stuck in "container_creating"

The error reprting on Google Cloud console says

so we are suspecting something is wrong with the setup around cert-manager. There were no errors during installation though. Also the pods in the cert-manager namespace look healthy.

As we were trying to follow your documentation, it would be great if you could help us out here. Is there something wrong with the steps that we did for installing cert-manager?
Thanks for your support!

Hi @SvendDomdey
The error message indicates you are missing a secret that is created by cert manager, check the status of a certificate named "sap-btp-operator-serving-cert" to see why the secret is not created.
Thanks

if issue still occurs please reopen


Italian keyword and small refactor for es.go

Hello,
I have created an Italian keyboard mapping following the same format as the other languages provided.
For the Spanish language mapping, I have also included all vowels with accents.

Pull requested :-)


Disable collectors

TASK [cloudalchemy.node-exporter : Assert collectors are not both disabled and enabled at the same time] ***
failed: [host] (item=diskstats) => {
    "assertion": "item in node_exporter_enabled_collectors",
    "changed": false,
    "evaluated_to": false,
    "item": "diskstats",
    "msg": "Assertion failed"
}
failed: [host] (item=mdadm) => {
    "assertion": "item in node_exporter_enabled_collectors",
    "changed": false,
    "evaluated_to": false,
    "item": "mdadm",
    "msg": "Assertion failed"
}

I recently updated the role locally and it started failing with the above message. I think this check was introduced in #22. How do you disable what is enabled by this role (by default)? So far, I was using the role and disabled the collectors that I didn't need and it worked — node-exporter didn't use the collector for e.g. mdam or diskstats.
With #22, my deploy stalls as the collector is enabled by default, but I can't disable it anymore.
Do I need to now explicitly set all enabled and disabled?

Do I need to now explicitly set all enabled and disabled?

Yes, you need to overwrite both node_exporter_enabled_collectors and node_exporter_disabled_collectors

@paulfantom that seems to be new then? I'll go ahead and do that now.

I believe I set them both "correctly" now, but maybe I mis-understood.
Some sample configurations:
# play.yml
- hosts: all
  roles:
     - { role: cloudalchemy.node-exporter }

# group_vars/all.yml
node_exporter_enabled_collectors:
  - arp
  - bcache
  - bonding
  - boottime
  - conntrack
  - cpu
  - cpufreq
  - edac
  - entropy
  - exec
  - filefd
  - filesystem
  - hwmon
  - ipvs
  - loadavg
  - meminfo
  - netclass
  - netdev
  - netstat
  - sockstat
  - stat
  - textfile
  - time
  - timex
  - uname
  - vmstat
node_exporter_disabled_collectors:
  - diskstats
  - infiniband
  - mdadm
  - nfs
  - nfsd
  - wifi
  - xfs
  - zfs

Error "persists", e.g. it's complaining about e.g, "wifi" which is now only in node_exporter_disabled_collectors. Is there anything I am missing?
Here is a log, it repeats for all my hosts in all — same collectors:
TASK [cloudalchemy.node-exporter : Assert collectors are not both disabled and enabled at the same time] ***
failed: [host] (item=diskstats) => {
    "assertion": "item in node_exporter_enabled_collectors",
    "changed": false,
    "evaluated_to": false,
    "item": "diskstats",
    "msg": "Assertion failed"
}
failed: [host] (item=infiniband) => {
    "assertion": "item in node_exporter_enabled_collectors",
    "changed": false,
    "evaluated_to": false,
    "item": "infiniband",
    "msg": "Assertion failed"
}
failed: [host] (item=mdadm) => {
    "assertion": "item in node_exporter_enabled_collectors",
    "changed": false,
    "evaluated_to": false,
    "item": "mdadm",
    "msg": "Assertion failed"
}
failed: [host] (item=nfs) => {
    "assertion": "item in node_exporter_enabled_collectors",
    "changed": false,
    "evaluated_to": false,
    "item": "nfs",
    "msg": "Assertion failed"
}
failed: [host] (item=nfsd) => {
    "assertion": "item in node_exporter_enabled_collectors",
    "changed": false,
    "evaluated_to": false,
    "item": "nfsd",
    "msg": "Assertion failed"
}
failed: [host] (item=wifi) => {
    "assertion": "item in node_exporter_enabled_collectors",
    "changed": false,
    "evaluated_to": false,
    "item": "wifi",
    "msg": "Assertion failed"
}
failed: [host] (item=xfs) => {
    "assertion": "item in node_exporter_enabled_collectors",
    "changed": false,
    "evaluated_to": false,
    "item": "xfs",
    "msg": "Assertion failed"
}
failed: [host] (item=zfs) => {
    "assertion": "item in node_exporter_enabled_collectors",
    "changed": false,
    "evaluated_to": false,
    "item": "zfs",
    "msg": "Assertion failed"
}

Again, it seemed to have worked before. Isn't this is a hefty BC break?

Also related: https://github.com/cloudalchemy/ansible-node-exporter/pull/24/files

Am I reading something wrong? Both PRs seem to be in this for over a year, but I am also sure when I initially started using this, it had a full list of enabled collectors in defaults/main.yml.

Seems like I introduced a bug with https://github.com/cloudalchemy/ansible-node-exporter/pull/79. Will fix it soon.
Full list of enabled collectors was removed as we decided to use collectors enabled in node_exporter by default and extend it by using systemd (on which cloudalchemy roles depend) and configure filesystem collector.

Should be fixed now. :+1:
I see you are based in Berlin, come to next prometheus meetup (April 17th) :smile:

@paulfantom What do I google to find it? I saw one on meetup, but there are no new events listed.

Soon there should be an announcement in https://www.meetup.com/Berlin-Prometheus-Meetup/


Leshan TriggerUpdate() method increasing the thread count

Hi ,
when i trigger Leshan  client update() , for every call leshan thread count is increasing .how to handle these situation?
terminal : jstack 17976 | grep waiting |wc -l  -> count 15
and next trigger
terminal : jstack 17976 | grep waiting |wc -l  -> count 30
Please update

By default calling triggerUpdate() will submit a new task to the internal ScheduledExecutorService of Leshan client DefaultRegistrationEngine.
By default a Single Thread Scheduled Executor is created. (so only 1 thread in the pool) I just tested it and calling triggerUpdate to not increase the number of thread in this case.
You can use a different ExecutorService (than the default one) and in this case this could increase the number of thread in the pool (depending of ExecutorService implementation) but this is the "normal" java behavior.

hi simon,
i was trying multiple clients in single machine as simulator,
when i tried to create 5000 clients in same machine am getting out of memory exception(threads), is there any way to handle these thread?

A good solution would be to consume less thread at Leshan side but as you probably already know that (https://github.com/eclipse/leshan/issues/778#issuecomment-559783618), there is no easy way for now.
Leshan was modified to consume less thread (see #794) but there is still a blocking issue to decrease even more the number of thread usage (see eclipse/californium#1203 for more details).
So at short term, there is no way to decrease this number of thread without writing code (new connector for californium).
But you can eventually moved the OS limit, maybe you could have a look at : https://stackoverflow.com/a/57359754/5088764

ya sure.thank you
On Mon, Aug 17, 2020 at 7:33 PM Simon<EMAIL_ADDRESS>wrote:

Could we close this issue ?
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
https://github.com/eclipse/leshan/issues/865#issuecomment-674900796, or
unsubscribe
https://github.com/notifications/unsubscribe-auth/AIU3WH4EJFYZM2J2HVEUGVTSBE2B5ANCNFSM4OZKQ6UA
.

--
Thanks and Regards,
venkatesh.


Documentation typo: endponit -> endpoint

Extraordinarily trivial issue noticed reviewing rate limit documentation.
No impact out of documentation and trivial review shows this typo was unintented.
docs: Fix a typo in API rate-limiting documentation

this typo was unintented

So was this one I guess :smile:
Thanks!

/test


[Fix #1924] Use a cache to speed things up

I've been working on this for a while, and feel ready to make a pull request. The performance of RuboCop has been discussed lately, so I guess this would be welcomed by some users.
Cache invalidation is generally a hard problem, but I think this solution should work (knock on wood). It uses the source code of the rubocop executable, a selection of the passed options, the inspected file, and its configuration as basis.
Add --cache option and AlwaysRunWithCache configuration parameter (false by default). Store a cache of inspection results at /tmp/rubocop_cache/ (or whatever the temporary directory is). Clean up when it gets too big (governed by the configuration parameter MaxFilesInCache).
Performace
There's a slight performance penalty for storing cached results while inspecting files, around 2%, which is why I chose to only store in the cache if the option is given. The execution when there are cached results to reuse is typically between 10 and 30 times faster.

Great feature! I had totally forgot about this discussion. A see a few small issues right now:

If it's not enabled by default - few people will likely use it
It's still won't help people running RuboCop on CIs (as often they use one-off VMs)
This should be extensively documented in the README

Good feedback. I'll make it on by default, but then I also need to add a --no-cache option. And update README. It's unfortunate that CI runs typically won't benefit. That means we also need come up with some good old-fashioned optimizations. But that's another topic.

Working on a solution that addresses the issues raised here. I have also identified a couple of more problems.

Running without -D, saving to the cache, and then with -D reading from the cache, you get no cop names in the output. I'm sure the problem is more general, i.e., options are not handled correctly in cache invalidation.
The configuration parameter AllCops: MaxFilesInCache is global, so if one inspected project sets it really low, it causes cached results to be erased for other projects. One solution could the to store the cache under the current directory, in .rubocop_cache/ instead of under /tmp/rubocop_cache/.

Pushed some fixes.

Pushed some new updates. Please check again.

Looks fine to me.

Btw, one idea for optimization for dealing with config changes or CLI option changes would be to also cache the ASTs, so we can reuse them directly in such scenarios.

I haven't tested caching the ASTs, so I can't say for sure, but I suspect that it won't do much for performance.
So if we push that aside, maybe we're ready to merge?

Fair enough. Let's merge this!

:+1: Can't wait to use this!


Minting on Asset Hub error (Unable to retrieve a keypair)

Artist (tg: @Frankford18) is trying to mint his collection: https://kodadot.xyz/ahk/collection/120
Production, AssetHub
He is getting this error:

What it is?

https://docs.kodadot.xyz/tutorials/how-to-fix-error-keypair.html#_2-browser-update might help
Maybe try to clear browser cache?

https://docs.kodadot.xyz/tutorials/how-to-fix-error-keypair.html#_2-browser-update might help
Maybe try to clear browser cache?

thank you, will tell him to try

https://docs.kodadot.xyz/tutorials/how-to-fix-error-keypair.html#_2-browser-update might help
Maybe try to clear browser cache?

he did, he tried to do it all - all steps in the document you sent, he has no metadata update in polkadot.js and he ist still getting this error. His address: HC8PkF1x3LLTVpFXNuy2i8h7btKk5ZGxDX8dFZPaLPV2m87

He tried:

delete cookies, cache
restart laptop
remove and add wallet (by accident)
update his metadata in the wallet
I sent him more funds

His reply:

@roiLeo would you think it would be too bad to spawn prompt and ask user which wallet does he use?

@JustLuuuu for the context this bug happens when app is trying to find a wallet which user used to log in. If app fails to do this task, it would try to find your Wallet JSON in localStorage (aka keyring) and when it also fails it will spawn this dialog.
I am thinking to remove the keypair storage but need another fallback for the user

@roiLeo would you think it would be too bad to spawn prompt and ask user which wallet does he use?

wdym? looks bad for UX, maybe we can throw error in sentry.
does this occur before or after the validation popup in extension?

does this occur before or after the validation popup in extension?

As I wrote above the error is thrown when app cannot find wallet we can try rather say unable to communicate with wallet please relogin

I would still open issue to rework the signing 😇🫶

I would still open issue to rework the signing 😇🫶

could you please share step to reproduce?

Login
Clear localstorage
Sign anything

This should fail imo

Yup I was able to reproduce :)