internlm/SWE-Fixer-Train-110K huggingface dataset:
Repository: biolab/orange3

Issue:
Bugs in SOM
SOM seems to have a few problems. See https://github.com/biolab/orange3/files/14397182/log.txt.


Discussion:

Resolving patch:
diff --git a/Orange/widgets/unsupervised/owsom.py b/Orange/widgets/unsupervised/owsom.py
--- a/Orange/widgets/unsupervised/owsom.py
+++ b/Orange/widgets/unsupervised/owsom.py
@@ -1018,7 +1018,7 @@ def make_domain(values, default_grp, offset):
                 compute_value=GetGroups(id_to_group, default_grp, offset))
 
             if not self.data.domain.class_vars:
-                class_vars, metas = grp_var, som_attrs
+                class_vars, metas = (grp_var,), som_attrs
             else:
                 class_vars, metas = (), (grp_var,) + som_attrs
             return add_columns(self.data.domain, (), class_vars, metas)


Test patch:
diff --git a/Orange/widgets/unsupervised/tests/test_owsom.py b/Orange/widgets/unsupervised/tests/test_owsom.py
--- a/Orange/widgets/unsupervised/tests/test_owsom.py
+++ b/Orange/widgets/unsupervised/tests/test_owsom.py
@@ -723,6 +723,18 @@ def test_modified_info(self):
         restart_button.click()
         self.assertFalse(w.Information.modified.is_shown())
 
+    def test_make_domain_without_class_vars(self):
+        widget = self.widget
+        data = self.iris.transform(Domain(self.iris.domain.attributes))
+        self.send_signal(self.widget.Inputs.data, data)
+
+        domain = self.get_output((widget.Outputs.annotated_data)).domain
+        self.assertEqual(domain.attributes, data.domain.attributes)
+        self.assertEqual(domain.class_var.name, ANNOTATED_DATA_FEATURE_NAME)
+        self.assertEqual([var.name for var in domain.metas],
+                         ["som_cell", "som_row", "som_col", "som_error"])
+
+
 
 class TestComputeValues(unittest.TestCase):
     def test_eq_hash(self):
Repository: biolab/orange3

Issue:
ROC Curve widget sets a wrong prior probability
With apologies to self for writing such a bad bug report: I have no time to properly explore it now, but I have to write this down lest I forget.

I encountered a situation (on Pima diabetes data) in which the ROC widget's target was set to 1, but the prior probability was that for class 0. I changed the target to 0 and back to 1, and the prior probabilty was reset properly. My hunch is that if the widget was loaded in the workflow, the target is retrieved from settings, but the prior probability is set before and disregarding the target. Changing the target back and forth calls the necessary callbacks and updates the prior probability. This is just a hypothesis, I don't have time to actually reproduce the bug and check the code.


Discussion:
Here's how to reproduce the bug:

- Load Zoo, feed it to Test and Score, use an arbitrary learning algorithm (e.g. Logistic regression). Connect ROC Analysis to Test and Score.
- In ROC Analysis, you will see that `Target` is set to `amphibian`, and `Prior probability` is `4 %` (proportion of amphibians).
- Change `Target` to `mammal`. `Prior probability` changes to `41 %` (proportion of mammals).
- In File widget, click Reload.
- In ROC Analysis, `Target` is still `mammal` (which is correct)`, but `Prior probability` changes to `4 %`, which is proportion of amphibians. The correct value would be `41 %`, as before (proportion of mammals).

Resolving patch:
diff --git a/Orange/widgets/evaluate/owrocanalysis.py b/Orange/widgets/evaluate/owrocanalysis.py
--- a/Orange/widgets/evaluate/owrocanalysis.py
+++ b/Orange/widgets/evaluate/owrocanalysis.py
@@ -442,6 +442,7 @@ def set_results(self, results):
             self._initialize(self.results)
             self.openContext(self.results.domain.class_var,
                              self.classifier_names)
+            self._set_target_prior()
             self._setup_plot()
         else:
             self.warning()


Test patch:
diff --git a/Orange/widgets/evaluate/tests/test_owrocanalysis.py b/Orange/widgets/evaluate/tests/test_owrocanalysis.py
--- a/Orange/widgets/evaluate/tests/test_owrocanalysis.py
+++ b/Orange/widgets/evaluate/tests/test_owrocanalysis.py
@@ -278,6 +278,14 @@ def test_target_prior(self):
         simulate.combobox_activate_item(w.controls.target_index, "soft")
         self.assertEqual(np.round(5/12 * 100), w.target_prior)
 
+    def test_target_prior_reload(self):
+        w = self.widget
+        self.send_signal(w.Inputs.evaluation_results, self.res)
+        simulate.combobox_activate_item(w.controls.target_index, "soft")
+        self.assertEqual(np.round(5/12 * 100), w.target_prior)
+        self.send_signal(w.Inputs.evaluation_results, self.res)
+        self.assertEqual(np.round(5/12 * 100), w.target_prior)
+
     @patch("Orange.widgets.evaluate.owrocanalysis.ThresholdClassifier")
     def test_apply_no_output(self, *_):
         """Test no output warnings"""
Repository: microsoft/lisa

Issue:
package installation update for file system tests (RHEL 8.x)
pass after manual changes. missing dependencies in rhel8: indent and llvm-ocaml-devel and btrfs-progs-devel and python (replaced with python36)
--





Discussion:

Resolving patch:
diff --git a/Testscripts/Linux/VERIFY-VHD-PREREQUISITES.py b/Testscripts/Linux/VERIFY-VHD-PREREQUISITES.py
--- a/Testscripts/Linux/VERIFY-VHD-PREREQUISITES.py
+++ b/Testscripts/Linux/VERIFY-VHD-PREREQUISITES.py
@@ -46,7 +46,13 @@ def verify_grub(distro):
             print(distro+"_TEST_GRUB_VERIFICATION_FAIL")
             return False
     if distro == "CENTOS" or distro == "ORACLELINUX" or distro == "REDHAT" or distro == "SLES" or distro == "FEDORA":
-        if os.path.isfile("/boot/grub2/grub.cfg"):
+        version_release = 0
+        if distro == "REDHAT":
+            version_release = Run("cat /etc/system-release | grep -Eo '[0-9].?[0-9]?' | head -1 | tr -d '\n'")
+        if float(version_release) == 8.0:
+            RunLog.info("Getting Contents of /boot/grub2/grubenv")
+            grub_out = Run("cat /boot/grub2/grubenv")
+        elif os.path.isfile("/boot/grub2/grub.cfg"):
             RunLog.info("Getting Contents of /boot/grub2/grub.cfg")
             grub_out = Run("cat /boot/grub2/grub.cfg")
         elif os.path.isfile("/boot/grub/menu.lst"):


Test patch:
Repository: microsoft/lisa

Issue:
VERIFY-BOOT-ERROR-WARNINGS.py: fix test case
Test case is not running properly on redhat. Run the script directly, not through lisav2 to observe this better.

Release: 7.7 Snapshot 5 (most likely 7.6 should also have this behavior)

Issues to be fixed:
- ignore if syslog is not present (that exists only on ubuntu/debian).
[root@rhel77gen2 Linux]# python VERIFY-BOOT-ERROR-WARNINGS.py
2.7.5 (default, Jun 11 2019, 14:33:56)
[GCC 4.8.5 20150623 (Red Hat 4.8.5-39)]
grep: /var/log/syslog: No such file or directory

- fix grep search
[root@rhel77gen2 Linux]#  grep -nw '/var/log/messages' -e 'mlx5'
[root@rhel77gen2 Linux]# grep /var/log/messages -e mlx5
Jul 29 10:02:27 rhel77gen2 kernel: mlx5_core ae35:00:02.0: firmware version: 14.23.1020



Discussion:
@v-sijliu Please cover this 
@chvalean Could you please let know which distro you use?

Resolving patch:
diff --git a/Testscripts/Linux/VERIFY-BOOT-ERROR-WARNINGS.py b/Testscripts/Linux/VERIFY-BOOT-ERROR-WARNINGS.py
--- a/Testscripts/Linux/VERIFY-BOOT-ERROR-WARNINGS.py
+++ b/Testscripts/Linux/VERIFY-BOOT-ERROR-WARNINGS.py
@@ -9,9 +9,9 @@
 def RunTest():
     UpdateState("TestRunning")
     RunLog.info("Checking for ERROR and WARNING messages in system logs.")
-    errors = Run("grep -nw '/var/log/syslog' -e 'error' --ignore-case && grep -nw '/var/log/messages' -e 'error' --ignore-case")
-    warnings = Run("grep -nw '/var/log/syslog' -e 'warning' --ignore-case && grep -nw '/var/log/messages' -e 'warning' --ignore-case")
-    failures = Run("grep -nw '/var/log/syslog' -e 'fail' --ignore-case && grep -nw '/var/log/messages' -e 'fail' --ignore-case")
+    errors = Run("grep -nw '/var/log/syslog' -e 'error' --ignore-case --no-message && grep /var/log/messages -e error --ignore-case --no-message")
+    warnings = Run("grep -nw '/var/log/syslog' -e 'warning' --ignore-case --no-message && grep /var/log/messages -e warning --ignore-case --no-message")
+    failures = Run("grep -nw '/var/log/syslog' -e 'fail' --ignore-case --no-message && grep /var/log/messages -e fail --ignore-case --no-message")
     if (not errors and not warnings and not failures):
         RunLog.info('Could not find ERROR/WARNING/FAILURE messages in syslog/messages log file.')
         ResultLog.info('PASS')


Test patch:
Repository: microsoft/lisa

Issue:
CentOS8 has new changes
1. python is no longer default, so it had to instaill python2 first. And create a soft link in /usr/bin/python.
2. Need to make sure how to do with kdump-tools and makedumpfile dependency installation. They are not in the official repo site.
3. c.	CENTOS_TEST_REPOSITORIES_AVAILABLE & CENTOS_TEST_GRUB_VERIFICATION_SUCCESS are missing.  The meta data shows below only.

_Last metadata expiration check: 0:00:23 ago on Fri 01 Nov 2019 11:19:26 PM UTC.
repo id           repo name                       status
AppStream         CentOS-8 - AppStream            5,532
BaseOS            CentOS-8 - Base                 2,847_



Discussion:

Resolving patch:
diff --git a/Testscripts/Linux/VERIFY-VHD-PREREQUISITES.py b/Testscripts/Linux/VERIFY-VHD-PREREQUISITES.py
--- a/Testscripts/Linux/VERIFY-VHD-PREREQUISITES.py
+++ b/Testscripts/Linux/VERIFY-VHD-PREREQUISITES.py
@@ -47,7 +47,7 @@ def verify_grub(distro):
             return False
     if distro == "CENTOS" or distro == "ORACLELINUX" or distro == "REDHAT" or distro == "SLES" or distro == "FEDORA":
         version_release = 0
-        if distro == "REDHAT":
+        if distro == "REDHAT" or distro == "CENTOS":
             version_release = Run("cat /etc/system-release | grep -Eo '[0-9].?[0-9]?' | head -1 | tr -d '\n'")
         if float(version_release) == 8.0:
             RunLog.info("Getting Contents of /boot/grub2/grubenv")
@@ -277,13 +277,13 @@ def verify_udev_rules(distro):
     result = verify_udev_rules(distro)
     #Verify repositories
     r_out = Run("yum repolist")
-    if "base" in r_out and "updates" in r_out:
+    if "base" in r_out.lower() and "updates" in r_out.lower():
         RunLog.info("Expected repositories are present")
         print(distro+"_TEST_REPOSITORIES_AVAILABLE")
     else:
-        if "base" not in r_out:
+        if "base" not in r_out.lower():
             RunLog.error("Base repository not present")
-        if "updates" not in r_out:
+        if "updates" not in r_out.lower():
             RunLog.error("Updates repository not present")
         print(distro+"_TEST_REPOSITORIES_ERROR")
     #Verify etc/yum.conf


Test patch:
Repository: microsoft/lisa

Issue:
Ubuntu 20.04 - platform.dist()  is deprecated since Python 3.5 and removed in Python 3.8
Affected distro - ubuntu 20.04 (use python 3.8)
Affected case - WALA-VERIFY-VERBOSE-ENABLED-LOGS
Use distro.linux_distribution(full_distribution_name=False) instead


Discussion:

Resolving patch:
diff --git a/Testscripts/Linux/WALA-VERIFY-VERBOSE-ENABLED-LOGS.py b/Testscripts/Linux/WALA-VERIFY-VERBOSE-ENABLED-LOGS.py
--- a/Testscripts/Linux/WALA-VERIFY-VERBOSE-ENABLED-LOGS.py
+++ b/Testscripts/Linux/WALA-VERIFY-VERBOSE-ENABLED-LOGS.py
@@ -7,6 +7,7 @@
 import os
 import platform
 import time
+import sys
 
 parser = argparse.ArgumentParser()
 
@@ -14,13 +15,16 @@
 constants_path = os.path.join(file_path, "constants.sh")
 params = GetParams(constants_path)
 passwd = params["PASSWORD"]
-
-distro = platform.dist()
+if sys.version_info[0] >= 3:
+    import distro
+    distro = distro.linux_distribution(full_distribution_name=False)
+else:
+    distro = platform.dist()
 
 
 def RunTest():
     UpdateState("TestRunning")
-    if(distro[0] == "CoreOS"):
+    if(distro[0].upper() == "COREOS"):
         versionOutPut = Run("waagent --version")
     else:
         output = Run("pgrep -fa python3.*waagent")
@@ -48,7 +52,7 @@ def RunTest():
 
 
 def Restartwaagent():
-    if (distro[0] == "CoreOS"):
+    if (distro[0].upper() == "COREOS"):
         Run("echo '"+passwd+"' | sudo -S sed -i s/Logs.Verbose=n/Logs.Verbose=y/g  /usr/share/oem/waagent.conf")
     elif (DetectDistro()[0] == 'clear-linux-os'):
         Run("echo '"+passwd+"' | sudo -S sed -i s/Logs.Verbose=n/Logs.Verbose=y/g  \
@@ -57,7 +61,7 @@ def Restartwaagent():
         Run("echo '"+passwd+"' | sudo -S sed -i s/Logs.Verbose=n/Logs.Verbose=y/g  /etc/waagent.conf")
     RunLog.info("Restart waagent service...")
     result = Run("echo '"+passwd+"' | sudo -S find / -name systemctl |wc -l | tr -d '\n'")
-    if (distro[0] == "Ubuntu") or (distro[0] == "debian"):
+    if (distro[0].upper() == "UBUNTU") or (distro[0].upper() == "DEBIAN"):
         Run("echo '"+passwd+"' | sudo -S service walinuxagent restart")
     else:
         if (result == "0") :


Test patch:
Repository: microsoft/lisa

Issue:
[Log] typo in log
There's a typo in log: tocount -> to count

![图片](https://github.com/microsoft/lisa/assets/712433/9972adee-d11c-4165-bcec-1ca6a29421f3)

And I ask to improve the log. It's not a case missing `nvidia-smi`.


Discussion:
@hcoona welcome to contribute on lisa.
@adityagesh could you please fix this issue, thanks!

Resolving patch:
diff --git a/microsoft/testsuites/gpu/gpusuite.py b/microsoft/testsuites/gpu/gpusuite.py
--- a/microsoft/testsuites/gpu/gpusuite.py
+++ b/microsoft/testsuites/gpu/gpusuite.py
@@ -346,7 +346,7 @@ def _check_driver_installed(node: Node, log: Logger) -> None:
         lspci_gpucount = gpu.get_gpu_count_with_lspci()
         nvidiasmi_gpucount = nvidia_smi.get_gpu_count()
         assert_that(lspci_gpucount).described_as(
-            f"GPU count from lspci {lspci_gpucount} not equal to"
+            f"GPU count from lspci {lspci_gpucount} not equal to "
             f"count from nvidia-smi {nvidiasmi_gpucount}"
         ).is_equal_to(nvidiasmi_gpucount)
     except Exception as identifier:


Test patch:
Repository: diofant/diofant

Issue:
exp(n*x).subs({exp(x): x}) doesn't work for integer symbol n
References:
https://github.com/skirpichev/omg/pull/116#issuecomment-131186652
https://groups.google.com/forum/#!topic/sympy/xEgWEcg6Puk

```
In [2]: n = Symbol('n', integer=True)

In [3]: x = Symbol('x')

In [4]: exp(3*x).subs({exp(x): x})
Out[4]: x**3

In [5]: exp(n*x).subs({exp(x): x})
Out[5]: exp(n*x)
```



Discussion:

Resolving patch:
diff --git a/sympy/core/power.py b/sympy/core/power.py
--- a/sympy/core/power.py
+++ b/sympy/core/power.py
@@ -526,8 +526,8 @@ def _check(ct1, ct2, old):
 
         if old.func is self.func and self.base == old.base:
             if self.exp.is_Add is False:
-                ct1 = self.exp.as_independent(Symbol, as_Add=False)
                 ct2 = old.exp.as_independent(Symbol, as_Add=False)
+                ct1 = (self.exp/ct2[1], ct2[1])
                 ok, pow = _check(ct1, ct2, old)
                 if ok:
                     # issue 5180: (x**(6*y)).subs(x**(3*y),z)->z**2


Test patch:
diff --git a/sympy/core/tests/test_subs.py b/sympy/core/tests/test_subs.py
--- a/sympy/core/tests/test_subs.py
+++ b/sympy/core/tests/test_subs.py
@@ -651,3 +651,8 @@ def test_pow_eval_subs_no_cache():
     # It incorrectly returned 1/sqrt(x**2) before.
     result = s.subs(sqrt(x**2), y)
     assert result == 1/y
+
+
+def test_omgissue_124():
+    n = Symbol('n', integer=True)
+    assert exp(n*x).subs({exp(x): x}) == x**n
Repository: diofant/diofant

Issue:
Wrong hyperexpand(hyper((-6, -7, -5), (-6, -6), 1))
Right now it's 0, should be -1/6.

See https://groups.google.com/forum/?fromgroups=#!topic/sympy/pfYJI-lxkYE



Discussion:

Resolving patch:
diff --git a/sympy/simplify/hyperexpand.py b/sympy/simplify/hyperexpand.py
--- a/sympy/simplify/hyperexpand.py
+++ b/sympy/simplify/hyperexpand.py
@@ -1342,7 +1342,7 @@ def __new__(cls, ai, bj):
         n = ai - bj
         if not n.is_Integer or n < 0:
             return
-        if bj.is_integer and bj <= 0 and bj + n - 1 >= 0:
+        if bj.is_integer and bj <= 0:
             return
 
         expr = Operator.__new__(cls)
@@ -1706,7 +1706,7 @@ def try_polynomial(func, z):
     al0 = [x for x in a0 if x <= 0]
     bl0 = [x for x in b0 if x <= 0]
 
-    if bl0:
+    if bl0 and len(al0) <= 1:
         return oo
     if not al0:
         return


Test patch:
diff --git a/sympy/simplify/tests/test_hyperexpand.py b/sympy/simplify/tests/test_hyperexpand.py
--- a/sympy/simplify/tests/test_hyperexpand.py
+++ b/sympy/simplify/tests/test_hyperexpand.py
@@ -1013,3 +1013,10 @@ def test_prudnikov_fail_other():
 def test_bug():
     h = hyper([-1, 1], [z], -1)
     assert hyperexpand(h) == (z + 1)/z
+
+
+def test_omgissue_203():
+    h = hyper((-5, -3, -4), (-6, -6), 1)
+    assert hyperexpand(h) == Rational(1, 30)
+    h = hyper((-6, -7, -5), (-6, -6), 1)
+    assert hyperexpand(h) == -Rational(1, 6)
Repository: diofant/diofant

Issue:
Plotting doesn't work with matplotlib 2.0.0 
See https://travis-ci.org/diofant/diofant/jobs/192710635


Discussion:

Resolving patch:
diff --git a/diofant/plotting/plot.py b/diofant/plotting/plot.py
--- a/diofant/plotting/plot.py
+++ b/diofant/plotting/plot.py
@@ -372,7 +372,7 @@ def get_color_array(self):
         np = import_module('numpy')
         c = self.line_color
         if hasattr(c, '__call__'):
-            f = np.vectorize(c)
+            f = np.vectorize(c, otypes=[np.float64])
             arity = len(getfullargspec(c)[0])
             if arity == 1 and self.is_parametric:
                 x = self.get_parameter_points()
@@ -672,7 +672,7 @@ def get_color_array(self):
         np = import_module('numpy')
         c = self.surface_color
         if isinstance(c, Callable):
-            f = np.vectorize(c)
+            f = np.vectorize(c, otypes=[np.float64])
             arity = len(getfullargspec(c)[0])
             if self.is_parametric:
                 variables = list(map(centers_of_faces, self.get_parameter_meshes()))
diff --git a/setup.py b/setup.py
--- a/setup.py
+++ b/setup.py
@@ -31,7 +31,7 @@
 setup_reqs = ['setuptools>=5.5.1', 'pip>=6.0', 'pytest-runner']
 extra_reqs = {'exports': ['numpy', 'scipy', 'Theano'],
               'gmpy': ['gmpy2>2.0.3'],
-              'plot': ['pyparsing!=2.1.2', 'matplotlib!=2.0.0'],
+              'plot': ['pyparsing!=2.1.2', 'matplotlib'],
               'interactive': ['ipython>=2.3.0'],
               'docs': ['docutils!=0.13.1', 'sphinx>=1.2.3', 'numpydoc',
                        'sphinx_rtd_theme'],


Test patch:
Repository: diofant/diofant

Issue:
Ugly unicode pprint output in the pdf docs
Examples from the tutorial introduction:

![1](https://user-images.githubusercontent.com/2155800/50540201-955ab980-0b9e-11e9-878a-5a52a59d9869.png)


Note additional padding around symbols and other mess.

See also [this](https://github.com/diofant/diofant/issues/744#issuecomment-450215143).


Discussion:
This also could be fixed by #169.

Resolving patch:
diff --git a/docs/conf.py b/docs/conf.py
--- a/docs/conf.py
+++ b/docs/conf.py
@@ -14,6 +14,8 @@
 import sys
 import warnings
 
+import sphinx.util.texescape
+
 import diofant
 
 
@@ -67,12 +69,16 @@
 
 # A dictionary that contains LaTeX snippets that override predefined.
 latex_elements = {
-    'preamble':  r'''
+    'fontpkg': r'''
 \setmainfont{DejaVu Serif}
 \setsansfont{DejaVu Sans}
 \setmonofont{DejaVu Sans Mono}
+''',
+    'preamble':  r'''
 % redefine \LaTeX to be usable in math mode
 \expandafter\def\expandafter\LaTeX\expandafter{\expandafter\text\expandafter{\LaTeX}}
+
+\fvset{formatcom=\baselineskip10pt\relax\let\strut\empty}
 '''
 }
 
@@ -207,3 +213,7 @@ def linkcode_resolve(domain, info):
         return blobpath + "master/diofant/%s%s" % (fn, linespec)
     else:
         return blobpath + "v%s/diofant/%s%s" % (version, fn, linespec)
+
+
+# monkey-patch sphinx
+del sphinx.util.texescape.tex_replacements[29:]


Test patch:
Repository: diofant/diofant

Issue:
limit(erfc(ln(1/x)), x, oo) is 0 (should be 2)
see sympy/sympy#11496


Discussion:

Resolving patch:
diff --git a/diofant/functions/special/error_functions.py b/diofant/functions/special/error_functions.py
--- a/diofant/functions/special/error_functions.py
+++ b/diofant/functions/special/error_functions.py
@@ -2,7 +2,7 @@
 of incomplete gamma functions. It should probably be renamed.
 """
 
-from ...core import (Add, EulerGamma, Function, I, Integer, Pow, Rational,
+from ...core import (Add, E, EulerGamma, Function, I, Integer, Pow, Rational,
                      cacheit, expand_mul, oo, pi, zoo)
 from ...core.function import ArgumentIndexError
 from ...core.sympify import sympify
@@ -2254,9 +2254,11 @@ class _erfs(Function):
 
     @classmethod
     def eval(cls, z):
-        r = cls(z, evaluate=False).rewrite('intractable')
-        if r.is_number:
-            return r
+        if z in (0, 1, I, 1 + E**-1):
+            return cls(z, evaluate=False).rewrite('intractable')
+
+        if z.could_extract_minus_sign():
+            return 2*exp(z**2) - cls(-z, evaluate=False)
 
     def _eval_aseries(self, n, args0, x, logx):
         from ...series import Order


Test patch:
diff --git a/diofant/tests/series/test_limits.py b/diofant/tests/series/test_limits.py
--- a/diofant/tests/series/test_limits.py
+++ b/diofant/tests/series/test_limits.py
@@ -7,10 +7,10 @@
 from diofant import (E, Float, Function, I, Integral, Lambda, Limit, O,
                      Piecewise, PoleError, Rational, Sum, Symbol, acos, acosh,
                      asin, atan, besselk, binomial, cbrt, ceiling, cos, cosh,
-                     cot, diff, digamma, erf, erfi, exp, factorial, floor,
-                     gamma, integrate, limit, log, nan, oo, pi, polygamma,
-                     root, sign, simplify, sin, sinh, sqrt, subfactorial,
-                     symbols, tan)
+                     cot, diff, digamma, erf, erfc, erfi, exp, factorial,
+                     floor, gamma, integrate, limit, log, nan, oo, pi,
+                     polygamma, root, sign, simplify, sin, sinh, sqrt,
+                     subfactorial, symbols, tan)
 from diofant.abc import a, b, c, n, x, y, z
 from diofant.series.limits import heuristics
 
@@ -943,3 +943,8 @@ def test_sympyissue_7391():
 def test_issue_1216():
     assert (x/abs(sqrt(1 - x**2))).limit(x, oo) == 1
     assert((4*x - 2)/abs(sqrt(4 - 4*(2*x - 1)**2))).limit(x, oo) == 1
+
+
+def test_issue_1213():
+    # also sympy/sympy#11496
+    assert limit(erfc(log(1/x)), x, oo) == 2