[WIP] 0.4.0

This PR is a rebuild of the api for react-apollo. The initial discussion can be found here

The release candidate can be installed using npm i --save react-apollo@next

TODO

[ ] write some tests for common libs (redux, redux-form, mobx, etc)
[ ] docs 📖

API overview
react-apollo exposes three top level items for the client (and two for the server) which, when used in conjunction, make for easily binding graphql actions to react components. The intent of this library is to make co-location of graphql data simple, and mutations easy to use within components.
ApolloProvider
Modeled after react-redux, this is a component which binds the created client from ApolloClient to the store. It can be used as a drop in replacement for the Provider from react-redux, or used in with it.
Basic apollo version:

```js
import ApolloClient from 'apollo-client';
import { ApolloProvider } from 'react-apollo';
const client = new ApolloClient();
ReactDOM.render(

,
rootEl
)
</details>

Used in conjunction with a redux store:
<details>
```js
import { createStore, combineReducers, applyMiddleware } from 'redux';
import ApolloClient from 'apollo-client';
import { ApolloProvider } from 'react-apollo';

import { todoReducer, userReducer } from './reducers';

const client = new ApolloClient();

const store = createStore(
  combineReducers({
    todos: todoReducer,
    users: userReducer,
    apollo: client.reducer(),
  }),
  applyMiddleware(client.middleware())
);

ReactDOM.render(
  <ApolloProvider store={store} client={client}>
    <MyRootComponent />
  </ApolloProvider>,
  rootEl
)

Used in conjunction with react-redux Provider:

```js
import { createStore, combineReducers, applyMiddleware } from 'redux';
import ApolloClient from 'apollo-client';
import { ApolloProvider } from 'react-apollo';
import { Provider } from 'react-redux';
import { todoReducer, userReducer } from './reducers';
const client = new ApolloClient();
const store = createStore(
combineReducers({
todos: todoReducer,
users: userReducer,
apollo: client.reducer(),
}),
applyMiddleware(client.middleware())
);
ReactDOM.render(

,
rootEl
)
</details>

## `withApollo`

`withApollo` is a HOC [higher order component](https://medium.com/@dan_abramov/mixins-are-dead-long-live-higher-order-components-94a0d2f9e750) which provides access to your apollo-client as a prop to your wrapped component. This is useful if you want to do custom logic with apollo, without using the `graphql` HOC.

```js
const MyComponent = withApollo((props) => {
  // this.props.client is the apollo client
  return

})

// or

@withApollo
class MyComponent extends Component {
  render() {
    // this.props.client is the apollo client
    return

  }
}

graphql
graphql is a HOC higher order component which allows you to declare a graphql operation (mutation or query) and have the data or actions it represents bound to the wrapped component. For queries, this means graphql handles the fetching and updating of information from the query using apollo's watchQuery method. For mutations, graphql binds the intended mutation to be called using apollo.
The signature of graphql is as follows:
graphql(Document, (props) => QueryHandleOpts || MutataionHandleOpts, (result) => props)(Component)

Lets break that apart..
HOC
graphql(/* arguments */)(Component) in keeping with the HOC model, graphql should be used with either a react class, or a stateless component. It should wrap the component using either function syntax or as a decorator. For example:

```js
// function syntax
const MyComponent = (props) => (

)
const MyComponentWithData = graphql(Document)(MyComponent);
@graphql(Document)
class MyDecoratedComponent extends Component {
render() {
return
}
}
</details>

Both of the above will return a wrapped component which will get the benefit of graphql integration.

#### Document

The first, and only required, argument of `graphql` is a graphql document. This cannot be a string so using a library like [`graphql-tag`](https://www.npmjs.com/package/graphql-tag) or a compilation step is recommended. This can either be a `query` or a `mutation` but not both. If a query name is not used (i.e. `{ user { name } }`, instead of `query getUser { user { name } }`, the data will be mapped to `this.props.data` by default). It is recommended to use a query name for the most control.

```js
import { Component } from 'react';
import { graphql } from 'react-apollo';
import gql from 'graphql-tag';

@graphql(gql`
  query getUser {
    user { name }
  }
`)
class MyDecoratedComponent extends Component {
  render() {
    const { loading, user } = this.props.getUser;

    if (loading) return
Loading...

    return
{user.name}

  }
}

(props) => QueryHandleOpts || MutataionHandleOpts (mapPropsToOptions)
The second argument of graphql allows you to map the props passed from the parent component to create either options for watchQuery or mutate. The default is to pass props as the variables key in both option types ((props) => ({ variables: props })).

if you are coming from the previous react-apollo where state was useable, this is where you can use graphql in concert with connect from react-redux

XXX it would be awesome to be able to dynamically create flow and typescript definitions dynamically for wrapped components which describe the required and possible props.

Using the default method will expect an id key to exist on the props:
import { Component } from 'react';
import { graphql } from 'react-apollo';
import gql from 'graphql-tag';

@graphql(gql`
  query getUser(id: $ID!) {
    user { name }
  }
`)
class MyDecoratedComponent extends Component {
  render() {
    const { loading, user } = this.props.getUser;

    if (loading) return
Loading...

    return
{user.name}

  }
}

Using a custom mapping method which returns a computed option definition

```js
import { Component } from 'react';
import { graphql } from 'react-apollo';
import gql from 'graphql-tag';
@graphql(gql  query getUser(id: $ID!) {     user { name }   }, (props) => ({ variables: { id: props.userId } }))
class MyDecoratedComponent extends Component {
render() {
const { loading, user } = this.props.getUser;
if (loading) return <h1>Loading...</h1>
return <h1>{user.name}</h1>

}
}
</details>

Passing other option definitions
<details>
```js
import { Component } from 'react';
import { graphql } from 'react-apollo';
import gql from 'graphql-tag';

@graphql(gql`
  query getUser(id: $ID!) {
    user { name }
  }
`, () => ({ pollInterval: 1000 }))
class MyDecoratedComponent extends Component {
  render() {
    const { loading, user } = this.props.getUser;

    if (loading) return
Loading...

    return
{user.name}

  }
}

(result) => props (mapResultToProps)
The third argument of graphql allows you to customize the props passed to the child component based on resulting data. It takes a method which receives the result object (which includes the data, the loading state, any errors, and client methods) and expects an object in return. This is similar to react-redux's mapStateToProps method.
import { Component } from 'react';
import { graphql } from 'react-apollo';
import gql from 'graphql-tag';

@graphql(gql`
    query getUser(id: $ID!) {
      user { name }
    }
  `,
  null, // use default mapPropsToOptions function
  ({ loading, data, error, refetch }) => {
    if (loading) return { userLoading: true };
    if (error) return { hasErrors: true };
    return {
      currentUser: data.user,
      refetchUser: refetch
    };
  }
)
class MyDecoratedComponent extends Component {
  render() {
    const {
      userLoading,
      hasErrors,
      currentUser,
      refetchUser
    } = this.props;

    if (userLoading) return
Loading...

    return
{currentUser.name}

  }
}

Queries
Using graphql with queries makes it easy to bind data to components. As seen above, graphql will use the query name of the passed document to assign the result to the props passed to the wrapped component. If no query name is found, it will use the key data on props. The shape of the result will be the following:

loading: Boolean
Loading will be true if a query is in flight (including when calling refetch)

error: ApolloError
The error key will be null if no errors were created during the query

...queries
graphql will merge the root queries used within the query document executed. This allows for multiple root queries to be located on the top level of the result. For instance:

query getUserAndLikes(id: $ID!) {
  user(userId: $id) { name }
  likes(userId: $id) { count }
}

will return a result object that includes { user: { name: "James" }, likes: { count: 10 } }.

...QuerySubscription
The subscription created on this query will be merged into the passed props so you can dynamically refetch, change polling settings, or even unsubscribe to this query.

query
Sometimes you may want to call a custom query within a component. To make this possible, graphql passes the query method from ApolloClient as a prop

mutate
Sometimes you may want to call a custom mutation within a component. To make this possible, graphql passes the mutate method from ApolloClient as a prop

Mutations
Using graphql with mutations makes it easy to bind actions to components. Unlike queries, mutations return only a single method (the mutation method) to the wrapped component.

Previously react-apollo tried to match the shape of mutation props with that of query props. I don't think that was super helpful so mutation props match the need of mutations.

import { Component } from 'react';
import { graphql } from 'react-apollo';
import gql from 'graphql-tag';

@graphql(gql`
  mutation addTask($text: String!, $list_id: ID!) {
    addNewTask(text: $text, list_id: $list_id) {
      id
      text
      completed
      createdAt
    }
  }
`)
class MyDecoratedComponent extends Component {

  onClick = () => {
    this.props.addTask({ text: "task", list_id: 1 }) // pass in extra / changed variables
      .then(({ data }) => {
        console.log('got data', data);
      }).catch((error) => {
        console.log('there was an error sending the query', error);
      });
  }

  render() {
    return
Add Task

  }
}

Server methods
react-apollo supports integrated server side rendering for both store rehydration purposes, or fully rendered markup.
getDataFromTree
The getDataFromTree method takes your react tree and returns the context of you react tree. This can be used to get the initialState via context.store.getState()

```js
// no changes to client :tada:
// server application code (custom usage)
import { getDataFromTree } from "react-apollo/server"
// during request
getDataFromTree(app).then((context) => {
// markup with data from requests
const markup = ReactDOM.renderToString(app);
});
</details>

## `renderToStringWithData`
The `renderToStringWithData` takes your react tree and returns the stringified tree with all data requirements. It also injects a script tag that includes `window. __APOLLO_STATE__ ` which equals the full redux store for hydration. This method returns a promise that eventually returns the markup

<details>
```js
// no changes to client :tada:

// server application code (integrated usage)
import { renderToStringWithData } from "react-apollo/server"

// during request
renderToStringWithData(app).then(markup => // send markup to client)

> Server notes:
  When creating the client on the server, it is best to use `ssrMode: true`. This prevents unneeded force refetching in the tree walking.

Client notes:
When creating new client, you can pass initialState: __APOLLO_STATE__  to rehydrate which will stop the client from trying to requery data.

Looks great! combineRequests seems like a bit of an odd name to me though. I would preference just combine (it feels weird to include Request, which isn't really anywhere else in the API). If I was picking a word I'd choose Operation.

@tmeasday combine sounds great to me! I'll edit the PR

I'd change the graphql function to something more descriptive, since that kinda intersects with some things inside the graphql-js package (probably nobody will run into it, but it seems a bit generic for a name).
Maybe something like connectGraphQL or graphQLContainer?

One thing missing from this API is a way to fetch a totally different query based on the props. Before, you could simply not fetch a query if a certain prop wasn't fetched, but now as far as I can tell you will always fetch the document and then only thing you can control is the options. Maybe that means we need a new option like skip: true or something if you don't need the query at all?

The default is to pass props as the variables key in both option types

AFAIK GraphQL servers error if they get unused variables - so I'm not sure if passing props as variables by default will be the right approach?

The subscription created on this query will be merged into the passed props so you can dynamically refetch, change polling settings, or even unsubscribe to this query.

These methods are on the observable now, just a heads up.

Unlike queries, mutations return only a single method (the mutation method) to the wrapped component.

I think it's important to be able to show a loading state while a mutation is in progress. What would be the way to do that here?

having said that, WOW this is super dope.

@stubailo

I'd change the graphql function to something more descriptive, since that kinda intersects with some things inside the graphql-js package

That sounds great to me. How do you feel about withGraphQL. React-router has withRouter which makes a lot of sense to me.

One thing missing from this API is a way to fetch a totally different query based on the props.

Ah yes, we actually run into this often. skip: true seems like a simple and effective solution.

AFAIK GraphQL servers error if they get unused variables

This wasn't clear enough in the api, my plan is to use variableDefinitions from the AST to try and auto match variables. I plan on erroring if you send props that the query can't execute (does apollo-client do this already?

These methods are on the observable now, just a heads up.

👍 I've got to play some catchup on all the awesome stuff in the client now!

I think it's important to be able to show a loading state while a mutation is in progress. What would be the way to do that here?

In practice, we have been using setState prior to calling the mutation to set a loading state then calling it again after the mutation. I'd be good to move it into react-apollo. I could always add it in on the mutation method (i.e. this.props.addTask.loading)

FWIW, between these two:
withRouter(Component)
connect([mapStateToProps], [mapDispatchToProps], [mergeProps], [options])(Component)

I would suggest that:
graphql([Document], [mapPropsToOptions], [mapResultToProps])(Component)

is most similar to the connect signature. So between withGraphQL vs connectGraphQL, it would seem that connectGraphQL could add clarity to the api expectations.
That said, I kind of like the simplicity of graphql since there isn't any pre-existing api expectations with that (at least not in my mind), and as a mini bonus it's less to type.
p.s. I'm so excited to start using this! Awesome stuff!

Yeah having a really short and sweet name can be nice :) people can always use ES2015 import renaming if they want to (not that most people are aware of that ES2015 feature though)

@stubailo are you okay with graphql then? ;)

@stubailo how do you want me to handle documentation on this? Are the new docs ready?
@tmeasday @stubailo also, I'll probably abstract out the getDataFromTree as it isn't react-apollo specific anymore, but works for any component that exposes a static fetchData method.

@stubailo thoughts on the being the 1.0 (after a through RC testing) so align with the 1.0 of the client?

The initial release of this is ready for testing!
The release candidate can be installed using npm i --save react-apollo@next

I don't think we are going to ship 1.0 of apollo-client until late september at the earliest, so I'd say it's a bit early. I'd rather ship all the features ahead of time, do a ton of testing, and then change the number at the last moment.
IMO 1.0 draws a lot of attention so you don't want to be making major changes in a 0.x -> 1.0 transition, it's mostly a marketing move.

Ah, that makes sense. I'll downgrade this back to the 0.4.0

@jbaxleyiii just FYI have been looking at this and plan on digging a lot deeper very very soon.

@tmeasday perhaps we can try out the release candidate in Galaxy/GitHunt? If it works there then it should be pretty good

@jbaxleyiii. Took a closer look and worked on converting GitHunt over to the new API: https://github.com/apollostack/GitHunt/pull/72/files
First off, it's a big improvement!
Some comments / issues in order of immediacy:

The behavior of mapResultsToProps doesn't match your example, or the intent I think. The return value still gets "scoped" to the query name, so I have to do this or to be clear:

Profile.propTypes = {
  CurrentUserForLayout: React.PropTypes.shape({
    loading: React.PropTypes.bool.isRequired,
    currentUser: React.PropTypes.object,
  }),
};

Rather than what I want, which is
Profile.propTypes = {
  loading: React.PropTypes.bool.isRequired,
  currentUser: React.PropTypes.object,
};

Ideally the presentational component (Profile) would not need to concern itself with where it's data is coming from (neither Apollo or specifics about the queries where the data came from).

How do I pass extra arguments such as optimisticResponse and updateQueries into the mutation?

Ideally this would happen in the container, not the presentational component.
Perhaps the mutation form should take a second mapMutationsToProps argument also, so I can do something like:
const CommentWithDataAndMutations = graphql(
  SUBMIT_COMMENT_MUTATION,
  // is this unintelligible ES2015?
  ({ submitComment }) => ({
     submitComment(args) {
       return submitComment(args, {
          optimisticResponse: ..../
       });
     }
  })
)

@stubailo and I were talking about react-apollo and the other integrations and we think that there's perhaps some shared "stateful" behavior handling that could be shared and should perhaps be moved into apollo-client, enabling a more direct (and thus probably different again) API for react-apollo.

I'll probably try and sketch something later this week/early next week to explain a little more, but I guess it's a little while away in the best case. But I wanted to give you a heads up.

Another thing:
The arguments to mapResultsToProps appear to include variables, which is useful, but I'm seeing them alternate between being defined and undefined during the render process. Not sure what's happening there.

There also appears to be a problem with fetchMore and createBoundRefetch -- the bound function gets called with a null result. I haven't investigated more but I'll list it here.

@tmeasday thanks so much for checking this out!

The behavior of mapResultsToProps doesn't match your example, or the intent I think

Good catch, the API design did not match the built product. I've adjusted the code to match the API as I agree, it is much nicer

How do I pass extra arguments such as optimisticResponse and updateQueries into the mutation?

The result of the mapPropsToOptions function allows you to do this. Detailed here

and I were talking about react-apollo and the other integrations and we think that there's perhaps some shared "stateful" behavior handling that could be shared and should perhaps be moved into apollo-client, enabling a more direct (and thus probably different again) API for react-apollo.

I'd love to know more, I really like this API and would love to know how it could be better / change with changes to the client

The arguments to mapResultsToProps appear to include variables, which is useful, but I'm seeing them alternate between being defined and undefined during the render process

Fixed and test added!

There also appears to be a problem with fetchMore and createBoundRefetch -- the bound function gets called with a null result.

This is actually a bug in the client. This should fix that. Once it does, I'll add a test here to ensure it works

@tmeasday @stubailo new code pushed as react-apollo@next

I really like this API and would love to know how it could be better / change with changes to the client

To clarify this, people often reach out to us for help because we have the Apollo Client core API where you call watchQuery, etc, and then the more declarative React API where you return static options from a function.
We were talking yesterday and it seems like if we added the concept of a "component" to the core, then react-apollo's job could simply be to initialize a "component" object, then that could have an idempotent function to basically set query options on it. Then react-apollo could basically call that, and it would be almost the same API as the "core".
But either way we don't think this needs to be done right away - just something we are going to think about in the next month.

@jbaxleyiii are you sure you published it? I'm not getting the fix in 1.0.0-rc.2, and 0.4.0 doesn't seem to exist.

Looking good @jbaxleyiii (check out https://github.com/apollostack/githunt/tree/react-apollo-next).
One final thing: how can we do a parameterized optimizedResponse?

@jbaxleyiii here is a little more color on what @stubailo was saying above. The final part is just my thoughts on what it could look like, and I love everyone's thoughts on it all.

@jbaxleyiii one minor thing that's kind of unfortunate is needing to use graphql(query, null, (result) => {...}) when you don't have variables to your query but you want to massage the query results.
I wonder if there's a way to get a nicer API for that use case (I also imagine it'll be really easy to leave out the null and stuff things up). Maybe we could also accept:
graphql(
  gql`...`,
  {
     mapPropsToOptions(props) { return {...}; }
     mapResultsToProps({ loading, something }) { return { ... } )
   }
```?

(As an example, I was putting together an example for the apollostack website here: https://github.com/apollostack/frontpage-react-app/blob/ffab743608b9f3c95a09247f7a76d6f1d9b89c4e/src/App.js#L38)

@tmeasday you know I had been wondering the same thing. I think it's a great idea and it enforces the names of the methods which will make documentation and training better. I'll make that change today

@tmeasday I've adjusted the API (and the design of it above) to allow for an argument instead of positional arguments. It also allows you to pass an optimistic result as part of the mutation action (mutations now take a mutation option instead of just variables.)
Let me know if this solves the missing pieces!

@jbaxleyiii I don't know if you saw @tmeasday's question above:

One final thing: how can we do a parameterized optimisticResponse?

@stubailo yep! You can now pass in an optimisticResponse when calling the mutation which would allow you to create it with any variables you want

I did it this way so you could pass user input, component state, whatever as a response

Sounds great to me. Tom is out for a few minutes, when he comes back let's get a final OK and then we're probably ready to ship!

@stubailo @tmeasday and I were going to work on the new docs for shipping. I'd love to have them in place before the release

Oh OK, I'll let you guys figure it out!

API adjustments made, and added a test for redux usage in conjunction with graphql

@tmeasday @stubailo I've added mobx, redux, and react-native testing so aside from documentation this is ready to go!

Docs PR: https://github.com/apollostack/docs/pull/171 viewable http://docs.apollostack.com/vreact-apollo-0.4.0/apollo-client/react.html

Once docs are signed off, we can merge and release this.
cc @tmeasday @stubailo

So how would I provide both query and mutation to one component?
Say I have form component
const MyForm = () => {
}

const MyComponentWithData = graphql(???)(MyForm);

Or you're saying that one should always have two separate components for queries and mutations?
const MyFormView = () => {
}

const MyComponentWithData = graphql(/* query */)(MyFormView);

const MyFormEdit = () => {
}

const MyComponentWithMutation = graphql(/* mutation */)(MyFormEdit);

How would I provide initial data to MyFormEdit?

@Vanuan you have a few options:
import React, { Component } from 'react';
import { graphql } from 'react-apollo';

class MyComponent extends Component { ... }
const MyComponentWithMutateAndData = graphql(UPVOTE)(graphql(DOWNVOTE)(MyComponent));

or with decorators
import React, { Component } from 'react';
import { graphql } from 'react-apollo';

@graphql(UPVOTE)
@graphql(DOWNVOTE)
class MyComponent extends Component { ... }

or with custom names:
import React, { Component } from 'react';
import { graphql } from 'react-apollo';

class MyComponent extends Component { ... }
MyComponent.propTypes = {
  upvote: React.PropTypes.func.isRequired,
  downvote: React.PropTypes.func.isRequired,
};

// This provides an `upvote` callback prop to `MyComponent`
const MyComponentWithUpvote = graphql(UPVOTE, {
  name: 'upvote',
})(MyComponent);

// This provides an `downvote` callback prop to `MyComponentWithUpvote`,
// and subsequently `MyComponent`
const MyComponentWithUpvoteAndDownvote = graphql(DOWNVOTE, {
  name: 'downvote',
})(MyComponentWithUpvote);

Ok, so it boils down to "use multi-layer wrapping". I see.

I'm going to merge this in manually since the rebase would be a major pain

Guys this is amazing! congrats on the new release!


Deprecated messages on converge

When using yum-epel, the following deprecated message is thrown when converging. Is this something that will be addressed going forward?
   Deprecated features used!
     baseurl nil currently does not overwrite the value of baseurl. This will change in Chef 13, and the value will be set to nil instead. Please change your code to explicitly accept nil using "property :baseurl, [MyType, nil]", or stop setting this value to nil. at 1 location:
       - /tmp/kitchen/cookbooks/yum-epel/recipes/default.rb:24:in `block (2 levels) in from_file'
     cost nil currently does not overwrite the value of cost. This will change in Chef 13, and the value will be set to nil instead. Please change your code to explicitly accept nil using "property :cost, [MyType, nil]", or stop setting this value to nil. at 1 location:
       - /tmp/kitchen/cookbooks/yum-epel/recipes/default.rb:25:in `block (2 levels) in from_file'
     enablegroups nil currently does not overwrite the value of enablegroups. This will change in Chef 13, and the value will be set to nil instead. Please change your code to explicitly accept nil using "property :enablegroups, [MyType, nil]", or stop setting this value to nil. at 1 location:
       - /tmp/kitchen/cookbooks/yum-epel/recipes/default.rb:28:in `block (2 levels) in from_file'
     exclude nil currently does not overwrite the value of exclude. This will change in Chef 13, and the value will be set to nil instead. Please change your code to explicitly accept nil using "property :exclude, [MyType, nil]", or stop setting this value to nil. at 1 location:
       - /tmp/kitchen/cookbooks/yum-epel/recipes/default.rb:29:in `block (2 levels) in from_file'
     fastestmirror_enabled nil currently does not overwrite the value of fastestmirror_enabled. This will change in Chef 13, and the value will be set to nil instead. Please change your code to explicitly accept nil using "property :fastestmirror_enabled, [MyType, nil]", or stop setting this value to nil. at 1 location:
       - /tmp/kitchen/cookbooks/yum-epel/recipes/default.rb:31:in `block (2 levels) in from_file'
     http_caching nil currently does not overwrite the value of http_caching. This will change in Chef 13, and the value will be set to nil instead. Please change your code to explicitly accept nil using "property :http_caching, [MyType, nil]", or stop setting this value to nil. at 1 location:
       - /tmp/kitchen/cookbooks/yum-epel/recipes/default.rb:34:in `block (2 levels) in from_file'
     include_config nil currently does not overwrite the value of include_config. This will change in Chef 13, and the value will be set to nil instead. Please change your code to explicitly accept nil using "property :include_config, [MyType, nil]", or stop setting this value to nil. at 1 location:
       - /tmp/kitchen/cookbooks/yum-epel/recipes/default.rb:35:in `block (2 levels) in from_file'
     includepkgs nil currently does not overwrite the value of includepkgs. This will change in Chef 13, and the value will be set to nil instead. Please change your code to explicitly accept nil using "property :includepkgs, [MyType, nil]", or stop setting this value to nil. at 1 location:
       - /tmp/kitchen/cookbooks/yum-epel/recipes/default.rb:36:in `block (2 levels) in from_file'
     keepalive nil currently does not overwrite the value of keepalive. This will change in Chef 13, and the value will be set to nil instead. Please change your code to explicitly accept nil using "property :keepalive, [MyType, nil]", or stop setting this value to nil. at 1 location:
       - /tmp/kitchen/cookbooks/yum-epel/recipes/default.rb:37:in `block (2 levels) in from_file'
     max_retries nil currently does not overwrite the value of max_retries. This will change in Chef 13, and the value will be set to nil instead. Please change your code to explicitly accept nil using "property :max_retries, [MyType, nil]", or stop setting this value to nil. at 1 location:
       - /tmp/kitchen/cookbooks/yum-epel/recipes/default.rb:38:in `block (2 levels) in from_file'
   hange your code to explicitly accept nil using "property :metadata_expire, [MyType, nil]", or stop setting this value to nil. at 1 location:
       - /tmp/kitchen/cookbooks/yum-epel/recipes/default.rb:39:in `block (2 levels) in from_file'
     mirror_expire nil currently does not overwrite the value of mirror_expire. This will change in Chef 13, and the value will be set to nil instead. Please change your code to explicitly accept nil using "property :mirror_expire, [MyType, nil]", or stop setting this value to nil. at 1 location:
       - /tmp/kitchen/cookbooks/yum-epel/recipes/default.rb:40:in `block (2 levels) in from_file'
     mirrorlist_expire nil currently does not overwrite the value of mirrorlist_expire. This will change in Chef 13, and the value will be set to nil instead. Please change your code to explicitly accept nil using "property :mirrorlist_expire, [MyType, nil]", or stop setting this value to nil. at 1 location:
       - /tmp/kitchen/cookbooks/yum-epel/recipes/default.rb:42:in `block (2 levels) in from_file'
     password nil currently does not overwrite the value of password. This will change in Chef 13, and the value will be set to nil instead. Please change your code to explicitly accept nil using "property :password, [MyType, nil]", or stop setting this value to nil. at 1 location:
       - /tmp/kitchen/cookbooks/yum-epel/recipes/default.rb:43:in `block (2 levels) in from_file'

       - /tmp/kitchen/cookbooks/yum-epel/recipes/default.rb:44:in `block (2 levels) in from_file'
     proxy nil currently does not overwrite the value of proxy. This will change in Chef 13, and the value will be set to nil instead. Please change your code to explicitly accept nil using "property :proxy, [MyType, nil]", or stop setting this value to nil. at 1 location:
       - /tmp/kitchen/cookbooks/yum-epel/recipes/default.rb:45:in `block (2 levels) in from_file'
     proxy_username nil currently does not overwrite the value of proxy_username. This will change in Chef 13, and the value will be set to nil instead. Please change your code to explicitly accept nil using "property :proxy_username, [MyType, nil]", or stop setting this value to nil. at 1 location:
       - /tmp/kitchen/cookbooks/yum-epel/recipes/default.rb:46:in `block (2 levels) in from_file'
     proxy_password nil currently does not overwrite the value of proxy_password. This will change in Chef 13, and the value will be set to nil instead. Please change your code to explicitly accept nil using "property :proxy_password, [MyType, nil]", or stop setting this value to nil. at 1 location:
       - /tmp/kitchen/cookbooks/yum-epel/recipes/default.rb:47:in `block (2 levels) in from_file'
     report_instanceid nil currently does not overwrite the value of report_instanceid. This will change in Chef 13, and the value will be set to nil instead. Please change your code to explicitly accept nil using "property :report_instanceid, [MyType, nil]", or stop setting this value to nil. at 1 location:
       - /tmp/kitchen/cookbooks/yum-epel/recipes/default.rb:48:in `block (2 levels) in from_file'
     skip_if_unavailable nil currently does not overwrite the value of skip_if_unavailable. This will change in Chef 13, and the value will be set to nil instead. Please change your code to explicitly accept nil using "property :skip_if_unavailable, [MyType, nil]", or stop setting this value to nil. at 1 location:
       - /tmp/kitchen/cookbooks/yum-epel/recipes/default.rb:50:in `block (2 levels) in from_file'
     source nil currently does not overwrite the value of source. This will change in Chef 13, and the value will be set to nil instead. Please change your code to explicitly accept nil using "property :source, [MyType, nil]", or stop setting this value to nil. at 1 location:
       - /tmp/kitchen/cookbooks/yum-epel/recipes/default.rb:51:in `block (2 levels) in from_file'
     sslcacert nil currently does not overwrite the value of sslcacert. This will change in Chef 13, and the value will be set to nil instead. Please change your code to explicitly accept nil using "property :sslcacert, [MyType, nil]", or stop setting this value to nil. at 1 location:
       - /tmp/kitchen/cookbooks/yum-epel/recipes/default.rb:52:in `block (2 levels) in from_file'
     sslclientcert nil currently does not overwrite the value of sslclientcert. This will change in Chef 13, and the value will be set to nil instead. Please change your code to explicitly accept nil using "property :sslclientcert, [MyType, nil]", or stop setting this value to nil. at 1 location:
       - /tmp/kitchen/cookbooks/yum-epel/recipes/default.rb:53:in `block (2 levels) in from_file'
     sslclientkey nil currently does not overwrite the value of sslclientkey. This will change in Chef 13, and the value will be set to nil instead. Please change your code to explicitly accept nil using "property :sslclientkey, [MyType, nil]", or stop setting this value to nil. at 1 location:
       - /tmp/kitchen/cookbooks/yum-epel/recipes/default.rb:54:in `block (2 levels) in from_file'
     sslverify nil currently does not overwrite the value of sslverify. This will change in Chef 13, and the value will be set to nil instead. Please change your code to explicitly accept nil using "property :sslverify, [MyType, nil]", or stop setting this value to nil. at 1 location:
       - /tmp/kitchen/cookbooks/yum-epel/recipes/default.rb:55:in `block (2 levels) in from_file'
   be set to nil instead. Please change your code to explicitly accept nil using "property :timeout, [MyType, nil]", or stop setting this value to nil. at 1 location:
       - /tmp/kitchen/cookbooks/yum-epel/recipes/default.rb:56:in `block (2 levels) in from_file'
     username nil currently does not overwrite the value of username. This will change in Chef 13, and the value will be set to nil instead. Please change your code to explicitly accept nil using "property :username, [MyType, nil]", or stop setting this value to nil. at 1 location:
       - /tmp/kitchen/cookbooks/yum-epel/recipes/default.rb:57:in `block (2 levels) in from_file'

Hello!
Fixing these up is definitely on our TODO (soon) lists... we're seeing these warnings on most of the cookbooks we maintain. The yum-* series is especially noisy because is uses a lot of nil attributes.
-s

Thank you for the response, looking forward to the fix!

any workaround to disable these warning messages?


Release v0.26.0

https://github.com/vmware-tanzu/carvel-imgpkg/releases/tag/v0.26.0
https://twitter.com/carvel_dev/status/1500980636303122436
https://community.chocolatey.org/packages/imgpkg/0.26.0

Available on choco central

RT https://twitter.com/rastadidi/status/1501006499836874759


New components - DayOfTheWeekButton, DaysOfTheWeekContainer, new page - DaysOfTheWeekSelection

Trello ticket:
Create a component and associated page to select a day of the week as per design.

Kept original funtionality for logs and data processing.
Custom components for both day button and day button container.
User can select a button and unselect it.
Save button is disable if no days are selected.

@Amutha37 , @batteries76 , @ymloh ,
Any feedback for Olga's PR?


Unit/Integration Testing

We need a little bit of confirmation on mewmba's behavior

[x] PR yaml?
[x] Unit test?
[x] Demo test gather location?

Actions on #22 serve as the unit testing


Advance copy   '[NULL]' PASTE

INSERT INTO C_FOREIGN(COMPANY_KIND,CONTROL_YEAR,CONTROL_NO,PAPMNY_CODE,SALE_DATE,PRINT_DTIME,REDEM_DATE,CURR_CD,PAPMNY_AMT,DEL_YN,REG_EMPNO,REG_DTIME,MOD_EMPNO,MOD_DTIME)
VALUES ('1000','2020',1,'1904000474','20191231',TIMESTAMP '2019-12-31 15:29:05.000000','20200102','JPY',18000000,'N','[NULL]',TIMESTAMP '2020-07-16 10:02:34.000000','[NULL]',TIMESTAMP'[NULL]');
If ADVANCED PASTE is performed on GRID by ADVANCED COPY=> ADVANCED COPY by selecting data tabpage on the table DATA display screen, the data of Date Type is entered as TIMESTAMP'[NULL] as shown above.
It should just be NULL. VARCHAR2 TYPE's Data Type shows the same phenomenon. Insert statements seem to be generated with '[NULL]'. You need to modify it to NULL to become INSERT.
Please check.
Thank you.

Hello @google007049
Please provide your DBeaver version, database name and version, and your table DDL. Data sample also will be beneficial

Dbeaver 22.1.3
oracle 11.2.40

Ok. And table DDL, please.

관심 감사드립니다.
Table Describe 올립니다.
Row 선택 후 Advanced Copy => Advanced paste 후 save 하면 발생합니다.
아래 그림에서 보면 Date Type 에서 에러가 발생합니다.

Can be connected with https://github.com/dbeaver/dbeaver/issues/17284

@google007049 Hi, could you provide a video that demonstrates this issue? It will be good if you also make one for the second ticket

I received your email, thank you.
Thank you.
I uploaded an Advanced Paste error video. Please check it again.
Thank you very much.
-----Original Message-----
From: @.>
To: @.>;
Cc: @.>; @.>;
Sent: 2022-08-12 (금) 00:09:49 (GMT+09:00)
Subject: Re: [dbeaver/dbeaver] Advance copy '[NULL]' PASTE (Issue #17210)
@google007049 Hi, could you provide a video that demonstrates this issue? It will be good if you also make one for the second ticket
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you were mentioned.Message ID: @.***>

Also connected with https://github.com/dbeaver/dbeaver/issues/8673


Fix link syntax: used markdown instead of adoc

Before you start

Open an issue to discuss your idea
Read CONTRIBUTING.md

Issue

What type of PR is this? (check all applicable)

[ ] Refactor
[ ] Feature
[ ] Bug Fix
[x] Documentation Update

Description
[optional] What gif best describes this PR or how it makes you feel?

So much CPU wasted for a doc fix!
Would be great that CIs skip doc files. GitHub Actions can exclude files by globs (which includes extension) FYI, not sure about Travis.


Is there any solution to use verdaccio on AWS ECS using S3 as synced package storage?

It would be very good to have some purposes or suggestions how to implement verdaccio registry using AWS ECS with shared storage for couple instances (using S3).
If there is some solution about this - could someone share a link about that?
Also would be awesome to have a full list of possible config values passed in config of verdaccio

@aremishevsky verdaccio works only with file system right now, we are working on https://github.com/verdaccio/verdaccio/pull/376 next big release to allow scale using different sort of storages. Hopefully beginning next year

Will wait for you updates a lot!!!


Remove version: CloudImperiumGames.RSILauncher version 1.6.9

[Automated] It returns code over 400 in all urls

Resolves #148848

Microsoft Reviewers: Open in CodeFlow

URL: https://install.robertsspaceindustries.com/star-citizen/RSI-Setup-1.6.9.exe
Status Code: 200
(Automated message - build 876)


Not working on iOS 12.4.4 on iPhone 6

iPhone 6 iOS 12.4.4 currently unsupported.

use checkrain

use checkrain

Unable to get into DFU because home botton is broken :/

There is a way to do it through command line.

Could you please let me know? I was not able to find it. I can only manage to put in recovery mode through command line.

there was an older program we were using to pull the noonce for A12 devices.  During the process it would throw the phone into dfu mode through command prompt.  For the life of me I just can't remember the name of the program.  There was also an older version used way back during the green poison jailbreak.

Thank you, will try to check it out.

closing, conversation turned into not related to unc0ver.


urlPathForPost does not include subdirectory

When generating the URL for a post, it does not include the subdirectory. This effects the controller that pulls a single post and post.url does not match req.path.
// CASE: permalink is not valid anymore, we redirect him permanently to the correct one
if (post.url !== req.path) {
return res.redirect(301, post.url);
}

@PeerWell Sorry to hear you're having trouble. When you raise an issue we provide a template which shows all the kinds of information that we need in order to track down an issue quickly and easily.
In particular, it includes the steps to reproduce & some details of your environment.
Can you please update your issue to include that info, so that we can find and fix the issue you're reporting?
Thanks 👍

This issue needs more information for us to be able to do anything with it and there has been no reply in more than a month. Going to close it for now, if more information is provided so that we can reproduce, we will reopen it 👍


Uncharted: Golden Abyss™ [PCSA00029]

App summary

App name: Uncharted: Golden Abyss™
App serial: PCSA00029
App version: 1.00

Vita3K summary

Version: v0.1.6
Build number: 3032
Commit hash: https://github.com/vita3k/vita3k/commit/e2b07dc4
CPU backend: Dynarmic
GPU backend: OpenGL

Test environment summary

Tested by: Adorait.com
OS: Windows 10/macOS/Linux Distro, Kernel Version?
CPU: AMD/Intel?
GPU: AMD/NVIDIA/Intel?
RAM: 7 GB

Issues

Screenshots

Log
Recommended labels

A?
B?
C?

what is the issue? need detailed information


Question: Are lifecycle args a part of the public API of configureRouter?

Are the lifecycle args that are passed to configureRouter alongside the RouterConfiguration and the Router part of the intended public API of configureRouter?
They are currently undocumented.
Currently the configureRouter callback is called like this (in route-loading.js)
return childRouter.configure(c => viewModel.configureRouter(c, childRouter, ...lifecycleArgs))         .then(() => component);
This means I can access any route parameters very easily and conditionally configure my router based on properties of an entity I load. I can also return a Promise. I'm currently doing this, but the docs don't mention any extra parameters (http://aurelia.io/docs/api/router/interface/ConfiguresRouter/method/configureRouter)
I'm worried if I rely on this method it might be deprecated in the future as it's not a documented public feature. Happy to send a pull request to the docs documenting with these extra parameters if that's helpful.

Bump, just came across this parameter and would love to know if this is here to stay.

Well, I am the third.
https://discourse.aurelia.io/t/the-easy-way-to-customize-child-router-based-on-parent-router-param/768?u=huochunpeng
@davismj neither endorses nor totally rejects the usage.

They are here to stay since we have no intention of introducing breaking changes. I may or may not document them at some point since, as @huochunpeng mentioned, I think this leads developers down a bad path that leads to architectural problems.

@davismj actually I rely on dynamic behaviour quite a lot. I have many pure backend defined dynamic routes like the one I showed you in the last post of the discourse topic.
In many parts of my app, I have no way to pre-define routes. My app is in cloud business. For instance, I need to show tabs "AWS" and "AZURE" because those are the cloud providers that client (app user) is using. That can be only defined at runtime, because another client might uses "VMWARE" and "ORACLE".

You did not get my point. “AWS” is unknown noun in my front-end code, it is just a provider. The list of providers is unknown, and should not be anyway hard coded by frontend code.
The config of any provider is unknown to my front-end, its driven by meta-data provided by backend, then rendered by front-end using exactly same code, same class.

In our architecture, provider type can be added to the app through plugin (backend). So some client can have their own provider named “Lorem” with a total different config and backend logic.

Keep in mind that configureRouter can actually be called in two different ways:
1. During initial composition (templating lifecycle) of the top-level router-view.
When a router-view is constructed during composition, it calls registerViewPort on the router to register itself as a rendering target. If the router is AppRouter it also calls configureRouter on the component and does not pass lifecycleArgs to it. An important exception.
2. During LoadRouteStep (routing lifecycle) of any child route
When you're navigating to some child route, the normal router pipeline runs and of course you have all the lifecycle args at this point. They are simply based on the url you're navigating to.
Any child route (and associated component) is only composed after you navigate to a url associated with it. Url -> lifecycleArgs, therefore it's only logical to always have those available inside any method of a child routed component.
LifecycleArgs in the constructor?
In fact, there's nothing special about having this during configureRouter. You can even grab them in the constructor with a little detour. Just inject Router as a dependency, which gives you the router of the component above it.
From any Router you can traverse up and down the entire routing/navigation chain and access all lifecycleArgs through currentInstruction and its properties lifecycleArgs, childInstruction, childInstruction.router, etc, even outside of the activation lifecycle.
So in that light I don't see any reason to not "endorse" this as long as its clear the root doesn't get them. But to be fair, the root does have the AppRouter during its composition and that one has - you guessed it - lifecycleArgs :)
It might feel as a semi-private API but aurelia has a not-even-potentially-breaking-change policy anyway, so properties would only be added and never removed.

Very grateful for your informative inside. I used Router injection but no more than doing manual navigation.


Add methods to output tensorboard metrics

Resolves https://github.com/petuum/adaptdl/issues/9
Add a few helper methods to output relevant tensorboard metrics.

Codecov Report

Merging #56 into master will decrease coverage by 0.18%.
The diff coverage is 28.57%.

@@            Coverage Diff             @@
##           master      #56      +/-   ##
==========================================
- Coverage   57.55%   57.37%   -0.19%
==========================================
  Files          29       29
  Lines        2177     2191      +14
  Branches      333      333
==========================================
+ Hits         1253     1257       +4
- Misses        861      871      +10
  Partials       63       63

Impacted Files
Coverage Δ

adaptdl/adaptdl/torch/parallel.py
26.59% <14.28%> (-1.00%)
:arrow_down:

adaptdl/adaptdl/torch/data.py
76.14% <42.85%> (-1.11%)
:arrow_down:

Continue to review full report at Codecov.

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


Need technical information to make OracleDatabase 19.3 slim docker container

I've built oracle/database:19.3.0-ee image using the Dockerfile in this repo, and noticed it's not quite usable in integration tests; it takes 882 seconds to start up on my machine.
Previously, I've used the slim image of store/oracle/database-enterprise:<IP_ADDRESS>-slim. On my machine, the regular 12.2c container took 328 seconds, but the slim version took 84 seconds. According to https://container-registry.oracle.com or https://hub.docker.com, details for the slim image are:

Oracle Database Server <IP_ADDRESS> Enterprise Edition Slim Variant
The Slim Variant (<IP_ADDRESS>-slim tag) of EE has reduced disk space (4GB) requirements and a quicker container startup. This image does not support the following features - Analytics, Oracle R, Oracle Label Security, Oracle Text, Oracle Application Express and Oracle DataVault.

May I get the Dockerfile used to produce store/oracle/database-enterprise:<IP_ADDRESS>-slim, or technical details to produce 19.3 slim version?
Please advise.
Thanks,

The -slim variant of the Database container image is deprecated. There are sample Dockerfiles in this repo that are designed to make image startup faster (like creating the Database during build instead of at container startup).

The open #1666 pull request adds -slim variants to all the Database images. You should be able to use the proposed changes to create one yourself.


Any plans on porting the addon to Godot 4?

I love the idea of your 'Say What' plug-in. To parse a simple dialog script that treats the data and events almost automagically is mindblowing. This mixed with something like dialogic (a dialog-box theme editor) could make frameworks like Ren'Py outdated and deprecated. :P
Anw, praises aside. As soon as I got my hands on the plugin, decided to translate it to Godot 4 alpha. Availlable here.  It's somewhat functional ─ I may test it later to catch unreached bugs.
If you wish to post it already into Godot 4 AssetsLib, go ahead! I would love to contribute. :3

That's awesome 👍
I have my own port for Godot 4 in the works (with a few new features that are only now possible with G4). I'm making a video about the kinds of things that are different in 4 when porting over so I'll push up the changes as an alpha branch when the video goes out.

This is exciting stuff, looking forward to it!

i like this

So glad someone has already raised this question! Stoked for the Godot 4 release :D

I mentioned this in the Discord a little while ago but I'll put it here too: the current plan is now to make Dialogue Manager 2.0 a Godot 4 thing, which I'll start releasing once we get a G4 beta and I've had more of a chance to work through some of the GDM breaking changes I want to make.

From version 2 onwards, Dialogue Manager is now for Godot 4.


copr: fix panic during push bit column down

Signed-off-by: yisaer<EMAIL_ADDRESS>
What is changed and how it works?

Issue Number: ref https://github.com/pingcap/tidb/issues/32506 https://github.com/tikv/tikv/pull/12016
What's Changed:
Bit Column should be solved separately according to its flag, otherwise it will cause panic.

Check List
Tests

Manual test (add detailed scripts or steps below)

same in https://github.com/tikv/tikv/pull/12016
Release note
None

How long will it take to fix this issue. TiSpark meet some problems because of this bug :)

How long will it take to fix this issue. TiSpark meet some problems because of this bug :)

I will revert pr which caused bug firstly in https://github.com/tikv/tikv/pull/12030 as the fixing and testing costs much time.


Show MB For Updates.

Description of the new feature / enhancement
show how much megabytes is that update.
Scenario when this would be used?
Showing megabytes will help metered connection users like me to decide whether to update or not
Supporting information
No response

Can be combined with #14700

Can be combined with #14700

Should I close it then?

Small, specific, but valid suggestion. I'll add it to the other issue and then will close this :)

Thanks.
Get Outlook for Androidhttps://aka.ms/AAb9ysg

From: Jay @.>
Sent: Saturday, August 13, 2022, 6:41 PM
To: microsoft/PowerToys @.>
Cc: Moheshwar Amarnath Biswas @.>; Author @.>
Subject: Re: [microsoft/PowerToys] Show MB For Updates. (Issue #19706)
Small, specific, but valid suggestion. I'll add it to the other issue and then will close this :)
—
Reply to this email directly, view it on GitHubhttps://github.com/microsoft/PowerToys/issues/19706#issuecomment-1214150766, or unsubscribehttps://github.com/notifications/unsubscribe-auth/APTOM2JCXHWJWUFRTSOBFXDVY6JXRANCNFSM55KCFSNQ.
You are receiving this because you authored the thread.Message ID: @.***>


Plan (semi-)automatic test execution

The CloudFormation template (see #23) and performance testing scripts (see #32) should ideally be executable in a (semi-)automatic fashion from a Jenkins job (see #24) to allow systematic gathering of performance metrics for a selected variety of infrastructure variations.
This issue is about discussing and planning the design of and required issues for this setup during the respective milestone.

Closed as Won't Fix due to project being retired to the CityIndex Attic.


Fix: multistring assertions

📚 Description
Related: https://github.com/phpstan/phpstan-src/actions/runs/9567238902/job/26374488151

Thanks for the support and help @staabm

🔖 Changes

Remove the optional label and use always label="$(helper::normalize_test_function_name "${FUNCNAME[1]}")", which is something we are using all around and it makes sense to keep it this way
For string arguments, use all arguments but the first one (reserved for the expected)

⏰  Disclaimer

assert_equals on multiline strings does not work, because multilines takes mutiple arguments positions when passing to other functions... so it's bash - at least I didn't find another solution for this problem so far.
This means that, multiline strings will work as last argument as they are treated as variadic arguments like ...string, therefore the first argument must be one liner, whatever that is.

You can use assert_contains or assert_matches instead

assert_equals on multiline strings does not work, because multilines takes mutiple arguments positions when passing to other functions... so it's bash - at least I didn't find another solution for this problem so far.

Would it make sense to emit an error in case of multi-line strings telling the user that its not supported?

I see, thanks for the details. maybe it makes sense to open a new issue about this known problem, so people showing up in the issue tracker find the "known problem"..?


Interesting idea

Hey @asuiu , I think this is a very interesting idea and attractive for a project I'm managing.
I'd be interested to know if you have plans to implement the various MigrationStrategies?
Also I was taking a look at some examples and if I'm not mistaken, in 1.2.24 some are no longer working because of recent changes (unless I'm mistaken?) Can you let me know if I should be able to do this?
from sparkorm import Struct

e.g. https://github.com/asuiu/SparkORM/blob/master/examples/conferences_extended/conferences.py#L3

Hi!
You are right, the from sparkorm import Struct doesn't work due to not exported Struct in the init.
I have fixed this, and the example should work now, in the version 1.2.25, uploaded on PyPi as well.
Yes, I have plans to implement more MigrationStrategies. Do you have any specific examples in mind?

Nice.
Yes, I have a couple concrete use cases for migration strategies right now actually!
The simplest is "add new column to existing schema."
The other immediate use is "modify existing column type, given a specified cast":

Simple example would be "cast IntegerType to DoubleType"
More complex example would be "cast LongType epoch in usecs to TimestampType"


ddev drupal install says site installed but no tables in database

I'm following the readme instructions and reach the ddev drupal install phase.
$ ddev drupal install

 Select an installation profile [Install with commonly used features pre-configured.]:
  [standard  ] Install with commonly used features pre-configured.
  [minimal   ] Build a custom site without pre-configured functionality. Suitable for advanced users.
  [demo_umami] Install an example site that shows off some of Drupal’s capabilities.
 >

17/17 [▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓]
Congratulations, you installed Drupal!
Username: admin
Password: <password>

then I run echo 'show tables' |ddev mysql and nothing is shown, indicating that the DB is in fact empty.

@kekkis have you customised anything in your drupal core checkout? When you run ddev drupal login does the generated link work?

@justafish, no customisation has happened except that I cloned the repo into a directory called drupal-core instead of drupal. The link results in a valid-looking URL (https://drupal-core.ddev.site/user/reset/1/1699618202/dVx_Kz-eyw9pLFLiqSiDQzu4xdF1cZ1476q0GncahoM) which fails with HTTP 404 "File not found" obviously being sent by nginx.

Same happens even if I use a directory called drupal for the git clone.

I think I have made a mistake at first because following the instruction to the letter actually now did give me a working site installed. Sorry for the false alarm.


Polish how we pass -Djavax.net.ssl.trustStore to the Solr test #2029

Fix #2029
Could you please review, @zbendhiba ?

@ppalaga For JVM, mode it looks good to me. I can't tell for native mode.

Ah, the native test would work if the JVM would be run in advance, but apparently on the CI this is not the case. Let me fix it.

In 08e7dc6 I abandoned the idea with JUnit extension. All is done via Maven pom.xml. I think it is easier to follow like that. The downside is that some special pom setup will be needed on the Platform. Could you please re-review, @zbendhiba ?

I have filed https://github.com/quarkusio/quarkus/issues/13752 and added this and this as a workaround.


Fix branch page pull request title and link error

Fix #8305.
This PR will display <owner>/<repo>#<number> on branches if the repository is a forked repository and the branch has sent a PR to base repository.

Integration tests fail

Codecov Report

Merging #10092 into master will increase coverage by <.01%.
The diff coverage is 100%.

@@            Coverage Diff             @@
##           master   #10092      +/-   ##
==========================================
+ Coverage   43.45%   43.45%   +<.01%
==========================================
  Files         566      566
  Lines       78987    78989       +2
==========================================
+ Hits        34321    34324       +3
+ Misses      40430    40426       -4
- Partials     4236     4239       +3

Impacted Files
Coverage Δ

routers/repo/branch.go
55.72% <100%> (+0.34%)
:arrow_up:

services/pull/patch.go
67.92% <0%> (-1.89%)
:arrow_down:

modules/queue/manager.go
60.51% <0%> (-1.54%)
:arrow_down:

modules/log/event.go
64.61% <0%> (-1.03%)
:arrow_down:

routers/repo/view.go
39.47% <0%> (+0.87%)
:arrow_up:

models/unit.go
39.5% <0%> (+2.46%)
:arrow_up:

services/pull/temp_repo.go
34.18% <0%> (+2.56%)
:arrow_up:

Continue to review full report at Codecov.

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

Please send backports


Edit button on recurring transactions triggers delete

Fixed on master branch. Will be available on today's release.


Snapshot

Currently we are using subprocess to run the snapshot.js file
in the snapshot directory.
This is because there is no Python Library for Snapshot, and the JS
Library appears to utilize signing messages using EIP-712 standard which
no library appears to exist for this in Python.
The API requires that the message is signed using EIP-712 standard. More
information is here:
https://snapshot.mirror.xyz/vuManI14DW8u2zhrlskndNgQcXOTbKIelQvkgmxOG2k
We could try and make this ourselves but it could be a lot of work and
I am not sure if it is worth it at the moment

Whats going on here? this creates zombie or ghost branches and pings me

We spoke about Snapshot and / gov-bot the other day, I was going to merge to do testing and realized I should have done it locally instead. Sorry for the unnecessary ping.

No worries


Fixes issue with BuilderDefault used with Builder and NoArgsConstructor.

Below tests demos the issue this change fixes.  Basically if you want to use both @Builder and @NoArgsConstructor which we do because of legacy code, the @Builder.Default breaks the default initialization for @NoArgsConstructor.  We'd like the defaults values initialized when using both the builder and no arg construction of the object.
public class BuilderDefaultIssueUnitTest {
    @Test
    public void test() {
        Example example1 = Example.builder().build();
        Example example2 = new Example();

        assertEquals(example1.getSomeDefInitInteger(),example2.getSomeDefInitInteger());
        assertEquals(example2.getSomeDefInitString(),example1.getSomeDefInitString());
    }

    @Data
    @Builder
    @AllArgsConstructor
    @NoArgsConstructor
    public static class Example {
        @Builder.Default
        private int someDefInitInteger = 5;
        @Builder.Default
        private String someDefInitString = "Hello";
    }
}

Well, it fixes one problem and introduces another. If the initializer is a "complex operation", for every object created by the builder it is now executed twice.
Reinier and I are aware of the problem and are considering several solutions, but we have no clear winner yet. Possibly, the best solution is to duplicate the initializer code in the generated no-args constructor, and possible also in the applicable required args constructors if the fields are nullable.
For now, the workaroun is to type a no-args constructor and initialize the fields with the same expression in the constructor.

I see... I think your probably right generating the code in the no arg constructor is probably best.

I was just pointed at this issue by a colleague of mine who found this behavior and was unpleasantly surprised by it.
I do believe that the argument that @rspilker pointed out of of optimizing potentially expensive initialization logic is not really in the responsibility of the tool, but rather a responsibility of the developer.
I have no concrete metrics to offer, but my gut feeling based on the kind of code bases I've seen (and believe me -- none of them have been shining examples of Clean Code or beacons of hope for believers in SOLID architecture), most of the field initialization logic has been rather trivial static default values (new empty arrays, constant literal values, null, etc.); Very few involve minimal calculation and extremely rarely is there an expensive computation involved.
Optimising for rare conditions seems like a weird choice given the widespread use and generality of the tool. And one that introduces surprising and rather unwelcome results for the end users.
So, from my completely biased and uninformed position, the current solution breaks more expectations than it solves any existing problems.
So, I would of course prefer if Lombok generated builders would be able to solve the expensive initialization issue in a way that it would be guaranteed to be performed only once without much extra effort from developer, but barring that, I would expect the developer to know how to counter such cases without

Very few involve minimal calculation and extremely rarely is there an expensive computation involved.

Sure, it's hardly ever possible to do anything useful in the initializer expression as it's executed before the constructor and can't depend on constructor arguments. Anything except initializing to suitable constant expression is very rare. The most expensive thing, I've ever seen there was a 16 kB buffer allocation and a static AtomicInteger instance counter increment (which is a bad design). Anyway, such cases are rather exceptional and then there's usually no use for a Builder.

Please fix this. I just lost a day's work when I ran into this after refactoring an extensive codebase. Its not mentioned in the documentation and I made the mistake of trusting that. Another complicating factor was that de-lombok from the GUI (plugin) didn't show it up but tests proved 1.16.16 was broken in this respect. Very very confusing altogether.
I still love Lombok and will continue to recommend it but this really saddens me.

Fixed in a different way, see issue #1347 .

Thanks Ronald, we removed most of the offending builders for now. Which maven release do you expect this to be included in?


{"error":"Authentication error"}

When tried to trigger event this error is occuring

use 123 or 1234 like that as app_id value for regex matching, it works fine now


Make CC-PAW purge itself correctly

This means deleting its cache directories, log directories, its startup file, its autorun file.

Done on dev branch with 0.4.3 pkg.lua

Should be working now. Can only really check on release since I'm bumping the version number now. o.o

Working on with cc-paw 0.5.0-dev release.

Working!


Add installation instructions

Can you include some instructions for installing this? It's unclear exactly what a user should do.
EDIT: nvm, just found them. Maybe just explain the link between the python and bash scripts more clearly?

Maybe just explain the link between the python and bash scripts more clearly?

The python script's file name's the clue - it handles the web search stuff. While the rofi-spotlight.sh handles all the search query (it passes the query to the python script if the query has a certain pattern - read README) and file search.

Yeah, totally understood. I'm just telling you that it wasn't immediately obvious to me how to install / use this, and that it might be worth improving the docs.

I didn't add an instruction of how to install it because I felt that there's no need for it. It's just:

Clone it.
Run it by rofi -modi "Global Search":"rofi-spotlight/rofi-spotlight.sh" -show "Global Search" \ -config rofi-spotlight/rofi.rasi.

Yes. I just assumed that everyone knew how to clone/download a repo. So yeah lol

Here's what each file does

Yeah, didn't think about explaining the files. Will add it to the docs.

Here's where they have to live (in relation to each other? Are you using $PATH to find them?, etc)

You can add the script to the $PATH or not. The path to script must be in the rofi command.
Anyway yeah the documentation needs an improvement but I don't really have time right now. Patches welcome, of course! Thank you for your input! Closing this for now.


Strip leading "." from versioned file name

splitext() will return the version as ".HASH", so the leading period needs to be stripped.
Fixes #90.

Thanks.

Will you release a new version in the near future?

@miracle2k Hello. Could you please release a new version with the latests merged fixes, please? Thanks!


Reusing simple structs in the bridge interface

We have a Rust API that we're trying to expose to C++. It has a ton of simple structs like this:
#[derive(Debug)]
pub struct LibVersion {
  pub string: String,
  pub package_hash: String,
  pub major: u32,
  pub minor: u32,
  pub point: u32,
}

#[derive(Debug, Clone)]
pub struct CompilationTraceEvent {
  pub cat: String,
  pub dur: u64,
  pub name: String,
  pub ph: String,
  pub pid: u32,
  pub tid: u32,
  pub ts: u64,
}

pub struct ItemType {
  pub name: String,
  pub size: u64,
  pub source: ItemSource,
}

#[derive(Debug, Copy, Clone)]
pub enum ItemSource {
  A,
  B,
}

You get the idea. In order to expose these to C++ the obvious but annoying thing to do is to copy/paste them all into the mod ffi { and then tediously add From implementations. Obviously not ideal!
The second best solution that I can think of at the moment is to move everything into the ffi mod, and then we can add pub use ffi::LibVersion etc. which is much less tedious. I think this will work, but it seems like only Copy and Clone auto-derive traits are supported by the macro.
I assume the proc macro system only gives you the contents of the macro, so you could never do something like mod ffi { type LibVersion = super::LibVersion; } because then your proc macro has no idea what the fields of super::LibVersion are - is that right?
I'm not sure what the solution is here but it's definitely an annoying problem....

Has anyone figured out what to do in this situation? CXX seems awesome but we have a lot of structs with custom derives and have run into exactly the same problem here...

@Timmmm Did you ever figure out a workaround for this?

I don't think so, sorry. :-/

The discussion under #1077 lays out the supported options for reusing simple structs in the bridge interface.


go.mod is redirecting away from this project to a fork

Describe the bug
A clear and concise description of what the bug is.
To Reproduce
Steps to reproduce the behavior(Be specific!):

Go to the command line and type the following and observe
go get github.com/nutsdb/nutsdb
go<EMAIL_ADDRESS>parsing go.mod:
module declares its path as: github.com/xujiajun/nutsdb
but was required as: github.com/nutsdb/nutsdb

Expected behavior
A clear and concise description of what you expected to happen.
I did not expect to see such an unexpected result.  I would have expected the module links to the correct github organization.
What actually happens
A clear and concise description of what actually happens.
See above.

Actually, we use this one  github.com/xujiajun/nutsdb in our code, so maybe we need to change it.  @xujiajun

#281


make snow diagrams

Draw static snow diagrams in a similar vein to  the fire-hydro pre- and post-  fire diagrams. Could keep them mostly the same and adapt the color scheme to this page, add relevance to some snow-to-flow process. Concept needs to be pinned down, but some ideas are:

the effect of fire on snowmelt timing and magnitude, build off fire (https://labs.waterdata.usgs.gov/visualizations/fire-hydro/index.html#/)
seasonal drivers of snow > flow relationships. see: https://agupubs.onlinelibrary.wiley.com/doi/full/10.1029/2019WR026132
different types of snow
how  climate and snowmelt affect runoff generation (https://hess.copernicus.org/articles/23/3553/2019/hess-23-3553-2019.html)

This is in the completed page.


Paimon:

Please make sure you have read the Wechaty Puppet Service: Paimon from Wechaty Official Website before you continue writting this issue.
Question
message.to_recall 接口不能获取已撤回的消息内容

2022-07-06 14:12:14,650 - Message - INFO - get recall message <

wxid_6885978859215
1169038710
5756993658152928858
"哇哇哇" 撤回了一条消息

2022-07-06 14:12:14,652 - Message - ERROR - can"t load or ready message payload ()
2022-07-06 14:12:14,652 - Wechaty - ERROR - internal error <WechatyOperationError('can"t load or ready message payload ()', None, None)>

You can't recall the expired message.


TypeError: self.vmTraces[self.processingHash] is undefined

The above error is reported right after construction in all constant functions (it goes away if you run the function explicitly) for the following source code:
contract Employee{
string public name;
string public locaon;
string public doj;
uint public empno;
uint public role;
}

Duplicate of https://github.com/ethereum/browser-solidity/issues/248 but it seems to be easier to reproduce.