home / github

Menu
  • GraphQL API
  • Search all tables

issues

Table actions
  • GraphQL API for issues

6 rows where state = "closed" and user = 40136154 sorted by updated_at descending

✎ View and edit SQL

This data as json, CSV (advanced)

Suggested facets: comments, closed_at, created_at (date), updated_at (date), closed_at (date)

type 2

  • pull 5
  • issue 1

state 1

  • closed · 6 ✖

repo 1

  • xarray 6
id node_id number title user state locked assignee milestone comments created_at updated_at ▲ closed_at author_association active_lock_reason draft pull_request body reactions performed_via_github_app state_reason repo type
606823874 MDExOlB1bGxSZXF1ZXN0NDA4OTQ3MjQ0 4006 fix dangerous default arguments pnijhara 40136154 closed 0     3 2020-04-25T18:05:11Z 2020-05-23T17:41:56Z 2020-05-23T17:30:51Z CONTRIBUTOR   0 pydata/xarray/pulls/4006
  • [x] Closes #4002
  • [ ] Passes isort -rc . && black . && mypy . && flake8
  • [ ] Fully documented, including whats-new.rst for all changes and api.rst for new API
{
    "url": "https://api.github.com/repos/pydata/xarray/issues/4006/reactions",
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
    xarray 13221727 pull
606549469 MDU6SXNzdWU2MDY1NDk0Njk= 4002 Remove dangerous default argument pnijhara 40136154 closed 0     16 2020-04-24T19:58:59Z 2020-05-23T17:30:51Z 2020-05-23T17:30:51Z CONTRIBUTOR      

Hi, It is good not to use the default arguments while calling a function.

MCVE Code Sample

In file xarray/tests/test_conventions.py ```python

Your code here

329 @contextlib.contextmanager 330 def roundtrip( 331 self, data, save_kwargs={}, open_kwargs={}, allow_cleanup_failure=False332 ): 333 store = CFEncodedInMemoryStore() 334 data.dump_to_store(store, **save_kwargs) ```

Problem Description

Default arguments in Python are evaluated once when the function definition is executed. This means that the expression is evaluated only once when the function is defined and that the same value is used for each subsequent call. So if you are modifying the mutable default argument — a list, dict, etc., it will be modified for all future calls.

{
    "url": "https://api.github.com/repos/pydata/xarray/issues/4002/reactions",
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  completed xarray 13221727 issue
613516581 MDExOlB1bGxSZXF1ZXN0NDE0MjU1NDg3 4038 Use literal syntax instead of function calls to create the data structure pnijhara 40136154 closed 0     1 2020-05-06T18:17:40Z 2020-05-06T22:55:40Z 2020-05-06T22:55:40Z CONTRIBUTOR   0 pydata/xarray/pulls/4038
  • [x] Passes isort -rc . && black . && mypy . && flake8
  • [x] Fully documented, including whats-new.rst for all changes and api.rst for new API

It is slower to call e.g. list() than using the empty literal, because the name list must be looked up in the global scope in case it has been rebound. Same for the other two types like dict() and tuple().

{
    "url": "https://api.github.com/repos/pydata/xarray/issues/4038/reactions",
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
    xarray 13221727 pull
605921766 MDExOlB1bGxSZXF1ZXN0NDA4MjM4MDUw 3999 Fix some code quality and bug-risk issues pnijhara 40136154 closed 0     3 2020-04-23T22:46:31Z 2020-05-05T02:21:12Z 2020-04-24T07:14:55Z CONTRIBUTOR   0 pydata/xarray/pulls/3999
  • Fix dangerous default argument
  • Remove unnecessary comprehension

Find the other issues found here - https://deepsource.io/gh/pnijhara/xarray/issues/?category=all This PR also adds .deepsource.toml configuration file to run DeepSource analysis on the repo with. Upon enabling DeepSource, the analysis will run on every PR and commit to detect 560+ types of issues in the changes — including bug risks, anti-patterns, security vulnerabilities, etc.

To enable DeepSource analysis after merging this PR, please follow these steps:

  1. Signup on DeepSource with your GitHub account and grant access to this repo.
  2. Activate analysis on this repo here

You can also look at the docs for more details. Do let me know if I can be of any help!

{
    "url": "https://api.github.com/repos/pydata/xarray/issues/3999/reactions",
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
    xarray 13221727 pull
611850402 MDExOlB1bGxSZXF1ZXN0NDEyOTMxNjc1 4026 chore: Remove unnecessary comprehension pnijhara 40136154 closed 0     5 2020-05-04T12:49:41Z 2020-05-05T01:57:32Z 2020-05-05T01:57:31Z CONTRIBUTOR   0 pydata/xarray/pulls/4026
  • [x] Passes isort -rc . && black . && mypy . && flake8
  • [x] Fully documented, including whats-new.rst for all changes and api.rst for new API
{
    "url": "https://api.github.com/repos/pydata/xarray/issues/4026/reactions",
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
    xarray 13221727 pull
606822020 MDExOlB1bGxSZXF1ZXN0NDA4OTQ1ODk4 4005 Fix dangerous default argument pnijhara 40136154 closed 0     0 2020-04-25T17:55:07Z 2020-04-25T17:58:24Z 2020-04-25T17:55:32Z CONTRIBUTOR   0 pydata/xarray/pulls/4005
  • [x] Closes #4002
  • [ ] Tests added
  • [ ] Passes isort -rc . && black . && mypy . && flake8
  • [ ] Fully documented, including whats-new.rst for all changes and api.rst for new API
{
    "url": "https://api.github.com/repos/pydata/xarray/issues/4005/reactions",
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
    xarray 13221727 pull

Advanced export

JSON shape: default, array, newline-delimited, object

CSV options:

CREATE TABLE [issues] (
   [id] INTEGER PRIMARY KEY,
   [node_id] TEXT,
   [number] INTEGER,
   [title] TEXT,
   [user] INTEGER REFERENCES [users]([id]),
   [state] TEXT,
   [locked] INTEGER,
   [assignee] INTEGER REFERENCES [users]([id]),
   [milestone] INTEGER REFERENCES [milestones]([id]),
   [comments] INTEGER,
   [created_at] TEXT,
   [updated_at] TEXT,
   [closed_at] TEXT,
   [author_association] TEXT,
   [active_lock_reason] TEXT,
   [draft] INTEGER,
   [pull_request] TEXT,
   [body] TEXT,
   [reactions] TEXT,
   [performed_via_github_app] TEXT,
   [state_reason] TEXT,
   [repo] INTEGER REFERENCES [repos]([id]),
   [type] TEXT
);
CREATE INDEX [idx_issues_repo]
    ON [issues] ([repo]);
CREATE INDEX [idx_issues_milestone]
    ON [issues] ([milestone]);
CREATE INDEX [idx_issues_assignee]
    ON [issues] ([assignee]);
CREATE INDEX [idx_issues_user]
    ON [issues] ([user]);
Powered by Datasette · Queries took 479.685ms · About: xarray-datasette