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
⌀
enthought__chaco-394
Bug in the connected single range example **Problem Description** [Connected single range](https://github.com/enthought/chaco/blob/master/examples/tutorials/scipy2008/connected_single_range.py) example has a bug - left-hand side plot has all its points collapse onto the y-axis. ![screenshot from 2017-12-18 12-30-2...
[ { "content": "\"\"\" Defines the Plot class.\n\"\"\"\n# Major library imports\nimport itertools\nimport warnings\n\nimport six\nimport six.moves as sm\nfrom numpy import arange, array, ndarray, linspace\nfrom types import FunctionType\n\n# Enthought library imports\nfrom traits.api import Delegate, Dict, Instan...
[ { "content": "\"\"\" Defines the Plot class.\n\"\"\"\n# Major library imports\nimport itertools\nimport warnings\n\nimport six\nimport six.moves as sm\nfrom numpy import arange, array, ndarray, linspace\nfrom types import FunctionType\n\n# Enthought library imports\nfrom traits.api import Delegate, Dict, Instan...
diff --git a/chaco/plot.py b/chaco/plot.py index 5b17199f1..cb4a690b6 100644 --- a/chaco/plot.py +++ b/chaco/plot.py @@ -1276,7 +1276,7 @@ def _handle_range_changed(self, name, old, new): if new is not None: new.add(datasource) range_name = name + "_range" - for ren...
pypa__setuptools-777
py_limited_api calculates extension module filename incorrectly In https://github.com/pypa/setuptools/blob/2a0db96ee5e78a4d555cbd7288029cbd975c5976/setuptools/command/build_ext.py#L113-L116 a suffix of `get_config_var("SO")` is removed from the filename calculated by the superclass; however, the actual suffix that the ...
[ { "content": "import os\nimport sys\nimport itertools\nimport imp\nfrom distutils.command.build_ext import build_ext as _du_build_ext\nfrom distutils.file_util import copy_file\nfrom distutils.ccompiler import new_compiler\nfrom distutils.sysconfig import customize_compiler, get_config_var\nfrom distutils.error...
[ { "content": "import os\nimport sys\nimport itertools\nimport imp\nfrom distutils.command.build_ext import build_ext as _du_build_ext\nfrom distutils.file_util import copy_file\nfrom distutils.ccompiler import new_compiler\nfrom distutils.sysconfig import customize_compiler, get_config_var\nfrom distutils.error...
diff --git a/setuptools/command/build_ext.py b/setuptools/command/build_ext.py index f994b62654..454c91fbf0 100644 --- a/setuptools/command/build_ext.py +++ b/setuptools/command/build_ext.py @@ -111,7 +111,7 @@ def get_ext_filename(self, fullname): and get_abi3_suffix() ) if u...
marshmallow-code__webargs-537
Errors while validating arguments in headers result in a flask crash If you make a view with header arguments `@bp.arguments(someschema, location='headers')` Then feed it headers that are not defined in the schema, it will (rightfully) cause a schema validation error, however the error created includes the entire head...
[ { "content": "from collections.abc import Mapping\n\nfrom webargs.compat import MARSHMALLOW_VERSION_INFO\nfrom webargs.core import missing, is_multiple\n\n\nclass MultiDictProxy(Mapping):\n \"\"\"\n A proxy object which wraps multidict types along with a matching schema\n Whenever a value is looked up,...
[ { "content": "from collections.abc import Mapping\n\nfrom webargs.compat import MARSHMALLOW_VERSION_INFO\nfrom webargs.core import missing, is_multiple\n\n\nclass MultiDictProxy(Mapping):\n \"\"\"\n A proxy object which wraps multidict types along with a matching schema\n Whenever a value is looked up,...
diff --git a/CHANGELOG.rst b/CHANGELOG.rst index f72d2b00..5c03e4df 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -1,6 +1,16 @@ Changelog --------- +6.1.1 (Unreleased) +****************** + +Bug fixes: + +* Failure to validate flask headers would produce error data which contained + tuples as keys, and was the...
mozilla__pontoon-3172
Update to Google Analytics 4 We should update to Google Analytics 4 or our property will be permanently deleted on July 1, 2024. Until then our Universal Analytics property remains unchanged and continues to collect data.
[ { "content": "\"\"\"Django settings for Pontoon.\"\"\"\nimport re\nimport os\nimport socket\n\nfrom django.utils.functional import lazy\n\nimport dj_database_url\n\n\n_dirname = os.path.dirname\n\nROOT = _dirname(_dirname(_dirname(os.path.abspath(__file__))))\n\n\ndef path(*args):\n return os.path.join(ROOT,...
[ { "content": "\"\"\"Django settings for Pontoon.\"\"\"\nimport re\nimport os\nimport socket\n\nfrom django.utils.functional import lazy\n\nimport dj_database_url\n\n\n_dirname = os.path.dirname\n\nROOT = _dirname(_dirname(_dirname(os.path.abspath(__file__))))\n\n\ndef path(*args):\n return os.path.join(ROOT,...
diff --git a/pontoon/base/templates/tracker.html b/pontoon/base/templates/tracker.html index 4f1008828e..723b528531 100644 --- a/pontoon/base/templates/tracker.html +++ b/pontoon/base/templates/tracker.html @@ -1,14 +1,11 @@ {% if settings.GOOGLE_ANALYTICS_KEY %} - <!-- Google Analytics --> - <script type="text/java...
mars-project__mars-613
[BUG]The parameter `open_browser` of `new_cluster` doesn't work **Describe the bug** In `new_cluster`, we use ```python open_browser = open_browser or options.deploy.open_browser ``` to decide if we should open the browser after web worker available. When `open_browser` is `False`, it will still fall back t...
[ { "content": "#!/usr/bin/env python\n# -*- coding: utf-8 -*-\n# Copyright 1999-2018 Alibaba Group Holding Ltd.\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://...
[ { "content": "#!/usr/bin/env python\n# -*- coding: utf-8 -*-\n# Copyright 1999-2018 Alibaba Group Holding Ltd.\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://...
diff --git a/mars/deploy/local/core.py b/mars/deploy/local/core.py index 5a889479f6..533ba4875c 100644 --- a/mars/deploy/local/core.py +++ b/mars/deploy/local/core.py @@ -290,7 +290,8 @@ def stop(self): def new_cluster(address='0.0.0.0', web=False, n_process=None, shared_memory=None, open_browser=No...
mlflow__mlflow-2098
[BUG] multistep_workflow "best-effort detection of 'already run'" fails to detect run_info has FINISHED status Thank you for submitting an issue. Please refer to our [issue policy](https://www.github.com/mlflow/mlflow/blob/master/ISSUE_POLICY.md) for information on what types of issues we address. For help with debugg...
[ { "content": "\"\"\"\nDownloads the MovieLens dataset, ETLs it into Parquet, trains an\nALS model, and uses the ALS model to train a Keras neural network.\n\nSee README.rst for more details.\n\"\"\"\n\nimport click\nimport os\n\n\nimport mlflow\nfrom mlflow.utils import mlflow_tags\nfrom mlflow.entities import ...
[ { "content": "\"\"\"\nDownloads the MovieLens dataset, ETLs it into Parquet, trains an\nALS model, and uses the ALS model to train a Keras neural network.\n\nSee README.rst for more details.\n\"\"\"\n\nimport click\nimport os\n\n\nimport mlflow\nfrom mlflow.utils import mlflow_tags\nfrom mlflow.entities import ...
diff --git a/examples/multistep_workflow/main.py b/examples/multistep_workflow/main.py index 4423edcecca9c..fffd3b8fcb4e5 100644 --- a/examples/multistep_workflow/main.py +++ b/examples/multistep_workflow/main.py @@ -40,7 +40,7 @@ def _already_ran(entry_point_name, parameters, git_commit, experiment_id=None): ...
getsentry__sentry-10686
UnicodeEncodeError: 'ascii' codec can't encode character u'\xe9' ## Important Details How are you running Sentry? * [x] On-Premise docker [Version 9.0.0] * [ ] Saas (sentry.io) * [ ] Other [briefly describe your environment] ## Description I've got this exception in the `internal` Sentry project : `Unic...
[ { "content": "\"\"\"\nsentry.models.group\n~~~~~~~~~~~~~~~~~~~\n\n:copyright: (c) 2010-2014 by the Sentry Team, see AUTHORS for more details.\n:license: BSD, see LICENSE for more details.\n\"\"\"\nfrom __future__ import absolute_import, print_function\n\nimport logging\nimport math\nimport re\nimport warnings\n...
[ { "content": "\"\"\"\nsentry.models.group\n~~~~~~~~~~~~~~~~~~~\n\n:copyright: (c) 2010-2014 by the Sentry Team, see AUTHORS for more details.\n:license: BSD, see LICENSE for more details.\n\"\"\"\nfrom __future__ import absolute_import, print_function\n\nimport logging\nimport math\nimport re\nimport warnings\n...
diff --git a/src/sentry/models/group.py b/src/sentry/models/group.py index be6c2cc4d32408..7e25fe92a66a07 100644 --- a/src/sentry/models/group.py +++ b/src/sentry/models/group.py @@ -16,8 +16,8 @@ from django.core.urlresolvers import reverse from django.db import models from django.utils import timezone +from django...
pwr-Solaar__Solaar-1456
Big amount of CPU **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 see if your issue persists. --> - Solaar versio...
[ { "content": "## 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 option) any later versio...
[ { "content": "## 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 option) any later versio...
diff --git a/lib/logitech_receiver/notifications.py b/lib/logitech_receiver/notifications.py index b9a4b581a4..50a47f6671 100644 --- a/lib/logitech_receiver/notifications.py +++ b/lib/logitech_receiver/notifications.py @@ -161,6 +161,9 @@ def _process_device_notification(device, status, n): # HID++ 1.0 requests, s...
Gallopsled__pwntools-967
pwnlib.util.misc.run_in_terminal does not respect $TERM_PROGRAM The documentation for `pwnlib.util.misc.run_in_terminal` asserts that it will respect the environment variable $TERM_PROGRAM, however that does not actually occur. There's no reference to this environment variable when detecting which terminal to use: ...
[ { "content": "import base64\nimport errno\nimport os\nimport platform\nimport re\nimport socket\nimport stat\nimport string\n\nfrom pwnlib.context import context\nfrom pwnlib.log import getLogger\nfrom pwnlib.util import fiddling\nfrom pwnlib.util import lists\n\nlog = getLogger(__name__)\n\ndef align(alignment...
[ { "content": "import base64\nimport errno\nimport os\nimport platform\nimport re\nimport socket\nimport stat\nimport string\n\nfrom pwnlib.context import context\nfrom pwnlib.log import getLogger\nfrom pwnlib.util import fiddling\nfrom pwnlib.util import lists\n\nlog = getLogger(__name__)\n\ndef align(alignment...
diff --git a/pwnlib/util/misc.py b/pwnlib/util/misc.py index 6c7fafc0f..474ad8086 100644 --- a/pwnlib/util/misc.py +++ b/pwnlib/util/misc.py @@ -210,6 +210,9 @@ def run_in_new_terminal(command, terminal = None, args = None): elif which('pwntools-terminal'): terminal = 'pwntools-terminal' ...
PennyLaneAI__pennylane-211
Bug: QubitStateVector function for qubit state preparation Hi, There is some bug or inconsistency in this function. see the file jupyter notebook attached. ```Python dev2 = qml.device('default.qubit', wires=2) @qml.qnode(dev2) def make_State2(s=None): qml.QubitStateVector(s, wires=[0,1]) return qml....
[ { "content": "# Copyright 2018 Xanadu Quantum Technologies 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 re...
[ { "content": "# Copyright 2018 Xanadu Quantum Technologies 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 re...
diff --git a/pennylane/plugins/default_qubit.py b/pennylane/plugins/default_qubit.py index f5a2f15b820..5a756f03282 100644 --- a/pennylane/plugins/default_qubit.py +++ b/pennylane/plugins/default_qubit.py @@ -294,7 +294,7 @@ def pre_apply(self): def apply(self, operation, wires, par): if operation == 'Q...
cal-itp__benefits-447
Ensure OAuth redirect URLs are secure We construct the OAUth redirect URLs using the Django [`reverse()`](https://docs.djangoproject.com/en/3.2/ref/urlresolvers/#reverse) helper and [`request.build_absolute_uri()`](https://docs.djangoproject.com/en/3.2/ref/request-response/#django.http.HttpRequest.build_absolute_uri). ...
[ { "content": "\"\"\"\nDjango settings for benefits project.\n\"\"\"\nimport os\n\n\ndef _filter_empty(ls):\n return [s for s in ls if s]\n\n\n# Build paths inside the project like this: os.path.join(BASE_DIR, ...)\nBASE_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__)))\n\n# SECURITY WARNING: ...
[ { "content": "\"\"\"\nDjango settings for benefits project.\n\"\"\"\nimport os\n\n\ndef _filter_empty(ls):\n return [s for s in ls if s]\n\n\n# Build paths inside the project like this: os.path.join(BASE_DIR, ...)\nBASE_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__)))\n\n# SECURITY WARNING: ...
diff --git a/benefits/settings.py b/benefits/settings.py index 2bca42d675..ccba7b0d6f 100644 --- a/benefits/settings.py +++ b/benefits/settings.py @@ -90,6 +90,14 @@ def _filter_empty(ls): SECURE_BROWSER_XSS_FILTER = True +# the NGINX reverse proxy sits in front of the application in deployed environments +# SSL t...
napari__napari-5726
3D camera rotation is broken ## 🐛 Bug It seems we introduced a bug in #5701, according to `git bisect`. The 3D camera rotation is "absolute" instead of relative (i.e: the point you press on the canvas determines the starting point of that rotation). ## To Reproduce ```py import napari import numpy as np v ...
[ { "content": "from typing import Type\n\nimport numpy as np\nfrom vispy.scene import ArcballCamera, BaseCamera, PanZoomCamera\n\nfrom napari._vispy.utils.quaternion import quaternion2euler\n\n\nclass VispyCamera:\n \"\"\"Vipsy camera for both 2D and 3D rendering.\n\n Parameters\n ----------\n view :...
[ { "content": "from typing import Type\n\nimport numpy as np\nfrom vispy.scene import ArcballCamera, BaseCamera, PanZoomCamera\n\nfrom napari._vispy.utils.quaternion import quaternion2euler\n\n\nclass VispyCamera:\n \"\"\"Vipsy camera for both 2D and 3D rendering.\n\n Parameters\n ----------\n view :...
diff --git a/napari/_vispy/camera.py b/napari/_vispy/camera.py index 670030a05d3..ac12b704cfd 100644 --- a/napari/_vispy/camera.py +++ b/napari/_vispy/camera.py @@ -242,7 +242,8 @@ def viewbox_mouse_event(self, event): self.mouse_zoom and event.type == 'mouse_wheel' or...
AlexsLemonade__refinebio-2025
Too many emails when dataset fails to smash ### Context I tried to download a dataset from refine.bio which failed. (Nov 19, 20) ### Problem or idea I received 5 emails that day and 4 of them in a span of 20 minutes, all with the same failure reason. For another one, I tried to download I got 3 emails in a span...
[ { "content": "# -*- coding: utf-8 -*-\n\nimport boto3\nimport csv\nimport os\nimport rpy2\nimport rpy2.robjects as ro\nimport shutil\nimport simplejson as json\nimport string\nimport warnings\nimport requests\nimport psutil\nimport logging\nimport time\n\nfrom botocore.exceptions import ClientError\nfrom dateti...
[ { "content": "# -*- coding: utf-8 -*-\n\nimport boto3\nimport csv\nimport os\nimport rpy2\nimport rpy2.robjects as ro\nimport shutil\nimport simplejson as json\nimport string\nimport warnings\nimport requests\nimport psutil\nimport logging\nimport time\n\nfrom botocore.exceptions import ClientError\nfrom dateti...
diff --git a/workers/data_refinery_workers/processors/smasher.py b/workers/data_refinery_workers/processors/smasher.py index ca1b8c55e..414780650 100644 --- a/workers/data_refinery_workers/processors/smasher.py +++ b/workers/data_refinery_workers/processors/smasher.py @@ -433,6 +433,11 @@ def _notify(job_context: Dict)...
pydantic__pydantic-8341
Upgrade ruff target version to Python 3.8 ### Initial Checks - [X] I confirm that I'm using Pydantic V2 ### Description I deemed this as an action left out from [Dropping Python 3.7 Support](https://github.com/pydantic/pydantic/issues/7187) 1. Update ruff's `target-version` to `py38` 2. Run `make format` a...
[ { "content": "from __future__ import annotations\n\nimport sys\nimport warnings\nfrom typing import TYPE_CHECKING, Iterable\n\nfrom typing_extensions import Final\n\nif sys.version_info >= (3, 8):\n import importlib.metadata as importlib_metadata\nelse:\n import importlib_metadata\n\n\nif TYPE_CHECKING:\n...
[ { "content": "from __future__ import annotations\n\nimport importlib.metadata as importlib_metadata\nimport warnings\nfrom typing import TYPE_CHECKING, Final, Iterable\n\nif TYPE_CHECKING:\n from . import PydanticPluginProtocol\n\n\nPYDANTIC_ENTRY_POINT_GROUP: Final[str] = 'pydantic'\n\n# cache of plugins\n_...
diff --git a/pydantic/plugin/_loader.py b/pydantic/plugin/_loader.py index b30143b6098..9e0e33ca8bb 100644 --- a/pydantic/plugin/_loader.py +++ b/pydantic/plugin/_loader.py @@ -1,16 +1,8 @@ from __future__ import annotations -import sys +import importlib.metadata as importlib_metadata import warnings -from typing i...
vaexio__vaex-1268
[FEATURE-REQUEST] Read files from ADLS Gen 2 (Cloud support for Azure Data Lake) Hello, in addition to support for S3 and GCS, it'd be awesome if it'd also be possible to read files directly from ADLS Gen 2, since some of us are restricted in the choice of cloud platforms we can use. Thanks,
[ { "content": "__author__ = 'breddels'\nimport pathlib\nimport logging\nfrom glob import glob as local_glob\nimport io\nimport os\nimport re\nimport sys\nfrom urllib.parse import parse_qs\nimport warnings\nimport pkg_resources\n\nimport pyarrow as pa\nimport pyarrow.fs\n\nimport vaex.file.cache\n\n\nnormal_open ...
[ { "content": "__author__ = 'breddels'\nimport pathlib\nimport logging\nfrom glob import glob as local_glob\nimport io\nimport os\nimport re\nimport sys\nfrom urllib.parse import parse_qs\nimport warnings\nimport pkg_resources\n\nimport pyarrow as pa\nimport pyarrow.fs\n\nimport vaex.file.cache\n\n\nnormal_open ...
diff --git a/packages/vaex-core/vaex/file/__init__.py b/packages/vaex-core/vaex/file/__init__.py index a2f0800c9c..5443972c88 100644 --- a/packages/vaex-core/vaex/file/__init__.py +++ b/packages/vaex-core/vaex/file/__init__.py @@ -190,6 +190,8 @@ def parse(path, fs_options={}, fs=None, for_arrow=False): im...
voxel51__fiftyone-355
Incosistent behavior when deleting datasets Why does the code below seemingly work when I copy + paste the whole thing into ipython, when, conversely, I get an error if I run the same commands one-by-one manually with, say, 1 second of spacing between each? ```py import fiftyone as fo dataset1 = fo.Dataset("test...
[ { "content": "\"\"\"\nFiftyOne datasets.\n\n| Copyright 2017-2020, Voxel51, Inc.\n| `voxel51.com <https://voxel51.com/>`_\n|\n\"\"\"\nfrom copy import deepcopy\nimport datetime\nimport inspect\nimport logging\nimport numbers\nimport os\n\nfrom bson import ObjectId\nfrom mongoengine.errors import DoesNotExist, F...
[ { "content": "\"\"\"\nFiftyOne datasets.\n\n| Copyright 2017-2020, Voxel51, Inc.\n| `voxel51.com <https://voxel51.com/>`_\n|\n\"\"\"\nfrom copy import deepcopy\nimport datetime\nimport inspect\nimport logging\nimport numbers\nimport os\n\nfrom bson import ObjectId\nfrom mongoengine.errors import DoesNotExist, F...
diff --git a/fiftyone/core/dataset.py b/fiftyone/core/dataset.py index e14771dde71..f90861819c1 100644 --- a/fiftyone/core/dataset.py +++ b/fiftyone/core/dataset.py @@ -195,7 +195,12 @@ def __delitem__(self, sample_id): self.remove_sample(sample_id) def __getattribute__(self, name): - if name in ...
projectmesa__mesa-2049
JupyterViz: the default grid space drawer doesn't scale to large size **Describe the bug** <!-- A clear and concise description the bug --> Here is Schelling space for 60x60: ![2023-07-24-102909_468x350_scrot](https://github.com/projectmesa/mesa/assets/395821/0949b124-dfeb-48ff-9205-4d242e99c833) **Expected behav...
[ { "content": "from typing import Optional\n\nimport networkx as nx\nimport solara\nfrom matplotlib.figure import Figure\nfrom matplotlib.ticker import MaxNLocator\n\nimport mesa\n\n\n@solara.component\ndef SpaceMatplotlib(model, agent_portrayal, dependencies: Optional[list[any]] = None):\n space_fig = Figure...
[ { "content": "from typing import Optional\n\nimport networkx as nx\nimport solara\nfrom matplotlib.figure import Figure\nfrom matplotlib.ticker import MaxNLocator\n\nimport mesa\n\n\n@solara.component\ndef SpaceMatplotlib(model, agent_portrayal, dependencies: Optional[list[any]] = None):\n space_fig = Figure...
diff --git a/mesa/experimental/components/matplotlib.py b/mesa/experimental/components/matplotlib.py index c43ad964224..85f8df9cb1d 100644 --- a/mesa/experimental/components/matplotlib.py +++ b/mesa/experimental/components/matplotlib.py @@ -48,6 +48,9 @@ def portray(g): if "color" in data: ...
scikit-hep__pyhf-1837
Jinja2 v3.1.0 breaks nbsphinx ### Summary [`Jinja2` `v3.1.0`](https://pypi.org/project/Jinja2/3.1.0/#history) was released 2 hours ago and is breaking [`nbsphinx`](https://github.com/spatialaudio/nbsphinx) (v0.8.7). This will need to get resolved soon by `nbsphinx`, but as a stopgap we should probably put in a `...
[ { "content": "from setuptools import setup\n\nextras_require = {\n 'shellcomplete': ['click_completion'],\n 'tensorflow': [\n 'tensorflow>=2.3.1', # c.f. https://github.com/tensorflow/tensorflow/pull/40789\n 'tensorflow-probability>=0.11.0', # c.f. PR #1657\n ],\n 'torch': ['torch>=1...
[ { "content": "from setuptools import setup\n\nextras_require = {\n 'shellcomplete': ['click_completion'],\n 'tensorflow': [\n 'tensorflow>=2.3.1', # c.f. https://github.com/tensorflow/tensorflow/pull/40789\n 'tensorflow-probability>=0.11.0', # c.f. PR #1657\n ],\n 'torch': ['torch>=1...
diff --git a/setup.py b/setup.py index c9c5fa38e1..32dfe5d48f 100644 --- a/setup.py +++ b/setup.py @@ -55,7 +55,6 @@ 'sphinx-click', 'sphinx_rtd_theme', 'nbsphinx!=0.8.8', # c.f. https://github.com/spatialaudio/nbsphinx/issues/620 - 'Jinja2!=3.1.0', # c.f. https://git...
open-telemetry__opentelemetry-python-contrib-537
Problem with using domain socket as bind address **Describe your environment** The OT-wsgi library throws error if domain socket is used for the bind address. **Steps to reproduce** Here is a test program: ``` import web from time import sleep from opentelemetry import trace from opentelemetry.sdk.trace im...
[ { "content": "# Copyright The OpenTelemetry Authors\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# http://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless required by...
[ { "content": "# Copyright The OpenTelemetry Authors\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# http://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless required by...
diff --git a/instrumentation/opentelemetry-instrumentation-wsgi/src/opentelemetry/instrumentation/wsgi/__init__.py b/instrumentation/opentelemetry-instrumentation-wsgi/src/opentelemetry/instrumentation/wsgi/__init__.py index 24303a8ac6..823ede7903 100644 --- a/instrumentation/opentelemetry-instrumentation-wsgi/src/open...
Nitrate__Nitrate-360
Ensure to work with Python 3.7
[ { "content": "# -*- coding: utf-8 -*-\n\nimport sys\n\nfrom setuptools import setup, find_packages\n\n\nwith open('VERSION.txt', 'r') as f:\n pkg_version = f.read().strip()\n\n\ndef get_long_description():\n with open('README.rst', 'r') as f:\n return f.read()\n\n\ninstall_requires = [\n 'PyMySQ...
[ { "content": "# -*- coding: utf-8 -*-\n\nimport sys\n\nfrom setuptools import setup, find_packages\n\n\nwith open('VERSION.txt', 'r') as f:\n pkg_version = f.read().strip()\n\n\ndef get_long_description():\n with open('README.rst', 'r') as f:\n return f.read()\n\n\ninstall_requires = [\n 'PyMySQ...
diff --git a/.travis.yml b/.travis.yml index 2fe19619..8aa8188b 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,7 +1,9 @@ language: python +dist: xenial python: - "2.7" - "3.6" + - "3.7" before_install: - pip install coveralls install: pip install tox-travis diff --git a/setup.py b/setup.py index 3521036...
google__mobly-842
Refactor Snippet Client Mobly supports testing devices of multiple platforms, including Android, iOS and Windows. Mobly has one snippet client for each platform, and these clients share common patterns. So we want to consolidate current clients that they inherit from the same base class. Currently, the father class ...
[ { "content": "# Copyright 2018 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# Unless required by applicab...
[ { "content": "# Copyright 2018 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# Unless required by applicab...
diff --git a/mobly/controllers/android_device_lib/services/snippet_management_service.py b/mobly/controllers/android_device_lib/services/snippet_management_service.py index 1eeb3382..fae60e2f 100644 --- a/mobly/controllers/android_device_lib/services/snippet_management_service.py +++ b/mobly/controllers/android_device_...
bids-standard__pybids-1034
All False boolean metadata fields are changed to True I've noticed that False metadata fields are being changed to True when I use `get_metadata()`. I've noticed this in `0.16.3` and the current master (`0.16.3.post0.dev27`) on Python 3.9.17, but I haven't checked previous versions. To create the test dataset: ``...
[ { "content": "\"\"\" Model classes used in BIDSLayouts. \"\"\"\n\nimport re\nimport os\nfrom pathlib import Path\nimport warnings\nimport json\nfrom copy import deepcopy\nfrom itertools import chain\nfrom functools import lru_cache\nfrom collections import UserDict\n\nfrom sqlalchemy.ext.associationproxy import...
[ { "content": "\"\"\" Model classes used in BIDSLayouts. \"\"\"\n\nimport re\nimport os\nfrom pathlib import Path\nimport warnings\nimport json\nfrom copy import deepcopy\nfrom itertools import chain\nfrom functools import lru_cache\nfrom collections import UserDict\n\nfrom sqlalchemy.ext.associationproxy import...
diff --git a/bids/layout/models.py b/bids/layout/models.py index 4221ab3ca..5120db7a8 100644 --- a/bids/layout/models.py +++ b/bids/layout/models.py @@ -698,6 +698,9 @@ def _init_on_load(self): if self._dtype == 'json': self.value = json.loads(self._value) self.dtype = 'json' + ...
chainer__chainer-254
`split_axis` fails when it splits the last axis of an array on py3 This code causes an error. ``` >>> x=chainer.Variable(chainer.cuda.to_gpu(numpy.array([1,2,3], numpy.float32))) >>> chainer.functions.split_axis(x, [1], 0) ... struct.error: required argument is not an integer ``` A return value of `numpy.prod(())` is...
[ { "content": "import collections\n\nimport numpy\n\nfrom chainer import cuda\nfrom chainer import function\nfrom chainer.utils import type_check\n\n\n_args = 'float* y, float* x, int cdimy, int cdimx, int rdim, int coffset'\n_preamble = '''\n#define COPY(statement) \\\n int l = i / (rdim * cdimy); \\\n ...
[ { "content": "import collections\n\nimport numpy\n\nfrom chainer import cuda\nfrom chainer import function\nfrom chainer.utils import type_check\n\n\n_args = 'float* y, float* x, int cdimy, int cdimx, int rdim, int coffset'\n_preamble = '''\n#define COPY(statement) \\\n int l = i / (rdim * cdimy); \\\n ...
diff --git a/chainer/functions/split_axis.py b/chainer/functions/split_axis.py index aedab48608dd..20fa62d13a59 100644 --- a/chainer/functions/split_axis.py +++ b/chainer/functions/split_axis.py @@ -57,7 +57,7 @@ def forward_cpu(self, x): def forward_gpu(self, x): xshape = x[0].shape self.cdimx =...
PrefectHQ__prefect-3551
Change "PYTHONPATH" construct for local agent ## Current behavior Local agent has the "--import-path" feature, but its now availible only for unix enviroment, because PYTHONPATH is concatenated with ":" current_env["PYTHONPATH"] = ":".join(python_path) ## Proposed behavior Use "os.pathsep" instead ":", to get th...
[ { "content": "import os\nimport socket\nimport sys\nfrom subprocess import STDOUT, Popen, DEVNULL\nfrom typing import Iterable, List\n\nfrom prefect import config\nfrom prefect.agent import Agent\nfrom prefect.environments.storage import Docker\nfrom prefect.run_configs import LocalRun\nfrom prefect.serializati...
[ { "content": "import os\nimport socket\nimport sys\nfrom subprocess import STDOUT, Popen, DEVNULL\nfrom typing import Iterable, List\n\nfrom prefect import config\nfrom prefect.agent import Agent\nfrom prefect.environments.storage import Docker\nfrom prefect.run_configs import LocalRun\nfrom prefect.serializati...
diff --git a/changes/pr3551.yaml b/changes/pr3551.yaml new file mode 100644 index 000000000000..729d7b304b34 --- /dev/null +++ b/changes/pr3551.yaml @@ -0,0 +1,2 @@ +fix: + - "Fix LocalAgent PYTHONPATH construction on Windows - [#3551](https://github.com/PrefectHQ/prefect/pull/3551)" diff --git a/src/prefect/agent/loc...
getpelican__pelican-2251
pelican-import output directory confusing name The pelican output directory default name is ``output`` for html generated files, but the pelican-import output directory default name is ``output`` for content source files. This could be very confusing for beginers. I think that a sane pelican-import output directory ...
[ { "content": "#!/usr/bin/env python\n# -*- coding: utf-8 -*-\nfrom __future__ import print_function, unicode_literals\n\nimport argparse\nimport logging\nimport os\nimport re\nimport subprocess\nimport sys\nimport time\nfrom codecs import open\n\nfrom six.moves.urllib.error import URLError\nfrom six.moves.urlli...
[ { "content": "#!/usr/bin/env python\n# -*- coding: utf-8 -*-\nfrom __future__ import print_function, unicode_literals\n\nimport argparse\nimport logging\nimport os\nimport re\nimport subprocess\nimport sys\nimport time\n\nfrom codecs import open\n\nfrom six.moves.urllib.error import URLError\nfrom six.moves.url...
diff --git a/docs/importer.rst b/docs/importer.rst index 83f4e1122..2a5365ee5 100644 --- a/docs/importer.rst +++ b/docs/importer.rst @@ -63,7 +63,7 @@ Optional arguments --tumblr Tumblr API (default: False) --feed Feed to parse (default: False) -o OUTPUT, --output OUTPUT - ...
googleapis__google-auth-library-python-729
jwt.encode() overrides the algorithm specified by the caller The `jwt.encode()` function always set the `alg` JWT header to either ES256 or RS256, even if the caller had specified an explicit algorithm: https://github.com/googleapis/google-auth-library-python/blob/48e8be3d59a47493e60f5b5d9f284b300979a11c/google/auth...
[ { "content": "# Copyright 2016 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 2016 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/google/auth/jwt.py b/google/auth/jwt.py index a4f04f529..8165ddad7 100644 --- a/google/auth/jwt.py +++ b/google/auth/jwt.py @@ -95,10 +95,11 @@ def encode(signer, payload, header=None, key_id=None): header.update({"typ": "JWT"}) - if es256 is not None and isinstance(signer, es256.ES256Signer): ...
jupyterhub__jupyterhub-596
`hub_prefix` option does not work Set `JupyterHub.hub_prefix` option, and error occurred. ``` TypeError: _hub_prefix_changed() missing 2 required positional arguments: 'old' and 'new' ``` Update `_hub_prefix_changed()`. ``` diff --- old/jupyterhub/app.py▸ 2016-05-31 18:01:49.633124540 +0900 +++ new/jupyterhub/ap...
[ { "content": "#!/usr/bin/env python3\n\"\"\"The multi-user notebook application\"\"\"\n\n# Copyright (c) Jupyter Development Team.\n# Distributed under the terms of the Modified BSD License.\n\nimport atexit\nimport binascii\nimport logging\nimport os\nimport signal\nimport socket\nimport sys\nimport threading\...
[ { "content": "#!/usr/bin/env python3\n\"\"\"The multi-user notebook application\"\"\"\n\n# Copyright (c) Jupyter Development Team.\n# Distributed under the terms of the Modified BSD License.\n\nimport atexit\nimport binascii\nimport logging\nimport os\nimport signal\nimport socket\nimport sys\nimport threading\...
diff --git a/jupyterhub/app.py b/jupyterhub/app.py index 15d379d892..1b0533c530 100644 --- a/jupyterhub/app.py +++ b/jupyterhub/app.py @@ -354,7 +354,8 @@ def _hub_prefix_default(self): return url_path_join(self.base_url, '/hub/') @observe('hub_prefix') - def _hub_prefix_changed(self, name, old, new)...
enthought__chaco-631
Use GitHub Actions instead of Travis and Appveyor CI We need to replace the use of Travis and Appveyor CI with GitHub Actions CI, similar to what we did in other ETS projects.
[ { "content": "# -*- coding: utf-8 -*-\n\"\"\"\nMinard's Map of Napoleon's Russian Campaign\n===========================================\n\nA Chaco version of Minard's visualization, as popularized by Edward Tufte.\n\nThis shows the use of segment plots, text plots and 1d line scatter plots.\n\nData is adapted f...
[ { "content": "# -*- coding: utf-8 -*-\n\"\"\"\nMinard's Map of Napoleon's Russian Campaign\n===========================================\n\nA Chaco version of Minard's visualization, as popularized by Edward Tufte.\n\nThis shows the use of segment plots, text plots and 1d line scatter plots.\n\nData is adapted f...
diff --git a/.github/workflows/test-with-edm.yml b/.github/workflows/test-with-edm.yml new file mode 100644 index 000000000..f9ff7fb0f --- /dev/null +++ b/.github/workflows/test-with-edm.yml @@ -0,0 +1,87 @@ +# This workflow targets stable released dependencies from EDM. +# Note that some packages may not actually be i...
pwr-Solaar__Solaar-736
Wireless Touch Keyboard K410 not recognized due to assertion error Firstly: thanks for writing this software. Being able to toggle Fn key behavior makes my life with this keyboard lot easier. There is a minor issue with the K410, causing its entry not to be added to the menu. I know it is not in the supported list so ...
[ { "content": "# -*- python-mode -*-\n# -*- coding: UTF-8 -*-\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...
[ { "content": "# -*- python-mode -*-\n# -*- coding: UTF-8 -*-\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...
diff --git a/lib/logitech_receiver/settings.py b/lib/logitech_receiver/settings.py index 21a4f715aa..89e829da40 100644 --- a/lib/logitech_receiver/settings.py +++ b/lib/logitech_receiver/settings.py @@ -60,7 +60,8 @@ def __init__(self, name, rw, validator, kind=None, label=None, description=None, def __call__(self,...
cisagov__manage.get.gov-278
DomainApplication list on logged in user homepage Outcome: A list (limited to one now) of domain applications on the homepage of a logged in user. A/C: As a user I want to see my in progress applications for a domain. As a user I want to be able to select an application that is `In Progress` and continue my progress....
[ { "content": "from django.shortcuts import render\n\n\ndef index(request):\n \"\"\"This page is available to anyone without logging in.\"\"\"\n return render(request, \"home.html\")\n", "path": "src/registrar/views/index.py" } ]
[ { "content": "from django.shortcuts import render\n\nfrom registrar.models import DomainApplication\n\n\ndef index(request):\n \"\"\"This page is available to anyone without logging in.\"\"\"\n context = {}\n if request.user.is_authenticated:\n applications = DomainApplication.objects.filter(cre...
diff --git a/src/registrar/templates/404.html b/src/registrar/templates/404.html index 9b791a88e..f715e0fa9 100644 --- a/src/registrar/templates/404.html +++ b/src/registrar/templates/404.html @@ -7,7 +7,7 @@ {% block content %} <main id="main-content" class="grid-container"> - <h2>{% translate "Page not found" %}...
elastic__apm-agent-python-576
Transport.queue spams log when queue is full In a busy application, the agent-internal event queue may fill up frequently, which will lead to events being dropped. We currently log a warning every time this occurs, which may lead to spamming the logs. Ideally, the agent would keep a record of the number of events dr...
[ { "content": "# -*- coding: utf-8 -*-\n\n# BSD 3-Clause License\n#\n# Copyright (c) 2019, Elasticsearch BV\n# All rights reserved.\n#\n# Redistribution and use in source and binary forms, with or without\n# modification, are permitted provided that the following conditions are met:\n#\n# * Redistributions...
[ { "content": "# -*- coding: utf-8 -*-\n\n# BSD 3-Clause License\n#\n# Copyright (c) 2019, Elasticsearch BV\n# All rights reserved.\n#\n# Redistribution and use in source and binary forms, with or without\n# modification, are permitted provided that the following conditions are met:\n#\n# * Redistributions...
diff --git a/elasticapm/transport/base.py b/elasticapm/transport/base.py index 1b8a63f96..6295e9ec0 100644 --- a/elasticapm/transport/base.py +++ b/elasticapm/transport/base.py @@ -109,7 +109,7 @@ def queue(self, event_type, data, flush=False): self._event_queue.put((event_type, data, flush), block=False, ...
microsoft__Qcodes-923
internal data of String validator breaks AWG5014 In PR #859 new variables `._valid_values` are added to the `String` validator. The default validator object `qcodes.utils.validators.String()` now has a size of 1 GB. The `AWG5014` driver uses the `String` validator four times, so the driver now is 4GB. If one reloads...
[ { "content": "import math\nfrom typing import Union, Tuple, cast\n\nimport numpy as np\n\nBIGSTRING = 1000000000\nBIGINT = int(1e18)\n\n\ndef validate_all(*args, context=''):\n \"\"\"\n Takes a list of (validator, value) couplets and tests whether they are\n all valid, raising ValueError otherwise\n\n ...
[ { "content": "import math\nfrom typing import Union, Tuple, cast\n\nimport numpy as np\n\nBIGSTRING = 1000000000\nBIGINT = int(1e18)\n\n\ndef validate_all(*args, context=''):\n \"\"\"\n Takes a list of (validator, value) couplets and tests whether they are\n all valid, raising ValueError otherwise\n\n ...
diff --git a/qcodes/utils/validators.py b/qcodes/utils/validators.py index 7cd95903ca7..f8d7eeb9bf2 100644 --- a/qcodes/utils/validators.py +++ b/qcodes/utils/validators.py @@ -147,7 +147,7 @@ def __init__(self, min_length=0, max_length=BIGSTRING): else: raise TypeError('max_length must be a posit...
ivy-llc__ivy-16244
softshrink
[ { "content": "# local\nimport ivy\nfrom ivy.func_wrapper import with_supported_dtypes\nfrom ivy.functional.frontends.paddle.func_wrapper import to_ivy_arrays_and_back\nfrom ivy.functional.frontends.paddle.tensor.math import tanh as paddle_tanh\nfrom ivy.functional.frontends.paddle.tensor.math import (\n log_...
[ { "content": "# local\nimport ivy\nfrom ivy.func_wrapper import with_supported_dtypes\nfrom ivy.functional.frontends.paddle.func_wrapper import to_ivy_arrays_and_back\nfrom ivy.functional.frontends.paddle.tensor.math import tanh as paddle_tanh\nfrom ivy.functional.frontends.paddle.tensor.math import (\n log_...
diff --git a/ivy/functional/frontends/paddle/nn/functional/activation.py b/ivy/functional/frontends/paddle/nn/functional/activation.py index 94101957c5a34..3635f57263281 100644 --- a/ivy/functional/frontends/paddle/nn/functional/activation.py +++ b/ivy/functional/frontends/paddle/nn/functional/activation.py @@ -72,3 +7...
pex-tool__pex-757
version 1.6.9 fails with null module __file__ attribute On my arch linux system, after the pants upgrade to version 1.6.9, a number of pieces of pants functionality that make use of pex started failing with the following error message: ``` Traceback (most recent call last): ...
[ { "content": "# Copyright 2014 Pants project contributors (see CONTRIBUTORS.md).\n# Licensed under the Apache License, Version 2.0 (see LICENSE).\n\nfrom __future__ import absolute_import, print_function\n\nimport os\nimport sys\nfrom distutils import sysconfig\nfrom site import USER_SITE\n\nimport pex.third_pa...
[ { "content": "# Copyright 2014 Pants project contributors (see CONTRIBUTORS.md).\n# Licensed under the Apache License, Version 2.0 (see LICENSE).\n\nfrom __future__ import absolute_import, print_function\n\nimport os\nimport sys\nfrom distutils import sysconfig\nfrom site import USER_SITE\n\nimport pex.third_pa...
diff --git a/pex/pex.py b/pex/pex.py index c357085d1..1260c1a60 100644 --- a/pex/pex.py +++ b/pex/pex.py @@ -175,8 +175,8 @@ def minimum_sys_modules(cls, site_libs, modules=None): for module_name, module in modules.items(): # Tainted modules should be dropped. - module_file = getattr(module, '__file_...
lutris__lutris-3705
Store banners in .cache They have no place to be in .local/share Store banners in .cache They have no place to be in .local/share
[ { "content": "\"\"\"Internal settings.\"\"\"\nimport os\nimport sys\nfrom gettext import gettext as _\n\nfrom gi.repository import GLib\n\nfrom lutris import __version__\nfrom lutris.util.settings import SettingsIO\n\nPROJECT = \"Lutris\"\nVERSION = __version__\nCOPYRIGHT = _(\"(c) 2010-2021 Lutris Team\")\nAUT...
[ { "content": "\"\"\"Internal settings.\"\"\"\nimport os\nimport sys\nfrom gettext import gettext as _\n\nfrom gi.repository import GLib\n\nfrom lutris import __version__\nfrom lutris.util.settings import SettingsIO\n\nPROJECT = \"Lutris\"\nVERSION = __version__\nCOPYRIGHT = _(\"(c) 2010-2021 Lutris Team\")\nAUT...
diff --git a/lutris/settings.py b/lutris/settings.py index a43485b404..af97e4f7f7 100644 --- a/lutris/settings.py +++ b/lutris/settings.py @@ -23,7 +23,7 @@ GAME_CONFIG_DIR = os.path.join(CONFIG_DIR, "games") TMP_PATH = os.path.join(CACHE_DIR, "tmp") -BANNER_PATH = os.path.join(DATA_DIR, "banners") +BANNER_PATH = o...
gammapy__gammapy-5257
Writing `EventList` with `Observation.write` set `MJDREFI` and `MJDREFF` to 0 When one write an `EventList` with `Observation.write`, `MJDREFI` and `MJDREFF` are set to 0 in the header of the `EventList`. This obviously jeopardize the time of the written `EventList`. This behaviour originates from updating the hea...
[ { "content": "# Licensed under a 3-clause BSD style license - see LICENSE.rst\nimport collections.abc\nimport copy\nimport html\nimport inspect\nimport itertools\nimport logging\nimport warnings\nfrom itertools import zip_longest\nimport numpy as np\nimport astropy.units as u\nfrom astropy.coordinates import Sk...
[ { "content": "# Licensed under a 3-clause BSD style license - see LICENSE.rst\nimport collections.abc\nimport copy\nimport html\nimport inspect\nimport itertools\nimport logging\nimport warnings\nfrom itertools import zip_longest\nimport numpy as np\nimport astropy.units as u\nfrom astropy.coordinates import Sk...
diff --git a/gammapy/data/observations.py b/gammapy/data/observations.py index e36896b22b..339f817168 100644 --- a/gammapy/data/observations.py +++ b/gammapy/data/observations.py @@ -578,7 +578,9 @@ def write( events = self.events if events is not None: events_hdu = events.to_table_hdu(fo...
projectmesa__mesa-539
epstein_civil_violence box doesn't fit grid <img width="431" alt="screen shot 2018-04-01 at 10 05 11 pm" src="https://user-images.githubusercontent.com/166734/38180219-de2decf8-35f8-11e8-8d9b-562d2fb7c58b.png"> ^^ Fix the outline grid on this model. The grid should be the same size as the outline.
[ { "content": "from mesa.visualization.ModularVisualization import ModularServer\nfrom mesa.visualization.modules import CanvasGrid\n\nfrom .model import CivilViolenceModel\nfrom .agent import Citizen, Cop\n\n\nCOP_COLOR = \"#000000\"\nAGENT_QUIET_COLOR = \"#0066CC\"\nAGENT_REBEL_COLOR = \"#CC0000\"\nJAIL_COLOR ...
[ { "content": "from mesa.visualization.ModularVisualization import ModularServer\nfrom mesa.visualization.modules import CanvasGrid\n\nfrom .model import CivilViolenceModel\nfrom .agent import Citizen, Cop\n\n\nCOP_COLOR = \"#000000\"\nAGENT_QUIET_COLOR = \"#0066CC\"\nAGENT_REBEL_COLOR = \"#CC0000\"\nJAIL_COLOR ...
diff --git a/examples/epstein_civil_violence/civil_violence/server.py b/examples/epstein_civil_violence/civil_violence/server.py index 161e1f0e5c7..c5f710dfffa 100644 --- a/examples/epstein_civil_violence/civil_violence/server.py +++ b/examples/epstein_civil_violence/civil_violence/server.py @@ -43,6 +43,6 @@ def citiz...
sosreport__sos-471
[block] Don't use parted human readable output - rhbz #1183770 Changed the parted command to return data in sectors units instead of human readable form. Signed-off-by: Shane Bradley sbradley@redhat.com
[ { "content": "# 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 option) any later version.\n\n# This program is distributed in the hope th...
[ { "content": "# 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 option) any later version.\n\n# This program is distributed in the hope th...
diff --git a/sos/plugins/block.py b/sos/plugins/block.py index 7984f0d454..e02304c6bf 100644 --- a/sos/plugins/block.py +++ b/sos/plugins/block.py @@ -46,7 +46,7 @@ def setup(self): disk_path = os.path.join('/dev/', disk) self.add_cmd_output([ "udevadm info -ap /sy...
scikit-hep__pyhf-1546
Different ordering of channels between model.config.channels and mode.config.channel_nbins # Description We've recently observed that the ordering of channels outputted from `model.config.channels` differs from the order obtained with `model.config.channel_nbins`. This isn't really a bug, but more a quirk which we t...
[ { "content": "import logging\n\nlog = logging.getLogger(__name__)\n\n\nclass _ChannelSummaryMixin:\n \"\"\"\n A mixin that provides summary data of the provided channels.\n\n This mixin will forward all other information to other classes defined in the Child class.\n\n Args:\n **channels: A lis...
[ { "content": "import logging\n\nlog = logging.getLogger(__name__)\n\n\nclass _ChannelSummaryMixin:\n \"\"\"\n A mixin that provides summary data of the provided channels.\n\n This mixin will forward all other information to other classes defined in the Child class.\n\n Args:\n **channels: A lis...
diff --git a/src/pyhf/mixins.py b/src/pyhf/mixins.py index 01f3fc4265..077395fa14 100644 --- a/src/pyhf/mixins.py +++ b/src/pyhf/mixins.py @@ -42,6 +42,9 @@ def __init__(self, *args, **kwargs): self.samples = sorted(list(set(self.samples))) self.parameters = sorted(list(set(self.parameters))) ...
mozilla__bugbug-1214
Log number of spam/non-spam bugs in SpamBug get_labels
[ { "content": "# -*- coding: utf-8 -*-\n# 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 file,\n# You can obtain one at http://mozilla.org/MPL/2.0/.\n\nimport xgboost\nfrom imblearn.under_sampling import RandomUnderSample...
[ { "content": "# -*- coding: utf-8 -*-\n# 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 file,\n# You can obtain one at http://mozilla.org/MPL/2.0/.\n\nimport xgboost\nfrom imblearn.under_sampling import RandomUnderSample...
diff --git a/bugbug/models/spambug.py b/bugbug/models/spambug.py index 1e321c4de0..927b5554d4 100644 --- a/bugbug/models/spambug.py +++ b/bugbug/models/spambug.py @@ -85,6 +85,17 @@ def get_labels(self): ): classes[bug_id] = 1 + print( + "{} bugs are classified as non-s...
Lightning-AI__torchmetrics-1008
AttributeError while updating MetricCollection with prefix/postfix. When the metric collection object is initialized with either a prefix or a postfix (or both), updating throws an **AttributeError: 'MetricCollection' object has no attribute '{prefix}MetricKey{postfix}'**. This is unexpected because after initializat...
[ { "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 bb48353da98..87d037a23b7 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -62,6 +62,9 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - Fixed MAP metric when using custom list of thresholds ([#995](https://github.com/PyTorchLightning/met...
scikit-image__scikit-image-5236
feature.peak_local_max modifies input image ## Description Hi I am processing a float image (linked below) to detect peaks. When i call `feature.peak_local_max` without defining labels everything is fine. If I define labels the call to `feature.peak_local_max` causes a change in the intensity values (adding/changing...
[ { "content": "from warnings import warn\nimport numpy as np\nimport scipy.ndimage as ndi\nfrom .. import measure\nfrom .._shared.utils import remove_arg\nfrom .._shared.coord import ensure_spacing\n\n\ndef _get_high_intensity_peaks(image, mask, num_peaks, min_distance, p_norm):\n \"\"\"\n Return the highe...
[ { "content": "from warnings import warn\nimport numpy as np\nimport scipy.ndimage as ndi\nfrom .. import measure\nfrom .._shared.utils import remove_arg\nfrom .._shared.coord import ensure_spacing\n\n\ndef _get_high_intensity_peaks(image, mask, num_peaks, min_distance, p_norm):\n \"\"\"\n Return the highe...
diff --git a/skimage/feature/peak.py b/skimage/feature/peak.py index 5e2b8055a85..55d07d8d34d 100644 --- a/skimage/feature/peak.py +++ b/skimage/feature/peak.py @@ -281,7 +281,7 @@ def peak_local_max(image, min_distance=1, threshold_abs=None, # Get roi mask label_mask = labels[roi] == label_id...
huggingface__diffusers-5115
convert_original_stable_diffison script have issue https://github.com/huggingface/diffusers/blob/8263cf00f832399bca215e29fa7572e0b0bde4da/scripts/convert_original_stable_diffusion_to_diffusers.py#L157C9-L157C40 config_files command line argment is not include in this script. I think we need to add this code pars...
[ { "content": "# coding=utf-8\n# Copyright 2023 The HuggingFace Inc. 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#...
[ { "content": "# coding=utf-8\n# Copyright 2023 The HuggingFace Inc. 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#...
diff --git a/scripts/convert_original_stable_diffusion_to_diffusers.py b/scripts/convert_original_stable_diffusion_to_diffusers.py index bc4f06164c0e..2ca70963d132 100644 --- a/scripts/convert_original_stable_diffusion_to_diffusers.py +++ b/scripts/convert_original_stable_diffusion_to_diffusers.py @@ -35,6 +35,12 @@ ...
stephenmcd__mezzanine-1954
Small typo in mezzanine/core/auth_backends.py Should read verification rather than verficiation.
[ { "content": "from __future__ import unicode_literals\n\nfrom django.contrib.auth import get_user_model\nfrom django.contrib.auth.backends import ModelBackend\nfrom django.contrib.auth.tokens import default_token_generator\nfrom django.db.models import Q\nfrom django.utils.http import base36_to_int\n\n\nUser = ...
[ { "content": "from __future__ import unicode_literals\n\nfrom django.contrib.auth import get_user_model\nfrom django.contrib.auth.backends import ModelBackend\nfrom django.contrib.auth.tokens import default_token_generator\nfrom django.db.models import Q\nfrom django.utils.http import base36_to_int\n\n\nUser = ...
diff --git a/mezzanine/core/auth_backends.py b/mezzanine/core/auth_backends.py index c06444d4bb..4845caf45e 100644 --- a/mezzanine/core/auth_backends.py +++ b/mezzanine/core/auth_backends.py @@ -21,7 +21,7 @@ class MezzanineBackend(ModelBackend): For login, is_active is not given, so that the login form can r...
goauthentik__authentik-4778
OAuth sources seem to be linked to every account **Describe the bug** Opening user settings then going to "Connected services" seem to show everyone's connections instead of just the current authenticated user **To Reproduce** Steps to reproduce the behavior: 1. Login using existing user (User A) 2. Go to accoun...
[ { "content": "\"\"\"Source API Views\"\"\"\nfrom typing import Iterable\n\nfrom django_filters.rest_framework import DjangoFilterBackend\nfrom drf_spectacular.utils import OpenApiResponse, extend_schema\nfrom rest_framework import mixins\nfrom rest_framework.decorators import action\nfrom rest_framework.filters...
[ { "content": "\"\"\"Source API Views\"\"\"\nfrom typing import Iterable\n\nfrom django_filters.rest_framework import DjangoFilterBackend\nfrom drf_spectacular.utils import OpenApiResponse, extend_schema\nfrom rest_framework import mixins\nfrom rest_framework.decorators import action\nfrom rest_framework.filters...
diff --git a/authentik/core/api/sources.py b/authentik/core/api/sources.py index ffbdce1d12a4..7c3d5c435f75 100644 --- a/authentik/core/api/sources.py +++ b/authentik/core/api/sources.py @@ -206,5 +206,6 @@ class UserSourceConnectionViewSet( queryset = UserSourceConnection.objects.all() serializer_class = Use...
pyca__cryptography-5318
TypeError when calling asdict() on a dataclass containing Certificates * Versions: Python 3.7.4 with cryptography 2.8. * How you installed cryptography: via a Pipfile in my project I am using Python 3.7's dataclasses to pass around data, including certificates parsed using `cryptography.x509.load_pem_x509_certifica...
[ { "content": "# This file is dual licensed under the terms of the Apache License, Version\n# 2.0, and the BSD License. See the LICENSE file in the root of this repository\n# for complete details.\n\nfrom __future__ import absolute_import, division, print_function\n\nimport datetime\nimport operator\n\nfrom cryp...
[ { "content": "# This file is dual licensed under the terms of the Apache License, Version\n# 2.0, and the BSD License. See the LICENSE file in the root of this repository\n# for complete details.\n\nfrom __future__ import absolute_import, division, print_function\n\nimport datetime\nimport operator\n\nfrom cryp...
diff --git a/src/cryptography/hazmat/backends/openssl/x509.py b/src/cryptography/hazmat/backends/openssl/x509.py index efa4a8752761..9b3982707856 100644 --- a/src/cryptography/hazmat/backends/openssl/x509.py +++ b/src/cryptography/hazmat/backends/openssl/x509.py @@ -55,6 +55,9 @@ def __ne__(self, other): def __has...
getsentry__sentry-106
logging: __sentry__ isn't always callable acdha@0af552b18d72594b183b18834ba7245a1ff5ade1 contains a trivial "fix" to avoid crashing when handling a value which has `__sentry__` set to `None` but I haven't had time to learn what `__sentry__` is supposed to do. `logging` is configured exactly as in the documentation, the...
[ { "content": "import logging\nimport sys\nimport urllib\nimport urllib2\nimport uuid\n\nimport django\nfrom django.conf import settings\nfrom django.utils.encoding import force_unicode\nfrom django.utils.hashcompat import md5_constructor\n\nfrom sentry import conf\n\n_FILTER_CACHE = None\ndef get_filters():\n ...
[ { "content": "import logging\nimport sys\nimport urllib\nimport urllib2\nimport uuid\n\nimport django\nfrom django.conf import settings\nfrom django.utils.encoding import force_unicode\nfrom django.utils.hashcompat import md5_constructor\n\nfrom sentry import conf\n\n_FILTER_CACHE = None\ndef get_filters():\n ...
diff --git a/sentry/helpers.py b/sentry/helpers.py index a54eb2911c4940..4a84aa68a91354 100644 --- a/sentry/helpers.py +++ b/sentry/helpers.py @@ -76,7 +76,7 @@ def transform(value): return str(value) except: return to_unicode(value) - elif hasattr(value, '__sentry__'): + elif c...
pwr-Solaar__Solaar-2159
Distribution of 42-logitech-unify-permissions.rules I see `/usr/share/solaar/udev-rules.d/42-logitech-unify-permissions.rules` is installed by the setuptools packaging by default but it has to be installed/copied by user to e.g. `/usr/lib/udev/rules.d/42-logitech-unify-permissions.rules` for it to actually be useful an...
[ { "content": "#!/usr/bin/env python3\nimport subprocess\n\nfrom glob import glob as _glob\n\ntry:\n from setuptools import setup\nexcept ImportError:\n from distutils.core import setup\n\nNAME = 'Solaar'\n\nwith open('lib/solaar/version', 'r') as vfile:\n version = vfile.read().strip()\n\ntry: # get c...
[ { "content": "#!/usr/bin/env python3\nimport subprocess\n\nfrom glob import glob as _glob\n\ntry:\n from setuptools import setup\nexcept ImportError:\n from distutils.core import setup\n\nNAME = 'Solaar'\n\nwith open('lib/solaar/version', 'r') as vfile:\n version = vfile.read().strip()\n\ntry: # get c...
diff --git a/setup.py b/setup.py index ccb343a81a..8aa4f58874 100755 --- a/setup.py +++ b/setup.py @@ -39,7 +39,7 @@ def _data_files(): yield _dirname(mo), [mo] yield 'share/applications', ['share/applications/solaar.desktop'] - yield 'share/solaar/udev-rules.d', ['rules.d/42-logitech-unify-permissio...
encode__django-rest-framework-2981
ManyRelatedField.choices tries to iterate over None `ManyRelatedField.choices` is a `property` which [iterates over](https://github.com/tomchristie/django-rest-framework/blob/311cad64c998a89b8e8e2394140e0265ff98f53d/rest_framework/relations.py#L376-L383) `self.child_relation.queryset`. This can be `None` if `self.child...
[ { "content": "\"\"\"\nThe metadata API is used to allow customization of how `OPTIONS` requests\nare handled. We currently provide a single default implementation that returns\nsome fairly ad-hoc information about the view.\n\nFuture implementations might use JSON schema or other definitions in order\nto return...
[ { "content": "\"\"\"\nThe metadata API is used to allow customization of how `OPTIONS` requests\nare handled. We currently provide a single default implementation that returns\nsome fairly ad-hoc information about the view.\n\nFuture implementations might use JSON schema or other definitions in order\nto return...
diff --git a/rest_framework/metadata.py b/rest_framework/metadata.py index b2c48b816f..45f5b766d3 100644 --- a/rest_framework/metadata.py +++ b/rest_framework/metadata.py @@ -127,7 +127,7 @@ def get_field_info(self, field): if value is not None and value != '': field_info[attr] = force_tex...
jupyterhub__jupyterhub-2413
Is the /hub to /hub/ redirect useful? I get this from my hub pod of my z2jh deployment when I access `/` and have configured so I don't need to click on the "login with ..." button in order to login using `c.Authenticator.auto_login = True`. Is the `/hub` to `/hub/` doing something for us in some way or is it a mist...
[ { "content": "\"\"\"HTTP Handlers for the hub server\"\"\"\n\n# Copyright (c) Jupyter Development Team.\n# Distributed under the terms of the Modified BSD License.\n\nimport asyncio\nimport copy\nfrom datetime import datetime, timedelta\nfrom http.client import responses\nimport json\nimport math\nimport random...
[ { "content": "\"\"\"HTTP Handlers for the hub server\"\"\"\n\n# Copyright (c) Jupyter Development Team.\n# Distributed under the terms of the Modified BSD License.\n\nimport asyncio\nimport copy\nfrom datetime import datetime, timedelta\nfrom http.client import responses\nimport json\nimport math\nimport random...
diff --git a/jupyterhub/handlers/base.py b/jupyterhub/handlers/base.py index 30dc966c9e..729c0bad34 100644 --- a/jupyterhub/handlers/base.py +++ b/jupyterhub/handlers/base.py @@ -1068,6 +1068,10 @@ def get(self): path = self.request.uri[len(self.base_url):] else: path = self.request.p...
pulp__pulpcore-4011
RESTAPI document fix for Upstream Pulp Replication API **Version** Pulp installed through the Python modules. "core:3.28.0" "certguard:3.28.0" "file:3.28.0" "python:3.28.0" "rpm:3.28.0" **Describe the bug** Why the attributes of **upstream_pulps_create**/**update** is mentioned again in the **upstream_pulps_...
[ { "content": "\"\"\"\nViewSet for replicating repositories and distributions from an upstream Pulp\n\"\"\"\nfrom django.conf import settings\nfrom drf_spectacular.utils import extend_schema\nfrom rest_framework import mixins\nfrom rest_framework.decorators import action\n\nfrom pulpcore.app.models import TaskGr...
[ { "content": "\"\"\"\nViewSet for replicating repositories and distributions from an upstream Pulp\n\"\"\"\nfrom django.conf import settings\nfrom drf_spectacular.utils import extend_schema\nfrom rest_framework import mixins\nfrom rest_framework.decorators import action\n\nfrom pulpcore.app.models import TaskGr...
diff --git a/CHANGES/3995.bugfix b/CHANGES/3995.bugfix new file mode 100644 index 0000000000..acfdd5ad32 --- /dev/null +++ b/CHANGES/3995.bugfix @@ -0,0 +1 @@ +Fix api schema of the `upstream_pulp_replicate` operation requiring no body. diff --git a/pulpcore/app/viewsets/replica.py b/pulpcore/app/viewsets/replica.py in...
pulp__pulpcore-3996
RESTAPI document fix for Upstream Pulp Replication API **Version** Pulp installed through the Python modules. "core:3.28.0" "certguard:3.28.0" "file:3.28.0" "python:3.28.0" "rpm:3.28.0" **Describe the bug** Why the attributes of **upstream_pulps_create**/**update** is mentioned again in the **upstream_pulps_...
[ { "content": "\"\"\"\nViewSet for replicating repositories and distributions from an upstream Pulp\n\"\"\"\nfrom django.conf import settings\nfrom drf_spectacular.utils import extend_schema\nfrom rest_framework import mixins\nfrom rest_framework.decorators import action\n\nfrom pulpcore.app.models import TaskGr...
[ { "content": "\"\"\"\nViewSet for replicating repositories and distributions from an upstream Pulp\n\"\"\"\nfrom django.conf import settings\nfrom drf_spectacular.utils import extend_schema\nfrom rest_framework import mixins\nfrom rest_framework.decorators import action\n\nfrom pulpcore.app.models import TaskGr...
diff --git a/CHANGES/3995.bugfix b/CHANGES/3995.bugfix new file mode 100644 index 0000000000..acfdd5ad32 --- /dev/null +++ b/CHANGES/3995.bugfix @@ -0,0 +1 @@ +Fix api schema of the `upstream_pulp_replicate` operation requiring no body. diff --git a/pulpcore/app/viewsets/replica.py b/pulpcore/app/viewsets/replica.py in...
mitmproxy__mitmproxy-2155
cryptography dependency update? The template here wasn't relevant so I cut it, apologies. `mitmproxy` currently mandates `cryptography <1.8` which when built from source on macOS/OS X El Capitan (10.11) using Xcode 8 results in `Symbol not found: _getentropy` errors. Reported and explained in more detail [here](http...
[ { "content": "import os\nimport runpy\nfrom codecs import open\n\nfrom setuptools import setup, find_packages\n\n# Based on https://github.com/pypa/sampleproject/blob/master/setup.py\n# and https://python-packaging-user-guide.readthedocs.org/\n\nhere = os.path.abspath(os.path.dirname(__file__))\n\nwith open(os....
[ { "content": "import os\nimport runpy\nfrom codecs import open\n\nfrom setuptools import setup, find_packages\n\n# Based on https://github.com/pypa/sampleproject/blob/master/setup.py\n# and https://python-packaging-user-guide.readthedocs.org/\n\nhere = os.path.abspath(os.path.dirname(__file__))\n\nwith open(os....
diff --git a/setup.py b/setup.py index bbbac95e32..ecaea492be 100644 --- a/setup.py +++ b/setup.py @@ -64,7 +64,7 @@ "click>=6.2, <7", "certifi>=2015.11.20.1", # no semver here - this should always be on the last release! "construct>=2.8, <2.9", - "cryptography>=1.3, <1.8", + "...
napari__napari-5577
Dock Widgets are hidden when restoring minimized napari ## 🐛 Bug <!-- A clear and concise description of what the bug is. --> From https://forum.image.sc/t/dock-widgets-closing-when-minimizing-napari/59353/3 > When I am minimizing the napari window my dock widgets from plugins close as well and I have to reopen...
[ { "content": "import contextlib\nimport warnings\nfrom functools import reduce\nfrom itertools import count\nfrom operator import ior\nfrom typing import TYPE_CHECKING, List, Optional, Union\nfrom weakref import ReferenceType, ref\n\nfrom qtpy.QtCore import Qt\nfrom qtpy.QtWidgets import (\n QDockWidget,\n ...
[ { "content": "import contextlib\nimport warnings\nfrom functools import reduce\nfrom itertools import count\nfrom operator import ior\nfrom typing import TYPE_CHECKING, List, Optional, Union\nfrom weakref import ReferenceType, ref\n\nfrom qtpy.QtCore import Qt\nfrom qtpy.QtWidgets import (\n QDockWidget,\n ...
diff --git a/napari/_qt/widgets/qt_viewer_dock_widget.py b/napari/_qt/widgets/qt_viewer_dock_widget.py index 7ae0d743481..88028e63ec2 100644 --- a/napari/_qt/widgets/qt_viewer_dock_widget.py +++ b/napari/_qt/widgets/qt_viewer_dock_widget.py @@ -272,7 +272,6 @@ def _on_visibility_changed(self, visible): ...
facebookresearch__CompilerGym-735
Running autotuning fails with `Primary config directory not found.` ## 🐛 Bug When I tried running the auto tuning script, I get an error saying `Primary config directory not found`. See details below. ## To Reproduce Steps to reproduce the behavior: 1. Run `make install` from base directory to install from...
[ { "content": "#!/usr/bin/env python3\n#\n# Copyright (c) Facebook, Inc. and its affiliates.\n#\n# This source code is licensed under the MIT license found in the\n# LICENSE file in the root directory of this source tree.\n\nimport distutils.util\n\nimport setuptools\n\nwith open(\"../VERSION\") as f:\n versi...
[ { "content": "#!/usr/bin/env python3\n#\n# Copyright (c) Facebook, Inc. and its affiliates.\n#\n# This source code is licensed under the MIT license found in the\n# LICENSE file in the root directory of this source tree.\n\nimport distutils.util\n\nimport setuptools\n\nwith open(\"../VERSION\") as f:\n versi...
diff --git a/examples/llvm_autotuning/config/benchmarks/single_benchmark_for_testing.yaml b/examples/llvm_autotuning/config/benchmarks/single_benchmark_for_testing.yaml new file mode 100644 index 000000000..ae3139048 --- /dev/null +++ b/examples/llvm_autotuning/config/benchmarks/single_benchmark_for_testing.yaml @@ -0,...
instadeepai__Mava-808
[MAINTAIN] Set environment factory function based on executor or evaluator. ### Please describe what needs to be maintained? Set `evaluation` variable in environment factory based on if an executor or evaluator is in use. ### Describe the outcome you'd like Set `evaluation` variable in environment factory based on...
[ { "content": "# python3\n# Copyright 2021 InstaDeep Ltd. 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....
[ { "content": "# python3\n# Copyright 2021 InstaDeep Ltd. 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....
diff --git a/mava/components/building/environments.py b/mava/components/building/environments.py index 9d7419fc6..9b08b377b 100644 --- a/mava/components/building/environments.py +++ b/mava/components/building/environments.py @@ -115,7 +115,9 @@ def on_building_executor_environment(self, builder: SystemBuilder) -> None:...
mozilla__bugbug-1691
Timeout when the list of commits to analyze is empty We are analyzing all commits in that case, which makes the job timeout (it would take hours :D).
[ { "content": "# -*- coding: utf-8 -*-\n# 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 file,\n# You can obtain one at http://mozilla.org/MPL/2.0/.\n\nimport argparse\nimport concurrent.futures\nimport copy\nimport itert...
[ { "content": "# -*- coding: utf-8 -*-\n# 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 file,\n# You can obtain one at http://mozilla.org/MPL/2.0/.\n\nimport argparse\nimport concurrent.futures\nimport copy\nimport itert...
diff --git a/bugbug/repository.py b/bugbug/repository.py index d5892d6b5d..9bd95eed2e 100644 --- a/bugbug/repository.py +++ b/bugbug/repository.py @@ -1005,9 +1005,10 @@ def download_commits( with hglib.open(repo_dir) as hg: if revs is None: revs = get_revs(hg, rev_start) - if len(...
chainer__chainer-6050
Add chainerx.ndarray.item Background: #5797, #6007.
[ { "content": "import chainerx\nfrom chainerx import _docs\n\n\ndef set_docs():\n ndarray = chainerx.ndarray\n\n _docs.set_doc(\n ndarray,\n \"\"\"ndarray(shape, dtype, device=None)\nMulti-dimensional array, the central data structure of ChainerX.\n\nThis class, along with other APIs in the :...
[ { "content": "import chainerx\nfrom chainerx import _docs\n\n\ndef set_docs():\n ndarray = chainerx.ndarray\n\n _docs.set_doc(\n ndarray,\n \"\"\"ndarray(shape, dtype, device=None)\nMulti-dimensional array, the central data structure of ChainerX.\n\nThis class, along with other APIs in the :...
diff --git a/chainerx/_docs/array.py b/chainerx/_docs/array.py index d6b649b87556..0486450500fd 100644 --- a/chainerx/_docs/array.py +++ b/chainerx/_docs/array.py @@ -248,6 +248,19 @@ def binary_op(name, s): Returns ``True`` if the gradient will be set after backprop. See the note on :meth:`require_grad` for detail...
pypa__pip-11030
setup_requires with python_version conflicts with identical pyproject.toml build-system.requires ### Description If I create a new directory with two files, setup.cfg ```ini [options] setup_requires= cython >= 0.26, <0.27; python_version == "3.2" cython >= 0.29, <3.0; python_version >= "3.3" ``` and pyp...
[ { "content": "\"\"\"Build Environment used for isolation during sdist building\n\"\"\"\n\nimport contextlib\nimport logging\nimport os\nimport pathlib\nimport sys\nimport textwrap\nimport zipfile\nfrom collections import OrderedDict\nfrom sysconfig import get_paths\nfrom types import TracebackType\nfrom typing ...
[ { "content": "\"\"\"Build Environment used for isolation during sdist building\n\"\"\"\n\nimport contextlib\nimport logging\nimport os\nimport pathlib\nimport sys\nimport textwrap\nimport zipfile\nfrom collections import OrderedDict\nfrom sysconfig import get_paths\nfrom types import TracebackType\nfrom typing ...
diff --git a/news/10883.bugfix.rst b/news/10883.bugfix.rst new file mode 100644 index 00000000000..3807524c1ae --- /dev/null +++ b/news/10883.bugfix.rst @@ -0,0 +1,2 @@ +When checking for conflicts in the build environment, correctly skip requirements +containing markers that do not match the current environment. diff ...
pandas-dev__pandas-25925
Duplicate xstrtod implementations In _libs/src/parse_helper.h and libs/src/parser/tokenizer.c Not identical, comments suggest the tokenizer.c version may be more modern.
[ { "content": "#!/usr/bin/env python\n\n\"\"\"\nParts of this file were taken from the pyzmq project\n(https://github.com/zeromq/pyzmq) which have been permitted for use under the\nBSD license. Parts are from lxml (https://github.com/lxml/lxml)\n\"\"\"\n\nimport os\nfrom os.path import join as pjoin\n\nimport pk...
[ { "content": "#!/usr/bin/env python\n\n\"\"\"\nParts of this file were taken from the pyzmq project\n(https://github.com/zeromq/pyzmq) which have been permitted for use under the\nBSD license. Parts are from lxml (https://github.com/lxml/lxml)\n\"\"\"\n\nimport os\nfrom os.path import join as pjoin\n\nimport pk...
diff --git a/pandas/_libs/parsers.pyx b/pandas/_libs/parsers.pyx index 7a9db38957e94..a6512080eb428 100644 --- a/pandas/_libs/parsers.pyx +++ b/pandas/_libs/parsers.pyx @@ -187,9 +187,11 @@ cdef extern from "parser/tokenizer.h": int64_t skipfooter # pick one, depending on whether the converter require...
saulpw__visidata-1558
[zo] Give feedback when a file or URL is not found in the cell value New users (and me when I have a few z related `open-cell-XYZ` commands 🙃) may get confused at the purpose of `zo`, when it is usually `zENTER` they want. I propose the change, whereby a status is given to the user to tell them that a `file` or `UR...
[ { "content": "from visidata import *\n\n\nvd.option('filetype', '', 'specify file type', replay=True)\n\n\n@VisiData.api\ndef inputFilename(vd, prompt, *args, **kwargs):\n return vd.input(prompt, type=\"filename\", *args, completer=_completeFilename, **kwargs).strip()\n\n\n@VisiData.api\ndef inputPath(vd, *a...
[ { "content": "from visidata import *\n\n\nvd.option('filetype', '', 'specify file type', replay=True)\n\n\n@VisiData.api\ndef inputFilename(vd, prompt, *args, **kwargs):\n return vd.input(prompt, type=\"filename\", *args, completer=_completeFilename, **kwargs).strip()\n\n\n@VisiData.api\ndef inputPath(vd, *a...
diff --git a/visidata/_open.py b/visidata/_open.py index 6bbc293e8..1953527fa 100644 --- a/visidata/_open.py +++ b/visidata/_open.py @@ -132,4 +132,4 @@ def loadInternalSheet(vd, cls, p, **kwargs): BaseSheet.addCommand('o', 'open-file', 'vd.push(openSource(inputFilename("open: "), create=True))', 'Open file or URL...
internetarchive__openlibrary-7980
Update Merge Author UI to reflect current merge guidelines <!-- What problem are we solving? What does the experience look like today? What are the symptoms? --> At the moment, the Merge Authors page contradicts the merge documentation. As the information on the Merge Author page is repeatedly shown, librarians in tra...
[ { "content": "\"\"\"Merge authors.\n\"\"\"\nimport re\nimport json\nimport web\n\nfrom typing import Any\n\nfrom infogami.infobase.client import ClientException\nfrom infogami.utils import delegate\nfrom infogami.utils.view import render_template, safeint\nfrom openlibrary.accounts import get_current_user\nfrom...
[ { "content": "\"\"\"Merge authors.\n\"\"\"\nimport re\nimport json\nimport web\n\nfrom typing import Any\n\nfrom infogami.infobase.client import ClientException\nfrom infogami.utils import delegate\nfrom infogami.utils.view import render_template, safeint\nfrom openlibrary.accounts import get_current_user\nfrom...
diff --git a/openlibrary/plugins/upstream/merge_authors.py b/openlibrary/plugins/upstream/merge_authors.py index 055b0bc9566..853b27af83a 100644 --- a/openlibrary/plugins/upstream/merge_authors.py +++ b/openlibrary/plugins/upstream/merge_authors.py @@ -263,6 +263,9 @@ def GET(self): # filter bad keys ...
pypa__pip-3539
Invalid package name argument to `pip install` can output an IndexError `pip install -e git+` will yield: ``` Traceback (most recent call last): File "/PATH/site-packages/pip/basecommand.py", line 209, in main status = self.run(options, args) File "/PATH/site-packages/pip/commands/install.py", line 287, in run...
[ { "content": "from __future__ import absolute_import\n\nimport logging\nimport os\nimport re\nimport shutil\nimport sys\nimport tempfile\nimport traceback\nimport warnings\nimport zipfile\n\nfrom distutils import sysconfig\nfrom distutils.util import change_root\nfrom email.parser import FeedParser\n\nfrom pip....
[ { "content": "from __future__ import absolute_import\n\nimport logging\nimport os\nimport re\nimport shutil\nimport sys\nimport tempfile\nimport traceback\nimport warnings\nimport zipfile\n\nfrom distutils import sysconfig\nfrom distutils.util import change_root\nfrom email.parser import FeedParser\n\nfrom pip....
diff --git a/CHANGES.txt b/CHANGES.txt index f28fb9556e3..11f49eb3afb 100644 --- a/CHANGES.txt +++ b/CHANGES.txt @@ -14,6 +14,9 @@ * Decode requirement files according to their BOM if present (:pull:`3485`, :issue:`2865`). +* Fix and deprecate package name detection from url path (:issue:`3523` and + :pull:`3495...
frappe__frappe-13199
bug: Strip EXIF data throws error when using SVG file <!-- Welcome to the Frappe Framework issue tracker! Before creating an issue, please heed the following: 1. This tracker should only be used to report bugs and request features / enhancements to Frappe - For questions and general support, use https://stacko...
[ { "content": "# Copyright (c) 2015, Frappe Technologies Pvt. Ltd. and Contributors\n# MIT License. See license.txt\n\n\"\"\"\nrecord of files\n\nnaming for same name files: file.gif, file-1.gif, file-2.gif etc\n\"\"\"\n\nfrom __future__ import unicode_literals\n\nimport base64\nimport hashlib\nimport imghdr\nim...
[ { "content": "# Copyright (c) 2015, Frappe Technologies Pvt. Ltd. and Contributors\n# MIT License. See license.txt\n\n\"\"\"\nrecord of files\n\nnaming for same name files: file.gif, file-1.gif, file-2.gif etc\n\"\"\"\n\nfrom __future__ import unicode_literals\n\nimport base64\nimport hashlib\nimport imghdr\nim...
diff --git a/frappe/core/doctype/file/file.py b/frappe/core/doctype/file/file.py index 017106e6f592..d6923c001071 100755 --- a/frappe/core/doctype/file/file.py +++ b/frappe/core/doctype/file/file.py @@ -498,7 +498,7 @@ def save_file(self, content=None, decode=False, ignore_existing_file_check=False self.file_size = ...
jupyterhub__jupyterhub-2062
Redirect to login page broken when using baseUrl Freshly deployed vanilla hub using the zero2jupyterhub chart (v0.7-8b9cb79) on google cloud. None standard parts are that this uses an nginx-ingress to route traffic to the hub which is at example.com/foobar. http://example.com/foobar redirects to http://example.com/f...
[ { "content": "\"\"\"HTTP Handlers for the hub server\"\"\"\n\n# Copyright (c) Jupyter Development Team.\n# Distributed under the terms of the Modified BSD License.\n\nimport copy\nfrom datetime import datetime, timedelta\nfrom http.client import responses\nimport json\nimport math\nimport random\nimport re\nimp...
[ { "content": "\"\"\"HTTP Handlers for the hub server\"\"\"\n\n# Copyright (c) Jupyter Development Team.\n# Distributed under the terms of the Modified BSD License.\n\nimport copy\nfrom datetime import datetime, timedelta\nfrom http.client import responses\nimport json\nimport math\nimport random\nimport re\nimp...
diff --git a/jupyterhub/handlers/base.py b/jupyterhub/handlers/base.py index f5365d6a24..cb1711a144 100644 --- a/jupyterhub/handlers/base.py +++ b/jupyterhub/handlers/base.py @@ -901,6 +901,11 @@ class PrefixRedirectHandler(BaseHandler): """ def get(self): uri = self.request.uri + # Since self...
kornia__kornia-698
Enabled RandomResizedCrop batch mode when same_on_batch=False ### Description #680 The previous implementation would crop the same size then resize. This PR enabled different cropped sizes across the batch. <img width="1028" alt="Screenshot 2020-09-15 at 11 18 54 PM" src="https://user-images.githubusercontent....
[ { "content": "import warnings\n\nimport torch\nfrom typing import Tuple, Optional\n\nimport kornia\nfrom kornia.geometry.epipolar import normalize_points\n\nTupleTensor = Tuple[torch.Tensor, torch.Tensor]\n\n\ndef find_homography_dlt(\n points1: torch.Tensor, points2: torch.Tensor, weights: Optional[torc...
[ { "content": "import warnings\n\nimport torch\nfrom typing import Tuple, Optional\n\nimport kornia\nfrom kornia.geometry.epipolar import normalize_points\n\nTupleTensor = Tuple[torch.Tensor, torch.Tensor]\n\n\ndef find_homography_dlt(\n points1: torch.Tensor, points2: torch.Tensor, weights: Optional[torc...
diff --git a/kornia/geometry/homography.py b/kornia/geometry/homography.py index 916d5c9032..d9983636e9 100644 --- a/kornia/geometry/homography.py +++ b/kornia/geometry/homography.py @@ -47,7 +47,7 @@ def find_homography_dlt( else: # We should use provided weights assert len(weights.shape) == 2 a...
psychopy__psychopy-1325
psychopyApp won't start with Matplotlib 1.5 installed See http://discourse.psychopy.org/t/mac-specific-help/1540/3 We need to figure out - whether this problem is Anaconda-specific (and would require fixing upstream) - whether this problem is Mac-specific
[ { "content": "#!/usr/bin/env python2\n\n# Part of the PsychoPy library\n# Copyright (C) 2015 Jonathan Peirce\n# Distributed under the terms of the GNU General Public License (GPL).\n\nfrom __future__ import absolute_import, print_function\n\nimport sys\nfrom psychopy.app._psychopyApp import PsychoPyApp, __versi...
[ { "content": "#!/usr/bin/env python2\n\n# Part of the PsychoPy library\n# Copyright (C) 2015 Jonathan Peirce\n# Distributed under the terms of the GNU General Public License (GPL).\n\nfrom __future__ import absolute_import, print_function\n\nimport sys\nfrom psychopy.app._psychopyApp import PsychoPyApp, __versi...
diff --git a/psychopy/app/psychopyApp.py b/psychopy/app/psychopyApp.py index 7b53743064..ccce357b83 100755 --- a/psychopy/app/psychopyApp.py +++ b/psychopy/app/psychopyApp.py @@ -8,6 +8,8 @@ import sys from psychopy.app._psychopyApp import PsychoPyApp, __version__ +# fix OS X locale-bug on startup: sets locale to L...
getpelican__pelican-3094
A dead link on PyPI for the contributions and feedback I just stumbled upon [Pelican's page in PyPI](https://pypi.org/project/pelican/) and found that the l[ink for the contributions and feedback](https://pypi.org/project/pelican/CONTRIBUTING.rst) is dead. Perhaps, it needs to be updated?
[ { "content": "#!/usr/bin/env python\n\nfrom os import walk\nfrom os.path import join, relpath\n\nfrom setuptools import find_packages, setup\n\n\nversion = \"4.8.0\"\n\nrequires = ['feedgenerator >= 1.9', 'jinja2 >= 2.7', 'pygments',\n 'docutils>=0.15', 'pytz >= 0a', 'blinker', 'unidecode',\n ...
[ { "content": "#!/usr/bin/env python\n\nfrom os import walk\nfrom os.path import join, relpath\n\nfrom setuptools import find_packages, setup\n\n\nversion = \"4.8.0\"\n\nrequires = ['feedgenerator >= 1.9', 'jinja2 >= 2.7', 'pygments',\n 'docutils>=0.15', 'pytz >= 0a', 'blinker', 'unidecode',\n ...
diff --git a/setup.py b/setup.py index b88f59285..da038d244 100755 --- a/setup.py +++ b/setup.py @@ -25,6 +25,13 @@ README = open('README.rst', encoding='utf-8').read() CHANGELOG = open('docs/changelog.rst', encoding='utf-8').read() +# Relative links in the README must be converted to absolute URL's +# so that they...
sanic-org__sanic-819
Configs loaded from environmental variables aren't properly typed When setting configs using environmental variables `export SANIC_REQUEST_TIMEOUT=30` ``` app = Sanic(__name__) print(type(app.config.REQUEST_TIMEOUT)) # <class 'str'> ``` The problem is in this function ``` # .../sanic/config.py def loa...
[ { "content": "import os\nimport sys\nimport syslog\nimport platform\nimport types\n\nfrom sanic.log import DefaultFilter\n\nSANIC_PREFIX = 'SANIC_'\n\n_address_dict = {\n 'Windows': ('localhost', 514),\n 'Darwin': '/var/run/syslog',\n 'Linux': '/dev/log',\n 'FreeBSD': '/dev/log'\n}\n\nLOGGING = {\n ...
[ { "content": "import os\nimport sys\nimport syslog\nimport platform\nimport types\n\nfrom sanic.log import DefaultFilter\n\nSANIC_PREFIX = 'SANIC_'\n\n_address_dict = {\n 'Windows': ('localhost', 514),\n 'Darwin': '/var/run/syslog',\n 'Linux': '/dev/log',\n 'FreeBSD': '/dev/log'\n}\n\nLOGGING = {\n ...
diff --git a/sanic/config.py b/sanic/config.py index e3563bc183..f5649cfe99 100644 --- a/sanic/config.py +++ b/sanic/config.py @@ -201,4 +201,10 @@ def load_environment_vars(self): for k, v in os.environ.items(): if k.startswith(SANIC_PREFIX): _, config_key = k.split(SANIC_PREFIX,...
fidals__shopelectro-806
Adapt catalog models to the new Product-Position hierarhy. stb2 Created the new hierarhy at https://github.com/fidals/refarm-site/issues/261
[ { "content": "import enum\nimport random\nimport string\nimport typing\nfrom uuid import uuid4\n\nfrom django.conf import settings\nfrom django.db import models\nfrom django.urls import reverse\nfrom django.utils.translation import ugettext_lazy as _\n\nfrom catalog import models as catalog_models\nfrom ecommer...
[ { "content": "import enum\nimport random\nimport string\nimport typing\nfrom uuid import uuid4\n\nfrom django.conf import settings\nfrom django.db import models\nfrom django.urls import reverse\nfrom django.utils.translation import ugettext_lazy as _\n\nfrom catalog import models as catalog_models\nfrom ecommer...
diff --git a/requirements.txt b/requirements.txt index 898689e0..f8d26c02 100644 --- a/requirements.txt +++ b/requirements.txt @@ -25,4 +25,4 @@ sorl-thumbnail==12.5.0 python-telegram-bot==11.1.0 sentry-sdk==0.7.2 https://github.com/selwin/django-user_agents/archive/master.zip -https://github.com/fidals/refarm-site/...
Kinto__kinto-499
Explain in the doc how to disable default_buckets and bucket creation from authenticated users. From a discussion with @chrismbeckett on IRC: 1) Anyone can register for my application and get an auth token that allows them to login to Kinto. With personal buckets, someone could figure out how to start storing anything...
[ { "content": "import pkg_resources\nimport logging\n\nimport cliquet\nfrom pyramid.config import Configurator\nfrom pyramid.settings import asbool\nfrom pyramid.security import Authenticated\n\nfrom kinto.authorization import RouteFactory\n\n# Module version, as defined in PEP-0396.\n__version__ = pkg_resources...
[ { "content": "import pkg_resources\nimport logging\n\nimport cliquet\nfrom pyramid.config import Configurator\nfrom pyramid.settings import asbool\nfrom pyramid.security import Authenticated\n\nfrom kinto.authorization import RouteFactory\n\n# Module version, as defined in PEP-0396.\n__version__ = pkg_resources...
diff --git a/CHANGELOG.rst b/CHANGELOG.rst index 56058fe66..362d3be9c 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -38,6 +38,9 @@ Protocol is now version 1.4. See `API changelog <http://kinto.readthedocs.org/en on transaction rollback: most likely database storage operations. For irreversible operations se...
mit-ll-responsible-ai__hydra-zen-266
Building an inherited classmethod yields method from parent ```python class A: @classmethod def foo(cls): return cls.bar() @classmethod def bar(self): raise NotImplementedError() class B(A): @classmethod def bar(self): return 1 ``` ```python >>...
[ { "content": "# Copyright (c) 2022 Massachusetts Institute of Technology\n# SPDX-License-Identifier: MIT\nimport inspect\nimport sys\nimport warnings\nfrom dataclasses import MISSING, field as _field, is_dataclass\nfrom enum import Enum\nfrom typing import (\n Any,\n Callable,\n Dict,\n Iterable,\n ...
[ { "content": "# Copyright (c) 2022 Massachusetts Institute of Technology\n# SPDX-License-Identifier: MIT\nimport inspect\nimport sys\nimport warnings\nfrom dataclasses import MISSING, field as _field, is_dataclass\nfrom enum import Enum\nfrom typing import (\n Any,\n Callable,\n Dict,\n Iterable,\n ...
diff --git a/docs/source/changes.rst b/docs/source/changes.rst index 3be891da8..c6219f6bd 100644 --- a/docs/source/changes.rst +++ b/docs/source/changes.rst @@ -64,11 +64,15 @@ installed. (See :pull:`261`) Deprecations ------------ -:pull:`263` deprecates the ``builds_bases`` argument in ``make_custom_builds``. It ...
searxng__searxng-1944
[Bug] "Google" is missing a lot of results. **Version of SearXNG, commit number if you are using on master branch and stipulate if you forked SearXNG.** 2022.09.29-a7d69323 **What happened?** <!-- A clear and concise description of what the bug is. --> the Google engine is missing a lot of results. this is...
[ { "content": "# SPDX-License-Identifier: AGPL-3.0-or-later\n# lint: pylint\n\"\"\"This is the implementation of the google WEB engine. Some of this\nimplementations are shared by other engines:\n\n- :ref:`google images engine`\n- :ref:`google news engine`\n- :ref:`google videos engine`\n\nThe google WEB engine...
[ { "content": "# SPDX-License-Identifier: AGPL-3.0-or-later\n# lint: pylint\n\"\"\"This is the implementation of the google WEB engine. Some of this\nimplementations are shared by other engines:\n\n- :ref:`google images engine`\n- :ref:`google news engine`\n- :ref:`google videos engine`\n\nThe google WEB engine...
diff --git a/searx/engines/google.py b/searx/engines/google.py index 2f894b21fae..d77837c9e27 100644 --- a/searx/engines/google.py +++ b/searx/engines/google.py @@ -112,9 +112,9 @@ # specific xpath variables # ------------------------ -results_xpath = '//div[contains(@class, "MjjYud")]' -title_xpath = './/h3[1]' -h...
pulp__pulpcore-4151
BaseDownloader.fetch passes coroutine to asyncio.wait which is forbidden in python 3.11 Python 3.8 deprecated passing coroutines to `asyncio.wait` and Python 3.11 will now [raise an error](https://github.com/python/cpython/blob/a6313d78f21f79ca64dedd38e637509dc530a1b6/Lib/asyncio/tasks.py#L414C13-L414C13). This causes ...
[ { "content": "from gettext import gettext as _\n\nimport asyncio\nfrom collections import namedtuple\nimport logging\nimport os\nimport tempfile\nfrom urllib.parse import urlsplit\n\nfrom pulpcore.app import pulp_hashlib\nfrom pulpcore.app.loggers import deprecation_logger\nfrom pulpcore.app.models import Artif...
[ { "content": "from gettext import gettext as _\n\nimport asyncio\nfrom collections import namedtuple\nimport logging\nimport os\nimport tempfile\nfrom urllib.parse import urlsplit\n\nfrom pulpcore.app import pulp_hashlib\nfrom pulpcore.app.loggers import deprecation_logger\nfrom pulpcore.app.models import Artif...
diff --git a/CHANGES/4107.bugfix b/CHANGES/4107.bugfix new file mode 100644 index 0000000000..73fb394cc7 --- /dev/null +++ b/CHANGES/4107.bugfix @@ -0,0 +1 @@ +Updated the downloader's fetch method to comply with Python 3.11. diff --git a/pulpcore/download/base.py b/pulpcore/download/base.py index 649e3916d2..7c2204add...
pulp__pulpcore-4130
BaseDownloader.fetch passes coroutine to asyncio.wait which is forbidden in python 3.11 Python 3.8 deprecated passing coroutines to `asyncio.wait` and Python 3.11 will now [raise an error](https://github.com/python/cpython/blob/a6313d78f21f79ca64dedd38e637509dc530a1b6/Lib/asyncio/tasks.py#L414C13-L414C13). This causes ...
[ { "content": "from gettext import gettext as _\n\nimport asyncio\nfrom collections import namedtuple\nimport logging\nimport os\nimport tempfile\nfrom urllib.parse import urlsplit\n\nfrom pulpcore.app import pulp_hashlib\nfrom pulpcore.app.models import Artifact\nfrom pulpcore.exceptions import (\n DigestVal...
[ { "content": "from gettext import gettext as _\n\nimport asyncio\nfrom collections import namedtuple\nimport logging\nimport os\nimport tempfile\nfrom urllib.parse import urlsplit\n\nfrom pulpcore.app import pulp_hashlib\nfrom pulpcore.app.models import Artifact\nfrom pulpcore.exceptions import (\n DigestVal...
diff --git a/CHANGES/4107.bugfix b/CHANGES/4107.bugfix new file mode 100644 index 0000000000..73fb394cc7 --- /dev/null +++ b/CHANGES/4107.bugfix @@ -0,0 +1 @@ +Updated the downloader's fetch method to comply with Python 3.11. diff --git a/pulpcore/download/base.py b/pulpcore/download/base.py index 59223deac3..7bbaa4f4c...
pulp__pulpcore-4152
BaseDownloader.fetch passes coroutine to asyncio.wait which is forbidden in python 3.11 Python 3.8 deprecated passing coroutines to `asyncio.wait` and Python 3.11 will now [raise an error](https://github.com/python/cpython/blob/a6313d78f21f79ca64dedd38e637509dc530a1b6/Lib/asyncio/tasks.py#L414C13-L414C13). This causes ...
[ { "content": "from gettext import gettext as _\n\nimport asyncio\nfrom collections import namedtuple\nimport logging\nimport os\nimport tempfile\nfrom urllib.parse import urlsplit\n\nfrom pulpcore.app import pulp_hashlib\nfrom pulpcore.app.models import Artifact\nfrom pulpcore.exceptions import (\n DigestVal...
[ { "content": "from gettext import gettext as _\n\nimport asyncio\nfrom collections import namedtuple\nimport logging\nimport os\nimport tempfile\nfrom urllib.parse import urlsplit\n\nfrom pulpcore.app import pulp_hashlib\nfrom pulpcore.app.models import Artifact\nfrom pulpcore.exceptions import (\n DigestVal...
diff --git a/CHANGES/4107.bugfix b/CHANGES/4107.bugfix new file mode 100644 index 0000000000..73fb394cc7 --- /dev/null +++ b/CHANGES/4107.bugfix @@ -0,0 +1 @@ +Updated the downloader's fetch method to comply with Python 3.11. diff --git a/pulpcore/download/base.py b/pulpcore/download/base.py index 59223deac3..7bbaa4f4c...
getredash__redash-2062
More flexible widgets grid (allow finer control over height/width) ## User should be able to control widget's placement, width and height ### Current implementation Currently editing a dashboard works as follow: 1. When adding a widget you select its width: regular (half width) or double (full width). Height i...
[ { "content": "import json\n\nfrom flask import request\nfrom redash import models\nfrom redash.handlers.base import BaseResource\nfrom redash.permissions import (require_access,\n require_object_modify_permission,\n require_permission, view_only)\n\n...
[ { "content": "import json\n\nfrom flask import request\nfrom redash import models\nfrom redash.handlers.base import BaseResource\nfrom redash.permissions import (require_access,\n require_object_modify_permission,\n require_permission, view_only)\n\n...
diff --git a/client/.eslintrc.js b/client/.eslintrc.js index 54ff5bc79e..069966f2c0 100644 --- a/client/.eslintrc.js +++ b/client/.eslintrc.js @@ -19,6 +19,8 @@ module.exports = { "no-restricted-properties": "off", "no-restricted-globals": "off", "no-multi-assign": "off", + "no-lonely-if": "off", + ...
borgbackup__borg-6135
update pypi metadata master (1.2): alpha -> beta (and keep that at least until 1.2.1) 1.1-maint: definitely beta -> stable https://pypi.org/classifiers/
[ { "content": "# borgbackup - main setup code (see also other setup_*.py files)\n\nimport os\nimport sys\nfrom collections import defaultdict\nfrom glob import glob\n\ntry:\n import multiprocessing\nexcept ImportError:\n multiprocessing = None\n\nfrom setuptools.command.build_ext import build_ext\nfrom set...
[ { "content": "# borgbackup - main setup code (see also other setup_*.py files)\n\nimport os\nimport sys\nfrom collections import defaultdict\nfrom glob import glob\n\ntry:\n import multiprocessing\nexcept ImportError:\n multiprocessing = None\n\nfrom setuptools.command.build_ext import build_ext\nfrom set...
diff --git a/Vagrantfile b/Vagrantfile index 81cff36e77..2b58d6c636 100644 --- a/Vagrantfile +++ b/Vagrantfile @@ -160,7 +160,7 @@ def install_pythons(boxname) return <<-EOF . ~/.bash_profile pyenv install 3.10.0 # tests, version supporting openssl 1.1 - pyenv install 3.9.9 # tests, version supporting...
privacyidea__privacyidea-1946
More detailed description of splitAtSign We should have a more precise description how ``splitAtSign`` interacts with a given ``realm`` parameter. We should describe, that it works with ``/validate/`` and ``/auth`` endpoint. We can have a link for a more detailed description here: https://github.com/privacyidea/pr...
[ { "content": "# -*- coding: utf-8 -*-\n#\n# privacyIDEA documentation build configuration file, created by\n# sphinx-quickstart on Fri Jun 13 07:31:01 2014.\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 t...
[ { "content": "# -*- coding: utf-8 -*-\n#\n# privacyIDEA documentation build configuration file, created by\n# sphinx-quickstart on Fri Jun 13 07:31:01 2014.\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 t...
diff --git a/doc/_static/css/custom.css b/doc/_static/css/custom.css new file mode 100644 index 0000000000..af4310f32f --- /dev/null +++ b/doc/_static/css/custom.css @@ -0,0 +1,4 @@ + +#relate-user-to-a-realm table td { + white-space: nowrap; +} diff --git a/doc/conf.py b/doc/conf.py index 81322240bd..ebff99fcc8 100...
huggingface__diffusers-550
Question about flax model output classes For example here, it is using `from dataclasses import dataclass` https://github.com/huggingface/diffusers/blob/d8b0e4f433778f9d4555cfab642e43db3aff4833/src/diffusers/models/unet_2d_condition_flax.py#L22-L23 But transformers equivalents use `@flax.struct.dataclass`. For exam...
[ { "content": "from dataclasses import dataclass\nfrom typing import Tuple, Union\n\nimport flax.linen as nn\nimport jax\nimport jax.numpy as jnp\nfrom flax.core.frozen_dict import FrozenDict\n\nfrom ..configuration_utils import ConfigMixin, flax_register_to_config\nfrom ..modeling_flax_utils import FlaxModelMix...
[ { "content": "from typing import Tuple, Union\n\nimport flax\nimport flax.linen as nn\nimport jax\nimport jax.numpy as jnp\nfrom flax.core.frozen_dict import FrozenDict\n\nfrom ..configuration_utils import ConfigMixin, flax_register_to_config\nfrom ..modeling_flax_utils import FlaxModelMixin\nfrom ..utils impor...
diff --git a/src/diffusers/models/unet_2d_condition_flax.py b/src/diffusers/models/unet_2d_condition_flax.py index 1ac68e10c159..636a7ef9816a 100644 --- a/src/diffusers/models/unet_2d_condition_flax.py +++ b/src/diffusers/models/unet_2d_condition_flax.py @@ -1,6 +1,6 @@ -from dataclasses import dataclass from typing i...
pytorch__ignite-1145
ProgressBar does not close the bar on Colab if every is used ## 🐛 Bug description Progress bar is set with `common.setup_common_training_handlers(... log_every_iters=15, ...)` and it does not close itself as being not terminated ... <img width="451" alt="Screen Shot 2020-06-09 at 16 34 53" src="https://user-imag...
[ { "content": "# -*- coding: utf-8 -*-\nimport warnings\nfrom typing import Any, Mapping\n\nimport torch\n\nfrom ignite.contrib.handlers.base_logger import BaseLogger, BaseOutputHandler\nfrom ignite.engine import Engine, Events\nfrom ignite.engine.events import CallableEventWithFilter\n\n\nclass _OutputHandler(B...
[ { "content": "# -*- coding: utf-8 -*-\nimport warnings\nfrom typing import Any, Mapping\n\nimport torch\n\nfrom ignite.contrib.handlers.base_logger import BaseLogger, BaseOutputHandler\nfrom ignite.engine import Engine, Events\nfrom ignite.engine.events import CallableEventWithFilter\n\n\nclass _OutputHandler(B...
diff --git a/ignite/contrib/handlers/tqdm_logger.py b/ignite/contrib/handlers/tqdm_logger.py index 6697c3f2683f..9c5602acb389 100644 --- a/ignite/contrib/handlers/tqdm_logger.py +++ b/ignite/contrib/handlers/tqdm_logger.py @@ -199,6 +199,11 @@ def _reset(self, pbar_total): def _close(self, engine): if s...
huggingface__diffusers-1686
It is not possible to disable telemetry ### Describe the bug Although the DISABLE_TELEMETRY and HF_HUB_OFFLINE env variables exist, setting them doesn't actually seem to disable telemetry. https://github.com/huggingface/diffusers/blob/main/src/diffusers/hub_utils.py#L87 Pass is used, and /api/telemetry is prepen...
[ { "content": "# coding=utf-8\n# Copyright 2022 The HuggingFace Inc. 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#...
[ { "content": "# coding=utf-8\n# Copyright 2022 The HuggingFace Inc. 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#...
diff --git a/src/diffusers/hub_utils.py b/src/diffusers/hub_utils.py index fbf97ecb0f69..7f363587baf2 100644 --- a/src/diffusers/hub_utils.py +++ b/src/diffusers/hub_utils.py @@ -84,7 +84,7 @@ def send_telemetry(data: Dict, name: str): name: a unique name to differentiate the telemetry logs, e.g. "diffusers_ex...
gratipay__gratipay.com-3172
provide a way to browse/search teams I want to be able to easily find teams to contribute to. <bountysource-plugin> --- Want to back this issue? **[Place a bounty on it!](https://www.bountysource.com/issues/950213-gittip-com-teams?utm_campaign=plugin&utm_content=tracker%2F85909&utm_medium=issues&utm_source=github)**...
[ { "content": "# encoding: utf8\nfrom __future__ import print_function, unicode_literals\n\nfrom io import BytesIO\nimport re\nfrom unicodedata import combining, normalize\n\nfrom aspen.resources.pagination import parse_specline, split_and_escape\nfrom aspen.utils import utcnow\nfrom babel.core import LOCALE_ALI...
[ { "content": "# encoding: utf8\nfrom __future__ import print_function, unicode_literals\n\nfrom io import BytesIO\nimport re\nfrom unicodedata import combining, normalize\n\nfrom aspen.resources.pagination import parse_specline, split_and_escape\nfrom aspen.utils import utcnow\nfrom babel.core import LOCALE_ALI...
diff --git a/gratipay/utils/i18n.py b/gratipay/utils/i18n.py index b2990442dd..0b8b1c5930 100644 --- a/gratipay/utils/i18n.py +++ b/gratipay/utils/i18n.py @@ -182,8 +182,8 @@ def match_lang(languages): return LOCALE_EN -def format_currency_with_options(number, currency, locale='en', trailing_zeroes=True): - ...
InstaPy__InstaPy-5592
bot doesn't comment : "UnboundLocalError: local variable 'commenting_approved' referenced before assignment" ## Expected Behavior comment on post when activity is like_by_tags ## Current Behavior bot likes photo but exits with the following error when trying to comment: File "/Users/InstaPy-master/instapy/comme...
[ { "content": "# -*- coding: utf-8 -*-\n\"\"\" Module which handles the commenting features \"\"\"\n\nimport random\nimport emoji\n\nfrom .time_util import sleep\nfrom .util import update_activity\nfrom .util import add_user_to_blacklist\nfrom .util import click_element\nfrom .util import get_action_delay\nfrom ...
[ { "content": "# -*- coding: utf-8 -*-\n\"\"\" Module which handles the commenting features \"\"\"\n\nimport random\nimport emoji\n\nfrom .time_util import sleep\nfrom .util import update_activity\nfrom .util import add_user_to_blacklist\nfrom .util import click_element\nfrom .util import get_action_delay\nfrom ...
diff --git a/CHANGELOG.md b/CHANGELOG.md index 84ec21665..681a399dc 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,12 @@ The **goal** of this file is explaining to the users of our project the notable _The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to...
pyro-ppl__pyro-1206
Update paramstore documentation Params are not properly reused from the paramstore via `.load()` since the default flag `update_module_params` is false (iirc this is because of `random_module`). the interface/defaults should be revisited and at the very least, documentation updated. [source](https://forum.pyro.ai/t...
[ { "content": "from __future__ import absolute_import, division, print_function\n\nimport weakref\n\nimport torch\nfrom torch.distributions import constraints, transform_to\n\n\nclass ParamStoreDict(object):\n \"\"\"\n Global store for parameters in Pyro. This is basically a key-value store.\n The typic...
[ { "content": "from __future__ import absolute_import, division, print_function\n\nimport weakref\n\nimport torch\nfrom torch.distributions import constraints, transform_to\n\n\nclass ParamStoreDict(object):\n \"\"\"\n Global store for parameters in Pyro. This is basically a key-value store.\n The typic...
diff --git a/pyro/params/param_store.py b/pyro/params/param_store.py index 873e821c5b..3fac555c5f 100644 --- a/pyro/params/param_store.py +++ b/pyro/params/param_store.py @@ -174,6 +174,14 @@ def load(self, filename): """ Loads parameters from disk + .. note:: + + If using :meth:`py...
NVIDIA-Merlin__NVTabular-1587
[BUG] configure_tensorflow raises TypeError: expected string or bytes-like object in Horovod **Describe the bug** While trying to integrate Horovod's KerasEstimator w/ NVTabular, I'm seeing this error: ``` [1,0]<stderr>:/nvtabular/nvtabular/loader/tf_utils.py:53: UserWarning: TensorFlow runtime already initialized, ...
[ { "content": "#\n# Copyright (c) 2021, NVIDIA CORPORATION.\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 requ...
[ { "content": "#\n# Copyright (c) 2021, NVIDIA CORPORATION.\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 requ...
diff --git a/nvtabular/loader/tf_utils.py b/nvtabular/loader/tf_utils.py index 6c2d26e1f80..1c8c0b196e8 100644 --- a/nvtabular/loader/tf_utils.py +++ b/nvtabular/loader/tf_utils.py @@ -60,7 +60,7 @@ def configure_tensorflow(memory_allocation=None, device=None): ) except RuntimeError as e: ...
cupy__cupy-2299
nvcc absence warning could be removed On installing cupy from source, it is warned about absence of nvcc in `PATH`. But it is actually not required both during installation and on runtime. ``` ************************************************** *** WARNING: nvcc not in path. *** WARNING: Please set path...
[ { "content": "import contextlib\nimport distutils.util\nimport os\nimport re\nimport shutil\nimport subprocess\nimport sys\nimport tempfile\n\nfrom install import utils\n\n\nPLATFORM_DARWIN = sys.platform.startswith('darwin')\nPLATFORM_LINUX = sys.platform.startswith('linux')\nPLATFORM_WIN32 = sys.platform.star...
[ { "content": "import contextlib\nimport distutils.util\nimport os\nimport re\nimport shutil\nimport subprocess\nimport sys\nimport tempfile\n\nfrom install import utils\n\n\nPLATFORM_DARWIN = sys.platform.startswith('darwin')\nPLATFORM_LINUX = sys.platform.startswith('linux')\nPLATFORM_WIN32 = sys.platform.star...
diff --git a/install/build.py b/install/build.py index 1f36daab7f0..14df60208f5 100644 --- a/install/build.py +++ b/install/build.py @@ -41,10 +41,7 @@ def get_cuda_path(): nvcc_path = utils.search_on_path(('nvcc', 'nvcc.exe')) cuda_path_default = None - if nvcc_path is None: - utils.print_warning...
ranaroussi__yfinance-1528
ParserError('Error tokenizing data. ...') Hello, I am running Python 3.11.2 and Yfinance 0.2.18. I am trying to download historical data by executing the following line: yf.download(tickers="AAPL", start='2021-1-1', auto_adjust=True, threads=True) I am getting the following output (error): "- AAPL: Parse...
[ { "content": "#!/usr/bin/env python\n# -*- coding: utf-8 -*-\n#\n# yfinance - market data downloader\n# https://github.com/ranaroussi/yfinance\n#\n# Copyright 2017-2019 Ran Aroussi\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the ...
[ { "content": "#!/usr/bin/env python\n# -*- coding: utf-8 -*-\n#\n# yfinance - market data downloader\n# https://github.com/ranaroussi/yfinance\n#\n# Copyright 2017-2019 Ran Aroussi\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the ...
diff --git a/yfinance/utils.py b/yfinance/utils.py index b25deccd3..576872af7 100644 --- a/yfinance/utils.py +++ b/yfinance/utils.py @@ -940,7 +940,7 @@ def _migrate_cache_tkr_tz(self): if not _os.path.isfile(old_cache_file_path): return None try: - df = _pd.read_csv(old_cache_...
matrix-org__synapse-3724
GET /rooms/!whatever/event should be guest accessible as per https://github.com/matrix-org/matrix-doc/issues/1540#issuecomment-414379939
[ { "content": "# -*- coding: utf-8 -*-\n# Copyright 2014-2016 OpenMarket Ltd\n# Copyright 2018 New Vector Ltd\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...
[ { "content": "# -*- coding: utf-8 -*-\n# Copyright 2014-2016 OpenMarket Ltd\n# Copyright 2018 New Vector Ltd\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...
diff --git a/changelog.d/3724.feature b/changelog.d/3724.feature new file mode 100644 index 000000000000..1b374ccf4760 --- /dev/null +++ b/changelog.d/3724.feature @@ -0,0 +1 @@ +Allow guests to use /rooms/:roomId/event/:eventId diff --git a/synapse/rest/client/v1/room.py b/synapse/rest/client/v1/room.py index fcc10917...
google__jax-1063
jit inside pmap inside jit error Commenting out *either* of the `@jax.jit` decorators works, as does explicitly passing the `count` argument (e.g., `multi_step_pmap(u, 2)` ```python import jax.numpy as np import jax from jax import lax from functools import partial from jax.lib import xla_bridge device_count =...
[ { "content": "# Copyright 2018 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# https://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless required by applicab...
[ { "content": "# Copyright 2018 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# https://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless required by applicab...
diff --git a/jax/interpreters/pxla.py b/jax/interpreters/pxla.py index 4362c77ad3c0..9ff7a5bd3a29 100644 --- a/jax/interpreters/pxla.py +++ b/jax/interpreters/pxla.py @@ -399,6 +399,8 @@ def tuple_element_handler(axis_size, aval): xla.canonicalize_dtype_handlers[ShardedDeviceTuple] = \ xla.canonicalize_dtype_hand...
ibis-project__ibis-2401
remove requests dep https://github.com/ibis-project/ibis/pull/2385/files#r491220098 should just move the import inside
[ { "content": "\"\"\"File system module.\"\"\"\n# Copyright 2014 Cloudera 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#...
[ { "content": "\"\"\"File system module.\"\"\"\n# Copyright 2014 Cloudera 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#...
diff --git a/ibis/filesystems.py b/ibis/filesystems.py index fa4070da51f8..f4fbcd6291b1 100644 --- a/ibis/filesystems.py +++ b/ibis/filesystems.py @@ -19,8 +19,6 @@ import posixpath -import requests - import ibis.common.exceptions as com from ibis.config import options @@ -697,6 +695,8 @@ def hdfs_connect( ...
chainer__chainer-7529
test_init_docstring.py fail ``` C:\Path\To\chainer>py -3.7 -m pytest tests\chainer_tests\test_init_docstring.py ================================================= test session starts ================================================= platform win32 -- Python 3.7.3, pytest-4.1.1, py-1.8.0, pluggy-0.12.0 rootdir: C:\De...
[ { "content": "#!/usr/bin/env python\n\nimport os\nimport pkg_resources\nimport sys\n\nfrom setuptools import setup\n\nimport chainerx_build_helper\n\n\nif sys.version_info[:3] == (3, 5, 0):\n if not int(os.getenv('CHAINER_PYTHON_350_FORCE', '0')):\n msg = \"\"\"\nChainer does not work with Python 3.5....
[ { "content": "#!/usr/bin/env python\n\nimport os\nimport pkg_resources\nimport sys\n\nfrom setuptools import setup\n\nimport chainerx_build_helper\n\n\nif sys.version_info[:3] == (3, 5, 0):\n if not int(os.getenv('CHAINER_PYTHON_350_FORCE', '0')):\n msg = \"\"\"\nChainer does not work with Python 3.5....
diff --git a/setup.py b/setup.py index d988ab8edae2..0aa0e6f8eafb 100644 --- a/setup.py +++ b/setup.py @@ -28,11 +28,7 @@ 'typing_extensions', 'filelock', 'numpy>=1.9.0', - # protobuf 3.8.0rc1 causes CI errors. - # TODO(niboshi): Probably we should always use pip in CIs for - ...
internetarchive__openlibrary-6354
Tags are deleted/lost with line break <!-- What problem are we solving? What does the experience look like today? What are the symptoms? --> It's too easy to delete existing tags or lose new tags. If there is a line break in the tags, everything after the line break is deleted or not saved. ### Evidence / Screenshot ...
[ { "content": "\"\"\"Handlers for adding and editing books.\"\"\"\n\nimport web\nimport json\nimport csv\nimport datetime\n\nfrom infogami import config\nfrom infogami.core import code as core\nfrom infogami.core.db import ValidationException\nfrom infogami.utils import delegate\nfrom infogami.utils.view import ...
[ { "content": "\"\"\"Handlers for adding and editing books.\"\"\"\n\nimport web\nimport json\nimport csv\nimport datetime\n\nfrom infogami import config\nfrom infogami.core import code as core\nfrom infogami.core.db import ValidationException\nfrom infogami.utils import delegate\nfrom infogami.utils.view import ...
diff --git a/openlibrary/plugins/upstream/addbook.py b/openlibrary/plugins/upstream/addbook.py index 6433d468226..7725ec1453b 100644 --- a/openlibrary/plugins/upstream/addbook.py +++ b/openlibrary/plugins/upstream/addbook.py @@ -723,7 +723,7 @@ def read_subject(subjects): """ if not subjects: ...
secdev__scapy-1040
Problems while importing scapy on some environments (e.g. Eclipse, some peculiarly configured Windows boxes etc.) Scapy Version: v2.3.3-1008 System: Windows10 Python Version: 2.7.14 Updated (closed) issue: [#1029](https://github.com/secdev/scapy/issues/1029l) File: scapy/\_\_init\_\_.py There are a problems...
[ { "content": "## This file is part of Scapy\n## See http://www.secdev.org/projects/scapy for more informations\n## Copyright (C) Philippe Biondi <phil@secdev.org>\n## This program is published under a GPLv2 license\n\n\"\"\"\nScapy: create, send, sniff, dissect and manipulate network packets.\n\nUsable either f...
[ { "content": "## This file is part of Scapy\n## See http://www.secdev.org/projects/scapy for more informations\n## Copyright (C) Philippe Biondi <phil@secdev.org>\n## This program is published under a GPLv2 license\n\n\"\"\"\nScapy: create, send, sniff, dissect and manipulate network packets.\n\nUsable either f...
diff --git a/scapy/__init__.py b/scapy/__init__.py index 5db3f574a55..4f385780828 100644 --- a/scapy/__init__.py +++ b/scapy/__init__.py @@ -38,7 +38,7 @@ def _version_from_git_describe(): >>> _version_from_git_describe() '2.3.2.dev346' """ - if not os.path.isdir(os.path.join(_SCAPY_PKG_DIR, '...
streamlit__streamlit-6217
`CachedStFunctionWarning` incorrectly asks users to set `suppress_st_warning=True` when widget replay is disabled ### Checklist - [X] I have searched the [existing issues](https://github.com/streamlit/streamlit/issues) for similar issues. - [X] I added a very descriptive title to this issue. - [X] I have provided suff...
[ { "content": "# Copyright (c) Streamlit Inc. (2018-2022) Snowflake Inc. (2022)\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...
[ { "content": "# Copyright (c) Streamlit Inc. (2018-2022) Snowflake Inc. (2022)\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...
diff --git a/lib/streamlit/runtime/caching/cache_errors.py b/lib/streamlit/runtime/caching/cache_errors.py index 66b5bb4b29cf..e0bac3c3b9fc 100644 --- a/lib/streamlit/runtime/caching/cache_errors.py +++ b/lib/streamlit/runtime/caching/cache_errors.py @@ -115,8 +115,8 @@ def __init__( How to fix this: * Move the %(s...
bookwyrm-social__bookwyrm-995
Books with same title but different subtitle are hard to distinguish in TL **Is your feature request related to a problem? Please describe.** Sometimes a book series has the same title for all books but different subtitles. Example: [Saga: Book One](https://bookwyrm.social/book/39501), [Saga: Book Two](https://bookwyr...
[ { "content": "\"\"\" template filters \"\"\"\nfrom uuid import uuid4\n\nfrom django import template, utils\nfrom django.db.models import Avg\n\nfrom bookwyrm import models, views\nfrom bookwyrm.views.status import to_markdown\n\n\nregister = template.Library()\n\n\n@register.filter(name=\"dict_key\")\ndef dict_...
[ { "content": "\"\"\" template filters \"\"\"\nfrom uuid import uuid4\n\nfrom django import template, utils\nfrom django.db.models import Avg\n\nfrom bookwyrm import models, views\nfrom bookwyrm.views.status import to_markdown\n\n\nregister = template.Library()\n\n\n@register.filter(name=\"dict_key\")\ndef dict_...
diff --git a/bookwyrm/templates/snippets/book_titleby.html b/bookwyrm/templates/snippets/book_titleby.html index e561a8a330..80127fb729 100644 --- a/bookwyrm/templates/snippets/book_titleby.html +++ b/bookwyrm/templates/snippets/book_titleby.html @@ -1,7 +1,8 @@ {% load i18n %} +{% load bookwyrm_tags %} {% if book.au...
pydantic__pydantic-1849
Mypy complains about PyObject # Question Output of `python -c "import pydantic.utils; print(pydantic.utils.version_info())"`: ``` pydantic version: 1.4 pydantic compiled: False install path: /Users/slafs/.pyenv/versions/3.8.1/envs/tapper-core-py38/lib/python3.8/site-pack...
[ { "content": "import math\nimport re\nimport warnings\nfrom decimal import Decimal\nfrom enum import Enum\nfrom pathlib import Path\nfrom types import new_class\nfrom typing import (\n TYPE_CHECKING,\n Any,\n Callable,\n ClassVar,\n Dict,\n List,\n Optional,\n Pattern,\n Set,\n Typ...
[ { "content": "import math\nimport re\nimport warnings\nfrom decimal import Decimal\nfrom enum import Enum\nfrom pathlib import Path\nfrom types import new_class\nfrom typing import (\n TYPE_CHECKING,\n Any,\n Callable,\n ClassVar,\n Dict,\n List,\n Optional,\n Pattern,\n Set,\n Typ...
diff --git a/changes/1352-brianmaissy.md b/changes/1352-brianmaissy.md new file mode 100644 index 00000000000..f87b1cd4ae6 --- /dev/null +++ b/changes/1352-brianmaissy.md @@ -0,0 +1 @@ +Add a `__call__` stub to `PyObject` so that mypy will know that it is callable diff --git a/pydantic/types.py b/pydantic/types.py inde...
yt-project__yt-3086
FutureWarning from numpy ### Bug report **Bug summary** This is showing up on Jenkins (`yt_py38_git`), with two occurrences ``` yt.utilities.tests.test_minimal_representation.test_store ... yt : [INFO ] 2021-02-22 16:45:55,215 Parameters: current_time = 0.0060000200028298 yt : [INFO ] 2021-0...
[ { "content": "import base64\nimport builtins\nimport contextlib\nimport copy\nimport errno\nimport getpass\nimport glob\nimport inspect\nimport itertools\nimport os\nimport pdb\nimport re\nimport struct\nimport subprocess\nimport sys\nimport time\nimport traceback\nimport urllib.parse\nimport urllib.request\nim...
[ { "content": "import base64\nimport builtins\nimport contextlib\nimport copy\nimport errno\nimport getpass\nimport glob\nimport inspect\nimport itertools\nimport os\nimport pdb\nimport re\nimport struct\nimport subprocess\nimport sys\nimport time\nimport traceback\nimport urllib.parse\nimport urllib.request\nim...
diff --git a/yt/funcs.py b/yt/funcs.py index 15f3aaaa361..e5468d16cac 100644 --- a/yt/funcs.py +++ b/yt/funcs.py @@ -120,8 +120,8 @@ def compare_dicts(dict1, dict2): else: return False try: - comparison = (dict1[key] == dict2[key]).all() - exc...
vaexio__vaex-402
Print/repr of df fails after join I am encountering an issue in which i can not `display/print/repr` a DataFrame after join. I believe the join works successfully, you can view individual rows, and use their methods (`unique`, `value_counts` etc..) but not display the entire DataFrame. I tried, but I could not re...
[ { "content": "import logging\nimport os\n\nimport six\nimport numpy as np\n\non_rtd = os.environ.get('READTHEDOCS', None) == 'True'\nif not on_rtd:\n import vaex.strings\n\nlogger = logging.getLogger(\"vaex.column\")\n\n\nclass Column(object):\n def tolist(self):\n return self.to_numpy().tolist()\n...
[ { "content": "import logging\nimport os\n\nimport six\nimport numpy as np\n\non_rtd = os.environ.get('READTHEDOCS', None) == 'True'\nif not on_rtd:\n import vaex.strings\n\nlogger = logging.getLogger(\"vaex.column\")\n\n\nclass Column(object):\n def tolist(self):\n return self.to_numpy().tolist()\n...
diff --git a/packages/vaex-core/vaex/column.py b/packages/vaex-core/vaex/column.py index 38d587141d..a71db17b7b 100644 --- a/packages/vaex-core/vaex/column.py +++ b/packages/vaex-core/vaex/column.py @@ -74,7 +74,8 @@ def __init__(self, df, indices, name): self.dtype = self.df.dtype(name) self.shape = ...
OpenMined__PySyft-5384
Improving Dict Iterator creation ## Description Currently, if you trace it, we are making 4 remote `__len__` requests when creating a Dict/OrderedDict remote iterator. Ideally, we should stick to one. The same goes for any Iterator that is being created from Dict (`.values()`, `.items()`, etc). Snippet to reproduce...
[ { "content": "# stdlib\nimport inspect\nfrom types import ModuleType\nfrom typing import Any\nfrom typing import Callable as CallableT\nfrom typing import Dict\nfrom typing import Iterable\nfrom typing import List\nfrom typing import Optional\nfrom typing import Tuple\nfrom typing import Union\nimport warnings\...
[ { "content": "# stdlib\nimport inspect\nfrom types import ModuleType\nfrom typing import Any\nfrom typing import Callable as CallableT\nfrom typing import Dict\nfrom typing import Iterable\nfrom typing import List\nfrom typing import Optional\nfrom typing import Tuple\nfrom typing import Union\nimport warnings\...
diff --git a/src/syft/ast/klass.py b/src/syft/ast/klass.py index 152accf2ec8..a5b13163fae 100644 --- a/src/syft/ast/klass.py +++ b/src/syft/ast/klass.py @@ -232,6 +232,12 @@ def __iter__(self: Any) -> Iterable: attr_name = "__iter__" iter_target = attrs[attr_name] + + # skip if __iter__ has already been ...