text:
expose chart ref

This pull request resolves #6, taking advances of React.forwardRef and React.useImperativeHandle
Breaking Changes
// No more
import { ReactChart } from 'chartjs-react';
ReactChart.register(...);

// Do below
import { ReactChart, register } from 'chartjs-react';
register(...);

// It's no good to add arbitrary props or functions to an FC in TypeScript.
// Let's be definitely typed!

Demo
https://codesandbox.io/s/musing-stallman-wbq7s?file=/src/App.tsx
https://codesandbox.io/s/musing-stallman-wbq7s?file=/src/ReactChartWithRegister.tsx

It's hard to get register under ReactChart however...

Ok. I did a little digging. It's okay to keep `ReactChart.register.
Please refer to https://codesandbox.io/s/musing-stallman-wbq7s?file=/src/ReactChartWithRegister.tsx
However, this would make code a little more complicated. What do you think?
Looking forward to your feedback. I make another pull request if necessary.
Best Regards,
Ace

Ok. I did a little digging. It's okay to keep ReactChart.register.
Please refer to https://codesandbox.io/s/musing-stallman-wbq7s?file=/src/ReactChartWithRegister.tsx
However, this would make the code a little more complicated. What do you think?
Looking forward to your feedback. I could make another pull request if necessary.
Best Regards,
Ace

Hey! First, I want to apologize for this delay and thank you for your participation.

ReactChart.register -  the main idea was to align the syntax with Chart.js to make the wrapper easier to use. I think that this is exactly what we have achieved, so I don’t see any reason to change the syntax yet.
The forwardRef. I once had a similar solution in my mind, but the main problem is that such a solution does little for end-users. One of the main ideas for giving users the ref to the instance is to allow them to add listeners for events like click or hover. As in request: https://github.com/xr0master/chartjs-react/issues/3
In addition, the ref will be null while the canvas element is not mounted, which requires end-users to constantly check if there is an instance.

On the other hand, though... Most of the API will be available
https://www.chartjs.org/docs/next/developers/api

After some thought, I still think that such a pattern will not be stable and effective. At the moment, I added the ability to specify the chart ID, which makes it possible to get an instance through the API Chart.
const myChartInstance = Chart.getChart('unique-chart-id');

Thank you very much!


text:
kcp能不能走TCP协议?

我的服务商不支持UDP转发,只支持TCP,可以用KCP吗?谢谢

不可以，不越界。

@xtaci 什么时候支持一下udp吧，就剩它了

你可以试试linux 4.9的BBR

我的这个程序可以把UDP流量包装成TCP，用raw socket的方式。测试过，可以配合kcptun使用。
https://github.com/wangyu-/udp2raw-tunnel

感觉这个想法被实现了好多遍了

确实被实现了很多遍了，现有的让kcptun支持tcp的项目貌似有3个：
https://github.com/linhua55/some_kcptun_tools/tree/master/relayRawSocket 。这个是最早的，ptyhon写的，没有模拟3次握手。在我这里的NAT环境用不了。
https://github.com/Chion82/kcptun-raw  。这个是简化版的kcp，支持TCP的同时简化掉了FEC之类的功能。
https://github.com/ccsexyz/kcpraw 。这个fork了原版，但是xtaci并不打算把新加的功能merge进去。时间长了以后，这个分支会落后于xtaci的版本很多。
所以我写了我的那个udp2raw-tunnel，优点是，可以一直兼容最新版的kcptun。缺点是，相当于给kcptun包了一层额外的tunnel，有额外性能开销。侧重点不一样，根据自己的需求决定使用哪个吧。

关于“时间长了会落后很多”我持保留意见。

@ccsexyz 更改了相关表述 。。

@ccsexyz 师弟毕业了么

其实 kcptun 的主要实现是在 kcp-go 和 smux 这两个库里的，kcptun 本身的代码并不算多，所以 copy 起来工作量也不会很大。
实在担心跟不上上游，还可以用 https://github.com/ccsexyz/tunnel 啊。

才看到@ccsexyz
之前测试了下udp2raw-tunnel，win客户端需要跑在虚拟机麻烦了点。

source: gharchive/issue

authors: ccsexyz cjjdaq daiaji wangyu- xtaci yjd yuhuan21

repo: xtaci/kcptun

license: mit

license_type: permissive

license_source: bigquery


text:
🛑 Xensor V Wiki is down

In 5ed2bc6, Xensor V Wiki (https://w.xvnet.eu.org) was down:

HTTP code: 0
Response time: 0 ms

Resolved: Xensor V Wiki is back up in aa777e3 after 12 minutes.

repo: xtexChooser/uptime

license: MIT

license_source: github-api


text:
Issue with SignOut

Hi
I am having a JS error when signing out that says: this.afAuth.signOut is not a function
I believe this line of code is the culprit:
https://github.com/xtreamsrl/firebase-ngrx-user-management/blob/277df50f4e58a363decfee4ad3f08180c97b1110/projects/xtream/firebase-ngrx-user-management/src/lib/effects/login.effects.ts#L114
And it should be this.afAuth.auth.signOut
When debugging, you can see this.afAuth don't have a signOut function:

Encountering the same issue with Login with this below this.afAuth.setPersistence is not a function
https://github.com/xtreamsrl/firebase-ngrx-user-management/blob/277df50f4e58a363decfee4ad3f08180c97b1110/projects/xtream/firebase-ngrx-user-management/src/lib/effects/login.effects.ts#L157
I am not sure if it is a bug on the library or an environmental issue on my end, in any case, I'd appreciate any help.
Thank you

I think this occurs because the latest version depends on angular/fire 6.0. According to this the auth object no longer exists.

Correct, I'm on 5.x. Upgrading should then do it.
Thanks

A quick review on changelogs in @angular/fire makes it clear.

authors: emilbonnek jcmelchorp miroo93

repo: xtreamsrl/firebase-ngrx-user-management


text:
the default values for camera calibration

Hi, thank you for the work.
I can't find the camera calibration function, so I'm trying to perform the camera calibration.
[workflows]

Get the config value in loadFameConfig.
Calculate the matrix using deg step, t step, fxfy scale, xyz degree, xyz trans fields. in setOptions
Call setOptions and re-render every time the value of "2." changes

What should I specify as the default values of  camera_internal, camera_external from config in loadFameConfig?
ex) deg_step = 0.3 ... etc
Can you help me with the above?
I am willing to contribute to the development of these features if they align with Xtreme's development roadmap.

For more info about camera configs, you can refer the BasicAI Cloud's doc
Point cloud camera configs.

@jaggerwang
Thanks, I found the answer I was looking for in the above document.

authors: jaggerwang seungdeok


text:
底部回弹问题

怎么开启 到底部有回弹效果，再上拉才有加载更多。iOS效果

设置Footer中的overScroll参数


text:
打开全白，代理是啥？

问题描述
打开就是全白，手动更新，网路出错，看了帮助说，需要代理，一直没搞清楚怎么代理，特来询问，
复现步骤
打开就这样，我也不知道
截图
No response
系统版本
win11 22h2
寻空版本
1.4.4.0
日志
log_20240527_131002.txt
log_20240527_131848.txt
log_20240527_131908.txt
log_20240527_132157.txt
log_20240527_132727.txt
log_20240527_133606.txt
log_20240527_133616.txt
备注
No response

vpn挂着没一点用，真的搞不懂这代理是个啥

repo: xunkong/xunkong


text:
请求增加长亭雷池图标

你想要新增什么图标？

长亭雷池

该图标有可参考的项目或 LOGO 地址吗？

https://waf-ce.chaitin.cn/images/safeline.svg

已添加 https://github.com/xushier/HD-Icons/commit/9273165e221aada428c3d3ff5139cc9eef867460

authors: xushier xzxnc

repo: xushier/HD-Icons


text:
Running ./gradlew mkdocsPublish in parent project results in submodules overwriting parent module.

Parent project is configured for mkdocs.
Parent project has one or more submodules.
If any submodule is separately configured for mkdocs.
Running /.gradlew mkdocsPublish results in the submodule mkdocsPublish task overwriting the parent's mkdocs output.

Thank you for the report!
I tried to reproduce this and did not note any overrides.
Maybe you were publishing into the same git repository and target doc folders for root and submodule were named the same and that cause the override you refer to:

Root build docs in folder 'build/mkdocs/1.0`
Module (for example, named 'sub') build docs in folder 'sub/build/mkdiocs/1.0'
Root pushed folder '1.0' into git
Submodule pushed its '1.0' folder and override root docs

If that was the case and you need to push both folders into the same git (same branch) then rename root or submodule folder, for example:
mkdocs.publish.docPath = 'sub-\$version'

In this case two separate folders would be published: '1.0' and 'sub-1.0'.
It is also importatnt to disable root redirects in one of modules:
mkdocs.publish.rootRedirect = false
because only one folder could be the default.
If your case is different, please describe it so I can reproduce.

It's not an override. It's an overwrite.
Submodule builds use the same build folder as the parent build when built from the parent.
When I run ./gradlew mkdocsBuild in the parent project each submodule clears out the build/mkdocs folder and then places it's output there. This is because the submodules get the same working directory for builds as the parent module. I'm not sure there is an easy fix other than documenting that you have to use ./gradlew :mkdocsBuild and not ./gradlew mkdocsBuild.

Can you please post mkdocs-related configurations (if it happens inside allprojects or subprojects block, please mention it)?
I checked with mostly default settings and it was working:
          mkdocs {
                sourcesDir = 'docs'
          }

          project(':doc') {
              apply plugin: 'ru.vyarus.mkdocs'

              mkdocs {
                  sourcesDir = 'src'

                  publish {
                      docPath = 'sub-$version'
                      rootRedirect = false
                  }
              }
          }

There should be something in your config causing overwrites (could be side effects of allprojects/subprojects block usage).
Build dir is declared in mkdocs.buildDir and resolved using context project, so build dirs should be different.

Did you solve your problem? In case if not, without configuration example I wouldn't be able to help (I can't reproduce).

Sorry, I've been swamped. Will try and put together something today.

Closing this as not active, but please reopen if you still have this problem and can describe how it could be reproduced

authors: michael-newsrx xvik

repo: xvik/gradle-mkdocs-plugin


text:
When the parent node sets an opaque background color in subflow, the edges of the child node disappear

What platform were you using when you found the bug?

React Flow / Svelte Flow version: 12.3.1
Browser and version: Microsoft Edge  129.0.2792.79
OS and version: Windows 22H2

Live code example
https://stackblitz.com/edit/t2rqgd?file=nodes.js,package-lock.json
Describe the Bug
edge exit:

edge not exit:

Steps to reproduce the bug or issue
Open link:https://stackblitz.com/edit/t2rqgd?file=nodes.js,package-lock.json
Expected behavior
Add this feature according to your progress
Screenshots or Videos
No response
Additional context
No response

By default all edges are rendered below nodes. You can move them to the foreground by adjusting their zIndex https://reactflow.dev/api-reference/types/edge#z-index

authors: moklick xiaoyaovo

repo: xyflow/xyflow


text:
Add NPM package

Hello,
I like this classless CSS framework a lot! Any plans about publishing it on NPM? In this way devs might use more standard ways to add this CSS to their workflow

Thanks for the suggestion! It's on npm now as @exampledev/new.css. I'm pretty new to npm, so let me know if it could use improvements or changes.


text:
How can I add my social media links to the website

Please assist

@vmandela99  Please refer to https://github.com/zerostaticthemes/hugo-hero-theme.
I am sorry I can not provide any further assistance, as this is just a fork of the original repository.

No problem. I figured it out. I added the in the config.toml as menu items.
Thanks though
On Sun, Feb 14, 2021, 19:10 Xiaozhe Yao notifications@github.com wrote:

@vmandela99 https://github.com/vmandela99 Please refer to
https://github.com/zerostaticthemes/hugo-hero-theme.
I am sorry I can not provide any further assistance, as this is just a
fork of the original repository.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/xzyaoi/hugo-hero-theme/issues/1#issuecomment-778799292,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AL6ZSLOLW3LBQBOZ3LDJABDS67YY5ANCNFSM4XSTCSOA
.

repo: xzyaoi/hugo-hero-theme


text:
Omit "input" message when only expecting "output"

When you are only waiting for Output, you have to use something like heartbeat message in Input section of step for the step to be saved in Scenario.
Otherwise Step is not being saved

This is fixed in https://github.com/yaalalabs/fixyl/releases/tag/v1.0.9

authors: DhananjayaR GrumpyRoger

repo: yaalalabs/fixyl


text:
Fix #24 Unable to find ruff executable

This PR changes the default value for the pylsp.plugins.ruff.executable config setting to null (from ruff) in order to match the default for python-lsp-ruff. This fixes #24 and restores the expected default behaviour of python-lsp-ruff, which is to look for ruff in the current Python environment. Without this fix the user has to either install ruff globally, or ensure their editor is running in a suitably activated virtual environment containing ruff.
This PR also:

updates the README with some additional help text related to python-lsp-ruff;
syncs descriptions, types and missing config options from the upstream LSPs/plugins;
changes the defaults for some additional config options to match upstream.

The last item in that list (change defaults for some additional config options) will result in a change in behaviour for existing users who haven't overridden these options in their own config. If this is too much of a breaking change then I'm happy to resubmit this PR without that commit, however I do believe that changing the default for pylsp.plugins.ruff.executable is important and necessary as the current default will result in a broken ruff plugin for those who don't have a ruff binary in their $PATH (and, in fact, completely broken linting due to a bug in python-lsp-ruff).

Thanks merged!

source: gharchive/pull-request

authors: chris-reeves yaegassy

repo: yaegassy/coc-pylsp


text:
deep linking support

Is there any way to do deep linking with this library?
i.e. deep-linking

Yes you can do it ...

I found nothing in the docs. could you explain how I can do this?

Yes, it is possible. As the docs (https://core.telegram.org/bots#deep-linking) say,

... your bot will receive a message from that user in this format:
/start PAYLOAD`

PAYLOAD stands for the value of the start or startgroup parameter that was passed in the link.

Therefore, all you've to do is capture the message with the format described above. For example,
bot.onText(/\/start (\w+)/, function(msg, match) {
    const payload = match[1];
    // ....
    // use payload
   // ...
  return bot.sendMessage(msg.chat.id, "bot at your service");
});

repo: yagop/node-telegram-bot-api


text:
When using any helper the message "env is not defined" is shown in the console

While doing a test with the library in a project, no matter what helper I use I always get the "env is not defined" message in the console and the app doesn't render at all.
The only things I've done so far are:

Install the library with ember install ember-intl
Add the ready function to app/app.js as stated in the docs
Generate en locale with ember g ember-intl and then ember g locale en
Trying to parse a number with the following helper (Previously I've tried to parse a date without success): {{format-number product.price style="currency" currency="USD"}}

The offending line is:
exports['default'] = function (formatterName) {
        function throwError () {
            return new Error(formatterName + ' requires a single unname argument. {{' + formatterName + ' value}}');
        }

        if (Ember['default'].HTMLBars) {
            return function (params, hash, options, env) {
                if (!params || (params && !params.length)) {
                    return throwError();
                }

                var outStream;

                function touchStream () {
                    outStream.notify();
                }

                var value     = params[0];
                var view      = env.data.view;   // <=== ENV IS NOT DEFINED HERE
                var intl      = view.container.lookup('service:intl');
                var seenHash  = streams.readHash(hash);
                var formatter = view.container.lookup('formatter:' + formatterName);

                if (value.isStream) {
                    value.subscribe(function () {
                        touchStream();
                    }, value);
                }
// .....

I'm using latest version of ember-cli and Ember 1.13
UPDATE: Reading through the issues, is this related to #105?

Hi @larsbs 1.13 introduced a breaking change around how helpers are constructed.  The 1.x will only work up until 1.12.
However, there is a 2.0 branch in progress that addressed this yesterday:
https://github.com/yahoo/ember-intl/pull/127
I just need to fix the failing tests for < 1.13 before merging into 2.0.  Once that is done, I will be releasing 2.0-beta1 hopefully tonight or tomorrow.
A lot more has changed in 2.0, so if you go that route be sure to read the documentation.  The major one is translations are now stored outside of the app folder and in a translations folder and can be in YAML/JSON format.  The best example of this is in the dummy app inside of tests.

authors: jasonmit larsbs

repo: yahoo/ember-intl


text:
Rebuild state serially

We should be rebuilding the state serially, because some operations should not be reordered. I think should read the log in parallel building a sequential list of operations until we reach a stop condition, and then replay these operations sequentially.

Current version is not based on BK

authors: dgomezferro francisco-perez-sorrosal

repo: yahoo/omid


text:
Add pure-menu-open CSS class to the main menu

I made this pull request to fix issue #302, feel free to ignore or reject it if the new pure menus fixes the problem.

CLA is valid!

Closed the pull request, seems the the new pure menus do not require pure-menu-opened.

@macguru2000 Correct. Thanks. Oh, the hazards of Master being out of sync with the website documentation.

authors: jamesalley macguru2000 yahoocla

repo: yahoo/pure-site


text:
Support Simple JS Escaping

You guys have done some excellent work, but I'm curious why you don't handle "simple" JS escaping where the template value is in a string?
Fully tokenizing JS is obviously a lot of work; but to get to being able to escape values inside String it seems like you only need to track comments & quotes.
Am I missing something, or are there other reasons you guys haven't approached this problem?

it is a good question, right now, we have the logic to identify the template markup is being placed within script tag, however, we think that most of the time, the scriptable context is DYNAMIC and it is NOT the final output context, such that even we apply the filtering rule to the template markup, it is still vulnerable
taking the following example, the final output context is attribute single quoted and URI contexts, not scriptable context, attacker can easily bypass with "javascript:" in this case, if we apply the JS filtering, we will give the false sense of security to the developer, so we take the approach of warning the developer instead right now.

PS. the logic to detect template markup in scriptable context
https://github.com/yahoo/secure-handlebars/blob/master/src/context-parser-handlebars.js#L761
https://github.com/yahoo/secure-handlebars/blob/master/src/context-parser-handlebars.js#L640

I am curious what exact use case u want to support? and then we can brainstorm what is the best approach.

I don't have a specific use case in mind, I just think this is really useful tech that I would want to recommend to people building webapps. Frankly, I think these kinds of systems should be the default for templating in every language/framework.
You're right that there are probably a lot of apps that look exactly how you mention, but the approach you've taken of html encoding things in that context is one that other templating systems have taken before (in the form of static auto-escaping), and the result has been people just removing the escaping entirely rather than figure out how to properly escape the data. Or in the event handler scenario, they just assume that since the html escaping isn't breaking everything it's fine.
I haven't actually looked at what the warnings you have are, but the solution I saw in the slides about this talk for making it to go away involve reading the value out of a HTML attribute, which is fine, but doesn't really solve the issue of JS being dynamic.
I just feel like not everyone has the capability to review JS code for security, or even has access to a security person, but we should still make their lives incrementally easier when we can.
You can still keep emitting the warning if you like, but I feel getting the escaping right by default would be a better than getting it half-right sometimes (event handlers in HTML) and emitting a warning. I get so much output on my command line when I build my code that I may miss warnings entirely.

I totally agree to your point that escaping right by default is the goal.
The workaround we are suggesting right now is to ask the developer to add the filter to specify the final output context. frankly, this workaround defeats our initial intention of analyzing context and applying the filter right automatically. it is manual approach. :(
https://github.com/yahoo/secure-handlebars#warnings-and-workarounds
Recently, I have seen the trend of JS templating is evolving to another approach of transforming the template into the DOM before data binding, the main reason of this approach is have more responsive UI. interestingly, the by product of this transformation can limit the output context by its templating language, not similar to handlebars that developers can put output markup without limitation like the example above. in this case, our life is easier of just applying the filters correctly and automatically. Of course, I assume that their template parsers are correctly coded.
If we wanna to solve the JS context in handlebars, we need to solve one interesting challenge, what parser should we use for parsing the code within the

repo: yahoo/secure-handlebars


text:
ViewModel - left join on same table multiple times

I have a model that has multiple references in another model (1:1 relations). My ModelView attempt looks like following:
@ViewModelSpec(className="MediaView", viewName="mediaView")
public class MediaViewModelSpec
{
    @ViewQuery
    public static final Query QUERY = Query.select()
            .from(Media.TABLE)

            // Following two queries belong together, so FolderSorting must have this folders id as reference!
            .leftJoin(Folder.TABLE, Media.FK_FOLDER.eq(Folder.ID))
            .leftJoin(FolderSorting.TABLE, Folder.FK_SORTING.eq(FolderSorting.ID))

            // Following two queries belong together again
            .leftJoin(Folder.TABLE, Media.FK_FOLDER_DATE.eq(Folder.ID))
            .leftJoin(FolderSorting.TABLE, Folder.FK_SORTING.eq(FolderSorting.ID))

            // Following two queries belong together again
            .leftJoin(Folder.TABLE, Media.FK_FOLDER_LOCATION.eq(Folder.ID))
            .leftJoin(FolderSorting.TABLE, Folder.FK_SORTING.eq(FolderSorting.ID))

            // Following two queries belong together again
            .leftJoin(Folder.TABLE, Media.FK_FOLDER_TAG.eq(Folder.ID))
            .leftJoin(FolderSorting.TABLE, Folder.FK_SORTING.eq(FolderSorting.ID));
}

Explanation is, that each Media belongs to 4 types of folders and each of this folder can have it's own sorting. I want to use the ModelView for this ombined query to query all data at once.
Do I have to use my own aliases so that this type of view works? Or is there some build in solution for this?
Additionally, merging on one and the same table multiple times seems to make problems when I want to use mapToModel. Can I still somehow use it?

You'll probably need aliases, yes. SquiDB by design doesn't do much magic with its SQL builders, it's a WYSIWYG situation. You can alias tables using as(), and then get the table aliased version of a property using qualifyField:
Table folder1 = Folder.TABLE.as("folder1");
LongProperty folderId1 = folder1.qualifyField(Folder.ID);

We have test cases and a test model spec illustrating the concept you're trying to achieve -- see ThingJoinSpec.

I missed the qualifyField function...
So following should work:
@ViewModelSpec(className="MediaView", viewName="mediaView")
public class MediaViewModelSpec
{
	public static final Table TBL_FOLDER = Folder.TABLE.as("F1");
	public static final Property.LongProperty TBL_FOLDER_ID = TBL_FOLDER.qualifyField(Folder.ID);

	public static final Table TBL_FOLDER_DATE = Folder.TABLE.as("F2");
	public static final Property.LongProperty TBL_FOLDER_DATE_ID = TBL_FOLDER_DATE.qualifyField(Folder.ID);

	@ViewQuery
	public static final Query QUERY = Query.select()
			.from(Media.TABLE)

			// Following two queries belong together, so FolderSorting must have this folders id as reference!
			.leftJoin(TBL_FOLDER, Media.FK_FOLDER.eq(TBL_FOLDER_ID))
			.leftJoin(FolderSorting.TABLE, Folder.FK_SORTING.eq(TBL_FOLDER_ID))

			// Following two queries belong together again
			.leftJoin(TBL_FOLDER_DATE, Media.FK_FOLDER_DATE.eq(TBL_FOLDER_DATE_ID))
			.leftJoin(FolderSorting.TABLE, Folder.FK_SORTING.eq(TBL_FOLDER_DATE_ID));

}

And then I can do following:
MediaView mediaView = ...;
Folder folder = mediaView.mapToModel(new Folder(), MediaViewModelSpec.TBL_FOLDER);
Folder folderDate = mediaView.mapToModel(new Folder(), MediaViewModelSpec.TBL_FOLDER_DATE);

I think this will work, so I will close that issue. Thanks

Yep, that's how it's done! Let us know if you run into any other issues with it.

Edit: it's possible you'll need to alias the joins on FolderSorting.TABLE as well, and I think your query might mean to say folderSortingAlias.qualifyField(FolderSorting.FK_SORTING).eq(TBL_FOLDER_ID), but I think you have the tools you need now to set up those joins the way you want.

yes, you're right, of course they have to be aliases as well... Thanks.
Btw, you may be able to answer following question as well: I have thousands of medias that are linked to a few folders, each folder is linked to a sorting (and some other foreign key property). When I make such a complex query with so many joins (I need a few more than I have in the example above) and most of the time the foreign properties are the same objects, would it make a difference if I query each table seperately and then set the foreign properties in java? Via binary searches and so?
I want to avoid that the database is querying the same foreign property over and over again. I think, sql internal caching solves the problem for me, but I'm not sure. Do you know that?

In my experience, 99% of the time doing things in a single query is faster than multiple queries. It's just better to delegate more of the work to native SQLite (which is quite fast) than to do the same work in Java. SQLite's query optimizer and page cache are pretty smart, so I think in this scenario they'll probably work fine for your case. The SQL may be more complex when you do things all in a single query, but it's very often faster, especially if you've taken the time to optimize the SQL and make sure all the necessary indexes are set up.
If you feel like things are slow when they should be fast, the first place to look is your indexes! Note that SQLite may not index foreign key columns: see https://www.sqlite.org/foreignkeys.html#fk_indexes

Just for others:
I think, there is one thing that you have to consider, memory. Having thousands of rows that are all linked to a few objects means, that if you use SQL directly, every linked object is a own object. I this case, you may consider linking foreign key objects in java instead of querying them directly via SQL. In my case, I'll do that.
Question about views
As far as I see, I MUST define each field, that my subquery should select and use an empty select in the query definitions. Am I able to add all fields of a sub table at once? I tried adding an array, but this is not added to the Property array of the view...
Example
@ViewModelSpec(isSubquery = true)
public class FolderViewModelSpec
{
	@ViewQuery
	public static final Query QUERY = Query.select().from(Test.TABLE);

	public static final Property.LongProperty TEST_FIELD1 = Test.TABLE.qualifyField(Test.ROWID);
	public static final Property.LongProperty TEST_FIELD2 = Test.TABLE.qualifyField(Test.FIELD1);
	// ... and so on... list of all fields of the test table
	// this is hard doing it by hand...

	// THIS DOES NOT WORK, those fields are NOT added to the subquery's select
	public static final Field[] TEST_FIELDS = Test.TABLE.qualifyFields(Test.PROPERTIES);

}

I then want to do following:
Test folder = modelView.mapToModel(new Test (), Test.TABLE);

You're right, of course, about memory usage. SquiDB itself doesn't particularly care how you decide to read things into Java objects -- whatever works best for your app is good :)
And yes, you have to list each field you want included in the view. The annotation processing API can only give you access to values that are compile time constants, but things like property objects or the contents of the properties array of a table are runtime constants only. There's no way to extract them from the array at compile time or to know what each of their types are, which would be needed to generate the individual property declarations for them in the generated view model class. From the perspective of the code generator, the only thing that exists at compile time is the field declaration public static final Field[] TEST_FIELDS; as though no value were given to it. So, they have to each be listed one by one.

Can't you change the public static final Field[] to a public static final List<Field> and then do something like following in the annotation processor:
public static final Field[] fields = new ArrayList<>()
{
    {
        // add all defined fields AND arrays of fields here
        add(singleField);
        addAll(Arrays.asList(listOffields));
    }
}

This could then respect following in the ModelView specs:
// one row per table must be defined only
// an array of all qualified fields of a particular table
public static final Field[] TEST_FIELDS = Test.TABLE.qualifyFields(Test.PROPERTIES);

I see what you're saying, you're suggesting building up the lists of properties at runtime (we'd still have to convert them to arrays when the class is loaded for backwards compatibility reasons but that's not much of an issue). It's an interesting idea, but it comes with a couple major drawbacks:

We still wouldn't be able to generate individual property declarations for any fields included via an array, and by extension we wouldn't be able to generate getters/setters for them either. So the model would be unusable on its own: you would ALWAYS have to use mapToModel to extract data from it.
You wouldn't be able to construct any queries with WHERE clauses on the view, since no individual properties would be declared in the model.

For the things we use views for, I think both of these restrictions would be major problems, especially the second one. Do you have any follow up thoughts though?

If it is not possible to do something like following in an annotation processor
for (int i = 0; i < TEST_FIELDS.size(); i++)
{
    // do something with every value, like generating the property for it
}

then I don't see any sense in adding this with the drawbacks you mention...

Yeah, not possible unfortunately. The contents of an array or list like that aren't constant at compile time, so from the perspective of the annotation processor they basically don't exist. The fields are represented to the processor as a VariableElement, but you can see from the javadoc here that the only way to get the value of a VariableElement is if it is a constant -- and only primitive values or String constants qualify as compile-time constants.

authors: MFlisar sbosley

repo: yahoo/squidb


text:
iOS sample project SDBSampleTask not found

commit: f1d61b250c8eed196362c7be09fc5a8949af4cc3

Task.h is also not found in iOS project.
Is Task.h file generated by j2objc or written by native objc code?

I found Task.h in xcode derived data


text:
Fehler beim Debugmodus in einem Modul

dump() verursacht eventuell einen Query (User erkennen) und dadurch kann es dazu kommen, dass getLastId() nicht klappt. Deswegen im Modul das komplett herausnehmen. Debugging geht dann nur über redaxo debug modus

Soweit ich weiss, ist das im REDAXO Core bereits erledigt


text:
context menus

at least for cut/copy/paste
"There also are no context menus. I can't right-click to copy or paste in the message box."

I was looking for a "Copy link location" today when I tried to right-click a link. Context menus would be cool.

https://www.sitepoint.com/building-custom-right-click-context-menu-javascript/

implemented!

authors: PMiner algesten averissimo maxkueng

repo: yakyak/yakyak


text:
A JavaScript error occurred in the main process

This seems to have shown up after a Windows 10 updates installed last night. Running YakYak 1.4.3 on Windows x64.
A screen shot is here: http://i.imgur.com/uwmXr4H.png
Text of the error:
A JavaScript error occurred in the main process
Uncaught Exception:
SyntaxError: Unexpected token

Have you tried deleting your Preferences file from %appdata%\yakyak folder?
https://goo.gl/HE7ooD

I may have overreacted, but I just ditched the whole folder from AppData. Brilliant! It worked.
Thank you @infool7 !

I ran into this same issue.  Wiping AppData fixed it, though of course I had to sign in again.  Is it possible this is related to two-factor authentication?

Same issue here, and can confirm a fix.
Tried first to delete the Preference file from '\AppData\Roaming\yakyak' as @infool7 suggested. Didn't work. I then deleted the entire yakyak folder. That worked, meaning I don't know how much really is needed to delete, but the entire folder does work.
Like @cout stated I also had to log in again. I also have two-factor authentication.

Delete the 3 cookies files inside the AppData folder, this forces the App to request the login data again, fixing this error.
My guess is that refreshtoken.txt isn't being read correctly or so causing the auth token to expire

I can't find any description of this error on Google. What's wrong with this error?
我无法从谷歌上搜索到任何这个错误的描述信息，这个错误到底是怎么回事？

authors: DanLauer ccpwcn cout dheeris infool7 neico


text:
Tutorial

Added tutorial

@esantus , please dont merge anything into master until i review it.
I want to QA everything before it goes to master

authors: esantus yala


text:
Allow arbitrary values to be inserted into _media and _container objects

Description
CSS At-rules @media and @container are updated daily, and it is safer if developers can insert arbitrary values.
Problem Statement/Justification
type Media {
  ...,
  [key: string]: any
}

Proposed Solution or API
No response
Alternatives
No response
Are you willing to participate in implementing this feature and create a pull request include the implementation?
Yes
Additional Information
No response

Fixed #974

repo: yamada-ui/yamada-ui


text:
Streaming by line inconsistencies

Hey @yamafaktory, first of all, thank you! JQL is fantastic
However, I've noticed issues when streaming logs into JQL. I've looked at #26 and tried every option I can think of but I'm getting zero output.
This works as expected:
docker logs container_name 2>&1 | jql '.!'

Fails when trying to tail via docker logs -f
docker logs -f container_name 2>&1 | jql '.!'

Right now I'm using JQ to process them, (docker logs -f container_name 2>&1 | jq '.') but I honestly love the '.!' option.
Any ideas on how to make this work? Wondering if it's similar to many JQ comments suggesting you need --unbuffered --stream.

Hi @joshmeads and thanks for the feedback!
At the moment jql doesn't support reading a real stream of JSON as input. In #26, what I've done was using Deserializer::from_str from serde_json, but this is only valid for a file.
However there's a super handy function which should make this possible: Deserializer::from_reader (https://docs.serde.rs/serde_json/fn.from_reader.html). I'd have to refactor the way the binary currently takes the data.
Bonus point: this will be unbuffered out of the box.

The content of the IO stream is deserialized directly from the stream without being buffered in memory by serde_json.

Will soon have a look at it and keep you updated!

@joshmeads I've just released v2.8.0 with a new --stream flag that should fix your issue.
Please feel free to reopen this issue if this is not working as expected.
Thanks again for the feedback!
https://github.com/yamafaktory/jql#streaming

@yamafaktory you're a legend. Works perfectly. Thank you so much!

authors: joshmeads yamafaktory

repo: yamafaktory/jql


text:
インラインボックス作成

組版オブジェクトでspanに相当するインラインボックスを用意する。
これがないと文字を枠で囲ったりするのが難しい。
ドキュメント - ページ（物理）- ボックス（論理、breakable）- 行（物理）- インラインボックス（論理、breakable）- 文字という構造になる。
インラインボックス（やボックス）の入れ子を許すかは難しいところ。
改行処理とかがテキスト設定の指定が大変なので。
ただ、枠を書くことを考えると必要そうではある。

インラインボックスとしてるけど、単語としては単にinlineでよさそう。
page - box - line - inline - char。
論理のboxとinlineに対してbox_settingとinline_settingがある感じ。

boxじゃなくてblockにした方がいいかもしれない。

repo: yamaimo/TexGoodByeTool


text:
Readme / wiki update

Can someone update the readme/wiki for correctly understand what the new features offer and what are they deafult values?

All are false by default. The current fixes has a short description on each setting as well. What do you want from it?

i didn't found any description, can you pass me it ? I just wanna know what "disable_boundary_teleport" do 😅😅

i didn't found any description, can you pass me it ? I just wanna know what "disable_boundary_teleport" do 😅😅

Delete the teleport caused by going beyond the boundary in the game

disable_intro_movies ... Skips the logo/warning movie (it still plays in the background while the game is loading, but will be skipped to the intro cinematic when it's ready)
disable_vignette ... Removes vignette overlay (aka no "darkened border")

enable_debug/unlock_menu will also let you use debug teleport on map screen, but you need to edit inputUserMappings.xml file to bind the teleport button first, as explained at #145
To use it just open map screen, hover over a map icon and hold the teleport button (you can also set a waypoint and then teleport to waypoint icon too)

enable_debug/unlock_menu will also let you use debug teleport on map screen, but you need to edit inputUserMappings.xml file to bind the teleport button first, as explained at #145
To use it just open map screen, hover over a map icon and hold the teleport button (you can also set a waypoint and then teleport to waypoint icon too)

Hem ... i didn't really understad this features ... can you explain to me ?

Hm, not really sure how else to explain it...
With enable_debug/unlock_menu (and the inputUserMappings.xml file edited like #145 says), you can open map screen -> hover on icon -> hold down 'O' key on keyboard -> character will be teleported to the map icon.
Changes inside #145 are needed to set up the O key to work, unfortunately.

I am going to need help documenting and updating the wiki, I think people should be able to make pull requests to it? I am not sure

Had a quick look on the wiki pages earlier but didn't see anything about editing/forking/etc, I guess there must be some way though, but only thing I've found so far is that wiki itself has a git repo at https://github.com/yamashi/PerformanceOverhaulCyberpunk.wiki.git :/

I am going to need help documenting and updating the wiki, I think people should be able to make pull requests to it? I am not sure

yup, i already made one pull request, i`m kinda shy to do so because of my bad eng... but i will try to help today =D

authors: ArturVRSampaio Jeddunk LittleZen emoose extract hulovexu1314 yamashi

repo: yamashi/PerformanceOverhaulCyberpunk


text:
Minimize the output HTML

固定の style は CSS を一度だけ読み込むようにするなど。
as is:
...

to be
...

.typeset {
  word-break: keep-all;
  overflow-wrap: anywhere;
}

Web コンポーネントもありえそう。
見通しも良くなるし、option 値を下層まで伝えずに済むのでいいかもしれない。
as is:
Text

to be

<typeset-wrapper><typeset-latin>Text</typeset-latin><typeset-thinsp></typeset-thinsp></typeset-wrapper>

Web コンポーネントを使う場合、

他のライブラリとの名前空間のバッティング
Typesetter が2回以上呼ばれるときはどうするか？オプションを必須にする？

あたりを考慮する

Node.js 環境では Web コンポーネントの扱いがややこしいので、
Web コンポーネントライブラリである Lit を試したが、
最終的なバンドルサイズが 50kb 程度と約2倍になってしまったため、泣く泣く断念。
Lit 自体はいいライブラリだと思った。

repo: yamatoiizuka/palt-typesetting


text:
Added exception handling.

Sorry I can't reproduce this crash on my device, but here is at least a fix that should work.

Thanks!

authors: vitaminwater yamill

repo: yamill/react-native-orientation

license: isc


text:
Update user-images.md

I hereby agree to the terms of the CLA available at: https://yandex.ru/legal/cla/?lang=ru
Description of changes:

Все готово!
Проверьте результат: RU,
Check the result: EN.

authors: rmdlv yfm-team

repo: yandex-cloud/docs


text:
Unknown compression method: 105 when using multiIf on indexOf result

I have a query that searches from the last index of 3 in the array and than slices the array. When I try to add a condition for no match (using multiIf) I got weird error:
SELECT
    [1, 2, 3, 1, 3] AS a,
    indexOf(arrayReverse(arraySlice(a, 1, -1)), 3) AS offset_from_right,
    arraySlice(a, multiIf(offset_from_right = 0, 1, (length(a) - offset_from_right) + 1))

Exception on client:
Code: 89. DB::Exception: Unknown compression method: 105: while receiving packet from localhost:9000, 127.0.0.1

When I disable compression
Connecting to localhost:9000 as user default.
Connected to ClickHouse server version 1.1.54390.
select [1,2,3,1,3] as a, indexOf(arrayReverse(arraySlice(a, 1, -1)), 3) as offset_from_right, arraySlice(a, case when offset_from_right = 0 then 1 else length(a) - offset_from_right + 1 end)

SELECT
    [1, 2, 3, 1, 3] AS a,
    indexOf(arrayReverse(arraySlice(a, 1, -1)), 3) AS offset_from_right,
    arraySlice(a, multiIf(offset_from_right = 0, 1, (length(a) - offset_from_right) + 1))

Exception on client:
Code: 62. DB::Exception: Empty query: while receiving packet from localhost:9000, 127.0.0.1

Connecting to localhost:9000 as user default.
Connected to ClickHouse server version 1.1.54390.

Without multiIf part, query works fine:
    arrayPushFront([1, 2, 3], 3) AS a,
    indexOf(arrayReverse(arraySlice(a, 1, -1)), 3) AS offset_from_right,
    arraySlice(a, (length(a) - offset_from_right) + 1)

┌─a─────────┬─offset_from_right─┬─arraySlice(arrayPushFront([1, 2, 3], 3), plus(minus(length(arrayPushFront([1, 2, 3], 3)), indexOf(arrayReverse(arraySlice(arrayPushFront([1, 2, 3], 3), 1, -1)), 3)), 1))─┐
│ [3,1,2,3] │                 3 │ [1,2,3]                                                                                │
└───────────┴───────────────────┴───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────┘

Now it works smoothly. I'll add a test.

authors: alexey-milovidov kodieg

repo: yandex/ClickHouse


text:
alter table via distributed table is not working

Hello,
I'm not sure if this a bug or not but based on documentation: "INSERT and ALTER are replicated"
Having this in mind I'm expecting the following scenario is working:
CREATE TABLE db_1_testing.collection_four_src(`ck.partition` Date,`ck.created_at` DateTime,`ck.timestamp` DateTime, `transaction_id` Nullable(String),`price` Nullable(Float64),`name` Nullable(String),`array` Nullable(Array(String))) ENGINE = ReplicatedMergeTree('/var/lib/clickhouse/tables/{shard}/collection_four_src','{replica}',`ck.partition`,`ck.timestamp`,8192);
CREATE TABLE db_1_testing.collection_four AS db_1_testing.collection_four_src ENGINE = Distributed(cluster_test,db_1_testing,collection_four_src,rand());

Then when I execute:
ALTER TABLE db_1_testing.collection_four MODIFY COLUMN `array` Nullable(Array(Int64));

I receive 200 OK but nothing happened. The column is still Nullable(Array(String)) not Nullable(Array(Int64))
If I execute the same on each collection_four_src table on each node works.
Silviu

Behavior it's pretty odd...
Basically I create a table with a column which is Nullable(String) then I alter the table to change the type of that column in Nullable(Int64). (look at validation_date in the following example)
CREATE TABLE project_1_1.ivr_src(`ck.partition` Date,`ck.created_at` DateTime,`app_id` Nullable(Int64),`charge_cost` Nullable(Float64),`charge_rate` Nullable(Float64),`ck.timestamp` DateTime,`country_code` Nullable(String),`delivery_cost` Nullable(Float64),`delivery_rate` Nullable(Float64),`duration_billed` Nullable(Int64),`from` Nullable(String),`provider_id` Nullable(Int64),`repeated` Nullable(UInt8),`to` Nullable(String),`user_id` Nullable(Int64),`validated` Nullable(UInt8),`validation_date` Nullable(String)) ENGINE = ReplicatedMergeTree('/var/lib/clickhouse/tables/{shard}/ivr_src','{replica}',`ck.partition`,`ck.timestamp`,8192);
CREATE TABLE project_1_1.ivr AS project_1_1.ivr_src ENGINE = Distributed(cluster_test,project_1_1,ivr_src,rand())
ALTER TABLE project_1_1.ivr_src MODIFY COLUMN `validation_date` Nullable(Int64)

If I insert values via the distributed table is not working: (Code: 53, e.displayText() = DB::Exception: Type mismatch in IN or VALUES section. Expected: String. Got: UInt64, e.what() = DB::Exception\n)
If I do via the local table is working.
Working:
INSERT INTO project_1_1.ivr_src(`validation_date`,`validated`,`user_id`,`to`,`repeated`,`provider_id`,`from`,`duration_billed`,`delivery_rate`,`delivery_cost`,`country_code`,`ck.timestamp`,`charge_rate`,`charge_cost`,`app_id`,`ck.created_at`,`ck.partition`) VALUES (1491000849,1,14226201,'557799738',1,675,'157783225',1,0.262,0.262,'LB',1491000845,0.3406,0.3406,14226201,1498769440,17256);

Not working:
INSERT INTO project_1_1.ivr(`validation_date`,`validated`,`user_id`,`to`,`repeated`,`provider_id`,`from`,`duration_billed`,`delivery_rate`,`delivery_cost`,`country_code`,`ck.timestamp`,`charge_rate`,`charge_cost`,`app_id`,`ck.created_at`,`ck.partition`) VALUES (1491000849,1,14226201,'557799738',1,675,'157783225',1,0.262,0.262,'LB',1491000845,0.3406,0.3406,14226201,1498769440,17256);

Yes, it is designed behavior.

I'm not sure if this a bug or not but based on documentation: "INSERT and ALTER are replicated"

It is related to Replicated* tables, not to Distributed.
From the doc:

The Distributed engine by itself does not store data, but allows distributed query processing on multiple servers.

Distributed table is just proxies INSERT and SELECT queries.
Since it does not store data it is logically that it cannot modify underlying data.
Moreover, it can proxies different kind of tables simultaneously (even other proxy tables such as Merge and Distributed).
It makes cascading altering of distributed table is too complicated.
But to make ALTERs on cluster easier you could try new feature called "distributed DDL".
So, you can write ALTER queries like
ALTER TABLE merge ON CLUSTER cluster ADD COLUMN s DEFAULT toString(i)

it will be eventually executed on each instance (even if someone instance not available now).
Currently Distributed DDL doesn't allow to make ALTERs of Replicated tables, but you can avoid this using distributed_ddl_allow_replicated_alter=1 setting (more technical details why it happens).

Hello thanks,
Very useful comment. I'll try the new feature "distributed DDL" but still you are telling that "Distributed table is just proxies INSERT and SELECT queries." if it's like this then why in order to alter a replicated table I need to:

alter all replicated tables on all nodes where I have it.
(at this point all inserts on the new column via the replicated tables are working but via distributed table are not)
2.I need to perform the same alter via the distributed table on all nodes again (after this queries involving the new column on distributed table start working as well)

See my second comment did few days ago. In case distributed table was only a view I was expecting to be able to do queries on the new column once I changed the replicated tables on all nodes.
Maybe something is not clear enough for me
Silviu

Distributed table is just a view, but it has it's own table structure (list of columns),
that must match table structure of remote tables, or at least have a subset of columns.
This looks redundant, but it is much more simple in implementation: every table has it's own list of columns.
That's why you have to alter both remote tables and distributed table.

@alexey-milovidov  so means that in order to alter a table you need to :

Run "ALTER TABLE x ON CLUSTER" cluster on one of the nodes of the replicated table
Run the alter on all nodes individual where you have a distributed table ?

I'm correct ? seems a bit redundant..

This is correct.
It's typical to have Distributed table on every node on cluster. In that case, you just run second ALTER TABLE y ON CLUSTER.

Ah ok got it. Might be better to add this in documentation as well :) I'm sure it's confusing for other peoples as well.

@alexey-milovidov
I have an error when I try to alter distributed table that points to ReplicatedMergeTree on cluster
CREATE TABLE log.test ON CLUSTER 'my-cluster' (date Date, value1 String) ENGINE = ReplicatedMergeTree ('/clickhouse/tables/{shard}/log/test','{replica}', date, (date), 8192)
CREATE TABLE log.test_d ON CLUSTER 'my-cluster' AS log.test ENGINE = Distributed('my-cluster', log, test, rand())
ALTER TABLE log.test ON CLUSTER 'my-cluster' ADD COLUMN value2 String
ALTER TABLE log.test_d ON CLUSTER 'my-cluster' ADD COLUMN value2 String

The last alter throws an error: An error occured before execution: Code: 371, e.displayText() = DB::Exception: Table test_d isn\'t replicated, but shard #2 is replicated according to its cluster definition, e.what() = DB::Exception for each node

I came across this problem in clickhouse 18.1.6 version. I got the query log in every nodes of the cluster when Alter a distributed table 'test'. For example, DDLWorker: Processing task query-0000000005 (ALTER TABLE default.test ON CLUSTER replicated_stock ADD COLUMN  nc String ), and it can be executed on every node successfully, but failed with the exception  "able test isn't replicated, but shard #3 is replicated according to its cluster definition, e.what() = DB::Exception". It almost succeeds from my view, and the code
if (!execute_once_on_replica && config_is_replicated_shard)
{
throw Exception("Table " + ast_alter->table + " isn't replicated, but shard #" + toString(task.host_shard_num + 1) +
" is replicated according to its cluster definition", ErrorCodes::INCONSISTENT_CLUSTER_DEFINITION);
}
makes me confused. If we can alter the query manually on each node, why does the server give a try?

Correct me if I am wrong, based on the above comments I summarize the current status as of 2019.12.18. The following is by design.

[x] 3-node zookeeper + 3-node cluster
config = 2 replicas, 0 shards
config = <internal_replication>true</internal_replication>

[x] CREATE/DROP ReplicatedMergeTree ON CLUSTER
working ok

[ ] ALTER TABLE ON CLUSTER
fails with error:
DB::Exception: There was an error on [clickhouse-2.clickhouse-headless.clickhouse.svc.cluster.local:9000]: An error occured before execution: Code: 371, e.displayText() = DB::Exception: Table '[REDACTED]' is replicated, but shard #3 isn't replicated according to its cluster definition. Possibly <internal_replication>true</internal_replication> is forgotten in the cluster config. (version 19.15.3.6 (official build)).

authors: alexey-milovidov dolbyzerr ludv1x silviucpp wangzhen11aaa zhangguiyu


text:
Run the code in single GPU

Dear Song,
Hi, thanks for your great work.
I try to reproduce your work to enhance it a bit, but there is some problem in my setting.
I have to use a single GPU due to the limitation of resources. For this, I add
os.environ["CUDA_VISIBLE_DEVICES"]='1'
in main.py or set device with
torch.device('cuda:1')
in run_lib.train.
However, it always assigns gpu:0, so
RuntimeError: cuDNN error: CUDNN_STATUS_MAPPING_ERROR
is occurred.
Is there any solution for it?
GPU that I used is NVIDIA RTX3090 with 24GB.
Thank you.

You can create a .sh file to export export CUDA_VISIBLE_DEVICES=1 and use  config.device = torch.device('cuda:0') if torch.cuda.is_available() else torch.device('cpu') on config file. this solved the issue

Thank you!


text:
🛑 Google is down

In b97f8bf, Google (https://google.icloudnative.io) was down:

HTTP code: 0
Response time: 0 ms

Resolved: Google is back up in 387604b.

repo: yangchuansheng/upptime


text:
🛑 Google is down

In 686ffb9, Google (https://google.icloudnative.io) was down:

HTTP code: 0
Response time: 0 ms

Resolved: Google is back up in d023d3d.


text:
🛑 Google is down

In 1532544, Google (https://google.icloudnative.io) was down:

HTTP code: 0
Response time: 0 ms

Resolved: Google is back up in b652d19 after 1 minute.


text:
🛑 gcr.io Mirror is down

In ec882e2, gcr.io Mirror (https://gcr.icloudnative.io) was down:

HTTP code: 503
Response time: 701 ms

Resolved: gcr.io Mirror is back up in b312d13 after 6 minutes.


text:
nextProps aren't handled by no-unused-props

I have the following (simplified) piece of code:
  componentWillReceiveProps(nextProps) {
    if (!nextProps.error) {
      console.log('oh noez');
    }
  }

This triggers the following ESLint error:
  89:27  error  'error' is missing in props validation  react/prop-types

However, if I do add error to propTypes, another error is triggered:
  33:10  error  'error' PropType is defined but prop is never used  react/no-unused-prop-types

I think the two rules should cooperate.
I'm using the following relevant packages:

eslint@3.15.0
eslint-config-airbnb@14.1.0
eslint-plugin-react@6.10.0

+1

It's not really about "cooperation", but certainly both rules should be able to detect used props in nextProps identically.

authors: emirdeliz ljharb remcohaszing

repo: yannickcr/eslint-plugin-react


text:
semver policy for rule changes

I noticed that in v7.8.0, the no-deprecated rule was enhanced to warn about componentWillMount and the other newly deprecated lifecycle methods. I'm curious why this is not considered a breaking change that requires a major version bump. For codebases that have that rule enabled (or the recommended set) and have the disabled lifecycle methods, pulling that change in broke their builds even though it was a minor upgrade.
I know a linter is kind of weird in that new features can break apps, but It seems to me that any time a rule gets more strict or a rule is added to the recommended set, that should be considered a breaking change. If the policy is different, maybe I just need to change my wildcard to be a ~ instead of a ^. But I'd appreciate some clarification on how the semver bumps are decided.
Thanks!

That would definitely help. Though it could still break someone couldn't it? The react pragma version is  an eslint thing right? If a person could have had the version set to 16.3+ before 7.8 came out, then upgrading to this new rule would break them without a major upgrade.

In that case they’d have runtime warnings, so the eslint warnings would be catching those sooner.
For the eslint ecosystem, the standard isn’t “any new errors is major”, it’s more nuanced than that. I don’t think that means you want ~, either - i think it means that if a new release suddenly causes linter errors, it’s supposed to be something you should have been doing in the first place. If you set the 16.3 pragma, it’s assumed that you’re following React 16.3’s conventions already.

Are the runtime warnings enabled yet? I haven't seen them in my apps.
Your point makes sense though. I guess linters are a special case in that they are designed to break builds. So they can't follow semver in the traditional sense.
Thanks for the explanation. I like the pragma solution.

So it turns out the rule already does respect the pragma. I just never set my version of it. Sorry for the false alarm. I'll close this. But I think react may not have enabled the runtime warnings yet because I have not seen any in my apps and they are in dev mode and still have some deprecated lifecycle methods.

authors: bdwain ljharb


text:
forbid-prop-types crashes on PropTypes.shape

eslint: v7.3.1
eslint-plugin-react: v7.20.1
Code:
import PropTypes from "prop-types";

const Foo = {
	foo: PropTypes.string,
};

const Bar = {
	bar: PropTypes.shape(Foo),
};

Error:
TypeError: Cannot read property 'forEach' of undefined
Occurred while linting C:\Projects\test\index.js:8
    at checkProperties (C:\Projects\test\node_modules\eslint-plugin-react\lib\rules\forbid-prop-types.js:91:20)
    at CallExpression (C:\Projects\test\node_modules\eslint-plugin-react\lib\rules\forbid-prop-types.js:173:11)
    at C:\Projects\test\node_modules\eslint\lib\linter\safe-emitter.js:45:58
    at Array.forEach (<anonymous>)
    at Object.emit (C:\Projects\test\node_modules\eslint\lib\linter\safe-emitter.js:45:38)
    at NodeEventGenerator.applySelector (C:\Projects\test\node_modules\eslint\lib\linter\node-event-generator.js:254:26)
    at NodeEventGenerator.applySelectors (C:\Projects\test\node_modules\eslint\lib\linter\node-event-generator.js:283:22)
    at NodeEventGenerator.enterNode (C:\Projects\test\node_modules\eslint\lib\linter\node-event-generator.js:297:14)
    at CodePathAnalyzer.enterNode (C:\Projects\test\node_modules\eslint\lib\linter\code-path-analysis\code-path-analyzer.js:635:23)
    at C:\Projects\test\node_modules\eslint\lib\linter\linter.js:949:32

I have the same error.

Thanks for the repro; I'll have the fix released later today.

v7.20.2 is released.

authors: Aerendir MhMadHamster ljharb


text:
Added GetTextAngle compatibility for KiCad 6

This is needed for KiKit panelize using KiCad 6.0.11

Thanks!

authors: set-soft yaqwsx

repo: yaqwsx/pcbnewTransition


text:
[Question] DataLoader

Great job!!
I have a doubt about DataLoader, how could I add to resolvers? or is it not possible?

DataLoader?
The resolvers are dynamic at runtime, static resolvers have to be written manually, for that, generate your gql schema and from there you go further writing your own resolver functions:
node ./node_modules/swagger-to-graphql/bin/swagger2graphql  --swagger=./src/swagger.json > ./src/swagger.graphqls

repo: yarax/swagger-to-graphql


text:
Delivery rule models

Resolves #

Description
Needs #1430
Proposed Changes

Add delivery rules

Screenshots
License
I confirm that this contribution is made under the terms of the license found in the root directory of this repository's source tree and that I have the authority necessary to make this contribution on behalf of its copyright owner.

@kevinhinterlong we might want to bump from 2.0 since this change could break users that have the old FB schema.

repo: yavin-dev/framework


text:
Web Creator, iOS, and Android player APIs all returned errors

Describe the bug
Works locally fine!
But not in AWS Lambda for download
https://github.com/ybd-project/ytdl-core/blob/2062b0934c5aea2296fc43b619e86cc29a6ad329/src/info.ts#L522
 const videoReadableStream = ytdl(
      `https://www.youtube.com/watch?v=${videoId}`,
      {
        filter: 'audioandvideo',
        quality: 'lowest',
      }
);

videoReadableStream
        .pipe(writeStream)
        .on('finish', async () => {
          this.logger.log(`VIDEO_DOWNLOAD_FINISHED`);
...
...
...

Error Details (Log)
{
    "errorType": "Runtime.UnhandledPromiseRejection",
    "errorMessage": "Error: Web Creator, iOS, and Android player APIs all returned errors.",
    "reason": {
        "errorType": "Error",
        "errorMessage": "Web Creator, iOS, and Android player APIs all returned errors.",
        "stack": [
            "Error: Web Creator, iOS, and Android player APIs all returned errors.",
            "    at _getBasicInfo (/var/task/dist/main.js:265353:15)",
            "    at process.processTicksAndRejections (node:internal/process/task_queues:95:5)"
        ]
    },
    "promise": {},
    "stack": [
        "Runtime.UnhandledPromiseRejection: Error: Web Creator, iOS, and Android player APIs all returned errors.",
        "    at process.<anonymous> (file:///var/runtime/index.mjs:1276:17)",
        "    at process.emit (node:events:529:35)",
        "    at process.emit (node:domain:489:12)",
        "    at emit (node:internal/process/promises:149:20)",
        "    at processPromiseRejections (node:internal/process/promises:283:27)",
        "    at process.processTicksAndRejections (node:internal/process/task_queues:96:32)"
    ]
}

Environment

Video URL: https://www.youtube.com/watch?v=jKi2SvWOCXc
@ybd-project/ytdl-core version: "@ybd-project/ytdl-core": "^5.0.6",
Node.js version:
Operating system: Lambda

Specify poToken and visitorData as the second argument of the ytdl function.

Thannk you @ybd-project . I tried different type of solutions and fixed it.
Best one is;
const info = await ytdl.getInfo(
      `https://www.youtube.com/watch?v=${videoId}`,
      {
        agent,
        poToken: PO_TOKEN,
        visitorData: VISITOR_DATA,
      },
    );
// Get info first and download from info
const videoReadableStream = ytdl.downloadFromInfo(info, {
      filter: 'audioandvideo',
      quality: 'lowest',
      poToken: PO_TOKEN,
      visitorData: VISITOR_DATA,
    });

authors: hicay ybd-project

repo: ybd-project/ytdl-core


text:
🛑 Vaultwarden is down

In b6dd495, Vaultwarden (https://e.neko.red) was down:

HTTP code: 0
Response time: 0 ms

Resolved: Vaultwarden is back up in 0dc9eec.


text:
NBS-4826 send message about long running blob operations to TPartitionActor and TVolumeActor

Столкнулись с проблемой. Если происходит несколько проблем чтения блобов, то происходит перезапуск актора партишена (https://github.com/ydb-platform/nbs/blob/wp/NBS-4826/1/cloud/blockstore/libs/storage/partition/part_actor_readblob.cpp#L101). А он пересылает сообщения от компаньона, отслеживающего зависшие запросы (TLongRunningOperationCompanion) в TVolumeActor, который отправляет данные про зависшие запросы в мониторинг и в логи.
Так вот, если происходит перезапуск актора партишена, то он не пересылает сообщения, от акторов чтения/записи блобов потому что уже умер.
Все это приводит к тому что TVolumeActor считает что запрос завис навечно и на графиках мониторинга появляется полка зависших запросов.
Что сделано: TLongRunningOperationCompanion шлет теперь сразу два сообщения - в  TPartitionActor и TVolumeActor.

еще надо прекоммитный чек перезапустить

authors: drbasic qkrorlqr

repo: ydb-platform/nbs


text:
run experimental tests on nightly ydb image

Pull request type

Please check the type of change your PR introduces:

[ ] Bugfix
[ ] Feature
[ ] Code style update (formatting, renaming)
[ ] Refactoring (no functional changes, no api changes)
[x] Build related changes
[ ] Documentation content changes
[ ] Other (please describe):

What is the current behavior?

Issue Number: N/A
What is the new behavior?

Other information

Codecov Report
All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 43.20%. Comparing base (43625f8) to head (ed26da4).
Report is 6 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #1383      +/-   ##
==========================================
+ Coverage   41.87%   43.20%   +1.32%
==========================================
  Files         351      293      -58
  Lines       35226    25768    -9458
==========================================
- Hits        14751    11133    -3618
+ Misses      19993    14183    -5810
+ Partials      482      452      -30

Flag
Coverage Δ

go-1.20.x
43.18% <ø> (-0.50%)
:arrow_down:

go-1.21.x
43.16% <ø> (+0.01%)
:arrow_up:

go-1.22.x
?

macOS
43.12% <ø> (+1.70%)
:arrow_up:

ubuntu
43.20% <ø> (+1.81%)
:arrow_up:

unit
43.20% <ø> (+1.32%)
:arrow_up:

windows
?

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

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

authors: codecov-commenter rekby

repo: ydb-platform/ydb-go-sdk


text:
fix: codecov flag for integration tests

I hereby agree to the terms of the CLA available at: https://yandex.ru/legal/cla/?lang=en
Pull request type
Please check the type of change your PR introduces:

[x] Bugfix
[ ] Feature
[ ] Code style update (formatting, renaming)
[ ] Refactoring (no functional changes, no api changes)
[ ] Build related changes
[ ] Documentation content changes
[ ] Other (please describe):

Codecov Report
Patch coverage has no change and project coverage change: -0.26 :warning:

Comparison is base (c23f6a5) 46.47% compared to head (ac09ae7) 46.22%.

:mega: This organization is not using Codecov’s GitHub App Integration. We recommend you install it so Codecov can continue to function properly for your repositories. Learn more
Additional details and impacted files
@@            Coverage Diff             @@
##           master     #726      +/-   ##
==========================================
- Coverage   46.47%   46.22%   -0.26%
==========================================
  Files         150      149       -1
  Lines       16017    15962      -55
==========================================
- Hits         7444     7378      -66
- Misses       8240     8255      +15
+ Partials      333      329       -4

Flag
Coverage Δ

go-1.17.x
46.22% <ø> (?)

go-1.20.x
?

ubuntu
46.22% <ø> (?)

unit
46.22% <ø> (-0.26%)
:arrow_down:

windows
?

Flags with carried forward coverage won't be shown. Click here to find out more.
see 17 files with indirect coverage changes

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Do you have feedback about the report comment? Let us know in this issue.

authors: ImpressionableRaccoon codecov-commenter


text:
Update KingfisherWebP.podspec

fix: change kingfisher dependence version

@VanQuvideo Thanks for this! I forgot that CocoaPods' version constraints are not the same as other languages. I'll merge this PR once the comment issue is addressed.

authors: VanQuvideo yeatse

repo: yeatse/KingfisherWebP


text:
Blog: Add discord-copy-id article

起飛前確認事項

[x] 我已詳細確認編輯之文件有符合 CONTRIBUTING.md 文件規範

@Nat1anWasTaken is there any ongoing development?

repo: yeecord/website


text:
More reasons (and discussion links) added

More reasons (and discussion links) added to the things we do and don't tolerate.

Are the failing checks a problem?!

@pa9ey no worries about the CI issues, I'll fix them a bit later. Thanks!


text:
For #800: Fix FtRemote for empty response body test case and unignore returnsAnEmptyResponseBody.

For #800:

Fixed test cases for empty response body;
Removed @todo and @Ignore from tests

Job #855 is now in scope, role is REV

This pull request #855 is assigned to @g4s8/z, here is why; the budget is 15 minutes, see §4; please, read §27 and when you decide to accept the changes, inform @yegor256/z (the architect) right in this ticket; if you decide that this PR should not be accepted ever, also inform the architect; this blog post will help you understand what is expected from a code reviewer; there will be a monetary reward for this job

@g4s8 answered, please take a look

@g4s8 @t-izbassar As asked, I've reverted the changes and added an issue to jcabi-http project, and changed our issue so it can only be fixed after we deal with the problems in assertBody in jcabi-http. I've reverted pom.xml changes because although I think that they're pertinent and important they does not belong to this ticket. Please take a look now and say me what you think.

Codecov Report

Merging #855 into master will decrease coverage by 0.02%.
The diff coverage is n/a.

@@             Coverage Diff              @@
##             master     #855      +/-   ##
============================================
- Coverage     77.19%   77.17%   -0.03%
+ Complexity      998      997       -1
============================================
  Files           224      224
  Lines          4731     4731
  Branches        380      380
============================================
- Hits           3652     3651       -1
  Misses          918      918
- Partials        161      162       +1

Impacted Files
Coverage Δ
Complexity Δ

src/main/java/org/takes/http/MainRemote.java
53.33% <0%> (-1.67%)
6% <0%> (-1%)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 341fb1b...2541579. Read the comment docs.

@t-izbassar I don't know if it fixes https://github.com/yegor256/takes/issues/712, I'm trying to  find why https://github.com/yegor256/takes/issues/800 is happening and these classes are not behaving accordingly.
I've not tried with another http client either, but I've tracked the problem to the jcabi-http library and documented it in ticket comments and in PR comments too. I've spent way more than 30 minutes in this ticket, mostly in review, and this issue is clogging my agenda for almost a month now.
If the presented solutions are not enough, please tell me precisely what would I do so we could close this ticket. Takes tickets are stale in my agenda and are preventing me for making money, so please help me to get rid of this one.

The architect of the project has changed; @yegor256/z is not at this role anymore; @paulodamaso/z is the architect now

@g4s8 @t-izbassar ping, what we need to get this one moving?

@paulodamaso as long as you are an architect now - it’s your call to make. I’ve already expressed my view. I don’t think that issue with jcabi-http is connected to the original problem. At least there is no test added that proves it. You haven’t checked if problem remains with different http client so from my perspective - this PR do not solve anything.

@elenavolokhova/z please review this job completed by @g4s8/z, as in §30; the job will be fully closed and all payments will be made when the quality review is completed

Code review was too long (21 days), architects (@paulodamaso) were penalized, see §55

The job #855 is now out of scope

Payment to ARC for a closed pull request, as in §28: +10 point(s) just awarded to @paulodamaso/z

@g4s8 According to our Policy:

The code reviewer found at least three problems in the code

Only two issues were found during this review.
Please, confirm that you will try to find at least three issues next time.

@0crat quality acceptable

authors: 0crat codecov-io elenavolokhova paulodamaso t-izbassar


text:
Скласти таймлайн

Скласти список всіх (важливих) життєвих подій, визначних дат, досягнень, періодів, що дали приємний і неприємний досвід, тощо. В цьому конкретному випадку довгих списків не буває, натомість бувають погано згорнуті, тому пакуємо сюди все підряд, а про "лишні" події можна буде промовчати пізніше. Список повинен бути систематизованим і посортованим в такий спосіб, щоб читач швидко зрозумів "паттерн" і міг легко орієнтуватись в просторі і часі цього резюме.

sent on email

Thank you

repo: yeldev/homepage


text:
get rid of references to plugins registry

In the welcome message we're making multiple references to the jQuery plugins registry and publishing plugins in there. That doesn't really make sense anymore, since the plugins site is currently in "read-only mode".

:+1: Wanna do a PR?

Sorry, @sindresorhus, missed your comment. Will do PR this evening ;)

@sindresorhus https://github.com/yeoman/generator-jquery/pull/37

authors: arthurvr sindresorhus

repo: yeoman/generator-jquery


text:
Exclude file from minification

I use KendoUI library in my project, so it's already minified but incredibly big. Is it possible to exclude it from being uglified when using grunt-usemin?
Thanks!

I have the same issue
Did you found a solution for that?

+1 on this

authors: Deklin laylaaitlaaraj novikserg

repo: yeoman/grunt-usemin


text:
Update Pages “about”

Automatically generated by Netlify CMS

👷 Deploy Preview for yff111 processing.

Name
Link

🔨 Latest commit
d2234bd1b15b0f7186075fa72698c51f397b87a7

🔍 Latest deploy log
https://app.netlify.com/sites/yff111/deploys/6362466fa517710008963503


text:
Issue with -v /input /output

Hi,
I am new docker, I have build the LongQC docker image, and ran with below command
docker run  -v /data/shared/clinical/LongRead/Data:/input  -v /data/shared/clinical/LongRead/Data:/output  longqc sampleqc  -x pb-sequel  -p 60  -o /data/shared/clinical/LongRead/Data/175841_s1  bampath.txt
Input i tried with input file /input/data/shared/clinical/LongRead/Data/m84011_220902_175841_s1.hifi_reads.bam does not exist and gave abs path in txt file for both instance it says file doest exists
Is there something wrong with my mount -v ? how should one give the input BAM

Hi @kiranpatil222,
Thanks for your interest in our app.
kindly read the below instruction for docker if you haven't.

docker run -it
-v YOUR_INPUT_DIR:/input
-v YOUR_OUTPUT_DIR:/output
longqc sampleqc
-x pb-sequel \ specify a preset and change accordingly.
-p $(nproc) \ number of process/cores, this uses all of your cores. change accordingly.
-o /output/YOUR_SAMPLE_NAME \ keep /output as this is binded.
/input/YOUR_INPUT_READ_FILE keep /input as this is binded.

The path /data/shared/clinical/LongRead/Data should exist in your host OS, which doesn't exist in your docker container. this is why binding is important like /data/shared/clinical/LongRead/Data -> /output.
In this case, -o option should be simply like -o /output/175841_s1 as mentioned above. The same goes for the input, if your bam file exists under /data/shared/clinical/LongRead/Data/ in your host OS, then the input path should be /input/m84011_220902_175841_s1.hifi_reads.bam.
BTW, -x pb-sequel option is for CLR data, not for HiFi data. You should use -x pb-hifi if your data is HiFi.
Yoshinori

Hi @yfukasawa , Thank you for the clarification, Now worked perfectly got results,
I have converted my local docker image to singularity image as follows
singularity build longqc.sif docker-daemon://longqc:latest
I was jus wondering how to use/run the tool using Singularity file command as in docker image
singularity exec --bind /data  longqc.sif  /opt or /bin ??

Hi @kiranpatil222,
glad to know that it worked fine. unfortunately, I'm not an expert of singularity - never tested LongQC on it.
Some web tutorial says it mounts your home dir automatically like this page.
If you face LongQC specific issue in this context, reopen this issue please.
Yoshinori

repo: yfukasawa/LongQC


text:
use the Ansible podman_secret module to make secret generation idempotent

successor of #19 and #23
It took me a while, but I think now I got it:
Podman secrets contain only a value. They get an ID and and stored in /var/lib/containers/storage/secrets/filedriver as base64 encoded strings.
[root@quadlet-demo ~]# echo "Hello" | podman secret create mysecret -
18ed3fa112e5db63364c8c0c4
[root@quadlet-demo ~]# podman secret inspect mysecret
[
    {
        "ID": "18ed3fa112e5db63364c8c0c4",
        "CreatedAt": "2023-03-21T15:34:13.800126852Z",
        "UpdatedAt": "2023-03-21T15:34:13.800126852Z",
        "Spec": {
            "Name": "mysecret",
            "Driver": {
                "Name": "file",
                "Options": {
                    "path": "/var/lib/containers/storage/secrets/filedriver"
                }
            },
            "Labels": {}
        }
    }
]
[root@quadlet-demo ~]# cat /var/lib/containers/storage/secrets/filedriver/secretsdata.json
{
  "18ed3fa112e5db63364c8c0c4": "SGVsbG8K"
}[root@quadlet-demo ~]# echo SGVsbG8K|base64 -d
Hello
[root@quadlet-demo ~]#

Secrets created by kubectl ... | podman play kube contain also only a value, but in this case it is the whole kubernetes secret YAML:
[root@quadlet-demo ~]# kubectl create secret generic --from-literal=password=hello mykubesecret --dry-run=client -o yaml | podman kube play -
[root@quadlet-demo ~]# podman secret inspect mykubesecret
[
    {
        "ID": "6979ab3f9d11be64bac6ccc36",
        "CreatedAt": "2023-03-21T15:35:49.757097061Z",
        "UpdatedAt": "2023-03-21T15:35:49.757097061Z",
        "Spec": {
            "Name": "mykubesecret",
            "Driver": {
                "Name": "file",
                "Options": {
                    "path": "/var/lib/containers/storage/secrets/filedriver"
                }
            },
            "Labels": {}
        }
    }
]
[root@quadlet-demo ~]# cat /var/lib/containers/storage/secrets/filedriver/secretsdata.json
{
  "6979ab3f9d11be64bac6ccc36": "YXBpVmVyc2lvbjogdjEKZGF0YToKICBwYXNzd29yZDogYUdWc2JHOD0Ka2luZDogU2VjcmV0Cm1ldGFkYXRhOgogIGNyZWF0aW9uVGltZXN0YW1wOiBudWxsCiAgbmFtZTogbXlrdWJlc2VjcmV0Cg=="
}[root@quadlet-demo ~]# echo YXBpVmVyc2lvbjogdjEKZGF0YToKICBwYXNzd29yZDogYUdWc2JHOD0Ka2luZDogU2VjcmV0Cm1ldGFkYXRhOgogIGNyZWF0aW9uVGltZXN0YW1wOiBudWxsCiAgbmFtZTogbXlrdWJlc2VjcmV0Cg== | base64 -d
apiVersion: v1
data:
  password: aGVsbG8=
kind: Secret
metadata:
  creationTimestamp: null
  name: mykubesecret
[root@quadlet-demo ~]#

So, the trick for generating kube-style secrets using podman secret create or the Ansible module is to specify the whole YAML file, just like you would do for Kubernetes.
This avoids the shell module calls and the hassle to get this idempotent.

Looks good. One comment now that you've removed the usage of kubectl, we should also remove its installation (along with the steps that adds the repo and the one that sets the arch fact)

Looks good. One comment now that you've removed the usage of kubectl, we should also remove its installation (along with the steps that adds the repo and the one that sets the arch fact)

Done! And it still works!

authors: johanneskastl ygalblum

repo: ygalblum/quadlet-demo


text:
Replace retrofit and okhttp by quarkus http-client stack

The current implementation for our provider API calls is using retrofit with okhttp client behind the hood. This means that we require to some extend kotlin on our dependencies and this heavy client. Changing this to the quarkus stack for HTTP-client (Microprofile + Vert.X client) might be benefitial in many ways:

Using the default quarkus stack allows to have a seamless integration
Using the jakarta REST standard will allow to migrate easily to other clients (retrofit is using its own annotations). This might not be 100% accurate as microprofile has its own annotations too.
Better quarkus-test support (maybe)
Remove the need of our ClientFactory in favor of the CDI injection.

As I lack the experience with this toolstack, this would require that we ensure the following is true:

[x] The user-agent can be configured in a per-client basis. Currently we are using a okhttp-interceptor for it, but most likely this can be easily configurable with quarkus-config.
[x] Rate-limiting is possible in a way that each request waits for the next (not as a fault-tolerance microprofile implementation as smallrye does, as we don't require to fail). Currently we are also using an interceptor for this, but we should check if a container-filter might be used (see for example this that was found when evaluating). This will require to have it as a provider.
[x] Contract-test and unit-test for the data-provider clients (currently only yugipedia) should still work as expected: the first with a "real-world" client instance, and the second with a mock-webserver with our expectations. At the moment these expectations are using the okhttp-client mockwebserver, but we can also migrate to WireMock as it is also part of the quarkus plug-ins and could be easier also to migrate there.

This ticket is marked by now as status: discussion until the previous is evaluated (probably in a branch where a new client implementation is created to check all the possibilities that we have).

Something to note down: maybe the first step to migrate is to remove the usage of okhttp client and move to vert.x - for example, implementing a call-factory as the one in https://github.com/vietj/retrofit-vertx

As retrofit includes kotlin, this might be a stopper (or require extra-configuration) for the native build. Thus, this kind of blocks #12

First step is to move to wiremock instead of the okhttp-custom system for mocking (see #161). Still the okhttp3-mockwebserver is a dependency as it is required for the tests of the user-agent and rate-limiter. Those componets would be modify to work with the new rest client (if possible).

As shown in #162, the evaluation result is that it is possible (and cleaner) than the actual implementation

repo: ygojson/ygojson-tools


text:
resnet.py architecture queries

Hi @yhenon ,
I was looking through the network in resnet.py under the function nn_base(). I notice that the function is missing stage5 conv_block and identity_block to take into account of filter [512, 512, 2048].
Is there a reason why this was taken out when compared to the default Keras resnet50 architecture?

Okay, I'm closing this. I suppose the reason for this is to adhere to the Faster RCNN paper on 256-d feature vector for bbox coordinates prediction and classification of object.

Sorry for re-opening this ticket. I notice that in resnet.py, under the function rpn(base_layers,num_anchors), I observed that the convolution layer is defined to be a 512-d output.
Q1. Is this suppose to be 256-d as suggested by the paper for ZF net? Or are we following 512-d as per VGG architecture even though we are using ResNet50?
Q2. Referring to my earlier question then, should we be taking into account of the Stage 5 conv_block that is apparently missing in resnet.py under the function nn_base()?
I would appreciate if anyone out there who is experienced with deep learning could shine some light into this. Thanks everyone for reading :)

This dimensions are supposed to be chosen based on the fully connected layers of the original architecture.  Therefore I suspect 512-d is not the correct shape for Resnet-50, might be wrong. @yhenon is there a specific reason for 512-d?

I've looked over this and I'm pretty sure that is the correct size for that layer. My implementation matches what I found here (https://github.com/rbgirshick/py-faster-rcnn/issues/62). Also, 512 is the size of the layer 5a that follows the layer 4f.
The general implementation does match what is described in the resnet paper (although with resnet-5, not resnet-101). The RPN is after stage 4, then the classifier uses stage 5:

We compute the full-image shared conv feature maps using those layers
whose strides on the image are no greater than 16 pixels
(i.e., conv1, conv2 x, conv3 x, and conv4 x, totally 91 conv
layers in ResNet-101; Table 1). We consider these layers as
analogous to the 13 conv layers in VGG-16, and by doing
so, both ResNet and VGG-16 have conv feature maps of the
same total stride (16 pixels). These layers are shared by a
region proposal network (RPN, generating 300 proposals)
[32] and a Fast R-CNN detection network [7]. RoI pooling
[7] is performed before conv5 1. On this RoI-pooled
feature, all layers of conv5 x and up are adopted for each
region, playing the roles of VGG-16’s fc layers.

@yhenon Does this implementation of faster r-cnn use 300 region proposals? And where can I change the amount of region proposals in the code? Thanks.

At train time it uses 300 (see train_frcnn.py), R = roi_helpers.rpn_to_roi(P_rpn[0], P_rpn[1], C, K.image_dim_ordering(), use_regr=True, overlap_thresh=0.7, max_boxes=300)
Not a bad idea to make it a parameter in config.py
On Tue, Aug 1, 2017 at 4:09 PM, jahdiel notifications@github.com wrote:

@yhenon https://github.com/yhenon Does this implementation of faster
r-cnn use 300 region proposals? And where can I change the amount of region
proposals in the code? Thanks.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/yhenon/keras-frcnn/issues/122#issuecomment-319481739,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AJe4ynLGb-aJRphWBzckL6PnRoJiJDvVks5sT4XigaJpZM4OhDxi
.

Yes, thanks so much. In the paper they use 2000 region proposals for training and 300 for testing, it should be a good idea to notify this minor change given it can have a substantial influence in the performance of the network.

@yhenon , thank you for your reply, much appreciation! If the anchor boxes and scale is reduced, will the detector be able to pick up smaller objects in your experience?
Much appreciation for open sourcing this repo.

@yhenon I have a confusion about roi_pooling size in resnet.py, why is the pooling size in tensorflow is 14 while 7 in theano?
Is there some specific consideration?
As I know, the default pooing size in original faster rcnn is 7.
Thank you very much.

@yhenon which paper for
We compute the full-image shared conv feature maps using those layers
whose strides on the image are no greater than 16 pixels
(i.e., conv1, conv2 x, conv3 x, and conv4 x, totally 91 conv
layers in ResNet-101; Table 1). We consider these layers as
analogous to the 13 conv layers in VGG-16, and by doing
so, both ResNet and VGG-16 have conv feature maps of the
same total stride (16 pixels). These layers are shared by a
region proposal network (RPN, generating 300 proposals)
[32] and a Fast R-CNN detection network [7]. RoI pooling
[7] is performed before conv5 1. On this RoI-pooled
feature, all layers of conv5 x and up are adopted for each
region, playing the roles of VGG-16’s fc layers.
I can not find this in KaimingHe's 'Deep Residual Learning for Image Recognition
'

repo: yhenon/keras-frcnn


text:
刚开始可以用一会，不会就报错

Exception: Error https://api2.mina.mi.com/remote/ubus: {'code': 101, 'message': 'ubus server or device returned invalid result', 'data': {'device_data': '{"msg":"ROM端未响应","code":3012}', 'reqID': 'app_ios_J7xO8qku4WtmfrwF6MNZKhTRPBsQCV'}}

Exception: Error https://api2.mina.mi.com/remote/ubus: {'code': 101, 'message': 'ubus server or device returned invalid result', 'data': {'device_data': '{"msg":"ROM端未响应","code":3012}', 'reqID': 'app_ios_J7xO8qku4WtmfrwF6MNZKhTRPBsQCV'}}

重启小爱，然后连蓝牙，不建议一直 mute 小爱

没有mute小授

没有mute小爱

那试试我之前提供的步骤，我研究一下哈，这个 issue 重新打开了。

重启，还有一这个问题，用了几分钟，就停了，因为ROM端未没响应，可能就退出了

@joe12801 可以拉最新代码再试试

我也碰到了这个问题。

有这个API 的文档 能让我们详细看下吗

Exception: Error https://api2.mina.mi.com/remote/ubus: {'code': 101, 'message': 'ubus server or device returned invalid result', 'data': {'device_data': '{"msg":"ROM端未响应","code":3012}', 'reqID': 'app_ios_HuprAzBNKhylCEqocO1gdfU5Iw6GX7'}}
Task was destroyed but it is pending!

Exception: Error https://api2.mina.mi.com/remote/ubus: {'code': 101, 'message': 'ubus server or device returned invalid result', 'data': {'device_data': '{"msg":"ROM端未响应","code":3012}', 'reqID': 'app_ios_HuprAzBNKhylCEqocO1gdfU5Iw6GX7'}}
Task was destroyed but it is pending!

重启。。

有这个API 的文档 能让我们详细看下吗

同求

没有


text:
Add config UrlMatcherInterface::class.

Q
A

Is bugfix?
✔

New feature?
❌

Breaks BC?
❌

Fixed issues
https://github.com/yiisoft/yii-db-migration/issues/76

That does NOT fix the core issue of https://github.com/yiisoft/yii-db-migration/issues/76

This is a bad idea. The problem is no here.

authors: Mister-42 terabytesoftw yiiliveext

repo: yiisoft/router-fastroute


text:
Pathinfo should not be decoded

In yii\web\Request::resolvePathInfo(), pathinfo has been decoded using urldecode(), which is similar in yii 1.x.
That would be an issue if the url path contains %2f.
For example a url path like /foo/GNU%2fLinux/bar, the pathinfo would become /foo/GNU/Linux/bar, which used for matching url rule.
This may cause some problem when routing.
The code for resolving PathInfo is coming from Zend Framework, but the urldecode behavior has been added later, described in https://code.google.com/p/yii/issues/detail?id=1309
Zend Framework also fixed the similar issue in http://framework.zend.com/issues/browse/ZF-11017
Here are some test cases in Zend Framework for reference:
https://github.com/zendframework/zf1/blob/master/tests/Zend/Controller/Request/HttpTest.php#L988

PSR-7 is now used so this issue is not actual.

authors: iodragon samdark

repo: yiisoft/yii-web


text:
Ja 0103

Q
A

Is bugfix?
no

New feature?
no

Breaks BC?
no

Tests pass?
--

Fixed issues
guide-ja updated

Thanks!

authors: samdark softark


text:
Yii2框架中的一个小问题，控制器action被加载两次的bug

这是我前几天在开发一个文章阅读统计功能时候发现的问题。当时我想做的是页面访问一次，数据库访问量+1，但是无意中我发现，每次刷新后，访问量居然增加2个。
初步以为模型被调用了2次，后来排查发现并不是。于是我用file_put_contents函数，随机写入文件发现，我的所有控制器action都被执行了两次。测试代码如下：
public function actionIndex()
 {
        file_put_contents(rand(10000,99999).'.txt','123');
        return $this->render('index');
 }

以上代码会生成两个文件。
后来我发现，每当我注释掉return $this->render('index');时候，问题就会被解决。所以我就去比对官方原始安装包和我的代码，发现只要我在layout的html代码里面的head中加上<link rel="icon" href="">并且其中的href值为空，那么控制器的action就会被加载两次，如果我给href加上一个链接值，那么控制器就没有问题。
这个问题，在发生错误时候，没有任何的报错，程序也运行的很好，只是在有些情况下会发现异常，比如我统计文章访问量。我想应该属于一个bug
还有一个注意点：当上面那个href值为空时候，只要控制器内有内容输出，比如echo 123或者var_dump，那么这个控制器加载两次的问题也不会发生。

adding that code will cause the browser to try loading the icon from the main URL so each time you load the page, the browser will access the same URL again to load the icon. that is why your action is called twice.

authors: cebe leyuxinsi


text:
enableClientValidation bug?

What steps will reproduce the problem?
\yii\widgets\ActiveForm::widget([
        'enableClientScript' => false,
        'enableClientValidation' => true
    ]);

What is the expected result?
Load client validation script, but not load additional scripts
What do you get instead?
Do not load client script validation at all.
Additional info
I use webpack and all yii scripts are disabled in assets. When enableClientScript is true, yii load all scripts and crashing my webpack files that include the same yii scripts.

Q
A

Yii version
2.0.12

PHP version
7.1

Operating system
Win 10

You need to override bundles in order to solve your case. Disabling client script won't help.

Thanks. I disabled scripts
        'assetManager' => [
            'bundles' => [
                'yii\web\YiiAsset' => false,
                'yii\validators\ValidationAsset' => false,
                'yii\web\JqueryAsset' => false,
                'yii\widgets\ActiveFormAsset' => false,
            ],
        ],

and make jquery globally in webpack
            {
                test: require.resolve('jquery'),
                use: [{
                    loader: 'expose-loader',
                    options: 'jQuery'
                }]
            }

It works for me.

authors: RSalo samdark


text:
$.pjax.reload reloads the whole page when url is specified and normalizeTrailingSlash is true

Hello everybody.
I have configs like this
 'urlManager' => [
...
            'normalizer' => [
                'class' => 'yii\web\UrlNormalizer',
                'collapseSlashes' => true,
                'normalizeTrailingSlash' => true,
            ],

I have the GridView via Pjax on the page.
    <?php Pjax::begin(['id' => 'any-pjax-container', 'timeout' => false]); ?>
    <?= GridView::widget([
        'dataProvider' => $dataProvider,
        'filterModel' => $searchModel,
... etc

Also I have $.pjax.reload fired on the some event.
// It reloads the whole page
$.pjax.reload("#any-pjax-container", {
    url: "/site/index?something=anything",
});

It reloads the whole page.
But if I pass the url with the trailing slash it works fine.
// It works fine
$.pjax.reload("#any-pjax-container", {
    url: "/site/index/?something=anything",
});

I have lost a lot of time to find the solution. Maybe it could be fixed in the framework.

Do you have any idea why that happens and how to fix it?

I think it because of pjax faces redirect when he tries to get content from the url. UrlNormalizer redirects request from /site/index?something=anything to /site/index/?something=anything

url: "/site/index?something=anything",

How did you get this URL? If your UrlManager is configured with trailing slash as suffix, you should get /site/index/?something=anything.

I typed it manually directly in my js. I didn't use Url::to or something.

Then it's not something that should be fixed on framework side.

authors: letstestcode rob006 samdark