in_source_id stringlengths 13 58 | issue stringlengths 3 241k | before_files listlengths 0 3 | after_files listlengths 0 3 | pr_diff stringlengths 109 107M ⌀ |
|---|---|---|---|---|
elastic__ecs-1148 | Documentation Suggestion: anchor links on ECS fields
This is really pretty simple and I'm not sure where else to properly capture it.
The existing ECS documentation should have anchor tags on each field name in the ECS guide so you can easily deep-link directly to the relevant field.
When collaborating, often I... | [
{
"content": "import copy\nimport re\n\nfrom schema import visitor\n\n# This script takes the fleshed out deeply nested fields dictionary as emitted by\n# cleaner.py, and performs field reuse in two phases.\n#\n# Phase 1 performs field reuse across field sets. E.g. `group` fields should also be under `user`.\n#... | [
{
"content": "import copy\nimport re\n\nfrom schema import visitor\n\n# This script takes the fleshed out deeply nested fields dictionary as emitted by\n# cleaner.py, and performs field reuse in two phases.\n#\n# Phase 1 performs field reuse across field sets. E.g. `group` fields should also be under `user`.\n#... | diff --git a/docs/field-details.asciidoc b/docs/field-details.asciidoc
index 0303cb6e5b..0d41f4462c 100644
--- a/docs/field-details.asciidoc
+++ b/docs/field-details.asciidoc
@@ -12,7 +12,10 @@ The `base` field set contains all fields which are at the root of the events. Th
// =======================================... |
nf-core__tools-1357 | Linting should fail if pipeline module file is edited
In https://github.com/ewels/nf-core-methylseq/pull/2 I have edited a module file that was pulled from nf-core/modules. I shouldn't be allowed to do this.
The linting warns me that something is amiss:
```
│ bismark/align │ modules/nf... | [
{
"content": "\"\"\"\nCheck whether the content of a module has changed compared to the original repository\n\"\"\"\nimport os\nimport requests\nimport rich\nfrom nf_core.modules.lint import LintResult\n\n\ndef module_changes(module_lint_object, module):\n \"\"\"\n Checks whether installed nf-core modules... | [
{
"content": "\"\"\"\nCheck whether the content of a module has changed compared to the original repository\n\"\"\"\nimport os\nimport requests\nimport rich\nfrom nf_core.modules.lint import LintResult\n\n\ndef module_changes(module_lint_object, module):\n \"\"\"\n Checks whether installed nf-core modules... | diff --git a/CHANGELOG.md b/CHANGELOG.md
index 2234b207c3..c59818d907 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -50,6 +50,7 @@
* Check if README is from modules repo
* Update module template to DSL2 v2.0 (remove `functions.nf` from modules template and updating `main.nf` ([#1289](https://github.com/nf-core/tool... |
mathesar-foundation__mathesar-1670 | Filters not applied when calculating count of items within group
## Reproduce
1. Go to the Library Management schema.
1. Load the Table Page for the Publications table.
1. Group by "Publication Year".
1. Observe the first group, for year 1900, to contain 10 records and to display a "Count" of 10. Good.
1. Add a filter... | [
{
"content": "from db.transforms.base import enforce_relation_type_expectations, Transform\nfrom db.transforms import base\n\n\ndef apply_transformations(relation, transformations):\n enforce_relation_type_expectations(relation)\n for transform in transformations:\n relation = _apply_transform(rela... | [
{
"content": "from db.transforms.base import enforce_relation_type_expectations, Transform\nfrom db.transforms import base\n\n\ndef apply_transformations(relation, transformations):\n enforce_relation_type_expectations(relation)\n for transform in transformations:\n relation = _apply_transform(rela... | diff --git a/db/tests/tables/operations/test_select.py b/db/tests/tables/operations/test_select.py
index 373e05db27..44d5832456 100644
--- a/db/tests/tables/operations/test_select.py
+++ b/db/tests/tables/operations/test_select.py
@@ -224,7 +224,7 @@ def test_get_description_from_table(roster_table_name, engine_with_ro... |
pytorch__vision-3710 | Unable to load CelebA dataset: "File is not zip file" error.
## 🐛 Bug
I am unable to download the CelebFace Attributes (CelebA) dataset using TorchVision. The error I get when attempting to download is "File is not a zip file."
I have encountered this error every time I've tried to download the file, over the c... | [
{
"content": "import os\nimport os.path\nimport hashlib\nimport gzip\nimport re\nimport tarfile\nfrom typing import Any, Callable, List, Iterable, Optional, TypeVar, Dict, IO, Tuple\nfrom urllib.parse import urlparse\nimport zipfile\nimport lzma\nimport contextlib\nimport urllib\nimport urllib.request\nimport u... | [
{
"content": "import os\nimport os.path\nimport hashlib\nimport gzip\nimport re\nimport tarfile\nfrom typing import Any, Callable, List, Iterable, Optional, TypeVar, Dict, IO, Tuple\nfrom urllib.parse import urlparse\nimport zipfile\nimport lzma\nimport contextlib\nimport urllib\nimport urllib.request\nimport u... | diff --git a/torchvision/datasets/utils.py b/torchvision/datasets/utils.py
index 8da26d6e98e..0d1d879f045 100644
--- a/torchvision/datasets/utils.py
+++ b/torchvision/datasets/utils.py
@@ -175,9 +175,11 @@ def list_files(root: str, suffix: str, prefix: bool = False) -> List[str]:
def _quota_exceeded(response: "req... |
Lightning-AI__torchmetrics-1460 | MultioutputWrapper does not reset cleanly
## 🐛 Bug
Calling `MultioutputWrapper.compute()` after `MultioutputWrapper.reset()` returns old metrics that should have been cleared by the reset.
### To Reproduce
<!-- If you have a code sample, error messages, stack traces, please provide it here as well -->
###... | [
{
"content": "from copy import deepcopy\nfrom typing import Any, List, Tuple\n\nimport torch\nfrom torch import Tensor\nfrom torch.nn import ModuleList\n\nfrom torchmetrics import Metric\nfrom torchmetrics.utilities import apply_to_collection\n\n\ndef _get_nan_indices(*tensors: Tensor) -> Tensor:\n \"\"\"Get... | [
{
"content": "from copy import deepcopy\nfrom typing import Any, Callable, List, Tuple\n\nimport torch\nfrom torch import Tensor\nfrom torch.nn import ModuleList\n\nfrom torchmetrics import Metric\nfrom torchmetrics.utilities import apply_to_collection\n\n\ndef _get_nan_indices(*tensors: Tensor) -> Tensor:\n ... | diff --git a/CHANGELOG.md b/CHANGELOG.md
index 2b0b00933dd..1edf4b27f75 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -13,8 +13,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- Added support for plotting of metrics through `.plot()` method ([#1328](https://github.com/Lightni... |
angr__angr-1862 | Strange successors of the return block of a function
I'm analysing a MIPS binary when facing the problem.
The problem exists in the funcition `do_ssc`.
In the following block which has a return statement
... | [
{
"content": "\nimport logging\n\nimport pyvex\nimport archinfo\n\n\nfrom .... import options, BP_BEFORE\nfrom ....blade import Blade\nfrom ....annocfg import AnnotatedCFG\nfrom ....exploration_techniques import Slicecutor\n\nfrom .resolver import IndirectJumpResolver\n\n\nl = logging.getLogger(name=__name__)\n... | [
{
"content": "\nimport logging\n\nimport pyvex\nimport archinfo\n\n\nfrom .... import options, BP_BEFORE\nfrom ....blade import Blade\nfrom ....annocfg import AnnotatedCFG\nfrom ....exploration_techniques import Slicecutor\n\nfrom .resolver import IndirectJumpResolver\n\n\nl = logging.getLogger(name=__name__)\n... | diff --git a/angr/analyses/cfg/indirect_jump_resolvers/mips_elf_fast.py b/angr/analyses/cfg/indirect_jump_resolvers/mips_elf_fast.py
index b74dc119652..821e131c8c7 100644
--- a/angr/analyses/cfg/indirect_jump_resolvers/mips_elf_fast.py
+++ b/angr/analyses/cfg/indirect_jump_resolvers/mips_elf_fast.py
@@ -97,7 +97,13 @@ ... |
scrapy__scrapy-504 | get_func_args() from scrapy.utils.python crashes on partial functions
I use Python 2.7 and used a partial function (`functools.partial`) as part of an input_processor for the ItemLoader. For instance,
``` python
price = Field(input_processor=Compose(some_partial_func, some_other_func))
```
During execution, `get_func... | [
{
"content": "\"\"\"\nThis module contains essential stuff that should've come with Python itself ;)\n\nIt also contains functions (or functionality) which is in Python versions\nhigher than 2.5 which used to be the lowest version supported by Scrapy.\n\n\"\"\"\nimport os\nimport re\nimport inspect\nimport weak... | [
{
"content": "\"\"\"\nThis module contains essential stuff that should've come with Python itself ;)\n\nIt also contains functions (or functionality) which is in Python versions\nhigher than 2.5 which used to be the lowest version supported by Scrapy.\n\n\"\"\"\nimport os\nimport re\nimport inspect\nimport weak... | diff --git a/scrapy/tests/test_utils_python.py b/scrapy/tests/test_utils_python.py
index 24e96275426..ca73bc5ac27 100644
--- a/scrapy/tests/test_utils_python.py
+++ b/scrapy/tests/test_utils_python.py
@@ -1,3 +1,4 @@
+import functools
import operator
import unittest
from itertools import count
@@ -174,12 +175,14 @@ ... |
dotkom__onlineweb4-268 | Registering user messes up values of address and zip code
For example trying to register with the zip code 1234 will add the value (u'1234',) to the database. Exact same thing with address.
This also causes the zip code to go over the 4 character limit which again causes the database (if it's not SQLite) to throw an ... | [
{
"content": "# -*- coding: utf-8 -*-\n\nimport uuid\nimport re\n\nfrom django.contrib import auth\nfrom django.contrib import messages\nfrom django.core.mail import send_mail\nfrom django.shortcuts import render, redirect, get_object_or_404\nfrom django.http import HttpResponseRedirect\nfrom django.utils.trans... | [
{
"content": "# -*- coding: utf-8 -*-\n\nimport uuid\nimport re\n\nfrom django.contrib import auth\nfrom django.contrib import messages\nfrom django.core.mail import send_mail\nfrom django.shortcuts import render, redirect, get_object_or_404\nfrom django.http import HttpResponseRedirect\nfrom django.utils.trans... | diff --git a/apps/authentication/views.py b/apps/authentication/views.py
index 170d8deed..f9c968aaa 100644
--- a/apps/authentication/views.py
+++ b/apps/authentication/views.py
@@ -54,9 +54,9 @@ def register(request):
email=cleaned['email'].lower(),
)
# Set remaini... |
huggingface__transformers-9038 | "run_mlm_wwm.py", line 284 AttributeError: 'DataTrainingArguments' object has no attribute 'valid_ref_file'
Hi! There is a tiny typo in the code "transformers/examples/language-modeling/run_mlm_wwm.py" at line 284. It should be:
`if data_args.validation_ref_file is not None:` since at line 103 in `DataTrainingArgument... | [
{
"content": "# coding=utf-8\n# Copyright 2020 The HuggingFace Team All rights reserved.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# http://www.apache.org/licenses... | [
{
"content": "# coding=utf-8\n# Copyright 2020 The HuggingFace Team All rights reserved.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# http://www.apache.org/licenses... | diff --git a/examples/language-modeling/run_mlm_wwm.py b/examples/language-modeling/run_mlm_wwm.py
index e7c6505fc93e..4686a64047e0 100644
--- a/examples/language-modeling/run_mlm_wwm.py
+++ b/examples/language-modeling/run_mlm_wwm.py
@@ -281,7 +281,7 @@ def tokenize_function(examples):
# Add the chinese reference... |
microsoft__Qcodes-1089 | Bug in ramp_rate for AMI430 driver
### Bug
The following code (where ix is an AMI430 driver):
`ix.ramp_rate(0.001)`
produces an error:
`TypeError: ("'str' object is not callable", 'setting ix_ramp_rate to 0.001')`
### Proposed fix
In instrument_drivers/american_magnetics/AMI430.py line 367, change:
`rais... | [
{
"content": "import collections\nimport logging\nimport time\nfrom functools import partial\nfrom warnings import warn\n\nimport numpy as np\n\nfrom qcodes import Instrument, IPInstrument, InstrumentChannel\nfrom qcodes.math.field_vector import FieldVector\nfrom qcodes.utils.validators import Bool, Numbers, In... | [
{
"content": "import collections\nimport logging\nimport time\nfrom functools import partial\nfrom warnings import warn\n\nimport numpy as np\n\nfrom qcodes import Instrument, IPInstrument, InstrumentChannel\nfrom qcodes.math.field_vector import FieldVector\nfrom qcodes.utils.validators import Bool, Numbers, In... | diff --git a/qcodes/instrument_drivers/american_magnetics/AMI430.py b/qcodes/instrument_drivers/american_magnetics/AMI430.py
index f54be1a8c61..bb151efd19e 100644
--- a/qcodes/instrument_drivers/american_magnetics/AMI430.py
+++ b/qcodes/instrument_drivers/american_magnetics/AMI430.py
@@ -364,7 +364,7 @@ def _get_ramp_r... |
Textualize__rich-2029 | [BUG] Incorrect type for print_json indent in __init__.py
**Describe the bug**
The type for `indent` (`indent: int = 2`) in `print_json` from the `__init__.py` file seems to be incorrect. In `console.py` it is typed as `indent: Union[None, int, str] = 2` and `print_json` in the init calls from console.py so it seems... | [
{
"content": "\"\"\"Rich text and beautiful formatting in the terminal.\"\"\"\n\nimport os\nfrom typing import Callable, IO, TYPE_CHECKING, Any, Optional\n\nfrom ._extension import load_ipython_extension\n\n__all__ = [\"get_console\", \"reconfigure\", \"print\", \"inspect\"]\n\nif TYPE_CHECKING:\n from .cons... | [
{
"content": "\"\"\"Rich text and beautiful formatting in the terminal.\"\"\"\n\nimport os\nfrom typing import Callable, IO, TYPE_CHECKING, Any, Optional, Union\n\nfrom ._extension import load_ipython_extension\n\n__all__ = [\"get_console\", \"reconfigure\", \"print\", \"inspect\"]\n\nif TYPE_CHECKING:\n fro... | diff --git a/CHANGELOG.md b/CHANGELOG.md
index 6a0e3e518..eb6b62623 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -22,6 +22,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- Fix syntax lexer guessing.
- Fixed Pretty measure not respecting expand_all https://github.com/Textualiz... |
scipy__scipy-3497 | BUG: linalg.hessenberg broken (wrong results)
The function `scipy.linalg.hessenberg` computes wrong factorizations. Minimal example:
``` python
import numpy
from scipy.linalg import hessenberg
A = numpy.eye(3)
A[-1,0] = 2
H, Q = hessenberg(A, calc_q=True)
print(A - Q.dot(H.dot(Q.T)))
```
yields
```
[[ 0. -2. 0.]
... | [
{
"content": "#\n# Author: Pearu Peterson, March 2002\n#\n# additions by Travis Oliphant, March 2002\n# additions by Eric Jones, June 2002\n# additions by Johannes Loehnert, June 2006\n# additions by Bart Vandereycken, June 2006\n# additions by Andrew D Straw, May 2007\n# additions by Tiziano Zito, Novembe... | [
{
"content": "#\n# Author: Pearu Peterson, March 2002\n#\n# additions by Travis Oliphant, March 2002\n# additions by Eric Jones, June 2002\n# additions by Johannes Loehnert, June 2006\n# additions by Bart Vandereycken, June 2006\n# additions by Andrew D Straw, May 2007\n# additions by Tiziano Zito, Novembe... | diff --git a/scipy/linalg/decomp.py b/scipy/linalg/decomp.py
index dd8848bd80dc..a294f02e030f 100644
--- a/scipy/linalg/decomp.py
+++ b/scipy/linalg/decomp.py
@@ -820,7 +820,7 @@ def hessenberg(a, calc_q=False, overwrite_a=False, check_finite=True):
raise ValueError('expected square matrix')
overwrite_a =... |
edgedb__edgedb-841 | Identifier quoting clashes with fully-qualified names
The point of identifier quoting is that it allows using non-alphanumeric characters or reserved keywords as identifiers. So consider the following:
```
CREATE TYPE `foo::Bar`;
```
It will be interpreted as a single identifier, which then gets prefixed with the `... | [
{
"content": "#\n# This source file is part of the EdgeDB open source project.\n#\n# Copyright 2014-present MagicStack Inc. and the EdgeDB authors.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy... | [
{
"content": "#\n# This source file is part of the EdgeDB open source project.\n#\n# Copyright 2014-present MagicStack Inc. and the EdgeDB authors.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy... | diff --git a/docs/edgeql/lexical.rst b/docs/edgeql/lexical.rst
index 3263eda6d72..e3702403180 100644
--- a/docs/edgeql/lexical.rst
+++ b/docs/edgeql/lexical.rst
@@ -25,11 +25,12 @@ There are two ways of writing identifiers in EdgeQL: plain and quoted.
The plain identifiers are similar to many other languages, they are... |
unionai-oss__pandera-943 | DataFrameSchema.from_yaml ignores "ordered"
We are using `DataFrameSchema.from_yaml` and our schema YAML file includes the line `ordered: true`. However, we found that the column order was not being validated as expected. By examining the string representation of the `DataFrameSchema` we observed that `ordered=False` -... | [
{
"content": "\"\"\"Module for reading and writing schema objects.\"\"\"\n\nimport warnings\nfrom collections.abc import Mapping\nfrom functools import partial\nfrom pathlib import Path\nfrom typing import Dict, Optional, Union\n\nimport pandas as pd\n\nimport pandera.errors\n\nfrom . import dtypes\nfrom .check... | [
{
"content": "\"\"\"Module for reading and writing schema objects.\"\"\"\n\nimport warnings\nfrom collections.abc import Mapping\nfrom functools import partial\nfrom pathlib import Path\nfrom typing import Dict, Optional, Union\n\nimport pandas as pd\n\nimport pandera.errors\n\nfrom . import dtypes\nfrom .check... | diff --git a/docs/source/schema_inference.rst b/docs/source/schema_inference.rst
index 93af3d11c..2b9e67325 100644
--- a/docs/source/schema_inference.rst
+++ b/docs/source/schema_inference.rst
@@ -237,6 +237,7 @@ is a convenience method for this functionality.
coerce: true
strict: false
unique: null
+ ... |
pyg-team__pytorch_geometric-7536 | Planetoid dtype mismatch for CiteSeer
### 🐛 Describe the bug
I find that I can't load the CiteSeer dataset with double precision
```python
import torch_geometric as tg
tg.datasets.Planetoid(root="/tmp", name="CiteSeer")
```
I get this error
```
File /user/work/pc22286/mambaforge/envs/dkm/lib/python3.11... | [
{
"content": "import os.path as osp\nimport sys\nimport warnings\nfrom itertools import repeat\n\nimport torch\n\nfrom torch_geometric.data import Data\nfrom torch_geometric.io import read_txt_array\nfrom torch_geometric.typing import SparseTensor\nfrom torch_geometric.utils import coalesce, index_to_mask, remo... | [
{
"content": "import os.path as osp\nimport sys\nimport warnings\nfrom itertools import repeat\n\nimport torch\n\nfrom torch_geometric.data import Data\nfrom torch_geometric.io import read_txt_array\nfrom torch_geometric.typing import SparseTensor\nfrom torch_geometric.utils import coalesce, index_to_mask, remo... | diff --git a/torch_geometric/io/planetoid.py b/torch_geometric/io/planetoid.py
index ba767668f21d..3026b11f5534 100644
--- a/torch_geometric/io/planetoid.py
+++ b/torch_geometric/io/planetoid.py
@@ -30,9 +30,9 @@ def read_planetoid_data(folder, prefix):
# as zero vectors to `tx` and `ty`.
len_test_ind... |
safe-global__safe-config-service-90 | Use different namespace and endpoint name for `/safe-apps`
The endpoint `/api/v1/safe-apps` is currently under the `v1` namespace and `safe-apps` endpoint name.
To align it better with the future endpoints the following should be changed:
- the namespace changes from `v1` to `safe-apps`
- the endpoint name chang... | [
{
"content": "from django.contrib import admin\nfrom django.http import HttpResponse\nfrom django.urls import include, path, re_path\nfrom drf_yasg.views import get_schema_view\nfrom rest_framework import permissions\n\nschema_view = get_schema_view(\n validators=[\"flex\", \"ssv\"],\n public=True,\n p... | [
{
"content": "from django.contrib import admin\nfrom django.http import HttpResponse\nfrom django.urls import include, path, re_path\nfrom drf_yasg.views import get_schema_view\nfrom rest_framework import permissions\n\nschema_view = get_schema_view(\n validators=[\"flex\", \"ssv\"],\n public=True,\n p... | diff --git a/src/config/urls.py b/src/config/urls.py
index c3c6a081..667fc0dd 100644
--- a/src/config/urls.py
+++ b/src/config/urls.py
@@ -11,7 +11,7 @@
)
urlpatterns = [
- path("api/v1/", include("safe_apps.urls", namespace="v1")),
+ path("api/v1/", include("safe_apps.urls", namespace="safe-apps")),
pat... |
google__turbinia-294 | Programatically setting config file
I am trying to write tests for the dftimewolf turbinia module. Loading the configuration on a system that doesn't have one will fail, so I am trying to manually feed in a test config data to see if the module behaves as expected.
I tried setting the `TURBINIA_CONFIG_PATH` environm... | [
{
"content": "# -*- coding: utf-8 -*-\n# Copyright 2016 Google Inc.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# http://www.apache.org/licenses/LICENSE-2.0\n#\n# U... | [
{
"content": "# -*- coding: utf-8 -*-\n# Copyright 2016 Google Inc.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# http://www.apache.org/licenses/LICENSE-2.0\n#\n# U... | diff --git a/turbinia/config/__init__.py b/turbinia/config/__init__.py
index f5cd54a05..0fb00bf64 100644
--- a/turbinia/config/__init__.py
+++ b/turbinia/config/__init__.py
@@ -85,12 +85,16 @@ def LoadConfig():
if CONFIG:
return CONFIG
+ # If the environment variable is set, take precedence over the pre-defi... |
apluslms__a-plus-1183 | Hide exercises in the maintenance mode from the course table of contents
Exercises in maintenance mode (LearningObject.status maintenance) should be hidden from course table of contents.
Exercises with the status hidden are already hidden in the table of contents. The maintenance mode could be handled in the code in... | [
{
"content": "from django.http.response import Http404\nfrom course.models import CourseModule, LearningObjectCategory\nfrom ..models import LearningObject\n\n\nclass NoSuchContent(Exception):\n pass\n\n\nclass HierarchyIterator:\n # pylint: disable-next=too-many-arguments\n def __init__(self, children... | [
{
"content": "from django.http.response import Http404\nfrom course.models import CourseModule, LearningObjectCategory\nfrom ..models import LearningObject\n\n\nclass NoSuchContent(Exception):\n pass\n\n\nclass HierarchyIterator:\n # pylint: disable-next=too-many-arguments\n def __init__(self, children... | diff --git a/exercise/cache/hierarchy.py b/exercise/cache/hierarchy.py
index a9b56d9d9..643018a61 100644
--- a/exercise/cache/hierarchy.py
+++ b/exercise/cache/hierarchy.py
@@ -302,7 +302,10 @@ def is_listed(cls, entry):
return (
entry.get('category_status') != LearningObjectCategory.STATU... |
cobbler__cobbler-3600 | `cobbler validate-autoinstalls`: Crashes with "Unhashable type Profile"
### Describe the bug
`cobbler validate-autoinstalls` is crashing even though with a single profile or distro added to Cobbler.
### Steps to reproduce
1. Install Cobbler
2. Import single distro/profile
3. Execute `cobbler validate-autoins... | [
{
"content": "\"\"\"\nThis module contains code in order to create the automatic installation files. For example kickstarts, autoyast files\nor preseed files.\n\"\"\"\n\nimport logging\nimport os\n\nfrom cobbler import autoinstallgen\nfrom cobbler import utils\n\nTEMPLATING_ERROR = 1\nKICKSTART_ERROR = 2\n\n\nc... | [
{
"content": "\"\"\"\nThis module contains code in order to create the automatic installation files. For example kickstarts, autoyast files\nor preseed files.\n\"\"\"\n\nimport logging\nimport os\n\nfrom cobbler import autoinstallgen\nfrom cobbler import utils\n\nTEMPLATING_ERROR = 1\nKICKSTART_ERROR = 2\n\n\nc... | diff --git a/cobbler/autoinstall_manager.py b/cobbler/autoinstall_manager.py
index 410f752264..72c9ae42d0 100644
--- a/cobbler/autoinstall_manager.py
+++ b/cobbler/autoinstall_manager.py
@@ -305,9 +305,9 @@ def validate_autoinstall_file(self, obj, is_profile: bool) -> list:
self.logger.info("------------------... |
buildbot__buildbot-790 | Implement missing worker email in the email reporter
This is done via creating a custom event message
which the mail reporter can listen to
note that an irc reporter could also listen to the message and alert accordingly
| [
{
"content": "# This file is part of Buildbot. Buildbot is free software: you can\n# redistribute it and/or modify it under the terms of the GNU General Public\n# License as published by the Free Software Foundation, version 2.\n#\n# This program is distributed in the hope that it will be useful, but WITHOUT\n... | [
{
"content": "# This file is part of Buildbot. Buildbot is free software: you can\n# redistribute it and/or modify it under the terms of the GNU General Public\n# License as published by the Free Software Foundation, version 2.\n#\n# This program is distributed in the hope that it will be useful, but WITHOUT\n... | diff --git a/master/buildbot/steps/source/svn.py b/master/buildbot/steps/source/svn.py
index 84f45247cf8d..b7810a0e2df8 100644
--- a/master/buildbot/steps/source/svn.py
+++ b/master/buildbot/steps/source/svn.py
@@ -187,6 +187,12 @@ def copy(self):
export_cmd = ['svn', 'export']
if self.revisio... |
lutris__lutris-4249 | Typo when no installed games.
### Bug description
When having no games installed from a source, there is a typo "No installed games found. Press Ctrl+H **so** show all games". "so" should be "to".
### How to Reproduce
Steps to reproduce the behavior:
1. Have no installed games for a specific source (for me, the lu... | [
{
"content": "\"\"\"Main window for the Lutris interface.\"\"\"\nimport os\nfrom collections import namedtuple\nfrom gettext import gettext as _\n\nfrom gi.repository import Gdk, Gio, GLib, GObject, Gtk\n\nfrom lutris import services, settings\nfrom lutris.database import categories as categories_db\nfrom lutri... | [
{
"content": "\"\"\"Main window for the Lutris interface.\"\"\"\nimport os\nfrom collections import namedtuple\nfrom gettext import gettext as _\n\nfrom gi.repository import Gdk, Gio, GLib, GObject, Gtk\n\nfrom lutris import services, settings\nfrom lutris.database import categories as categories_db\nfrom lutri... | diff --git a/lutris/gui/lutriswindow.py b/lutris/gui/lutriswindow.py
index 010040e13b..23dd30020b 100644
--- a/lutris/gui/lutriswindow.py
+++ b/lutris/gui/lutriswindow.py
@@ -418,7 +418,7 @@ def show_empty_label(self):
if self.filters.get("category") == "favorite":
self.show_label(_("Add g... |
openstates__openstates-scrapers-1994 | NY failing since at least 2017-12-03
NY has been failing since 2017-12-03
Based on automated runs it appears that NY has not run successfully in 2 days (2017-12-03).
```
23:04:41 INFO pupa: save person Simotas, Aravella as person_a26f9bb2-d8b0-11e7-b5da-0242ac110006.json
23:04:41 INFO pupa: save membership a26f9bb... | [
{
"content": "import re\nimport datetime\n\nfrom pupa.scrape import Person, Scraper\nfrom openstates.utils import LXMLMixin\n\n\nclass NYPersonScraper(Scraper, LXMLMixin):\n def _split_list_on_tag(self, elements, tag):\n data = []\n for element in elements:\n element_class = None\n\n... | [
{
"content": "import re\nimport datetime\n\nfrom pupa.scrape import Person, Scraper\nfrom openstates.utils import LXMLMixin\n\n\nclass NYPersonScraper(Scraper, LXMLMixin):\n def _split_list_on_tag(self, elements, tag):\n data = []\n for element in elements:\n element_class = None\n\n... | diff --git a/openstates/ny/people.py b/openstates/ny/people.py
index f00712373d..53d5ddc009 100644
--- a/openstates/ny/people.py
+++ b/openstates/ny/people.py
@@ -405,7 +405,10 @@ def scrape_lower_chamber(self, chamber):
self.critical(
'Party for {} (Assembly district {}) has not b... |
mindsdb__mindsdb-813 | Add endpoint for mindsdb version
Add HTTP route to get a version of mindsdb: /util/version/
That should return as mindsb version in JSON view:
```
{
"mindsdb": "2.11.2"
}
```
The new endpoint needs to be added in [Utils](https://github.com/mindsdb/mindsdb/blob/staging/mindsdb/api/http/namespaces/util.py).
| [
{
"content": "from flask import request\nfrom flask_restx import Resource, abort\n\nfrom mindsdb.api.http.namespaces.configs.util import ns_conf\n\n\n@ns_conf.route('/ping')\nclass Ping(Resource):\n @ns_conf.doc('get_ping')\n def get(self):\n '''Checks server avaliable'''\n return {'status':... | [
{
"content": "from flask import request\nfrom flask_restx import Resource, abort\n\nfrom mindsdb.api.http.namespaces.configs.util import ns_conf\nfrom mindsdb import __about__\n\n@ns_conf.route('/ping')\nclass Ping(Resource):\n @ns_conf.doc('get_ping')\n def get(self):\n '''Checks server avaliable'... | diff --git a/mindsdb/api/http/namespaces/util.py b/mindsdb/api/http/namespaces/util.py
index 91011779ece..40deea4fc89 100644
--- a/mindsdb/api/http/namespaces/util.py
+++ b/mindsdb/api/http/namespaces/util.py
@@ -2,7 +2,7 @@
from flask_restx import Resource, abort
from mindsdb.api.http.namespaces.configs.util impor... |
ray-project__ray-7392 | Serialization of certain objects not handled correctly after 0.8.1
### What is the problem?
When using Ray 0.8.2 on Ubuntu 18.04, I am serializing data structures from the astropy library (https://pypi.org/project/astropy/ , version 4.0).
Previously, I have configured ray to use cloudpickle for many of these astr... | [
{
"content": "\"\"\"\nNew, fast version of the CloudPickler.\n\nThis new CloudPickler class can now extend the fast C Pickler instead of the\nprevious Python implementation of the Pickler class. Because this functionality\nis only available for Python versions 3.8+, a lot of backward-compatibility\ncode is also... | [
{
"content": "\"\"\"\nNew, fast version of the CloudPickler.\n\nThis new CloudPickler class can now extend the fast C Pickler instead of the\nprevious Python implementation of the Pickler class. Because this functionality\nis only available for Python versions 3.8+, a lot of backward-compatibility\ncode is also... | diff --git a/python/ray/cloudpickle/cloudpickle_fast.py b/python/ray/cloudpickle/cloudpickle_fast.py
index 75fd89e6b2c0..ccfee6c7aa0f 100644
--- a/python/ray/cloudpickle/cloudpickle_fast.py
+++ b/python/ray/cloudpickle/cloudpickle_fast.py
@@ -541,8 +541,8 @@ def reducer_override(self, obj):
# This is a patch f... |
Flexget__Flexget-3953 | Quality plugin <hdr not working
<!---
Before opening an issue, verify:
- Is this an issue with webui? Make an issue over on https://github.com/Flexget/webui
- Did you recently upgrade? Look at the Change Log and Upgrade Actions to make sure that you don't need to make any changes to your config https://flexget.com... | [
{
"content": "import copy\nimport functools\nimport re\nfrom typing import Dict, Iterator, List, Optional, Set, Tuple, Union\n\nfrom loguru import logger\n\nfrom flexget.utils.serialization import Serializer\n\nlogger = logger.bind(name='utils.qualities')\n\n\n@functools.total_ordering\nclass QualityComponent:\... | [
{
"content": "import copy\nimport functools\nimport re\nfrom typing import Dict, Iterator, List, Optional, Set, Tuple, Union\n\nfrom loguru import logger\n\nfrom flexget.utils.serialization import Serializer\n\nlogger = logger.bind(name='utils.qualities')\n\n\n@functools.total_ordering\nclass QualityComponent:\... | diff --git a/flexget/utils/qualities.py b/flexget/utils/qualities.py
index 439b8f767e..a41f61cbc6 100644
--- a/flexget/utils/qualities.py
+++ b/flexget/utils/qualities.py
@@ -164,8 +164,8 @@ def __deepcopy__(self, memo=None):
_color_ranges = [
QualityComponent('color_range', 10, '8bit', r'8[^\w]?bits?|hi8p?'),
... |
Pylons__pyramid-3657 | Sphinx doesn't like the reify decorator
> Failed to get a method signature for kinto.core.resource.Resource.timestamp: <pyramid.decorator.reify object at 0x7f175ae45640> is not a callable object
If I understand correctly this is because the reify decorator doesn't pass along the function signature.
| [
{
"content": "from functools import update_wrapper\n\n\nclass reify:\n \"\"\"Use as a class method decorator. It operates almost exactly like the\n Python ``@property`` decorator, but it puts the result of the method it\n decorates into the instance dict after the first call, effectively\n replacin... | [
{
"content": "class reify:\n \"\"\"Use as a class method decorator. It operates almost exactly like the\n Python ``@property`` decorator, but it puts the result of the method it\n decorates into the instance dict after the first call, effectively\n replacing the function it decorates with an instan... | diff --git a/CHANGES.rst b/CHANGES.rst
index a8e4d6c61a..4700258c5e 100644
--- a/CHANGES.rst
+++ b/CHANGES.rst
@@ -4,6 +4,9 @@ Unreleased
- Break potential reference cycle between ``request`` and ``context``.
See https://github.com/Pylons/pyramid/pull/3649
+- Remove ``update_wrapper`` from ``pyramid.decorator.rei... |
cornellius-gp__gpytorch-781 | [Bug] RBF Kernel is sometimes not positive definite
# 🐛 Bug
When I create a RBFKernel with 512 evenly spaced points between 500 and 501, and form the resulting kernel matrix, the matrix seems numerically positive definite (minimum eigenvalue is -1e-6). But, when I do the same with 513 points, the kernel matrix is v... | [
{
"content": "#!/usr/bin/env python3\n\nfrom abc import abstractmethod\nimport torch\nimport warnings\nfrom torch.nn import ModuleList\nfrom ..lazy import lazify, delazify, LazyEvaluatedKernelTensor, ZeroLazyTensor\nfrom ..module import Module\nfrom ..models.exact_prediction_strategies import DefaultPredictionS... | [
{
"content": "#!/usr/bin/env python3\n\nfrom abc import abstractmethod\nimport torch\nimport warnings\nfrom torch.nn import ModuleList\nfrom ..lazy import lazify, delazify, LazyEvaluatedKernelTensor, ZeroLazyTensor\nfrom ..module import Module\nfrom ..models.exact_prediction_strategies import DefaultPredictionS... | diff --git a/gpytorch/kernels/kernel.py b/gpytorch/kernels/kernel.py
index 9e33f874e..6643f5319 100644
--- a/gpytorch/kernels/kernel.py
+++ b/gpytorch/kernels/kernel.py
@@ -34,6 +34,10 @@ def _sq_dist(self, x1, x2, postprocess, x1_eq_x2=False):
# cdist is a bit faster on small tensors. Check again after py... |
litestar-org__litestar-1418 | StaticFilesConfig and virtual directories
I'm trying to write a ``FileSystemProtocol`` to load files from the package data using [importlib_resources](https://importlib-resources.readthedocs.io/en/latest/using.html#). But because ``directories`` is defined as ``DirectoryPath``, pydantic checks if the given directories ... | [
{
"content": "from datetime import date, datetime, time, timedelta\nfrom decimal import Decimal\nfrom inspect import isclass\nfrom ipaddress import IPv4Network, IPv6Network\nfrom typing import (\n TYPE_CHECKING,\n Any,\n Callable,\n Dict,\n List,\n Optional,\n Tuple,\n Type,\n Union,\... | [
{
"content": "from datetime import date, datetime, time, timedelta\nfrom decimal import Decimal\nfrom inspect import isclass\nfrom ipaddress import IPv4Network, IPv6Network\nfrom typing import (\n TYPE_CHECKING,\n Any,\n Callable,\n Dict,\n List,\n Optional,\n Tuple,\n Type,\n Union,\... | diff --git a/starlite/contrib/sqlalchemy_1/plugin.py b/starlite/contrib/sqlalchemy_1/plugin.py
index fa1a8e6d86..accfbf8bca 100644
--- a/starlite/contrib/sqlalchemy_1/plugin.py
+++ b/starlite/contrib/sqlalchemy_1/plugin.py
@@ -223,8 +223,6 @@ def providers_map(self) -> Dict[Type[TypeEngine], Callable[[Union[TypeEngine,... |
freedomofpress__securedrop-3464 | Formatting of i18 codes in includes/l10.txt and install.rst
## Description
The readability of the list of supported languages in `install.rst` could be improved.
## Suggestion
If the output in `includes/l10.txt` could include backticks around the language codes, it would make the section [here](https://docs.se... | [
{
"content": "#!/usr/bin/env python\n# -*- coding: utf-8 -*-\n\nimport argparse\nimport io\nimport logging\nimport os\nimport re\nimport signal\nimport subprocess\nimport sys\nimport textwrap\nimport version\n\nfrom os.path import dirname, join, realpath\n\nlogging.basicConfig(format='%(asctime)s %(levelname)s ... | [
{
"content": "#!/usr/bin/env python\n# -*- coding: utf-8 -*-\n\nimport argparse\nimport io\nimport logging\nimport os\nimport re\nimport signal\nimport subprocess\nimport sys\nimport textwrap\nimport version\n\nfrom os.path import dirname, join, realpath\n\nlogging.basicConfig(format='%(asctime)s %(levelname)s ... | diff --git a/docs/includes/l10n.txt b/docs/includes/l10n.txt
index d4013e9c2c..253b52b252 100644
--- a/docs/includes/l10n.txt
+++ b/docs/includes/l10n.txt
@@ -1,14 +1,14 @@
.. GENERATED BY i18n_tool.py DO NOT EDIT:
-* Arabic (ar)
-* German (de_DE)
-* Spanish (es_ES)
-* French (fr_FR)
-* Hindi (hi)
-* Italian (it_IT)... |
nltk__nltk-3022 | nltk.chat.chatbot() endless loop
When I type `import nltk` followed by `nltk.chat.chatbots()`, it lists/asks which one I want to talk to, and then endlessly scrolls the following: ` Enter a number in the range 1-5: Error: bad chatbot number`, in both Jupyter and Spyder.
| [
{
"content": "# Natural Language Toolkit: Chatbots\n#\n# Copyright (C) 2001-2022 NLTK Project\n# Authors: Steven Bird <stevenbird1@gmail.com>\n# URL: <https://www.nltk.org/>\n# For license information, see LICENSE.TXT\n\n# Based on an Eliza implementation by Joe Strout <joe@strout.net>,\n# Jeff Epler <jepler@in... | [
{
"content": "# Natural Language Toolkit: Chatbots\n#\n# Copyright (C) 2001-2022 NLTK Project\n# Authors: Steven Bird <stevenbird1@gmail.com>\n# URL: <https://www.nltk.org/>\n# For license information, see LICENSE.TXT\n\n# Based on an Eliza implementation by Joe Strout <joe@strout.net>,\n# Jeff Epler <jepler@in... | diff --git a/nltk/chat/__init__.py b/nltk/chat/__init__.py
index 59d1a4eca3..f0f0eb313e 100644
--- a/nltk/chat/__init__.py
+++ b/nltk/chat/__init__.py
@@ -33,15 +33,12 @@
def chatbots():
- import sys
-
print("Which chatbot would you like to talk to?")
botcount = len(bots)
for i in range(botcount)... |
pyro-ppl__pyro-198 | pytorch broadcasting
in various places in the codebase we have tensor ops like `expand_as()`. given the extended broadcasting functionality in the latest version of pytorch, some of these may be unnecessary and/or clunky. more generally, we should investigate and deal with any pytorch warnings that popped once once we ... | [
{
"content": "import argparse\n\nimport numpy as np\nimport torch\nimport torchvision.datasets as dset\nimport torchvision.transforms as transforms\nimport visdom\nfrom torch.autograd import Variable\nfrom torch.nn import Softmax\n\nimport pyro\nfrom pyro.distributions import Bernoulli, Categorical\nfrom pyro.i... | [
{
"content": "import argparse\n\nimport numpy as np\nimport torch\nimport torchvision.datasets as dset\nimport torchvision.transforms as transforms\nimport visdom\nfrom torch.autograd import Variable\nfrom torch.nn import Softmax\n\nimport pyro\nfrom pyro.distributions import Bernoulli, Categorical\nfrom pyro.i... | diff --git a/examples/categorical_bmm.py b/examples/categorical_bmm.py
index 5e52c1d8d7..038ff5a555 100644
--- a/examples/categorical_bmm.py
+++ b/examples/categorical_bmm.py
@@ -12,6 +12,7 @@
from pyro.distributions import Bernoulli, Categorical
from pyro.infer.kl_qp import KL_QP
+
mnist = dset.MNIST(
root='... |
jazzband__django-oauth-toolkit-239 | redirect uri on error (e.g. AuthCanceled) may contain two question marks, thus sending the wrong exception
I'm using django-oauth-toolkit along with python-social-auth and of course oauthlib which is a requirement of both, and I've run into an issue when the user clicks the "cancel" button.
The wrong exception may oc... | [
{
"content": "from __future__ import unicode_literals\n\nimport logging\n\nfrom django.core.exceptions import ImproperlyConfigured\nfrom django.http import HttpResponseForbidden\n\nfrom ..exceptions import FatalClientError\nfrom ..settings import oauth2_settings\n\n\nlog = logging.getLogger(\"oauth2_provider\")... | [
{
"content": "from __future__ import unicode_literals\n\nimport logging\n\nfrom django.core.exceptions import ImproperlyConfigured\nfrom django.http import HttpResponseForbidden\n\nfrom ..exceptions import FatalClientError\nfrom ..settings import oauth2_settings\n\n\nlog = logging.getLogger(\"oauth2_provider\")... | diff --git a/oauth2_provider/views/mixins.py b/oauth2_provider/views/mixins.py
index 168d5f42d..919878a9f 100644
--- a/oauth2_provider/views/mixins.py
+++ b/oauth2_provider/views/mixins.py
@@ -155,9 +155,17 @@ def error_response(self, error, **kwargs):
:param error: :attr:`OAuthToolkitError`
"""
... |
freqtrade__freqtrade-3913 | 0 trades --dmmp [Backtesting-Hyperopt]
## Describe your environment
* Operating system: Centos 7
* Python Version: 3.8
* CCXT version: 1.36.85
* Freqtrade Version: 2020.10
## Describe the problem:
When --dmmp option is enabled in backtesting or hyperopt, there are no trades. But when you don't... | [
{
"content": "# pragma pylint: disable=missing-docstring, W0212, too-many-arguments\n\n\"\"\"\nThis module contains the backtesting logic\n\"\"\"\nimport logging\nfrom collections import defaultdict\nfrom copy import deepcopy\nfrom datetime import datetime, timedelta\nfrom typing import Any, Dict, List, NamedTu... | [
{
"content": "# pragma pylint: disable=missing-docstring, W0212, too-many-arguments\n\n\"\"\"\nThis module contains the backtesting logic\n\"\"\"\nimport logging\nfrom collections import defaultdict\nfrom copy import deepcopy\nfrom datetime import datetime, timedelta\nfrom typing import Any, Dict, List, NamedTu... | diff --git a/freqtrade/optimize/backtesting.py b/freqtrade/optimize/backtesting.py
index 47bb9edd920..883f7338c23 100644
--- a/freqtrade/optimize/backtesting.py
+++ b/freqtrade/optimize/backtesting.py
@@ -340,7 +340,7 @@ def backtest(self, processed: Dict, stake_amount: float,
# max_open_trades must be... |
nautobot__nautobot-5492 | Duplicated entries in the Roles dropdown when creating a new Config Context
<!--
NOTE: IF YOUR ISSUE DOES NOT FOLLOW THIS TEMPLATE, IT WILL BE CLOSED.
This form is only for reporting reproducible bugs. If you need assistance
with Nautobot installation, or if you have a general question, please start a
... | [
{
"content": "from collections import OrderedDict\nfrom copy import deepcopy\nimport logging\nimport uuid\n\nfrom django import forms as django_forms\nfrom django.conf import settings\nfrom django.db import models\nfrom django.forms.utils import ErrorDict, ErrorList\nimport django_filters\nfrom django_filters.c... | [
{
"content": "from collections import OrderedDict\nfrom copy import deepcopy\nimport logging\nimport uuid\n\nfrom django import forms as django_forms\nfrom django.conf import settings\nfrom django.db import models\nfrom django.forms.utils import ErrorDict, ErrorList\nimport django_filters\nfrom django_filters.c... | diff --git a/changes/5431.fixed b/changes/5431.fixed
new file mode 100644
index 00000000000..66f4b1a54ee
--- /dev/null
+++ b/changes/5431.fixed
@@ -0,0 +1,2 @@
+Fixed Roles API response containing duplicate entries when filtering on more than one `content_types` value.
+Fixed Providers API response containing duplicate... |
qutip__qutip-2103 | Missing `__all__`
### Bug Description
Some files are missing `__all__` and leaking variables.
### Code to Reproduce the Bug
```shell
import qutip.measurement
qt.measurement.np
```
### Code Output
```shell
<module 'numpy' from 'miniconda3/lib/python3.10/site-packages/numpy/__init__.py'>
```
### Expected Behavio... | [
{
"content": "# -*- coding: utf-8 -*-\n\n\"\"\"\nThis module implements internal-use functions for semidefinite programming.\n\"\"\"\n\nimport collections\nimport functools\n\nimport numpy as np\nimport scipy.sparse as sp\n# Conditionally import CVXPY\ntry:\n import cvxpy\nexcept ImportError:\n cvxpy = No... | [
{
"content": "# -*- coding: utf-8 -*-\n\n\"\"\"\nThis module implements internal-use functions for semidefinite programming.\n\"\"\"\n\n__all__ = [\n 'dnorm_problem',\n 'dnorm_sparse_problem',\n]\n\nimport collections\nimport functools\n\nimport numpy as np\nimport scipy.sparse as sp\n# Conditionally impo... | diff --git a/doc/changes/2103.misc b/doc/changes/2103.misc
new file mode 100644
index 0000000000..aff1b7eb93
--- /dev/null
+++ b/doc/changes/2103.misc
@@ -0,0 +1 @@
+added __all__ to qutip/measurements.py and qutip/core/semidefinite.py
\ No newline at end of file
diff --git a/qutip/core/semidefinite.py b/qutip/core/sem... |
ckan__ckan-7483 | Pytest ckan_config does not override configurations from test.ini
## CKAN version
2.9, master
## Describe the bug
By configuring some variable in test.ini like `ckan.plugins` reduces duplication in tests themselves. However if test requires some other variable like different plugins, using `ckan_config` decorator ... | [
{
"content": "# encoding: utf-8\n'''CKAN environment configuration'''\nfrom __future__ import annotations\n\nimport os\nimport logging\nimport warnings\nimport pytz\n\nfrom typing import Union, cast\n\nimport sqlalchemy\nimport sqlalchemy.exc\n\nimport ckan.model as model\nimport ckan.plugins as p\nimport ckan.... | [
{
"content": "# encoding: utf-8\n'''CKAN environment configuration'''\nfrom __future__ import annotations\n\nimport os\nimport logging\nimport warnings\nimport pytz\n\nfrom typing import Union, cast\n\nimport sqlalchemy\nimport sqlalchemy.exc\n\nimport ckan.model as model\nimport ckan.plugins as p\nimport ckan.... | diff --git a/changes/7483.bugfix b/changes/7483.bugfix
new file mode 100644
index 00000000000..70fcb7b12b3
--- /dev/null
+++ b/changes/7483.bugfix
@@ -0,0 +1,3 @@
+In tests, templates from ``ckan.plugins`` set by the config file are used even
+if these plugins are disabled for the test via
+``pytest.mark.ckan_config("c... |
akvo__akvo-rsr-3210 | IATI export for project editors
Project editors are not able to export an IATI file although they have the interface.
| [
{
"content": "# -*- coding: utf-8 -*-\n\n# Akvo RSR is covered by the GNU Affero General Public License.\n# See more details in the license.txt file located at the root folder of the Akvo RSR module.\n# For additional details on the GNU license please see < http://www.gnu.org/licenses/agpl.html >.\n\n\nimport l... | [
{
"content": "# -*- coding: utf-8 -*-\n\n# Akvo RSR is covered by the GNU Affero General Public License.\n# See more details in the license.txt file located at the root folder of the Akvo RSR module.\n# For additional details on the GNU license please see < http://www.gnu.org/licenses/agpl.html >.\n\n\nimport l... | diff --git a/akvo/rsr/models/__init__.py b/akvo/rsr/models/__init__.py
index 049b75f0e7..7f2a52ecac 100644
--- a/akvo/rsr/models/__init__.py
+++ b/akvo/rsr/models/__init__.py
@@ -353,7 +353,7 @@
rules.add_perm('rsr.change_projectdocument', is_rsr_admin | is_org_admin | is_org_project_editor)
rules.add_perm('rsr.delet... |
mozilla__telemetry-analysis-service-812 | When a job terminates early a metrics recording error is thrown
There might be more than one issue here...
Recently a few jobs terminated early b/c of EBS volume limits. When that happened the status failed to update correctly and an error was reported to sentry when we try to calculate one of the metrics which is m... | [
{
"content": "# This Source Code Form is subject to the terms of the Mozilla Public\n# License, v. 2.0. If a copy of the MPL was not distributed with this\n# file, you can obtain one at http://mozilla.org/MPL/2.0/.\nimport math\nfrom datetime import timedelta\n\nimport urlman\nfrom autorepr import autorepr, aut... | [
{
"content": "# This Source Code Form is subject to the terms of the Mozilla Public\n# License, v. 2.0. If a copy of the MPL was not distributed with this\n# file, you can obtain one at http://mozilla.org/MPL/2.0/.\nimport math\nfrom datetime import timedelta\n\nimport urlman\nfrom autorepr import autorepr, aut... | diff --git a/atmo/jobs/models.py b/atmo/jobs/models.py
index 5290953d..101b7c4b 100644
--- a/atmo/jobs/models.py
+++ b/atmo/jobs/models.py
@@ -461,8 +461,10 @@ def sync(self, info=None):
}
)
+ if self.finished_at and self.ready_at:
# Wh... |
piskvorky__gensim-2288 | Incoherent topic word distributions after `malletmodel2ldamodel`
Hi everyone,
first off many thanks for providing such an awesome module! I am using `gensim` to do topic modeling with LDA and encountered the following bug/issue. I have already read about it in the [mailing list](https://groups.google.com/forum/#!topic... | [
{
"content": "#!/usr/bin/env python\n# -*- coding: utf-8 -*-\n#\n# Copyright (C) 2014 Radim Rehurek <radimrehurek@seznam.cz>\n# Licensed under the GNU LGPL v2.1 - http://www.gnu.org/licenses/lgpl.html\n\n\nr\"\"\"Python wrapper for `Latent Dirichlet Allocation (LDA) <https://en.wikipedia.org/wiki/Latent_Dirichl... | [
{
"content": "#!/usr/bin/env python\n# -*- coding: utf-8 -*-\n#\n# Copyright (C) 2014 Radim Rehurek <radimrehurek@seznam.cz>\n# Licensed under the GNU LGPL v2.1 - http://www.gnu.org/licenses/lgpl.html\n\n\nr\"\"\"Python wrapper for `Latent Dirichlet Allocation (LDA) <https://en.wikipedia.org/wiki/Latent_Dirichl... | diff --git a/gensim/models/wrappers/ldamallet.py b/gensim/models/wrappers/ldamallet.py
index 2649eb6953..e1bf2a85e8 100644
--- a/gensim/models/wrappers/ldamallet.py
+++ b/gensim/models/wrappers/ldamallet.py
@@ -588,9 +588,11 @@ def malletmodel2ldamodel(mallet_model, gamma_threshold=0.001, iterations=50):
"""
... |
ytdl-org__youtube-dl-4599 | cannot download Daum tvpot url
cannot download video from Daum tvpot which is Korean internet portal service
http://tvpot.daum.net/v/vfb45BtrWBWWHKEkOwXEghB
| [
{
"content": "# encoding: utf-8\n\nfrom __future__ import unicode_literals\n\nimport re\n\nfrom .common import InfoExtractor\nfrom ..compat import (\n compat_urllib_parse,\n)\n\n\nclass DaumIE(InfoExtractor):\n _VALID_URL = r'https?://(?:m\\.)?tvpot\\.daum\\.net/(?:v/|.*?clipid=)(?P<id>[^?#&]+)'\n IE_N... | [
{
"content": "# encoding: utf-8\n\nfrom __future__ import unicode_literals\n\nimport re\n\nfrom .common import InfoExtractor\nfrom ..compat import (\n compat_urllib_parse,\n)\n\n\nclass DaumIE(InfoExtractor):\n _VALID_URL = r'https?://(?:m\\.)?tvpot\\.daum\\.net/(?:v/|.*?clipid=)(?P<id>[^?#&]+)'\n IE_N... | diff --git a/youtube_dl/extractor/daum.py b/youtube_dl/extractor/daum.py
index c6b813f58ed..b4b3b795c10 100644
--- a/youtube_dl/extractor/daum.py
+++ b/youtube_dl/extractor/daum.py
@@ -38,7 +38,7 @@ def _real_extract(self, url):
canonical_url = 'http://tvpot.daum.net/v/%s' % video_id
webpage = self._d... |
openstates__openstates-scrapers-1987 | VT failing since at least 2017-12-02
VT has been failing since 2017-12-02
Based on automated runs it appears that VT has not run successfully in 2 days (2017-12-02).
```
00:02:03 INFO scrapelib: GET - http://legislature.vermont.gov/bill/status/2018/S.C.R.13
00:02:06 INFO scrapelib: GET - http://legislature.vermont... | [
{
"content": "import json\n\nfrom pupa.scrape import Person, Scraper\nfrom openstates.utils import LXMLMixin\n\n\nclass VTPersonScraper(Scraper, LXMLMixin):\n CHAMBERS = {'Senator': 'upper', 'Representative': 'lower'}\n\n def scrape(self, session=None):\n if session is None:\n session = ... | [
{
"content": "import json\n\nfrom pupa.scrape import Person, Scraper\nfrom openstates.utils import LXMLMixin\n\n\nclass VTPersonScraper(Scraper, LXMLMixin):\n CHAMBERS = {'Senator': 'upper', 'Representative': 'lower'}\n\n def scrape(self, session=None):\n if session is None:\n session = ... | diff --git a/openstates/vt/people.py b/openstates/vt/people.py
index bf91f75dc5..c4c2e18efe 100644
--- a/openstates/vt/people.py
+++ b/openstates/vt/people.py
@@ -24,6 +24,11 @@ def scrape(self, session=None):
# Strip whitespace from strings
info = {k: v.strip() for k, v in info.items()}
+ ... |
openmc-dev__openmc-2320 | High Temperature key error in from_njoy()
When using **openmc.data.IncidentNeutron.from_njoy()**, for high temperatures a python KeyError may arise.
For what I can say the problem arises from the following sequence of actions performed by this routine (in file neutron.py):
- Input temperature is taken in Kelvin... | [
{
"content": "from collections import OrderedDict\nfrom collections.abc import Mapping, MutableMapping\nfrom io import StringIO\nfrom math import log10\nfrom numbers import Integral, Real\nimport os\nimport tempfile\nfrom warnings import warn\n\nimport numpy as np\nimport h5py\n\nfrom . import HDF5_VERSION, HDF... | [
{
"content": "from collections import OrderedDict\nfrom collections.abc import Mapping, MutableMapping\nfrom io import StringIO\nfrom math import log10\nfrom numbers import Integral, Real\nimport os\nimport tempfile\nfrom warnings import warn\n\nimport numpy as np\nimport h5py\n\nfrom . import HDF5_VERSION, HDF... | diff --git a/openmc/data/neutron.py b/openmc/data/neutron.py
index db78ce27b86..e0574d76d4e 100644
--- a/openmc/data/neutron.py
+++ b/openmc/data/neutron.py
@@ -868,9 +868,8 @@ def get_file3_xs(ev, mt, E):
heatr_evals = get_evaluations(kwargs["heatr"])
heatr_local_evals = get_evaluations(kwa... |
pypa__pipenv-3352 | --site-packages is not recognized without --two or --three option
### Issue description
`--site-packages` is not recognized without `--two` or `--three` option.
PR: #3352
### Reason
`site_packages` argument in `cli` function always set to false because `--site-packages` flag was defined in the global state ... | [
{
"content": "# -*- coding: utf-8 -*-\nfrom __future__ import absolute_import\n\nimport os\nimport sys\n\nfrom click import (\n argument, echo, edit, group, option, pass_context, secho, version_option\n)\n\nimport click_completion\nimport crayons\nimport delegator\n\nfrom click_didyoumean import DYMCommandCo... | [
{
"content": "# -*- coding: utf-8 -*-\nfrom __future__ import absolute_import\n\nimport os\nimport sys\n\nfrom click import (\n argument, echo, edit, group, option, pass_context, secho, version_option\n)\n\nimport click_completion\nimport crayons\nimport delegator\n\nfrom click_didyoumean import DYMCommandCo... | diff --git a/news/3351.bugfix.rst b/news/3351.bugfix.rst
new file mode 100644
index 0000000000..d2d9c675f0
--- /dev/null
+++ b/news/3351.bugfix.rst
@@ -0,0 +1 @@
+Fix a bug that ``--site-packages`` flag is not recognized.
diff --git a/pipenv/cli/command.py b/pipenv/cli/command.py
index ae7111f1a0..ec1bef6138 100644
---... |
learningequality__kolibri-3616 | As superuser, users + collections belonging to other Facilities are appearing in facility management workflows
By default, the device owner (i.e. the first superuser) is created and made a Member of the Facility (Facility 1) made during the Setup Wizard.
However, if a second Facility (Facility 2) is created the devi... | [
{
"content": "from __future__ import absolute_import\nfrom __future__ import print_function\nfrom __future__ import unicode_literals\n\nimport time\n\nfrom django.contrib.auth import authenticate\nfrom django.contrib.auth import get_user\nfrom django.contrib.auth import login\nfrom django.contrib.auth import lo... | [
{
"content": "from __future__ import absolute_import\nfrom __future__ import print_function\nfrom __future__ import unicode_literals\n\nimport time\n\nfrom django.contrib.auth import authenticate\nfrom django.contrib.auth import get_user\nfrom django.contrib.auth import login\nfrom django.contrib.auth import lo... | diff --git a/kolibri/auth/api.py b/kolibri/auth/api.py
index 5ff357d3665..5e30eedc496 100644
--- a/kolibri/auth/api.py
+++ b/kolibri/auth/api.py
@@ -247,6 +247,7 @@ class PublicFacilityViewSet(viewsets.ReadOnlyModelViewSet):
class ClassroomFilter(FilterSet):
role = CharFilter(method="filter_has_role_for")
+ ... |
obspy__obspy-3209 | Pop check_compression from argument list for readers?
I wrote a small io plugin for ObsPy events based on zipped files, see https://github.com/trichter/obspycsv. Because ObsPy automatically unpacks zip files, I had some difficulties to get it working.
I found the check_compression argument in the uncompress_file decor... | [
{
"content": "# -*- coding: utf-8 -*-\n\"\"\"\nDecorator used in ObsPy.\n\n:copyright:\n The ObsPy Development Team (devs@obspy.org)\n:license:\n GNU Lesser General Public License, Version 3\n (https://www.gnu.org/copyleft/lesser.html)\n\"\"\"\nimport functools\nimport inspect\nfrom pathlib import Path... | [
{
"content": "# -*- coding: utf-8 -*-\n\"\"\"\nDecorator used in ObsPy.\n\n:copyright:\n The ObsPy Development Team (devs@obspy.org)\n:license:\n GNU Lesser General Public License, Version 3\n (https://www.gnu.org/copyleft/lesser.html)\n\"\"\"\nimport functools\nimport inspect\nfrom pathlib import Path... | diff --git a/obspy/core/util/decorator.py b/obspy/core/util/decorator.py
index 31819bc6e27..d4aa75118ad 100644
--- a/obspy/core/util/decorator.py
+++ b/obspy/core/util/decorator.py
@@ -164,8 +164,14 @@ def uncompress_file(func, filename, *args, **kwargs):
pass
elif zipfile.is_zipfile(filename):
... |
strawberry-graphql__strawberry-3507 | `Annotated` + `strawberry.lazy` + deferred annotations results in `UnresolvedFieldTypeError: Could not resolve the type of ...` errors
<!-- Provide a general summary of the bug in the title above. -->
<!--- This template is entirely optional and can be removed, but is here to help both you and us. -->
<!--- Anythin... | [
{
"content": "import ast\nimport dataclasses\nimport sys\nimport typing\nfrom functools import lru_cache\nfrom typing import ( # type: ignore\n TYPE_CHECKING,\n Any,\n AsyncGenerator,\n ClassVar,\n Dict,\n ForwardRef,\n Generic,\n List,\n Optional,\n Tuple,\n Type,\n TypeVar... | [
{
"content": "import ast\nimport dataclasses\nimport sys\nimport typing\nfrom functools import lru_cache\nfrom typing import ( # type: ignore\n TYPE_CHECKING,\n Any,\n AsyncGenerator,\n ClassVar,\n Dict,\n ForwardRef,\n Generic,\n List,\n Optional,\n Tuple,\n Type,\n TypeVar... | diff --git a/RELEASE.md b/RELEASE.md
new file mode 100644
index 0000000000..5ce366cab8
--- /dev/null
+++ b/RELEASE.md
@@ -0,0 +1,21 @@
+Release type: patch
+
+This release fixes an issue when using `Annotated` + `strawberry.lazy` +
+deferred annotations such as:
+
+```python
+from __future__ import annotations
+import ... |
Pylons__pyramid-3447 | stop overriding certain webob properties like json_body
pyramid defined `request.json_body` before webob, but now webob has a better impl than pyramid and it can't be used. We should remove the impl and rely on inheriting the behavior from webob. There may be other attributes like this as well.
| [
{
"content": "from collections import deque\nimport json\n\nfrom zope.interface import implementer\nfrom zope.interface.interface import InterfaceClass\n\nfrom webob import BaseRequest\n\nfrom pyramid.interfaces import (\n IRequest,\n IRequestExtensions,\n IResponse,\n ISessionFactory,\n)\n\nfrom py... | [
{
"content": "from collections import deque\n\nfrom zope.interface import implementer\nfrom zope.interface.interface import InterfaceClass\n\nfrom webob import BaseRequest\n\nfrom pyramid.interfaces import (\n IRequest,\n IRequestExtensions,\n IResponse,\n ISessionFactory,\n)\n\nfrom pyramid.decorat... | diff --git a/CHANGES.rst b/CHANGES.rst
index 7772ac7e29..32963027cc 100644
--- a/CHANGES.rst
+++ b/CHANGES.rst
@@ -31,6 +31,10 @@ Features
to ``add_route`` is the empty string (``''``).
See https://github.com/Pylons/pyramid/pull/3420
+- No longer define ``pyramid.request.Request.json_body`` which is already
+ ... |
facebookresearch__hydra-1551 | [Bug] Cannot use experiment pattern when using overrides in main config file
# 🐛 Bug
When using any override in main config, e.g. for color logging or sweeper:
```yaml
defaults:
- override hydra/hydra_logging: colorlog
- override hydra/job_logging: colorlog
```
Then the experiment configs can't be loa... | [
{
"content": "# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved\n\nimport copy\nimport warnings\nfrom dataclasses import dataclass, field\nfrom textwrap import dedent\nfrom typing import Callable, Dict, List, Optional, Set, Tuple, Union\n\nfrom omegaconf import DictConfig, OmegaConf\n\nfrom... | [
{
"content": "# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved\n\nimport copy\nimport warnings\nfrom dataclasses import dataclass, field\nfrom textwrap import dedent\nfrom typing import Callable, Dict, List, Optional, Set, Tuple, Union\n\nfrom omegaconf import DictConfig, OmegaConf\n\nfrom... | diff --git a/examples/patterns/configuring_experiments/conf/hydra/env/custom.yaml b/examples/patterns/configuring_experiments/conf/hydra/env/custom.yaml
new file mode 100644
index 00000000000..e69de29bb2d
diff --git a/hydra/_internal/defaults_list.py b/hydra/_internal/defaults_list.py
index 7ee9cb389ea..6a7a76670dc 100... |
django-cms__django-cms-1992 | 404 while adding child plugin in a non-page placeholder
If I try to add a child plugin to a parent plugin held by a placeholder from an app hook defined in models I get a 404 error. I spotted the error in the placeholderadmin.py on line 161:
```
# in-plugin add-plugin
else:
parent = get_object_or_4... | [
{
"content": "# -*- coding: utf-8 -*-\nimport sys\nfrom django.utils.decorators import method_decorator\nfrom django.db import transaction\nfrom django.utils import simplejson\n\nfrom django.views.decorators.clickjacking import xframe_options_sameorigin\nfrom cms.exceptions import PluginLimitReached\nfrom cms.m... | [
{
"content": "# -*- coding: utf-8 -*-\nimport sys\nfrom django.utils.decorators import method_decorator\nfrom django.db import transaction\nfrom django.utils import simplejson\n\nfrom django.views.decorators.clickjacking import xframe_options_sameorigin\nfrom cms.exceptions import PluginLimitReached\nfrom cms.m... | diff --git a/cms/admin/placeholderadmin.py b/cms/admin/placeholderadmin.py
index bc9e40bbc7b..8be0bc959dc 100644
--- a/cms/admin/placeholderadmin.py
+++ b/cms/admin/placeholderadmin.py
@@ -157,9 +157,6 @@ def add_plugin(self, request):
else:
parent = get_object_or_404(CMSPlugin, pk=parent_id)
... |
privacyidea__privacyidea-1517 | Remove sub modules
We often have problems, when building plugins. Plugins have another release pace than the server.
We should remove the submodules
* pam_python
* freeradius
* simplesamlphp
* adminclient
and give them their own versioning.
The debian build environment has to be added/moved to those reposit... | [
{
"content": "# -*- coding: utf-8 -*-\nfrom setuptools import setup, find_packages\nimport os\nimport stat\nimport sys\n\n#VERSION=\"2.1dev4\"\nVERSION=\"3.0dev1\"\n\n# Taken from kennethreitz/requests/setup.py\npackage_directory = os.path.realpath(os.path.dirname(__file__))\n\n\ndef get_file_contents(file_path... | [
{
"content": "# -*- coding: utf-8 -*-\nfrom setuptools import setup, find_packages\nimport os\nimport stat\nimport sys\n\n#VERSION=\"2.1dev4\"\nVERSION=\"3.0dev1\"\n\n# Taken from kennethreitz/requests/setup.py\npackage_directory = os.path.realpath(os.path.dirname(__file__))\n\n\ndef get_file_contents(file_path... | diff --git a/.gitmodules b/.gitmodules
index 6422e4aadd..e69de29bb2 100644
--- a/.gitmodules
+++ b/.gitmodules
@@ -1,12 +0,0 @@
-[submodule "adminclient"]
- path = adminclient
- url = https://github.com/privacyidea/privacyideaadm.git
-[submodule "authmodules/simpleSAMLphp"]
- path = authmodules/simpleSAMLphp
- url = ht... |
liqd__a4-opin-529 | Wording change for accept page
The page for accepting invites to private projects currently is a bit too straight-forward. ;) Let’s add some information
The headline should be changed to: Do you want to join “<project name>” ?
Then there should be another line underneath the headline set in our standard paragraph t... | [
{
"content": "import rules\nfrom rules.predicates import is_superuser\n\nfrom euth.organisations.predicates import is_initiator\n\nfrom .predicates import is_live, is_member, is_public\n\nrules.add_perm('euth_projects.edit_project',\n is_superuser | is_initiator)\n\n\nrules.add_perm('projects.view... | [
{
"content": "import rules\nfrom rules.predicates import is_superuser\n\nfrom euth.organisations.predicates import is_initiator\n\nfrom .predicates import is_live, is_member, is_public\n\nrules.add_perm('euth_projects.edit_project',\n is_superuser | is_initiator)\n\n\nrules.add_perm('euth_projects... | diff --git a/euth/memberships/templates/euth_memberships/invite_form.html b/euth/memberships/templates/euth_memberships/invite_form.html
index 012ac3f01..68078ce6a 100644
--- a/euth/memberships/templates/euth_memberships/invite_form.html
+++ b/euth/memberships/templates/euth_memberships/invite_form.html
@@ -12,12 +12,1... |
dotkom__onlineweb4-1818 | Unable to remove image from event in dashboard
If an image has been selected for an event there is currently no way to remove the image after saving.
A shitty workaround is to inspect the hidden input field and set the value to an empty string.
| [
{
"content": "# -*- coding: utf8 -*-\n#\n# Created by 'myth' on 10/14/15\n\nfrom django.conf import settings\nfrom django.core.urlresolvers import reverse_lazy\nfrom django.forms import HiddenInput, TextInput\nfrom django.forms.utils import flatatt, force_text, format_html\n\nfrom apps.gallery.models import Res... | [
{
"content": "# -*- coding: utf8 -*-\n#\n# Created by 'myth' on 10/14/15\n\nfrom django.conf import settings\nfrom django.core.urlresolvers import reverse_lazy\nfrom django.forms import HiddenInput, TextInput\nfrom django.forms.utils import flatatt, force_text, format_html\n\nfrom apps.gallery.models import Res... | diff --git a/apps/gallery/widgets.py b/apps/gallery/widgets.py
index 16cdd1989..e70573032 100644
--- a/apps/gallery/widgets.py
+++ b/apps/gallery/widgets.py
@@ -15,7 +15,9 @@
<a href="#" class="btn btn-primary" id="add-responsive-image">\r\n
<i class="fa fa-plus fa-lg"></i> Velg</a>\r\n
<a href="{}" class="btn btn-p... |
common-workflow-language__cwltool-1187 | singularity option does not work correctly 2 step workflow
## Expected Behavior
I execute CWL workflow that has 2 step with `--singularity` .
I setup `CWL_SINGULARITY_CACHE`
```console
$ echo $CWL_SINGULARITY_CACHE
/home/manabu/work/toil/singularity_cache
```
I execute with
```
cwltool --debug --sing... | [
{
"content": "\"\"\"Support for executing Docker containers using the Singularity 2.x engine.\"\"\"\nfrom __future__ import absolute_import\n\nimport os\nimport os.path\nimport re\nimport shutil\nimport tempfile\nimport sys\nfrom distutils import spawn\nfrom io import open # pylint: disable=redefined-builtin\n... | [
{
"content": "\"\"\"Support for executing Docker containers using the Singularity 2.x engine.\"\"\"\nfrom __future__ import absolute_import\n\nimport os\nimport os.path\nimport re\nimport shutil\nimport tempfile\nimport sys\nfrom distutils import spawn\nfrom io import open # pylint: disable=redefined-builtin\n... | diff --git a/cwltool/singularity.py b/cwltool/singularity.py
index 2b8dfd677..e8f6bf7b1 100644
--- a/cwltool/singularity.py
+++ b/cwltool/singularity.py
@@ -118,6 +118,8 @@ def get_image(dockerRequirement, # type: Dict[Text, Text]
if not match:
dockerRequirement["dockerPull"] = "docker://... |
frappe__frappe-11899 | Workflow transition condition allows datetime functions
<!--
Welcome to the Frappe Framework issue tracker! Before creating an issue, please heed the following:
1. This tracker should only be used to report bugs and request features / enhancements to Frappe
- For questions and general support, refer to https:/... | [
{
"content": "# Copyright (c) 2015, Frappe Technologies Pvt. Ltd. and Contributors\n# MIT License. See license.txt\n\nfrom __future__ import unicode_literals\nimport frappe\nfrom frappe.utils import cint\nfrom frappe import _\nfrom six import string_types\nimport json\n\nclass WorkflowStateError(frappe.Validati... | [
{
"content": "# Copyright (c) 2015, Frappe Technologies Pvt. Ltd. and Contributors\n# MIT License. See license.txt\n\nfrom __future__ import unicode_literals\nimport frappe\nfrom frappe.utils import cint\nfrom frappe import _\nfrom six import string_types\nimport json\n\nclass WorkflowStateError(frappe.Validati... | diff --git a/frappe/model/workflow.py b/frappe/model/workflow.py
index 72ce8c9ce478..43e26cc5d0e6 100644
--- a/frappe/model/workflow.py
+++ b/frappe/model/workflow.py
@@ -53,14 +53,17 @@ def get_transitions(doc, workflow = None, raise_exception=False):
return transitions
def get_workflow_safe_globals():
- # access... |
holoviz__holoviews-5409 | Matplotlib error on colorbar
Issue first observed when making a doc build of hvPlot (https://pyviz-dev.github.io/hvplot/user_guide/Plotting_with_Matplotlib.html#scatter). Making a Matplotlib plot with a colorbar raises an error on display. This is due to the latest version of Matplotlib, i.e. 3.5.3. There's no error wi... | [
{
"content": "import inspect\nimport re\nimport warnings\n\nimport numpy as np\nimport matplotlib\n\nfrom matplotlib import units as munits\nfrom matplotlib import ticker\nfrom matplotlib.colors import Normalize, cnames\nfrom matplotlib.lines import Line2D\nfrom matplotlib.markers import MarkerStyle\nfrom matpl... | [
{
"content": "import inspect\nimport re\nimport warnings\n\nimport numpy as np\nimport matplotlib\n\nfrom matplotlib import units as munits\nfrom matplotlib import ticker\nfrom matplotlib.colors import Normalize, cnames\nfrom matplotlib.lines import Line2D\nfrom matplotlib.markers import MarkerStyle\nfrom matpl... | diff --git a/holoviews/plotting/mpl/util.py b/holoviews/plotting/mpl/util.py
index aa7fe57b4c..07c6e33a7b 100644
--- a/holoviews/plotting/mpl/util.py
+++ b/holoviews/plotting/mpl/util.py
@@ -308,8 +308,11 @@ def get_tight_bbox(fig, bbox_extra_artists=[], pad=None):
clip_path = clip_path.get_fully_trans... |
ansible__ansible-modules-core-3819 | Fix unarchive bug when unzipping an archive that has one or more file (#3792)
##### ISSUE TYPE
<!--- Pick one below and delete the rest: -->
Bugfix Pull Request
##### COMPONENT NAME
<!--- Name of the plugin/module/task -->
unarchive
##### ANSIBLE VERSION
```
ansible 2.1.0.0
```
##### SUMMARY
<!--- Describe the c... | [
{
"content": "#!/usr/bin/python\n# -*- coding: utf-8 -*-\n\n# (c) 2012, Michael DeHaan <michael.dehaan@gmail.com>\n# (c) 2013, Dylan Martin <dmartin@seattlecentral.edu>\n# (c) 2015, Toshio Kuratomi <tkuratomi@ansible.com>\n# (c) 2016, Dag Wieers <dag@wieers.com>\n# (c) 2016, Virgil Dupras <hsoft@hardcoded.net>\... | [
{
"content": "#!/usr/bin/python\n# -*- coding: utf-8 -*-\n\n# (c) 2012, Michael DeHaan <michael.dehaan@gmail.com>\n# (c) 2013, Dylan Martin <dmartin@seattlecentral.edu>\n# (c) 2015, Toshio Kuratomi <tkuratomi@ansible.com>\n# (c) 2016, Dag Wieers <dag@wieers.com>\n# (c) 2016, Virgil Dupras <hsoft@hardcoded.net>\... | diff --git a/files/unarchive.py b/files/unarchive.py
index 6492af60633..af9891a008f 100644
--- a/files/unarchive.py
+++ b/files/unarchive.py
@@ -312,13 +312,16 @@ def is_unarchived(self):
for line in old_out.splitlines():
change = False
- pcs = line.split()
- if len(pcs) !=... |
pre-commit__pre-commit-832 | git.get_git_dir() appears to break with older versions of git
When you install the current pre-commit (v1.11.0) on a system using an older git, eg 2.1.4, the `git rev-parse --git-common-dir` ultimately issued by `git.get_git_dir()` yields the result `--git-common-dir` instead of `.git` like you'd expect. This causes pr... | [
{
"content": "from __future__ import unicode_literals\n\nimport logging\nimport os.path\nimport sys\n\nfrom pre_commit.error_handler import FatalError\nfrom pre_commit.util import CalledProcessError\nfrom pre_commit.util import cmd_output\n\n\nlogger = logging.getLogger('pre_commit')\n\n\ndef zsplit(s):\n s ... | [
{
"content": "from __future__ import unicode_literals\n\nimport logging\nimport os.path\nimport sys\n\nfrom pre_commit.error_handler import FatalError\nfrom pre_commit.util import CalledProcessError\nfrom pre_commit.util import cmd_output\n\n\nlogger = logging.getLogger('pre_commit')\n\n\ndef zsplit(s):\n s ... | diff --git a/pre_commit/git.py b/pre_commit/git.py
index 9ec9c9fbc..a92611632 100644
--- a/pre_commit/git.py
+++ b/pre_commit/git.py
@@ -31,16 +31,13 @@ def get_root():
def get_git_dir(git_root):
- def _git_dir(opt):
- return os.path.normpath(os.path.join(
- git_root,
- cmd_output('... |
getmoto__moto-2402 | Error in handling maxReceiveCount in SQS dead letter queues
When creating a queue with a deadletter queue redrive policy, the "maxReceiveCount" is not being converted to an integer before being tested against.
The AWS guidance for setting up the redrive policy is a JSON string with string keys and values:
https://d... | [
{
"content": "from __future__ import unicode_literals\n\nimport base64\nimport hashlib\nimport json\nimport re\nimport six\nimport struct\nfrom xml.sax.saxutils import escape\n\nimport boto.sqs\n\nfrom moto.core.exceptions import RESTError\nfrom moto.core import BaseBackend, BaseModel\nfrom moto.core.utils impo... | [
{
"content": "from __future__ import unicode_literals\n\nimport base64\nimport hashlib\nimport json\nimport re\nimport six\nimport struct\nfrom xml.sax.saxutils import escape\n\nimport boto.sqs\n\nfrom moto.core.exceptions import RESTError\nfrom moto.core import BaseBackend, BaseModel\nfrom moto.core.utils impo... | diff --git a/moto/sqs/models.py b/moto/sqs/models.py
index f2e3ed40088b..6779bc2b53bb 100644
--- a/moto/sqs/models.py
+++ b/moto/sqs/models.py
@@ -263,6 +263,9 @@ def _setup_dlq(self, policy):
if 'maxReceiveCount' not in self.redrive_policy:
raise RESTError('InvalidParameterValue', 'Redrive policy... |
keras-team__keras-2883 | YAML serialization throws exception with Regularizers
If a model contains a regularizer, YAML serialization throws an exception. Using latest Keras 1.0.3.
Compare:
``` python
>>> model = Sequential([LSTM(20, input_shape=(2,3))])
>>> model.to_yaml()
'class_name: Sequential\nconfig:\n- class_name: LSTM\n config:\n ... | [
{
"content": "from __future__ import absolute_import\nfrom . import backend as K\n\n\nclass Regularizer(object):\n def set_param(self, p):\n self.p = p\n\n def set_layer(self, layer):\n self.layer = layer\n\n def __call__(self, loss):\n return loss\n\n def get_config(self):\n ... | [
{
"content": "from __future__ import absolute_import\nfrom . import backend as K\n\n\nclass Regularizer(object):\n def set_param(self, p):\n self.p = p\n\n def set_layer(self, layer):\n self.layer = layer\n\n def __call__(self, loss):\n return loss\n\n def get_config(self):\n ... | diff --git a/keras/regularizers.py b/keras/regularizers.py
index 39a7ff17cf97..61fa10e9c1f4 100644
--- a/keras/regularizers.py
+++ b/keras/regularizers.py
@@ -41,8 +41,8 @@ def __call__(self, loss):
def get_config(self):
return {'name': self.__class__.__name__,
- 'l1': self.l1,
- ... |
ansible-collections__community.general-6684 | Composite variables support for Proxmox nodes in dynamic inventory plugin
### Summary
In my environment Proxmox nodes are assigned an IP address in management VLAN and DNS name in a subdomain of my local domain. Currently if I try to configure the `ansible_host` variable in `compose:` section it will only work for h... | [
{
"content": "# -*- coding: utf-8 -*-\n# Copyright (C) 2016 Guido Günther <agx@sigxcpu.org>, Daniel Lobato Garcia <dlobatog@redhat.com>\n# Copyright (c) 2018 Ansible Project\n# GNU General Public License v3.0+ (see LICENSES/GPL-3.0-or-later.txt or https://www.gnu.org/licenses/gpl-3.0.txt)\n# SPDX-License-Identi... | [
{
"content": "# -*- coding: utf-8 -*-\n# Copyright (C) 2016 Guido Günther <agx@sigxcpu.org>, Daniel Lobato Garcia <dlobatog@redhat.com>\n# Copyright (c) 2018 Ansible Project\n# GNU General Public License v3.0+ (see LICENSES/GPL-3.0-or-later.txt or https://www.gnu.org/licenses/gpl-3.0.txt)\n# SPDX-License-Identi... | diff --git a/changelogs/fragments/6640-proxmox-composite-variables-support.yml b/changelogs/fragments/6640-proxmox-composite-variables-support.yml
new file mode 100644
index 00000000000..bce33c01ba5
--- /dev/null
+++ b/changelogs/fragments/6640-proxmox-composite-variables-support.yml
@@ -0,0 +1,3 @@
+---
+minor_changes... |
internetarchive__openlibrary-9018 | Error message is not displayed on Google sign-in failure
### Problem
Whenever a Google sign-in attempt fails, the `/account/login` page is reloaded and no error message is rendered.
#### Evidence / Screenshot
#### Relevant URL(s)
### Reproducing the bug
1. Go to `/account/login`
2. Do attempt to log in with... | [
{
"content": "from datetime import datetime\nimport json\nimport logging\nimport re\nfrom typing import Any, Final\nfrom collections.abc import Callable\nfrom collections.abc import Iterable, Mapping\n\nimport web\n\nfrom infogami.utils import delegate\nfrom infogami import config\nfrom infogami.utils.view impo... | [
{
"content": "from datetime import datetime\nimport json\nimport logging\nimport re\nfrom typing import Any, Final\nfrom collections.abc import Callable\nfrom collections.abc import Iterable, Mapping\n\nimport web\n\nfrom infogami.utils import delegate\nfrom infogami import config\nfrom infogami.utils.view impo... | diff --git a/openlibrary/plugins/openlibrary/js/ia_thirdparty_logins.js b/openlibrary/plugins/openlibrary/js/ia_thirdparty_logins.js
index 2dad033df34..68c3c040374 100644
--- a/openlibrary/plugins/openlibrary/js/ia_thirdparty_logins.js
+++ b/openlibrary/plugins/openlibrary/js/ia_thirdparty_logins.js
@@ -21,9 +21,20 @@ ... |
cookiecutter__cookiecutter-528 | chg: be more precise in error message on config file.
We can be more helpful when the main config file throws a parser error.
| [
{
"content": "#!/usr/bin/env python\n# -*- coding: utf-8 -*-\n\n\"\"\"\ncookiecutter.config\n-------------------\n\nGlobal configuration handling\n\"\"\"\n\nfrom __future__ import unicode_literals\nimport copy\nimport logging\nimport os\nimport io\n\nimport yaml\n\nfrom .exceptions import ConfigDoesNotExistExce... | [
{
"content": "#!/usr/bin/env python\n# -*- coding: utf-8 -*-\n\n\"\"\"\ncookiecutter.config\n-------------------\n\nGlobal configuration handling\n\"\"\"\n\nfrom __future__ import unicode_literals\nimport copy\nimport logging\nimport os\nimport io\n\nimport yaml\n\nfrom .exceptions import ConfigDoesNotExistExce... | diff --git a/cookiecutter/config.py b/cookiecutter/config.py
index 840fea072..3418a96d9 100755
--- a/cookiecutter/config.py
+++ b/cookiecutter/config.py
@@ -41,9 +41,12 @@ def get_config(config_path):
with io.open(config_path, encoding='utf-8') as file_handle:
try:
yaml_dict = yaml.safe_load(... |
ipython__ipython-5340 | TypeError in bootstrap-tour.min.js
Two minor issues:
1. When pressing `cursor left` in edit mode on current master I get:
```
TypeError: c is undefined
...ame+"_"+a,this._options.storage.removeItem(b),this._options.afterRemoveState(b))...
```
in `http://127.0.0.1:8889/static/components/bootstrap-tour/build/js/bootstr... | [
{
"content": "# encoding: utf-8\n\"\"\"\nThis module defines the things that are used in setup.py for building IPython\n\nThis includes:\n\n * The basic arguments to setup\n * Functions for finding things like packages, package data, etc.\n * A function for checking dependencies.\n\"\"\"\nfrom __future... | [
{
"content": "# encoding: utf-8\n\"\"\"\nThis module defines the things that are used in setup.py for building IPython\n\nThis includes:\n\n * The basic arguments to setup\n * Functions for finding things like packages, package data, etc.\n * A function for checking dependencies.\n\"\"\"\nfrom __future... | diff --git a/IPython/html/static/notebook/js/tour.js b/IPython/html/static/notebook/js/tour.js
index 6129a447c33..dbbae407916 100644
--- a/IPython/html/static/notebook/js/tour.js
+++ b/IPython/html/static/notebook/js/tour.js
@@ -155,11 +155,12 @@ IPython = (function (IPython) {
steps: this.tour_steps,
... |
encode__uvicorn-895 | Subprocess returncode is not detected when running Gunicorn with Uvicorn (with fix PR companion)
### Checklist
<!-- Please make sure you check all these items before submitting your bug report. -->
- [x] The bug is reproducible against the latest release and/or `master`.
- [x] There are no similar issues or pull... | [
{
"content": "import asyncio\nimport logging\n\nfrom gunicorn.workers.base import Worker\n\nfrom uvicorn.config import Config\nfrom uvicorn.main import Server\n\n\nclass UvicornWorker(Worker):\n \"\"\"\n A worker class for Gunicorn that interfaces with an ASGI consumer callable,\n rather than a WSGI ca... | [
{
"content": "import asyncio\nimport logging\nimport signal\n\nfrom gunicorn.workers.base import Worker\n\nfrom uvicorn.config import Config\nfrom uvicorn.main import Server\n\n\nclass UvicornWorker(Worker):\n \"\"\"\n A worker class for Gunicorn that interfaces with an ASGI consumer callable,\n rather... | diff --git a/uvicorn/workers.py b/uvicorn/workers.py
index 1ac036372..7c160dff6 100644
--- a/uvicorn/workers.py
+++ b/uvicorn/workers.py
@@ -1,5 +1,6 @@
import asyncio
import logging
+import signal
from gunicorn.workers.base import Worker
@@ -62,7 +63,11 @@ def init_process(self):
super(UvicornWorker, s... |
DataDog__dd-trace-py-1477 | ddtrace.profiling.exporter.http.UploadFailed: 400 Bad request
### Which version of dd-trace-py are you using?
```
ddtrace[profiling]==0.37.1
```
### Which version of the libraries are you using?
```
aiodns==2.0.0
aiohttp==3.5.4
apipkg==1.5
appnope==0.1.0
argcomplete==1.9.3
asn1crypto==0.24.0
async-tim... | [
{
"content": "# -*- encoding: utf-8 -*-\nimport binascii\nimport datetime\nimport gzip\nimport os\nimport platform\n\nimport tenacity\n\nfrom ddtrace.internal.runtime import container\nfrom ddtrace.utils.formats import parse_tags_str\nfrom ddtrace.vendor import six\nfrom ddtrace.vendor.six.moves import http_cli... | [
{
"content": "# -*- encoding: utf-8 -*-\nimport binascii\nimport datetime\nimport gzip\nimport os\nimport platform\n\nimport tenacity\n\nfrom ddtrace.internal.runtime import container\nfrom ddtrace.utils.formats import parse_tags_str\nfrom ddtrace.vendor import six\nfrom ddtrace.vendor.six.moves import http_cli... | diff --git a/ddtrace/profiling/exporter/http.py b/ddtrace/profiling/exporter/http.py
index a0b6bf30de4..205036b861c 100644
--- a/ddtrace/profiling/exporter/http.py
+++ b/ddtrace/profiling/exporter/http.py
@@ -173,7 +173,9 @@ def export(self, events, start_time_ns, end_time_ns):
except tenacity.RetryError as e:... |
optuna__optuna-5176 | Use `__future__.annotations` everywhere in the Optuna code base
### Motivation
Optuna drops Python 3.6 from v3.1, so we can use `__future__.annotations`, which simplifies the code base. See [PEP 563](https://peps.python.org/pep-0563/), [PEP584](https://peps.python.org/pep-0584/), [PEP 585](https://peps.python.org/pe... | [
{
"content": "import logging\nfrom logging import CRITICAL\nfrom logging import DEBUG\nfrom logging import ERROR\nfrom logging import FATAL\nfrom logging import INFO\nfrom logging import WARN\nfrom logging import WARNING\nimport os\nimport sys\nimport threading\nfrom typing import Optional\n\nimport colorlog\n\... | [
{
"content": "from __future__ import annotations\n\nimport logging\nfrom logging import CRITICAL\nfrom logging import DEBUG\nfrom logging import ERROR\nfrom logging import FATAL\nfrom logging import INFO\nfrom logging import WARN\nfrom logging import WARNING\nimport os\nimport sys\nimport threading\n\nimport co... | diff --git a/optuna/logging.py b/optuna/logging.py
index be0b4043d4..b5a07d67e3 100644
--- a/optuna/logging.py
+++ b/optuna/logging.py
@@ -1,3 +1,5 @@
+from __future__ import annotations
+
import logging
from logging import CRITICAL
from logging import DEBUG
@@ -9,7 +11,6 @@
import os
import sys
import threading
... |
readthedocs__readthedocs.org-1407 | Migration failing on version slugs
Running migrations on #1396, I hit the following error:
```
Traceback (most recent call last):
File "/home/docs/bin/django-admin.py", line 5, in <module>
management.execute_from_command_line()
File "/home/docs/local/lib/python2.7/site-packages/django/core/management/__init__.... | [
{
"content": "\"\"\"Contains logic for handling version slugs.\n\nHandling slugs for versions is not too straightforward. We need to allow some\ncharacters which are uncommon in usual slugs. They are dots and underscores.\nUsually we want the slug to be the name of the tag or branch corresponding VCS\nversion. ... | [
{
"content": "\"\"\"Contains logic for handling version slugs.\n\nHandling slugs for versions is not too straightforward. We need to allow some\ncharacters which are uncommon in usual slugs. They are dots and underscores.\nUsually we want the slug to be the name of the tag or branch corresponding VCS\nversion. ... | diff --git a/readthedocs/builds/version_slug.py b/readthedocs/builds/version_slug.py
index 871edf5b826..bbc4ada4a52 100644
--- a/readthedocs/builds/version_slug.py
+++ b/readthedocs/builds/version_slug.py
@@ -27,10 +27,10 @@
# Regex breakdown:
# [a-z0-9] -- start with alphanumeric value
# [-._a-z0-9] -- allow da... |
inventree__InvenTree-1744 | Add ability to filter stock by "has purchase price"
- Add another filter to the stock table
- Boolean
| [
{
"content": "\"\"\"\nJSON API for the Stock app\n\"\"\"\n\nfrom django_filters.rest_framework import FilterSet, DjangoFilterBackend\nfrom django_filters import NumberFilter\n\nfrom rest_framework import status\n\nfrom django.conf.urls import url, include\nfrom django.urls import reverse\nfrom django.http impor... | [
{
"content": "\"\"\"\nJSON API for the Stock app\n\"\"\"\n\nfrom django_filters.rest_framework import FilterSet, DjangoFilterBackend\nfrom django_filters import NumberFilter\n\nfrom rest_framework import status\n\nfrom django.conf.urls import url, include\nfrom django.urls import reverse\nfrom django.http impor... | diff --git a/InvenTree/stock/api.py b/InvenTree/stock/api.py
index 3fc440cae45a..98dcab6287d1 100644
--- a/InvenTree/stock/api.py
+++ b/InvenTree/stock/api.py
@@ -858,6 +858,17 @@ def filter_queryset(self, queryset):
print("After error:", str(updated_after))
pass
+ # Filter st... |
spyder-ide__spyder-10443 | Spyder executable file opened on launch
## Problem Description
When I launch spyder from the command line, the spyder window launches with the previous state as is expected, then also opens the spyder executable file, in my case `~/anaconda3/bin/spyder`.
### What steps reproduce the problem?
1. type `spyder`... | [
{
"content": "# -*- coding: utf-8 -*-\r\n#\r\n# Copyright © Spyder Project Contributors\r\n# Licensed under the terms of the MIT License\r\n# (see spyder/__init__.py for details)\r\n\r\n\"\"\"Qt utilities.\"\"\"\r\n\r\n# Standard library imports\r\nfrom math import pi\r\nimport logging\r\nimport os\r\nimport os... | [
{
"content": "# -*- coding: utf-8 -*-\r\n#\r\n# Copyright © Spyder Project Contributors\r\n# Licensed under the terms of the MIT License\r\n# (see spyder/__init__.py for details)\r\n\r\n\"\"\"Qt utilities.\"\"\"\r\n\r\n# Standard library imports\r\nfrom math import pi\r\nimport logging\r\nimport os\r\nimport os... | diff --git a/spyder/utils/qthelpers.py b/spyder/utils/qthelpers.py
index 44243a616ff..63f39dd36be 100644
--- a/spyder/utils/qthelpers.py
+++ b/spyder/utils/qthelpers.py
@@ -65,7 +65,11 @@ def __init__(self, *args):
def event(self, event):
if event.type() == QEvent.FileOpen:
fname = str(even... |
elastic__apm-agent-python-1687 | Elastic APM crashes when trying to inspect hits from queries while track_total_hits is False
**Describe the bug**:
The Elastic APM instrumentation for _Elasticsearch_ tries to get total number of hits in the results of a query but if the **track_total_hits** is set to **False** the `result.body['hits']` does not ha... | [
{
"content": "# BSD 3-Clause License\n#\n# Copyright (c) 2019, Elasticsearch BV\n# All rights reserved.\n#\n# Redistribution and use in source and binary forms, with or without\n# modification, are permitted provided that the following conditions are met:\n#\n# * Redistributions of source code must retain... | [
{
"content": "# BSD 3-Clause License\n#\n# Copyright (c) 2019, Elasticsearch BV\n# All rights reserved.\n#\n# Redistribution and use in source and binary forms, with or without\n# modification, are permitted provided that the following conditions are met:\n#\n# * Redistributions of source code must retain... | diff --git a/CHANGELOG.asciidoc b/CHANGELOG.asciidoc
index 0ff3bb8fa..222d4139c 100644
--- a/CHANGELOG.asciidoc
+++ b/CHANGELOG.asciidoc
@@ -29,6 +29,18 @@ endif::[]
//===== Bug fixes
//
+=== Unreleased
+
+// Unreleased changes go here
+// When the next release happens, nest these changes under the "Python Agent ve... |
fossasia__open-event-server-5124 | HTTP 500 on /oauth/<provider>
**Describe the bug**
<!-- A clear and concise description of what the bug is. -->
The server returns HTTP 500 when a request is made to /oauth/<provider>. It is probably because I haven't configured facebook keys in the settings.
**Expected behavior**
<!-- A clear and concise descrip... | [
{
"content": "import base64\nfrom flask import request, jsonify, make_response, Blueprint\nfrom flask_jwt import current_identity as current_user, jwt_required\nfrom sqlalchemy.orm.exc import NoResultFound\nimport requests\n\nfrom app import get_settings\nfrom app.api.helpers.db import save_to_db\nfrom app.api.... | [
{
"content": "import base64\nfrom flask import request, jsonify, make_response, Blueprint\nfrom flask_jwt import current_identity as current_user, jwt_required\nfrom sqlalchemy.orm.exc import NoResultFound\nimport requests\n\nfrom app import get_settings\nfrom app.api.helpers.db import save_to_db\nfrom app.api.... | diff --git a/app/api/auth.py b/app/api/auth.py
index b01c23a8f4..fb72e5f438 100644
--- a/app/api/auth.py
+++ b/app/api/auth.py
@@ -35,8 +35,14 @@ def redirect_uri(provider):
else:
return make_response(jsonify(
message="No support for {}".format(provider)), 404)
+
+ client_id = provider_cla... |
microsoft__DeepSpeed-2049 | [BUG] Impossible to prebuild w/o having at least one gpu
**Describe the bug**
The goal is to cross-compile on a VM that has no GPUs for other VMs that have GPUs (preparing docker images for CIs). Currently the prebuilding fails.
**To Reproduce**
Steps to reproduce the behavior:
Normally when gpus are enabled ... | [
{
"content": "\"\"\"\nCopyright 2020 The Microsoft DeepSpeed Team\n\nDeepSpeed library\n\nTo build wheel on Windows:\n 1. Install pytorch, such as pytorch 1.8 + cuda 11.1\n 2. Install visual cpp build tool\n 3. Launch cmd console with Administrator privilege for creating required symlink folders\n\nCre... | [
{
"content": "\"\"\"\nCopyright 2020 The Microsoft DeepSpeed Team\n\nDeepSpeed library\n\nTo build wheel on Windows:\n 1. Install pytorch, such as pytorch 1.8 + cuda 11.1\n 2. Install visual cpp build tool\n 3. Launch cmd console with Administrator privilege for creating required symlink folders\n\nCre... | diff --git a/setup.py b/setup.py
index e281b189a256..2e92a847a75d 100755
--- a/setup.py
+++ b/setup.py
@@ -235,7 +235,7 @@ def create_dir_symlink(src, dest):
nccl_version = ".".join(str(torch.cuda.nccl.version())[:2])
else:
nccl_version = ".".join(map(str, torch.cuda.nccl.version()[:2]))
- if ... |
mesonbuild__meson-4401 | Unknown CPU family 'powerpc'
I'm using meson to build a program.
I'm getting this warning:
`WARNING: Unknown CPU family 'powerpc', please report this at https://github.com/mesonbuild/meson/issues/new with theoutput of `uname -a` and `cat /proc/cpuinfo``
uname -a:
`FreeBSD XXX 12.0-BETA1 FreeBSD 12.0-BETA1 #7 r3... | [
{
"content": "# Copyright 2012-2016 The Meson development team\n\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n\n# http://www.apache.org/licenses/LICENSE-2.0\n\n# Unless req... | [
{
"content": "# Copyright 2012-2016 The Meson development team\n\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n\n# http://www.apache.org/licenses/LICENSE-2.0\n\n# Unless req... | diff --git a/mesonbuild/environment.py b/mesonbuild/environment.py
index 101d386c7cec..c1a36546c77b 100644
--- a/mesonbuild/environment.py
+++ b/mesonbuild/environment.py
@@ -211,6 +211,19 @@ def detect_cpu_family(compilers):
return 'arm'
if trial.startswith('ppc64'):
return 'ppc64'
+ if trial... |
nilearn__nilearn-2549 | nistats: dependence between function calls – strange bug may affect reproducibility
Hi,
I've encountered very strange behavior of two functions – `map_threshold` from `nistats.thresholding` module and `get_clusters_table` from `nistats.reporting` module. It seems like the threshold value returned by `map_threshold` ... | [
{
"content": "\"\"\"\nThis module implements plotting functions useful to report analysis results.\n\nAuthor: Martin Perez-Guevara, Elvis Dohmatob, 2017\n\"\"\"\n\nimport warnings\nfrom string import ascii_lowercase\n\nimport numpy as np\nimport pandas as pd\nimport nibabel as nib\nfrom scipy import ndimage\n\n... | [
{
"content": "\"\"\"\nThis module implements plotting functions useful to report analysis results.\n\nAuthor: Martin Perez-Guevara, Elvis Dohmatob, 2017\n\"\"\"\n\nimport warnings\nfrom string import ascii_lowercase\n\nimport numpy as np\nimport pandas as pd\nimport nibabel as nib\nfrom scipy import ndimage\n\n... | diff --git a/nilearn/reporting/_get_clusters_table.py b/nilearn/reporting/_get_clusters_table.py
index 13c91e97ad..2e1f073c33 100644
--- a/nilearn/reporting/_get_clusters_table.py
+++ b/nilearn/reporting/_get_clusters_table.py
@@ -120,7 +120,14 @@ def get_clusters_table(stat_img, stat_threshold, cluster_threshold=None,... |
Cloud-CV__EvalAI-475 | Participant teams not showing up
The participant teams to which the user has been invited does not show up if that user logs in.
For instance: User A creates a team ABC and invites User B
User B logs in, and goes to the participant teams page.
User B does not see team ABC.
| [
{
"content": "from rest_framework import permissions, status\nfrom rest_framework.decorators import (api_view,\n authentication_classes,\n permission_classes,\n throttle_classes,)\nfrom rest_framewo... | [
{
"content": "from rest_framework import permissions, status\nfrom rest_framework.decorators import (api_view,\n authentication_classes,\n permission_classes,\n throttle_classes,)\nfrom rest_framewo... | diff --git a/apps/participants/views.py b/apps/participants/views.py
index 9e6c10c53d..11b52527b8 100644
--- a/apps/participants/views.py
+++ b/apps/participants/views.py
@@ -27,8 +27,9 @@
def participant_team_list(request):
if request.method == 'GET':
+ participant_teams_id = Participant.objects.filter(... |
elastic__apm-agent-python-1822 | urllib3 v2.0 compatibility
urllib3 v2.0 came out during PyConUS 2023 and is resulting in hanging tests on windows, and test failures on Linux. We need to update our code/tests to ensure compatibility for this new version.
| [
{
"content": "# BSD 3-Clause License\n#\n# Copyright (c) 2019, Elasticsearch BV\n# All rights reserved.\n#\n# Redistribution and use in source and binary forms, with or without\n# modification, are permitted provided that the following conditions are met:\n#\n# * Redistributions of source code must retain... | [
{
"content": "# BSD 3-Clause License\n#\n# Copyright (c) 2019, Elasticsearch BV\n# All rights reserved.\n#\n# Redistribution and use in source and binary forms, with or without\n# modification, are permitted provided that the following conditions are met:\n#\n# * Redistributions of source code must retain... | diff --git a/CHANGELOG.asciidoc b/CHANGELOG.asciidoc
index 2d72e7876..568ed6d24 100644
--- a/CHANGELOG.asciidoc
+++ b/CHANGELOG.asciidoc
@@ -42,6 +42,7 @@ endif::[]
* Add S3 bucket and key name to OTel attributes {pull}1790[#1790]
* Implement partial transaction support in AWS lambda {pull}1784[#1784]
* Add instrume... |
PyGithub__PyGithub-1433 | List pull requests based on commit
There's a functionality on the Github API that is apparently not supported on PyGithub -- https://developer.github.com/v3/repos/commits/#list-pull-requests-associated-with-commit
## Motivation
I'm doing an auto-versioning type of thing on my repo, and I need to walk through all ... | [
{
"content": "# -*- coding: utf-8 -*-\n\n############################ Copyrights and license ############################\n# #\n# Copyright 2012 Vincent Jacques <vincent@vincent-jacques.net> #\n# Copyright 2012 Zearin <... | [
{
"content": "# -*- coding: utf-8 -*-\n\n############################ Copyrights and license ############################\n# #\n# Copyright 2012 Vincent Jacques <vincent@vincent-jacques.net> #\n# Copyright 2012 Zearin <... | diff --git a/github/Commit.py b/github/Commit.py
index 280b897c8c..b3c691d560 100644
--- a/github/Commit.py
+++ b/github/Commit.py
@@ -245,6 +245,19 @@ def get_combined_status(self):
self._requester, headers, data, completed=True
)
+ def get_pulls(self):
+ """
+ :calls: `GET /re... |
mesonbuild__meson-9636 | ldconfig on install corrupts freebsd cache
**Describe the bug**
2c3a68bc30cf and 6b7d43ebe0d7 make it so `ldconfig` is invoked after install. But it seems like thos corrupts the cache on FreeBSD (maybe other BSDs as well), and results in errors similar to:
ld-elf.so.1: Shared object "libreadline.so.8" not found... | [
{
"content": "# Copyright 2013-2014 The Meson development team\n\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n\n# http://www.apache.org/licenses/LICENSE-2.0\n\n# Unless req... | [
{
"content": "# Copyright 2013-2014 The Meson development team\n\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n\n# http://www.apache.org/licenses/LICENSE-2.0\n\n# Unless req... | diff --git a/mesonbuild/minstall.py b/mesonbuild/minstall.py
index 7d0da13098df..cb87faf5cac0 100644
--- a/mesonbuild/minstall.py
+++ b/mesonbuild/minstall.py
@@ -18,6 +18,7 @@
import errno
import os
import pickle
+import platform
import shlex
import shutil
import subprocess
@@ -251,6 +252,9 @@ def apply_ldconfig... |
cython__cython-5302 | [BUG] `IS_UNSIGNED()` macro is applied to `const` types in test suite
### Describe the bug
Example (there are several such modules):
```
Compiler output for module memslice:
memslice.cpp:1348:37: warning: type qualifiers ignored on cast result type [-Wignored-qualifiers]
#define IS_UNSIGNED(type) (((type) -1) > 0... | [
{
"content": "from __future__ import absolute_import\n\nfrom .Visitor import CythonTransform\nfrom .ModuleNode import ModuleNode\nfrom .Errors import CompileError\nfrom .UtilityCode import CythonUtilityCode\nfrom .Code import UtilityCode, TempitaUtilityCode\n\nfrom . import Options\nfrom . import Interpreter\nf... | [
{
"content": "from __future__ import absolute_import\n\nfrom .Visitor import CythonTransform\nfrom .ModuleNode import ModuleNode\nfrom .Errors import CompileError\nfrom .UtilityCode import CythonUtilityCode\nfrom .Code import UtilityCode, TempitaUtilityCode\n\nfrom . import Options\nfrom . import Interpreter\nf... | diff --git a/Cython/Compiler/Buffer.py b/Cython/Compiler/Buffer.py
index e33a95e298a..e86e1e9c24d 100644
--- a/Cython/Compiler/Buffer.py
+++ b/Cython/Compiler/Buffer.py
@@ -699,10 +699,10 @@ def get_type_information_cname(code, dtype, maxdepth=None):
flags = "0"
is_unsigned = "0"
if dtype is ... |
conda__conda-5273 | conda env export under python2 is ug
```
$ python2 -m conda_env export -p /conda
name: null
channels:
- !!python/unicode
'file:///Users/kfranz/.conda/conda-bld'
- !!python/unicode
'file:///conda/conda-bld'
- !!python/unicode
'bkreider'
- !!python/unicode
'conda-canary'
- !!python/unicode
'conda-f... | [
{
"content": "\"\"\"\nWrapper around yaml to ensure that everything is ordered correctly.\n\nThis is based on the answer at http://stackoverflow.com/a/16782282\n\"\"\"\nfrom __future__ import absolute_import, print_function\nfrom collections import OrderedDict\n\nfrom conda.common.yaml import get_yaml\nyaml = g... | [
{
"content": "\"\"\"\nWrapper around yaml to ensure that everything is ordered correctly.\n\nThis is based on the answer at http://stackoverflow.com/a/16782282\n\"\"\"\nfrom __future__ import absolute_import, print_function\nfrom collections import OrderedDict\n\nfrom conda.common.compat import PY2\nfrom conda.... | diff --git a/conda_env/yaml.py b/conda_env/yaml.py
index 084d05ea724..11ccb424be7 100644
--- a/conda_env/yaml.py
+++ b/conda_env/yaml.py
@@ -6,6 +6,7 @@
from __future__ import absolute_import, print_function
from collections import OrderedDict
+from conda.common.compat import PY2
from conda.common.yaml import get_... |
sublimelsp__LSP-311 | Error handling server payload in php intelephense language server
### language server - [intelephense](https://github.com/bmewburn/intelephense-server)
### Minimal reproduction steps
In a Laravel project in a class that extends TestCase,
after typying `$this->` expect to see method suggestions but LSP throws `Erro... | [
{
"content": "import sublime\nimport sublime_plugin\n\ntry:\n from typing import Any, List, Dict, Tuple, Callable, Optional\n assert Any and List and Dict and Tuple and Callable and Optional\nexcept ImportError:\n pass\n\nfrom .core.protocol import Request\nfrom .core.settings import settings\nfrom .co... | [
{
"content": "import sublime\nimport sublime_plugin\n\ntry:\n from typing import Any, List, Dict, Tuple, Callable, Optional\n assert Any and List and Dict and Tuple and Callable and Optional\nexcept ImportError:\n pass\n\nfrom .core.protocol import Request\nfrom .core.settings import settings\nfrom .co... | diff --git a/plugin/completion.py b/plugin/completion.py
index b6863f74c..a1e539055 100644
--- a/plugin/completion.py
+++ b/plugin/completion.py
@@ -257,9 +257,7 @@ def handle_response(self, response: 'Optional[Dict]'):
items = response["items"]
elif isinstance(response, list):
... |
praw-dev__praw-1145 | `reddit.user.moderator_subreddits()` has a limit of 100 subreddits that is not documented.
## Issue Description
`reddit.user.moderator_subreddits()` is a method for `reddit.user` that [returns a ListingGenerator of the subreddits that the currently authenticated user is a moderator of](https://praw.readthedocs.io/en... | [
{
"content": "\"\"\"Provides the User class.\"\"\"\nfrom ..const import API_PATH\nfrom ..models import Preferences\nfrom ..util.cache import cachedproperty\nfrom .base import PRAWBase\nfrom .listing.generator import ListingGenerator\nfrom .reddit.redditor import Redditor\nfrom .reddit.subreddit import Subreddit... | [
{
"content": "\"\"\"Provides the User class.\"\"\"\nfrom ..const import API_PATH\nfrom ..models import Preferences\nfrom ..util.cache import cachedproperty\nfrom .base import PRAWBase\nfrom .listing.generator import ListingGenerator\nfrom .reddit.redditor import Redditor\nfrom .reddit.subreddit import Subreddit... | diff --git a/.github/CONTRIBUTING.md b/.github/CONTRIBUTING.md
index 101d6cc3c..752a8fac6 100644
--- a/.github/CONTRIBUTING.md
+++ b/.github/CONTRIBUTING.md
@@ -32,7 +32,7 @@ to you, it likely is not to the person asking the question.
commenting on the issue. This act will hopefully minimize any duplicate
work.... |
ESMCI__cime-249 | Misleading error message in case_setup.py
I suggest changing "%s NINST value %d greater than %s NTASKS %d"
(e.g ERROR: ATM NINST value 1 greater than ATM NTASKS 0)
to
"NINST_%s value %d greater than NTASKS_%s %d
(e.g. ERROR: NINST_ATM value 1 greater than NTASKS_ATM 0)
to reflect the real variable name which can ... | [
{
"content": "\"\"\"\nLibrary for case.setup.\n\"\"\"\n\nfrom CIME.XML.standard_module_setup import *\n\nfrom CIME.check_lockedfiles import check_lockedfiles\nfrom CIME.preview_namelists import preview_namelists\nfrom CIME.XML.env_mach_pes import EnvMachPes\nfrom CIME.XML.component import Component\nfrom C... | [
{
"content": "\"\"\"\nLibrary for case.setup.\n\"\"\"\n\nfrom CIME.XML.standard_module_setup import *\n\nfrom CIME.check_lockedfiles import check_lockedfiles\nfrom CIME.preview_namelists import preview_namelists\nfrom CIME.XML.env_mach_pes import EnvMachPes\nfrom CIME.XML.component import Component\nfrom C... | diff --git a/utils/python/CIME/case_setup.py b/utils/python/CIME/case_setup.py
index 9bb177b5fca..6de99b700a0 100644
--- a/utils/python/CIME/case_setup.py
+++ b/utils/python/CIME/case_setup.py
@@ -166,7 +166,7 @@ def case_setup(case, clean=False, test_mode=False, reset=False):
if ntasks == 1:
... |
django-cms__django-cms-1379 | One the clean method in PageForm does not play well with permod
I can't save the same page several time in a raw with the moderator.
The form has a validation error telling me: "Page with redirect url u'uk' already exist"
| [
{
"content": "# -*- coding: utf-8 -*-\nfrom cms.apphook_pool import apphook_pool\nfrom cms.forms.widgets import UserSelectAdminWidget\nfrom cms.models import (Page, PagePermission, PageUser, ACCESS_PAGE, \n PageUserGroup)\nfrom cms.utils.mail import mail_page_user_change\nfrom cms.utils.page import is_valid_... | [
{
"content": "# -*- coding: utf-8 -*-\nfrom cms.apphook_pool import apphook_pool\nfrom cms.forms.widgets import UserSelectAdminWidget\nfrom cms.models import (Page, PagePermission, PageUser, ACCESS_PAGE, \n PageUserGroup)\nfrom cms.utils.mail import mail_page_user_change\nfrom cms.utils.page import is_valid_... | diff --git a/cms/admin/forms.py b/cms/admin/forms.py
index 0f90860f531..3e2138a0002 100644
--- a/cms/admin/forms.py
+++ b/cms/admin/forms.py
@@ -177,7 +177,9 @@ def clean_overwrite_url(self):
if not any_path_re.match(url):
raise forms.ValidationError(_('Invalid URL, use /my/url for... |
mampfes__hacs_waste_collection_schedule-118 | ICS Scraper error
My Home-Assistant has the following error:
`2021-12-02 06:53:42 ERROR (SyncWorker_19) [waste_collection_schedule.scraper] fetch failed for source <waste_collection_schedule.source.ics.Source object at 0x7f3785601ca0>: 'NoneType' object does not support item assignment`
I have events for this yea... | [
{
"content": "import datetime\nimport logging\nfrom pathlib import Path\n\nimport requests\nfrom waste_collection_schedule import Collection # type: ignore[attr-defined]\nfrom waste_collection_schedule.service.ICS import ICS\n\nTITLE = \"ICS\"\nDESCRIPTION = \"Source for ICS based schedules.\"\nURL = None\nTES... | [
{
"content": "import datetime\nimport logging\nfrom pathlib import Path\n\nimport requests\nfrom waste_collection_schedule import Collection # type: ignore[attr-defined]\nfrom waste_collection_schedule.service.ICS import ICS\n\nTITLE = \"ICS\"\nDESCRIPTION = \"Source for ICS based schedules.\"\nURL = None\nTES... | diff --git a/custom_components/waste_collection_schedule/waste_collection_schedule/source/ics.py b/custom_components/waste_collection_schedule/waste_collection_schedule/source/ics.py
index 0d94b0619..2b2d2a4b0 100644
--- a/custom_components/waste_collection_schedule/waste_collection_schedule/source/ics.py
+++ b/custom_... |
pypi__warehouse-3647 | Automagic GitHub repo stats display doesn't find www.github.com/user/repo URLs
As noted [here](https://github.com/pypa/warehouse/pull/2163#pullrequestreview-111691465), the automagic sidebar stats feature when a GitHub repo is the project homepage doesn't activate if the URL is written using `www.github.com`; it only f... | [
{
"content": "# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# http://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless required by applicable law or agreed to in writing, softw... | [
{
"content": "# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# http://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless required by applicable law or agreed to in writing, softw... | diff --git a/tests/unit/packaging/test_models.py b/tests/unit/packaging/test_models.py
index 8e5fc9d7f36a..f8fe94e10246 100644
--- a/tests/unit/packaging/test_models.py
+++ b/tests/unit/packaging/test_models.py
@@ -305,6 +305,10 @@ def test_acl(self, db_session):
"https://github.com/pypa/warehouse/tree... |
yt-project__yt-2843 | bug: mesh sampling throws error with FLASH data
### Bug report
The script below attempts to create a mesh sampled particle field using a FLASH dataset with plt and part files. The expected outcome is a list of density values at the location of each particle, like those produced by the example script (https://yt-pro... | [
{
"content": "import abc\nimport weakref\nfrom collections import defaultdict\n\nimport numpy as np\n\nfrom yt.arraytypes import blankRecordArray\nfrom yt.config import ytcfg\nfrom yt.fields.derived_field import ValidateSpatial\nfrom yt.fields.field_detector import FieldDetector\nfrom yt.funcs import ensure_lis... | [
{
"content": "import abc\nimport weakref\nfrom collections import defaultdict\n\nimport numpy as np\n\nfrom yt.arraytypes import blankRecordArray\nfrom yt.config import ytcfg\nfrom yt.fields.derived_field import ValidateSpatial\nfrom yt.fields.field_detector import FieldDetector\nfrom yt.funcs import ensure_lis... | diff --git a/yt/geometry/grid_geometry_handler.py b/yt/geometry/grid_geometry_handler.py
index 1602ca40cb0..fd49f1e2149 100644
--- a/yt/geometry/grid_geometry_handler.py
+++ b/yt/geometry/grid_geometry_handler.py
@@ -462,7 +462,17 @@ def _mesh_sampling_particle_field(field, data):
i, j, k = np.floor((pos... |
ansible__ansible-modules-core-3578 | apt module throws `UnboundLocalError` when installing ctags on Ubuntu 15.10
##### Bug Report
##### COMPONENT NAME
apt
##### ANSIBLE VERSION
```
ansible 2.2.0 (devel 1fc44e4103) last updated 2016/05/02 10:25:32 (GMT +800)
lib/ansible/modules/core: (devel 82aeaed45d) last updated 2016/05/02 12:06:05 (GMT +800)
lib/... | [
{
"content": "#!/usr/bin/python\n# -*- coding: utf-8 -*-\n\n# (c) 2012, Flowroute LLC\n# Written by Matthew Williams <matthew@flowroute.com>\n# Based on yum module written by Seth Vidal <skvidal at fedoraproject.org>\n#\n# This module is free software: you can redistribute it and/or modify\n# it under the terms... | [
{
"content": "#!/usr/bin/python\n# -*- coding: utf-8 -*-\n\n# (c) 2012, Flowroute LLC\n# Written by Matthew Williams <matthew@flowroute.com>\n# Based on yum module written by Seth Vidal <skvidal at fedoraproject.org>\n#\n# This module is free software: you can redistribute it and/or modify\n# it under the terms... | diff --git a/packaging/os/apt.py b/packaging/os/apt.py
index 6f116907da8..450579eadd7 100644
--- a/packaging/os/apt.py
+++ b/packaging/os/apt.py
@@ -263,6 +263,7 @@ def package_status(m, pkgname, version, cache, state):
provided_packages = cache.get_providing_packages(pkgname)
if provi... |
translate__pootle-5681 | Downloading store in a zip file with no revision lacks revision headers
not sure if this is a dupe or related to other PO-headers bugs - but it seems like stores with no unit revision dont get headers - this causes re-uploading to fail
| [
{
"content": "# -*- coding: utf-8 -*-\n#\n# Copyright (C) Pootle contributors.\n#\n# This file is a part of the Pootle project. It is distributed under the GPL3\n# or later license. See the LICENSE file for a copy of the license and the\n# AUTHORS file for copyright and authorship information.\n\nfrom django.co... | [
{
"content": "# -*- coding: utf-8 -*-\n#\n# Copyright (C) Pootle contributors.\n#\n# This file is a part of the Pootle project. It is distributed under the GPL3\n# or later license. See the LICENSE file for a copy of the license and the\n# AUTHORS file for copyright and authorship information.\n\nfrom django.co... | diff --git a/pootle/apps/pootle_store/store/serialize.py b/pootle/apps/pootle_store/store/serialize.py
index 45c4ba8dcb3..49a252c3094 100644
--- a/pootle/apps/pootle_store/store/serialize.py
+++ b/pootle/apps/pootle_store/store/serialize.py
@@ -50,8 +50,9 @@ def tostring(self):
if hasattr(store, "updateheader"... |
Flexget__Flexget-2288 | Incorrect timeframe plugin behaviour when loading items from an entry_list
### Expected behaviour:
The 1080p is downloaded
### Actual behaviour:
The plugin ignores 1080p and sees only 720p
### Steps to reproduce:
- Step 1: Add movies from rss http://rutor.info/rss.php?cat=7 to list movies_list
#### Config:
... | [
{
"content": "from __future__ import unicode_literals, division, absolute_import\nfrom builtins import * # noqa pylint: disable=unused-import, redefined-builtin\n\nimport logging\n\nfrom flexget import plugin\nfrom flexget.event import event\nfrom flexget.utils import qualities\n\nlog = logging.getLogger('meta... | [
{
"content": "from __future__ import unicode_literals, division, absolute_import\nfrom builtins import * # noqa pylint: disable=unused-import, redefined-builtin\n\nimport logging\n\nfrom flexget import plugin\nfrom flexget.event import event\nfrom flexget.utils import qualities\n\nlog = logging.getLogger('meta... | diff --git a/flexget/plugins/metainfo/quality.py b/flexget/plugins/metainfo/quality.py
index c79233fd54..140561be77 100644
--- a/flexget/plugins/metainfo/quality.py
+++ b/flexget/plugins/metainfo/quality.py
@@ -25,7 +25,12 @@ def on_task_metainfo(self, task, config):
if config is False:
return
... |
nyu-mll__jiant-386 | Problems with new PATH_TO_COVE var
https://github.com/jsalt18-sentence-repl/jiant/pull/349
- Demo is broken because the user_config script doesn't contain this variable.
- README should be updated to match. (See pending comment on the closed README PR).
| [
{
"content": "'''Core model and functions for building it.'''\nimport os\nimport sys\nimport math\nimport copy\nimport json\nimport logging as log\n\nimport torch\nimport torch.nn as nn\nimport numpy as np\nimport torch.nn.functional as F\nfrom torch.autograd import Variable\nfrom sklearn.metrics import mean_sq... | [
{
"content": "'''Core model and functions for building it.'''\nimport os\nimport sys\nimport math\nimport copy\nimport json\nimport logging as log\n\nimport torch\nimport torch.nn as nn\nimport numpy as np\nimport torch.nn.functional as F\nfrom torch.autograd import Variable\nfrom sklearn.metrics import mean_sq... | diff --git a/.gitmodules b/.gitmodules
new file mode 100644
index 000000000..9a0c946de
--- /dev/null
+++ b/.gitmodules
@@ -0,0 +1,3 @@
+[submodule "src/cove"]
+ path = src/cove
+ url = git@github.com:salesforce/cove.git
diff --git a/README.md b/README.md
index b26726dda..1d4d9d7c5 100644
--- a/README.md
+++ b/README.md... |
spyder-ide__spyder-4177 | Add a message to the Python console about its removal in Spyder 3.2
@dalthviz, the message should be added before the first prompt (i.e. `>>>`) and should say
> NOTE: The Python console is going to be removed in Spyder 3.2. Please start to migrate your work to the IPython console instead.
| [
{
"content": "# -*- coding: utf-8 -*-\r\n#\r\n# Copyright © Spyder Project Contributors\r\n# Licensed under the terms of the MIT License\r\n# (see spyder/__init__.py for details)\r\n\r\n\"\"\"External Console plugin\"\"\"\r\n\r\n# pylint: disable=C0103\r\n# pylint: disable=R0903\r\n# pylint: disable=R0911\r\n# ... | [
{
"content": "# -*- coding: utf-8 -*-\r\n#\r\n# Copyright © Spyder Project Contributors\r\n# Licensed under the terms of the MIT License\r\n# (see spyder/__init__.py for details)\r\n\r\n\"\"\"External Console plugin\"\"\"\r\n\r\n# pylint: disable=C0103\r\n# pylint: disable=R0903\r\n# pylint: disable=R0911\r\n# ... | diff --git a/spyder/plugins/externalconsole.py b/spyder/plugins/externalconsole.py
index 7ee49b14e27..4d9bb2b1b49 100644
--- a/spyder/plugins/externalconsole.py
+++ b/spyder/plugins/externalconsole.py
@@ -715,6 +715,11 @@ def process_started(self, shell_id):
self.help.set_shell(shell.shell)
if se... |
liqd__a4-meinberlin-563 | Making messages for translation has system dependent output
When calling `make makemessages` the output of the generated "djangojs.po" is dependent on the system configuration.
For example in my case it inserts messages from:
"adhocracy4/node_modules/ajv/dist/regenerator.min.js" and
"adhocracy4/node_modules/js-yam... | [
{
"content": "from os import path\n\nfrom django.conf import settings\nfrom django.core.management.commands import makemessages\n\n\ndef get_module_dir(name):\n module = __import__(name)\n return path.dirname(module.__file__)\n\n\nclass Command(makemessages.Command):\n msgmerge_options = (\n mak... | [
{
"content": "from os import path\n\nfrom django.conf import settings\nfrom django.core.management.commands import makemessages\n\n\ndef get_module_dir(name):\n module = __import__(name)\n return path.dirname(module.__file__)\n\n\nclass Command(makemessages.Command):\n msgmerge_options = (\n mak... | diff --git a/apps/contrib/management/commands/makemessages.py b/apps/contrib/management/commands/makemessages.py
index a4772ad235..4f387b6fdb 100644
--- a/apps/contrib/management/commands/makemessages.py
+++ b/apps/contrib/management/commands/makemessages.py
@@ -21,9 +21,9 @@ def handle(self, *args, **options):
... |
pallets__click-1872 | `HelpFormatter.write_text()` is not using all the available line width
`HelpFormatter.write_text()` uses the function `wrap_text(text, width, initial_indent, ...)` internally. This function expects `width` to be the line width **including** the eventual indentation. `HelpFormatter.write_text()` gets this wrong and pass... | [
{
"content": "import typing as t\nfrom contextlib import contextmanager\nfrom gettext import gettext as _\n\nfrom ._compat import term_len\nfrom .parser import split_opt\n\n# Can force a width. This is used by the test system\nFORCED_WIDTH: t.Optional[int] = None\n\n\ndef measure_table(rows: t.Iterable[t.Tuple... | [
{
"content": "import typing as t\nfrom contextlib import contextmanager\nfrom gettext import gettext as _\n\nfrom ._compat import term_len\nfrom .parser import split_opt\n\n# Can force a width. This is used by the test system\nFORCED_WIDTH: t.Optional[int] = None\n\n\ndef measure_table(rows: t.Iterable[t.Tuple... | diff --git a/CHANGES.rst b/CHANGES.rst
index 51f47dc3f..d5705f711 100644
--- a/CHANGES.rst
+++ b/CHANGES.rst
@@ -215,6 +215,8 @@ Unreleased
- When defining a parameter, ``default`` is validated with
``multiple`` and ``nargs``. More validation is done for values being
processed as well. :issue:`1806`
+- `... |
scipy__scipy-20906 | DOC: linalg.schur: unclear signature for `sort` callable when `output='real'`
### Describe your issue.
A real matrix can have complex (conjugate) eigenvalues. scipy.linalg.schur provides the option to produce the **real** Schur decomposition of a real matrix and also the option for a user to provide a callable (a fun... | [
{
"content": "\"\"\"Schur decomposition functions.\"\"\"\nimport numpy as np\nfrom numpy import asarray_chkfinite, single, asarray, array\nfrom numpy.linalg import norm\n\n\n# Local imports.\nfrom ._misc import LinAlgError, _datacopied\nfrom .lapack import get_lapack_funcs\nfrom ._decomp import eigvals\n\n__all... | [
{
"content": "\"\"\"Schur decomposition functions.\"\"\"\nimport numpy as np\nfrom numpy import asarray_chkfinite, single, asarray, array\nfrom numpy.linalg import norm\n\n\n# Local imports.\nfrom ._misc import LinAlgError, _datacopied\nfrom .lapack import get_lapack_funcs\nfrom ._decomp import eigvals\n\n__all... | diff --git a/scipy/linalg/_decomp_schur.py b/scipy/linalg/_decomp_schur.py
index 73bcaffeb700..54a5ce92dd58 100644
--- a/scipy/linalg/_decomp_schur.py
+++ b/scipy/linalg/_decomp_schur.py
@@ -42,6 +42,9 @@ def schur(a, output='real', lwork=None, overwrite_a=False, sort=None,
Specifies whether the upper eigenval... |
open-telemetry__opentelemetry-python-1124 | Zipkin exporter must map status
As per spec: https://github.com/open-telemetry/opentelemetry-specification/blob/master/specification/trace/sdk_exporters/zipkin.md#status
| [
{
"content": "# Copyright The OpenTelemetry Authors\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# http://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless required by... | [
{
"content": "# Copyright The OpenTelemetry Authors\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# http://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless required by... | diff --git a/exporter/opentelemetry-exporter-zipkin/CHANGELOG.md b/exporter/opentelemetry-exporter-zipkin/CHANGELOG.md
index 562e5cc1248..1d03ea25c5b 100644
--- a/exporter/opentelemetry-exporter-zipkin/CHANGELOG.md
+++ b/exporter/opentelemetry-exporter-zipkin/CHANGELOG.md
@@ -15,6 +15,8 @@ Released 2020-09-17
([#109... |
ESMCI__cime-2187 | use MAX_MPI_TASKS_PER_NODE for core limit in test_schedular
The current scheme fails to run tests on small systems that should be okay even though they overload the node.
| [
{
"content": "\"\"\"\nImplementation of the CIME PET test. This class inherits from SystemTestsCommon\n\nThis is an openmp test to determine that changing thread counts does not change answers.\n(1) do an initial run where all components are threaded by default (suffix: base)\n(2) do another initial run with n... | [
{
"content": "\"\"\"\nImplementation of the CIME PET test. This class inherits from SystemTestsCommon\n\nThis is an openmp test to determine that changing thread counts does not change answers.\n(1) do an initial run where all components are threaded by default (suffix: base)\n(2) do another initial run with n... | diff --git a/scripts/lib/CIME/SystemTests/pet.py b/scripts/lib/CIME/SystemTests/pet.py
index 1cb15939f39..e44da463296 100644
--- a/scripts/lib/CIME/SystemTests/pet.py
+++ b/scripts/lib/CIME/SystemTests/pet.py
@@ -46,6 +46,7 @@ def _case_two_setup(self):
# to the batch submission, things break. Setting MAX_TASK... |
OpenEnergyPlatform__oeplatform-690 | Database: Open data only.
Where do we need / want to remind the users?
I added this rule to the [DatabaseRules](http://wiki.openmod-initiative.org/wiki/DatabaseRules).
Do we want to add a reminder to the upload interface?
| [
{
"content": "from django.conf.urls import url\n\nfrom base import views\n\nurlpatterns = [\n url(r\"^robots.txt$\", views.robot),\n url(r\"^$\", views.Welcome.as_view(), name=\"index\"),\n url(r\"^about/$\", views.redir, {\"target\": \"about\"}, name=\"index\"),\n url(r\"^faq/$\", views.redir, {\"t... | [
{
"content": "from django.conf.urls import url\n\nfrom base import views\n\nurlpatterns = [\n url(r\"^robots.txt$\", views.robot),\n url(r\"^$\", views.Welcome.as_view(), name=\"index\"),\n url(r\"^about/$\", views.redir, {\"target\": \"about\"}, name=\"index\"),\n url(r\"^faq/$\", views.redir, {\"t... | diff --git a/base/templates/base/base.html b/base/templates/base/base.html
index 31d4156b7..eee9fe043 100644
--- a/base/templates/base/base.html
+++ b/base/templates/base/base.html
@@ -132,10 +132,7 @@
<a class="nav-link" href="/contact/">Contact</a>
</li>
... |
mozilla__pontoon-2645 | Sync should run locales in order of locale code, not language name
*This issue was created automatically by a [script](https://github.com/mathjazz/bugzilla2github/).*
## [Bug 1703773](https://bugzilla.mozilla.org/show_bug.cgi?id=1703773)
Bug Reporter: @flodolo
CC: @mathjazz
Currently sync runs following the alphabet... | [
{
"content": "import logging\n\nfrom django.conf import settings\nfrom django.db import transaction\nfrom django.utils import timezone\n\nfrom pontoon.base.models import (\n ChangedEntityLocale,\n Project,\n Locale,\n)\n\nfrom pontoon.base.tasks import PontoonTask\nfrom pontoon.sync.changeset import Ch... | [
{
"content": "import logging\n\nfrom django.conf import settings\nfrom django.db import transaction\nfrom django.utils import timezone\n\nfrom pontoon.base.models import (\n ChangedEntityLocale,\n Project,\n Locale,\n)\n\nfrom pontoon.base.tasks import PontoonTask\nfrom pontoon.sync.changeset import Ch... | diff --git a/pontoon/sync/tasks.py b/pontoon/sync/tasks.py
index e708319f78..1be479d41a 100644
--- a/pontoon/sync/tasks.py
+++ b/pontoon/sync/tasks.py
@@ -187,7 +187,7 @@ def sync_translations(
project_sync_log=project_sync_log, repository=repo, start_time=timezone.now()
)
- locales = db_project.loca... |
qtile__qtile-2603 | client_focus and focus_change hooks seem to mean the same thing
# Issue description
There are two hooks with similar names: `client_focus` and `focus_change`. I can't tell what their distinction is conceptually.
We should either clarify the distinction (if there is one) or merge them.
# Qtile version
Mast... | [
{
"content": "# Copyright (c) 2009-2010 Aldo Cortesi\n# Copyright (c) 2010 Lee McCuller\n# Copyright (c) 2010 matt\n# Copyright (c) 2010, 2014 dequis\n# Copyright (c) 2010, 2012, 2014 roger\n# Copyright (c) 2011 Florian Mounier\n# Copyright (c) 2011 Kenji_Takahashi\n# Copyright (c) 2011 Paul Colomiets\n# Copyri... | [
{
"content": "# Copyright (c) 2009-2010 Aldo Cortesi\n# Copyright (c) 2010 Lee McCuller\n# Copyright (c) 2010 matt\n# Copyright (c) 2010, 2014 dequis\n# Copyright (c) 2010, 2012, 2014 roger\n# Copyright (c) 2011 Florian Mounier\n# Copyright (c) 2011 Kenji_Takahashi\n# Copyright (c) 2011 Paul Colomiets\n# Copyri... | diff --git a/libqtile/hook.py b/libqtile/hook.py
index b113e48470..644a0829d2 100644
--- a/libqtile/hook.py
+++ b/libqtile/hook.py
@@ -144,7 +144,8 @@ def changegroup(self, func):
return self._subscribe("changegroup", func)
def focus_change(self, func):
- """Called when focus is changed
+ ... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.