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 ⌀ |
|---|---|---|---|---|
microsoft__ptvsd-1286 | pydevd_resolver.py: "unsupported operand type(s) for +: 'dict' and 'list'" in TupleResolver.get_contents_debug_adapter_protocol throws
## Environment data
- PTVSD version: python-2019.3.6139
- OS and version: Windows10
- Python version (& distribution if applicable, e.g. Anaconda): 3.7.2.64 standard python
- Usi... | [
{
"content": "try:\n import StringIO\nexcept:\n import io as StringIO\nimport traceback\nfrom os.path import basename\n\nfrom functools import partial\nfrom _pydevd_bundle.pydevd_constants import dict_iter_items, dict_keys, xrange\nfrom _pydevd_bundle.pydevd_safe_repr import SafeRepr\n\n# Note: 300 is alr... | [
{
"content": "try:\n import StringIO\nexcept:\n import io as StringIO\nimport traceback\nfrom os.path import basename\n\nfrom functools import partial\nfrom _pydevd_bundle.pydevd_constants import dict_iter_items, dict_keys, xrange\nfrom _pydevd_bundle.pydevd_safe_repr import SafeRepr\n\n# Note: 300 is alr... | diff --git a/src/ptvsd/_vendored/pydevd/_pydevd_bundle/pydevd_resolver.py b/src/ptvsd/_vendored/pydevd/_pydevd_bundle/pydevd_resolver.py
index f497b8b78..1fa6c0de8 100644
--- a/src/ptvsd/_vendored/pydevd/_pydevd_bundle/pydevd_resolver.py
+++ b/src/ptvsd/_vendored/pydevd/_pydevd_bundle/pydevd_resolver.py
@@ -369,7 +369,... |
ytdl-org__youtube-dl-24512 | Prefer ffmpeg HLS decoder for v.redd.it
### Make sure you are using the *latest* version: run `youtube-dl --version` and ensure your version is *2017.11.15*. If it's not, read [this FAQ entry](https://github.com/rg3/youtube-dl/blob/master/README.md#how-do-i-update-youtube-dl) and update. Issues with outdated version wi... | [
{
"content": "from __future__ import unicode_literals\n\nimport re\nimport binascii\ntry:\n from Crypto.Cipher import AES\n can_decrypt_frag = True\nexcept ImportError:\n can_decrypt_frag = False\n\nfrom .fragment import FragmentFD\nfrom .external import FFmpegFD\n\nfrom ..compat import (\n compat_u... | [
{
"content": "from __future__ import unicode_literals\n\nimport re\nimport binascii\ntry:\n from Crypto.Cipher import AES\n can_decrypt_frag = True\nexcept ImportError:\n can_decrypt_frag = False\n\nfrom .fragment import FragmentFD\nfrom .external import FFmpegFD\n\nfrom ..compat import (\n compat_u... | diff --git a/youtube_dl/downloader/hls.py b/youtube_dl/downloader/hls.py
index 84bc3492880..0f2c06f4041 100644
--- a/youtube_dl/downloader/hls.py
+++ b/youtube_dl/downloader/hls.py
@@ -141,7 +141,7 @@ def is_ad_fragment_end(s):
count = 0
headers = info_dict.get('http_headers', ... |
mkdocs__mkdocs-820 | MkDocs incorrectly warns that external themes will be removed in a future release.
A warning that was intended for internal non-mkdocs or readthedocs themes only is being displayed for any other themes.
| [
{
"content": "from __future__ import unicode_literals\nimport os\n\nfrom mkdocs import utils, legacy\nfrom mkdocs.config.base import Config, ValidationError\n\n\nclass BaseConfigOption(object):\n\n def __init__(self):\n self.warnings = []\n self.default = None\n\n def is_required(self):\n ... | [
{
"content": "from __future__ import unicode_literals\nimport os\n\nfrom mkdocs import utils, legacy\nfrom mkdocs.config.base import Config, ValidationError\n\n\nclass BaseConfigOption(object):\n\n def __init__(self):\n self.warnings = []\n self.default = None\n\n def is_required(self):\n ... | diff --git a/docs/about/release-notes.md b/docs/about/release-notes.md
index 60f3167cd8..7a898e4f28 100644
--- a/docs/about/release-notes.md
+++ b/docs/about/release-notes.md
@@ -13,6 +13,12 @@ You can determine your currently installed version using `mkdocs --version`:
$ mkdocs --version
mkdocs, version 0.14... |
holoviz__panel-2775 | Spinner widget doesn't honor bounds when created from Param object
The `Spinner` widget allows you to set a `start` and `end` bound. The widget does not let a user set the number outside the bounds:
```python
pn.widgets.Spinner(start=0, end=5)
```
When creating a `Spinner` widget from a `param.Number` I would h... | [
{
"content": "\"\"\"\nThe input widgets generally allow entering arbitrary information into\na text field or similar.\n\"\"\"\nimport ast\nimport json\n\nfrom base64 import b64decode\nfrom datetime import datetime, date\nfrom six import string_types\n\nimport param\n\nfrom bokeh.models.formatters import TickFor... | [
{
"content": "\"\"\"\nThe input widgets generally allow entering arbitrary information into\na text field or similar.\n\"\"\"\nimport ast\nimport json\n\nfrom base64 import b64decode\nfrom datetime import datetime, date\nfrom six import string_types\n\nimport param\n\nfrom bokeh.models.formatters import TickFor... | diff --git a/panel/tests/test_param.py b/panel/tests/test_param.py
index e1a0f08c6f..8db26d1a08 100644
--- a/panel/tests/test_param.py
+++ b/panel/tests/test_param.py
@@ -9,7 +9,7 @@
from panel.pane import Pane, PaneBase, Matplotlib, Bokeh, HTML
from panel.layout import Tabs, Row
from panel.param import Param, Param... |
DataDog__dd-trace-py-2475 | Mongoengine/PyMongo instrumentation caused extreme slowness(nearly causing an outage).
### Which version of dd-trace-py are you using?
ddtrace==0.48.4
### Which version of pip are you using?
pip 20.0.1
_ddtrace requires pip>=18 to install one of our pre-built wheels_
### Which version of the libraries ar... | [
{
"content": "# stdlib\nimport contextlib\nimport json\n\n# 3p\nimport pymongo\n\n# project\nimport ddtrace\nfrom ddtrace import config\nfrom ddtrace.vendor.wrapt import ObjectProxy\n\nfrom ...constants import ANALYTICS_SAMPLE_RATE_KEY\nfrom ...constants import SPAN_MEASURED_KEY\nfrom ...ext import SpanTypes\nf... | [
{
"content": "# stdlib\nimport contextlib\nimport json\n\n# 3p\nimport pymongo\n\n# project\nimport ddtrace\nfrom ddtrace import config\nfrom ddtrace.vendor.wrapt import ObjectProxy\n\nfrom ...constants import ANALYTICS_SAMPLE_RATE_KEY\nfrom ...constants import SPAN_MEASURED_KEY\nfrom ...ext import SpanTypes\nf... | diff --git a/ddtrace/contrib/pymongo/client.py b/ddtrace/contrib/pymongo/client.py
index b58e99e62b1..4eaa2473f24 100644
--- a/ddtrace/contrib/pymongo/client.py
+++ b/ddtrace/contrib/pymongo/client.py
@@ -55,7 +55,8 @@ def __init__(self, client=None, *args, **kwargs):
# calls in the trace library. This is good... |
getsentry__sentry-65375 | Consolidate Intervals in metric widget preview
| [
{
"content": "import re\nfrom datetime import datetime, timedelta\nfrom enum import Enum\nfrom typing import TypedDict\n\nfrom django.db.models import Max\nfrom rest_framework import serializers\n\nfrom sentry import features, options\nfrom sentry.api.issue_search import parse_search_query\nfrom sentry.api.seri... | [
{
"content": "import re\nfrom datetime import datetime, timedelta\nfrom enum import Enum\nfrom typing import TypedDict\n\nfrom django.db.models import Max\nfrom rest_framework import serializers\n\nfrom sentry import features, options\nfrom sentry.api.issue_search import parse_search_query\nfrom sentry.api.seri... | diff --git a/src/sentry/api/serializers/rest_framework/dashboard.py b/src/sentry/api/serializers/rest_framework/dashboard.py
index e56683645d8831..9eeb87a0af8964 100644
--- a/src/sentry/api/serializers/rest_framework/dashboard.py
+++ b/src/sentry/api/serializers/rest_framework/dashboard.py
@@ -268,7 +268,7 @@ class Thr... |
blakeblackshear__frigate-210 | Small issue with handling of the crop argument
The new cropping setting is a nice addition but when using `crop=0` the image still gets cropped. This is because `request.args.get('crop', 0)` returns the specified value as a string and obviously `bool('0')` is `True`. I think the easiest fix would be to simply use the `... | [
{
"content": "import os\nimport signal\nimport sys\nimport traceback\nimport signal\nimport cv2\nimport time\nimport datetime\nimport queue\nimport yaml\nimport threading\nimport multiprocessing as mp\nimport subprocess as sp\nimport numpy as np\nimport logging\nfrom flask import Flask, Response, make_response,... | [
{
"content": "import os\nimport signal\nimport sys\nimport traceback\nimport signal\nimport cv2\nimport time\nimport datetime\nimport queue\nimport yaml\nimport threading\nimport multiprocessing as mp\nimport subprocess as sp\nimport numpy as np\nimport logging\nfrom flask import Flask, Response, make_response,... | diff --git a/detect_objects.py b/detect_objects.py
index 029c1cb8ef..88dfa7e9a2 100644
--- a/detect_objects.py
+++ b/detect_objects.py
@@ -384,7 +384,7 @@ def best(camera_name, label):
best_object = object_processor.get_best(camera_name, label)
best_frame = best_object.get('frame', np.zeros((7... |
keras-team__keras-core-339 | BatchNorm layer appears broken in multi-backend Keras
classic MNIST training:
- [Keras multi-backend with BN on JAX](https://colab.research.google.com/drive/1ZZI6UK9umgCDSIRcPqVUl6YpLmRdwMF3?resourcekey=0-8YS9usjjxUuh0FUl_JW0Ow&usp=sharing). Final accuracy __19%__!!!
- [Keras multi-backend w/o BN on JAX](https://cola... | [
{
"content": "from keras_core import constraints\nfrom keras_core import initializers\nfrom keras_core import operations as ops\nfrom keras_core import regularizers\nfrom keras_core.api_export import keras_core_export\nfrom keras_core.layers.input_spec import InputSpec\nfrom keras_core.layers.layer import Layer... | [
{
"content": "from keras_core import constraints\nfrom keras_core import initializers\nfrom keras_core import operations as ops\nfrom keras_core import regularizers\nfrom keras_core.api_export import keras_core_export\nfrom keras_core.layers.input_spec import InputSpec\nfrom keras_core.layers.layer import Layer... | diff --git a/keras_core/layers/normalization/batch_normalization.py b/keras_core/layers/normalization/batch_normalization.py
index 765d81d62..5e38cce1b 100644
--- a/keras_core/layers/normalization/batch_normalization.py
+++ b/keras_core/layers/normalization/batch_normalization.py
@@ -201,6 +201,10 @@ def call(self, inp... |
nf-core__tools-1520 | modules install to also print/write `include` statements
### Description of feature
print `include` statements to terminal for easy copy to destination files
| [
{
"content": "import os\nimport questionary\nimport logging\n\nimport nf_core.utils\nimport nf_core.modules.module_utils\n\nfrom .modules_command import ModuleCommand\nfrom .module_utils import get_module_git_log, module_exist_in_repo\n\nlog = logging.getLogger(__name__)\n\n\nclass ModuleInstall(ModuleCommand):... | [
{
"content": "import os\nimport questionary\nimport logging\n\nimport nf_core.utils\nimport nf_core.modules.module_utils\n\nfrom .modules_command import ModuleCommand\nfrom .module_utils import get_module_git_log, module_exist_in_repo\n\nlog = logging.getLogger(__name__)\n\n\nclass ModuleInstall(ModuleCommand):... | diff --git a/CHANGELOG.md b/CHANGELOG.md
index 57a4cff8ea..2b6f8131c7 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -17,6 +17,7 @@
- Add an empty line to `modules.json`, `params.json` and `nextflow-schema.json` when dumping them to avoid prettier errors.
- Add actions workflow to respond to `@nf-core-bot fix lintin... |
freedomofpress__securedrop-4467 | Add list of supported languages to the metadata API
Whether or not a SecureDrop is available in one of the [supported languages](https://docs.securedrop.org/en/latest/admin.html#configuring-localization-for-the-source-interface-and-the-journalist-interface) is public information enumerated at the bottom of the source i... | [
{
"content": "import json\nimport platform\n\nfrom flask import Blueprint, make_response\n\nimport version\n\n\ndef make_blueprint(config):\n view = Blueprint('api', __name__)\n\n @view.route('/metadata')\n def metadata():\n meta = {'gpg_fpr': config.JOURNALIST_KEY,\n 'sd_version'... | [
{
"content": "import json\nimport platform\n\nfrom flask import Blueprint, make_response\n\nimport version\n\n\ndef make_blueprint(config):\n view = Blueprint('api', __name__)\n\n @view.route('/metadata')\n def metadata():\n meta = {\n 'gpg_fpr': config.JOURNALIST_KEY,\n 's... | diff --git a/securedrop/source_app/api.py b/securedrop/source_app/api.py
index 6667d9ba4a..6ae59de884 100644
--- a/securedrop/source_app/api.py
+++ b/securedrop/source_app/api.py
@@ -11,10 +11,12 @@ def make_blueprint(config):
@view.route('/metadata')
def metadata():
- meta = {'gpg_fpr': config.JOURN... |
scoutapp__scout_apm_python-597 | object has no attribute '__qualname__'
I am getting the following error when trying to enable the scout APM on a starlette application:
```
Traceback (most recent call last):
File "/app/.heroku/python/lib/python3.8/site-packages/uvicorn/protocols/http/httptools_impl.py", line 391, in run_asgi
result = await a... | [
{
"content": "# coding=utf-8\nfrom __future__ import absolute_import, division, print_function, unicode_literals\n\nimport wrapt\nfrom starlette.background import BackgroundTask\n\nimport scout_apm.core\nfrom scout_apm.core.tracked_request import TrackedRequest\nfrom scout_apm.core.web_requests import asgi_trac... | [
{
"content": "# coding=utf-8\nfrom __future__ import absolute_import, division, print_function, unicode_literals\n\nimport wrapt\nfrom starlette.background import BackgroundTask\n\nimport scout_apm.core\nfrom scout_apm.core.tracked_request import TrackedRequest\nfrom scout_apm.core.web_requests import asgi_trac... | diff --git a/CHANGELOG.md b/CHANGELOG.md
index 6e451c06..949751cb 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -16,6 +16,8 @@
([PR #598](https://github.com/scoutapp/scout_apm_python/pull/598))
- Fix a socket resource leak when downloading the core agent.
([PR #609](https://github.com/scoutapp/scout_apm_python... |
pantsbuild__pants-13566 | Evaluate removing the invalidation of parent directories when files change
Since using `watchman` (which was deprecated in favor of `notify` in #9714), we have had a special case in place to invalidate the parent directory of a changed file, because in some cases we would not be notified about parent directory changes ... | [
{
"content": "# Copyright 2015 Pants project contributors (see CONTRIBUTORS.md).\n# Licensed under the Apache License, Version 2.0 (see LICENSE).\n\nfrom __future__ import annotations\n\nimport logging\nimport os\nimport time\nfrom dataclasses import dataclass\nfrom pathlib import PurePath\nfrom types import Co... | [
{
"content": "# Copyright 2015 Pants project contributors (see CONTRIBUTORS.md).\n# Licensed under the Apache License, Version 2.0 (see LICENSE).\n\nfrom __future__ import annotations\n\nimport logging\nimport os\nimport time\nfrom dataclasses import dataclass\nfrom pathlib import PurePath\nfrom types import Co... | diff --git a/src/python/pants/engine/internals/scheduler.py b/src/python/pants/engine/internals/scheduler.py
index 0f4ec38b61d..320d9a04cc7 100644
--- a/src/python/pants/engine/internals/scheduler.py
+++ b/src/python/pants/engine/internals/scheduler.py
@@ -277,10 +277,7 @@ def rule_graph_consumed_types(
se... |
Lightning-AI__pytorch-lightning-932 | TPU Training Issues and Feature Requests
TPU training is really cool. A couple issues that came up in training.
* There is no longer a call to `optimizer_step` this is needed for setting learning rates that change over each step. Not sure how to fix this except by maybe having another "post_optimizer" call, which ... | [
{
"content": "import collections\nimport logging as log\nimport csv\nimport os\nimport warnings\nfrom abc import ABC, abstractmethod\nfrom argparse import Namespace\n\nimport torch\nimport torch.distributed as dist\n\nfrom pytorch_lightning.core.decorators import data_loader\nfrom pytorch_lightning.core.grads i... | [
{
"content": "import collections\nimport logging as log\nimport csv\nimport os\nimport warnings\nfrom abc import ABC, abstractmethod\nfrom argparse import Namespace\n\nimport torch\nimport torch.distributed as dist\n\nfrom pytorch_lightning.core.decorators import data_loader\nfrom pytorch_lightning.core.grads i... | diff --git a/docs/source/tpu.rst b/docs/source/tpu.rst
index ca8ad8fee7774..3a3b6ba2db369 100644
--- a/docs/source/tpu.rst
+++ b/docs/source/tpu.rst
@@ -174,3 +174,5 @@ About XLA
----------
XLA is the library that interfaces PyTorch with the TPUs.
For more information check out `XLA <https://github.com/pytorch/xla>`... |
Textualize__textual-4266 | `Switch.action_toggle` name clash
Similar to #4214 `Switch` has an `action_toggle` method whose name and form clash with `DOMNode.action_toggle`.
| [
{
"content": "from __future__ import annotations\n\nfrom typing import TYPE_CHECKING, ClassVar\n\nif TYPE_CHECKING:\n from ..app import RenderResult\nfrom ..binding import Binding, BindingType\nfrom ..events import Click\nfrom ..geometry import Size\nfrom ..message import Message\nfrom ..reactive import reac... | [
{
"content": "from __future__ import annotations\n\nfrom typing import TYPE_CHECKING, ClassVar\n\nif TYPE_CHECKING:\n from ..app import RenderResult\nfrom ..binding import Binding, BindingType\nfrom ..events import Click\nfrom ..geometry import Size\nfrom ..message import Message\nfrom ..reactive import reac... | diff --git a/CHANGELOG.md b/CHANGELOG.md
index 5b3d4909de..3aa2cf3dd3 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -28,6 +28,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/).
- Fixed `RichLog.min_width` not being used https://github.com/Textualize/textual/pull/4223
- Rename `CollapsibleTi... |
aio-libs__aiohttp-3262 | access_log_class can't be used in handle_args of aiohttp.web.Application
## Long story short
I'm setting up a project with a custom access logger. My code looks like:
```python
# main.py
import asyncio
from aiohttp import web
from aiohttp.abc import AbstractAccessLogger
class AccessLogger(AbstractAcces... | [
{
"content": "import asyncio\nimport logging\nimport warnings\nfrom collections import MutableMapping\nfrom functools import partial\nfrom typing import (TYPE_CHECKING, Any, Awaitable, Callable, List, Mapping,\n Optional, Sequence, Tuple, Union)\n\nfrom . import hdrs\nfrom .abc import Abstrac... | [
{
"content": "import asyncio\nimport logging\nimport warnings\nfrom collections import MutableMapping\nfrom functools import partial\nfrom typing import (TYPE_CHECKING, Any, Awaitable, Callable, List, Mapping,\n Optional, Sequence, Tuple, Union)\n\nfrom . import hdrs\nfrom .abc import Abstrac... | diff --git a/CHANGES/3158.bugfix b/CHANGES/3158.bugfix
new file mode 100644
index 00000000000..55662f69f7b
--- /dev/null
+++ b/CHANGES/3158.bugfix
@@ -0,0 +1 @@
+Enable passing `access_log_class` via `handler_args`
diff --git a/CONTRIBUTORS.txt b/CONTRIBUTORS.txt
index c5fcd50c20c..91bf9d8af82 100644
--- a/CONTRIBUTORS... |
beeware__toga-1927 | DetailedList showing empty rows
### Describe the bug
Using Toga for the first time, trying to add `DetailedListBox` to my window. *Something* shows up in the box that contains the `DetailedListBox`, but it just looks like a single empty list cell. `on_select` confirms that it's a list cell.
### Steps to reproduce
Ru... | [
{
"content": "from ..libs import Gdk, Gio, GLib, Gtk\nfrom .base import Widget\nfrom .internal.buttons.refresh import RefreshButton\nfrom .internal.buttons.scroll import ScrollButton\nfrom .internal.rows.texticon import TextIconRow\n\n\n# TODO: Verify if right clicking a row currently works with touch screens, ... | [
{
"content": "from travertino.size import at_least\n\nfrom ..libs import Gdk, Gio, GLib, Gtk\nfrom .base import Widget\nfrom .internal.buttons.refresh import RefreshButton\nfrom .internal.buttons.scroll import ScrollButton\nfrom .internal.rows.texticon import TextIconRow\n\n\n# TODO: Verify if right clicking a ... | diff --git a/changes/1920.bugfix.rst b/changes/1920.bugfix.rst
new file mode 100644
index 0000000000..547ecc89ae
--- /dev/null
+++ b/changes/1920.bugfix.rst
@@ -0,0 +1 @@
+The DetailedList widget on GTK now provides an accurate size hint during layout.
diff --git a/gtk/src/toga_gtk/widgets/detailedlist.py b/gtk/src/tog... |
ESMCI__cime-2860 | floating point mpiprocs when running ./case.setup with python3
I noticed that when running with python3, mpiprocs is set to be a float, i.e.,
$ python3 ./case.setup # will create the following in .case.run:
#PBS -l select=5:ncpus=36:mpiprocs=36.0:ompthreads=1
$ python2 ./case.setup # will create the following .... | [
{
"content": "\"\"\"\nInterface to the env_mach_pes.xml file. This class inherits from EntryID\n\"\"\"\nfrom CIME.XML.standard_module_setup import *\nfrom CIME.XML.env_base import EnvBase\nimport math\n\nlogger = logging.getLogger(__name__)\n\nclass EnvMachPes(EnvBase):\n\n def __init__(self, case_root=None... | [
{
"content": "\"\"\"\nInterface to the env_mach_pes.xml file. This class inherits from EntryID\n\"\"\"\nfrom CIME.XML.standard_module_setup import *\nfrom CIME.XML.env_base import EnvBase\nimport math\n\nlogger = logging.getLogger(__name__)\n\nclass EnvMachPes(EnvBase):\n\n def __init__(self, case_root=None... | diff --git a/scripts/lib/CIME/XML/env_mach_pes.py b/scripts/lib/CIME/XML/env_mach_pes.py
index 9b1dcd8b095..f17f9d8310f 100644
--- a/scripts/lib/CIME/XML/env_mach_pes.py
+++ b/scripts/lib/CIME/XML/env_mach_pes.py
@@ -94,7 +94,7 @@ def get_total_tasks(self, comp_classes):
def get_tasks_per_node(self, total_tasks,... |
ansible__ansible-modules-core-5050 | docker_image often fails to push with docker-py 1.10.x
##### ISSUE TYPE
- Bug Report
##### COMPONENT NAME
docker_image module
##### ANSIBLE VERSION
```
ansible 2.2.0 (devel 07a76bece1) last updated 2016/09/16 16:50:58 (GMT -700)
lib/ansible/modules/core: (detached HEAD 488f082761) last updated 2016/09/16 16:51:07 (... | [
{
"content": "#!/usr/bin/python\n#\n# Copyright 2016 Red Hat | Ansible\n#\n# This file is part of Ansible\n#\n# Ansible is free software: you can redistribute it and/or modify\n# it under the terms of the GNU General Public License as published by\n# the Free Software Foundation, either version 3 of the License... | [
{
"content": "#!/usr/bin/python\n#\n# Copyright 2016 Red Hat | Ansible\n#\n# This file is part of Ansible\n#\n# Ansible is free software: you can redistribute it and/or modify\n# it under the terms of the GNU General Public License as published by\n# the Free Software Foundation, either version 3 of the License... | diff --git a/cloud/docker/docker_image.py b/cloud/docker/docker_image.py
index 0a9ab09096f..7d97d984190 100644
--- a/cloud/docker/docker_image.py
+++ b/cloud/docker/docker_image.py
@@ -424,8 +424,7 @@ def push_image(self, name, tag=None):
if not self.check_mode:
status = None
... |
joke2k__faker-1937 | When attempting to generate a Finnish ssn of a specific age the provider crashes
* Faker version: 19.11.0
* OS: Windows 10
When attempting to generate a Finnish ssn of a certain age the provider crashes because ``datetime.timedelta(days=self.generator.random.randrange(min_age * 365, max_age * 365))`` is always tryi... | [
{
"content": "import datetime\n\nfrom .. import Provider as SsnProvider\n\n\nclass Provider(SsnProvider):\n def ssn(self, min_age: int = 0, max_age: int = 105, artificial: bool = False) -> str:\n \"\"\"\n Returns 11 character Finnish personal identity code (Henkilötunnus,\n HETU, Swedish... | [
{
"content": "import datetime\n\nfrom .. import Provider as SsnProvider\n\n\nclass Provider(SsnProvider):\n def ssn(self, min_age: int = 0, max_age: int = 105, artificial: bool = False) -> str:\n \"\"\"\n Returns 11 character Finnish personal identity code (Henkilötunnus,\n HETU, Swedish... | diff --git a/faker/providers/ssn/fi_FI/__init__.py b/faker/providers/ssn/fi_FI/__init__.py
index 8e8bba6c8a..016782c09c 100644
--- a/faker/providers/ssn/fi_FI/__init__.py
+++ b/faker/providers/ssn/fi_FI/__init__.py
@@ -26,7 +26,10 @@ def _checksum(hetu):
checksum_characters = "0123456789ABCDEFHJKLMNPRSTUVW... |
ytdl-org__youtube-dl-26032 | C-span
<!--
######################################################################
WARNING!
IGNORING THE FOLLOWING TEMPLATE WILL RESULT IN ISSUE CLOSED AS INCOMPLETE
######################################################################
-->
## Checklist
<!--
Carefully read and work through this c... | [
{
"content": "from __future__ import unicode_literals\n\nimport re\n\nfrom .common import InfoExtractor\nfrom ..utils import (\n determine_ext,\n ExtractorError,\n extract_attributes,\n find_xpath_attr,\n get_element_by_class,\n int_or_none,\n smuggle_url,\n unescapeHTML,\n)\nfrom .senat... | [
{
"content": "from __future__ import unicode_literals\n\nimport re\n\nfrom .common import InfoExtractor\nfrom ..utils import (\n determine_ext,\n ExtractorError,\n extract_attributes,\n find_xpath_attr,\n get_element_by_class,\n int_or_none,\n smuggle_url,\n unescapeHTML,\n)\nfrom .senat... | diff --git a/youtube_dl/extractor/cspan.py b/youtube_dl/extractor/cspan.py
index 67d6df4b0eb..3356cc280f6 100644
--- a/youtube_dl/extractor/cspan.py
+++ b/youtube_dl/extractor/cspan.py
@@ -165,6 +165,8 @@ def get_text_attr(d, attr):
formats = self._extract_m3u8_formats(
path, video... |
encode__django-rest-framework-7137 | OpenApi AutoSchema inspection produces invalid type `null` on ArrayField(base_field=ChoicesField())
## Checklist
- [x] I have verified that that issue exists against the `master` branch of Django REST framework.
- [x] I have searched for similar issues in both open and closed tickets and cannot find a duplicate.
-... | [
{
"content": "import warnings\nfrom operator import attrgetter\nfrom urllib.parse import urljoin\n\nfrom django.core.validators import (\n DecimalValidator, EmailValidator, MaxLengthValidator, MaxValueValidator,\n MinLengthValidator, MinValueValidator, RegexValidator, URLValidator\n)\nfrom django.db impor... | [
{
"content": "import warnings\nfrom operator import attrgetter\nfrom urllib.parse import urljoin\n\nfrom django.core.validators import (\n DecimalValidator, EmailValidator, MaxLengthValidator, MaxValueValidator,\n MinLengthValidator, MinValueValidator, RegexValidator, URLValidator\n)\nfrom django.db impor... | diff --git a/rest_framework/schemas/openapi.py b/rest_framework/schemas/openapi.py
index 58788bc234..596b645523 100644
--- a/rest_framework/schemas/openapi.py
+++ b/rest_framework/schemas/openapi.py
@@ -268,13 +268,7 @@ def _map_field(self, field):
'items': {},
}
if not isinst... |
Pycord-Development__pycord-2000 | Can't set custom name for bridge group
### Summary
`@bridge_group(name="name")` gives error
### Reproduction Steps
Create bridge group with a `name=`
### Minimal Reproducible Code
```python
import discord
from discord.ext import bridge
bot = bridge.Bot()
@bot.bridge_group(name="test")
async def _test(c... | [
{
"content": "\"\"\"\nThe MIT License (MIT)\n\nCopyright (c) 2015-2021 Rapptz\nCopyright (c) 2021-present Pycord Development\n\nPermission is hereby granted, free of charge, to any person obtaining a\ncopy of this software and associated documentation files (the \"Software\"),\nto deal in the Software without r... | [
{
"content": "\"\"\"\nThe MIT License (MIT)\n\nCopyright (c) 2015-2021 Rapptz\nCopyright (c) 2021-present Pycord Development\n\nPermission is hereby granted, free of charge, to any person obtaining a\ncopy of this software and associated documentation files (the \"Software\"),\nto deal in the Software without r... | diff --git a/CHANGELOG.md b/CHANGELOG.md
index 57d0af8f6d..951baa9f2e 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -38,6 +38,8 @@ These changes are available on the `master` branch, but have not yet been releas
in cogs. ([#1989](https://github.com/Pycord-Development/pycord/pull/1989))
- Fixed scheduled events br... |
fossasia__open-event-server-2181 | Move Payment Gateways to own subtab
On `admin/settings/` add a subtab "Payment Gateways" and move the Paypal and Stripe here.

:\n \"\"\"\n Use this to get latest system settings\n \"\"\"\n if 'custom_settings' in current_app.config:\n ... | [
{
"content": "import stripe\nfrom flask import current_app\nfrom sqlalchemy import desc\nfrom app.models.setting import Setting\nfrom app.models.fees import TicketFees\n\n\ndef get_settings():\n \"\"\"\n Use this to get latest system settings\n \"\"\"\n if 'custom_settings' in current_app.config:\n ... | diff --git a/app/settings/__init__.py b/app/settings/__init__.py
index 5b82bf70d8..125d84f61c 100644
--- a/app/settings/__init__.py
+++ b/app/settings/__init__.py
@@ -30,7 +30,7 @@ def set_settings(**kwargs):
from app.helpers.data_getter import DataGetter
from app.helpers.data import save_to_db
... |
deepchecks__deepchecks-1341 | [BUG] [Vision] running ImageSegmentPerformance raises out of memory in both gpu and cpu devices
**Describe the bug**
`RuntimeError: CUDA out of memory. Tried to allocate 196.00 MiB (GPU 0; 15.90 GiB total capacity; 14.64 GiB already allocated; 145.75 MiB free; 14.82 GiB reserved in total by PyTorch)`
**To Reprodu... | [
{
"content": "# ----------------------------------------------------------------------------\n# Copyright (C) 2021 Deepchecks (https://www.deepchecks.com)\n#\n# This file is part of Deepchecks.\n# Deepchecks is distributed under the terms of the GNU Affero General\n# Public License (version 3 or later).\n# You ... | [
{
"content": "# ----------------------------------------------------------------------------\n# Copyright (C) 2021 Deepchecks (https://www.deepchecks.com)\n#\n# This file is part of Deepchecks.\n# Deepchecks is distributed under the terms of the GNU Affero General\n# Public License (version 3 or later).\n# You ... | diff --git a/deepchecks/vision/checks/performance/image_segment_performance.py b/deepchecks/vision/checks/performance/image_segment_performance.py
index bb6dd6ae3c..1e47e42d4d 100644
--- a/deepchecks/vision/checks/performance/image_segment_performance.py
+++ b/deepchecks/vision/checks/performance/image_segment_performa... |
svthalia__concrexit-1736 | AttributeError: 'Event' object has no attribute 'title_en'
Sentry Issue: [CONCREXIT-6D](https://sentry.io/organizations/thalia/issues/2465590057/?referrer=github_integration)
```
AttributeError: 'Event' object has no attribute 'title_en'
(9 additional frame(s) were not displayed)
...
File "rest_framework/mixins.py",... | [
{
"content": "from django.template.defaultfilters import date\n\nfrom payments import Payable, payables\nfrom pizzas.models import FoodOrder\nfrom pizzas.services import can_change_order\n\n\nclass FoodOrderPayable(Payable):\n @property\n def payment_amount(self):\n return self.model.product.price\... | [
{
"content": "from django.template.defaultfilters import date\n\nfrom payments import Payable, payables\nfrom pizzas.models import FoodOrder\nfrom pizzas.services import can_change_order\n\n\nclass FoodOrderPayable(Payable):\n @property\n def payment_amount(self):\n return self.model.product.price\... | diff --git a/website/pizzas/payables.py b/website/pizzas/payables.py
index 546db665e..fc82ad5c9 100644
--- a/website/pizzas/payables.py
+++ b/website/pizzas/payables.py
@@ -13,13 +13,13 @@ def payment_amount(self):
@property
def payment_topic(self):
start_date = date(self.model.food_event.start, "Y-m... |
pyg-team__pytorch_geometric-7104 | `data.num_edges` is 0 when using native PyTorch sparse tensor
### 🐛 Describe the bug
When using the native PyTorch sparse tensor for representing the adjacency matrix, the number of edges reported by the `Data` object is always zero. The following code reproduces the issue:
```python
import torch_geometric.transf... | [
{
"content": "import copy\nimport warnings\nimport weakref\nfrom collections import defaultdict, namedtuple\nfrom collections.abc import Mapping, MutableMapping, Sequence\nfrom enum import Enum\nfrom typing import (\n Any,\n Callable,\n Dict,\n Iterable,\n List,\n NamedTuple,\n Optional,\n ... | [
{
"content": "import copy\nimport warnings\nimport weakref\nfrom collections import defaultdict, namedtuple\nfrom collections.abc import Mapping, MutableMapping, Sequence\nfrom enum import Enum\nfrom typing import (\n Any,\n Callable,\n Dict,\n Iterable,\n List,\n NamedTuple,\n Optional,\n ... | diff --git a/CHANGELOG.md b/CHANGELOG.md
index 4daeb5c74452..f69c6930b045 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -15,6 +15,7 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/).
### Changed
+- Added support for `Data.num_edges` for native `torch.sparse.Tensor` adjacency matri... |
ray-project__ray-3656 | PermissionError not defined in Python 2.7
### System information
- **OS Platform and Distribution (e.g., Linux Ubuntu 16.04)**: Ubuntu 16
- **Ray installed from (source or binary)**: binary
- **Ray version**: 0.6.1
- **Python version**: 2.7
- **Exact command to reproduce**:
I don't have access to `/tmp`, and I ... | [
{
"content": "import binascii\nimport collections\nimport datetime\nimport errno\nimport logging\nimport os\nimport shutil\nimport tempfile\n\nimport ray.utils\n\nlogger = logging.getLogger(__name__)\n_incremental_dict = collections.defaultdict(lambda: 0)\n_temp_root = None\n\n\ndef make_inc_temp(suffix=\"\", p... | [
{
"content": "import binascii\nimport collections\nimport datetime\nimport errno\nimport logging\nimport os\nimport shutil\nimport tempfile\n\nimport ray.utils\n\nlogger = logging.getLogger(__name__)\n_incremental_dict = collections.defaultdict(lambda: 0)\n_temp_root = None\n\n\ndef make_inc_temp(suffix=\"\", p... | diff --git a/python/ray/tempfile_services.py b/python/ray/tempfile_services.py
index 791b8a257f089..104c81c5f0cfa 100644
--- a/python/ray/tempfile_services.py
+++ b/python/ray/tempfile_services.py
@@ -66,8 +66,16 @@ def try_to_create_directory(directory_path):
# important when multiple people are using the sam... |
iterative__dvc-5205 | diff: unexpected error when diffing workspace after dvc remove
# Bug Report
## Description
`dvc diff` will raise unexpected error with no other output if both the `.dvc` file and the original data file are removed from the workspace (i.e. after running `dvc remove`).
```
$ git status ... | [
{
"content": "import logging\nimport os\n\nfrom dvc.exceptions import PathMissingError\nfrom dvc.repo import locked\nfrom dvc.tree.local import LocalTree\nfrom dvc.tree.repo import RepoTree\n\nlogger = logging.getLogger(__name__)\n\n\n@locked\ndef diff(self, a_rev=\"HEAD\", b_rev=None, targets=None):\n \"\"\... | [
{
"content": "import logging\nimport os\n\nfrom dvc.exceptions import PathMissingError\nfrom dvc.repo import locked\nfrom dvc.tree.local import LocalTree\nfrom dvc.tree.repo import RepoTree\n\nlogger = logging.getLogger(__name__)\n\n\n@locked\ndef diff(self, a_rev=\"HEAD\", b_rev=None, targets=None):\n \"\"\... | diff --git a/dvc/repo/diff.py b/dvc/repo/diff.py
index 097d30d4ae..8d9958acf2 100644
--- a/dvc/repo/diff.py
+++ b/dvc/repo/diff.py
@@ -148,11 +148,14 @@ def _dir_output_paths(repo_tree, output, targets=None):
def _filter_missing(repo, paths):
repo_tree = RepoTree(repo, stream=True)
for path in paths:
- ... |
openstates__openstates-scrapers-1952 | FL: No bills with signed dates for 2017 session.
State: FL
The bill data for FL 2017 session shows none with signed dates, parser doesn't appear to track Approved by Governor or other executive actions.
| [
{
"content": "import re\nimport datetime\nfrom urllib.parse import urlencode\nfrom collections import defaultdict\nfrom pupa.scrape import Scraper, Bill, VoteEvent\nfrom pupa.utils import format_datetime\nfrom spatula import Page, PDF, Spatula\n\n\nclass StartPage(Page):\n\n def handle_page(self):\n t... | [
{
"content": "import re\nimport datetime\nfrom urllib.parse import urlencode\nfrom collections import defaultdict\nfrom pupa.scrape import Scraper, Bill, VoteEvent\nfrom pupa.utils import format_datetime\nfrom spatula import Page, PDF, Spatula\n\n\nclass StartPage(Page):\n\n def handle_page(self):\n t... | diff --git a/openstates/fl/bills.py b/openstates/fl/bills.py
index e2cb4873b0..f6217de9e2 100644
--- a/openstates/fl/bills.py
+++ b/openstates/fl/bills.py
@@ -155,6 +155,10 @@ def process_history(self):
atype.append('passage')
elif action.startswith('CS passed'):
... |
xorbitsai__inference-1093 | ENH: [UI] Show `replica` count on running model page
Note that the issue tracker is NOT the place for general support.
| [
{
"content": "# Copyright 2022-2023 XProbe 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# Unless required by ap... | [
{
"content": "# Copyright 2022-2023 XProbe 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# Unless required by ap... | diff --git a/xinference/core/supervisor.py b/xinference/core/supervisor.py
index 348bb6528a..a736869d16 100644
--- a/xinference/core/supervisor.py
+++ b/xinference/core/supervisor.py
@@ -922,7 +922,11 @@ async def list_models(self) -> Dict[str, Dict[str, Any]]:
workers = list(self._worker_address_to_worker.val... |
sublimelsp__LSP-2163 | Backslash in hover popup is not shown
**Describe the bug**
As the title.
Original response payload:
```
:: <<< LSP-intelephense 22: {'range': {'start': {'line': 4, 'character': 6}, 'end': {'line': 4, 'character': 9}}, 'contents': {'kind': 'markdown', 'value': '__A\\B\\C\\Foo__\n\n```php\n<?php\nclass Foo { }\... | [
{
"content": "from .css import css as lsp_css\nfrom .protocol import CodeAction\nfrom .protocol import CodeActionKind\nfrom .protocol import CodeActionContext\nfrom .protocol import CodeActionParams\nfrom .protocol import CodeActionTriggerKind\nfrom .protocol import Color\nfrom .protocol import ColorInformation... | [
{
"content": "from .css import css as lsp_css\nfrom .protocol import CodeAction\nfrom .protocol import CodeActionKind\nfrom .protocol import CodeActionContext\nfrom .protocol import CodeActionParams\nfrom .protocol import CodeActionTriggerKind\nfrom .protocol import Color\nfrom .protocol import ColorInformation... | diff --git a/plugin/core/views.py b/plugin/core/views.py
index 03193057c..ba0c74821 100644
--- a/plugin/core/views.py
+++ b/plugin/core/views.py
@@ -720,12 +720,6 @@ def minihtml(
"allow_code_wrap": True,
"markdown_extensions": [
"markdown.extensions.admonition",
- ... |
scverse__scanpy-321 | Plotting layout behavior at repl
As mentioned in #299, I'm getting some strange layout behavior when plotting at the repl.
Using the setup:
```python
import scanpy.api as sc
import numpy as np
N = 1000
M = 2000
adata = sc.AnnData(X=np.random.random_sample((N, M)))
sc.pp.pca(adata)
```
I get output... | [
{
"content": "from matplotlib import pyplot as pl\nfrom pandas.api.types import is_categorical_dtype\nimport numpy as np\nfrom matplotlib import rcParams\nfrom matplotlib.colors import is_color_like\nfrom .. import utils\nfrom ...utils import sanitize_anndata, doc_params\nfrom ... import settings\nfrom ..docs i... | [
{
"content": "from matplotlib import pyplot as pl\nfrom pandas.api.types import is_categorical_dtype\nimport numpy as np\nfrom matplotlib import rcParams\nfrom matplotlib.colors import is_color_like\nfrom .. import utils\nfrom ...utils import sanitize_anndata, doc_params\nfrom ... import settings\nfrom ..docs i... | diff --git a/scanpy/plotting/tools/scatterplots.py b/scanpy/plotting/tools/scatterplots.py
index d4650cd5da..0ed1622e1c 100644
--- a/scanpy/plotting/tools/scatterplots.py
+++ b/scanpy/plotting/tools/scatterplots.py
@@ -236,7 +236,7 @@ def plot_scatter(adata,
from matplotlib import gridspec
# set up th... |
conda__conda-build-2420 | noarch: python packages strip data_files
in setup.py, `data_files` can be used to deliver support files, especially to `$PREFIX/share`. `noarch: python` [doesn't know how to handle these](https://github.com/conda/conda-build/blob/3.0.23/conda_build/noarch_python.py#L90) and ends up omitting them.
It seems like 'unkn... | [
{
"content": "import io\nimport json\nimport locale\nimport logging\nimport os\nfrom os.path import basename, dirname, isdir, join, isfile\nimport shutil\nimport sys\n\nISWIN = sys.platform.startswith('win')\n\n\ndef _force_dir(dirname):\n if not isdir(dirname):\n os.makedirs(dirname)\n\n\ndef _error_... | [
{
"content": "import io\nimport json\nimport locale\nimport logging\nimport os\nfrom os.path import basename, dirname, isdir, join, isfile\nimport shutil\nimport sys\n\nISWIN = sys.platform.startswith('win')\n\n\ndef _force_dir(dirname):\n if not isdir(dirname):\n os.makedirs(dirname)\n\n\ndef _error_... | diff --git a/conda_build/noarch_python.py b/conda_build/noarch_python.py
index 9611e4388f..c5c51cfd31 100644
--- a/conda_build/noarch_python.py
+++ b/conda_build/noarch_python.py
@@ -85,10 +85,11 @@ def handle_file(f, d, prefix):
# Include examples in the metadata doc
elif f.startswith(('Examples/', 'Examples... |
quantumlib__Cirq-4255 | Using `def _channel_(...)` to specify channels was changed to `def _kraus_(...)` without a deprecation period
This caused sudden breakages internally when we updated.
https://github.com/quantumlib/Cirq/commit/bc4123ef2a85c6a61667dc268554429690d2838d
Repro:
```
import cirq
import numpy as np
class Measuremen... | [
{
"content": "# Copyright 2018 The Cirq Developers\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# https://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless required by... | [
{
"content": "# Copyright 2018 The Cirq Developers\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# https://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless required by... | diff --git a/cirq-core/cirq/ops/gate_operation.py b/cirq-core/cirq/ops/gate_operation.py
index dda8fdb6597..412428c8fc9 100644
--- a/cirq-core/cirq/ops/gate_operation.py
+++ b/cirq-core/cirq/ops/gate_operation.py
@@ -201,6 +201,18 @@ def _mixture_(self) -> Sequence[Tuple[float, Any]]:
return getter()
... |
hpcaitech__ColossalAI-2737 | [tensor] fix some unittests
[tensor] fix some unittests
[tensor] fix some unittests
| [
{
"content": "from dataclasses import dataclass\nfrom torch.fx.node import Node\nfrom torch.fx.graph import Graph\nfrom torch.fx.graph_module import GraphModule\nfrom collections import OrderedDict as ODict\nfrom typing import List, OrderedDict, Union, Any\nfrom colossalai.fx.passes.utils import get_node_module... | [
{
"content": "from collections import OrderedDict as ODict\nfrom dataclasses import dataclass\nfrom typing import Any, List, OrderedDict, Union\n\nfrom torch.fx.graph import Graph\nfrom torch.fx.graph_module import GraphModule\nfrom torch.fx.node import Node\n\nfrom colossalai.fx.passes.utils import get_node_mo... | diff --git a/colossalai/auto_parallel/tensor_shard/deprecated/graph_analysis.py b/colossalai/auto_parallel/tensor_shard/deprecated/graph_analysis.py
index 831e7eadd179..9f7a6a5ec286 100644
--- a/colossalai/auto_parallel/tensor_shard/deprecated/graph_analysis.py
+++ b/colossalai/auto_parallel/tensor_shard/deprecated/gra... |
bentoml__BentoML-992 | Add console log to prediction
**Is your feature request related to a problem? Please describe.**
When running bentoml in a docker container, request logs are not printed to standard out.
**Describe the solution you'd like**
In a [slack discussion](https://bentoml.slack.com/archives/CKRANBHPH/p1597270160005700), th... | [
{
"content": "# Copyright 2019 Atalaya Tech, 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# Unless required by applicab... | [
{
"content": "# Copyright 2019 Atalaya Tech, 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# Unless required by applicab... | diff --git a/bentoml/utils/log.py b/bentoml/utils/log.py
index b286acca53c..1b27d5e2064 100644
--- a/bentoml/utils/log.py
+++ b/bentoml/utils/log.py
@@ -87,12 +87,12 @@ def get_logging_config_dict(logging_level, base_log_directory):
"propagate": False,
},
"bentoml.prediction":... |
OCA__server-tools-75 | [7.0] [base_optional_quick_create] AttributeError: 'NoneType' object has no attribute 'name_create'
Error at starting before a migration if a model has been removed
| [
{
"content": "# -*- coding: utf-8 -*-\n##############################################################################\n#\n# Copyright (C) 2013 Agile Business Group sagl (<http://www.agilebg.com>)\n#\n# This program is free software: you can redistribute it and/or modify\n# it under the terms of the GNU... | [
{
"content": "# -*- coding: utf-8 -*-\n##############################################################################\n#\n# Copyright (C) 2013 Agile Business Group sagl (<http://www.agilebg.com>)\n#\n# This program is free software: you can redistribute it and/or modify\n# it under the terms of the GNU... | diff --git a/base_optional_quick_create/model.py b/base_optional_quick_create/model.py
index 20345dadbf0..00862f0c70d 100644
--- a/base_optional_quick_create/model.py
+++ b/base_optional_quick_create/model.py
@@ -44,7 +44,7 @@ def _register_hook(self, cr, ids=None):
if model.avoid_quick_create:
... |
mampfes__hacs_waste_collection_schedule-1879 | [Bug]: WasteNet Southland not working after 1.46.0
### I Have A Problem With:
A specific source
### What's Your Problem
The WasteNet Southland website and url has changed about a month ago. The issue created by this change was supposed to be fixed in 1.46.0, but unfortunately it is still not working.
Tested with my... | [
{
"content": "import re\nfrom datetime import datetime\nfrom html.parser import HTMLParser\n\nimport requests\nfrom waste_collection_schedule import Collection # type: ignore[attr-defined]\n\nTITLE = \"Gore, Invercargill & Southland\"\nDESCRIPTION = \"Source for Wastenet.org.nz.\"\nURL = \"http://www.wastenet.... | [
{
"content": "import re\nfrom datetime import datetime\nfrom html.parser import HTMLParser\n\nimport requests\nfrom waste_collection_schedule import Collection # type: ignore[attr-defined]\n\nTITLE = \"Gore, Invercargill & Southland\"\nDESCRIPTION = \"Source for Wastenet.org.nz.\"\nURL = \"http://www.wastenet.... | diff --git a/custom_components/waste_collection_schedule/waste_collection_schedule/source/wastenet_org_nz.py b/custom_components/waste_collection_schedule/waste_collection_schedule/source/wastenet_org_nz.py
index 88d3b5c27..26d5ae016 100644
--- a/custom_components/waste_collection_schedule/waste_collection_schedule/sou... |
openstates__openstates-scrapers-2984 | FL failing since at least 2019-06-03
FL has been failing since 2019-06-03
Based on automated runs it appears that FL has not run successfully in 2 days (2019-06-03).
```
04:01:17 CRITICAL pupa: Session(s) 2009B, 2003C, 2003B, 2002E, 2004A, 2012 Org., 2007D, 1998 Org, 2000A (Jan.), 2007C, 2007A, 2000A (Dec.), 2006 ... | [
{
"content": "# encoding=utf-8\nimport logging\nfrom pupa.scrape import Jurisdiction, Organization\nfrom .bills import FlBillScraper\nfrom .people import FlPersonScraper\n# from .committees import FlCommitteeScraper\n# from .events import FlEventScraper\nfrom openstates.utils import url_xpath\n\nlogging.getLogg... | [
{
"content": "# encoding=utf-8\nimport logging\nfrom pupa.scrape import Jurisdiction, Organization\nfrom .bills import FlBillScraper\nfrom .people import FlPersonScraper\n# from .committees import FlCommitteeScraper\n# from .events import FlEventScraper\nfrom openstates.utils import url_xpath\n\nlogging.getLogg... | diff --git a/openstates/fl/__init__.py b/openstates/fl/__init__.py
index ffdb382b85..48f4e0635f 100644
--- a/openstates/fl/__init__.py
+++ b/openstates/fl/__init__.py
@@ -62,6 +62,37 @@ class Florida(Jurisdiction):
'2014O',
'2016O',
'2018O',
+ '2018 Org.',
+ '2016 Org.',
+ ... |
spyder-ide__spyder-6523 | AttributeError in jedi_plugin.py:102
I am getting the following error with the current master:
```
Response error:Traceback (most recent call last):
File "plugin_server.py", line 95, in run
response['result'] = func(*args, **kwargs)
File "/home/jitse/misc/spyder/spyder/utils/introspection/jedi_plugin.py", ... | [
{
"content": "# -*- coding: utf-8 -*-\n#\n# Copyright © Spyder Project Contributors\n# Licensed under the terms of the MIT License\n# (see spyder/__init__.py for details)\n\n\"\"\"\nJedi Introspection Plugin\n\"\"\"\nimport re\nimport os.path as osp\nimport sys\nimport time\n\nfrom spyder.config.base import deb... | [
{
"content": "# -*- coding: utf-8 -*-\n#\n# Copyright © Spyder Project Contributors\n# Licensed under the terms of the MIT License\n# (see spyder/__init__.py for details)\n\n\"\"\"\nJedi Introspection Plugin\n\"\"\"\nimport re\nimport os.path as osp\nimport sys\nimport time\n\nfrom spyder.config.base import deb... | diff --git a/spyder/utils/introspection/jedi_plugin.py b/spyder/utils/introspection/jedi_plugin.py
index ffe6a127a33..e9884a06e02 100644
--- a/spyder/utils/introspection/jedi_plugin.py
+++ b/spyder/utils/introspection/jedi_plugin.py
@@ -99,7 +99,7 @@ def get_info(self, info):
calltip = getsignaturefromtext... |
bokeh__bokeh-6413 | matches() is broken when pandas is not installed
For example `models/server/buttons` fail with:
```
Traceback (most recent call last):
File "examples/models/server/buttons.py", line 5, in <module>
from bokeh.models.layouts import WidgetBox
File "/home/mateusz/repos/bokeh/bokeh/models/__init__.py", line 5, ... | [
{
"content": "''' Provide base classes for the Bokeh property system.\n\n.. note::\n These classes form part of the very low-level machinery that implements\n the Bokeh model and property system. It is unlikely that any of these\n classes or their methods will be applicable to any standard usage or to\... | [
{
"content": "''' Provide base classes for the Bokeh property system.\n\n.. note::\n These classes form part of the very low-level machinery that implements\n the Bokeh model and property system. It is unlikely that any of these\n classes or their methods will be applicable to any standard usage or to\... | diff --git a/bokeh/core/property/bases.py b/bokeh/core/property/bases.py
index 016514412c4..07ac2fb7887 100644
--- a/bokeh/core/property/bases.py
+++ b/bokeh/core/property/bases.py
@@ -181,11 +181,12 @@ def matches(self, new, old):
if isinstance(new, np.ndarray) or isinstance(old, np.ndarray):
ret... |
python-pillow__Pillow-2275 | Error when save a particular image
Hi all,
I try to simply resize one image with Pillow (3.1.1, and i try on last 3.4.2 with same result) and the save function return an error.
The image is in this link
https://drive.google.com/file/d/0BxZoHLj1LrNeNU5vSHpnSjFNNFE/view?usp=sharing
This is the code i use
```pyt... | [
{
"content": "#\n# The Python Imaging Library.\n# $Id$\n#\n# JPEG (JFIF) file handling\n#\n# See \"Digital Compression and Coding of Continuous-Tone Still Images,\n# Part 1, Requirements and Guidelines\" (CCITT T.81 / ISO 10918-1)\n#\n# History:\n# 1995-09-09 fl Created\n# 1995-09-13 fl Added full parser\n#... | [
{
"content": "#\n# The Python Imaging Library.\n# $Id$\n#\n# JPEG (JFIF) file handling\n#\n# See \"Digital Compression and Coding of Continuous-Tone Still Images,\n# Part 1, Requirements and Guidelines\" (CCITT T.81 / ISO 10918-1)\n#\n# History:\n# 1995-09-09 fl Created\n# 1995-09-13 fl Added full parser\n#... | diff --git a/PIL/JpegImagePlugin.py b/PIL/JpegImagePlugin.py
index 221bf6495e1..4daf67aad20 100644
--- a/PIL/JpegImagePlugin.py
+++ b/PIL/JpegImagePlugin.py
@@ -716,8 +716,11 @@ def validate_qtables(qtables):
# https://github.com/matthewwithanm/django-imagekit/issues/50
bufsize = 0
if optimize or progres... |
django-cms__django-cms-2937 | (Un-)publishing a normal pages gives spews warning message on console re: app url changes
Latest dev. 3.0b4.dev14
Simply publishing a page or unpublishing it spews this into the console (on runserver):
“Application url changed and urls_need_reloading signal fired. Please reload the urls.py or restart the server”
I t... | [
{
"content": "# -*- coding: utf-8 -*-\nimport sys\nfrom django.core.management import color_style\nfrom django.core.urlresolvers import clear_url_caches\nfrom django.core.signals import request_finished\nfrom cms.models import Title\n\n\nDISPATCH_UID = 'cms-restart'\n\n\ndef apphook_pre_title_checker(instance, ... | [
{
"content": "# -*- coding: utf-8 -*-\nimport sys\nfrom django.core.management import color_style\nfrom django.core.urlresolvers import clear_url_caches\nfrom django.core.signals import request_finished\nfrom cms.models import Title\n\n\nDISPATCH_UID = 'cms-restart'\n\n\ndef apphook_pre_title_checker(instance, ... | diff --git a/cms/signals/apphook.py b/cms/signals/apphook.py
index 7b50f4358f9..fbf7b27205f 100644
--- a/cms/signals/apphook.py
+++ b/cms/signals/apphook.py
@@ -47,7 +47,7 @@ def apphook_post_title_checker(instance, **kwargs):
old_title.published, old_title.page.application_urls, old_title.page.application... |
google__fuzzbench-1360 | Unbound variable in scheduler.py
```
UnboundLocalError: local variable 'trial_instance_manager' referenced before assignment Message: Error occurred during scheduling.
at .schedule_loop ( [/work/src/experiment/scheduler.py:585](https://pantheon.corp.google.com/debug?referrer=fromlog&file=%2Fwork%2Fsrc%2Fexperiment... | [
{
"content": "# Copyright 2020 Google LLC\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 applicab... | [
{
"content": "# Copyright 2020 Google LLC\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 applicab... | diff --git a/experiment/scheduler.py b/experiment/scheduler.py
index 01d645097..0f8946001 100644
--- a/experiment/scheduler.py
+++ b/experiment/scheduler.py
@@ -562,9 +562,11 @@ def schedule_loop(experiment_config: dict):
pool_args = (processes, _process_init, (cores_queue,))
else:
po... |
zulip__zulip-5496 | 500 server error on LDAP login
I'm not sure if this is related to server configuration, as I've not successfully gotten LDAP login to work yet. But `manage.py query_ldap` is fine, so I thought that should mean my Zulip configuration is correct.
When I login using the user's email and pw, Zulip contacts the director... | [
{
"content": "from __future__ import absolute_import\n\nimport logging\nfrom typing import Any, Dict, List, Set, Tuple, Optional, Text\n\nfrom django.contrib.auth.backends import RemoteUserBackend\nfrom django.conf import settings\nfrom django.http import HttpResponse\nimport django.contrib.auth\n\nfrom django_... | [
{
"content": "from __future__ import absolute_import\n\nimport logging\nfrom typing import Any, Dict, List, Set, Tuple, Optional, Text\n\nfrom django.contrib.auth.backends import RemoteUserBackend\nfrom django.conf import settings\nfrom django.http import HttpResponse\nimport django.contrib.auth\n\nfrom django_... | diff --git a/zerver/tests/test_auth_backends.py b/zerver/tests/test_auth_backends.py
index 7fefdb5f5f055..3a9656dbbd5c8 100644
--- a/zerver/tests/test_auth_backends.py
+++ b/zerver/tests/test_auth_backends.py
@@ -1776,8 +1776,8 @@ def test_login_failure_due_to_wrong_password(self):
LDAP_APPEND_DOMAIN='... |
ethereum__web3.py-3248 | Web3.isAddress doesn't work for non prefixed checksumed values
* Version: 4.0.0b11
* Python: 3.6
* OS: linux
### What was wrong?
As stated in the docs http://web3py.readthedocs.io/en/latest/overview.html#Web3.isAddress the function Web3.isAddress(value) should **allow both 0x prefixed and non prefixed values**.... | [
{
"content": "#!/usr/bin/env python\nfrom setuptools import (\n find_packages,\n setup,\n)\n\nextras_require = {\n \"tester\": [\n \"eth-tester[py-evm]==v0.10.0-b.1\",\n \"py-geth>=4.1.0\",\n ],\n \"linter\": [\n \"black>=22.1.0\",\n \"flake8==3.8.3\",\n \"isort... | [
{
"content": "#!/usr/bin/env python\nfrom setuptools import (\n find_packages,\n setup,\n)\n\nextras_require = {\n \"tester\": [\n \"eth-tester[py-evm]==v0.10.0-b.3\",\n \"py-geth>=4.1.0\",\n ],\n \"linter\": [\n \"black>=22.1.0\",\n \"flake8==3.8.3\",\n \"isort... | diff --git a/newsfragments/3248.misc.rst b/newsfragments/3248.misc.rst
new file mode 100644
index 0000000000..c9d5b73b6b
--- /dev/null
+++ b/newsfragments/3248.misc.rst
@@ -0,0 +1 @@
+Upgrade ``eth-utils`` to ``v4.0.0``.
diff --git a/setup.py b/setup.py
index 2716cb1c51..89bf0b343a 100644
--- a/setup.py
+++ b/setup.py
... |
Parsl__parsl-1865 | Support memoization of tuples
We already support lists, so implementing an `id_for_memo` for tuple types is straightforward.
| [
{
"content": "import hashlib\nfrom functools import singledispatch\nimport logging\nfrom parsl.serialize import serialize\nimport types\n\nlogger = logging.getLogger(__name__)\n\n\n@singledispatch\ndef id_for_memo(obj, output_ref=False):\n \"\"\"This should return a byte sequence which identifies the supplie... | [
{
"content": "import hashlib\nfrom functools import singledispatch\nimport logging\nfrom parsl.serialize import serialize\nimport types\n\nlogger = logging.getLogger(__name__)\n\n\n@singledispatch\ndef id_for_memo(obj, output_ref=False):\n \"\"\"This should return a byte sequence which identifies the supplie... | diff --git a/parsl/dataflow/memoization.py b/parsl/dataflow/memoization.py
index c6a7217f0f..0c2ef6525a 100644
--- a/parsl/dataflow/memoization.py
+++ b/parsl/dataflow/memoization.py
@@ -62,6 +62,19 @@ def id_for_memo_list(denormalized_list, output_ref=False):
return serialize(normalized_list)
+@id_for_memo.re... |
spack__spack-21177 | Installation issue: perl%nvhpc
<!-- Explain, in a clear and concise way, the command you ran and the result you were trying to achieve.
Example: "I ran `spack find` to list all the installed packages and ..." -->
### Steps to reproduce the issue
```console
$ spack install netcdf-c%nvhpc@20.11
...
```
###... | [
{
"content": "# Copyright 2013-2021 Lawrence Livermore National Security, LLC and other\n# Spack Project Developers. See the top-level COPYRIGHT file for details.\n#\n# SPDX-License-Identifier: (Apache-2.0 OR MIT)\n\n#\n# Author: Milton Woods <milton.woods@bom.gov.au>\n# Date: March 22, 2017\n# Author: George H... | [
{
"content": "# Copyright 2013-2021 Lawrence Livermore National Security, LLC and other\n# Spack Project Developers. See the top-level COPYRIGHT file for details.\n#\n# SPDX-License-Identifier: (Apache-2.0 OR MIT)\n\n#\n# Author: Milton Woods <milton.woods@bom.gov.au>\n# Date: March 22, 2017\n# Author: George H... | diff --git a/var/spack/repos/builtin/packages/perl/nvhpc.patch b/var/spack/repos/builtin/packages/perl/nvhpc-5.30.patch
similarity index 100%
rename from var/spack/repos/builtin/packages/perl/nvhpc.patch
rename to var/spack/repos/builtin/packages/perl/nvhpc-5.30.patch
diff --git a/var/spack/repos/builtin/packages/perl/... |
blakeblackshear__frigate-5642 | Should `sub_labels` be included in `api/events/summary` ?
I'm trying to implement `sub_label` support in the card (https://github.com/dermotduffy/frigate-hass-card/issues/900). To do this, I need to fetch the available sub_labels.
I had assumed they would show up in the event summary information, but they don't. So... | [
{
"content": "import base64\nfrom datetime import datetime, timedelta, timezone\nimport copy\nimport glob\nimport logging\nimport json\nimport os\nimport subprocess as sp\nimport pytz\nimport time\nimport traceback\n\nfrom functools import reduce\nfrom pathlib import Path\nfrom tzlocal import get_localzone_name... | [
{
"content": "import base64\nfrom datetime import datetime, timedelta, timezone\nimport copy\nimport glob\nimport logging\nimport json\nimport os\nimport subprocess as sp\nimport pytz\nimport time\nimport traceback\n\nfrom functools import reduce\nfrom pathlib import Path\nfrom tzlocal import get_localzone_name... | diff --git a/frigate/http.py b/frigate/http.py
index 01df6ed8a3..f59e341df2 100644
--- a/frigate/http.py
+++ b/frigate/http.py
@@ -111,6 +111,7 @@ def events_summary():
Event.select(
Event.camera,
Event.label,
+ Event.sub_label,
fn.strftime(
"%... |
qutip__qutip-259 | Hadamard transform normalisation factor incorrect
The qip.hadamard_transform function does not return return expected output.
Tested with N=1 in Python 2.7 and factor is 0.5 rather than 1/sqrt(2).
The 2*_(-N / 2) would need to be something like 2_(-N / 2.0) to ensure float division
Hadamard transform normalisation... | [
{
"content": "# This file is part of QuTiP: Quantum Toolbox in Python.\n#\n# Copyright (c) 2011 and later, Paul D. Nation and Robert J. Johansson.\n# All rights reserved.\n#\n# Redistribution and use in source and binary forms, with or without\n# modification, are permitted provided that the followi... | [
{
"content": "# This file is part of QuTiP: Quantum Toolbox in Python.\n#\n# Copyright (c) 2011 and later, Paul D. Nation and Robert J. Johansson.\n# All rights reserved.\n#\n# Redistribution and use in source and binary forms, with or without\n# modification, are permitted provided that the followi... | diff --git a/qutip/qip/gates.py b/qutip/qip/gates.py
index f1f9e499b3..88c322aef9 100644
--- a/qutip/qip/gates.py
+++ b/qutip/qip/gates.py
@@ -30,7 +30,7 @@
# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
###########... |
pwr-Solaar__Solaar-1409 | MK270 keyboard shows Battery status 30% even with full batteries
**Information**
<!-- Make sure that your issue is not one of the known issues in the Solaar documentation at https://pwr-solaar.github.io/Solaar/ -->
<!-- Do not bother opening an issue for a version older than 1.1.0. Update to the latest version and ... | [
{
"content": "# -*- python-mode -*-\n\n## Copyright (C) 2012-2013 Daniel Pavel\n##\n## This program is free software; you can redistribute it and/or modify\n## it under the terms of the GNU General Public License as published by\n## the Free Software Foundation; either version 2 of the License, or\n## (at your... | [
{
"content": "# -*- python-mode -*-\n\n## Copyright (C) 2012-2013 Daniel Pavel\n##\n## This program is free software; you can redistribute it and/or modify\n## it under the terms of the GNU General Public License as published by\n## the Free Software Foundation; either version 2 of the License, or\n## (at your... | diff --git a/lib/solaar/ui/icons.py b/lib/solaar/ui/icons.py
index 551303b158..bf4157d9f4 100644
--- a/lib/solaar/ui/icons.py
+++ b/lib/solaar/ui/icons.py
@@ -127,7 +127,7 @@ def _battery_icon_name(level, charging):
if level is None or level < 0:
return 'battery-missing' + ('-symbolic' if gtk.battery_icon... |
django-helpdesk__django-helpdesk-777 | Error trying to attach a file when using django-storages
Hello,
I'm receiving this error when I try to attach a file
```
Traceback (most recent call last):
File "/usr/local/lib/python2.7/dist-packages/django/core/handlers/exception.py", line 41, in inner
response = get_response(request)
File "/usr/loc... | [
{
"content": "import os\nimport mimetypes\nimport logging\nfrom smtplib import SMTPException\n\nfrom django.utils.safestring import mark_safe\n\nlogger = logging.getLogger('helpdesk')\n\n\ndef send_templated_mail(template_name,\n context,\n recipients,\n ... | [
{
"content": "import os\nimport mimetypes\nimport logging\nfrom smtplib import SMTPException\n\nfrom django.utils.safestring import mark_safe\n\nlogger = logging.getLogger('helpdesk')\n\n\ndef send_templated_mail(template_name,\n context,\n recipients,\n ... | diff --git a/helpdesk/templated_email.py b/helpdesk/templated_email.py
index ae64aae59..720e94453 100644
--- a/helpdesk/templated_email.py
+++ b/helpdesk/templated_email.py
@@ -100,13 +100,10 @@ def send_templated_mail(template_name,
if files:
for filename, filefield in files:
- mime = mimety... |
django-helpdesk__django-helpdesk-392 | User setting login_veiw_ticketlist always returns False
Issue in views/public.py. Call to getattr() doesn't work, since usersettings.settings are stored in a dict. Use 'usersettings.settings.get('login_view_ticketlist', False)' instead. #
| [
{
"content": "\"\"\"\ndjango-helpdesk - A Django powered ticket tracker for small enterprise.\n\n(c) Copyright 2008 Jutda. All Rights Reserved. See LICENSE for details.\n\nviews/public.py - All public facing views, eg non-staff (no authentication\n required) views.\n\"\"\"\n\nfrom django.core.u... | [
{
"content": "\"\"\"\ndjango-helpdesk - A Django powered ticket tracker for small enterprise.\n\n(c) Copyright 2008 Jutda. All Rights Reserved. See LICENSE for details.\n\nviews/public.py - All public facing views, eg non-staff (no authentication\n required) views.\n\"\"\"\n\nfrom django.core.u... | diff --git a/helpdesk/views/public.py b/helpdesk/views/public.py
index b020cfb22..0d9524858 100644
--- a/helpdesk/views/public.py
+++ b/helpdesk/views/public.py
@@ -25,7 +25,7 @@ def homepage(request):
if (request.user.is_staff or (request.user.is_authenticated() and helpdesk_settings.HELPDESK_ALLOW_NON_STAFF_TI... |
spack__spack-12009 | Installation issue: py-jsonchema (No checksum provided for @2.6.0 requested by nrm)
The nrm package specifically requests py-jsonschema@2.6.0. Attempting to install this package results in the following error:
==> Warning: There is no checksum on file to fetch py-jsonschema@2.6.0 safely.
==> Error: Will not fetch p... | [
{
"content": "# Copyright 2013-2019 Lawrence Livermore National Security, LLC and other\n# Spack Project Developers. See the top-level COPYRIGHT file for details.\n#\n# SPDX-License-Identifier: (Apache-2.0 OR MIT)\n\nfrom spack import *\n\n\nclass PyJsonschema(PythonPackage):\n \"\"\"Jsonschema: An(other) im... | [
{
"content": "# Copyright 2013-2019 Lawrence Livermore National Security, LLC and other\n# Spack Project Developers. See the top-level COPYRIGHT file for details.\n#\n# SPDX-License-Identifier: (Apache-2.0 OR MIT)\n\nfrom spack import *\n\n\nclass PyJsonschema(PythonPackage):\n \"\"\"Jsonschema: An(other) im... | diff --git a/var/spack/repos/builtin/packages/py-jsonschema/package.py b/var/spack/repos/builtin/packages/py-jsonschema/package.py
index f1752e578879ed..90a0079e4eaf88 100644
--- a/var/spack/repos/builtin/packages/py-jsonschema/package.py
+++ b/var/spack/repos/builtin/packages/py-jsonschema/package.py
@@ -10,8 +10,9 @@... |
boto__boto-2165 | Cannot remove cookie stickiness policy from ELB listener
I can set policies no problem, but when I try to remove them by using a list of length 0 (`elb.set_policies_of_listener(80, [])`) I get the following error:
ValidationError: 1 validation error detected: Value null at 'policyNames' failed
to satisfy constraint: ... | [
{
"content": "# Copyright (c) 2006-2012 Mitch Garnaat http://garnaat.org/\n# Copyright (c) 2012 Amazon.com, Inc. or its affiliates.\n# All Rights Reserved\n#\n# Permission is hereby granted, free of charge, to any person obtaining a\n# copy of this software and associated documentation files (the\n# \"Software\... | [
{
"content": "# Copyright (c) 2006-2012 Mitch Garnaat http://garnaat.org/\n# Copyright (c) 2012 Amazon.com, Inc. or its affiliates.\n# All Rights Reserved\n#\n# Permission is hereby granted, free of charge, to any person obtaining a\n# copy of this software and associated documentation files (the\n# \"Software\... | diff --git a/boto/ec2/elb/__init__.py b/boto/ec2/elb/__init__.py
index d308c72639..ad8695ddd7 100644
--- a/boto/ec2/elb/__init__.py
+++ b/boto/ec2/elb/__init__.py
@@ -635,7 +635,10 @@ def set_lb_policies_of_listener(self, lb_name, lb_port, policies):
"""
params = {'LoadBalancerName': lb_name,
... |
dask__distributed-6434 | `test_ucx_unreachable` failed on gpuCI
We got a gpuCI failure on https://github.com/dask/distributed/pull/6423. I'm pretty convinced this is unrelated
https://gpuci.gpuopenanalytics.com/job/dask/job/distributed/job/prb/job/distributed-prb/3200/CUDA_VER=11.5,LINUX_VER=ubuntu18.04,PYTHON_VER=3.9,RAPIDS_VER=22.06/testR... | [
{
"content": "\"\"\"\n:ref:`UCX`_ based communications for distributed.\n\nSee :ref:`communications` for more.\n\n.. _UCX: https://github.com/openucx/ucx\n\"\"\"\nimport functools\nimport logging\nimport os\nimport struct\nimport warnings\nimport weakref\nfrom typing import TYPE_CHECKING\n\nimport dask\nfrom da... | [
{
"content": "\"\"\"\n:ref:`UCX`_ based communications for distributed.\n\nSee :ref:`communications` for more.\n\n.. _UCX: https://github.com/openucx/ucx\n\"\"\"\nimport functools\nimport logging\nimport os\nimport struct\nimport warnings\nimport weakref\nfrom typing import TYPE_CHECKING\n\nimport dask\nfrom da... | diff --git a/distributed/comm/tests/test_comms.py b/distributed/comm/tests/test_comms.py
index db57bc579e6..fae1e5b6d23 100644
--- a/distributed/comm/tests/test_comms.py
+++ b/distributed/comm/tests/test_comms.py
@@ -563,7 +563,7 @@ async def client_communicate(key, delay=0):
@pytest.mark.gpu
@gen_test()
-async def... |
Lightning-Universe__lightning-flash-493 | Serve sanity check never called with PL master
## 🐛 Bug
`LightningModule.run_sanity_check` has been renamed to `_run_sanity_check`
| [
{
"content": "# Copyright The PyTorch Lightning 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 required ... | [
{
"content": "# Copyright The PyTorch Lightning 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 required ... | diff --git a/CHANGELOG.md b/CHANGELOG.md
index 7e78d1c66c..db0dc3f7a5 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -18,6 +18,9 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/).
### Fixed
+- Fixed a bug where serve sanity checking would not be triggered using the latest PyTorchLi... |
Mailu__Mailu-1184 | Mailu 1.7 : Issue when moving mail to the Junk folder
When I move a mail to the Junk Folder, i see the following in the logs:
imap_1 | Sep 22 16:51:26 imap: Error: cannot stat file mailu
imap_1 | Sep 22 16:51:26 imap: Error: cannot stat file mailu
imap_1 | Sep 22 16:51:26 imap: Error: tee: /dev/fd/... | [
{
"content": "#!/usr/bin/python3\n\nimport os\nimport glob\nimport multiprocessing\nimport logging as log\nimport sys\n\nfrom podop import run_server\nfrom socrate import system, conf\n\nlog.basicConfig(stream=sys.stderr, level=os.environ.get(\"LOG_LEVEL\", \"WARNING\"))\n\ndef start_podop():\n os.setuid(8... | [
{
"content": "#!/usr/bin/python3\n\nimport os\nimport glob\nimport multiprocessing\nimport logging as log\nimport sys\n\nfrom podop import run_server\nfrom socrate import system, conf\n\nlog.basicConfig(stream=sys.stderr, level=os.environ.get(\"LOG_LEVEL\", \"WARNING\"))\n\ndef start_podop():\n os.setuid(8... | diff --git a/core/dovecot/conf/bin/ham b/core/dovecot/conf/bin/ham
deleted file mode 100755
index becc304dd..000000000
--- a/core/dovecot/conf/bin/ham
+++ /dev/null
@@ -1,4 +0,0 @@
-#!/bin/bash
-
-tee >(rspamc -h ${ANTISPAM_ADDRESS} -P mailu learn_ham /dev/stdin) \
- | rspamc -h ${ANTISPAM_ADDRESS} -P mailu -f 13 fu... |
saleor__saleor-5311 | Broken multiple interface notation in schema
### What I'm trying to achieve
To use Apollo tooling to generate TS types for the application queries. However, it fails because Saleor's schema uses comma as a separator instead of ampersand. More: https://github.com/apollographql/apollo-tooling/issues/434
### Steps to... | [
{
"content": "from django.core.management.base import BaseCommand\nfrom graphql import print_schema\n\nfrom ...api import schema\n\n\nclass Command(BaseCommand):\n help = \"Writes SDL for GraphQL API schema to stdout\"\n\n def handle(self, *args, **options):\n self.stdout.write(print_schema(schema)... | [
{
"content": "from django.core.management.base import BaseCommand\nfrom graphql import print_schema\n\nfrom ...api import schema\n\n\nclass Command(BaseCommand):\n help = \"Writes SDL for GraphQL API schema to stdout\"\n\n def handle(self, *args, **options):\n \"\"\"Support multiple interface notat... | diff --git a/saleor/graphql/management/commands/get_graphql_schema.py b/saleor/graphql/management/commands/get_graphql_schema.py
index d230756e212..6e5812f4ae8 100644
--- a/saleor/graphql/management/commands/get_graphql_schema.py
+++ b/saleor/graphql/management/commands/get_graphql_schema.py
@@ -8,4 +8,14 @@ class Comm... |
encode__django-rest-framework-1280 | Stop breaking non-model usage in serializer
45d4622f090f8d81a04b4d3e888017419676bbc0 added a weird workaround for a problem that has nothing to do with the `BaseSerializer` but is tailor made for the Django ORM.
I'm trying to use DRF with elasticutils' search querysets and been wondering why the serializer always retu... | [
{
"content": "\"\"\"\nSerializers and ModelSerializers are similar to Forms and ModelForms.\nUnlike forms, they are not constrained to dealing with HTML output, and\nform encoded input.\n\nSerialization in REST framework is a two-phase process:\n\n1. Serializers marshal between complex types like model instance... | [
{
"content": "\"\"\"\nSerializers and ModelSerializers are similar to Forms and ModelForms.\nUnlike forms, they are not constrained to dealing with HTML output, and\nform encoded input.\n\nSerialization in REST framework is a two-phase process:\n\n1. Serializers marshal between complex types like model instance... | diff --git a/docs/topics/release-notes.md b/docs/topics/release-notes.md
index d3f85e6ee8..1ddd835192 100644
--- a/docs/topics/release-notes.md
+++ b/docs/topics/release-notes.md
@@ -43,6 +43,7 @@ You can determine your currently installed version using `pip freeze`:
### Master
* JSON renderer now deals with object... |
strawberry-graphql__strawberry-3478 | Document all the scalars we have
One that's definitely missing is the JSON one, or at least it doesn't show up on the search (we do get an example of creating a custom JSON scalar though, which is misleading)
<!-- POLAR PLEDGE BADGE START -->
## Upvote & Fund
- We're using [Polar.sh](https://polar.sh/strawberry-graph... | [
{
"content": "from __future__ import annotations\n\nimport base64\nfrom typing import TYPE_CHECKING, Any, Dict, NewType, Union\n\nfrom .custom_scalar import scalar\n\nif TYPE_CHECKING:\n from .custom_scalar import ScalarDefinition, ScalarWrapper\n\n\nID = NewType(\"ID\", str)\n\nJSON = scalar(\n NewType(\... | [
{
"content": "from __future__ import annotations\n\nimport base64\nfrom typing import TYPE_CHECKING, Any, Dict, NewType, Union\n\nfrom .custom_scalar import scalar\n\nif TYPE_CHECKING:\n from .custom_scalar import ScalarDefinition, ScalarWrapper\n\n\nID = NewType(\"ID\", str)\n\nJSON = scalar(\n NewType(\... | diff --git a/CHANGELOG.md b/CHANGELOG.md
index b14803468a..03c16c2423 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -4641,11 +4641,11 @@ will print the following SDL:
directive @specifiedBy(name: String!) on SCALAR
"""
-The `JSON` scalar type represents JSON values as specified by [ECMA-404](http://www.ecma-inter... |
django-import-export__django-import-export-1836 | Breaking change due to _check_import_id_fields
**Describe the bug**
This is a breaking change in 4.0 vs 3.x.
In my resource, I've declared a `before_import_row()` to add another column 'Object' to the row, which is used as an identifier.
```
object = resources.Field(column_name="Object", attribute="object")
... | [
{
"content": "import functools\nimport inspect\nimport logging\nimport traceback\nfrom collections import OrderedDict\nfrom copy import deepcopy\nfrom html import escape\nfrom warnings import warn\n\nimport tablib\nfrom diff_match_patch import diff_match_patch\nfrom django.conf import settings\nfrom django.core... | [
{
"content": "import functools\nimport inspect\nimport logging\nimport traceback\nfrom collections import OrderedDict\nfrom copy import deepcopy\nfrom html import escape\nfrom warnings import warn\n\nimport tablib\nfrom diff_match_patch import diff_match_patch\nfrom django.conf import settings\nfrom django.core... | diff --git a/docs/advanced_usage.rst b/docs/advanced_usage.rst
index 536d8adf5..2c224c501 100644
--- a/docs/advanced_usage.rst
+++ b/docs/advanced_usage.rst
@@ -577,6 +577,48 @@ For example, you can use the 'isbn' number instead of 'id' to uniquely identify
field(s) select more than one row, then a ``MultipleObjec... |
Mailu__Mailu-1183 | Mailu 1.7 : Issue when moving mail to the Junk folder
When I move a mail to the Junk Folder, i see the following in the logs:
imap_1 | Sep 22 16:51:26 imap: Error: cannot stat file mailu
imap_1 | Sep 22 16:51:26 imap: Error: cannot stat file mailu
imap_1 | Sep 22 16:51:26 imap: Error: tee: /dev/fd/... | [
{
"content": "#!/usr/bin/python3\n\nimport os\nimport glob\nimport multiprocessing\nimport logging as log\nimport sys\n\nfrom podop import run_server\nfrom socrate import system, conf\n\nlog.basicConfig(stream=sys.stderr, level=os.environ.get(\"LOG_LEVEL\", \"WARNING\"))\n\ndef start_podop():\n os.setuid(8... | [
{
"content": "#!/usr/bin/python3\n\nimport os\nimport glob\nimport multiprocessing\nimport logging as log\nimport sys\n\nfrom podop import run_server\nfrom socrate import system, conf\n\nlog.basicConfig(stream=sys.stderr, level=os.environ.get(\"LOG_LEVEL\", \"WARNING\"))\n\ndef start_podop():\n os.setuid(8... | diff --git a/core/dovecot/conf/bin/ham b/core/dovecot/conf/bin/ham
deleted file mode 100755
index becc304dd..000000000
--- a/core/dovecot/conf/bin/ham
+++ /dev/null
@@ -1,4 +0,0 @@
-#!/bin/bash
-
-tee >(rspamc -h ${ANTISPAM_ADDRESS} -P mailu learn_ham /dev/stdin) \
- | rspamc -h ${ANTISPAM_ADDRESS} -P mailu -f 13 fu... |
mozilla__telemetry-analysis-service-338 | Configure readbeat.scheduler logger to use mozlog
There is a logger in https://github.com/sibson/redbeat/blob/efc9491b2ffc6d9d544693143b42d771ec60f9c2/redbeat/schedulers.py#L61 that needs to be checked for using mozlog to show up in Kibana.
| [
{
"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/.\n\"\"\"\nDjango settings for atmo project.\n\nFor more information on this file, see\nhttps://doc... | [
{
"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/.\n\"\"\"\nDjango settings for atmo project.\n\nFor more information on this file, see\nhttps://doc... | diff --git a/atmo/settings.py b/atmo/settings.py
index 91f5c5c4..425f5e1d 100644
--- a/atmo/settings.py
+++ b/atmo/settings.py
@@ -475,9 +475,14 @@ def LOGGING(self):
'handlers': ['console'],
'propagate': False,
},
- 'request.summary': {
+ ... |
apluslms__a-plus-1304 | Optimize the very inefficient database queries in the deviation list view
#1122 presented performance issues in the deviations list page. This new issue focuses on specific performance issues.
Using the Django Debug toolbar, we have noticed that the database queries in the deviations list page include some very inef... | [
{
"content": "from itertools import groupby\nfrom typing import Any, Callable, Dict, Iterable, List, Optional, Tuple, Type\n\nfrom django.db import models\nfrom django.http import HttpRequest, HttpResponse\nfrom django.contrib import messages\nfrom django import forms\nfrom django.utils.text import format_lazy\... | [
{
"content": "from itertools import groupby\nfrom typing import Any, Callable, Dict, Iterable, List, Optional, Tuple, Type\n\nfrom django.db import models\nfrom django.http import HttpRequest, HttpResponse\nfrom django.contrib import messages\nfrom django import forms\nfrom django.utils.text import format_lazy\... | diff --git a/deviations/viewbase.py b/deviations/viewbase.py
index 5e9e4b711..e649fd346 100644
--- a/deviations/viewbase.py
+++ b/deviations/viewbase.py
@@ -257,6 +257,12 @@ def get_deviation_groups(
'submitter', 'submitter__user',
'granter', 'granter__user',
'exercise', 'exercise... |
acl-org__acl-anthology-1025 | Name parser
At ingestion time, we are often given data that is not split into BibTeX's "surname, given name" format. We therefore split it ourselves, heuristically, which often fails. Python has a [name parser](https://pypi.org/project/nameparser/) module, but it doesn't work on all Anthology names, either, e.g.,:
-... | [
{
"content": "#!/usr/bin/env python3\n# Daniel Gildea, 2020\n\n\"\"\"Usage: likely_name_split.py [--importdir=DIR]\n\nCounts first and last names in anthology.\nPredicts best split into first and last.\nChecks whether current names match our predictions.\n\nOptions:\n --importdir=DIR Directory to impo... | [
{
"content": "#!/usr/bin/env python3\n# Daniel Gildea, 2020\n\n\"\"\"Usage: likely_name_split.py [--importdir=DIR]\n\nCounts first and last names in anthology.\nPredicts best split into first and last.\nChecks whether current names match our predictions.\n\nOptions:\n --importdir=DIR Directory to impo... | diff --git a/bin/likely_name_split.py b/bin/likely_name_split.py
index 5c5f326362..c952ab7d70 100755
--- a/bin/likely_name_split.py
+++ b/bin/likely_name_split.py
@@ -57,8 +57,9 @@ def count_names(self, anthology):
# returns ("Lopez Gonzalez", "Maria Victoria")
# uses counts of words in first and last names i... |
scikit-hep__pyhf-1942 | Use string form for type checking until Python 3.7 dropped
What the if here? The string form is fine until you drop Pythons that don’t support it.
_Originally posted by @henryiii in https://github.com/scikit-hep/pyhf/pull/1909#discussion_r944456765_
This was in reference to
```python
if T.TYPE_CHECKING:
... | [
{
"content": "import os\nimport sys\nfrom typing import TYPE_CHECKING, MutableSequence, Sequence, Union\n\nif sys.version_info >= (3, 8):\n from typing import Literal, TypedDict\nelse:\n from typing_extensions import Literal, TypedDict\n\n__all__ = (\n \"PathOrStr\",\n \"ParameterBase\",\n \"Para... | [
{
"content": "import os\nimport sys\nfrom typing import MutableSequence, Sequence, Union\n\nif sys.version_info >= (3, 8):\n from typing import Literal, TypedDict\nelse:\n from typing_extensions import Literal, TypedDict\n\n__all__ = (\n \"PathOrStr\",\n \"ParameterBase\",\n \"Parameter\",\n \... | diff --git a/.coveragerc b/.coveragerc
deleted file mode 100644
index 0856c037f2..0000000000
--- a/.coveragerc
+++ /dev/null
@@ -1,3 +0,0 @@
-[report]
-exclude_lines =
- if TYPE_CHECKING:
diff --git a/src/pyhf/typing.py b/src/pyhf/typing.py
index bdfa44f85c..50a6237199 100644
--- a/src/pyhf/typing.py
+++ b/src/pyhf/... |
getpelican__pelican-1002 | "'dict_keys' object does not support indexing" in Python 3 using sourcecode directive
When I include a code-block with an option, like this:
```
.. sourcecode:: python
:linenos:
...
```
a WARNING appears and the corresponding file is not processed:
```
WARNING: Could not process /home/juanlu/Development/Pytho... | [
{
"content": "# -*- coding: utf-8 -*-\nfrom __future__ import unicode_literals, print_function\n\nfrom docutils import nodes, utils\nfrom docutils.parsers.rst import directives, roles, Directive\nfrom pygments.formatters import HtmlFormatter\nfrom pygments import highlight\nfrom pygments.lexers import get_lexer... | [
{
"content": "# -*- coding: utf-8 -*-\nfrom __future__ import unicode_literals, print_function\n\nfrom docutils import nodes, utils\nfrom docutils.parsers.rst import directives, roles, Directive\nfrom pygments.formatters import HtmlFormatter\nfrom pygments import highlight\nfrom pygments.lexers import get_lexer... | diff --git a/pelican/rstdirectives.py b/pelican/rstdirectives.py
index fb4a6c93a..1fdd09d63 100644
--- a/pelican/rstdirectives.py
+++ b/pelican/rstdirectives.py
@@ -32,7 +32,7 @@ def run(self):
# no lexer found - use the text one instead of an exception
lexer = TextLexer()
# take an a... |
yt-project__yt-4036 | UX: unclear error message for off-axis operations with SPH data
### Bug report
**Bug summary**
We got two users independently reporting the same error message as unclear on Slack within hours.
They are both working with SPH data and trying to create off-axis `LinePlot` and `SlicePlot` respectively.
The problem ... | [
{
"content": "# We don't need to import 'exceptions'\nimport os.path\n\nfrom unyt.exceptions import UnitOperationError\n\n\nclass YTException(Exception):\n def __init__(self, message=None, ds=None):\n Exception.__init__(self, message)\n self.ds = ds\n\n\n# Data access exceptions:\n\n\nclass YTU... | [
{
"content": "# We don't need to import 'exceptions'\nimport os.path\n\nfrom unyt.exceptions import UnitOperationError\n\n\nclass YTException(Exception):\n def __init__(self, message=None, ds=None):\n Exception.__init__(self, message)\n self.ds = ds\n\n\n# Data access exceptions:\n\n\nclass YTU... | diff --git a/doc/source/cookbook/simple_plots.rst b/doc/source/cookbook/simple_plots.rst
index 5da1c2ea0f3..9a29536a983 100644
--- a/doc/source/cookbook/simple_plots.rst
+++ b/doc/source/cookbook/simple_plots.rst
@@ -59,6 +59,9 @@ See :ref:`manual-line-plots` for more information.
.. yt_cookbook:: simple_1d_line_plo... |
scikit-hep__awkward-1401 | `with_name` fails for `ak._v2.Record`
### Version of Awkward Array
278dccee
### Description and code to reproduce
```python
import awkward._v2 as ak
ak.Record({'x': 10.0}, with_name="X")
```
| [
{
"content": "# BSD 3-Clause License; see https://github.com/scikit-hep/awkward-1.0/blob/main/LICENSE\n\nimport copy\nfrom collections.abc import Iterable\n\nimport awkward as ak\nfrom awkward._v2.contents.content import Content\n\nnp = ak.nplike.NumpyMetadata.instance()\n\n\nclass Record:\n def __init__(sel... | [
{
"content": "# BSD 3-Clause License; see https://github.com/scikit-hep/awkward-1.0/blob/main/LICENSE\n\nimport copy\nfrom collections.abc import Iterable\n\nimport awkward as ak\nfrom awkward._v2.contents.content import Content\n\nnp = ak.nplike.NumpyMetadata.instance()\n\n\nclass Record:\n def __init__(sel... | diff --git a/src/awkward/_v2/record.py b/src/awkward/_v2/record.py
index 3b442c13f8..f172dfd654 100644
--- a/src/awkward/_v2/record.py
+++ b/src/awkward/_v2/record.py
@@ -193,3 +193,29 @@ def to_list(self, behavior=None):
def deep_copy(self):
return Record(self._array.deep_copy(), copy.deepcopy(self._at... |
django-wiki__django-wiki-912 | [Bug] NotImplemented is not an exception
https://github.com/django-wiki/django-wiki/blob/a144a3110cc688d796895aa1caddc4db1a4b62c6/src/wiki/plugins/images/models.py#L122
I think this is a bug as 'NotImplemented" is not an exception but a singleton. Delete lines 120-124?
[Docs](https://docs.python.org/3.6/library/c... | [
{
"content": "import os.path\n\nfrom django.conf import settings as django_settings\nfrom django.db import models\nfrom django.db.models import signals\nfrom django.utils.translation import gettext, gettext_lazy as _\nfrom wiki.models.pluginbase import RevisionPlugin, RevisionPluginRevision\n\nfrom . import set... | [
{
"content": "import os.path\n\nfrom django.conf import settings as django_settings\nfrom django.db import models\nfrom django.db.models import signals\nfrom django.utils.translation import gettext, gettext_lazy as _\nfrom wiki.models.pluginbase import RevisionPlugin, RevisionPluginRevision\n\nfrom . import set... | diff --git a/src/wiki/plugins/images/models.py b/src/wiki/plugins/images/models.py
index bf0cd9f1c..f25ca1ed9 100644
--- a/src/wiki/plugins/images/models.py
+++ b/src/wiki/plugins/images/models.py
@@ -110,16 +110,10 @@ def on_image_revision_delete(instance, *args, **kwargs):
# Remove image file
instance.ima... |
sunpy__sunpy-4596 | Rethinking and rewriting sunpy.self_test
We are currently using astropy's test runner for `sunpy.self_test` this was really designed for setup.py and is therefore very full of features which are probably not needed for self_test.
Before we (I) go deleting swathes of code as I love to do. What do we want to achieve wit... | [
{
"content": "\"\"\"\nSunPy\n=====\n\nAn open-source Python library for Solar Physics data analysis.\n\n* Homepage: https://sunpy.org\n* Documentation: https://docs.sunpy.org/en/stable/\n\"\"\"\nimport os\nimport sys\nimport logging\n\nfrom sunpy.tests.runner import SunPyTestRunner\nfrom sunpy.util import syste... | [
{
"content": "\"\"\"\nSunPy\n=====\n\nAn open-source Python library for Solar Physics data analysis.\n\n* Homepage: https://sunpy.org\n* Documentation: https://docs.sunpy.org/en/stable/\n\"\"\"\nimport os\nimport sys\nimport logging\n\nfrom sunpy.tests.self_test import self_test\nfrom sunpy.util import system_i... | diff --git a/CHANGELOG.rst b/CHANGELOG.rst
index 5fe479e2c7d..d07c97f8058 100644
--- a/CHANGELOG.rst
+++ b/CHANGELOG.rst
@@ -985,7 +985,7 @@ Bug Fixes
- Running the figure tests with ``setup.py test`` now saves the figures and the hashes to the same directory as setup.py. (`#2658 <https://github.com/sunpy/sunpy/pull/2... |
pwr-Solaar__Solaar-2140 | MX Master 3S For Mac shown with a missing name in the GUI device list
**Information**
<!-- Make sure that your issue is not one of the known issues in the Solaar documentation at https://pwr-solaar.github.io/Solaar/ -->
<!-- Do not bother opening an issue for a version older than 1.1.8. Upgrade to the latest version... | [
{
"content": "# -*- python-mode -*-\n\n## Copyright (C) 2012-2013 Daniel Pavel\n##\n## This program is free software; you can redistribute it and/or modify\n## it under the terms of the GNU General Public License as published by\n## the Free Software Foundation; either version 2 of the License, or\n## (at your... | [
{
"content": "# -*- python-mode -*-\n\n## Copyright (C) 2012-2013 Daniel Pavel\n##\n## This program is free software; you can redistribute it and/or modify\n## it under the terms of the GNU General Public License as published by\n## the Free Software Foundation; either version 2 of the License, or\n## (at your... | diff --git a/lib/solaar/ui/window.py b/lib/solaar/ui/window.py
index 1772a9654e..63682f0b24 100644
--- a/lib/solaar/ui/window.py
+++ b/lib/solaar/ui/window.py
@@ -915,6 +915,8 @@ def update_device(device, item, selected_device_id, need_popup, full=False):
icon_name = _icons.battery(battery_level, charging)
... |
kornia__kornia-2458 | Add docs for MobileSAM
## 📚 Documentation
<!-- A clear and concise description of what content in https://kornia.readthedocs.io is an issue. If this has to do with the general https://kornia.org website, please file an issue at https://github.com/kornia/kornia.github.io/issues/new/choose instead. If this has to do ... | [
{
"content": "\"\"\"Based from the original code from Meta Platforms, Inc. and affiliates.\n\nhttps://github.com/facebookresearch/segment-\nanything/blob/3518c86b78b3bc9cf4fbe3d18e682fad1c79dc51/segment_anything/build_sam.py\n\nhttps://github.com/facebookresearch/segment-\nanything/blob/3518c86b78b3bc9cf4fbe3d1... | [
{
"content": "\"\"\"Based from the original code from Meta Platforms, Inc. and affiliates.\n\nhttps://github.com/facebookresearch/segment-\nanything/blob/3518c86b78b3bc9cf4fbe3d18e682fad1c79dc51/segment_anything/build_sam.py\n\nhttps://github.com/facebookresearch/segment-\nanything/blob/3518c86b78b3bc9cf4fbe3d1... | diff --git a/docs/source/contrib.rst b/docs/source/contrib.rst
index 109d7bcba7..12d58bafa9 100644
--- a/docs/source/contrib.rst
+++ b/docs/source/contrib.rst
@@ -96,6 +96,7 @@ Segment Anything (SAM)
.. autoclass:: kornia.contrib.models.sam.SamModelType
:members:
:undoc-members:
+ :member-order: bysource
... |
sanic-org__sanic-862 | [Errno 13] Permission denied: '/access.log' with disabled debug & logging?
With:
```text
app.run(host=API_HOST, port=PORT, sock=None, debug=False, workers=API_WORKERS, log_config=None)
```
```text
app = Sanic(__name__)
File "/usr/local/anaconda/envs/proj/lib/python3.6/site-packages/sanic/app.py", line 33, i... | [
{
"content": "import logging\nimport logging.config\nimport re\nimport warnings\nfrom asyncio import get_event_loop, ensure_future, CancelledError\nfrom collections import deque, defaultdict\nfrom functools import partial\nfrom inspect import isawaitable, stack, getmodulename\nfrom traceback import format_exc\n... | [
{
"content": "import logging\nimport logging.config\nimport re\nimport warnings\nfrom asyncio import get_event_loop, ensure_future, CancelledError\nfrom collections import deque, defaultdict\nfrom functools import partial\nfrom inspect import isawaitable, stack, getmodulename\nfrom traceback import format_exc\n... | diff --git a/sanic/app.py b/sanic/app.py
index f1e8be7e22..f0ccad865c 100644
--- a/sanic/app.py
+++ b/sanic/app.py
@@ -33,9 +33,7 @@ def __init__(self, name=None, router=None, error_handler=None,
logging.config.dictConfig(log_config)
# Only set up a default log handler if the
# end-user a... |
boto__boto-3145 | Wrong documentation for publish method in SNS connection
The method says `Get properties of a Topic`.
| [
{
"content": "# Copyright (c) 2010-2012 Mitch Garnaat http://garnaat.org/\n# Copyright (c) 2012 Amazon.com, Inc. or its affiliates. All Rights Reserved\n#\n# Permission is hereby granted, free of charge, to any person obtaining a\n# copy of this software and associated documentation files (the\n# \"Software\")... | [
{
"content": "# Copyright (c) 2010-2012 Mitch Garnaat http://garnaat.org/\n# Copyright (c) 2012 Amazon.com, Inc. or its affiliates. All Rights Reserved\n#\n# Permission is hereby granted, free of charge, to any person obtaining a\n# copy of this software and associated documentation files (the\n# \"Software\")... | diff --git a/boto/sns/connection.py b/boto/sns/connection.py
index 5a6da205f4..8ba7d48183 100644
--- a/boto/sns/connection.py
+++ b/boto/sns/connection.py
@@ -216,10 +216,10 @@ def delete_topic(self, topic):
def publish(self, topic=None, message=None, subject=None, target_arn=None,
message_structu... |
getsentry__sentry-python-2239 | Add Sampling Decision to Trace Envelope Header
## Description
See project description: https://github.com/getsentry/team-sdks/issues/8
| [
{
"content": "import re\nimport contextlib\n\nimport sentry_sdk\nfrom sentry_sdk.consts import OP\nfrom sentry_sdk.utils import (\n capture_internal_exceptions,\n Dsn,\n match_regex_list,\n to_string,\n)\nfrom sentry_sdk._compat import PY2, iteritems\nfrom sentry_sdk._types import TYPE_CHECKING\n\ni... | [
{
"content": "import re\nimport contextlib\n\nimport sentry_sdk\nfrom sentry_sdk.consts import OP\nfrom sentry_sdk.utils import (\n capture_internal_exceptions,\n Dsn,\n match_regex_list,\n to_string,\n)\nfrom sentry_sdk._compat import PY2, iteritems\nfrom sentry_sdk._types import TYPE_CHECKING\n\ni... | diff --git a/sentry_sdk/tracing_utils.py b/sentry_sdk/tracing_utils.py
index 762dca1723..eb0d0e7878 100644
--- a/sentry_sdk/tracing_utils.py
+++ b/sentry_sdk/tracing_utils.py
@@ -330,6 +330,9 @@ def populate_from_transaction(cls, transaction):
if transaction.sample_rate is not None:
sentry_items["... |
yt-project__yt-4694 | DEP: (yt 4.3) set upper limit on runtime requirement on numpy (<2.0)
This issue is a reminder that, if yt 4.3.0 is released, as scheduled (sometime about end of September), *before* numpy 2.0 (currently aimed at December 2023), we should update the runtime requirement on the backport branch (basically replaying https:/... | [
{
"content": "#\n# yt documentation build configuration file, created by\n# sphinx-quickstart on Tue Jan 11 09:46:53 2011.\n#\n# This file is execfile()d with the current directory set to its containing dir.\n#\n# Note that not all possible configuration values are present in this\n# autogenerated file.\n#\n# A... | [
{
"content": "#\n# yt documentation build configuration file, created by\n# sphinx-quickstart on Tue Jan 11 09:46:53 2011.\n#\n# This file is execfile()d with the current directory set to its containing dir.\n#\n# Note that not all possible configuration values are present in this\n# autogenerated file.\n#\n# A... | diff --git a/doc/source/conf.py b/doc/source/conf.py
index 934cdb0b789..5f06bd51eaa 100644
--- a/doc/source/conf.py
+++ b/doc/source/conf.py
@@ -70,7 +70,7 @@
# The short X.Y version.
version = "4.3"
# The full version, including alpha/beta/rc tags.
-release = "4.3-dev"
+release = "4.3.0"
# The language for conte... |
encode__django-rest-framework-5480 | Have `schemas.is_list_view` recognise `RetrieveAPIView` subclasses
If you create a `RetrieveAPIView` with a fixed URL (using `request.user` in `get_object()`, say) then `rest_framwork.schemas.is_list_view` will return `True` leasing to schemas with `list` as the key, where `retrieve` is desired.
It would be good if... | [
{
"content": "\"\"\"\nutils.py # Shared helper functions\n\nSee schemas.__init__.py for package overview.\n\"\"\"\n\n\ndef is_list_view(path, method, view):\n \"\"\"\n Return True if the given path/method appears to represent a list view.\n \"\"\"\n if hasattr(view, 'action'):\n # View... | [
{
"content": "\"\"\"\nutils.py # Shared helper functions\n\nSee schemas.__init__.py for package overview.\n\"\"\"\nfrom rest_framework.mixins import RetrieveModelMixin\n\n\ndef is_list_view(path, method, view):\n \"\"\"\n Return True if the given path/method appears to represent a list view.\n \... | diff --git a/rest_framework/schemas/utils.py b/rest_framework/schemas/utils.py
index 1542b6154b..76437a20a6 100644
--- a/rest_framework/schemas/utils.py
+++ b/rest_framework/schemas/utils.py
@@ -3,6 +3,7 @@
See schemas.__init__.py for package overview.
"""
+from rest_framework.mixins import RetrieveModelMixin
... |
iterative__dvc-4462 | experiments: show table includes all staged/stashed experiments instead of only the currently applicable ones
```
example-get-started git:executor-tree py:dvc ❯ dvc exp show --no-pager --include-params=featurize
┏━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┳━━━━━━━━━┳━━━━━━━━━━━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━━━━┓
┃ Experimen... | [
{
"content": "import logging\nimport re\nfrom collections import OrderedDict, defaultdict\nfrom datetime import datetime\n\nfrom dvc.repo import locked\nfrom dvc.repo.metrics.show import _collect_metrics, _read_metrics\nfrom dvc.repo.params.show import _collect_configs, _read_params\n\nlogger = logging.getLogge... | [
{
"content": "import logging\nimport re\nfrom collections import OrderedDict, defaultdict\nfrom datetime import datetime\n\nfrom dvc.repo import locked\nfrom dvc.repo.metrics.show import _collect_metrics, _read_metrics\nfrom dvc.repo.params.show import _collect_configs, _read_params\n\nlogger = logging.getLogge... | diff --git a/dvc/repo/experiments/show.py b/dvc/repo/experiments/show.py
index a52435f49e..36f82d2271 100644
--- a/dvc/repo/experiments/show.py
+++ b/dvc/repo/experiments/show.py
@@ -73,10 +73,11 @@ def show(
# collect queued (not yet reproduced) experiments
for stash_rev, (_, baseline_rev) in repo.experime... |
google__timesketch-1939 | json import timestamp error
**Describe the bug**
Importing json data into into a sketch with a different timestamp produces an error.
**To Reproduce**
Steps to reproduce the behavior:
1. import timestamp in iso format.
2. import timestamp in a different format
3. See import error.
**Expected behavior**
Dat... | [
{
"content": "# Copyright 2015 Google Inc. 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/LICENSE-2.0\n#\n# Unless... | [
{
"content": "# Copyright 2015 Google Inc. 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/LICENSE-2.0\n#\n# Unless... | diff --git a/timesketch/lib/utils.py b/timesketch/lib/utils.py
index 633093611b..14cc5fbcb8 100644
--- a/timesketch/lib/utils.py
+++ b/timesketch/lib/utils.py
@@ -258,7 +258,8 @@ def read_and_validate_jsonl(file_handle):
linedict['datetime'] = dt.isoformat()
if 'timestamp' not in ld_keys a... |
nipy__nipype-3007 | mne.WatershedBEM creates incorrect command line
### Summary
The mne.WatershedBEM interface `_cmd` do not correspond to the behavior of the stable release of mne [see documentation](https://martinos.org/mne/stable/generated/commands.html#create-bem-surfaces-using-the-watershed-algorithm-included-with-freesurfer)
[Th... | [
{
"content": "# -*- coding: utf-8 -*-\nfrom __future__ import (print_function, division, unicode_literals,\n absolute_import)\nfrom builtins import str, bytes\n\nimport os.path as op\nimport glob\n\nfrom ... import logging\nfrom ...utils.filemanip import simplify_list\nfrom ..base import ... | [
{
"content": "# -*- coding: utf-8 -*-\nfrom __future__ import (print_function, division, unicode_literals,\n absolute_import)\nfrom builtins import str, bytes\n\nimport os.path as op\nimport glob\n\nfrom ... import logging\nfrom ...utils.filemanip import simplify_list\nfrom ..base import ... | diff --git a/nipype/interfaces/mne/base.py b/nipype/interfaces/mne/base.py
index 7f53071372..b6c8320e7a 100644
--- a/nipype/interfaces/mne/base.py
+++ b/nipype/interfaces/mne/base.py
@@ -89,12 +89,12 @@ class WatershedBEM(FSCommand):
>>> bem.inputs.subject_id = 'subj1'
>>> bem.inputs.subjects_dir = '.'
>... |
jschneier__django-storages-1282 | ClientError (404) in S3Boto3Storage when calling write()
When `S3Boto3Storage` has gzip enabled, the following code generates an error when writing to an S3 key that does not already exist:
```
with my_storage.open('new_key.txt', 'wb') as f:
f.write(b'hello')
```
The stack trace indicates an error is happe... | [
{
"content": "import mimetypes\nimport os\nimport posixpath\nimport tempfile\nimport threading\nimport warnings\nfrom datetime import datetime\nfrom datetime import timedelta\nfrom tempfile import SpooledTemporaryFile\nfrom urllib.parse import parse_qsl\nfrom urllib.parse import urlencode\nfrom urllib.parse imp... | [
{
"content": "import mimetypes\nimport os\nimport posixpath\nimport tempfile\nimport threading\nimport warnings\nfrom datetime import datetime\nfrom datetime import timedelta\nfrom tempfile import SpooledTemporaryFile\nfrom urllib.parse import parse_qsl\nfrom urllib.parse import urlencode\nfrom urllib.parse imp... | diff --git a/storages/backends/s3boto3.py b/storages/backends/s3boto3.py
index 700af57da..d7a331b59 100644
--- a/storages/backends/s3boto3.py
+++ b/storages/backends/s3boto3.py
@@ -148,8 +148,8 @@ def _get_file(self):
self._is_dirty = False
self.obj.download_fileobj(self._file, Config=... |
zostera__django-bootstrap3-892 | Inline radio buttons and checkboxes lack spacing
Introduced in 23.3.
<img width="278" alt="Schermafbeelding 2023-06-28 om 05 40 33" src="https://github.com/zostera/django-bootstrap3/assets/82315/e3ce7026-8973-4adb-8f89-69f7aa188ebe">
| [
{
"content": "__version__ = \"23.3\"\n",
"path": "src/bootstrap3/__about__.py"
},
{
"content": "import re\n\nfrom django.forms import (\n BaseForm,\n BaseFormSet,\n BoundField,\n CheckboxInput,\n CheckboxSelectMultiple,\n ClearableFileInput,\n DateInput,\n EmailInput,\n Fi... | [
{
"content": "__version__ = \"23.4.dev0\"\n",
"path": "src/bootstrap3/__about__.py"
},
{
"content": "import re\n\nfrom django.forms import (\n BaseForm,\n BaseFormSet,\n BoundField,\n CheckboxInput,\n CheckboxSelectMultiple,\n ClearableFileInput,\n DateInput,\n EmailInput,\n ... | diff --git a/CHANGELOG.md b/CHANGELOG.md
index c872c641..b34a607c 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,5 +1,9 @@
# Changelog
+## 23.4 (in development)
+
+- Fix inline form spacing (#892).
+
## 23.3 (2023-06-27)
- Fix example (#886).
diff --git a/src/bootstrap3/__about__.py b/src/bootstrap3/__about_... |
interlegis__sapl-1815 | Protocolo de Documento ou Matéria em duplicidade
Informar ao usuário que está sendo feito o protocolo de matéria ou documento mais de uma vez; e, solicitar confirmação se é isso de fato que deseja efetivar.
| [
{
"content": "\nimport django_filters\nfrom crispy_forms.bootstrap import InlineRadios\nfrom crispy_forms.helper import FormHelper\nfrom crispy_forms.layout import HTML, Button, Fieldset, Layout\nfrom django import forms\nfrom django.core.exceptions import (MultipleObjectsReturned,\n ... | [
{
"content": "\nimport django_filters\nfrom crispy_forms.bootstrap import InlineRadios\nfrom crispy_forms.helper import FormHelper\nfrom crispy_forms.layout import HTML, Button, Fieldset, Layout\nfrom django import forms\nfrom django.core.exceptions import (MultipleObjectsReturned,\n ... | diff --git a/sapl/protocoloadm/forms.py b/sapl/protocoloadm/forms.py
index 37d888ec2..fb1ec1c4f 100644
--- a/sapl/protocoloadm/forms.py
+++ b/sapl/protocoloadm/forms.py
@@ -638,6 +638,14 @@ def clean(self):
numero_protocolo = self.data['numero_protocolo']
ano_protocolo = self.data['ano_protocolo']
+... |
spyder-ide__spyder-4208 | IPython console fails to start (Ipython >=6.x)
## Description of your problem
**What steps will reproduce the problem?**
1. install latest IPython (>=6.x)
2. install spyder (git master)
3. run spyder3
**What is the expected output? What do you see instead?**
The Ipython console should start but instead it... | [
{
"content": "# -*- coding: utf-8 -*-\n#\n# Copyright © Spyder Project Contributors\n# Licensed under the terms of the MIT License\n# (see spyder/__init__.py for details)\n\n\"\"\"\nShell Widget for the IPython Console\n\"\"\"\n\nimport ast\nimport uuid\n\nfrom qtpy.QtCore import Signal\nfrom qtpy.QtWidgets imp... | [
{
"content": "# -*- coding: utf-8 -*-\n#\n# Copyright © Spyder Project Contributors\n# Licensed under the terms of the MIT License\n# (see spyder/__init__.py for details)\n\n\"\"\"\nShell Widget for the IPython Console\n\"\"\"\n\nimport ast\nimport uuid\n\nfrom qtpy.QtCore import Signal\nfrom qtpy.QtWidgets imp... | diff --git a/spyder/widgets/ipythonconsole/shell.py b/spyder/widgets/ipythonconsole/shell.py
index e8d3bddca1f..0c36329a117 100644
--- a/spyder/widgets/ipythonconsole/shell.py
+++ b/spyder/widgets/ipythonconsole/shell.py
@@ -89,7 +89,10 @@ def set_cwd(self, dirname):
def long_banner(self):
"""Banner for I... |
aws-cloudformation__cfn-lint-908 | cfn-lint shows `W1020 Fn::Sub isn't needed` on Serverless LayerVersion property LayerName when a Variable is actually present
*cfn-lint version: 0.20.1*
cfn-lint shows `W1020 Fn::Sub isn't needed` on Serverless LayerVersion property LayerName when a Variable is actually present in the layerName String of the intrins... | [
{
"content": "\"\"\"\n Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved.\n\n Permission is hereby granted, free of charge, to any person obtaining a copy of this\n software and associated documentation files (the \"Software\"), to deal in the Software\n without restriction, including w... | [
{
"content": "\"\"\"\n Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved.\n\n Permission is hereby granted, free of charge, to any person obtaining a copy of this\n software and associated documentation files (the \"Software\"), to deal in the Software\n without restriction, including w... | diff --git a/setup.py b/setup.py
index a120af1f40..69147e0980 100644
--- a/setup.py
+++ b/setup.py
@@ -75,7 +75,7 @@ def get_version(filename):
install_requires=[
'pyyaml',
'six~=1.11',
- 'requests>=2.15.0',
+ 'requests>=2.15.0,<=2.21.0',
'aws-sam-translator>=1.10.0',
... |
netbox-community__netbox-13243 | Interface Bulk edit fails if vlan_group is set to null
### NetBox version
v3.5.6
### Python version
3.8
### Steps to Reproduce
1. Select multiple Interfaces and click on Edit below the list.
2. Activate `Set Null` for the `802.1Q Switching`>` VLAN group` option
3. Click on save
### Expected Behavior
There is n... | [
{
"content": "from django import forms\nfrom django.conf import settings\nfrom django.contrib.auth.models import User\nfrom django.utils.translation import gettext as _\nfrom timezone_field import TimeZoneFormField\n\nfrom dcim.choices import *\nfrom dcim.constants import *\nfrom dcim.models import *\nfrom extr... | [
{
"content": "from django import forms\nfrom django.conf import settings\nfrom django.contrib.auth.models import User\nfrom django.utils.translation import gettext as _\nfrom timezone_field import TimeZoneFormField\n\nfrom dcim.choices import *\nfrom dcim.constants import *\nfrom dcim.models import *\nfrom extr... | diff --git a/netbox/dcim/forms/bulk_edit.py b/netbox/dcim/forms/bulk_edit.py
index f1abdef1dee..a16de0b7537 100644
--- a/netbox/dcim/forms/bulk_edit.py
+++ b/netbox/dcim/forms/bulk_edit.py
@@ -1259,8 +1259,8 @@ class InterfaceBulkEditForm(
)
nullable_fields = (
'module', 'label', 'parent', 'bridge', ... |
sanic-org__sanic-2094 | New style streaming route handler improvements
**Is your feature request related to a problem? Please describe.**
The new streaming API allows streaming responses in the route handler without having to use a callback:
```python
@app.route("/")
async def test(request):
response = await request.respond(content... | [
{
"content": "from functools import partial\nfrom mimetypes import guess_type\nfrom os import path\nfrom pathlib import PurePath\nfrom typing import (\n Any,\n AnyStr,\n Callable,\n Coroutine,\n Dict,\n Iterator,\n Optional,\n Tuple,\n Union,\n)\nfrom urllib.parse import quote_plus\nf... | [
{
"content": "from functools import partial\nfrom mimetypes import guess_type\nfrom os import path\nfrom pathlib import PurePath\nfrom typing import (\n Any,\n AnyStr,\n Callable,\n Coroutine,\n Dict,\n Iterator,\n Optional,\n Tuple,\n Union,\n)\nfrom urllib.parse import quote_plus\nf... | diff --git a/sanic/response.py b/sanic/response.py
index a67d24fe72..9ab110f68c 100644
--- a/sanic/response.py
+++ b/sanic/response.py
@@ -203,6 +203,9 @@ async def send(self, *args, **kwargs):
self.streaming_fn = None
await super().send(*args, **kwargs)
+ async def eof(self):
+ raise ... |
Cog-Creators__Red-DiscordBot-2748 | [Streams] Rerun feature broke Mixer
# Command bugs
<!--
Did you find a bug with a command? Fill out the following:
-->
#### Command name
Mixer Stream Alerts
#### What cog is this command from?
streams
#### What were you expecting to happen?
Automated posting of live streamers
#### What actual... | [
{
"content": "import contextlib\n\nimport discord\nfrom redbot.core import Config, checks, commands\nfrom redbot.core.utils.chat_formatting import pagify\nfrom redbot.core.bot import Red\nfrom redbot.core.i18n import Translator, cog_i18n\nfrom .streamtypes import (\n Stream,\n TwitchStream,\n HitboxStr... | [
{
"content": "import contextlib\n\nimport discord\nfrom redbot.core import Config, checks, commands\nfrom redbot.core.utils.chat_formatting import pagify\nfrom redbot.core.bot import Red\nfrom redbot.core.i18n import Translator, cog_i18n\nfrom .streamtypes import (\n Stream,\n TwitchStream,\n HitboxStr... | diff --git a/redbot/cogs/streams/streams.py b/redbot/cogs/streams/streams.py
index cd7478f8802..83a67f4fc7c 100644
--- a/redbot/cogs/streams/streams.py
+++ b/redbot/cogs/streams/streams.py
@@ -547,7 +547,11 @@ async def check_streams(self):
for stream in self.streams:
with contextlib.suppress(Exce... |
TileDB-Inc__TileDB-Py-1868 | DataFrame `from_csv` doesn't support alternative s3-compatible backend
Whenever we use `.from_csv` for whatever backend (alternate s3 endpoint, minio), the custom configuration that works on usual `Array` operation doesn't work in this case.
https://github.com/TileDB-Inc/TileDB-Py/blob/24d5b3bb0869ef4d2f0d0c64c494be... | [
{
"content": "import copy\nimport json\nimport os\nimport warnings\nfrom dataclasses import dataclass\nfrom typing import Any, List, Optional, Union\n\nimport numpy as np\n\nimport tiledb\n\nfrom .datatypes import DataType\n\n\ndef check_dataframe_deps():\n pd_error = \"\"\"Pandas version >= 1.0 required for... | [
{
"content": "import copy\nimport json\nimport os\nimport warnings\nfrom dataclasses import dataclass\nfrom typing import Any, List, Optional, Union\n\nimport numpy as np\n\nimport tiledb\n\nfrom .datatypes import DataType\n\n\ndef check_dataframe_deps():\n pd_error = \"\"\"Pandas version >= 1.0 required for... | diff --git a/tiledb/dataframe_.py b/tiledb/dataframe_.py
index c41a7918cc..da72af9ef1 100644
--- a/tiledb/dataframe_.py
+++ b/tiledb/dataframe_.py
@@ -865,8 +865,9 @@ def from_csv(uri: str, csv_file: Union[str, List[str]], **kwargs):
elif mode not in ["ingest", "append"]:
raise tiledb.TileDBError(... |
scrapy__scrapy-5251 | Scrapy > 2.3 prevents passing callback in cb_kwargs
To reproduce:
```bash
scrapy startproject tutorial
cd tutorial
scrapy genspider example example.com
```
In example.py
```python
import scrapy
class ExampleSpider(scrapy.Spider):
name = 'example'
def start_requests(self):
yield s... | [
{
"content": "\"\"\"This module implements the Scraper component which parses responses and\nextracts information from them\"\"\"\n\nimport logging\nfrom collections import deque\nfrom typing import Any, Deque, Iterable, Optional, Set, Tuple, Union\n\nfrom itemadapter import is_item\nfrom twisted.internet.defer... | [
{
"content": "\"\"\"This module implements the Scraper component which parses responses and\nextracts information from them\"\"\"\n\nimport logging\nfrom collections import deque\nfrom typing import Any, Deque, Iterable, Optional, Set, Tuple, Union\n\nfrom itemadapter import is_item\nfrom twisted.internet.defer... | diff --git a/scrapy/core/scraper.py b/scrapy/core/scraper.py
index d6d6f64f93d..f40bccbb3d9 100644
--- a/scrapy/core/scraper.py
+++ b/scrapy/core/scraper.py
@@ -156,7 +156,7 @@ def call_spider(self, result: Union[Response, Failure], request: Request, spider
callback = result.request.callback or spider._par... |
jazzband__django-simple-history-496 | Showing history in admin causes n+1 queries for history_user
It need a select_related as far as i can tell. Will create a pr for it.
| [
{
"content": "from __future__ import unicode_literals\n\nfrom django import http\nfrom django.conf import settings\nfrom django.conf.urls import url\nfrom django.contrib import admin\nfrom django.contrib.admin import helpers\nfrom django.contrib.admin.utils import unquote\nfrom django.contrib.contenttypes.model... | [
{
"content": "from __future__ import unicode_literals\n\nfrom django import http\nfrom django.conf import settings\nfrom django.conf.urls import url\nfrom django.contrib import admin\nfrom django.contrib.admin import helpers\nfrom django.contrib.admin.utils import unquote\nfrom django.contrib.contenttypes.model... | diff --git a/simple_history/admin.py b/simple_history/admin.py
index 5a99efffd..870c00ade 100644
--- a/simple_history/admin.py
+++ b/simple_history/admin.py
@@ -48,7 +48,9 @@ def history_view(self, request, object_id, extra_context=None):
pk_name = opts.pk.attname
history = getattr(model, model._meta.... |
pyro-ppl__numpyro-1759 | tracer error in blocked AutoGuide
I came across a very strange bug while trying to vmap the `SVI` class (in order to parallelize model training across multiple initializations + across different datasets of the same shape).
A tracer error occurs, but only if the AutoGuide has a site blocked out and there is also a ... | [
{
"content": "# Copyright Contributors to the Pyro project.\n# SPDX-License-Identifier: Apache-2.0\n\n\"\"\"\nThis provides a small set of effect handlers in NumPyro that are modeled\nafter Pyro's `poutine <http://docs.pyro.ai/en/stable/poutine.html>`_ module.\nFor a tutorial on effect handlers more generally, ... | [
{
"content": "# Copyright Contributors to the Pyro project.\n# SPDX-License-Identifier: Apache-2.0\n\n\"\"\"\nThis provides a small set of effect handlers in NumPyro that are modeled\nafter Pyro's `poutine <http://docs.pyro.ai/en/stable/poutine.html>`_ module.\nFor a tutorial on effect handlers more generally, ... | diff --git a/numpyro/handlers.py b/numpyro/handlers.py
index 3e38e204c..6e13aeb70 100644
--- a/numpyro/handlers.py
+++ b/numpyro/handlers.py
@@ -698,6 +698,14 @@ class seed(Messenger):
users need to use `seed` as a contextmanager to generate samples from
distributions or as a decorator for their model... |
ckan__ckan-5758 | Exception when deleting resource if datastore table should exist but does not
**2.8.4**
**Describe the bug**
If for whatever reason, you end up with a resource for which datastore_active is set in the resource extras, but the datastore table does not actually exist, an exception is thown when trying to delete this ... | [
{
"content": "# encoding: utf-8\n\nimport logging\n\nfrom six import string_types\n\nimport ckan.plugins as p\nimport ckan.logic as logic\nimport ckan.model as model\nfrom ckan.model.core import State\n\nimport ckanext.datastore.helpers as datastore_helpers\nimport ckanext.datastore.logic.action as action\nimpo... | [
{
"content": "# encoding: utf-8\n\nimport logging\n\nfrom six import string_types\n\nimport ckan.plugins as p\nimport ckan.logic as logic\nimport ckan.model as model\nfrom ckan.model.core import State\n\nimport ckanext.datastore.helpers as datastore_helpers\nimport ckanext.datastore.logic.action as action\nimpo... | diff --git a/ckanext/datastore/plugin.py b/ckanext/datastore/plugin.py
index aae35a9be08..341c2f9882f 100644
--- a/ckanext/datastore/plugin.py
+++ b/ckanext/datastore/plugin.py
@@ -145,9 +145,10 @@ def after_delete(self, context, resources):
if res.extras.get('datastore_active') is True]
for res... |
kubeflow__pipelines-1936 | Handling of boolean input types
I have a pipeline that has a boolean parameter:
```
def test(
param: dsl.PipelineParam = dsl.PipelineParam(name='param', value=True, param_type=TypeMeta('bool')),
) -> None:
pass
```
When starting a new pipeline via the UI, the input field is a textbox, prefilled with ... | [
{
"content": "# Copyright 2019 Google LLC\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 applicab... | [
{
"content": "# Copyright 2019 Google LLC\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 applicab... | diff --git a/sdk/python/kfp/components/_data_passing.py b/sdk/python/kfp/components/_data_passing.py
index fcd9f4b14f8..10cf2e27b76 100644
--- a/sdk/python/kfp/components/_data_passing.py
+++ b/sdk/python/kfp/components/_data_passing.py
@@ -35,10 +35,20 @@
])
+def _deserialize_bool(s) -> bool:
+ from distutils.... |
marshmallow-code__webargs-943 | Testsuite fails under pytest==8.2.0 with `'AsyncHTTPTestCase' has no attribute 'runTest'`
We currently have some test failures in basically all python versions, starting ~2 days ago. At first glance, it looks like an issue with `tornado`'s `AsyncHTTPTestCase`, but `tornado` doesn't have a recent release.
Looking at ... | [
{
"content": "from __future__ import annotations\n\nimport importlib.metadata\n\n# Make marshmallow's validation functions importable from webargs\nfrom marshmallow import validate\nfrom marshmallow.utils import missing\nfrom packaging.version import Version\n\nfrom webargs import fields\nfrom webargs.core impo... | [
{
"content": "from __future__ import annotations\n\nimport importlib.metadata\n\n# Make marshmallow's validation functions importable from webargs\nfrom marshmallow import validate\nfrom marshmallow.utils import missing\nfrom packaging.version import Version\n\nfrom webargs import fields\nfrom webargs.core impo... | diff --git a/src/webargs/__init__.py b/src/webargs/__init__.py
index 15a2f480..aa6587ae 100755
--- a/src/webargs/__init__.py
+++ b/src/webargs/__init__.py
@@ -14,8 +14,8 @@
__version__ = importlib.metadata.version("webargs")
__parsed_version__ = Version(__version__)
__version_info__: tuple[int, int, int] | tuple[int... |
pymedusa__Medusa-9100 | Authentication check - TypeError: expected bytes-like object, not str
New bug since last update from **linuxserver/medusa** docker.
**Branch:** master
**Commit:** e6025de42a034b5887e5806fda210e30f5a1e150
**Version:** 0.5.1
Database: 44.17
**Python Version:** 3.8.5 (default, Jul 20 2020, 23:11:29) [GCC ... | [
{
"content": "# coding=utf-8\n\"\"\"Base module for request handlers.\"\"\"\nfrom __future__ import division\nfrom __future__ import unicode_literals\n\nimport base64\nimport json\nimport logging\nimport sys\nimport traceback\nfrom collections import OrderedDict\nfrom concurrent.futures import ThreadPoolExecuto... | [
{
"content": "# coding=utf-8\n\"\"\"Base module for request handlers.\"\"\"\nfrom __future__ import division\nfrom __future__ import unicode_literals\n\nimport base64\nimport json\nimport logging\nimport sys\nimport traceback\nfrom collections import OrderedDict\nfrom concurrent.futures import ThreadPoolExecuto... | diff --git a/medusa/server/api/v2/base.py b/medusa/server/api/v2/base.py
index b6b61138dd..89322c8b55 100644
--- a/medusa/server/api/v2/base.py
+++ b/medusa/server/api/v2/base.py
@@ -109,7 +109,7 @@ def _check_authentication(self):
return self._unauthorized('Invalid token.')
elif authorization... |
DataDog__dd-trace-py-1022 | Django middleware not properly supported if left empty
In Django 1.10 and above, `dd-trace-py` will attempt to check first if the user is using the `MIDDLEWARE` Django setting and will fallback to `MIDDLEWARE_CLASSES` if unset. In my application, I deliberately declare an empty list for the `MIDDLEWARE` setting to tell... | [
{
"content": "# project\nfrom .conf import settings\nfrom .compat import user_is_authenticated, get_resolver\nfrom .utils import get_request_uri\n\nfrom ...constants import ANALYTICS_SAMPLE_RATE_KEY\nfrom ...contrib import func_name\nfrom ...ext import http\nfrom ...internal.logger import get_logger\nfrom ...pr... | [
{
"content": "# project\nfrom .conf import settings\nfrom .compat import user_is_authenticated, get_resolver\nfrom .utils import get_request_uri\n\nfrom ...constants import ANALYTICS_SAMPLE_RATE_KEY\nfrom ...contrib import func_name\nfrom ...ext import http\nfrom ...internal.logger import get_logger\nfrom ...pr... | diff --git a/ddtrace/contrib/django/middleware.py b/ddtrace/contrib/django/middleware.py
index 590fd1da354..95f76be18af 100644
--- a/ddtrace/contrib/django/middleware.py
+++ b/ddtrace/contrib/django/middleware.py
@@ -52,7 +52,7 @@ def get_middleware_insertion_point():
If middleware cannot be found, returns None fo... |
google__turbinia-628 | Client uses hard coded tmp folder to compress evidence
https://github.com/google/turbinia/blob/de550193a1247a4ec48b0797452c6f4b71f67f46/turbinia/turbiniactl.py#L579
Before uploading an evidence folder it is compressed into temporary folder. The code contains the hardcoded path '/tmp'.
Let's change this to python ... | [
{
"content": "#!/usr/bin/env python\n#\n# Copyright 2017 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# ... | [
{
"content": "#!/usr/bin/env python\n#\n# Copyright 2017 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# ... | diff --git a/turbinia/turbiniactl.py b/turbinia/turbiniactl.py
index d03b65932..657b93361 100644
--- a/turbinia/turbiniactl.py
+++ b/turbinia/turbiniactl.py
@@ -576,7 +576,8 @@ def main():
log.info(
'A Cloud Only Architecture has been detected. '
'Compressing the directory for GCS upload.')... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.