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 ⌀ |
|---|---|---|---|---|
pymodbus-dev__pymodbus-1547 | AsyncModbusTcpClient never recovers after bad response
I have a modbus server that occasionally returns an invalid response to read-holding-registers, where the "number of bytes" number in the PDU is higher than the actual number of bytes in the response. AsyncModbusTcpClient reacts by disconnecting — which is fine — b... | [
{
"content": "\"\"\"Socket framer.\"\"\"\n# pylint: disable=missing-type-doc\nimport struct\n\nfrom pymodbus.exceptions import (\n InvalidMessageReceivedException,\n ModbusIOException,\n)\nfrom pymodbus.framer.base import SOCKET_FRAME_HEADER, ModbusFramer\nfrom pymodbus.logging import Log\n\n\n# ---------... | [
{
"content": "\"\"\"Socket framer.\"\"\"\n# pylint: disable=missing-type-doc\nimport struct\n\nfrom pymodbus.exceptions import (\n InvalidMessageReceivedException,\n ModbusIOException,\n)\nfrom pymodbus.framer.base import SOCKET_FRAME_HEADER, ModbusFramer\nfrom pymodbus.logging import Log\n\n\n# ---------... | diff --git a/pymodbus/framer/socket_framer.py b/pymodbus/framer/socket_framer.py
index d0569cc6b..043d2b0d6 100644
--- a/pymodbus/framer/socket_framer.py
+++ b/pymodbus/framer/socket_framer.py
@@ -176,6 +176,7 @@ def _process(self, callback, tid, error=False):
"""Process incoming packets irrespective error con... |
redis__redis-py-2063 | Add support for missing command CLUSTER MYID
| [
{
"content": "from typing import Iterator, Union\n\nfrom redis.crc import key_slot\nfrom redis.exceptions import RedisClusterException, RedisError\nfrom redis.typing import PatternT\n\nfrom .core import (\n ACLCommands,\n DataAccessCommands,\n FunctionCommands,\n ManagementCommands,\n PubSubComma... | [
{
"content": "from typing import Iterator, Union\n\nfrom redis.crc import key_slot\nfrom redis.exceptions import RedisClusterException, RedisError\nfrom redis.typing import PatternT\n\nfrom .core import (\n ACLCommands,\n DataAccessCommands,\n FunctionCommands,\n ManagementCommands,\n PubSubComma... | diff --git a/redis/commands/cluster.py b/redis/commands/cluster.py
index bcbfbd599d..c3d7bd6e49 100644
--- a/redis/commands/cluster.py
+++ b/redis/commands/cluster.py
@@ -275,6 +275,17 @@ class RedisClusterCommands(
r.cluster_info(target_nodes=RedisCluster.ALL_NODES)
"""
+ def cluster_myid(self, targ... |
DDMAL__CantusDB-1068 | Chant admin "Manuscript full text std spelling" widget is small
The Manuscript full text std spelling widget should be the same size as the Manuscript full text and Manuscript syllabized full text widgets below in the Admin chant detail page.
\nfrom .widgets import (\n ... | [
{
"content": "from django import forms\nfrom django.contrib.auth.forms import ReadOnlyPasswordHashField\nfrom .models import (\n Chant,\n Office,\n Genre,\n Notation,\n Feast,\n Source,\n RismSiglum,\n Segment,\n Provenance,\n Century,\n Sequence,\n)\nfrom .widgets import (\n ... | diff --git a/django/cantusdb_project/main_app/forms.py b/django/cantusdb_project/main_app/forms.py
index 77dfe0ed3..24c45d4ce 100644
--- a/django/cantusdb_project/main_app/forms.py
+++ b/django/cantusdb_project/main_app/forms.py
@@ -556,6 +556,12 @@ class Meta:
'the first word of each chant, and the first word... |
internetarchive__openlibrary-6487 | Combine Loans and Waitlist pages
We currently have loans and waitlists as separate items in the My Books sidebar:

As we add more items to this sidebar (Eg #6427 ), this it's getting a little messy. "Wait... | [
{
"content": "import web\nimport logging\nimport json\nimport re\n\nfrom infogami.utils import delegate\nfrom infogami import config\nfrom infogami.utils.view import (\n require_login,\n render,\n render_template,\n add_flash_message,\n)\n\nfrom infogami.infobase.client import ClientException\nfrom ... | [
{
"content": "import web\nimport logging\nimport json\nimport re\n\nfrom infogami.utils import delegate\nfrom infogami import config\nfrom infogami.utils.view import (\n require_login,\n render,\n render_template,\n add_flash_message,\n)\n\nfrom infogami.infobase.client import ClientException\nfrom ... | diff --git a/openlibrary/plugins/upstream/account.py b/openlibrary/plugins/upstream/account.py
index b05be6d1024..a30f939e25f 100644
--- a/openlibrary/plugins/upstream/account.py
+++ b/openlibrary/plugins/upstream/account.py
@@ -858,13 +858,8 @@ def GET(self):
class account_waitlist(delegate.page):
path = "/accou... |
kubeflow__pipelines-6240 | [v2 sample test] kaniko build times out / OOM
We've observed significantly high build time outs and OOMs with Kaniko recently.
I've tried several combinations:
1. 1.3.0-debug with/without --snapshotMode=redo + 4GB memory
2. 1.6.0-debug with/without --snapshotMode=redo + 8GB memory https://github.com/kubeflow/pipelin... | [
{
"content": "# Copyright 2021 The Kubeflow 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 b... | [
{
"content": "# Copyright 2021 The Kubeflow 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 b... | diff --git a/sdk/python/kfp/compiler/testdata/v2_compatible_two_step_pipeline.yaml b/sdk/python/kfp/compiler/testdata/v2_compatible_two_step_pipeline.yaml
index 4fdf0ba9439..22de8a1f99a 100644
--- a/sdk/python/kfp/compiler/testdata/v2_compatible_two_step_pipeline.yaml
+++ b/sdk/python/kfp/compiler/testdata/v2_compatibl... |
spacetelescope__jwql-465 | Import environment bokeh version in HTML
As described in #425, having the environment Bokeh version NOT match the HTML template Bokeh version can cause problems.
I wrote some tests #429 that will test and make sure this is always the case in the future, but we could be even smarter about this if we programmatically ... | [
{
"content": "\"\"\"Provides functions that define context inherent to all views.\n\nThe functions within this module define ``context`` that will be\nincluded in requests, in addition to any specific ``context`` provided\nin the view.\n\nAuthors\n-------\n\n - Matthew Bourque\n\nUse\n---\n\n This module ... | [
{
"content": "\"\"\"Provides functions that define context inherent to all views.\n\nThe functions within this module define ``context`` that will be\nincluded in requests, in addition to any specific ``context`` provided\nin the view.\n\nAuthors\n-------\n\n - Matthew Bourque\n\nUse\n---\n\n This module ... | diff --git a/jwql/website/apps/jwql/context_processors.py b/jwql/website/apps/jwql/context_processors.py
index 9cadcbea7..65c40d0db 100644
--- a/jwql/website/apps/jwql/context_processors.py
+++ b/jwql/website/apps/jwql/context_processors.py
@@ -23,6 +23,8 @@
As such, it will automatically be executed upon each req... |
pretix__pretix-862 | Add event name to admin notification
When recieving an admin notification, e.g. when an order is placed, only the order number is displayed in the mail. It would be great to also see the event, right now you have to look it up in the "Detail" button url.
I thought this could be an easy task by adding `n.add_attribut... | [
{
"content": "import logging\nfrom collections import OrderedDict, namedtuple\n\nfrom django.dispatch import receiver\nfrom django.utils.formats import date_format\nfrom django.utils.translation import ugettext_lazy as _\n\nfrom pretix.base.models import Event, LogEntry\nfrom pretix.base.signals import register... | [
{
"content": "import logging\nfrom collections import OrderedDict, namedtuple\n\nfrom django.dispatch import receiver\nfrom django.utils.formats import date_format\nfrom django.utils.translation import ugettext_lazy as _\n\nfrom pretix.base.models import Event, LogEntry\nfrom pretix.base.signals import register... | diff --git a/src/pretix/base/notifications.py b/src/pretix/base/notifications.py
index 01084d4821a..4eb8360efdf 100644
--- a/src/pretix/base/notifications.py
+++ b/src/pretix/base/notifications.py
@@ -174,6 +174,7 @@ def build_notification(self, logentry: LogEntry):
title=self._title.format(order=order, ev... |
fedora-infra__bodhi-1450 | There are multiple alembic heads on the develop branch
The migrations can't be applied on the develop branch because there are multiple alembic heads:
```
[vagrant@bodhi-dev bodhi]$ alembic upgrade head
/usr/lib64/python2.7/pkgutil.py:186: ImportWarning: Not importing directory '/usr/lib64/python2.7/site-packages/... | [
{
"content": "\"\"\"Convert the builds table to be polymorphic.\n\nRevision ID: 9241378c92ab\nRevises: fc6b0169c596\nCreate Date: 2017-04-06 20:37:24.766366\n\"\"\"\nfrom alembic import op\nimport sqlalchemy as sa\n\n\n# revision identifiers, used by Alembic.\nrevision = '9241378c92ab'\ndown_revision = 'fc6b016... | [
{
"content": "\"\"\"Convert the builds table to be polymorphic.\n\nRevision ID: 9241378c92ab\nRevises: 12d3e8695f90\nCreate Date: 2017-04-06 20:37:24.766366\n\"\"\"\nfrom alembic import op\nimport sqlalchemy as sa\n\n\n# revision identifiers, used by Alembic.\nrevision = '9241378c92ab'\ndown_revision = '12d3e86... | diff --git a/alembic/versions/9241378c92ab_convert_the_builds_table_to_be_.py b/alembic/versions/9241378c92ab_convert_the_builds_table_to_be_.py
index ccc51613d7..ac44f65b65 100644
--- a/alembic/versions/9241378c92ab_convert_the_builds_table_to_be_.py
+++ b/alembic/versions/9241378c92ab_convert_the_builds_table_to_be_.... |
django-cms__django-cms-3838 | {% placeholder %} still has a deprecation warning for width
Looking the releases, the [width deprecation warning](https://github.com/divio/django-cms/blob/2be1893021650b15d1b5dbbf07b55a85b12e95ea/cms/templatetags/cms_tags.py#L296) still exists, which has been there since [2.1.4](https://github.com/divio/django-cms/blob... | [
{
"content": "# -*- coding: utf-8 -*-\nfrom copy import copy\nfrom datetime import datetime\nfrom itertools import chain\nimport re\nfrom classytags.values import StringValue\nfrom cms.utils.urlutils import admin_reverse\n\nfrom django import template\nfrom django.conf import settings\nfrom django.contrib.sites... | [
{
"content": "# -*- coding: utf-8 -*-\nfrom copy import copy\nfrom datetime import datetime\nfrom itertools import chain\nimport re\nfrom classytags.values import StringValue\nfrom cms.utils.urlutils import admin_reverse\n\nfrom django import template\nfrom django.conf import settings\nfrom django.contrib.sites... | diff --git a/cms/templatetags/cms_tags.py b/cms/templatetags/cms_tags.py
index 60688815861..613b7d99777 100644
--- a/cms/templatetags/cms_tags.py
+++ b/cms/templatetags/cms_tags.py
@@ -273,8 +273,6 @@ class Placeholder(Tag):
Keyword arguments:
name -- the name of the placeholder
- width -- additional wid... |
yt-dlp__yt-dlp-3368 | Bandcamp - infinite loop failure for "merch"
### Checklist
- [X] I'm reporting a broken site
- [X] I've verified that I'm running yt-dlp version **2022.03.08.1** ([update instructions](https://github.com/yt-dlp/yt-dlp#update)) or later (specify commit)
- [X] I've checked that all provided URLs are alive and playable i... | [
{
"content": "import random\nimport re\nimport time\n\nfrom .common import InfoExtractor\nfrom ..compat import compat_str\nfrom ..utils import (\n ExtractorError,\n float_or_none,\n int_or_none,\n KNOWN_EXTENSIONS,\n parse_filesize,\n str_or_none,\n try_get,\n update_url_query,\n unif... | [
{
"content": "# coding: utf-8\nfrom __future__ import unicode_literals\n\nimport random\nimport re\nimport time\n\nfrom .common import InfoExtractor\nfrom ..compat import compat_str\nfrom ..utils import (\n ExtractorError,\n float_or_none,\n int_or_none,\n KNOWN_EXTENSIONS,\n parse_filesize,\n ... | diff --git a/yt_dlp/extractor/bandcamp.py b/yt_dlp/extractor/bandcamp.py
index 745055e2d520..5edd05e69480 100644
--- a/yt_dlp/extractor/bandcamp.py
+++ b/yt_dlp/extractor/bandcamp.py
@@ -439,7 +439,7 @@ def _real_extract(self, url):
uploader = self._match_id(url)
webpage = self._download_webpage(url, ... |
getredash__redash-2134 | Use can't download dataset before saving query
Because the query results url contains the query id, before saving the user can't download the dataset.
We need to allow addressing query results without query id.
| [
{
"content": "from flask_restful import Api\nfrom werkzeug.wrappers import Response\nfrom flask import make_response\n\nfrom redash.utils import json_dumps\nfrom redash.handlers.base import org_scoped_rule\nfrom redash.handlers.permissions import ObjectPermissionsListResource, CheckPermissionResource\nfrom reda... | [
{
"content": "from flask_restful import Api\nfrom werkzeug.wrappers import Response\nfrom flask import make_response\n\nfrom redash.utils import json_dumps\nfrom redash.handlers.base import org_scoped_rule\nfrom redash.handlers.permissions import ObjectPermissionsListResource, CheckPermissionResource\nfrom reda... | diff --git a/client/app/components/queries/query-results-link.js b/client/app/components/queries/query-results-link.js
index c1a1b12498..cccfa00b3c 100644
--- a/client/app/components/queries/query-results-link.js
+++ b/client/app/components/queries/query-results-link.js
@@ -13,8 +13,20 @@ function queryResultLink() {
... |
pandas-dev__pandas-14007 | DEPR: deprecate SparseList
| [
{
"content": "import numpy as np\nfrom pandas.core.base import PandasObject\nfrom pandas.formats.printing import pprint_thing\n\nfrom pandas.types.common import is_scalar\nfrom pandas.sparse.array import SparseArray\nimport pandas._sparse as splib\n\n\nclass SparseList(PandasObject):\n\n \"\"\"\n Data str... | [
{
"content": "import warnings\nimport numpy as np\nfrom pandas.core.base import PandasObject\nfrom pandas.formats.printing import pprint_thing\n\nfrom pandas.types.common import is_scalar\nfrom pandas.sparse.array import SparseArray\nimport pandas._sparse as splib\n\n\nclass SparseList(PandasObject):\n\n \"\... | diff --git a/doc/source/sparse.rst b/doc/source/sparse.rst
index 2496335dc7b71..db9734edde482 100644
--- a/doc/source/sparse.rst
+++ b/doc/source/sparse.rst
@@ -90,6 +90,8 @@ can be converted back to a regular ndarray by calling ``to_dense``:
SparseList
----------
+.. note:: The ``SparseList`` class has been deprec... |
ansible__ansible-16589 | OSError: [Errno 2] No such file or directory: xxx/ziploader_cache
##### ISSUE TYPE
- Bug Report
##### ANSIBLE VERSION
```
ansible 2.1.0.0
config file = /home/ansible/infra-ansible-configuration/ansible.cfg
configured module search path = Default w/o overrides
```
##### CONFIGURATION
```
[defaults]
host_key_checki... | [
{
"content": "# (c) 2012-2014, Michael DeHaan <michael.dehaan@gmail.com>\n#\n# This file is part of Ansible\n#\n# Ansible is free software: you can redistribute it and/or modify\n# it under the terms of the GNU General Public License as published by\n# the Free Software Foundation, either version 3 of the Licen... | [
{
"content": "# (c) 2012-2014, Michael DeHaan <michael.dehaan@gmail.com>\n#\n# This file is part of Ansible\n#\n# Ansible is free software: you can redistribute it and/or modify\n# it under the terms of the GNU General Public License as published by\n# the Free Software Foundation, either version 3 of the Licen... | diff --git a/lib/ansible/constants.py b/lib/ansible/constants.py
index 7a9f63ee28784a..6e70d3c0d8800b 100644
--- a/lib/ansible/constants.py
+++ b/lib/ansible/constants.py
@@ -76,7 +76,8 @@ def get_config(p, section, key, env_var, default, boolean=False, integer=False,
value = shell_expand(value)
... |
ansible-collections__community.general-2898 | pacman: pointless 'removed' state?
### Summary
https://docs.ansible.com/ansible/latest/collections/community/general/pacman_module.html
The 'state' parameter has two seemingly synonymous options - absent and removed.
removed is not used in any example.
https://github.com/ansible-collections/community.general/... | [
{
"content": "#!/usr/bin/python\n# -*- coding: utf-8 -*-\n\n# Copyright: (c) 2012, Afterburn <https://github.com/afterburn>\n# Copyright: (c) 2013, Aaron Bull Schaefer <aaron@elasticdog.com>\n# Copyright: (c) 2015, Indrajit Raychaudhuri <irc+code@indrajit.com>\n# GNU General Public License v3.0+ (see COPYING or... | [
{
"content": "#!/usr/bin/python\n# -*- coding: utf-8 -*-\n\n# Copyright: (c) 2012, Afterburn <https://github.com/afterburn>\n# Copyright: (c) 2013, Aaron Bull Schaefer <aaron@elasticdog.com>\n# Copyright: (c) 2015, Indrajit Raychaudhuri <irc+code@indrajit.com>\n# GNU General Public License v3.0+ (see COPYING or... | diff --git a/plugins/modules/packaging/os/pacman.py b/plugins/modules/packaging/os/pacman.py
index 859c90a6c47..372d13cd496 100644
--- a/plugins/modules/packaging/os/pacman.py
+++ b/plugins/modules/packaging/os/pacman.py
@@ -30,9 +30,12 @@
state:
description:
- - Desired state of the package.... |
bookwyrm-social__bookwyrm-1854 | User confirmation
**Describe the bug**
When a new user has not yet confirmed their email address, if the site settings change to disable email address confirmation, the user's status stays inactive and the code doesn't work.
**To Reproduce**
1. Site settings: email confirmation ON
2. Register new user
3. Do ... | [
{
"content": "\"\"\" the particulars for this instance of BookWyrm \"\"\"\nimport datetime\nfrom urllib.parse import urljoin\n\nfrom django.db import models, IntegrityError\nfrom django.dispatch import receiver\nfrom django.utils import timezone\nfrom model_utils import FieldTracker\n\nfrom bookwyrm.preview_ima... | [
{
"content": "\"\"\" the particulars for this instance of BookWyrm \"\"\"\nimport datetime\nfrom urllib.parse import urljoin\n\nfrom django.db import models, IntegrityError\nfrom django.dispatch import receiver\nfrom django.utils import timezone\nfrom model_utils import FieldTracker\n\nfrom bookwyrm.preview_ima... | diff --git a/bookwyrm/models/site.py b/bookwyrm/models/site.py
index 5d91553e3b..b2119e238a 100644
--- a/bookwyrm/models/site.py
+++ b/bookwyrm/models/site.py
@@ -90,6 +90,14 @@ def get_url(self, field, default_path):
return get_absolute_url(uploaded)
return urljoin(STATIC_FULL_URL, default_path)
... |
archlinux__archinstall-636 | tmpfs in fstab causing issues with some steam games
Hi!
I've used archinstall to install arch. (ext4 partition, grub, network manager, gnome DE).
I wanted to install Death stranding with proton via steam. The installation was stuck into a loop (steam was always saying that there were corrupt update files).
After... | [
{
"content": "from .disk import *\nfrom .hardware import *\nfrom .locale_helpers import verify_keyboard_layout, verify_x11_keyboard_layout\nfrom .mirrors import *\nfrom .plugins import plugins\nfrom .storage import storage\nfrom .user_interaction import *\n\n# Any package that the Installer() is responsible for... | [
{
"content": "from .disk import *\nfrom .hardware import *\nfrom .locale_helpers import verify_keyboard_layout, verify_x11_keyboard_layout\nfrom .mirrors import *\nfrom .plugins import plugins\nfrom .storage import storage\nfrom .user_interaction import *\n\n# Any package that the Installer() is responsible for... | diff --git a/archinstall/lib/installer.py b/archinstall/lib/installer.py
index 62dc933d80..2aac85100b 100644
--- a/archinstall/lib/installer.py
+++ b/archinstall/lib/installer.py
@@ -403,9 +403,6 @@ def minimal_installation(self):
self.pacstrap(self.base_packages)
self.helper_flags['base-strapped'] = True
- wi... |
apache__tvm-5870 | Some Windows and MSVC fixes
ref: https://github.com/apache/incubator-tvm/issues/4529
| [
{
"content": "# Licensed to the Apache Software Foundation (ASF) under one\n# or more contributor license agreements. See the NOTICE file\n# distributed with this work for additional information\n# regarding copyright ownership. The ASF licenses this file\n# to you under the Apache License, Version 2.0 (the\n... | [
{
"content": "# Licensed to the Apache Software Foundation (ASF) under one\n# or more contributor license agreements. See the NOTICE file\n# distributed with this work for additional information\n# regarding copyright ownership. The ASF licenses this file\n# to you under the Apache License, Version 2.0 (the\n... | diff --git a/python/tvm/_ffi/base.py b/python/tvm/_ffi/base.py
index 39d211bb4758..66a8927dc516 100644
--- a/python/tvm/_ffi/base.py
+++ b/python/tvm/_ffi/base.py
@@ -35,8 +35,13 @@
# this function is needed for python3
# to convert ctypes.char_p .value back to python str
if sys.platform == "win32":
- ... |
Lightning-AI__torchmetrics-1219 | `list index out of range` in `_sync_dist`
## 🐛 Bug
`list index out of range` out of range error when using a `list` state with a `default=[]`.
### To Reproduce
`self.add_state("p_true_positives", default=[], dist_reduce_fx="cat")`
when no value is added during update, it raises a list index out of range wh... | [
{
"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 d2a6b72ed20..3c8ba845fa1 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -69,6 +69,9 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
* Jaccard index ([#1205](https://github.com/Lightning-AI/metrics/pull/1205))
+- Fixed synchroniza... |
mdn__kuma-6143 | Require minium length for "explanation" field in BCD signals
**Summary**
_What should be changed?_
A minimum length of 10 characters should be required for the "explanation" field in BCD signals
**Rationale**
_What problems would this solve?_
Less spam submissions
**Audience**
_Who would use this changed fea... | [
{
"content": "from rest_framework import exceptions\nfrom rest_framework import serializers\n\nfrom kuma.wiki.models import BCSignal, Document\n\n\nclass BCSignalSerializer(serializers.Serializer):\n feature = serializers.CharField(max_length=255)\n browsers = serializers.CharField(max_length=255)\n sl... | [
{
"content": "from rest_framework import exceptions\nfrom rest_framework import serializers\n\nfrom kuma.wiki.models import BCSignal, Document\n\n\nclass BCSignalSerializer(serializers.Serializer):\n feature = serializers.CharField(max_length=255)\n browsers = serializers.CharField(max_length=255)\n sl... | diff --git a/kuma/api/v1/serializers.py b/kuma/api/v1/serializers.py
index 06aac7e496f..534de6e03d6 100644
--- a/kuma/api/v1/serializers.py
+++ b/kuma/api/v1/serializers.py
@@ -9,7 +9,11 @@ class BCSignalSerializer(serializers.Serializer):
browsers = serializers.CharField(max_length=255)
slug = serializers.Ch... |
piskvorky__gensim-2618 | Dictionary gensim.corpora should update the collection frequencies cfs after filtering with filter_extremes
#### Problem description
I am using the Dictionary class gensim.corpora.dictionary.Dictionary , in particular the filter_extremes method and the cfs property (returning a collection frequencies dictionary mapp... | [
{
"content": "#!/usr/bin/env python\n# -*- coding: utf-8 -*-\n#\n# Copyright (C) 2010 Radim Rehurek <radimrehurek@seznam.cz>\n# Licensed under the GNU LGPL v2.1 - http://www.gnu.org/licenses/lgpl.html\n\n\"\"\"This module implements the concept of a Dictionary -- a mapping between words and their integer ids.\"... | [
{
"content": "#!/usr/bin/env python\n# -*- coding: utf-8 -*-\n#\n# Copyright (C) 2010 Radim Rehurek <radimrehurek@seznam.cz>\n# Licensed under the GNU LGPL v2.1 - http://www.gnu.org/licenses/lgpl.html\n\n\"\"\"This module implements the concept of a Dictionary -- a mapping between words and their integer ids.\"... | diff --git a/gensim/corpora/dictionary.py b/gensim/corpora/dictionary.py
index 229d28d2c9..2ba296b115 100644
--- a/gensim/corpora/dictionary.py
+++ b/gensim/corpora/dictionary.py
@@ -472,6 +472,7 @@ def compactify(self):
self.token2id = {token: idmap[tokenid] for token, tokenid in iteritems(self.token2id)}
... |
mlcommons__GaNDLF-429 | Add an error check for compute dimensions not supported by GaNDLF
### > I think the error message is caused by the yaml file. My input image size is 128 x 128 .
>
**> this is error mesage :**
`(venv_gandlf) C:\Users\pc\GaNDLF>python gandlf_run -c ./images_and_labels/model.yaml -i ./images_and_labels/train.csv... | [
{
"content": "# -*- coding: utf-8 -*-\n\"\"\"All Models in GANDLF are to be derived from this base class code.\"\"\"\n\nimport torch\nimport torch.nn as nn\nimport torch.nn.functional as F\n\nfrom GANDLF.utils import get_linear_interpolation_mode\nfrom GANDLF.utils.modelbase import get_modelbase_final_layer\nfr... | [
{
"content": "# -*- coding: utf-8 -*-\n\"\"\"All Models in GANDLF are to be derived from this base class code.\"\"\"\n\nimport torch\nimport torch.nn as nn\nimport torch.nn.functional as F\n\nfrom GANDLF.utils import get_linear_interpolation_mode\nfrom GANDLF.utils.modelbase import get_modelbase_final_layer\nfr... | diff --git a/GANDLF/models/modelBase.py b/GANDLF/models/modelBase.py
index b1719b02c..7a6747c82 100644
--- a/GANDLF/models/modelBase.py
+++ b/GANDLF/models/modelBase.py
@@ -78,6 +78,13 @@ def __init__(self, parameters):
self.GlobalAvgPool = GlobalAveragePooling3D
self.Norm = self.get_norm_type... |
kubeflow__pipelines-3108 | [Bug] Deploying 'metadata' from KFP manifests breaks KF Metadata
I'm testing the `metadata-writer` component locally, on an existing KF v0.7 (MiniKF on GCP).
First of all, it is a great service and looks pretty useful.
So, I deployed it using the manifests in this repo ([manifests/kustomize](https://github.com/kube... | [
{
"content": "# Copyright 2019 Google LLC\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# http://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless required by applicab... | [
{
"content": "# Copyright 2019 Google LLC\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# http://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless required by applicab... | diff --git a/backend/metadata_writer/src/metadata_helpers.py b/backend/metadata_writer/src/metadata_helpers.py
index 805a7f85a69..b42aac4d70e 100644
--- a/backend/metadata_writer/src/metadata_helpers.py
+++ b/backend/metadata_writer/src/metadata_helpers.py
@@ -21,8 +21,10 @@
def connect_to_mlmd() -> metadata_store... |
spotify__luigi-3216 | using default_scheduler_url as a mounting point (not root `http://address/mount`) behind proxy not working
<!---
We use GitHub issues mainly for tracking bugs and feature requests.
Questions for how to use luigi can be sent to the mailing list.
Currently, there are no strict procedures or guidelines for submittin... | [
{
"content": "# -*- coding: utf-8 -*-\n#\n# Copyright 2012-2015 Spotify AB\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# http://www.apache.org/licenses/LICENSE-2.0\n#\n#... | [
{
"content": "# -*- coding: utf-8 -*-\n#\n# Copyright 2012-2015 Spotify AB\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# http://www.apache.org/licenses/LICENSE-2.0\n#\n#... | diff --git a/luigi/rpc.py b/luigi/rpc.py
index 2066cbbc62..d5215e78ae 100644
--- a/luigi/rpc.py
+++ b/luigi/rpc.py
@@ -55,11 +55,12 @@ def _urljoin(base, url):
"""
Join relative URLs to base URLs like urllib.parse.urljoin but support
arbitrary URIs (esp. 'http+unix://').
+ base part is fixed or mounte... |
beetbox__beets-2601 | importadded: ValueError on trying to import a large library
After migrating my music to a new drive, I'm trying to update the beets library. I've first run `beet update` so beets flushes out the old files, and I'm now running `beet import -AC .` to import the new files. Along the way, I've seen this error show up a cou... | [
{
"content": "# -*- coding: utf-8 -*-\n\n\"\"\"Populate an item's `added` and `mtime` fields by using the file\nmodification time (mtime) of the item's source file before import.\n\nReimported albums and items are skipped.\n\"\"\"\nfrom __future__ import division, absolute_import, print_function\n\nimport os\n\... | [
{
"content": "# -*- coding: utf-8 -*-\n\n\"\"\"Populate an item's `added` and `mtime` fields by using the file\nmodification time (mtime) of the item's source file before import.\n\nReimported albums and items are skipped.\n\"\"\"\nfrom __future__ import division, absolute_import, print_function\n\nimport os\n\... | diff --git a/beetsplug/importadded.py b/beetsplug/importadded.py
index c1838884ba..36407b14c6 100644
--- a/beetsplug/importadded.py
+++ b/beetsplug/importadded.py
@@ -30,8 +30,8 @@ def __init__(self):
self.item_mtime = dict()
register = self.register_listener
- register('import_task_start', s... |
pymedusa__Medusa-4445 | [APP SUBMITTED]: ValueError: max() arg is an empty sequence
### INFO
**Python Version**: `2.7.14 (default, May 28 2018, 14:47:18) [GCC 4.7.3 20130102 (prerelease)]`
**Operating System**: `Linux-3.10.102-x86_64-with-glibc2.2.5`
**Locale**: `UTF-8`
**Branch**: [master](../tree/master)
**Database**: `44.11`
**Commit**: p... | [
{
"content": "# coding=utf-8\n\n\"\"\"TVDB2 api module.\"\"\"\nfrom __future__ import unicode_literals\n\nimport logging\nfrom collections import OrderedDict\n\nfrom medusa import app\nfrom medusa.app import TVDB_API_KEY\nfrom medusa.helper.metadata import needs_metadata\nfrom medusa.indexers.indexer_base impor... | [
{
"content": "# coding=utf-8\n\n\"\"\"TVDB2 api module.\"\"\"\nfrom __future__ import unicode_literals\n\nimport logging\nfrom collections import OrderedDict\n\nfrom medusa import app\nfrom medusa.app import TVDB_API_KEY\nfrom medusa.helper.metadata import needs_metadata\nfrom medusa.indexers.indexer_base impor... | diff --git a/medusa/indexers/tvdbv2/tvdbv2_api.py b/medusa/indexers/tvdbv2/tvdbv2_api.py
index fd567dbc88..f925b7ffa7 100644
--- a/medusa/indexers/tvdbv2/tvdbv2_api.py
+++ b/medusa/indexers/tvdbv2/tvdbv2_api.py
@@ -633,7 +633,7 @@ def get_last_updated_series(self, from_time, weeks=1, filter_show_list=None):
tr... |
jumpserver__jumpserver-138 | change(version num) change jumpserver version
from 0.3.0 -> 0.3.1
| [
{
"content": "import datetime\n\nfrom django.db import models\nfrom jasset.models import Asset, AssetGroup\nfrom juser.models import User, UserGroup\n\n\nclass PermLog(models.Model):\n datetime = models.DateTimeField(auto_now_add=True)\n action = models.CharField(max_length=100, null=True, blank=True, def... | [
{
"content": "import datetime\n\nfrom django.db import models\nfrom jasset.models import Asset, AssetGroup\nfrom juser.models import User, UserGroup\n\n\nclass PermLog(models.Model):\n datetime = models.DateTimeField(auto_now_add=True)\n action = models.CharField(max_length=100, null=True, blank=True, def... | diff --git a/jperm/models.py b/jperm/models.py
index 425d0141010f..0ba12354a58d 100644
--- a/jperm/models.py
+++ b/jperm/models.py
@@ -26,7 +26,7 @@ def __unicode__(self):
class PermRole(models.Model):
name = models.CharField(max_length=100, unique=True)
comment = models.CharField(max_length=100, null=True, ... |
elastic__apm-agent-python-1492 | Reduce default stack_trace_limit from 500 to 50
Looking through the [config docs](https://docs.google.com/spreadsheets/d/1JJjZotapacA3FkHc2sv_0wiChILi3uKnkwLTjtBmxwU/edit#gid=0&range=A63), all other agents set the default limit to 50.
Setting a modest limit for the stack traces is important for APM Server to avoid o... | [
{
"content": "# BSD 3-Clause License\n#\n# Copyright (c) 2012, the Sentry Team, see AUTHORS for more details\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 c... | [
{
"content": "# BSD 3-Clause License\n#\n# Copyright (c) 2012, the Sentry Team, see AUTHORS for more details\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 c... | diff --git a/CHANGELOG.asciidoc b/CHANGELOG.asciidoc
index 0ff161795..60692b012 100644
--- a/CHANGELOG.asciidoc
+++ b/CHANGELOG.asciidoc
@@ -43,6 +43,7 @@ endif::[]
* Fix Sanic integration to properly respect the `capture_body` config {pull}1485[#1485]
* Lambda fixes to align with the cross-agent spec {pull}1489[#1... |
nautobot__nautobot-1904 | CustomField default value populated in filterform
<!--
NOTE: IF YOUR ISSUE DOES NOT FOLLOW THIS TEMPLATE, IT WILL BE CLOSED.
This form is only for reporting reproducible bugs. If you need assistance
with Nautobot installation, or if you have a general question, please start a
discussion instead: h... | [
{
"content": "from django import forms\nfrom django.contrib.auth import get_user_model\nfrom django.contrib.contenttypes.models import ContentType\nfrom django.core.exceptions import ValidationError\nfrom django.db.models import Q\nfrom django.db.models.fields import TextField\nfrom django.forms import ModelMul... | [
{
"content": "from django import forms\nfrom django.contrib.auth import get_user_model\nfrom django.contrib.contenttypes.models import ContentType\nfrom django.core.exceptions import ValidationError\nfrom django.db.models import Q\nfrom django.db.models.fields import TextField\nfrom django.forms import ModelMul... | diff --git a/nautobot/extras/forms.py b/nautobot/extras/forms.py
index c05f2e22d55..a25f20b778c 100644
--- a/nautobot/extras/forms.py
+++ b/nautobot/extras/forms.py
@@ -601,10 +601,10 @@ def __init__(self, *args, **kwargs):
field_name = "cf_{}".format(cf.name)
if cf.type == "json":
... |
PaddlePaddle__models-477 | text_classification reader error
Get follow error log while running `train.py` of text_classification model:
```
[INFO 2017-11-16 17:19:51,458 train.py:44] please wait to build the word dictionary ...
[INFO 2017-11-16 17:20:07,138 train.py:101] length of word dictionary is : 5147.
I1116 17:20:07.168130 24638 Util... | [
{
"content": "import os\nimport sys\nimport gzip\n\nimport paddle.v2 as paddle\n\nimport reader\nfrom utils import logger, parse_train_cmd, build_dict, load_dict\nfrom network_conf import fc_net, convolution_net\n\n\ndef train(topology,\n train_data_dir=None,\n test_data_dir=None,\n w... | [
{
"content": "import os\nimport sys\nimport gzip\n\nimport paddle.v2 as paddle\n\nimport reader\nfrom utils import logger, parse_train_cmd, build_dict, load_dict\nfrom network_conf import fc_net, convolution_net\n\n\ndef train(topology,\n train_data_dir=None,\n test_data_dir=None,\n w... | diff --git a/text_classification/train.py b/text_classification/train.py
index cda04bfc6a..888fde356f 100644
--- a/text_classification/train.py
+++ b/text_classification/train.py
@@ -46,10 +46,10 @@ def train(topology,
word_dict = paddle.dataset.imdb.word_dict()
train_reader = paddle.batch(
... |
xorbitsai__inference-1024 | support google Gemma series models
please help to support google Gemma series models
| [
{
"content": "# Copyright 2022-2023 XProbe Inc.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# http://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless required by ap... | [
{
"content": "# Copyright 2022-2023 XProbe Inc.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# http://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless required by ap... | diff --git a/doc/source/models/builtin/llm/gemma-it.rst b/doc/source/models/builtin/llm/gemma-it.rst
new file mode 100644
index 0000000000..676e91b4a4
--- /dev/null
+++ b/doc/source/models/builtin/llm/gemma-it.rst
@@ -0,0 +1,45 @@
+.. _models_llm_gemma-it:
+
+========================================
+gemma-it
+========... |
rotki__rotki-200 | Replace the log watcher functionality in the frontend
## Description
At the moment in the frontend we use a [log watching](https://github.com/rotkehlchenio/rotkehlchen/blob/ecd231b8d8c55f30a7f7ef54280fa19e7a15f5ba/ui/utils.js#L119) functionality in order to watch the log for warnings and errors and display them to t... | [
{
"content": "# Based on https://github.com/fyears/electron-python-example\nfrom __future__ import print_function\n\nimport logging\nimport signal\nimport traceback\n\nimport gevent\nimport zerorpc\nfrom gevent.event import Event\nfrom gevent.lock import Semaphore\n\nfrom rotkehlchen.args import app_args\nfrom ... | [
{
"content": "# Based on https://github.com/fyears/electron-python-example\nfrom __future__ import print_function\n\nimport logging\nimport signal\nimport traceback\n\nimport gevent\nimport zerorpc\nfrom gevent.event import Event\nfrom gevent.lock import Semaphore\n\nfrom rotkehlchen.args import app_args\nfrom ... | diff --git a/package.json b/package.json
index 02ece031f1..c4f41af334 100644
--- a/package.json
+++ b/package.json
@@ -7,7 +7,6 @@
"cryptocurrency-icons": "^0.5.0",
"datatables.net": "latest",
"datatables.net-dt": "latest",
- "tail": "latest",
"zerorpc": "latest"
},
... |
google__jax-17080 | ModuleNotFoundError: No module named 'requests' when executing `jax.distributed.initialize()` on TPU Pods
### Description
```python
import jax
jax.distributed.initialize()
```
Error:
```
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/home/ayaka/nfs_share/venv/lib/pytho... | [
{
"content": "# Copyright 2018 The JAX 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# https://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless required by ap... | [
{
"content": "# Copyright 2018 The JAX 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# https://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless required by ap... | diff --git a/setup.py b/setup.py
index de67ff9ef8b6..36294aad6936 100644
--- a/setup.py
+++ b/setup.py
@@ -85,8 +85,11 @@ def generate_proto(source):
# Cloud TPU VM jaxlib can be installed via:
# $ pip install jax[tpu] -f https://storage.googleapis.com/jax-releases/libtpu_releases.html
- 'tpu... |
piskvorky__gensim-2791 | FastText RAM usage
#### Problem description
The `FastText` model takes too much RAM. We saw this issue many times in our CI systems, this typically looks like
```
____________________ TestFastTextModel.test_cbow_hs_online _____________________
self = <gensim.test.test_fasttext.TestFastTextModel testMethod=test_... | [
{
"content": "#!/usr/bin/env python\n# -*- coding: utf-8 -*-\n#\n# Copyright (C) 2014 Radim Rehurek <radimrehurek@seznam.cz>\n# Licensed under the GNU LGPL v2.1 - http://www.gnu.org/licenses/lgpl.html\n\n\"\"\"\nRun with::\n\n python ./setup.py install\n\"\"\"\n\nimport distutils.cmd\nimport distutils.log\ni... | [
{
"content": "#!/usr/bin/env python\n# -*- coding: utf-8 -*-\n#\n# Copyright (C) 2014 Radim Rehurek <radimrehurek@seznam.cz>\n# Licensed under the GNU LGPL v2.1 - http://www.gnu.org/licenses/lgpl.html\n\n\"\"\"\nRun with::\n\n python ./setup.py install\n\"\"\"\n\nimport distutils.cmd\nimport distutils.log\ni... | diff --git a/gensim/test/test_fasttext.py b/gensim/test/test_fasttext.py
index ba424a7178..bbd085a017 100644
--- a/gensim/test/test_fasttext.py
+++ b/gensim/test/test_fasttext.py
@@ -33,9 +33,12 @@
logger = logging.getLogger(__name__)
IS_WIN32 = (os.name == "nt") and (struct.calcsize('P') * 8 == 32)
-
MAX_WORDVEC_... |
learningequality__kolibri-5043 | inconsistent 'difficult question' reports between learners
### Observed behavior
reported by @jtamiace during last week's bug bash
Clicking a “difficult question” in an exercise does not all show the same question for each learner. Number of learners for a question does not match what the overview says
Quest... | [
{
"content": "from django.core.exceptions import ObjectDoesNotExist\nfrom django.db.models.query import F\nfrom django.http import Http404\nfrom django_filters import ModelChoiceFilter\nfrom django_filters.rest_framework import CharFilter\nfrom django_filters.rest_framework import DjangoFilterBackend\nfrom djan... | [
{
"content": "from django.core.exceptions import ObjectDoesNotExist\nfrom django.db.models.query import F\nfrom django.http import Http404\nfrom django_filters import ModelChoiceFilter\nfrom django_filters.rest_framework import CharFilter\nfrom django_filters.rest_framework import DjangoFilterBackend\nfrom djan... | diff --git a/kolibri/core/logger/api.py b/kolibri/core/logger/api.py
index a8877275e60..05c26ba43d0 100644
--- a/kolibri/core/logger/api.py
+++ b/kolibri/core/logger/api.py
@@ -170,7 +170,7 @@ def filter_content(self, queryset, name, value):
class Meta:
model = AttemptLog
- fields = ['masterylog'... |
ivy-llc__ivy-22811 | cov
| [
{
"content": "# local\nimport ivy\nimport ivy.functional.frontends.paddle as paddle_frontend\nfrom ivy.func_wrapper import (\n with_supported_dtypes,\n with_unsupported_dtypes,\n with_supported_device_and_dtypes,\n)\nfrom ivy.functional.frontends.paddle.func_wrapper import _to_ivy_array\n\n\nclass Tens... | [
{
"content": "# local\nimport ivy\nimport ivy.functional.frontends.paddle as paddle_frontend\nfrom ivy.func_wrapper import (\n with_supported_dtypes,\n with_unsupported_dtypes,\n with_supported_device_and_dtypes,\n)\nfrom ivy.functional.frontends.paddle.func_wrapper import _to_ivy_array\n\n\nclass Tens... | diff --git a/ivy/functional/frontends/paddle/tensor/tensor.py b/ivy/functional/frontends/paddle/tensor/tensor.py
index f3fe3500552a7..51ba3eee9a1d7 100644
--- a/ivy/functional/frontends/paddle/tensor/tensor.py
+++ b/ivy/functional/frontends/paddle/tensor/tensor.py
@@ -986,6 +986,18 @@ def trace(self, offset=0, axis1=0,... |
mitmproxy__mitmproxy-2005 | How to configure file system watchdog (away) for attached scripts
Hi folks,
I upgraded my local mitmproxy using pip from 0.17 to 0.18.2 and now my script does not work anymore. The mitmproxy is used to connect a local machine with a corporate proxy and measure the traffic in between. The mitmproxy (to be exact, the ... | [
{
"content": "import contextlib\nimport os\nimport shlex\nimport sys\nimport threading\nimport traceback\nimport types\n\nfrom mitmproxy import exceptions\nfrom mitmproxy import ctx\nfrom mitmproxy import eventsequence\n\n\nimport watchdog.events\nfrom watchdog.observers import polling\n\n\ndef parse_command(co... | [
{
"content": "import contextlib\nimport os\nimport shlex\nimport sys\nimport threading\nimport traceback\nimport types\n\nfrom mitmproxy import exceptions\nfrom mitmproxy import ctx\nfrom mitmproxy import eventsequence\n\n\nimport watchdog.events\nfrom watchdog.observers import polling\n\n\ndef parse_command(co... | diff --git a/mitmproxy/addons/script.py b/mitmproxy/addons/script.py
index b3a93571d1..a7d3a31237 100644
--- a/mitmproxy/addons/script.py
+++ b/mitmproxy/addons/script.py
@@ -110,11 +110,16 @@ def __init__(self, callback):
self.callback = callback
def filter(self, event):
+ """
+ Retur... |
edgedb__edgedb-2310 | InternalServerError: uncompiled expression in the field 'default' of property
EdgeDB Version: EdgeDB 1.0-beta.1+g2eee1afe4.d20210301
Changing schema from:
```
type Post {
required property createdAt -> datetime {
default := datetime_current();
}
required link user -> User;
required property co... | [
{
"content": "#\n# This source file is part of the EdgeDB open source project.\n#\n# Copyright 2008-present MagicStack Inc. and the EdgeDB authors.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy... | [
{
"content": "#\n# This source file is part of the EdgeDB open source project.\n#\n# Copyright 2008-present MagicStack Inc. and the EdgeDB authors.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy... | diff --git a/edb/schema/links.py b/edb/schema/links.py
index 69b2a682846..eff4fc241e6 100644
--- a/edb/schema/links.py
+++ b/edb/schema/links.py
@@ -552,6 +552,7 @@ class AlterLinkLowerCardinality(
class AlterLinkOwned(
referencing.AlterOwned[Link],
+ pointers.PointerCommandOrFragment[Link],
referrer_co... |
holoviz__holoviews-749 | Always get warnings.warn("All-NaN slice encountered", RuntimeWarning) for Overlay
I always get this error when creating an `hv.Overlay`:
``` python
x = np.linspace(0, 1)
hv.Path((x,x)) + hv.Path((x,x))
```
```
/home/bnijholt/anaconda3/lib/python3.5/site-packages/numpy/lib/nanfunctions.py:326: RuntimeWarning: All-NaN ... | [
{
"content": "import re\nimport inspect\n\nimport numpy as np\nfrom matplotlib import ticker\n\nfrom ...core.util import basestring\n\n\ndef wrap_formatter(formatter):\n \"\"\"\n Wraps formatting function or string in\n appropriate matplotlib formatter type.\n \"\"\"\n if isinstance(formatter, ti... | [
{
"content": "import re\nimport inspect\nimport warnings\n\nimport numpy as np\nfrom matplotlib import ticker\n\nfrom ...core.util import basestring\n\n\ndef wrap_formatter(formatter):\n \"\"\"\n Wraps formatting function or string in\n appropriate matplotlib formatter type.\n \"\"\"\n if isinsta... | diff --git a/holoviews/plotting/mpl/util.py b/holoviews/plotting/mpl/util.py
index 51e2e07ec1..15dd388912 100644
--- a/holoviews/plotting/mpl/util.py
+++ b/holoviews/plotting/mpl/util.py
@@ -1,5 +1,6 @@
import re
import inspect
+import warnings
import numpy as np
from matplotlib import ticker
@@ -54,4 +55,6 @@ de... |
fonttools__fonttools-2828 | [instancer] STAT: ElidedFallbackNameID is removed from 'name' table
When creating a static instance from a VF that has an `ElidedFallbackNameID` in the `STAT` table, the name record referred to by `ElidedFallbackNameID` is deleted, but the field is not cleared.
I'm not sure what the fix should be:
1. don't delete t... | [
{
"content": "\"\"\"Helpers for instantiating name table records.\"\"\"\n\nfrom contextlib import contextmanager\nfrom copy import deepcopy\nfrom enum import IntEnum\nimport re\n\n\nclass NameID(IntEnum):\n FAMILY_NAME = 1\n SUBFAMILY_NAME = 2\n UNIQUE_FONT_IDENTIFIER = 3\n FULL_FONT_NAME = 4\n V... | [
{
"content": "\"\"\"Helpers for instantiating name table records.\"\"\"\n\nfrom contextlib import contextmanager\nfrom copy import deepcopy\nfrom enum import IntEnum\nimport re\n\n\nclass NameID(IntEnum):\n FAMILY_NAME = 1\n SUBFAMILY_NAME = 2\n UNIQUE_FONT_IDENTIFIER = 3\n FULL_FONT_NAME = 4\n V... | diff --git a/Lib/fontTools/varLib/instancer/names.py b/Lib/fontTools/varLib/instancer/names.py
index cfe12a94d3..e9c6b13d28 100644
--- a/Lib/fontTools/varLib/instancer/names.py
+++ b/Lib/fontTools/varLib/instancer/names.py
@@ -37,6 +37,9 @@ def getVariationNameIDs(varfont):
used.append(axis.AxisNameID)
... |
spyder-ide__spyder-4785 | Spyder crashes when pressing ctrl-g in editor to go to definition
## Description of your problem
About half the times when pressing ctrl-g in the Spyder editor to go to definition, spyder/python crashes.
**What steps will reproduce the problem?**
1. Open a python file in the Spyder editor
2. Move the caret to... | [
{
"content": "# -*- coding: utf-8 -*-\r\n#\r\n# Copyright © Spyder Project Contributors\r\n# Licensed under the terms of the MIT License\r\n# (see spyder/__init__.py for details)\r\n\r\n# Standard library imports\r\nfrom __future__ import print_function\r\nfrom collections import OrderedDict\r\nimport time\r\n\... | [
{
"content": "# -*- coding: utf-8 -*-\r\n#\r\n# Copyright © Spyder Project Contributors\r\n# Licensed under the terms of the MIT License\r\n# (see spyder/__init__.py for details)\r\n\r\n# Standard library imports\r\nfrom __future__ import print_function\r\nfrom collections import OrderedDict\r\nimport time\r\n\... | diff --git a/spyder/utils/introspection/manager.py b/spyder/utils/introspection/manager.py
index 3cc20ca6aa6..8b595e2a0f4 100644
--- a/spyder/utils/introspection/manager.py
+++ b/spyder/utils/introspection/manager.py
@@ -143,8 +143,8 @@ def _finalize(self, response):
% (self.info.name, response['name']... |
strawberry-graphql__strawberry-2593 | Provide better error for Union of scalars.
This keeps coming from questions on discord
```py
union: Union[List[int], List[str]]
```
gives something like
```console
File "/root/backend/env/lib/python3.10/site-packages/strawberry/schema/name_converter.py", line 99, in from_union
assert hasattr(type_, "_type_... | [
{
"content": "from __future__ import annotations\n\nfrom inspect import getframeinfo, stack\nfrom pathlib import Path\nfrom typing import TYPE_CHECKING, Optional, Type\n\nfrom strawberry.exceptions.utils.source_finder import SourceFinder\nfrom strawberry.utils.cached_property import cached_property\n\nfrom .exc... | [
{
"content": "from __future__ import annotations\n\nfrom inspect import getframeinfo, stack\nfrom pathlib import Path\nfrom typing import TYPE_CHECKING, Optional, Type\n\nfrom strawberry.exceptions.utils.source_finder import SourceFinder\nfrom strawberry.utils.cached_property import cached_property\n\nfrom .exc... | diff --git a/RELEASE.md b/RELEASE.md
new file mode 100644
index 0000000000..937c791b8b
--- /dev/null
+++ b/RELEASE.md
@@ -0,0 +1,7 @@
+Release type: patch
+
+This release covers an edge case where the following would not give a nice error.
+```python
+some_field: "Union[list[str], SomeType]]"
+```
+Fixes [#2591](https:... |
nilearn__nilearn-3284 | Unexpected image resampling when nifti doesn't have an sform
<!--Provide a brief description of the bug.-->
The bug pertains the transformation of niftis that do not have an sform (all 0s). This happens when, for example, using antsApplyTransforms ([from ANTs versions older than Feb. 2021](https://github.com/ANTsX/A... | [
{
"content": "\"\"\"\nUtilities to resample a Niimg-like object\nSee http://nilearn.github.io/manipulating_images/input_output.html\n\"\"\"\n# Author: Gael Varoquaux, Alexandre Abraham, Michael Eickenberg\n# License: simplified BSD\n\nimport warnings\nfrom nilearn.version import _compare_version\nimport numbers... | [
{
"content": "\"\"\"\nUtilities to resample a Niimg-like object\nSee http://nilearn.github.io/manipulating_images/input_output.html\n\"\"\"\n# Author: Gael Varoquaux, Alexandre Abraham, Michael Eickenberg\n# License: simplified BSD\n\nimport warnings\nfrom nilearn.version import _compare_version\nimport numbers... | diff --git a/doc/changes/latest.rst b/doc/changes/latest.rst
index 3a443760a9..dff32182f1 100644
--- a/doc/changes/latest.rst
+++ b/doc/changes/latest.rst
@@ -22,6 +22,7 @@ Fixes
- Fix title display for :func:`~plotting.plot_surf_stat_map`. The ``title`` argument does not set the figure title anymore but the axis titl... |
qtile__qtile-1963 | configure() in libqtile.backend.x11.xcbq is not robust
<!--
Please do not ask general questions here! There are [community
contact](https://github.com/qtile/qtile#community) options for that.
-->
# Issue description
The function is not robust, as it breaks on xcffib declaring a version with patch level:
https... | [
{
"content": "# Copyright (c) 2009-2010 Aldo Cortesi\n# Copyright (c) 2010 matt\n# Copyright (c) 2010, 2012, 2014 dequis\n# Copyright (c) 2010 Philip Kranz\n# Copyright (c) 2010-2011 Paul Colomiets\n# Copyright (c) 2011 osebelin\n# Copyright (c) 2011 Mounier Florian\n# Copyright (c) 2011 Kenji_Takahashi\n# Copy... | [
{
"content": "# Copyright (c) 2009-2010 Aldo Cortesi\n# Copyright (c) 2010 matt\n# Copyright (c) 2010, 2012, 2014 dequis\n# Copyright (c) 2010 Philip Kranz\n# Copyright (c) 2010-2011 Paul Colomiets\n# Copyright (c) 2011 osebelin\n# Copyright (c) 2011 Mounier Florian\n# Copyright (c) 2011 Kenji_Takahashi\n# Copy... | diff --git a/libqtile/backend/x11/xcbq.py b/libqtile/backend/x11/xcbq.py
index 804191ae37..838bafe70b 100644
--- a/libqtile/backend/x11/xcbq.py
+++ b/libqtile/backend/x11/xcbq.py
@@ -623,7 +623,7 @@ def configure(self, **kwargs):
mask, values = ConfigureMasks(**kwargs)
# older versions of xcb pack eve... |
liqd__a4-opin-527 | Add explanations for inviting users
Currently the inivite users text input is very hard to understand. We should add some more information. (see: https://opin-stage.liqd.net/de/dashboard/sample-organisation/projects/test-invite/users/invite)
The **headline** of the form in the example currently is “INVITE USERS TO T... | [
{
"content": "import collections\nimport email.utils\nimport re\n\nfrom django import forms\nfrom django.conf import settings\nfrom django.core.exceptions import ValidationError\nfrom django.db.models import loading\nfrom django.forms import modelformset_factory\nfrom django.utils.translation import ugettext as... | [
{
"content": "import collections\nimport email.utils\nimport re\n\nfrom django import forms\nfrom django.conf import settings\nfrom django.core.exceptions import ValidationError\nfrom django.db.models import loading\nfrom django.forms import modelformset_factory\nfrom django.utils.translation import ugettext as... | diff --git a/euth/dashboard/forms.py b/euth/dashboard/forms.py
index 4dcd0ccbe..bef137cbe 100644
--- a/euth/dashboard/forms.py
+++ b/euth/dashboard/forms.py
@@ -34,7 +34,16 @@ class Meta:
class ProjectInviteForm(forms.Form):
- emails = forms.CharField()
+ emails = forms.CharField(
+ label=_('E-mail ad... |
zestedesavoir__zds-site-5449 | L'export à la demande ne fonctionne pas
Plus précisement, l'export Markdown ne fonctionne pas quand on clique sur le bouton "Exporter le contenu" alors qu'il fonctionne lors de la publication.
| [
{
"content": "import contextlib\nfrom pathlib import Path\n\nfrom django.http import Http404\nfrom django.utils import translation\nfrom django.utils.translation import gettext as _\nfrom rest_framework import status\nfrom rest_framework.fields import empty\nfrom rest_framework.generics import UpdateAPIView, Li... | [
{
"content": "import contextlib\nfrom pathlib import Path\n\nfrom django.http import Http404\nfrom django.utils import translation\nfrom django.utils.translation import gettext as _\nfrom rest_framework import status\nfrom rest_framework.fields import empty\nfrom rest_framework.generics import UpdateAPIView, Li... | diff --git a/zds/tutorialv2/api/views.py b/zds/tutorialv2/api/views.py
index 779be54457..b6f4dfb4a3 100644
--- a/zds/tutorialv2/api/views.py
+++ b/zds/tutorialv2/api/views.py
@@ -88,7 +88,7 @@ def create(self, request, *args, **kwargs):
if not publishable_content.public_version:
raise Http... |
readthedocs__readthedocs.org-8700 | Project slugs with multiple dashes can't load PR builds
For a period of time, projects could end up with a slightly invalid slug, with double dashes. This could happen if the project name included a utf8 character that would not slugify or even a dash/underscore. New projects seem to slug properly now, but for any proj... | [
{
"content": "\"\"\"\nMiddleware for Proxito.\n\nThis is used to take the request and map the host to the proper project slug.\n\nAdditional processing is done to get the project from the URL in the ``views.py`` as well.\n\"\"\"\nimport logging\nimport re\nimport sys\nfrom urllib.parse import urlparse\n\nfrom d... | [
{
"content": "\"\"\"\nMiddleware for Proxito.\n\nThis is used to take the request and map the host to the proper project slug.\n\nAdditional processing is done to get the project from the URL in the ``views.py`` as well.\n\"\"\"\nimport logging\nimport re\nimport sys\nfrom urllib.parse import urlparse\n\nfrom d... | diff --git a/readthedocs/proxito/middleware.py b/readthedocs/proxito/middleware.py
index a927698d026..02b5971eae7 100644
--- a/readthedocs/proxito/middleware.py
+++ b/readthedocs/proxito/middleware.py
@@ -86,7 +86,7 @@ def map_host_to_project_slug(request): # pylint: disable=too-many-return-statem
# Serve cus... |
enthought__chaco-499 | Demo noninteractive.py, Errors after <ENTER>
**Problem Description**
Errors after <ENTER>
**Reproduction Steps:**
Run noninteractive.py and hit ENTER
**Expected behavior:**
```
Please enter a path in which to place generated plots.
Press <ENTER> to generate in the current directory.
Path:
Traceback (most ... | [
{
"content": "#!/usr/bin/env python\n\"\"\"\nThis demonstrates how to create a plot offscreen and save it to an image\nfile on disk.\n\"\"\"\nfrom __future__ import print_function\n\n# Standard library imports\nimport os\nimport sys\n\n# Major library imports\nfrom numpy import linspace\nfrom scipy.special impo... | [
{
"content": "#!/usr/bin/env python\n\"\"\"\nThis demonstrates how to create a plot offscreen and save it to an image\nfile on disk.\n\"\"\"\nfrom __future__ import print_function\n\n# Standard library imports\nimport os\nimport sys\n\n# Major library imports\nfrom numpy import linspace\nfrom scipy.special impo... | diff --git a/examples/demo/noninteractive.py b/examples/demo/noninteractive.py
index d80d14956..f6639cae4 100644
--- a/examples/demo/noninteractive.py
+++ b/examples/demo/noninteractive.py
@@ -87,7 +87,14 @@ def draw_pdf(filename, size=(800, 600)):
def get_directory(filename):
print('Please enter a path in which ... |
imAsparky__django-cookiecutter-34 | [DOCS]: Add django project Conventional commits message template.
**Describe alternatives you've considered**
Would you please share your clear and concise description of any alternative/similar documentation you've considered.
**Additional context**
Would you please share any other context or screenshots abou... | [
{
"content": "#!/usr/bin/env python\n\"\"\"django-cookiecutter post project generation jobs.\"\"\"\nimport os\nimport subprocess # nosec\n\nPROJECT_DIRECTORY = os.path.realpath(os.path.curdir)\n\n# REMOTE_REPO = \"git@github.com:{{cookiecutter.github_username}}/\\\n# {{cookiecutter.git_project_name}}.git\"\n\n... | [
{
"content": "#!/usr/bin/env python\n\"\"\"django-cookiecutter post project generation jobs.\"\"\"\nimport os\nimport subprocess # nosec\n\nPROJECT_DIRECTORY = os.path.realpath(os.path.curdir)\n\n# REMOTE_REPO = \"git@github.com:{{cookiecutter.github_username}}/\\\n# {{cookiecutter.git_project_name}}.git\"\n\n... | diff --git a/cookiecutter.json b/cookiecutter.json
index ad88da7e..57f5ca59 100644
--- a/cookiecutter.json
+++ b/cookiecutter.json
@@ -10,7 +10,7 @@
"add_contributors_list": "n",
"version": "0.1.0",
- "create_conventional_commits_edit_message": "y",
+ "create_conventional_commits_edit_message": ["y", "n"],
... |
hpcaitech__ColossalAI-5440 | [tensor] fix some unittests
[tensor] fix some unittests
[tensor] fix some unittests
| [
{
"content": "from dataclasses import dataclass\nfrom typing import Optional\n\nfrom colossalai.legacy.tensor.distspec import DistPlacementPattern, _DistSpec\nfrom colossalai.legacy.tensor.process_group import ProcessGroup\n\nfrom .compute_spec import ComputeSpec\n\n\n@dataclass\nclass ColoTensorSpec:\n \"\"... | [
{
"content": "from dataclasses import dataclass, field\nfrom typing import Optional\n\nfrom colossalai.legacy.tensor.distspec import DistPlacementPattern, _DistSpec\nfrom colossalai.legacy.tensor.process_group import ProcessGroup\n\nfrom .compute_spec import ComputeSpec\n\n\n@dataclass\nclass ColoTensorSpec:\n ... | diff --git a/colossalai/legacy/tensor/tensor_spec.py b/colossalai/legacy/tensor/tensor_spec.py
index 5bdd384e5e15..44d8d04b9540 100644
--- a/colossalai/legacy/tensor/tensor_spec.py
+++ b/colossalai/legacy/tensor/tensor_spec.py
@@ -1,4 +1,4 @@
-from dataclasses import dataclass
+from dataclasses import dataclass, field
... |
obspy__obspy-2862 | Ambiguity in xcorr_max()
The [documentation ](https://docs.obspy.org/packages/autogen/obspy.signal.cross_correlation.xcorr_max.html) for `xcorr_max()` has a boolean for `abs_max` to define whether to take the maximum cross correlation or not. My confusion lies since absolute in mathematics often defines a positive valu... | [
{
"content": "#!/usr/bin/env python\n# -*- coding: utf-8 -*-\n# -------------------------------------------------------------------\n# Filename: cross_correlation.py\n# Author: Moritz Beyreuther, Tobias Megies, Tom Eulenfeld\n# Email: megies@geophysik.uni-muenchen.de\n#\n# Copyright (C) 2008-2019 Moritz Be... | [
{
"content": "#!/usr/bin/env python\n# -*- coding: utf-8 -*-\n# -------------------------------------------------------------------\n# Filename: cross_correlation.py\n# Author: Moritz Beyreuther, Tobias Megies, Tom Eulenfeld\n# Email: megies@geophysik.uni-muenchen.de\n#\n# Copyright (C) 2008-2019 Moritz Be... | diff --git a/obspy/CONTRIBUTORS.txt b/obspy/CONTRIBUTORS.txt
index 1d42fa63f2c..9e6b3184272 100644
--- a/obspy/CONTRIBUTORS.txt
+++ b/obspy/CONTRIBUTORS.txt
@@ -45,6 +45,7 @@ Inza, Adolfo
Isken, Marius
Kearns, Aaron
Ketchum, David
+Khan, Lewis
Koymans, Mathijs
Kremers, Simon
Kress, Victor
diff --git a/obspy/signa... |
ipython__ipython-13612 | Sphinx ipython directive greedily strips all decorators, including valid python ones!
A sphinx ipython code cell which contains a valid python decorator will currently have the line with the decorator completely stripped before the code is run!
In my case that meant that this code block
```python
.. ipython:: py... | [
{
"content": "# -*- coding: utf-8 -*-\n\"\"\"\nSphinx directive to support embedded IPython code.\n\nIPython provides an extension for `Sphinx <http://www.sphinx-doc.org/>`_ to\nhighlight and run code.\n\nThis directive allows pasting of entire interactive IPython sessions, prompts\nand all, and their code will... | [
{
"content": "# -*- coding: utf-8 -*-\n\"\"\"\nSphinx directive to support embedded IPython code.\n\nIPython provides an extension for `Sphinx <http://www.sphinx-doc.org/>`_ to\nhighlight and run code.\n\nThis directive allows pasting of entire interactive IPython sessions, prompts\nand all, and their code will... | diff --git a/IPython/sphinxext/ipython_directive.py b/IPython/sphinxext/ipython_directive.py
index 18bdfcae993..b1f3931a475 100644
--- a/IPython/sphinxext/ipython_directive.py
+++ b/IPython/sphinxext/ipython_directive.py
@@ -821,8 +821,11 @@ def process_pure_python(self, content):
output.append(line)
... |
quantumlib__Cirq-3404 | Read the docs has goofy copyright
**Description of the issue**
Copyright shows up on cirq tutorials on readthedocs.
**How to reproduce the issue**
Go to https://cirq.readthedocs.io/en/latest/docs/gates.html or other pages. Top part says "Copyright 2020 The Cirq Developers" with apache license.
**Cirq version**... | [
{
"content": "# -*- coding: utf-8 -*-\n# coverage: ignore\n\n# The content for all documentation lives in ../docs. That folder is\n# following the structure for the Google Quantum site configured for the\n# internal CMS, devsite. The readthedocs layer is a secondary, which generates\n# the content using sphinx ... | [
{
"content": "# -*- coding: utf-8 -*-\n# coverage: ignore\n\n# The content for all documentation lives in ../docs. That folder is\n# following the structure for the Google Quantum site configured for the\n# internal CMS, devsite. The readthedocs layer is a secondary, which generates\n# the content using sphinx ... | diff --git a/rtd_docs/conf.py b/rtd_docs/conf.py
index 2ee1eb00f9f..71ea685c0f8 100644
--- a/rtd_docs/conf.py
+++ b/rtd_docs/conf.py
@@ -132,8 +132,14 @@ def autodoc_process(app, what: str, name: str, obj: Any, options,
def source_read(app, docname, source):
- source[0] = re.sub(r'"##### (Copyright 20\d\d The C... |
arviz-devs__arviz-557 | Ordering of variables after coords set
## Short Description
I'm trying to use the coords/dims to set labels on posterior variables from a stan fit and the order of the dimensions gets shuffled when I set the labels (not sure what determines the order). Is there a way to (1) retain the existing order (A,B,C...) and (... | [
{
"content": "\"\"\"Utilities for plotting.\"\"\"\nfrom itertools import product\n\nimport numpy as np\nimport matplotlib.pyplot as plt\nimport matplotlib as mpl\nimport xarray as xr\n\n\ndef make_2d(ary):\n \"\"\"Convert any array into a 2d numpy array.\n\n In case the array is already more than 2 dimens... | [
{
"content": "\"\"\"Utilities for plotting.\"\"\"\nfrom itertools import product\n\nimport numpy as np\nimport matplotlib.pyplot as plt\nimport matplotlib as mpl\nimport xarray as xr\n\n\ndef make_2d(ary):\n \"\"\"Convert any array into a 2d numpy array.\n\n In case the array is already more than 2 dimens... | diff --git a/arviz/plots/plot_utils.py b/arviz/plots/plot_utils.py
index 7ced931826..cee27bbef7 100644
--- a/arviz/plots/plot_utils.py
+++ b/arviz/plots/plot_utils.py
@@ -260,7 +260,7 @@ def xarray_var_iter(data, var_names=None, combined=False, skip_dims=None, revers
for var_name in var_names:
if var_name... |
vacanza__python-holidays-555 | October 25 is no longer holiday in Spain Prov=PV
I'm using the WORKDAY integration of Home Assistant to obtain a binary sensor for workdays.
AFAIK python-holidays is being used "under the hood" in this integration
Yesterday October 25th was wrongly marked as holiday.
It's not holiday since 2014.
More info (sorry,... | [
{
"content": "# -*- coding: utf-8 -*-\n\n# python-holidays\n# ---------------\n# A fast, efficient Python library for generating country, province and state\n# specific sets of holidays on the fly. It aims to make determining whether a\n# specific date is a holiday as fast and flexible as possible.\n#\n# ... | [
{
"content": "# -*- coding: utf-8 -*-\n\n# python-holidays\n# ---------------\n# A fast, efficient Python library for generating country, province and state\n# specific sets of holidays on the fly. It aims to make determining whether a\n# specific date is a holiday as fast and flexible as possible.\n#\n# ... | diff --git a/holidays/countries/spain.py b/holidays/countries/spain.py
index 6b2c8dd0e..3fd948700 100644
--- a/holidays/countries/spain.py
+++ b/holidays/countries/spain.py
@@ -185,7 +185,10 @@ def _populate(self, year):
elif self.prov == "NC":
self._is_observed(date(year, SEP, 27), "Día d... |
vyperlang__vyper-1143 | `vyper-serve` error in compiling functions
### Version Information
* vyper Version: 0.1.0b4
* OS: osx
* Python Version : 3.6
### What's your issue about?
`vyper-serve` cause this error when it compiles some contract which has a function. It seems that it is related to `method_identifiers` and I think the upd... | [
{
"content": "import ast\nimport copy\n\n\nfrom vyper.exceptions import (\n InvalidLiteralException,\n StructureException,\n TypeMismatchException,\n FunctionDeclarationException,\n EventDeclarationException\n)\nfrom vyper.signatures.function_signature import (\n FunctionSignature,\n Variab... | [
{
"content": "import ast\nimport copy\n\n\nfrom vyper.exceptions import (\n InvalidLiteralException,\n StructureException,\n TypeMismatchException,\n FunctionDeclarationException,\n EventDeclarationException\n)\nfrom vyper.signatures.function_signature import (\n FunctionSignature,\n Variab... | diff --git a/vyper/parser/parser.py b/vyper/parser/parser.py
index cda7537ad1..625e217c36 100644
--- a/vyper/parser/parser.py
+++ b/vyper/parser/parser.py
@@ -140,7 +140,7 @@ def mk_method_identifiers(code):
for code in global_ctx._defs:
sig = FunctionSignature.from_definition(code, sigs=global_ctx._contr... |
pypa__pip-11124 | regression: `--no-build-isolation` validation causes failure with setup deps installed from custom commit
### Description
After updating from pip `22.0` to `22.1`, `--no-build-isolation` is incompatible with packages installed from a custom commit.
We have setup code that depends on ctypesgen, which did not get a P... | [
{
"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/11123.bugfix.rst b/news/11123.bugfix.rst
new file mode 100644
index 00000000000..17d3de27e69
--- /dev/null
+++ b/news/11123.bugfix.rst
@@ -0,0 +1,3 @@
+Allow using a pre-release version to satisfy a build requirement. This helps
+manually populated build environments to more accurately detect build-ti... |
python-gitlab__python-gitlab-673 | Python gitlab "reset_time_estimate" crashes with HTTP error 404
Just a typo here:
https://github.com/python-gitlab/python-gitlab/blob/85ac10200805de480a076760368336c8135e5acf/gitlab/mixins.py#L535
Fixed by:
`path = '%s/%s/reset_time_estimate' % (self.manager.path, self.get_id())`
Can we do this without pull r... | [
{
"content": "# -*- coding: utf-8 -*-\n#\n# Copyright (C) 2013-2017 Gauvain Pocentek <gauvain@pocentek.net>\n#\n# This program is free software: you can redistribute it and/or modify\n# it under the terms of the GNU Lesser General Public License as published by\n# the Free Software Foundation, either version 3 ... | [
{
"content": "# -*- coding: utf-8 -*-\n#\n# Copyright (C) 2013-2017 Gauvain Pocentek <gauvain@pocentek.net>\n#\n# This program is free software: you can redistribute it and/or modify\n# it under the terms of the GNU Lesser General Public License as published by\n# the Free Software Foundation, either version 3 ... | diff --git a/gitlab/mixins.py b/gitlab/mixins.py
index 2c80f36db..ca68658de 100644
--- a/gitlab/mixins.py
+++ b/gitlab/mixins.py
@@ -532,7 +532,7 @@ def reset_time_estimate(self, **kwargs):
GitlabAuthenticationError: If authentication is not correct
GitlabTimeTrackingError: If the time trackin... |
mozilla__pontoon-2816 | Don't submit pretranslated strings with warnings or errors
If possible, it would be great to have 2 different behaviors:
* Strings with warning should be suggested, instead of submitted, because they might be OK (i.e. the warning could be ignored), or at least it might be still useful to post-edit them instead of star... | [
{
"content": "import logging\n\nfrom django.db.models import Q, CharField, Value as V\nfrom django.db.models.functions import Concat\nfrom django.conf import settings\nfrom pontoon.base.models import (\n Project,\n Entity,\n TranslatedResource,\n Translation,\n)\nfrom pontoon.actionlog.models import... | [
{
"content": "import logging\n\nfrom django.db.models import Q, CharField, Value as V\nfrom django.db.models.functions import Concat\nfrom django.conf import settings\nfrom pontoon.base.models import (\n Project,\n Entity,\n TranslatedResource,\n Translation,\n)\nfrom pontoon.actionlog.models import... | diff --git a/pontoon/pretranslation/tasks.py b/pontoon/pretranslation/tasks.py
index 4d96c10e33..6b4e50a82f 100644
--- a/pontoon/pretranslation/tasks.py
+++ b/pontoon/pretranslation/tasks.py
@@ -171,7 +171,12 @@ def pretranslate(self, project_pk, locales=None, entities=None):
bulk_run_checks(Translation.objects.fo... |
ansible-collections__community.general-1250 | lvol: Ansible on 2nd and later runs expanding the Logical Volume size by doubling it, rather than locking it at 50% of the VG
<!--- Verify first that your issue is not already reported on GitHub -->
<!--- Also test if the latest release and devel branch are affected too -->
<!--- Complete *all* sections as described,... | [
{
"content": "#!/usr/bin/python\n# -*- coding: utf-8 -*-\n\n# Copyright: (c) 2013, Jeroen Hoekx <jeroen.hoekx@dsquare.be>, Alexander Bulimov <lazywolf0@gmail.com>\n# GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt)\n\nfrom __future__ import absolute_import, division, pr... | [
{
"content": "#!/usr/bin/python\n# -*- coding: utf-8 -*-\n\n# Copyright: (c) 2013, Jeroen Hoekx <jeroen.hoekx@dsquare.be>, Alexander Bulimov <lazywolf0@gmail.com>\n# GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt)\n\nfrom __future__ import absolute_import, division, pr... | diff --git a/changelogs/fragments/229_lvol_percentage_fix.yml b/changelogs/fragments/229_lvol_percentage_fix.yml
new file mode 100644
index 00000000000..aaf98454ed4
--- /dev/null
+++ b/changelogs/fragments/229_lvol_percentage_fix.yml
@@ -0,0 +1,2 @@
+minor_changes:
+ - lvol - fix idempotency issue when using lvol with ... |
holoviz__panel-5265 | PDF pane shows local pdf as base64 string
Reported by petegordon in https://discourse.holoviz.org/t/pn-pane-pdf-local-file-rendering/5720
## Reproduce
```python
import panel as pn
pn.extension()
pn.pane.PDF('sample.pdf', width=700, height=1000).servable()
```
[sample.pdf](https://github.com/holoviz/pan... | [
{
"content": "\"\"\"\nContains Image panes including renderers for PNG, SVG, GIF and JPG\nfile types.\n\"\"\"\nfrom __future__ import annotations\n\nimport asyncio\nimport base64\n\nfrom io import BytesIO\nfrom pathlib import PurePath\nfrom typing import (\n TYPE_CHECKING, Any, ClassVar, Dict, List, Mapping,... | [
{
"content": "\"\"\"\nContains Image panes including renderers for PNG, SVG, GIF and JPG\nfile types.\n\"\"\"\nfrom __future__ import annotations\n\nimport asyncio\nimport base64\n\nfrom io import BytesIO\nfrom pathlib import PurePath\nfrom typing import (\n TYPE_CHECKING, Any, ClassVar, Dict, List, Mapping,... | diff --git a/panel/pane/image.py b/panel/pane/image.py
index c830e20ede..20d7205bed 100644
--- a/panel/pane/image.py
+++ b/panel/pane/image.py
@@ -487,7 +487,9 @@ def _transform_object(self, obj: Any) -> Dict[str, Any]:
if not isinstance(data, bytes):
data = data.encode('utf-8')
... |
django-extensions__django-extensions-1128 | pipchecker doesn't find misconfigured pypi packages
I've encountered problems with running pipchecker when there's a package which is misconfigured on pypi with underscores instead of dashes. For example:
```
% manage.py pipchecker
django-celery-beat 1.0.1 release is not on pypi (check capitalization and/... | [
{
"content": "# -*- coding: utf-8 -*-\nimport json\nimport os\nimport re\nfrom distutils.version import LooseVersion\n\nimport pip\nfrom django.core.management.base import BaseCommand, CommandError\nfrom pip.req import parse_requirements\n\nfrom django_extensions.management.color import color_style\nfrom django... | [
{
"content": "# -*- coding: utf-8 -*-\nimport json\nimport os\nimport re\nfrom distutils.version import LooseVersion\n\nimport pip\nfrom django.core.management.base import BaseCommand, CommandError\nfrom pip.req import parse_requirements\n\nfrom django_extensions.management.color import color_style\nfrom django... | diff --git a/django_extensions/management/commands/pipchecker.py b/django_extensions/management/commands/pipchecker.py
index f60260dba..022a92d90 100644
--- a/django_extensions/management/commands/pipchecker.py
+++ b/django_extensions/management/commands/pipchecker.py
@@ -136,7 +136,7 @@ def check_pypi(self):
... |
shuup__shuup-2095 | Xtheme: there is no warning for usaved changes when switching between plugins
To reproduce:
1. Edit some content in Xtheme editor
2. Select another plugin without saving
3. See your changes to disappear
There probably should be warning before switching plugins when you have unsaved information.
| [
{
"content": "# This file is part of Shuup.\n#\n# Copyright (c) 2012-2019, Shoop Commerce Ltd. All rights reserved.\n#\n# This source code is licensed under the OSL-3.0 license found in the\n# LICENSE file in the root directory of this source tree.\nfrom django import forms\nfrom django.db.models import Q\nfrom... | [
{
"content": "# This file is part of Shuup.\n#\n# Copyright (c) 2012-2019, Shoop Commerce Ltd. All rights reserved.\n#\n# This source code is licensed under the OSL-3.0 license found in the\n# LICENSE file in the root directory of this source tree.\nfrom django import forms\nfrom django.db.models import Q\nfrom... | diff --git a/shuup/campaigns/admin_module/forms/_basket.py b/shuup/campaigns/admin_module/forms/_basket.py
index 5b6f01f19d..a6b1725800 100644
--- a/shuup/campaigns/admin_module/forms/_basket.py
+++ b/shuup/campaigns/admin_module/forms/_basket.py
@@ -30,7 +30,7 @@ def __init__(self, *args, **kwargs):
if suppli... |
facebookresearch__hydra-750 | [Bug] Config search path for hydra apps
# 🐛 Bug
For packaged hydra apps, `pkg://` rather than `file://` should be used in the config search path.
## To reproduce
Install `hydra_app` and run `hydra_app --info`.
## Stack trace/error message
```
Config search path
******************
| Provider | Search... | [
{
"content": "# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved\nimport argparse\nimport copy\nimport inspect\nimport logging.config\nimport os\nimport sys\nimport warnings\nfrom os.path import dirname, join, normpath, realpath\nfrom traceback import print_exc\nfrom typing import (\n Any... | [
{
"content": "# Copyright (c) Facebook, Inc. and its affiliates. All Rights Reserved\nimport argparse\nimport copy\nimport inspect\nimport logging.config\nimport os\nimport sys\nimport warnings\nfrom os.path import dirname, join, normpath, realpath\nfrom traceback import print_exc\nfrom typing import (\n Any... | diff --git a/examples/advanced/hydra_app_example/tests/test_installed_app.py b/examples/advanced/hydra_app_example/tests/test_installed_app.py
index 2de6a27199d..cd3bd6ab6fe 100644
--- a/examples/advanced/hydra_app_example/tests/test_installed_app.py
+++ b/examples/advanced/hydra_app_example/tests/test_installed_app.py... |
NVIDIA__NVFlare-250 | Startup folder not configured correctly
I think the `app_root="startup"` should be `app_root=startup` [here](https://github.com/NVIDIA/NVFlare/blob/fa20e5e27b01e0f66cbefea229aed2cf6729663d/nvflare/private/fed/app/server/server_train.py#L67-L69)
If you like I can submit a PR?
| [
{
"content": "# Copyright (c) 2021-2022, NVIDIA CORPORATION. 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/LICEN... | [
{
"content": "# Copyright (c) 2021-2022, NVIDIA CORPORATION. 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/LICEN... | diff --git a/nvflare/private/fed/app/server/server_train.py b/nvflare/private/fed/app/server/server_train.py
index 9601b99ee4..1256985b7b 100644
--- a/nvflare/private/fed/app/server/server_train.py
+++ b/nvflare/private/fed/app/server/server_train.py
@@ -66,7 +66,7 @@ def main():
# trainer = WorkFlowFactory().... |
ansible-collections__amazon.aws-1590 | Explain what use_ssm_inventory in ec2 inventory plugin does
### Summary
I'm trying to combine both the ec2 inventory plugin, and the SSM connector plugin. I'm really struggling to figure out how to do this, because of several documentation issues. But I'll just mention one here.
In the inventory plugin, there's a... | [
{
"content": "# -*- coding: utf-8 -*-\n\n# Copyright (c) 2017 Ansible Project\n# GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt)\n\nDOCUMENTATION = r\"\"\"\nname: aws_ec2\nshort_description: EC2 inventory source\nextends_documentation_fragment:\n - inventory_cache\n ... | [
{
"content": "# -*- coding: utf-8 -*-\n\n# Copyright (c) 2017 Ansible Project\n# GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt)\n\nDOCUMENTATION = r\"\"\"\nname: aws_ec2\nshort_description: EC2 inventory source\nextends_documentation_fragment:\n - inventory_cache\n ... | diff --git a/changelogs/fragments/20230531-aws_ec2-use_ssm_inventory_documentation.yml b/changelogs/fragments/20230531-aws_ec2-use_ssm_inventory_documentation.yml
new file mode 100644
index 00000000000..3b769cd3f07
--- /dev/null
+++ b/changelogs/fragments/20230531-aws_ec2-use_ssm_inventory_documentation.yml
@@ -0,0 +1,... |
saleor__saleor-730 | no_query_found method is missing.
Hello,
the user gets an error if he submits the search form without a query.
There is not "no_query_found" method inside SearchForm.
https://github.com/mirumee/saleor/blob/35956e20a85b66abc95e08491f38fa69d74d5f12/saleor/search/views.py#L28
| [
{
"content": "from __future__ import unicode_literals\n\nfrom django.core.paginator import Paginator, InvalidPage\nfrom django.conf import settings\nfrom django.http import Http404\nfrom django.shortcuts import render\nfrom .forms import SearchForm\nfrom ..product.utils import products_with_details\n\n\ndef pag... | [
{
"content": "from __future__ import unicode_literals\n\nfrom django.core.paginator import Paginator, InvalidPage\nfrom django.conf import settings\nfrom django.http import Http404\nfrom django.shortcuts import render\nfrom .forms import SearchForm\nfrom ..product.utils import products_with_details\n\n\ndef pag... | diff --git a/saleor/search/views.py b/saleor/search/views.py
index aca02a1ff37..3a5c8ed5d7a 100644
--- a/saleor/search/views.py
+++ b/saleor/search/views.py
@@ -23,10 +23,11 @@ def search(request):
if form.is_valid():
visible_products = products_with_details(request.user)
results = form.search(mo... |
freedomofpress__securedrop-5581 | Can not delete source keys in Focal
## Description
In Focal container if we delete a source, the related `gpg` keys should also be deleted, but they are not getting deleted.
## Steps to Reproduce
- [ ] Start a Focal dev container from `dev_focal` branch: `make dev-focal`
- [ ] Login as journalist, delete a so... | [
{
"content": "# -*- coding: utf-8 -*-\n\nfrom distutils.version import StrictVersion\nfrom typing import Optional\n\nimport pretty_bad_protocol as gnupg\nimport os\nimport io\nimport re\nimport scrypt\nfrom random import SystemRandom\n\nfrom base64 import b32encode\nfrom datetime import date\nfrom flask import ... | [
{
"content": "# -*- coding: utf-8 -*-\n\nfrom distutils.version import StrictVersion\nfrom typing import Optional\n\nimport pretty_bad_protocol as gnupg\nimport os\nimport io\nimport re\nimport scrypt\nfrom random import SystemRandom\n\nfrom base64 import b32encode\nfrom datetime import date\nfrom flask import ... | diff --git a/securedrop/crypto_util.py b/securedrop/crypto_util.py
index 20e6bd63a3..f4d0213408 100644
--- a/securedrop/crypto_util.py
+++ b/securedrop/crypto_util.py
@@ -267,7 +267,7 @@ def delete_reply_keypair(self, source_filesystem_id: str) -> None:
# Always delete keys without invoking pinentry-mode = l... |
strawberry-graphql__strawberry-1451 | from_pydantic error if pydantic models contains contains fields that are resolver field in strawberry type
Hi :),
i have a pydantic model that i want to convert to strawberry type using from_pydantic() method. The pydantic model contains fields that are resolver field in the strawberry type model.
```python
from... | [
{
"content": "from typing import Union, cast\n\nfrom strawberry.enum import EnumDefinition\nfrom strawberry.field import StrawberryField\nfrom strawberry.type import StrawberryList, StrawberryOptional, StrawberryType\nfrom strawberry.union import StrawberryUnion\n\n\ndef _convert_from_pydantic_to_strawberry_typ... | [
{
"content": "from typing import Union, cast\n\nfrom strawberry.enum import EnumDefinition\nfrom strawberry.field import StrawberryField\nfrom strawberry.type import StrawberryList, StrawberryOptional, StrawberryType\nfrom strawberry.union import StrawberryUnion\n\n\ndef _convert_from_pydantic_to_strawberry_typ... | diff --git a/RELEASE.md b/RELEASE.md
new file mode 100644
index 0000000000..05ce4b23b8
--- /dev/null
+++ b/RELEASE.md
@@ -0,0 +1,3 @@
+Release type: patch
+
+Fix init of Strawberry types from pydantic by skipping fields that have resolvers.
diff --git a/strawberry/experimental/pydantic/conversion.py b/strawberry/experi... |
freedomofpress__securedrop-4346 | Update SQLAlchemy to 1.3.0
## Description
Multiple vulnerabilities were reported in SQLAlchemy <1.3.0:
- CVE-2019-7164 (moderate) : SQLAlchemy through 1.2.17 and 1.3.x through 1.3.0b2 allows SQL Injection via the order_by parameter.
- CVE-2019-7548 (moderate) : SQLAlchemy 1.2.17 has SQL Injection when the group_by... | [
{
"content": "# -*- encoding:utf-8 -*-\nfrom __future__ import absolute_import, division, print_function, \\\n unicode_literals\n\nimport sys\n\nimport ansible\n\ntry:\n # Version 2.0+\n from ansible.plugins.callback import CallbackBase\nexcept ImportError:\n CallbackBase = object\n\n\ndef print... | [
{
"content": "# -*- encoding:utf-8 -*-\nfrom __future__ import absolute_import, division, print_function, \\\n unicode_literals\n\nimport sys\n\nimport ansible\n\ntry:\n # Version 2.0+\n from ansible.plugins.callback import CallbackBase\nexcept ImportError:\n CallbackBase = object\n\n\ndef print... | diff --git a/admin/requirements.txt b/admin/requirements.txt
index e37918e268..ab3611d69a 100644
--- a/admin/requirements.txt
+++ b/admin/requirements.txt
@@ -4,8 +4,8 @@
#
# pip-compile --generate-hashes --output-file requirements.txt requirements.in requirements-ansible.in
#
-ansible==2.6.8 \
- --hash=sha256... |
fonttools__fonttools-2786 | Gracefully handle TrueType fonts that misuse `post` table format 1 ?
⚠️ **The attached font is broken** ⚠️ . It uses `post` table format 1 which [requires it to contain exactly the 258 glyphs in the standard Macintosh TrueType font file](https://docs.microsoft.com/en-us/typography/opentype/spec/post#version-10). This f... | [
{
"content": "from fontTools.config import Config\nfrom fontTools.misc import xmlWriter\nfrom fontTools.misc.configTools import AbstractConfig\nfrom fontTools.misc.textTools import Tag, byteord, tostr\nfrom fontTools.misc.loggingTools import deprecateArgument\nfrom fontTools.ttLib import TTLibError\nfrom fontTo... | [
{
"content": "from fontTools.config import Config\nfrom fontTools.misc import xmlWriter\nfrom fontTools.misc.configTools import AbstractConfig\nfrom fontTools.misc.textTools import Tag, byteord, tostr\nfrom fontTools.misc.loggingTools import deprecateArgument\nfrom fontTools.ttLib import TTLibError\nfrom fontTo... | diff --git a/Lib/fontTools/ttLib/ttFont.py b/Lib/fontTools/ttLib/ttFont.py
index dbfcb6e89d..b78be19846 100644
--- a/Lib/fontTools/ttLib/ttFont.py
+++ b/Lib/fontTools/ttLib/ttFont.py
@@ -487,6 +487,14 @@ def getGlyphOrder(self):
# in combination with the Adobe Glyph List (AGL).
#
self._getGlyphNamesFromC... |
hpcaitech__ColossalAI-2641 | [tensor] fix some unittests
[tensor] fix some unittests
[tensor] fix some unittests
| [
{
"content": "import argparse\nimport csv\nimport datetime\nimport glob\nimport importlib\nimport os\nimport sys\nimport time\n\nimport numpy as np\nimport torch\nimport torchvision\n\ntry:\n import lightning.pytorch as pl\nexcept:\n import pytorch_lightning as pl\n\nfrom functools import partial\n\nfrom ... | [
{
"content": "import argparse\nimport csv\nimport datetime\nimport glob\nimport importlib\nimport os\nimport sys\nimport time\n\nimport numpy as np\nimport torch\nimport torchvision\n\ntry:\n import lightning.pytorch as pl\nexcept:\n import pytorch_lightning as pl\n\nfrom functools import partial\n\nfrom ... | diff --git a/examples/images/diffusion/README.md b/examples/images/diffusion/README.md
index 952da5d1c3b0..15932f1f524b 100644
--- a/examples/images/diffusion/README.md
+++ b/examples/images/diffusion/README.md
@@ -92,6 +92,12 @@ cd ColossalAI
CUDA_EXT=1 pip install .
```
+#### Step 3:Accelerate with flash attentio... |
ultralytics__yolov5-3973 | model ensembling isn't working
## 🐛 Bug
When I detect some image by using ensembling, it doesn't work.
## To Reproduce (REQUIRED)
Input:
```
!git clone https://github.com/ultralytics/yolov5 # clone repo
%cd yolov5
%pip install -qr requirements.txt # install dependencies
import torch
from IPython.display... | [
{
"content": "# YOLOv5 experimental modules\n\nimport numpy as np\nimport torch\nimport torch.nn as nn\n\nfrom models.common import Conv, DWConv\nfrom utils.google_utils import attempt_download\n\n\nclass CrossConv(nn.Module):\n # Cross Convolution Downsample\n def __init__(self, c1, c2, k=3, s=1, g=1, e=... | [
{
"content": "# YOLOv5 experimental modules\n\nimport numpy as np\nimport torch\nimport torch.nn as nn\n\nfrom models.common import Conv, DWConv\nfrom utils.google_utils import attempt_download\n\n\nclass CrossConv(nn.Module):\n # Cross Convolution Downsample\n def __init__(self, c1, c2, k=3, s=1, g=1, e=... | diff --git a/models/experimental.py b/models/experimental.py
index d316b18373c3..30dc36192bc0 100644
--- a/models/experimental.py
+++ b/models/experimental.py
@@ -100,10 +100,10 @@ class Ensemble(nn.ModuleList):
def __init__(self):
super(Ensemble, self).__init__()
- def forward(self, x, augment=False... |
mozilla__pontoon-1429 | Added pontoon hook for Django.
This implements Pontoon hook for Django.
| [
{
"content": "from __future__ import absolute_import\n\nimport logging\nfrom datetime import datetime\n\nimport waffle\n\nfrom django.conf import settings\nfrom django.contrib import messages\nfrom django.contrib.auth.decorators import login_required\nfrom django.contrib.auth.models import User\nfrom django.cor... | [
{
"content": "from __future__ import absolute_import\n\nimport logging\nfrom datetime import datetime\n\nimport waffle\n\nfrom django.conf import settings\nfrom django.contrib import messages\nfrom django.contrib.auth.decorators import login_required\nfrom django.contrib.auth.models import User\nfrom django.cor... | diff --git a/frontend/src/core/user/components/UserMenu.css b/frontend/src/core/user/components/UserMenu.css
index fbf68d83ed..a231e0f352 100644
--- a/frontend/src/core/user/components/UserMenu.css
+++ b/frontend/src/core/user/components/UserMenu.css
@@ -12,7 +12,7 @@
.user-menu .selector .menu-icon,
.user-menu .menu... |
hpcaitech__ColossalAI-4028 | [BUG]: example of gpt gemini set a bucket size to 12T
### 🐛 Describe the bug
At https://github.com/hpcaitech/ColossalAI/blob/main/examples/language/gpt/gemini/train_gpt_demo.py#L253, which is
`reduce_bucket_size_in_m=12 * 1024 * 1024`, the bucket size of comm is set to 12T(12*1024*1024M), which leads to the bucket c... | [
{
"content": "import os\nfrom functools import partial\nfrom time import time\n\nimport psutil\nimport torch\nimport torch.nn as nn\nfrom commons.model_zoo import model_builder\nfrom commons.utils import get_data, get_profile_context, get_tflops, get_time_stamp\nfrom packaging import version\nfrom torch.nn.para... | [
{
"content": "import os\nfrom functools import partial\nfrom time import time\n\nimport psutil\nimport torch\nimport torch.nn as nn\nfrom commons.model_zoo import model_builder\nfrom commons.utils import get_data, get_profile_context, get_tflops, get_time_stamp\nfrom packaging import version\nfrom torch.nn.para... | diff --git a/examples/language/gpt/gemini/train_gpt_demo.py b/examples/language/gpt/gemini/train_gpt_demo.py
index 4b78624f0110..a7b552c9e23d 100644
--- a/examples/language/gpt/gemini/train_gpt_demo.py
+++ b/examples/language/gpt/gemini/train_gpt_demo.py
@@ -250,7 +250,7 @@ def main():
plugin = None
i... |
pfnet__pytorch-pfn-extras-668 | Consumption of 'autocast' option not properly performed due to 'get' operation on line 195 not being 'pop'
https://github.com/pfnet/pytorch-pfn-extras/blob/master/pytorch_pfn_extras/handler/_logic.py#L195
Since the 'get' operation on this line (line 195) is not 'pop', the consumption of the 'autocast' option is not ... | [
{
"content": "import contextlib\nimport dataclasses\nfrom typing import Any, Dict, Generator, Iterable, Mapping, Optional\nimport warnings\n\nimport torch\n\nfrom pytorch_pfn_extras.handler._code_block import forward, update_parameters\nfrom pytorch_pfn_extras.runtime import _autocast\n\n\n# Deprecated: kept fo... | [
{
"content": "import contextlib\nimport dataclasses\nfrom typing import Any, Dict, Generator, Iterable, Mapping, Optional\nimport warnings\n\nimport torch\n\nfrom pytorch_pfn_extras.handler._code_block import forward, update_parameters\nfrom pytorch_pfn_extras.runtime import _autocast\n\n\n# Deprecated: kept fo... | diff --git a/pytorch_pfn_extras/handler/_logic.py b/pytorch_pfn_extras/handler/_logic.py
index 3285141dc..b13e1fd5f 100644
--- a/pytorch_pfn_extras/handler/_logic.py
+++ b/pytorch_pfn_extras/handler/_logic.py
@@ -192,7 +192,7 @@ def consume_options(self, options: Dict[str, Any]) -> None:
self._grad_scaler = op... |
python-discord__bot-1521 | Logic in Source Command's Help Command Check
## Description
<!-- Describe the bug you've found -->
Its impossible to get the source for the HelpChannel cog.
## Steps to Reproduce
<!-- Detail the exact list of steps to be able to encounter the bug -->
`!src HelpChannel`
Due to the logic of the command, all that ... | [
{
"content": "import inspect\nfrom pathlib import Path\nfrom typing import Optional, Tuple, Union\n\nfrom discord import Embed, utils\nfrom discord.ext import commands\n\nfrom bot.bot import Bot\nfrom bot.constants import URLs\n\nSourceType = Union[commands.HelpCommand, commands.Command, commands.Cog, str, comm... | [
{
"content": "import inspect\nfrom pathlib import Path\nfrom typing import Optional, Tuple, Union\n\nfrom discord import Embed, utils\nfrom discord.ext import commands\n\nfrom bot.bot import Bot\nfrom bot.constants import URLs\n\nSourceType = Union[commands.HelpCommand, commands.Command, commands.Cog, str, comm... | diff --git a/bot/exts/info/source.py b/bot/exts/info/source.py
index 78a6f68acf..ef07c77a1c 100644
--- a/bot/exts/info/source.py
+++ b/bot/exts/info/source.py
@@ -14,9 +14,10 @@
class SourceConverter(commands.Converter):
"""Convert an argument into a help command, tag, command, or cog."""
- async def convert... |
conda__conda-build-2757 | 'conda index' is broken when info/recipe/meta.yaml contains non-rendered jinja2
Apparently, some older packages can contain non-rendered jinja2 in info/recipe/meta.yaml.
| [
{
"content": "'''\nFunctions related to creating repodata index files.\n'''\n\nfrom __future__ import absolute_import, division, print_function\n\nimport bz2\nfrom collections import defaultdict\nimport contextlib\nfrom datetime import datetime\nfrom functools import partial\nfrom glob import glob\nimport json\... | [
{
"content": "'''\nFunctions related to creating repodata index files.\n'''\n\nfrom __future__ import absolute_import, division, print_function\n\nimport bz2\nfrom collections import defaultdict\nimport contextlib\nfrom datetime import datetime\nfrom functools import partial\nfrom glob import glob\nimport json\... | diff --git a/conda_build/index.py b/conda_build/index.py
index 4ab6552c17..41689bbf2e 100644
--- a/conda_build/index.py
+++ b/conda_build/index.py
@@ -311,6 +311,9 @@ def _read_index_tar(tar_path, lock, locking=True, timeout=90):
recipe_json = yaml.load(recipe_text)
except KeyError:
... |
Qiskit__qiskit-4870 | Executing a schedule with one instruction raises an error
<!-- ⚠️ If you do not respect this template, your issue will be closed -->
<!-- ⚠️ Make sure to browse the opened and closed issues -->
### Information
- **Qiskit Terra version**:
- **Python version**:
- **Operating system**:
### What is the current ... | [
{
"content": "# -*- coding: utf-8 -*-\n\n# This code is part of Qiskit.\n#\n# (C) Copyright IBM 2017, 2019.\n#\n# This code is licensed under the Apache License, Version 2.0. You may\n# obtain a copy of this license in the LICENSE.txt file in the root directory\n# of this source tree or at http://www.apache.org... | [
{
"content": "# -*- coding: utf-8 -*-\n\n# This code is part of Qiskit.\n#\n# (C) Copyright IBM 2017, 2019.\n#\n# This code is licensed under the Apache License, Version 2.0. You may\n# obtain a copy of this license in the LICENSE.txt file in the root directory\n# of this source tree or at http://www.apache.org... | diff --git a/qiskit/assembler/assemble_schedules.py b/qiskit/assembler/assemble_schedules.py
index f8be2ea89c82..76f5a86e5d10 100644
--- a/qiskit/assembler/assemble_schedules.py
+++ b/qiskit/assembler/assemble_schedules.py
@@ -93,6 +93,10 @@ def _assemble_experiments(
converters.Ins... |
piskvorky__gensim-902 | ZeroDivisionError: float division by zero in pagerank_weighted.py
Got ZeroDivisionError: float division by zero in **pagerank_weighted.py**
Input Text: BYAnonymousArabe
Error thrown at: `summarize(text_to_sum, word_count=50)`
:
delimiter = prespace + delimiter_char + postspace
if key in se... |
encode__starlette-1609 | Gzip Middleware content-length is incorrect
The following exception is thrown when I use uvicorn to drive my starlette project. After control variates, I am sure this is caused by Gzip Middleware.
```
File "C:\Users\AberS\Documents\Github\index.py\.venv\lib\site-packages\h11\_writers.py", line 102, in send_eom
... | [
{
"content": "import typing\n\nimport anyio\n\nfrom starlette.requests import Request\nfrom starlette.responses import Response, StreamingResponse\nfrom starlette.types import ASGIApp, Receive, Scope, Send\n\nRequestResponseEndpoint = typing.Callable[[Request], typing.Awaitable[Response]]\nDispatchFunction = ty... | [
{
"content": "import typing\n\nimport anyio\n\nfrom starlette.requests import Request\nfrom starlette.responses import Response, StreamingResponse\nfrom starlette.types import ASGIApp, Receive, Scope, Send\n\nRequestResponseEndpoint = typing.Callable[[Request], typing.Awaitable[Response]]\nDispatchFunction = ty... | diff --git a/starlette/middleware/base.py b/starlette/middleware/base.py
index ca9deb7de..49a5e3e2d 100644
--- a/starlette/middleware/base.py
+++ b/starlette/middleware/base.py
@@ -52,7 +52,11 @@ async def body_stream() -> typing.AsyncGenerator[bytes, None]:
async with recv_stream:
... |
spack__spack-31321 | containerize: python+pythoncmd fails to produce working symlink for pythoncmd
When installing python+pythoncmd as part of an environment and exporting it to a container, the python symlink in the container is broken. A minimal reproducer is listed below.
For a given spack environment file:
```
sajid@LAPTOP-CDJT... | [
{
"content": "# Copyright 2013-2022 Lawrence Livermore National Security, LLC and other\n# Spack Project Developers. See the top-level COPYRIGHT file for details.\n#\n# SPDX-License-Identifier: (Apache-2.0 OR MIT)\n\"\"\"Writers for different kind of recipes and related\nconvenience functions.\n\"\"\"\nimport c... | [
{
"content": "# Copyright 2013-2022 Lawrence Livermore National Security, LLC and other\n# Spack Project Developers. See the top-level COPYRIGHT file for details.\n#\n# SPDX-License-Identifier: (Apache-2.0 OR MIT)\n\"\"\"Writers for different kind of recipes and related\nconvenience functions.\n\"\"\"\nimport c... | diff --git a/lib/spack/spack/container/writers/__init__.py b/lib/spack/spack/container/writers/__init__.py
index 9b38b8162f1f96..e9541e91e7625d 100644
--- a/lib/spack/spack/container/writers/__init__.py
+++ b/lib/spack/spack/container/writers/__init__.py
@@ -171,11 +171,12 @@ def strip(self):
def paths(self):
... |
openvinotoolkit__datumaro-804 | explain command cannot find the model
When I try to infer an image with a model included in the project using the command 'explain', I get the error :
**AttributeError: 'Tree' object has no attribute 'models'**
However, when I check the project info I see that the model is successfully added to the project, and t... | [
{
"content": "# Copyright (C) 2019-2021 Intel Corporation\n#\n# SPDX-License-Identifier: MIT\n\nimport argparse\nimport logging as log\nimport os\nimport os.path as osp\n\nfrom datumaro.util.image import is_image, load_image, save_image\nfrom datumaro.util.scope import scope_add, scoped\n\nfrom ..util import Mu... | [
{
"content": "# Copyright (C) 2019-2021 Intel Corporation\n#\n# SPDX-License-Identifier: MIT\n\nimport argparse\nimport logging as log\nimport os\nimport os.path as osp\n\nfrom datumaro.util.image import is_image, load_image, save_image\nfrom datumaro.util.scope import scope_add, scoped\n\nfrom ..util import Mu... | diff --git a/CHANGELOG.md b/CHANGELOG.md
index 0222b4979c..5ee77d472e 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -9,14 +9,14 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
### Fixed
- Fix for importing CVAT image 1.1 data format exported to project level
(<https://github.c... |
secdev__scapy-785 | Dot11QoS QoS Control bits in reverse order
Looking at the 802.11-2012 spec and Wireshark output, it appears that the TID, EOSP, Ack Policy, and Reserved fields are in reverse order of what they should be. I made Pull Request #785 with what I think is the correct ordering.
I modified the existing `Dot11QoS - build` ... | [
{
"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\"\"\"\nWireless LAN according to IEEE 802.11.\n\"\"\"\n\nfrom __future__ import print_functio... | [
{
"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\"\"\"\nWireless LAN according to IEEE 802.11.\n\"\"\"\n\nfrom __future__ import print_functio... | diff --git a/scapy/layers/dot11.py b/scapy/layers/dot11.py
index 383af0821f4..69b827998c5 100644
--- a/scapy/layers/dot11.py
+++ b/scapy/layers/dot11.py
@@ -178,10 +178,10 @@ def unwep(self, key=None, warn=1):
class Dot11QoS(Packet):
name = "802.11 QoS"
- fields_desc = [ BitField("TID",None,4),
- ... |
django-cms__django-cms-877 | Document the fact that the django-cms mptt must be removed after upgrade
Document the fact that the django-cms mptt must be removed after upgrade.
| [
{
"content": "# -*- coding: utf-8 -*-\nimport copy\nfrom datetime import datetime\nfrom os.path import join\n\nfrom django.conf import settings\nfrom django.contrib.sites.models import Site\nfrom django.core.exceptions import ObjectDoesNotExist\nfrom django.core.urlresolvers import reverse\nfrom django.db impor... | [
{
"content": "# -*- coding: utf-8 -*-\nimport copy\nfrom datetime import datetime\nfrom os.path import join\n\nfrom django.conf import settings\nfrom django.contrib.sites.models import Site\nfrom django.core.exceptions import ObjectDoesNotExist\nfrom django.core.urlresolvers import reverse\nfrom django.db impor... | diff --git a/cms/models/pagemodel.py b/cms/models/pagemodel.py
index bfe12b3c1cf..689686b263b 100644
--- a/cms/models/pagemodel.py
+++ b/cms/models/pagemodel.py
@@ -551,6 +551,10 @@ def get_absolute_url(self, language=None, fallback=True):
home_pk = self.home_pk_cache
except NoHome... |
mlflow__mlflow-6026 | Fix typos
🚨 When you work on this issue, please make sure the following 🚨
- Follow https://opensource.com/article/19/7/create-pull-request-github if you're unfamiliar with how to create a pull request on GitHub.
- Create a PR from a non-master branch.
- Do not create commits on GitHub UI. [The DCO bot](https://g... | [
{
"content": "\"\"\"\nNOTE: The contents of this file have been inlined from the wrapt package's source code\nhttps://github.com/GrahamDumpleton/wrapt/blob/1.12.1/src/wrapt/importer.py.\nSome modifications, have been made in order to:\n - avoid duplicate registration of import hooks\n - inline functions f... | [
{
"content": "\"\"\"\nNOTE: The contents of this file have been inlined from the wrapt package's source code\nhttps://github.com/GrahamDumpleton/wrapt/blob/1.12.1/src/wrapt/importer.py.\nSome modifications, have been made in order to:\n - avoid duplicate registration of import hooks\n - inline functions f... | diff --git a/mlflow/utils/import_hooks/__init__.py b/mlflow/utils/import_hooks/__init__.py
index 2bc27e32b0c7b..3f065b36bb7ca 100644
--- a/mlflow/utils/import_hooks/__init__.py
+++ b/mlflow/utils/import_hooks/__init__.py
@@ -39,7 +39,7 @@ def new_fn(*args, **kwargs):
# The dictionary registering any post import hooks ... |
pypa__cibuildwheel-1195 | When testing x86_64 on macOS arm64, `CIBW_TEST_COMMAND` isn't ran under Rosetta when using pipes
### Description
So basically, the problem is that the way cibuildwheel runs stuff under Rosetta is by prefixing the command with `arch -x86_64`. This works great for regular subprocess calls *but* when used with `shell=T... | [
{
"content": "import functools\nimport os\nimport platform\nimport re\nimport shutil\nimport subprocess\nimport sys\nfrom dataclasses import dataclass\nfrom pathlib import Path\nfrom typing import Dict, List, Sequence, Set, Tuple, cast\n\nfrom filelock import FileLock\n\nfrom .architecture import Architecture\n... | [
{
"content": "import functools\nimport os\nimport platform\nimport re\nimport shutil\nimport subprocess\nimport sys\nfrom dataclasses import dataclass\nfrom pathlib import Path\nfrom typing import Dict, List, Sequence, Set, Tuple, cast\n\nfrom filelock import FileLock\n\nfrom .architecture import Architecture\n... | diff --git a/cibuildwheel/macos.py b/cibuildwheel/macos.py
index beb4d32ea..d6b5b9828 100644
--- a/cibuildwheel/macos.py
+++ b/cibuildwheel/macos.py
@@ -505,7 +505,7 @@ def build(options: Options, tmp_path: Path) -> None:
# define a custom 'call' function that adds the arch prefix each time
... |
mit-ll-responsible-ai__hydra-zen-73 | Typing Error for `builds` using ART
I was hoping to make a simple example but I'm not sure what is causing the error:
```python
from art.estimators.classification import PyTorchClassifier
builds(PyTorchClassifier) # the config is actually incomplete but it never gets to that error
```
error:
```python
-... | [
{
"content": "# Copyright (c) 2021 Massachusetts Institute of Technology\n# SPDX-License-Identifier: MIT\n\nimport inspect\nfrom collections import defaultdict\nfrom dataclasses import Field, dataclass, field, fields, is_dataclass, make_dataclass\nfrom functools import partial\nfrom itertools import chain\nfrom... | [
{
"content": "# Copyright (c) 2021 Massachusetts Institute of Technology\n# SPDX-License-Identifier: MIT\n\nimport inspect\nfrom collections import defaultdict\nfrom dataclasses import Field, dataclass, field, fields, is_dataclass, make_dataclass\nfrom functools import partial\nfrom itertools import chain\nfrom... | diff --git a/src/hydra_zen/structured_configs/_implementations.py b/src/hydra_zen/structured_configs/_implementations.py
index d13fcf6f1..2afbc11cf 100644
--- a/src/hydra_zen/structured_configs/_implementations.py
+++ b/src/hydra_zen/structured_configs/_implementations.py
@@ -647,8 +647,9 @@ def builds(
ty... |
jupyterhub__jupyterhub-1958 | npm local install suggestion
Hi,
This is not a bug, it's a suggestion for occasional python users like me, who are not familiar with node.js and npm related commands.
Every single time when I start a new virtualenv, and install jupyterhub, runnung `jupyterhub` tells me:
Failed to find proxy ['configurable... | [
{
"content": "\"\"\"API for JupyterHub's proxy.\n\nCustom proxy implementations can subclass :class:`Proxy`\nand register in JupyterHub config:\n\n.. sourcecode:: python\n\n from mymodule import MyProxy\n c.JupyterHub.proxy_class = MyProxy\n\nRoute Specification:\n\n- A routespec is a URL prefix ([host]/p... | [
{
"content": "\"\"\"API for JupyterHub's proxy.\n\nCustom proxy implementations can subclass :class:`Proxy`\nand register in JupyterHub config:\n\n.. sourcecode:: python\n\n from mymodule import MyProxy\n c.JupyterHub.proxy_class = MyProxy\n\nRoute Specification:\n\n- A routespec is a URL prefix ([host]/p... | diff --git a/jupyterhub/proxy.py b/jupyterhub/proxy.py
index 8d25f13284..11cfdfe75a 100644
--- a/jupyterhub/proxy.py
+++ b/jupyterhub/proxy.py
@@ -488,7 +488,10 @@ async def start(self):
except FileNotFoundError as e:
self.log.error(
"Failed to find proxy %r\n"
- "T... |
ytdl-org__youtube-dl-3644 | KeyError: 'k'
i was hoping you could help me out with this:
[debug] System config: []
[debug] User config: []
[debug] Command-line args: ['http://www.tudou.com/programs/view/ajX3gyhL0pc/', '
-v']
[debug] Encodings: locale cp1252, fs mbcs, out cp850, pref cp1252
[debug] youtube-dl version 2014.08.29
[debug] Python vers... | [
{
"content": "# coding: utf-8\n\nimport re\nimport json\n\nfrom .common import InfoExtractor\n\n\nclass TudouIE(InfoExtractor):\n _VALID_URL = r'(?:http://)?(?:www\\.)?tudou\\.com/(?:listplay|programs|albumplay)/(?:view|(.+?))/(?:([^/]+)|([^/]+))(?:\\.html)?'\n _TESTS = [{\n u'url': u'http://www.tu... | [
{
"content": "# coding: utf-8\n\nimport re\nimport json\n\nfrom .common import InfoExtractor\n\n\nclass TudouIE(InfoExtractor):\n _VALID_URL = r'(?:http://)?(?:www\\.)?tudou\\.com/(?:listplay|programs|albumplay)/(?:view|(.+?))/(?:([^/]+)|([^/]+))(?:\\.html)?'\n _TESTS = [{\n u'url': u'http://www.tu... | diff --git a/youtube_dl/extractor/tudou.py b/youtube_dl/extractor/tudou.py
index 7a3891b89b7..23816599c6d 100644
--- a/youtube_dl/extractor/tudou.py
+++ b/youtube_dl/extractor/tudou.py
@@ -57,7 +57,9 @@ def _real_extract(self, url):
segments = json.loads(segs_json)
# It looks like the keys are the arg... |
beetbox__beets-3453 | fetchart: Logged requests ignore proxy settings from environment variables
### Problem
I recently noticed that beet is not embedding album art in my music files as I import them if they are not available locally. So I ran`beet fetchart` command and tried running it in verbose mode for one of the failed albums.
I th... | [
{
"content": "# -*- coding: utf-8 -*-\n# This file is part of beets.\n# Copyright 2016, Adrian Sampson.\n#\n# Permission is hereby granted, free of charge, to any person obtaining\n# a copy of this software and associated documentation files (the\n# \"Software\"), to deal in the Software without restriction, in... | [
{
"content": "# -*- coding: utf-8 -*-\n# This file is part of beets.\n# Copyright 2016, Adrian Sampson.\n#\n# Permission is hereby granted, free of charge, to any person obtaining\n# a copy of this software and associated documentation files (the\n# \"Software\"), to deal in the Software without restriction, in... | diff --git a/beetsplug/fetchart.py b/beetsplug/fetchart.py
index a815d4d9b7..f78e6116a4 100644
--- a/beetsplug/fetchart.py
+++ b/beetsplug/fetchart.py
@@ -164,9 +164,14 @@ def _logged_get(log, *args, **kwargs):
message = 'getting URL'
req = requests.Request('GET', *args, **req_kwargs)
+
with reques... |
freedomofpress__securedrop-4865 | update ansible to 2.6.18 or later due to CVE-2019-10156
## Description
We should update Ansible to version 2.6.18 or later due to [CVE-2019-10156](https://nvd.nist.gov/vuln/detail/CVE-2019-10156). This is a templating vulnerability that would require an attacker to first insert malicious templates into the Admin wor... | [
{
"content": "# -*- encoding:utf-8 -*-\nfrom __future__ import absolute_import, division, print_function, \\\n unicode_literals\n\nimport sys\n\nimport ansible\n\ntry:\n # Version 2.0+\n from ansible.plugins.callback import CallbackBase\nexcept ImportError:\n CallbackBase = object\n\n\ndef print... | [
{
"content": "# -*- encoding:utf-8 -*-\nfrom __future__ import absolute_import, division, print_function, \\\n unicode_literals\n\nimport sys\n\nimport ansible\n\ntry:\n # Version 2.0+\n from ansible.plugins.callback import CallbackBase\nexcept ImportError:\n CallbackBase = object\n\n\ndef print... | diff --git a/.circleci/config.yml b/.circleci/config.yml
index dc8d1b5bd6..0201cfe11f 100644
--- a/.circleci/config.yml
+++ b/.circleci/config.yml
@@ -74,7 +74,7 @@ jobs:
name: Run all linters but shellcheck
command: |
fromtag=$(docker images |grep securedrop-test-xenial-py3 |head -n1... |
DataDog__dd-agent-2469 | [wmi] Filter documentation
The comment in https://github.com/DataDog/dd-agent/blob/master/checks/libs/wmi/sampler.py#L314-L317 says that `*` is a valid wilcard to use in WMI filters, but it's not actually processed in the code that follows said comment.
Only `%` is processed, which is fine, but I think the `*` should ... | [
{
"content": "# pylint: disable=E0401\n\"\"\"\nA lightweight Python WMI module wrapper built on top of `pywin32` and `win32com` extensions.\n\n**Specifications**\n* Based on top of the `pywin32` and `win32com` third party extensions only\n* Compatible with `Raw`* and `Formatted` Performance Data classes\n * ... | [
{
"content": "# pylint: disable=E0401\n\"\"\"\nA lightweight Python WMI module wrapper built on top of `pywin32` and `win32com` extensions.\n\n**Specifications**\n* Based on top of the `pywin32` and `win32com` third party extensions only\n* Compatible with `Raw`* and `Formatted` Performance Data classes\n * ... | diff --git a/checks/libs/wmi/sampler.py b/checks/libs/wmi/sampler.py
index a9a7aaf546..4d4e724c8a 100644
--- a/checks/libs/wmi/sampler.py
+++ b/checks/libs/wmi/sampler.py
@@ -295,8 +295,8 @@ def _format_filter(filters, and_props=[]):
NOTE: If we just provide a value we defailt to '=' comparison opera... |
googleapis__google-auth-library-python-953 | Mandatory urllib3 dependency introduced without declaration by 2.4.0 release
@arithmetic1728 I think https://github.com/googleapis/google-auth-library-python/pull/948 may have broken the 2.4.0 release. `google-auth` [does not declare a dependency on `urllib3`](https://github.com/googleapis/google-auth-library-python/bl... | [
{
"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/transport/requests.py b/google/auth/transport/requests.py
index 46ca669ff..a55b5f57b 100644
--- a/google/auth/transport/requests.py
+++ b/google/auth/transport/requests.py
@@ -36,10 +36,10 @@
)
import requests.adapters # pylint: disable=ungrouped-imports
import requests.exceptions # py... |
lutris__lutris-1610 | [master] Can't open winecfg
**Steps to reproduce:** Right click a wine game -> Wine Configuration
**Expected behaviour:** Winecfg opens without any tracebacks
**Observed behaviour:** Winecfg does not open. Terminal prints this:
```
DEBUG 2019-01-15 15:25:39,885 [wine.winecfg:365]:winecfg: /home/username/.local/s... | [
{
"content": "\"\"\"Wine commands for installers\"\"\"\n# pylint: disable=too-many-arguments\nimport os\nimport shlex\nimport time\n\nfrom lutris import runtime, settings\nfrom lutris.config import LutrisConfig\nfrom lutris.runners import import_runner\nfrom lutris.command import MonitoredCommand\nfrom lutris.u... | [
{
"content": "\"\"\"Wine commands for installers\"\"\"\n# pylint: disable=too-many-arguments\nimport os\nimport shlex\nimport time\n\nfrom lutris import runtime, settings\nfrom lutris.config import LutrisConfig\nfrom lutris.runners import import_runner\nfrom lutris.command import MonitoredCommand\nfrom lutris.u... | diff --git a/lutris/runners/commands/wine.py b/lutris/runners/commands/wine.py
index 83b4093929..e9debfd6e6 100644
--- a/lutris/runners/commands/wine.py
+++ b/lutris/runners/commands/wine.py
@@ -244,8 +244,10 @@ def wineexec(
MonitoredCommand instance otherwise.
"""
executable = str(executable) if ex... |
Kinto__kinto-1138 | Enforce the permission endpoint when the admin plugin is included.
Enforce the permission endpoint when the admin plugin is included.
| [
{
"content": "import pkg_resources\nimport logging\n\nimport kinto.core\nfrom pyramid.config import Configurator\nfrom pyramid.settings import asbool\nfrom pyramid.security import Authenticated, Everyone\n\nfrom kinto.authorization import RouteFactory\n\n\n# Module version, as defined in PEP-0396.\n__version__ ... | [
{
"content": "import pkg_resources\nimport logging\n\nimport kinto.core\nfrom pyramid.config import Configurator\nfrom pyramid.settings import asbool\nfrom pyramid.security import Authenticated, Everyone\n\nfrom kinto.authorization import RouteFactory\n\n\n# Module version, as defined in PEP-0396.\n__version__ ... | diff --git a/CHANGELOG.rst b/CHANGELOG.rst
index 175b3a9a1..669a6a568 100644
--- a/CHANGELOG.rst
+++ b/CHANGELOG.rst
@@ -18,6 +18,10 @@ This document describes changes between each past release.
Protocol is now at version **1.16**. See `API changelog`_.
+**New features**
+
+- Enforce the permission endpoint when t... |
freedomofpress__securedrop-4884 | Upgrade Ansble to 2.7 series
## Description
SecureDrop currently uses the Ansible 2.6 series which is approaching end-of-life. Ansible major versions are supported (receive security patches) for [three major releases](https://docs.ansible.com/ansible/latest/reference_appendices/release_and_maintenance.html).
We s... | [
{
"content": "# -*- encoding:utf-8 -*-\nfrom __future__ import absolute_import, division, print_function, \\\n unicode_literals\n\nimport sys\n\nimport ansible\n\ntry:\n # Version 2.0+\n from ansible.plugins.callback import CallbackBase\nexcept ImportError:\n CallbackBase = object\n\n\ndef print... | [
{
"content": "# -*- encoding:utf-8 -*-\nfrom __future__ import absolute_import, division, print_function, \\\n unicode_literals\n\nimport sys\n\nimport ansible\n\ntry:\n # Version 2.0+\n from ansible.plugins.callback import CallbackBase\nexcept ImportError:\n CallbackBase = object\n\n\ndef print... | diff --git a/admin/requirements-ansible.in b/admin/requirements-ansible.in
index 09201692c6..ee439ee79d 100644
--- a/admin/requirements-ansible.in
+++ b/admin/requirements-ansible.in
@@ -1,3 +1,3 @@
-ansible>2.6<2.7
+ansible>2.7<2.8
cryptography>=2.7
netaddr
diff --git a/admin/requirements.txt b/admin/requirements.tx... |
spack__spack-40344 | Spack add parser: Unbounded version specifier followed by another spec
### Steps to reproduce
An error occur when running this command:
```spack add opa-psm2^cuda@10.2: nccl
Error: 10.2:nccm is an empty range
```
You can reproduce this whenever you have 2 specs to add, use unbounded version specifier as last part... | [
{
"content": "# Copyright 2013-2023 Lawrence Livermore National Security, LLC and other\n# Spack Project Developers. See the top-level COPYRIGHT file for details.\n#\n# SPDX-License-Identifier: (Apache-2.0 OR MIT)\n\"\"\"Parser for spec literals\n\nHere is the EBNF grammar for a spec::\n\n spec = [n... | [
{
"content": "# Copyright 2013-2023 Lawrence Livermore National Security, LLC and other\n# Spack Project Developers. See the top-level COPYRIGHT file for details.\n#\n# SPDX-License-Identifier: (Apache-2.0 OR MIT)\n\"\"\"Parser for spec literals\n\nHere is the EBNF grammar for a spec::\n\n spec = [n... | diff --git a/lib/spack/spack/parser.py b/lib/spack/spack/parser.py
index d8f34d7e595d6e..31e44330465da5 100644
--- a/lib/spack/spack/parser.py
+++ b/lib/spack/spack/parser.py
@@ -95,9 +95,9 @@
VALUE = r"([a-zA-Z_0-9\-+\*.,:=\~\/\\]+)"
QUOTED_VALUE = r"[\"']+([a-zA-Z_0-9\-+\*.,:=\~\/\\\s]+)[\"']+"
-VERSION = r"=?([a... |
LMFDB__lmfdb-1608 | Typo in genus 2 decomposition
See:
http://lmfdb.org/Genus2Curve/Q/900601/a/900601/1
At the bottom, the polynomial is not formatted correctly. Not sure if this is a one-off (in which case I can quickly fix it), or if it occurs in other cases.
| [
{
"content": "# -*- coding: utf-8 -*-\nfrom pymongo import ASCENDING\nfrom ast import literal_eval\nfrom lmfdb.base import getDBConnection\nfrom lmfdb.utils import web_latex, encode_plot\nfrom lmfdb.ecnf.main import split_full_label\nfrom lmfdb.elliptic_curves.web_ec import split_lmfdb_label\nfrom lmfdb.number_... | [
{
"content": "# -*- coding: utf-8 -*-\nfrom pymongo import ASCENDING\nfrom ast import literal_eval\nfrom lmfdb.base import getDBConnection\nfrom lmfdb.utils import web_latex, encode_plot\nfrom lmfdb.ecnf.main import split_full_label\nfrom lmfdb.elliptic_curves.web_ec import split_lmfdb_label\nfrom lmfdb.number_... | diff --git a/lmfdb/genus2_curves/web_g2c.py b/lmfdb/genus2_curves/web_g2c.py
index 94cafcd19d..1f7cb317d1 100644
--- a/lmfdb/genus2_curves/web_g2c.py
+++ b/lmfdb/genus2_curves/web_g2c.py
@@ -433,7 +433,7 @@ def split_field_statement(is_simple_geom, field_label, poly):
return """Splits over the number field \(\... |
cookiecutter__cookiecutter-django-2457 | Serving media files without an external service
## Description
Currently, in order to serve media files, you need an external file storage service. Setting up an external file storage service introduces some complexity (especially for people who do not already use these services), as well as potentially extra costs. E... | [
{
"content": "\"\"\"\nNOTE:\n the below code is to be maintained Python 2.x-compatible\n as the whole Cookiecutter Django project initialization\n can potentially be run in Python 2.x environment\n (at least so we presume in `pre_gen_project.py`).\n\nTODO: restrict Cookiecutter Django project initia... | [
{
"content": "\"\"\"\nNOTE:\n the below code is to be maintained Python 2.x-compatible\n as the whole Cookiecutter Django project initialization\n can potentially be run in Python 2.x environment\n (at least so we presume in `pre_gen_project.py`).\n\nTODO: restrict Cookiecutter Django project initia... | diff --git a/README.md b/README.md
index 7ab0b7e152..aaeb25828b 100644
--- a/README.md
+++ b/README.md
@@ -31,7 +31,7 @@ production-ready Django projects quickly.
- Optional basic ASGI setup for Websockets
- Optional custom static build using Gulp or Webpack
- Send emails via [Anymail](https://github.com/anyma... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.