text:
ZuulHandlerMapping Not Happening On Startup So First Request Super Slow

I think this is just a question because most likely we've got some poor config choice that's causing this.
Just a note to say thanks first: Zuul is amazing! : ) We absolutely love it. It works really well and was super easy to integrate with our existing cloud services.
Anyway on to the question/problem:
We're using docker (and compose) to containerise and deploy multiple services including the cloud services with Eureka as our service registry and Zuul of course as our gateway. All the services can find each other and everything goes to the right place via the gateway as expected. However, the first request to the gateway is super slow. We've seen similar threads complaining that this causes timeouts etc. and we've tried various things we've seen in those threads including altering the timeout settings (haphazardly with a bit of trial and error and you can see we've done this badly both in the application.properties file and from the fact that the output warns us it's a weird setup) and we overcame the timeout problems but this obviously didn't address the actual issue that the first request is so slow. We also saw that we could set ribbon eager loading, which we've tried but doesn't seem to have helped.
Here are the application.properties from the zuul spring boot project (we really haven't learned what we're doing with these properly yet): https://gist.github.com/bbk-pij-2012-22/d5bd22151b57c7258cfbccff786ad978
Here are the bootstrap.properties from the same project: https://gist.github.com/bbk-pij-2012-22/e159f7027f86541b27da131d0a5115bb
Here is the output from the gateway during the first request (not on app startup but once everything is running and we make the first request to the gateway): https://gist.github.com/bbk-pij-2012-22/06ed5c75cffc0bcde391c85d11e14288
So we can see in the output that the gateway is busy getting the services during the first request and we guessed that this is the cause of the delay but the eager loading property did not help us. There are quite a few other lines of output that we don't really understand.
Note: we are not using any defined routing to or ports for the services. All services are assigned a random port on registration with eureka and we expect Zuul to find the services by name when we hit the gateway with the extension (which it does).
So I guess the questions are:

Is there some config that we're missing to force the gateway to load these services at startup (if that's even the cause of the delay?
Are we hashing together settings in the application.properties that shouldn't go together/don't make sense?

Many thanks in advance and sorry for our lack of understanding.

Hi @bbk-pij-2012-22
Maybe my answer not help you solution your issues, but I will talk about my understanding.

First about your application.properties
I see in this properties you have hystrix and ribbon properties, I think this properties about the time out, so my suggestion is hystrix timeout should include all ribbon timeout(include all ribbon retry)

Second
I see you have a config ribbon.eager-load.enabled=true which in application.properties, this represents whether the ribbon is loaded at startup instead of loading at the time of the call. but I think you miss other properties, so I think correct is like this and could you please have a try and see what happen : )

ribbon:
  eager-load:
    enabled: true
    clients: client1, client2, client3. --- YOU MISS THIS ONE

I hope my answer can help you !
Thanks

Thanks for your reply @holy12345
Regarding point 1 - do you mean if I set the hystrix property it encompasses ribbon and so makes any ribbon properties I set redundant?
Regarding point 2 - I would prefer my gateway to know nothing about what services might be available to it via the registry until it starts up, specifically so that I don't have to specify any config that's specific to other services other than Eureka's location. Perhaps there is an option to load all at this point; I'll look into it and report back.
Thanks again

@bbk-pij-2012-22

First
My thought is Hystrix timeout should include ALL ribbon timeout, if you see the spring-cloud reference you can see those sentence

Hystrix Timeouts And Ribbon Clients
When using Hystrix commands that wrap Ribbon clients you want to make sure your Hystrix timeout is configured to be longer than the configured Ribbon timeout, including any potential retries that might be made. For example, if your Ribbon connection timeout is one second and the Ribbon client might retry the request three times, than your Hystrix timeout should be slightly more than three seconds.

Second
IF you not set ribbon.eager-load.clients properties, this application context is lazily loaded on the first request to the named client

Hope this can help you : )
Thanks

Comments understood; thanks. I am trying to find out now if I can eager load the clients without naming them.

I can't find the answer from searching. I'd be surprised if this wasn't possible. Does anyone know?

I think this is the property you want
http://cloud.spring.io/spring-cloud-static/Edgware.SR4/single/spring-cloud.html#_zuul_eager_application_context_loading

yes it needs the zuul prefix

Please see my pom dependencies; perhaps this will be useful.
https://gist.github.com/bbk-pij-2012-22/6f1217a38008379dd39969b7eb1d2c8a

I've got a sneaking feeling it's because my other services haven't finished starting up and so haven't checked in with eureka by the time zuul starts up. I can depends_on my services in the docker compose file but it only depends on them starting up, not being in a ready state.
hmm

I also only have the @EnableZuulProxy, @EnableEurekaClient and @SpringBootApplication annotations above my gateway application. Is @EnableDiscoveryClient needed? It seems to work without but maybe this would help me? I'm clutching at straws now..

HI @bbk-pij-2012-22
Is this problem solved?

Hi. I've not had a chance to try it again but I will do this weekend. Thanks for your patience

Ok so I tried it without docker and with prefixes above as discussed and the delay was still there on the first request.
I decided to also try it by fully booting all the services first and waiting until they're all checked in with the eureka registry before booting up the zuul app. I still get the same result. Zuul is clearly mapping the routes at the time of the request and not before.
Perhaps I have no choice but to define the routes manually in Zuul for now?

Thanks. I really appreciate the continued efforts to help.
Please could you tell me exactly what to provide so I don't just add lots of irrelevant spam for you.

Can you provide a complete, minimal, verifiable sample that reproduces the problem?  It should be available as a GitHub (or similar) project or attached to this issue as a zip file.

Several of our apps require a mysql and redis connection with specific credentials etc. I'd have to strip all of that out and hide some sensitive code. If that's really necessary and I can't just provide more specific logs/configuration then I can give it a go....

repo: spring-cloud/spring-cloud-netflix


text:
Add failing test

@mbogoevici  Not sure if this is an SCSt issue, a core Spring issue, or one of my brain farts. Would appreciate your assistance. Thanks

@dturanski We should have used AnnotatedElementUtils instead of AnnotationUtils. Will provide a PR with the test and the fix shortly.

source: gharchive/pull-request

authors: dturanski mbogoevici

repo: spring-cloud/spring-cloud-stream

license_type: permissive

license_source: bigquery


text:
What can I do for spring-authorization-server?

I want to do something for spring-authorization-server, what can I do?
I know what the OAuth2.0 is and I used the spring-security-oauth2 in my company code which create the new grant type.  I think maybe I can do something for spring-authorization-server.
I hope the spring-authorization-server release the code as soon as possible, because I don't want to use the deprecated code.

我觉得这个起码需要到 0.1.2 版本才可以使用，主要来源于 #245 这个实现，对于源码阅读多几次就会觉得其实没啥变化，使用难度不大，添加多几个过滤器，如果有问题或者不满足需要可以覆盖实现。

另外这个是开源~请把说词换一下。

@lanmingle 因为我这边在使用spring-security-oauth2的时候，遇到了一些不太好扩展的地方，所以如果有机会参与项目的话，借此机会对我遇到的问题进行优化。另外“请把说词换一下”指的是什么？我是希望对这个项目提供帮助，而非对个人的

@littlefisher666 The best place to start is Getting Started and Feature Planning outlines the feature roadmap.

source: gharchive/issue

authors: jgrandja lanmingle littlefisher666

license_source: github-api


text:
Add support for NVidia inference server

https://docs.nvidia.com/deeplearning/triton-inference-server/user-guide/docs/customization_guide/inference_protocols.html

Doesn't seem to be interest on the vmware/nvidia side, so closing for now.

repo: spring-projects/spring-ai


text:
Spring Insight for Tomcat

Not sure whether this query belongs here or not. If it doesnt, do let me know and I can move it to the right place.
Does anyone know how I can integrate Spring Insight with Tomcat 6? I have been trying to search for documentation throughout but cant find any. Any help would be really appreciated.
Thanks,

I set up my liferay followed the instructions mentioned above.Unfortunately tomcat was not able to find the classes. Can anyone provide a logical solution on Integrated tomcat with spring insight?

HI
       I have set up the application long back spring with tomcat if

you don't mind will provide that code base to you by tomorrow, May be it
will helpful to you.
Thanks,
Kiran B.
On Tue, Jan 13, 2015 at 11:54 AM, Adam Zhang notifications@github.com
wrote:

I set up my liferay followed the instructions mentioned
above.Unfortunately tomcat was not able to find the classes. Can anyone
provide a logical solution on Integrated tomcat with spring insight?
—
Reply to this email directly or view it on GitHub
https://github.com/spring-projects/spring-insight-plugins/issues/1#issuecomment-69700801
.

HI @anchlovi  Have you successed by following the instructions you provide? Imeet ClassNotFoundException.

Yes succeed based on the @anchlovi https://github.com/anchlovi
suggesstions
On Tue, Jan 13, 2015 at 5:37 PM, Adam Zhang notifications@github.com
wrote:

HI @anchlovi https://github.com/anchlovi Have you successed by
following the instructions you provide? Imeet ClassNotFoundException.
—
Reply to this email directly or view it on GitHub
https://github.com/spring-projects/spring-insight-plugins/issues/1#issuecomment-69735133
.

authors: StefanieLover anujgandharv bkiran

repo: spring-projects/spring-insight-plugins


text:
Add deliveryAttempt header

See INT-4369.

Waiting for SI code to be reviewed/merged.


text:
A question of OAuth2AccessToken in OAuth2

I read through the Java Interface of OAuth2AccessToken and find this content format doesn't match my following token format(I don't want to modify some oauth client codes, I need to make a compatible way ), My question here is that If I want to flexibly customize this format, how can I do that? Because it is solidly written in TokenEndpoint with ResponseEntity<OAuth2AccessToken> as the return result.
{
  "access_token": "eyJraWQiOiJrMTIzNCIsImVuY...",
  "token_type": "Bearer",
  "expires_in": 3600,
  "refresh_token": "Ccx63VVeTn2dxV7ovXXfLtAqLLERAH1Bc",
  "id_token": "eyJhbGciOiJIUzI1N..."
}

Hi,Have you found a solution? I also want to modify the response json format of TokenEndpoint.

@caryyu https://github.com/spring-projects/spring-security-oauth/issues/1521

@Renqiangme  I did find out a solution since the result is being serialized by AccessTokenJackson2Serializer, so I customized the token class, two core are:
OIDCAccessTokenJackson2Serializer
import com.fasterxml.jackson.core.JsonGenerator;
import com.fasterxml.jackson.databind.SerializerProvider;
import com.fasterxml.jackson.databind.ser.std.StdSerializer;
import org.springframework.security.oauth2.common.OAuth2AccessToken;
import org.springframework.security.oauth2.common.OAuth2RefreshToken;
import org.springframework.util.Assert;

import java.io.IOException;
import java.util.Date;
import java.util.Map;
import java.util.Set;

public class OIDCAccessTokenJackson2Serializer extends StdSerializer<OIDCAccessToken> {

    public OIDCAccessTokenJackson2Serializer() {
        super(OIDCAccessToken.class);
    }

    @Override
    public void serialize(OIDCAccessToken token, JsonGenerator jgen, SerializerProvider provider) throws IOException {
        jgen.writeStartObject();
        jgen.writeStringField(OIDCAccessToken.ACCESS_TOKEN, token.getValue());
        jgen.writeStringField(OIDCAccessToken.TOKEN_TYPE, token.getTokenType());

        if(token.getScope().contains(OIDCAccessToken.OPENID.toLowerCase()) ||
                token.getScope().contains(OIDCAccessToken.OPENID.toUpperCase())) {
            jgen.writeStringField(OIDCAccessToken.ID_TOKEN, token.getValue());
        }

        OAuth2RefreshToken refreshToken = token.getRefreshToken();
        if (refreshToken != null) {
            jgen.writeStringField(OAuth2AccessToken.REFRESH_TOKEN, refreshToken.getValue());
        }
        Date expiration = token.getExpiration();
        if (expiration != null) {
            long now = System.currentTimeMillis();
            jgen.writeNumberField(OAuth2AccessToken.EXPIRES_IN, (expiration.getTime() - now) / 1000);
        }
        Set<String> scope = token.getScope();
        if (scope != null && !scope.isEmpty()) {
            StringBuffer scopes = new StringBuffer();
            for (String s : scope) {
                Assert.hasLength(s, "Scopes cannot be null or empty. Got " + scope + "");
                scopes.append(s);
                scopes.append(" ");
            }
            jgen.writeStringField(OAuth2AccessToken.SCOPE, scopes.substring(0, scopes.length() - 1));
        }
        Map<String, Object> additionalInformation = token.getAdditionalInformation();
        for (String key : additionalInformation.keySet()) {
            jgen.writeObjectField(key, additionalInformation.get(key));
        }
        jgen.writeEndObject();
    }
}

OIDCAccessToken
import org.springframework.security.oauth2.common.DefaultOAuth2AccessToken;

@com.fasterxml.jackson.databind.annotation.JsonSerialize(using = OIDCAccessTokenJackson2Serializer.class)
public class OIDCAccessToken extends DefaultOAuth2AccessToken {
    /**
     * if the scope contains "openid" then this value is required
     */
    public static String ID_TOKEN = "id_token";

    public static String OPENID = "openid";

    public OIDCAccessToken(String value) {
        super(value);
    }
}

authors: Renqiangme caryyu

repo: spring-projects/spring-security-oauth


text:
Can we use springfox with springboot 3.1.4??  Or any version of springfox is compatible with springboot 3.1.4

Please take the time to search the repository, if your question has already been asked or answered.

[x] What version of the library are you using? Is it the latest version? The latest released version is

What kind of issue is this?

[x] Question. Is this a question about how to do a certain thing?

[ ] Bug report. If you’ve found a bug, spend the time to write a failing test. Bugs with tests or
steps to reproduce get fixed faster. Here’s an example: https://gist.github.com/swankjesse/6608b4713ad80988cdc9

[ ] spring xml/java config that is relevant
[ ] springfox specific configuration if it makes sense
[ ] include any output you've received; logs, json snippets etc.; and what the expected output should be
[ ] if you have a repo that demonstrates the issue for bonus points! See this example

[ ] Feature Request. Start by telling us what problem you’re trying to solve. Often a solution
already exists! Don’t send pull requests to implement new features without first getting our
support. Sometimes we leave features out on purpose to keep the project small.

Please do consider starring this repository if you do like this project and find it useful.

My springfox version is 3.0.0 ang spring boot is 3.1.4

Use https://springdoc.org/ instead.

repo: springfox/springfox


text:
chore: add module entry to package.json

Hello,
I've replaced  jsnext:main entry with module so it can work with rollup bundler.
Rollup seems to not use jsnext:main and was using the umd build.
it's probably safe to use module now since webpack use "module" too

And could you please also rebase onto master? Cheers!

@ryami333 thanks for your reply ! I've updated my branch and revert the "jsnext:main"

Looks good, thanks @lionelB. I'll give it a bit of a test before it goes into the next release, likely to be 3.0.1.

repo: springload/react-accessible-accordion

license: mit


text:
Implement an ability of sending messages to the multi-user chat

Before these changes, it was impossible to send message in address of room/group.
This PR is intended to improve situation by applying minor changes to the smack.scala.Client and introducing a new message type - Messages.SendMultiUserMessage(room, message).

can you add a test to ClientTest for this please?

Sure

looks like your formatter messed up a lot of the codebase in that last commit - can you have a look and only format what you actually added? if there is a need to format the rest of the codebase, that should be a separate commit.
also, you committed a config change to 'localhost', which means that CI won't be able to run it.

I've reverted the config and the formatting for the code what was not directly affected by my changes. Is it okay know?

authors: mpollmeier nikelin

repo: springnz/smack-scala


text:
Material 3 version

Currently using M2-specific style. Factor out common usage and build M2 and M3 components

Completed in 756485b

repo: sproctor/compose-data-table


text:
🛑 Mitgliederdatenbank is down

In 1e96847, Mitgliederdatenbank (https://login.sp-ps.ch/tocco) was down:

HTTP code: 503
Response time: 794 ms

Resolved: Mitgliederdatenbank is back up in 9e5d916 after 6 minutes.

repo: spschweiz/status

license: MIT


text:
Question about services not covered by moto

This is not an issue, it's only a question about a service not covered by moto.
For example, for the AWS service Access Analyzer which is not covered what is the intended way to mock a client for that service?
Is there any way in moto to mock the session module?
Thanks!

Hi @jfagoagas! There's no builtin way to mock services that are not covered.
Personally I just use the standard patch in these scenarios - if you intercept the boto3-calls at the right time, you can decide whether you want to mock this call manually, or want Moto to intercept this.
Example:
import boto3
import botocore
from unittest.mock import patch

orig = botocore.client.BaseClient._make_api_call
def mock_make_api_call(self, operation_name, kwarg):
    if operation_name == 'ListFindings':
        # Your Operation here!
        return True
    return orig(self, operation_name, kwarg)

def test_list_findings():
    client = boto3.client("accessanalyzer")

    with patch('botocore.client.BaseClient._make_api_call', new=mock_make_api_call):
        resp = client.list_findings(analyzerArn="asdfasdfasdf")
        assert resp == True

Note that this does not use Moto, to keep it simple, but:
If you use any moto-decorators in addition to the patch, the call to orig(self, operation_name, kwarg) will be intercepted by Moto.

AWESOME @bblommers !! Thanks for your guidance ❤

Happy to help @jfagoagas! I'll close this, but let me know if you have any other questions.

Hi @bblommers, I was thinking about the piece of code you shared and I think it could be really useful for other users to have this into the moto documentation.
Can I make a PR with that? I have tests for the Access Analyzer API, something like a little guidance like the where to patch or the pesky imports.
What do you think?
Thanks!

Makes sense @jfagoagas - this question comes up fairly often, so having it documented would be useful.
Can you add it to the Implemented Services-section? That would make most sense IMO, so that the menu looks like this:
Implemented Services
Implemented Services
Patching other Services
Contributing to Moto
...

Thanks @bblommers, yes make sense including it there.

authors: bblommers jfagoagas

repo: spulec/moto


text:
Error with jedi 0.9.0

Description of your problem
It is not a problem, maybe a bug
What steps will reproduce the problem?

Launch spyder 3 gives me an error due to jedi

What is the expected output? What do you see instead?
Spyder3 runs correctly but with the advertisement of jedi dependencies
Please provide any additional information below
Versions and main components

Spyder Version: 3.1.3 installed with "pip install -U spyder"
Python Version: 3.6.1 x86
Qt Version: 5.8 installed with "pip3 install pyqt5"
PyQt Version: 5.8.2 installed with "pip3 install pyqt5"
Operating system: Windows 7 x64

Dependencies
The problem is that after use "pip install -U spyder" the system don't use the last version of ipython, so the spyder don't start. After update ipython, spyder runs correctly but with the advertisement of jedi, due to the update of ipython updates jedi
If I install jedi 0.9.0, spyder don't run, but with 0.10.2 runs correctly but wit the advertisement.

Why it doesn't run with 0.9?

I reinstall jedi 0.9.0. The error are:
raise VersionConflict(dist, req).with_context(dependent_req)pkg_resurces.VersionConflict: (jedi 0.9.0 (c:....), Requirement.parse('jedi>=0.10'))
Maybe python 3.6.1, needs jedi 0.10
I don't know, but with jedi updated works fine (with the advertisemnet).
Thanks for your software, it is great!

This advertisement is due in the dependencies list of spyder 3.1.3, all the packages have a >=...and only jedi needs a specific package version.

new IPython 6.0.0 requires jedi>=0.10

Thanks @romanet for the clarification.
Spyder 3.1.4 will be compatible with Jedi 0.10+ and it'll be released this weekend.

@GermanRR, Spyder 3.1.3 is only compatible with Jedi 0.9, that's the reason of us requiring that specific version.

authors: GermanRR ccordoba12 romanet

repo: spyder-ide/spyder


text:
Automatic error report

<!---   *** BEFORE SUBMITTING: PASTE CLIPBOARD HERE TO COMPLETE YOUR REPORT ***   ---!>

No comment


text:
WIP: Add the option to set two keybinds per shortcut in preferences

Description of Changes

[x] Wrote at least one-line docstrings (for any new functions)
[ ] Added unit test(s) covering the changes (if testable)

Issue(s) Resolved

Fixes #10808
Fixes #10787
Affirmation
By submitting this Pull Request or typing my (user)name below,
I affirm the Developer Certificate of Origin
with respect to all commits and content included in this PR,
and understand I am releasing the same under Spyder's MIT (Expat) license.

I certify the above statement is true and correct:

@ccordoba12 I've salvaged the POC I presented in https://github.com/spyder-ide/spyder/issues/10787#issuecomment-558242185 and finally managed to make a PR out of it.
So in the preference, it is now possible to fetch and save 1 or 2 keysequences per shortcut. It would be very easy to increase the number of keysequences supported per shortcut if needed in the future. I just need to add a test to cover these changes.
However, I have only covered the Spyder "preferences" side of this work. Do you think either you or @goanpeca could take this PR over and finish the implementation of this functionality on the spyder main window and plugin side? I don't feel comfortable doing it.

Sure thing! I can help :-)

Sure thing! I can help :-)

Ok that is excellent. So (1) let me add a test, (2) then maybe you could review the work done, and (3) then take over for refactoring the parts in Spyder that handle shortcuts.

Sure thing. Ping me then ;-)

authors: goanpeca jnsebgosselin


text:
XAML support

Is there a way I can use XAML with JSIL? I am creating a C# to HTML5 GUI framework and would like it to be usable with XAML. Currently, layouts can be built like this:

    public class MainForm : WebForm
    {
        public MainForm()
        {
			Controls = new Layout()
        	{
        		new TextBlock()
	            {
					Text = "SharpJS WebForms Demo",
					FontStyle = new FontStyle()
					{
						FontSize = 24,
						FontWeight = JSIL.Dom.Styles.FontWeight.Bold
					},
					TextAlign = JSIL.Dom.Styles.TextAlign.Center,
				},
        		new TextBlock()
        		{
        			Text = "Enter some text:",
        		},
        		new TextBox(),
        		new Button()
        		{
        			Text = "OK",
        		},
			};
        }
    }

I want to be able to specify this instead:

<WebForm x:Class="WebFormsTemplate.MainWFForm"
	xmlns="clr-namespace:ExaPhaser.WebForms;assembly=ExaPhaser.WebForms"
	xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
	xmlns:controls="clr-namespace:ExaPhaser.WebForms.Controls;assembly=ExaPhaser.WebForms">
	<WebForm.Controls>
		<controls:TextBlock Text="Hello, World!" />
	</WebForm.Controls>
</WebForm>

Does anyone know how I can implement this?
Please do not mention CSHTML5, as it is closed source and my project is open source.

The body of your issue seems to be mangled.
One option for XAML would be to feed the XAML through the normal MS build pipeline and translate the managed code their compiler generates. Not sure how hard that would be, though...

I currently tried referencing System.Xaml, but this references all the PresentationFramework and PresentationCore assemblies, which do not seem to decompile well with JSIL. I guess I'll try writing a custom implementation or something.

I have, however, been having trouble with the dynamic keyword. Is there anything special I should do when using dynamic with JSIL, like the DynamicAttribute or something?

Yeah, I think at present you wouldn't want to cross-compile the implementation. Just cross-compile the code generated by the compiler from your XAML files. This is similar to what is done for XML Serializer assemblies.

Is there a way I can use XAML without referencing PresentationCore and PresentationFramework? These aren't necessary but my compiler insists that I reference them.

@0xFireball. have you looked on Fayde projects? They implement XAML in html on top of canvas. It  would be great if somebody would implement bindings to it, and it would be great if they will be wpf/silverlight compatible.

@0xFireball, could you describe what type of problems do you have with dynamic?

Also it may worth to look on https://github.com/Perspex/Perspex, it should be much easier to port it to be used with JSIL.

Thanks! I'm trying to make an open source alternative to CSharp/Xaml for Html5

I resolved the issue with dynamic. Sorry about that, it was bad implementation on my part.

Hello,
if this is still relevant, I succeeded in creating a usable UI framework built upon JSIL!
https://github.com/exaphaser/SharpJS
After writing the UI framework, I wrote another library (It's in the repo too that would allow users to port WinForms projects to the web.)
It's obviously not production ready at the moment (I didn't spend that much time on it), but it's a start
for a compatibility layer for WinForms. At the moment, you still have to recompile the project to
reference my WinFormsCompat lib (or you could hack the assembly).
I also made C# bindings for some of jQuery (as much as the whole framework needed, I might add more)
and WebSockets, AJAX, JS Buffers, Printing, Blob saving, and uploading.
I paused development a couple months ago, but I'm restarting development again. This time, I'm going
to improve the UI framework and maybe try adding some XAML-inspired UI.
I'm looking at Fayde for ideas for now.
The extensions are licensed under GPLv3 in the repository, but if a merge would help JSIL, I would be delighted to give the changes back to JSIL under the MIT license. Just please let me know.

Unfortunately I messed up massively with Git, and that repo does not share a history with JSIL :( and I had to manually merge changes. That was a big mistake, but I don't want to lose my own commit history now. If anyone has a solution please let me know.

Worst case you could generate a single massive merge commit (ugh) by doing a diff of the whole tree against JSIL. Maybe then you could split the commit up into logical chunks.

authors: 0xFireball iskiselev kg

repo: sq/JSIL


text:
Bug Photino.Native DllNotFoundException

Hello,
I use an Azure Remote Desktop to run Power BI Desktop. I have installed Bravo on my remote desktop but I receive the following error when I try to run it:
System.DllNotFoundException: Unable to load DLL 'Photino.Native' or one of its dependencies: The specified module could not be found. (0x8007007E)
at PhotinoNET.PhotinoWindow.Photino_register_win32(IntPtr hInstance)
at PhotinoNET.PhotinoWindow.<>c.<.ctor>b__238_0()
at PhotinoNET.PhotinoWindow.Invoke(Action workItem)
at PhotinoNET.PhotinoWindow..ctor(PhotinoWindow parent)
at Sqlbi.Bravo.Infrastructure.AppWindow.CreateWindow() in D:\a\1\s\src\Infrastructure\AppWindow.cs:line 58
at Sqlbi.Bravo.Infrastructure.AppWindow..ctor(IHost host, AppInstance instance) in D:\a\1\s\src\Infrastructure\AppWindow.cs:line 35
at Sqlbi.Bravo.Program.Main() in D:\a\1\s\src\Program.cs:line 25

Duplicate of #225

Hi @evnpresson, please see my response to https://github.com/sql-bi/Bravo/issues/225#issuecomment-1083064111 as the same applies here.

authors: albertospelta danieleperilli evnpresson

repo: sql-bi/Bravo


text:
Test-DbaLastBackup - SQL Server cannot process this media family

Bug Report
Test-DbaLastBackup doesn't have LiteSpeed restore functionality (or Ola using Litespeed)
General Troubleshooting steps

[ x] Verified running latest release of dbatools?
[ x] Verified errors are not related to permissions?
[x ] Can duplicate in new/fresh PowerShell.exe session?

Version Information

Operating System (Name|Version): win 2012 r2
PowerShell Version: 4
SQL Server (Edition|Version): source 2016, dest 2008r2 (but will be done on all version)

Steps to Reproduce
Test-DbaLastBackup -SqlInstance '(source),port' -Destination '(destination),port' -DataDirectory S:\Data -LogDirectory T:\TLog
At line:171 char:21

                $datatable = $restore.ReadBackupHeader($server)

                ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Microsoft.SqlServer.Management.Common.ExecutionFailureException: An exception occurred while executing a Transact-SQL statement or batch. ---> System.Data.SqlClient.SqlException: The media family on device '(path and database name)_Full_2017-09-13-170505.bak' is incorrectly formed. SQL Server cannot process this media family.
RESTORE HEADERONLY is terminating abnormally.
at Microsoft.SqlServer.Management.Common.ConnectionManager.ExecuteTSql(ExecuteTSqlAction action, Object execObject, DataSet fillDataSet, Boolean catchException)
at Microsoft.SqlServer.Management.Common.ServerConnection.ExecuteWithResults(String sqlCommand)
--- End of inner exception stack trace ---
at Microsoft.SqlServer.Management.Common.ServerConnection.ExecuteWithResults(String sqlCommand)
at Microsoft.SqlServer.Management.Smo.ExecutionManager.ExecuteWithResults(String query)
at Microsoft.SqlServer.Management.Smo.BackupRestoreBase.ExecuteSqlWithResults(Server server, String cmd)
at Microsoft.SqlServer.Management.Smo.Restore.ReadBackupHeader(Server srv)
at CallSite.Target(Closure , CallSite , Object , Object )
Feature Request
I would like to be able to test restores of Litespeed backups.
I have some litespeed backups and some Ola backups.  It would be great if the script could handle either dynamically.
Here is what a litespeed restore script looks, if it helps:
exec master.dbo.xp_restore_database @database = N'(dbname)' ,
@filename = N'(path)(dbname)_Full_2017-09-13-170505.bak',
@filenumber = 1,
@with = N'STATS = 10',
@affinity = 0,
@logging = 0

I as able to tell the issue is on line 171 in Read-DbaBackupHeader.ps1.
$datatable = $restore.ReadBackupHeader($server)
It can't read the backup header of the Litespeed backup.  I'm sure the related restore must be different too.

Yes. Litespeed use their own proprietary format for backups and a compiled
dll via an xp stored procedure to do anything with them.
Last time I checked they didn't have a powershell implementation either.
So we'd need to write lots of string mangling code and invoke-sqlcmd2
statements.
Plus someone would have to provide us with a litespeed license for testing
:)
On Fri, 15 Sep 2017 at 15:42, cabana1 notifications@github.com wrote:

I as able to tell the issue is on line 171 in Read-DbaBackupHeader.ps1.
$datatable = $restore.ReadBackupHeader($server)
It can't read the backup header of the Litespeed backup. I'm sure the
related restore must be different too.
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
https://github.com/sqlcollaborative/dbatools/issues/2232#issuecomment-329802610,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AFWoZoD-hdhf2UJWeb2oJP2yz5W6iZg1ks5siozcgaJpZM4PXsTY
.

@cabana1 At this time we are not supporting 3rd party backup tools. LS is one that creates a proprietary backup format unlike others so we cannot provide any test/sandbox environment to develop. As well, we would not be able to perform any integration testing against it using Appveyor.
Licensing wise with LS you can restore a backup without purchasing any licenses, just have to install LS to have the procs and DLLs available. However, to perform the backup for testing a restore, does require licensing.

authors: Stuart-Moore cabana1 wsmelton

repo: sqlcollaborative/dbatools


text:
currentdb in connect-dbainstance

try again with connectioncontext.getdatabaseconnection
so far, this is not evaluating
            if ($instance.InputObject.ConnectionContext.IsOpen) {
                $currentdb = $instance.InputObject.ConnectionContext.ExecuteScalar("select db_name()")
                if (($Database -and ($Database -eq $currentdb))) {
                    $instance.InputObject
                    continue
                }
            }

okay turns out to get the db connection in Azure, Get-DbaDatabase is surprisingly effective 👍  No changes at this time.


text:
Backup dbadatabase compression

Fixes #
Changes proposed in this pull request:
Backup-DbaDatabase now supports

Compression

-lt 2008 - go away
-eq 2008

-eq Enterprise - Let's do it
-ne Enterprise - go away

-ge 2008R2 - let's do it
-like 'express' - go away

Checksum
Verfiy

How to test this code:

[ ]
[ ]

Has been tested on minimum requirements:

[ ]  Powershell 3
[ ]  Windows 7
[ ]  SQL Server 2000

Has been tested on maximum requirements:

[ ]  SQL Server vNext
[ ]  Windows 10
[ ]  Azure Database

Tests for tester:

[ ] Working/useful help content, including link to command on dbatools web site
[ ] All examples work as advertised
[ ] Does not contain template content
[ ] Does not contain excessive/unnecessary amounts of comments
[ ] Works remotely
[ ] Works locally
[ ] Works on lower versions or throws error specifying version not supported
[ ] Works with named instances
[ ] Works with clustered instances
[ ] Handles offline/read only databases
[ ] Supports multiple servers (at the command line or piped from Get-SqlRegisteredServerName)
[ ] No un-handled errors which stop the command working with multiple servers

Arse, crossed the streams between this one and 922 (was trying to keep the files seperate).
If both get accepte, merge the other one (922) first as it's got the most changes on Restore-DbaDatabase. So if the 2nd merge barfs it's only 1 line to fix


text:
Format SQL query

Add a button to format queries in the query box https://www.npmjs.com/package/sql-formatter

I suggest also a keybind for that, also, TablePlus has 'command + i' for beautify and 'command + shift + i' for minify, which I been finding super useful specially for one-liners, when I'm exploring queries in the client and then want to paste on my other code

authors: betafcc maxcnunes

repo: sqlectron/sqlectron-gui


text:
Support trailing commas

BigQuery supports trailing commas in a SELECT statement.
ref.  https://cloud.google.com/bigquery/docs/reference/standard-sql/lexical#trailing_commas

Pull Request Test Coverage Report for Build 2812898923

24 of 26 (92.31%)  changed or added relevant lines in 2 files are covered.
4 unchanged lines in 1 file lost coverage.
Overall coverage decreased (-0.03%) to 89.919%

Changes Missing Coverage
Covered Lines
Changed/Added Lines
%

src/parser.rs
14
16
87.5%

Files with Coverage Reduction
New Missed Lines
%

src/parser.rs
4
83.29%

Totals

Change from base Build 2805421159:
-0.03%

Covered Lines:
9116

Relevant Lines:
10138

💛  - Coveralls

authors: coveralls komukomo

repo: sqlparser-rs/sqlparser-rs


text:
I use rxjava2+retrofit2+okhttp3 in my android application and get crashed when app not connected to internet

Here is my sendHttpRequest mothed in BaseActivity:
  public <T> Disposable sendHttpRequest(Observable<Response<T>> observable, final GolfRequestCallback<T> requestCallback) {
        Disposable httpSubscribe = observable.compose(TransformerHelper.<Response<T>>io_main()).doOnSubscribe(new Consumer<Disposable>() {
            @Override
            public void accept(@io.reactivex.annotations.NonNull Disposable disposable) throws Exception {
                requestCallback.onBefore();
            }
        }).doOnError(new Consumer<Throwable>() {
            @Override
            public void accept(@io.reactivex.annotations.NonNull Throwable throwable) throws Exception {
                requestCallback.onAfter();
                requestCallback.onError(throwable);
            }
        }).doOnComplete(new Action() {
            @Override
            public void run() throws Exception {
                requestCallback.onAfter();
            }
        }).subscribe(new Consumer<Response<T>>() {
            @Override
            public void accept(@io.reactivex.annotations.NonNull Response<T> response) throws Exception {
                try {
                    requestCallback.onAfter();
                    if (response.isSuccess()) {
                        requestCallback.onSuccess(response.data, response.msg);
                    } else {
                        if ("mid_error".equals(response.code)) {
                            AccountUtils.INSTANCE.loginOut();
                            LoginActivity.startActivity(BaseActivity.this);
                        }
                        requestCallback.onBizErr(response.code, response.msg);
                    }
                } catch (Exception e) {
                    e.printStackTrace();
                }
            }
        }, new Consumer<Throwable>() {
            @Override
            public void accept(@io.reactivex.annotations.NonNull Throwable throwable) throws Exception {
                throwable.printStackTrace();
            }
        });
        return httpSubscribe;
    }

##Log
io.reactivex.exceptions.OnErrorNotImplementedException: failed to connect to /192.168.20.122 (port 8888) after 10000ms
09-29 10:54:18.151 16007-16007/com.tiemagolf W/System.err:     at io.reactivex.internal.functions.Functions$OnErrorMissingConsumer.accept(Functions.java:704)
09-29 10:54:18.151 16007-16007/com.tiemagolf W/System.err:     at io.reactivex.internal.functions.Functions$OnErrorMissingConsumer.accept(Functions.java:701)
09-29 10:54:18.151 16007-16007/com.tiemagolf W/System.err:     at io.reactivex.internal.observers.LambdaObserver.onError(LambdaObserver.java:74)
09-29 10:54:18.151 16007-16007/com.tiemagolf W/System.err:     at io.reactivex.internal.operators.observable.ObservableDoOnEach$DoOnEachObserver.onError(ObservableDoOnEach.java:119)
09-29 10:54:18.151 16007-16007/com.tiemagolf W/System.err:     at io.reactivex.internal.observers.DisposableLambdaObserver.onError(DisposableLambdaObserver.java:64)
09-29 10:54:18.151 16007-16007/com.tiemagolf W/System.err:     at io.reactivex.internal.operators.observable.ObservableObserveOn$ObserveOnObserver.checkTerminated(ObservableObserveOn.java:276)
09-29 10:54:18.151 16007-16007/com.tiemagolf W/System.err:     at io.reactivex.internal.operators.observable.ObservableObserveOn$ObserveOnObserver.drainNormal(ObservableObserveOn.java:172)
09-29 10:54:18.151 16007-16007/com.tiemagolf W/System.err:     at io.reactivex.internal.operators.observable.ObservableObserveOn$ObserveOnObserver.run(ObservableObserveOn.java:252)
09-29 10:54:18.151 16007-16007/com.tiemagolf W/System.err:     at io.reactivex.android.schedulers.HandlerScheduler$ScheduledRunnable.run(HandlerScheduler.java:109)
09-29 10:54:18.151 16007-16007/com.tiemagolf W/System.err:     at android.os.Handler.handleCallback(Handler.java:739)
09-29 10:54:18.151 16007-16007/com.tiemagolf W/System.err:     at android.os.Handler.dispatchMessage(Handler.java:95)
09-29 10:54:18.151 16007-16007/com.tiemagolf W/System.err:     at android.os.Looper.loop(Looper.java:135)
09-29 10:54:18.151 16007-16007/com.tiemagolf W/System.err:     at android.app.ActivityThread.main(ActivityThread.java:5314)
09-29 10:54:18.151 16007-16007/com.tiemagolf W/System.err:     at java.lang.reflect.Method.invoke(Native Method)
09-29 10:54:18.151 16007-16007/com.tiemagolf W/System.err:     at java.lang.reflect.Method.invoke(Method.java:372)
09-29 10:54:18.151 16007-16007/com.tiemagolf W/System.err:     at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:898)
09-29 10:54:18.151 16007-16007/com.tiemagolf W/System.err:     at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:693)
09-29 10:54:18.151 16007-16007/com.tiemagolf W/System.err: Caused by: java.net.SocketTimeoutException: failed to connect to /192.168.20.122 (port 8888) after 10000ms
09-29 10:54:18.152 16007-16007/com.tiemagolf W/System.err:     at libcore.io.IoBridge.connectErrno(IoBridge.java:169)
09-29 10:54:18.152 16007-16007/com.tiemagolf W/System.err:     at libcore.io.IoBridge.connect(IoBridge.java:122)
09-29 10:54:18.152 16007-16007/com.tiemagolf W/System.err:     at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:183)
09-29 10:54:18.152 16007-16007/com.tiemagolf W/System.err:     at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:456)
09-29 10:54:18.152 16007-16007/com.tiemagolf W/System.err:     at java.net.Socket.connect(Socket.java:882)
09-29 10:54:18.152 16007-16007/com.tiemagolf W/System.err:     at okhttp3.internal.platform.AndroidPlatform.connectSocket(AndroidPlatform.java:69)
09-29 10:54:18.152 16007-16007/com.tiemagolf W/System.err:     at okhttp3.internal.connection.RealConnection.connectSocket(RealConnection.java:238)
09-29 10:54:18.152 16007-16007/com.tiemagolf W/System.err:     at okhttp3.internal.connection.RealConnection.connectTunnel(RealConnection.java:210)
09-29 10:54:18.152 16007-16007/com.tiemagolf W/System.err:     at okhttp3.internal.connection.RealConnection.connect(RealConnection.java:152)
09-29 10:54:18.152 16007-16007/com.tiemagolf W/System.err:     at okhttp3.internal.connection.StreamAllocation.findConnection(StreamAllocation.java:256)
09-29 10:54:18.152 16007-16007/com.tiemagolf W/System.err:     at okhttp3.internal.connection.StreamAllocation.findHealthyConnection(StreamAllocation.java:134)
09-29 10:54:18.152 16007-16007/com.tiemagolf W/System.err:     at okhttp3.internal.connection.StreamAllocation.newStream(StreamAllocation.java:113)
09-29 10:54:18.152 16007-16007/com.tiemagolf W/System.err:     at okhttp3.internal.connection.ConnectInterceptor.intercept(ConnectInterceptor.java:42)
09-29 10:54:18.152 16007-16007/com.tiemagolf W/System.err:     at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:147)
09-29 10:54:18.152 16007-16007/com.tiemagolf W/System.err:     at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:121)
09-29 10:54:18.152 16007-16007/com.tiemagolf W/System.err:     at okhttp3.internal.cache.CacheInterceptor.intercept(CacheInterceptor.java:93)
09-29 10:54:18.152 16007-16007/com.tiemagolf W/System.err:     at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:147)
09-29 10:54:18.152 16007-16007/com.tiemagolf W/System.err:     at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:121)
09-29 10:54:18.152 16007-16007/com.tiemagolf W/System.err:     at okhttp3.internal.http.BridgeInterceptor.intercept(BridgeInterceptor.java:93)
09-29 10:54:18.152 16007-16007/com.tiemagolf W/System.err:     at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:147)
09-29 10:54:18.152 16007-16007/com.tiemagolf W/System.err:     at okhttp3.internal.http.RetryAndFollowUpInterceptor.intercept(RetryAndFollowUpInterceptor.java:125)
09-29 10:54:18.152 16007-16007/com.tiemagolf W/System.err:     at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:147)
09-29 10:54:18.152 16007-16007/com.tiemagolf W/System.err:     at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:121)
09-29 10:54:18.152 16007-16007/com.tiemagolf W/System.err:     at com.tiemagolf.api.GolfHeaderInterceptor.intercept(GolfHeaderInterceptor.java:44)
09-29 10:54:18.152 16007-16007/com.tiemagolf W/System.err:     at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:147)
09-29 10:54:18.152 16007-16007/com.tiemagolf W/System.err:     at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:121)
09-29 10:54:18.152 16007-16007/com.tiemagolf W/System.err:     at okhttp3.RealCall.getResponseWithInterceptorChain(RealCall.java:200)
09-29 10:54:18.152 16007-16007/com.tiemagolf W/System.err:     at okhttp3.RealCall.execute(RealCall.java:77)
09-29 10:54:18.152 16007-16007/com.tiemagolf W/System.err:     at retrofit2.OkHttpCall.execute(OkHttpCall.java:180)
09-29 10:54:18.152 16007-16007/com.tiemagolf W/System.err:     at retrofit2.adapter.rxjava2.CallExecuteObservable.subscribeActual(CallExecuteObservable.java:41)
09-29 10:54:18.153 16007-16007/com.tiemagolf W/System.err:     at io.reactivex.Observable.subscribe(Observable.java:10903)
09-29 10:54:18.153 16007-16007/com.tiemagolf W/System.err:     at retrofit2.adapter.rxjava2.BodyObservable.subscribeActual(BodyObservable.java:34)
09-29 10:54:18.153 16007-16007/com.tiemagolf W/System.err:     at io.reactivex.Observable.subscribe(Observable.java:10903)
09-29 10:54:18.153 16007-16007/com.tiemagolf W/System.err:     at io.reactivex.internal.operators.observable.ObservableSubscribeOn$SubscribeTask.run(ObservableSubscribeOn.java:96)
09-29 10:54:18.153 16007-16007/com.tiemagolf W/System.err:     at io.reactivex.Scheduler$DisposeTask.run(Scheduler.java:452)
09-29 10:54:18.153 16007-16007/com.tiemagolf W/System.err:     at io.reactivex.internal.schedulers.ScheduledRunnable.run(ScheduledRunnable.java:61)
09-29 10:54:18.153 16007-16007/com.tiemagolf W/System.err:     at io.reactivex.internal.schedulers.ScheduledRunnable.call(ScheduledRunnable.java:52)
09-29 10:54:18.153 16007-16007/com.tiemagolf W/System.err:     at java.util.concurrent.FutureTask.run(FutureTask.java:237)
09-29 10:54:18.153 16007-16007/com.tiemagolf W/System.err:     at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:152)
09-29 10:54:18.153 16007-16007/com.tiemagolf W/System.err:     at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:265)
09-29 10:54:18.153 16007-16007/com.tiemagolf W/System.err:     at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1112)
09-29 10:54:18.153 16007-16007/com.tiemagolf W/System.err:     at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:587)
09-29 10:54:18.153 16007-16007/com.tiemagolf W/System.err:     at java.lang.Thread.run(Thread.java:818)

you didn't implement exceptions for RxJava
Socket Timeout

Network errors are a certainty when writing mobile apps, and if you're consuming them with RxJava then you need to provide an error handler. See: https://github.com/ReactiveX/RxJava/wiki/Error-Handling.

Thanks, I have solved this problem.

I have the same problem.How to solve

I have the same problem.How to solve

repo: square/okhttp


text:
please allow GET request can go with the request body

please allow GET request can go with the request body

IIRC the spec isn’t definitive here. But in practice this is problematic with both proxies and servers and not generally supported. OkHttp tries to make the typical sensible use cases straight forward and avoid being a low level toolkit that enables making arguably invalid requests.

authors: heart yschimke


text:
Added documentation #2050

#2050 Added a one liner for the overriding of the Content-Length header.

Thanks! Please rebase and squash. http://rebaseandsqua.sh!

Rebase and squashing done. Thanks.

Merged manually. Note that I tweaked your copy & formatting. In particular I dropped the word 'compression' because OkHttp doesn't do request compression out of the box, and your copy slightly suggests that. (We do do response compression, so we have to be careful not to confuse our users!)

Ok. Thanks for the correction.


text:
Remove Content-Length in MultipartRequest Bodies

Solves #2604.
This removes the Content-Length header in a part of a multipart request.
I've tested with Chrome and it doesn't add the Content-Length header.

That issue is not open.

Closing - the linked issue has workarounds to fix this for servers that are incorrectly rejecting this.

Closing - the linked issue has workarounds to fix this for servers that are incorrectly rejecting this.

@JakeWharton, thanks for the response. I've updated the description with a new issue describing my case, which is slightly different than the one in the previous closed issue.

Are you able to run vanilla OkHttp with the rewritten MultipartBody class from your project?
Unless there is a specific opinionated decision to make this change, I think having your own MultipartBody is probably the correct workaround here for a faulty server.

authors: JakeWharton sdandois yschimke


text:
java.lang.ClassCastException in ExpandColumnNamesWildcardQuickFix.kt:22

Error in SQL Delight IntelliJ Plugin
java.lang.ClassCastException in ExpandColumnNamesWildcardQuickFix.kt:22
org.jetbrains.plugins.groovy.lang.psi.impl.GroovyFileImpl cannot be cast to com.squareup.sqldelight.core.lang.SqlDelightFile
View on Bugsnag
Stacktrace
ExpandColumnNamesWildcardQuickFix.kt:22 - com.squareup.sqldelight.intellij.intentions.ExpandColumnNamesWildcardQuickFix.isAvailable

View full stacktrace
Created automatically via Bugsnag

@Egorand
looks like the quickfix is somehow appearing in groovy files?

I think this is coming from me. It happens when I open a file and that click somewhere in that file. The groovy file was a build.gradle file. It also happens to regular Kotlin and Java files.

got it. We probably just need to ignore non-sq files.

authors: AlecStrong gabrielittner square-clippy

repo: square/sqldelight


text:
Insert default values fix

Closes #268

lgtm

authors: AlecStrong JakeWharton


text:
修改摘要的关键词不应该首行缩进问题

改成这样就行  \par\noindent 加上这个 \par针对当前段落  \noindent 取消首行缩进
\input{abstract.cfg}
% 中文摘要
\begin{titlepage}
\begin{spacing}{1.05}
\centering
\parbox[c]{.6\textwidth}{\thesistitlefont{\thesistitle}}
\end{spacing}
\begin{spacing}{1.6}
    \centering
    \sanhao\quad{} \\
    \abszhname{摘\quad{}要} \\
    \xiaosanhao\quad{}
\end{spacing}

\normalsize

\abstractcn

\quad{}

\par\noindent\abszhkey{关键词}\quad{}%
\abszhkeys{\abscnkeyone\quad{}%
\abscnkeytwo\quad{}%
\abscnkeythree\quad{}%
\abscnkeyfour\quad{}%
\abscnkeyfive}%
\end{titlepage}
% Abstract
\begin{titlepage}
\begin{spacing}{1.05}
\centering
\parbox[c]{.6\textwidth}{\thesistitleenfont{\thesistitleen}}
\end{spacing}
\begin{spacing}{1.6}
    \centering
    \sanhao\quad{} \\
    \abszhname{ABSTRACT} \\
    \xiaosanhao\quad{}
\end{spacing}

\normalsize

\abstracten

\quad{}

\par\noindent\absenkey{KEY WORDS}\quad{}%
\absenkeys{\absenkeyone\quad{}%
\absenkeytwo\quad{}%
\absenkeythree\quad{}%
\absenkeyfour\quad{}%
\absenkeyfive}%
\end{titlepage}

Negative 我们班说了要求这个

@lebronlambert 确认一下信源的可靠性。

根据今天发下的论文修改意见，已确认要求关键字不缩进。

@JoyBeginner 我昨天在现场，负责我班的检查小组成员亲自询问了寿心灵老师，得到了指导手册上没有规定，两种都可以接受的答复。

authors: JoyBeginner lebronlambert sqyx008


text:
DB tests fail on master

$ PSQL_USER=smacker PSQL_DB=test go test ./...
?   	github.com/src-d/metadata-retrieval/database	[no test files]
?   	github.com/src-d/metadata-retrieval/examples/cmd	[no test files]
?   	github.com/src-d/metadata-retrieval/examples/cmd/testing	[no test files]
--- FAIL: TestDownloaderTestSuite (6.59s)
    --- FAIL: TestDownloaderTestSuite/TestOfflineOrganizationDownloadWithDB (0.10s)
        --- FAIL: TestDownloaderTestSuite/TestOfflineOrganizationDownloadWithDB/src-d (0.06s)
            downloader_test.go:312:
                	Error Trace:	downloader_test.go:312
                	            				downloader_test.go:455
                	Error:      	Not equal:
                	            	expected: "2015-10-14 17:13:24 +0000 UTC"
                	            	actual  : "2015-10-14 19:13:24 +0200 CEST"

                	            	Diff:
                	            	--- Expected
                	            	+++ Actual
                	            	@@ -1 +1 @@
                	            	-2015-10-14 17:13:24 +0000 UTC
                	            	+2015-10-14 19:13:24 +0200 CEST
                	Test:       	TestDownloaderTestSuite/TestOfflineOrganizationDownloadWithDB/src-d
    --- FAIL: TestDownloaderTestSuite/TestOfflineRepositoryDownloadWithDB (5.73s)
        --- FAIL: TestDownloaderTestSuite/TestOfflineRepositoryDownloadWithDB/src-d/gitbase (5.65s)
            downloader_test.go:409:
                	Error Trace:	downloader_test.go:409
                	            				downloader_test.go:344
                	            				downloader_test.go:475
                	Error:      	Not equal:
                	            	expected: "2016-09-19 10:14:13 +0000 UTC"
                	            	actual  : "2016-09-19 12:14:13 +0200 CEST"

                	            	Diff:
                	            	--- Expected
                	            	+++ Actual
                	            	@@ -1 +1 @@
                	            	-2016-09-19 10:14:13 +0000 UTC
                	            	+2016-09-19 12:14:13 +0200 CEST
                	Test:       	TestDownloaderTestSuite/TestOfflineRepositoryDownloadWithDB/src-d/gitbase
FAIL
FAIL	github.com/src-d/metadata-retrieval/github	6.605s
?   	github.com/src-d/metadata-retrieval/github/graphql	[no test files]
?   	github.com/src-d/metadata-retrieval/github/store	[no test files]
?   	github.com/src-d/metadata-retrieval/testutils	[no test files]
ok  	github.com/src-d/metadata-retrieval/utils/ctxlog	(cached)
FAIL

I use local postgres instead of docker in case it matters.
//cc @kyrcha

Timestamp related. Because it uses the dockerized image it is too strict and expects in UTC. I will make a PR to convert it from whatever TZ => UTC

authors: kyrcha smacker

repo: src-d/metadata-retrieval


text:
Higher-level APIs to list simple AST constructs

Parent objective:  #20
Progress: 0%

[ ] [P0] UAST structure normalization
[ ] [P0] Port all existing beta language drivers

Status update as of friday's 29th june:

UAST structure normalization was defined.
Beta drivers are migrated and in PR state, but not merged because we're in review + fix state both for the drivers and the SDK.

authors: dennwc juanjux

repo: src-d/okrs


text:
Mismatch in remembering context history

If context is below -
A is apple. A's family is fruit. B is bubble. B's origin is soap.
When asked what is B's family after a conversation about A, it should give "No answer" but instead it gives information about A's family

Tested it out -
Please enter your question:
What is A?
Predicted answer:
Apple
Do you want to ask another question based on this text (Y/N)? Y
Please enter your question:
What is the family of it?
Predicted answer:
Fruit
Do you want to ask another question based on this text (Y/N)? Y
Please enter your question:
What is B?
Predicted answer:
Bubble
Do you want to ask another question based on this text (Y/N)? Y
Please enter your question:
What is the origin of it?
Predicted answer:
Soap
Do you want to ask another question based on this text (Y/N)? Y
Please enter your question:
What is the family of it?
Predicted answer:
Fruit
Do you want to ask another question based on this text (Y/N)? N
Bye!

confidence score is also really high

This is being tracked with confidence threshold issue. Closing for now.


text:
Problems With Templates?

Issue In

[x] Documentation

The templates which are created in ISSUE_TEMPLATE.md and PULL_REQUEST_TEMPLATE.md  end with an '+.
Is this intensional?  if not i would like to work on the PR for this chore (fix).

@SaanviKumar13 what do you think

I think we can remove it since all it does is act like a placeholder to add the files which is not required since it's already mentioned to add them.

repo: srm-kzilla/fury


text:
Unable to run sample Usage code

I installed the package empyrial and it is showing multiple errors
I am running python 3.9.0 and I installed plotly for the visualizations
I am running the sample Usage code

from empyrial import empyrial, Engine

portfolio = Engine(
                  start_date= "2020-06-09",
                  portfolio= ["BABA", "RELIANCE.NS", "KO", "^DJI","^IXIC"],
                  weights = [0.2, 0.2, 0.2, 0.2, 0.2], #equal weighting by default
                  benchmark = ["SPY"]
)

empyrial(portfolio)

Hey,
So you can see the error given is NameError: name 'display' undefined.
To show the final dataframe, Empyrial uses the display function. I found this post that can help you : https://stackoverflow.com/questions/49328447/display-in-python
So basically I think it gives an errror because you're not in a jupyter notebook/google colab.
To solve this you will need to:

Install IPython (if it's not already done)

pip install IPython
or if you are running pip3:
pip3 install IPython

When the installation is completed, add this import at the beginning of your code:

from IPython.display import display
Tell me if works.
I'm going to solve this as soon as possible thanks for raising the problem!

Tried it in a jupyter notebook and it worked! thank you.

authors: spindriftur ssantoshp

repo: ssantoshp/Empyrial


text:
Progress bar fresh changes color on completion and failure #397

Reference PR: https://github.com/ssl-hep/ServiceX_frontend/pull/397
Due to rebase issue the branch became very messy.
Created a new branch.

@ketan96-m can you check the missing line in the code coverage?

Added the tests for coverage @ponyisi


text:
Screenshot functionality not working

Hey @ssl,
Thanks for this awesome tool! I'm having issues where screenshots aren't being generated.
I used docker to launch the services and I can confirm I am getting callbacks with all of the other information.
However, the screenshot label shows nothing:

Furthermore, when I look in the docker container, I can confirm no screenshots were captured:
docker exec -it ezxss-ezxss-1 /bin/ls -lah assets/img
Here are my settings:

Here's the example page I've tried:
<?php
header("access-control-allow-origin: *");
?>

<link href="https://fonts.googleapis.com/css?family=Inconsolata" rel="stylesheet">
<title>ssrf.app</title>

ssrf.app

I've also tried this by modifying the response on https://example.com and I get the callback, but no screenshot.
I tried solving this with chown -R www-data:www-data /var/www/html/assets/ to see if there was some sort of permission issue with writing to the folder, but that did not fix it either.
When I visit https://MY_EZXSS/assets/payload-tester.html
I see the following:
ezXSS screenshot initialized: no

Hey @lc!
ezXSS screenshot initialized: no would tell me the html2canvas is not added at all.
Your second screenshot tells me that screenshots are enabled inside the admin settings tab. These are global settings.
Under 'Payload' has your fallback payload or payload domain you are using screenshots enabled aswell?

Ok, I got it working. It must've been my browser? It showed that I had the correct settings enabled. However, when I logged into the admin panel from my mobile device, it showed the setting as not enabled. So I enabled it from the other browser window and it works!
Sorry for being a nuisance 😁

authors: lc ssl

repo: ssl/ezXSS


text:
Model Complexity：Hello, how do you measure FLOPs, Parameters, and Memory?

Hello, how do you measure FLOPs, Parameters, and Memory?

hello, you can refer to this link: https://blog.csdn.net/qq_45359549/article/details/134813792.
The memory usage: You can loop the model and record memory usage information using cmd nvidia-smi.

hello, you can refer to this link: https://blog.csdn.net/qq_45359549/article/details/134813792. The memory usage: You can loop the model and record memory usage information using cmd nvidia-smi.

Thank you for your reply.

repo: sstary/SSRS


text:
Let ruby-build try to build with the best compiler available to the system

https://p8952.info/ruby/2014/12/12/benchmarking-ruby-with-gcc-and-clang.html
According to this benchmark, building with Clang is preferrable on a number of server-oriented Linux systems.
CentOS 6 has GCC 4.4 and Clang 3.4, the latter wins.
CentOS 7 has GCC 4.8 and Clang 3.5, the former wins.
Ubuntu 14.04 is in the same situation as CentOS 7.

Pull request #707 fixes this issue for CentOS. Ubuntu and Debian will be added later.

Closing for the same reason as https://github.com/sstephenson/ruby-build/pull/707#issuecomment-70571673
Thanks for the suggestion, though! :dizzy:

authors: grepwood mislav

repo: sstephenson/ruby-build


text:
Fix token generation for text > 0x10000

Also minor optimizations.
Python does not natively support Unicode surrogates, which are used when calculating the token for JS.
In addition, the loop was fixed to follow the value g instead of the static size, as the number of iterations is not necessarily the same as the length of the string.

Coverage decreased (-0.4%) to 98.381% when pulling aac44b619118b60a2a31fdace67633f3242ac6d3 on Roadcrosser:master into 48653332effe76d0a034a730abdba1e96cd56d8a on ssut:master.

authors: Roadcrosser coveralls

repo: ssut/py-googletrans


text:
🛑 ST37 Home is down

In fc72491, ST37 Home (https://www.st37.fr) was down:

HTTP code: 0
Response time: 0 ms

Resolved: ST37 Home is back up in af78e9e.


text:
The prompt or the messages are too long

Describe the bug
I deleted and reloaded the project, I could not overcome the error below even though I reopened the prompt. I want it to analyze an error from a very small .tsx file. I have never encountered such a problem before. I tried with chrome and firefox and got a similar error.
The prompt or the messages are too long
Link to the Bolt URL that caused the error
https://bolt.new/~/sb1-x2mdu5
Steps to reproduce

Expected behavior
I have never encountered such a problem before.
Screen Recording / Screenshot
No response
Platform
Browser name = Chrome
Full version = 130.0.0.0
Major version = 130
navigator.appName = Netscape
navigator.userAgent = Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/130.0.0.0 Safari/537.36
performance.memory = {
  "totalJSHeapSize": 72400463,
  "usedJSHeapSize": 61630427,
  "jsHeapSizeLimit": 2197815296
}
Username = prensgold
Chat ID = f0f5f860fe06

Additional context
No response

Appreciate the feedback! This is a known issue related to the AI model's context window that we are tracking here: #1322.

authors: endocytosis prensgold


text:
no complete code is shown

Describe the bug
many times the code shown is not complete
Link to the Bolt URL that caused the error
https://bolt.new/~/sb1-jkzvco
Steps to reproduce
ask some modification to code, sometimes the new code shown in the code window is not complete
Expected behavior
all the code should be shown
Screen Recording / Screenshot
No response
Platform
Browser name = Chrome
Full version = 130.0.0.0
Major version = 130
navigator.appName = Netscape
navigator.userAgent = Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/130.0.0.0 Safari/537.36
performance.memory = {
  "totalJSHeapSize": 71788896,
  "usedJSHeapSize": 67096740,
  "jsHeapSizeLimit": 4294705152
}
Username = Psychopixel
Chat ID = 427073e56d45

Additional context
No response

Appreciate the feedback! At times there are programming challenges that are too complex for the AI to solve. Sometimes pasting any error messages from the terminal into the chat is successful in resolving issues. At other times, manual intervention is required to prevent excessive token usage, which may include writing additional code. This page here has a number of helpful insights on using Bolt effectively while maximizing token efficiency. Appreciate your patience as the team continues to make improvements!

Wanting to confirm here.
While the code is fully generated ( you can see it generate to completion ) and the preview correctly displays the code as intended the actual code in the code IDE panel is cut off so you don't get to see the fully displayed code.
It's certainly there, just gets cut off for some reason.

authors: Psychopixel chrislaupama endocytosis


text:
macOS | Making/Editing expressions currently broken.

Describe the bug
When making or editing any expression, it will refuse to work.
To Reproduce
Steps to reproduce the behavior:

Go to 'Tools > Expressions'.
Make or edit any expression.
Hit "Apply".

Expected behavior
When making or editing any expression, and hitting apply, a window saying "Error: No options specified" will appear.
Screenshots

Environment:

OS: macOS
Version: v0.0.475.0
Voicebank used: doesn't apply
Ust used: doesn't apply

Should be fixed with 0.0.503 release.

authors: chouchorps stakira

repo: stakira/OpenUtau


text:
🛑 STAKR.space site is down

In d6e52f6, STAKR.space site (https://stakr.space) was down:

HTTP code: 0
Response time: 0 ms

Resolved: STAKR.space site is back up in fd2485e after 11 minutes.

repo: stakrspace/upptime


text:
Boilerplate reduction idea

Related to #40
If a proxy is used between the injected model/view/intent then there is no need to declare an interface upfront. The flip side is that the observables hanging off the model/view/intent must be accessed through a getter function and a stringed arg.
Example from the README:
var HelloModel = Cycle.createModel(function (intent) {
  return { name$: intent.get('changeName$').startWith('') };
});

Modified data-flow-node.js:
function P() { // Proxy is ES6 reserved
  this.proxiedProps = {};
  this.get = function (streamKey) {
    if (this.proxiedProps[streamKey] === undefined) {
      this.proxiedProps[streamKey] = new Rx.Subject();
    }
    return this.proxiedProps[streamKey];
  }
}

function DataFlowNode() {
  var args = Array.prototype.slice.call(arguments);
  var definitionFn = args.pop();
  if (typeof definitionFn !== 'function') {
    throw new Error('DataFlowNode expects the definitionFn as the last argument.');
  }
  var proxies = [];
  for (var i = 0; i < definitionFn.length; i++) {
    proxies[i] = new P();
  }
  var wasInjected = false;
  var output = definitionFn.apply(this, proxies);
  checkOutputObject(output);
  copyProperties(output, this);
  this.inject = function injectIntoDataFlowNode() {
    if (wasInjected) {
      console.warn('DataFlowNode has already been injected an input.');
    }
    for (var i = 0; i < arguments.length; i++) {
      replicateAll(arguments[i], proxies[i].proxiedProps);
    }
    wasInjected = true;
  };
  this.clone = function () {
    // TODO this is broken
    return DataFlowNode.apply({}, interfaces.concat([definitionFn]));
  };
  return this;
}

ES6 Proxy would be perfect for this, but they are very much a WIP.
One idea is to default to loose mode (as above) with an opt in to strict mode (as it is now) by passing in interface string arrays. This opt-int strict checking is how React handles it with their propTypes. I found myself constantly making errors during the writing and refactoring of a toy cycle app.
I'm somewhat on the fence with the need for the .get (it is ugly in it's own way) and the stringed stream arg, but those massive interface arrays in the TodoMVC are scary. It would be awesome to couple this with the removal of the events view property as outlined in #40. That would make the README example app really nice and welcoming:
var Cycle = require('cyclejs');
var h = Cycle.h;

var HelloModel = Cycle.createModel(function (intent) {
  return { name$: intent.get('changeName$').startWith('') };
});

var HelloView = Cycle.createView(function (model) {
  return {
    vtree$: model.get('name$')
      .map(function (name) {
        return h('div', {}, [
          h('label', 'Name:'),
          h('input', {
            'attributes': {'type': 'text'},
            'ev-input': 'inputText$'
          }),
          h('h1', 'Hello ' + name)
        ]);
      })
  };
});

var HelloIntent = Cycle.createIntent(function (view) {
  return {
    changeName$: view.get('inputText$').map(function (ev) { return ev.target.value; })
  };
});

Cycle.createRenderer('.js-container').inject(HelloView);
Cycle.circularInject(HelloModel, HelloView, HelloIntent);

I'm probably missing something obvious here that is a deal-breaker. Also, the explicit interface declaration was likely a purposeful design decision. In that case please feel free to ignore my suggestion!
:beers:

Wow, I really like your suggestion. Thanks! I hear you about boilerplate problems, and I'd like to reduce it as much as possible (but avoiding an API that makes the framework feel too "magical").

I found myself constantly making errors during the writing and refactoring of a toy cycle app.

That's a very important problem to solve.

those massive interface arrays in the TodoMVC are scary.

Yes they are.
I need to give some thought to your implementation, and also to the overall API design. My intuition is to lean towards your suggestion, since JS is after all a dynamically typed language, where we are used to code without specifying types or contracts. Interfaces in Cycle are a bit against that. I'll toy around with this suggestion, and comment back here soonish. :+1:

Commits https://github.com/staltz/cycle/commit/f9e733ae936eed414b70175f75d78f5798bdc95c and https://github.com/staltz/cycle/commit/a52db8223da48f327c812fa430af76d79b63b4db are implementing this. Boilerplate is being succesfully removed. :+1:
The README example would be:
var HelloModel = Cycle.createModel(function (intent) {
  return {name$: intent.get('changeName$').startWith('')};
});

var HelloView = Cycle.createView(function (model) {
  return {
    vtree$: model.get('name$')
      .map(function (name) {
        return h('div', {}, [
          h('label', 'Name:'),
          h('input', {
            'attributes': {'type': 'text'},
            'ev-input': 'inputText$'
          }),
          h('hr'),
          h('h1', 'Hello ' + name)
        ]);
      })
  };
});

var HelloIntent = Cycle.createIntent(function (view) {
  return {
    changeName$: view.get('inputText$')
      .map(function (ev) { return ev.target.value; })
  };
});

Cycle.circularInject(HelloModel, HelloView, HelloIntent);
Cycle.createRenderer('.js-container').inject(HelloView);

I'll still do some commits on lessboilerplate branch, to update the docs and README, etc. I might join these changes with also #58, removing dom-delegator, before releasing v0.8.0 which should have significantly slimmer API.
Thanks @dobrite !

And I've been investigating if I could use ES6 Proxy or something equivalent (maybe a polyfill), but there are no hopes yet. We need to wait for ES6 implemented in browsers. Only then can we make another version of Cycle without the use of get().

Wow, absolutely amazing! I looked through the 2 commits and what I saw looked good (but I'll admit most of it was over my head). I'll pull the branch and try it out with my toy app and see how it goes. So excited to delete those arrays. :beers:
I too looked for polyfills, googled, and checked SO and nothing turned up. It would be lovely to remove the gets eventually, but that will likely take a long while.

Toy app working! :+1:

So my app hits a brick wall after a few minutes of running (~1.5 gb of ram allocated). Heap Allocations in chrome turns up ReplaySubjects. No idea if this means anything or is just a red herring:
master

lessboilerplate

Perhaps this? No idea what it is but it looked a little fishy on my read through.

Would ES5 getters/setters further clean up the syntax? Or is that still too much to expect from the supported browsers?

Oh never mind, I guess you'd still have to know the props up-front to define getters/setters.

So my app hits a brick wall after a few minutes of running (~1.5 gb of ram allocated).

I'll try to fix it before merging to master. Can you share the code, or tell me the use case, so I can reproduce it?

Would ES5 getters/setters further clean up the syntax? Or is that still too much to expect from the supported browsers? Oh never mind, I guess you'd still have to know the props up-front to define getters/setters.

Yeah I looked into that, and it won't be enough. Has to be ES6 Proxy.

The custom-element example exhibits the same issue although slower. Pretty sure all apps will at some rate. I copied the ticker a bunch of times to get it to happen faster. In Chrome I used Profiles -> Record Heap Allocations to generate those screenshots above.

@dobrite fixed the memory leak. Turned out to be just the wrong way of using the replay() operator. replay(null, 1) and not replay(1). https://github.com/staltz/cycle/commit/ebc3c1e5ec1a8d580b9b2f7b343f1992ac450951
Check if it solves your issue.

Merged to master and considered done.

authors: dobrite secobarbital staltz

repo: staltz/cycle


text:
⚠ GitLab Server has degraded performance

In 29c612f, GitLab Server (https://gitlab01.its-telekom.eu) experienced degraded performance:

HTTP code: 200
Response time: 14121 ms

Resolved: GitLab Server performance has improved in 2a236c0.

repo: stamateas/upptime


text:
⚠ GitLab Server has degraded performance

In 3901752, GitLab Server (https://gitlab01.its-telekom.eu) experienced degraded performance:

HTTP code: 200
Response time: 7907 ms

Resolved: GitLab Server performance has improved in 0d6a660.


text:
⚠ GitLab Server has degraded performance

In 38168f4, GitLab Server (https://gitlab01.its-telekom.eu) experienced degraded performance:

HTTP code: 200
Response time: 11446 ms

Resolved: GitLab Server performance has improved in e9eb483.


text:
Add a builder with twig support

Initial approach to fix #3.
The twig template can be used with defining
"builder"      : "kss_styleguide/twig/",

in the kss-config.json file.
There is some room for improvements, to avoid duplication between both builders.

@szeidler Sorry for the late reply. I will look at this later on and try to improve it a bit to prevent duplications. Thnx! :)

Any chance on bringing this to the next release? I'd love to use my twig templates for the styleguide.

authors: JordyPouw schneyra szeidler

repo: stamkracht/michelangelo


text:
Scalar lgamma_stirling and lbeta truncate log input to integer

Description
https://github.com/stan-dev/math/blob/develop/stan/math/prim/fun/lbeta.hpp does not include <cmath> and does not declare using std::log anywhere. Which probably means that that would use stan::math::log. But, given that only declare stan::math::log(int) that means that the input gets truncated to integer. Luckily this doesnt effect vectorized versions and eigen versions.
We have the same issue in https://github.com/stan-dev/math/blob/develop/stan/math/prim/fun/lgamma_stirling.hpp where there is a missing using statement.
This came up when trying to fix https://github.com/stan-dev/math/issues/1692
cc: @martinmodrak  I think you were having issue with these two functions in the past if I remember correctly, but cant find the thread/PR right now. Hopefully the fix of this wil help in any way.
Will fix in #1702
Current Version:
v3.1.0

Thanks for looking into this, this is indeed my code (the relevant PR is #1612). Nevertheless the code is passing some quite strict tests, including with non-integer numbers, so I don't find it likely that the log is truncated. But rather safe than sorry I guess :-)

Yeah, I guess if it passes some strict tests, then log is not being truncated, luckily :)
Something like this was happening on an experimental branch where we were using exp() in a custom function in the stan::math namespace and the input got truncated and days were wasted figuring this one :)
There is most likely a global using std::log statement somewhere or something like that which is saving us in this case.

Are they passing these tests on all compilers?  What can happen is that top-level ::log can sneak in from some headers or in some compilers.  Is there a way to figure out which log is getting resolved?
Also, I think we should change all of our functions specified for int and/or double and rewrite them to take a template parameter with an enable-if for is-arithmetic.  Then if there's a more specific library function it'll match, but otherwise the templated version in the math lib will be the best match.
This is all in theory---I haven't tried it!

Ok, got to the bottom of this. First, the most important, there is no user-facing bug in terms of precision and performance but its a bit too dangerous at least for the latter.
In lgamma_stirling we are saved by the global namespace ::log that is included by <cmath>. If instead of <cmath> we would include #include <stan/math/prim/fun/log.hpp> this would use the vectorized version of log(). If that one would not exist (or was not included pre-flatten) it would use stan::math::log(int). I went and verified all these claims on Ubuntu with g++ and clang++.
Including stan/math/prim/fun/log.hpp instead of cmath can happen pretty quickly and the question is do we lose anything if log(3.3) calls the vectorized call shown below?
Tagging @t4c1 @SteveBronder @andrjohns who would know more on this.
template <typename T, typename = require_not_eigen_vt<std::is_arithmetic, T>>
inline auto log(const T& x) {
  return apply_scalar_unary<log_fun, T>::apply(x);
}

In lbeta we are saved by the same global namespace ::log that is included by <cmath> which is included by lgamma_stirling header that is included.There is no simple way to not include cmath here so I didnt go and try that.
The same things happen for other functions that dont have their own declarations for primitive scalars.
#include <stan/math/prim/fun/cos.hpp>
#include <iostream>

int main() {
    std::cout << stan::math::cos(1.1) << std::endl;
}

This uses https://github.com/stan-dev/math/blob/develop/stan/math/prim/fun/cos.hpp#L35
Is that fine or is it any slower?
If its slower, we need to add definitions for scalars for these functions.
If its fine, we can remove all the stan::math scalar functions like the ones defined for cbrt for example https://github.com/stan-dev/math/blob/develop/stan/math/prim/fun/cbrt.hpp

On Feb 13, 2020, at 7:11 AM, Rok Češnovar notifications@github.com wrote:
Ok, got to the bottom of this. First, the most important, there is no user-facing bug in terms of precision and performance but its a bit too dangerous at least for the latter.
In lgamma_stirling we are saved by the global namespace ::log that is included by . If instead of  we would include #include <stan/math/prim/fun/log.hpp> this would use the vectorized version of log(). If that one would not exist (or was not included pre-flatten) it would use stan::math::log(int). I went and verified all these claims on Ubuntu with g++ and clang++.

That's great.  I thought some of these behaved differently w.r.t putting the C math functions in the top-level namespace.

Including stan/math/prim/fun/log.hpp instead of cmath can happen pretty quickly and the question is do we lose anything if log(3.3) calls the vectorized call shown below?
Tagging @t4c1 @SteveBronder @andrjohns who would know more on this.

The code generated should be efficient and produce the correct results.  apply_scalar_unary has an overload for scalars and the log_fun defines a static function so there's no constructor overhead.

template <typename T, typename
= require_not_eigen_vt<std::is_arithmetic, T>>
inline auto log(const
T& x) {
return apply_scalar_unary<log_fun, T>::apply
(x);
}

In lbeta we are saved by the same global namespace ::log that is included by  which is included by lgamma_stirling header that is included.There is no simple way to not include cmath here so I didnt go and try that.
The same things happen for other functions that dont have their own declarations for primitive scalars.
#include <stan/math/prim/fun/cos.hpp>

include
int main
() {
std::cout <<
stan::math::cos(1.1
) << std::endl;
}
This uses https://github.com/stan-dev/math/blob/develop/stan/math/prim/fun/cos.hpp#L35
Is that fine or is it any slower?

I don't see why it'd be slower.  Compilers are really good at inlining trivial calls.

If its slower, we need to add definitions for scalars for these functions.
If its fine, we can remove all the stan::math scalar functions like the ones defined for cbrt for example https://github.com/stan-dev/math/blob/develop/stan/math/prim/fun/cbrt.hpp

I don't think it's slower.  Those scalar functions all got added because things wouldn't compile without them.   That may have all been laid in before the vectorization, though.  We've been struggling with the C math namespaces from the get go.

I wasn't sure how apply_scalar_unary worked and wanted to double check. In that case we don't need any of the scalar function definitions wherever we have the vectorized definitions. Will clean that up in  the updated PR.

Thanks so much for digging into this.  All this cleanup and getting to the bottom of things that've been thorns in our side for years is making me so happy!

On Feb 13, 2020, at 9:06 AM, Rok Češnovar notifications@github.com wrote:
I wasn't sure how apply_scalar_unary worked and wanted to double check. In that case we don't need any of the scalar function definitions wherever we have the vectorized definitions. Will clean that up in the updated PR.
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub, or unsubscribe.

No problem. I strangely enjoy solving these kind of puzzles.

Thanks for checking this and for making the codebase better.

Fixed by #1711

authors: bob-carpenter martinmodrak rok-cesnovar

repo: stan-dev/math


text:
MPI make issues

Summary:
The current MPI make commands fail on systems with spaces in its paths and can fail when order of arguments is wrong.
Description:
When the path to the stan-math contains spaces these are not correctly handled. Moreover, on some linkers the order of things matter more than for others (http://www.network-theory.co.uk/docs/gccintro/gccintro_18.html). Both issues seem to pop up currently on develop.
Reproducible Steps:
The space problem can be tickled with place stan-math in a sub-folder (on a mac) which has spaces and then trying to build the MPI stuff.
mkdir some\ space
mv math some\ space
# then enable MPI and build it => it will fail

Reproducing the linker order thing is hard, but has happened here: http://d1m1s1b1.stat.columbia.edu:8080/blue/organizations/jenkins/Math Pipeline/detail/PR-857/6/pipeline
Current Output:
It fails.
Expected Output:
It should work.
Additional Information:
Provide any additional information here.
Current Version:
v2.17.0

this one is fixed by https://github.com/stan-dev/math/pull/896


text:
Bugfix/issue 1731 argument configuration advi

Summary:
This gives reasonable values for variational input arguments.
Intended Effect:
It should make sure that the arguments tests don't fail.
How to Verify:
Run tests.
Documentation:
None.
Reviewer Suggestions:
@syclik

it's not quite right... I think you touched the submodule in some weird way. Mind backing out the change to the math submodule?

@syclik i did as you said, but i'm not sure it helped :(

Currently this pull request has merge conflicts, so you're going to need to resolve those before anything's going to pass.

that's odd. it was fine when i submitted it last week?
daniel said that this was blocking you guys. this pull request is all
standard stan/argument stuff; nothing specific to ADVI. so feel free to
hack at it, if you prefer.
On Mon, Dec 14, 2015 at 7:29 PM, Bob Carpenter notifications@github.com
wrote:

Currently this pull request has merge conflicts, so you're going to need
to resolve those before anything's going to pass.
—
Reply to this email directly or view it on GitHub
https://github.com/stan-dev/stan/pull/1732#issuecomment-164603405.

Unfortunately, it was never fine. It might have merged in the past, but it
definitely doesn't now. It never passed tests. (you can see the red x's for
when it was run and failed)
This is blocking Stan. Tests like should never fail and I've already seen
it fail a handful of times.
If you look back at the merge problem, I think it's due to the stan_math
submodule being in a conflicting state. Can you merge develop into the
branch locally and fix the conflict?
On Mon, Dec 14, 2015 at 7:36 PM, Alp Kucukelbir notifications@github.com
wrote:

that's odd. it was fine when i submitted it last week?
daniel said that this was blocking you guys. this pull request is all
standard stan/argument stuff; nothing specific to ADVI. so feel free to
hack at it, if you prefer.
On Mon, Dec 14, 2015 at 7:29 PM, Bob Carpenter notifications@github.com
wrote:

Currently this pull request has merge conflicts, so you're going to need
to resolve those before anything's going to pass.
—
Reply to this email directly or view it on GitHub
https://github.com/stan-dev/stan/pull/1732#issuecomment-164603405.

—
Reply to this email directly or view it on GitHub
https://github.com/stan-dev/stan/pull/1732#issuecomment-164604489.

@syclik looking okay now, i hope?

authors: akucukelbir bob-carpenter syclik

repo: stan-dev/stan


text:
Autocomplete branch from master

Enter still doesn't work but clicking does for suggestions.

Tested this and autocomplete works as well as clicking on suggestions. Just updated the package.json file to include slate-suggestions. Other than that, looks good to merge

repo: standardhealth/flux


text:
Visualize performance disparities better

Currently we report the results on a per-subgroup basis in a list of tables. Which seems tolerable but still not ideal for visualizing performance disparities.
Not a high priority, but could be improved by re-arranging how stuff gets visualized potentially (though seems gimmicky to do generally; e.g. we would likely not want this for MMLU, but i think we do care some about performance disparities even for MMLU).

There's already a way to do this in schema.yaml - add a unique group name for each subgroup to the run spec, then create an entry in schema.yaml for each subgroup with the desired metric , then create a parent group. The parent group table will show the desired metric for each subgroup side-by-side as columns.

authors: rishibommasani yifanmai

repo: stanford-crfm/helm


text:
Kubernetes jobs should be tagged to distinguish GPU vs CPU nodes

Otherwise, if some non GPU pod is restarted while a GPU job is running, the scheduler might place the restarted pod on the GPU node, causing unnecessary disruption later when the GPU node is taken down.

I forgot to add taints to gpu node. Will do so tomorrow.

I added the taint "role=training" to the node manually now, but I didn't find how to add taints to the nodegroup with eksctl.

Updated docs on how to create nodegroup taint using config file.

repo: stanford-oval/almond-cloud


text:
Add script to check how well synthetic set covers evaluation set

Examples:
https://docs.google.com/spreadsheets/d/1TuYwpAEwd0-t7OwGhyG4oXVGwWzNI1mnuEku6tHGcNk/edit?usp=sharing

I assume you coordinated with Ryan & Lucas? We had basically the same analysis in our paper to the Conference-That-Cannot-Be-Named, and we had a fairly sophisticated python script for this.

No! I was not aware of that.
which section is the analysis in? and where is the python code?

The analysis is section 5.4. The scripts are in genie-workdirs/dlgthingtalk, but I haven't touched in a while so you should check.

authors: gcampax rayslxu

repo: stanford-oval/genie-toolkit


text:
Grammar: allow program examples (prim templates) with parameters

There is no reason not to

Pull Request Test Coverage Report for Build 386

0 of 0   changed or added relevant lines in 0 files are covered.
No unchanged relevant lines lost coverage.
Overall coverage increased (+0.009%) to 81.727%

Totals

Change from base Build 385:
0.009%

Covered Lines:
5525

Relevant Lines:
6575

💛  - Coveralls

authors: coveralls gcampax

repo: stanford-oval/thingtalk


text:
docs(dspy): Fixed docstring for OpenAI having wrong default model

📝 Changes Description
I noticed that the docstring for OpenAI says that the default model value is davinci. However, the default value of the parameter in code is GT3 turbo instruct, which looks more reasonable.
I suspect the default changed a while ago and someone forgot to change the docstring.
This MR/PR contains the following changes:

New docstring value for the model property of OpenAI and AzureOpenAI classes

⚠ Warnings
Exactly because of these things (changing the parameter default value and forgetting to update the docs), I would consider not writing the default value in the docs at all. The IDE (I checked VS Code) anyway shows the available parameters and their default values, in addition to the docstring. So best case - it's written twice. Worst case - it's written twice AND one is incorrect.

LGTM

authors: isaacbmiller nsobadzhiev

repo: stanfordnlp/dspy


text:
feat(Indicator): add close indicator

Fixes https://github.com/stardust-ui/react/issues/896

Closing this in favor of https://github.com/stardust-ui/react/pull/1120

repo: stardust-ui/react


text:
feat(ListItem): add active prop

ListItem active prop
This PR will introduce possibility to specify a list item as active.
TODO

[x] Conformance test
[x] Minimal doc site example
[x] Stardust base theme
[x] Teams Light theme
[ ] Teams Dark theme
[ ] Teams Contrast theme
[ ] Confirm RTL usage
[ ] W3 accessibility check
[ ] Stardust accessibility check
[ ] Update glossary props table
[ ] Update the CHANGELOG.md

API Proposal
active

active prop makes a list item active by changing the background color.

Playing with this it seems like we should be changing the active item onClick....  i.e add handler for onClick and update active element.

@hughreeling that would require maintaining state in the List component. For simplicity, I thought to limit this PR to just an active prop in List.Item. Maybe a separate PR for implementing what you are saying?

closing as not needed anymore, meanwhile we implemented selected prop


text:
More fine-grained parsing of data attributes

Someone reported having a data attribute collision between a Craft plugin they use and Datastar. The plugin uses data-show-processing-spinner to mark elements as processing., which results in this error.

Uncaught (in promise) Error: Expression function not created

@delaneyj put aside any thoughts of “forms are bad”, because this is a plugin for collecting user input from the frontend. So it is less about forms and more about dealing with naming collisions.
Would it be possible to get rid of mustHaveEmptyKey and replace mustNotEmptyKey with mustHaveKey? That way, data-show-processing-spinner will not be confused with the data-show attribute.

We agreed that  we want to keep the possibility of using data-class-* attributes, so closing this.

This should be redundant with the changes coming in https://github.com/starfederation/datastar/issues/296.

repo: starfederation/datastar


text:
Errors in response

If there is an error thrown during deserialization of commands, response has array of errors as below. The error message in index 0 adds no value. In my opinion it needs to be removed.
Also the error code is missing on the raised error, in this case expecting "errorCode" : INVALID_FILTER_EXPRESSION
{     "errors": [         {             "message": "$in operator must have at least one value (through reference chain: io.stargate.sgv2.jsonapi.api.model.command.impl.FindOneCommand[\"filter\"])",             "exceptionClass": "JsonMappingException"         },         {             "message": "$in operator must have at least one value",             "exceptionClass": "JsonApiException"         }     ] }
@ivansenic @amorton @tatu-at-datastax

@ivansenic This sounds good to me -- we can re-visit this if need be, but I agree that ability to have multiple failures is useful; and in cases we don't want that, avoiding adding (or suppressing) cause makes sense.
Maybe we can also see if suppressing duplicate failures makes sense (literally same fail message) or something.

authors: maheshrajamani tatu-at-datastax

repo: stargate/jsonapi


text:
Parameter path warning in REST API

Shown on clean install:
[WARNING] [io.smallrye.openapi.runtime.scanner.spi] SROAP07902: @Parameter annotation missing JAX-RS parameter.
Class: io.stargate.sgv2.restapi.service.resources.CQLResource, Method:
  io.smallrye.mutiny.Uni<org.jboss.resteasy.reactive.RestResponse<java.lang.Object>>
  cqlQuery(java.lang.String keyspace, int pageSizeParam, java.lang.String pageStateParam,
  boolean raw, java.lang.@NotBlank(message = "CQL query body required") String payloadAsString),
  Parameter.name: keyspaceName, Parameter.in: path

Interesting. This is because CQL endpoint defines keyspace name as Query Parameter, whereas existing methods define it as Path Parameter. Former is required as well, latter not, so need to separate out definition.

authors: ivansenic tatu-at-datastax

repo: stargate/stargate


text:
updating Stargate description

only updating copy for the # Stargate section
Checklist

[ ] Changes manually tested
[ ] Automated Tests added/updated
[x] Documentation added/updated
[x] CLA Signed: DataStax CLA

Having some issues with editing this branch, will close and redo


text:
PFP setting after checkout

Description
Right now after purchasing a domain you don't have anything to do on the app and you're kind of lost. In a world where we have a lot of whitelisted PFPs collections, we can directly add a step after checkout where the person can choose an NFT to set as PFP or even buy one like an upsell.

I would like to work on this. Lemme know if you are still trying to expand this feature

Is this issue still open? and is there a design implementation of this? . Would love to work on this.

authors: fricoben jrmncos wheval


text:
bug: trait/impl resolution no longer working with generic types

Bug Report
Cairo version:
0b0392a461ca035c896308d199681164306f3e00

Current behavior:
The following code throws the following error:
struct Vec<T> {
    items: Felt252Dict<T>,
    len: usize,
}

impl DestructVec<T, impl TDrop: Drop::<T>> of Destruct::<Vec<T>> {
    fn destruct(self: Vec<T>) nopanic {
        self.items.squash();
    }
}

Method `squash` not found on type "core::dict::Felt252Dict::<GenericParamType(quaireaux_data_structures::vec::DestructVec::T)>". Did you import the correct trait and impl?

The same problem happens with
fn vec_new<T>() -> Vec<T> {
    let items = Felt252DictTrait::<T>::new();
    Vec { items, len: 0_usize }
}

Trait has no implementation in context: core::dict::Felt252DictTrait::<GenericParamType(quaireaux_data_structures::vec::vec_new::T)>

Expected behavior:
Compilation happens successfully

Steps to reproduce:

Related code:
Run the code above.

Other information:
It used to work before I updated the compiler to the last version. I'm not entirely sure what's causing this issue, but it looks like an issue when resolving the trait methods with generic arguments.

The issue is a missing , impl TFelt252DictValue: Felt252DictValue::<T> in the generic args - as now dict prevents problematic code by adding this high level request on the value type.
we do need to understand why the diagnostic was so unclear (i found it only after doing several iterations of simplifying the code)

authors: enitrat orizi

repo: starkware-libs/cairo


text:
[BUG] - Accepted row counting is incorrect in Audit table

Description
I was looking at my audit table and something was wrong on the countAccepted column on my json files :

Expected behavior
On my last row I have 5 row processed, 5 accepted and 3 rejected. When looking at my data I actually just have 2 accepted.
So countAccepted has a problem
Possible implementation
When looking in the source code I think I found the problem. In ai/starlake/job/ingest/JsonIngestionJob.scala, line 164 you return (rejectedDS, toValidate) instead of (rejectedDS, validationResult). I don't understand all your code architecture but it seems to be the problem.
Thank you in advance.

Hello @ametwalli1 and thanks for reporting this issue.
@tiboun just created a branch and we will include the fix in our next release.

repo: starlake-ai/starlake


text:
Update aws-java-sdk-bundle to 1.12.771

About this PR
📦 Updates com.amazonaws:aws-java-sdk-bundle from 1.12.769 to 1.12.771
Usage
✅ Please merge!
I'll automatically update this PR to resolve conflicts as long as you don't change it yourself.
If you'd like to skip this version, you can just close this PR. If you have any feedback, just mention me in the comments below.
Configure Scala Steward for your repository with a .scala-steward.conf file.
Have a fantastic day writing Scala!

⚙ Adjust future updates
Add this to your .scala-steward.conf file to ignore future updates of this dependency:
updates.ignore = [ { groupId = "com.amazonaws", artifactId = "aws-java-sdk-bundle" } ]

Or, add this to slow down future updates of this dependency:
dependencyOverrides = [{
  pullRequests = { frequency = "30 days" },
  dependency = { groupId = "com.amazonaws", artifactId = "aws-java-sdk-bundle" }
}]

labels: library-update, early-semver-patch, semver-spec-patch, commit-count:1

Superseded by #1015.


text:
Add Redis cache backend

PR Checklist

[x] Have you followed the guidelines in CONTRIBUTING.md?
[x] Have you got 100% test coverage on new code?
[x] Have you updated the prose documentation?
[x] Have you updated the reference documentation?

@Goldziher I'm not sure why pre-commit in the CI fails, any idea?
 slotscheck...............................................................Failed
- hook id: slotscheck
- exit code: 1

ERROR: Couldn't inspect module 'starlite.logging.standard' due to MissingDependencyException. Run `import starlite.logging.standard` to reproduce this error.

repo: starlite-api/starlite