ritzvik: For passing quality checks https://docs.einsteinpy.org/en/latest/dev_guide.html#code-linting
I'll review in a while :)

Thanks for the PR @bibek22 
diff --git a/src/einsteinpy/symbolic/tensor.py b/src/einsteinpy/symbolic/tensor.py
index 64ef407..238fd0b 100644
--- a/src/einsteinpy/symbolic/tensor.py
+++ b/src/einsteinpy/symbolic/tensor.py
@@ -90,6 +90,8 @@ class Tensor:
             Raised when arr is not a list or sympy array
         TypeError
             Raised when config is not of type str or contains characters other than 'l' or 'u'
+        ValueError
+            Raised when ``config`` implies order of Tensor different than that indicated by shape of ``arr``
 
         """
 
@@ -106,6 +108,12 @@ class Tensor:
             raise TypeError(
                 "config is either not of type 'str' or does contain characters other than 'l' or 'u'"
             )
+        if len(self.arr.shape) != len(config):
+            raise ValueError(
+                "invalid shape of array for tensor of order implied by config: '{}'".format(
+                    config
+                )
+            )
         self.name = name
 
     @property
diff --git a/src/einsteinpy/symbolic/weyl.py b/src/einsteinpy/symbolic/weyl.py
index 266e066..9846261 100644
--- a/src/einsteinpy/symbolic/weyl.py
+++ b/src/einsteinpy/symbolic/weyl.py
@@ -100,7 +100,7 @@ class WeylTensor(BaseRelativityTensor):
             return cls(C, metric.syms, config="llll", parent_metric=metric)
         if metric.dims == 3:
             return cls(
-                sympy.Array(np.zeros((3, 3), dtype=int)),
+                sympy.Array(np.zeros((3, 3, 3, 3), dtype=int)),
                 metric.syms,
                 config="llll",
                 parent_metric=metric,

Error handling for `config` variable in Tensor class
🐞 **Problem**
`config` variable denotes the contravariance-covariance of the tensor. It's lenrth is supposed to be equal to that the order of the tensor. 

🎯 **Goal**

  - [x] Introduce this error handling into `Tensor` class in `symbolic` module
  - [ ] After fixing this, fix [this](https://github.com/einsteinpy/einsteinpy/blob/30a68526b9cea7b21b3f81c0b89d2619c3e19440/docs/source/examples/Lambdify%20symbolic%20calculation.ipynb) example

💡 **Possible solutions**

  - `config` length should be equal to length of the tuple returned by `arr.shape`

📋  **Steps to solve the problem**

 * Comment below about what you've started working on.
 * Add, commit, push your changes
 * Submit a pull request.
 * Add this in the comments:
 	- `Addresses #<put issue number here>` if you are partially fixing the issue.
 	- `Fixes #<put issue number here>` if you are completely fixing the issue.
 * Ask for a review in comments section of pull request
 * Celebrate your contribution to this project 🎉

diff --git a/src/einsteinpy/tests/test_symbolic/test_tensor.py b/src/einsteinpy/tests/test_symbolic/test_tensor.py
index 1d5bc4a..6e6b6a6 100644
--- a/src/einsteinpy/tests/test_symbolic/test_tensor.py
+++ b/src/einsteinpy/tests/test_symbolic/test_tensor.py
@@ -82,8 +82,8 @@ def test_Tensor():
     x, y, z = symbols("x y z")
     test_list = [[[x, y], [y, sin(2 * z) - 2 * sin(z) * cos(z)]], [[z ** 2, x], [y, z]]]
     test_arr = Array(test_list)
-    obj1 = Tensor(test_arr)
-    obj2 = Tensor(test_list)
+    obj1 = Tensor(test_arr, config="ull")
+    obj2 = Tensor(test_list, config="ull")
     assert obj1.tensor() == obj2.tensor()
     assert isinstance(obj1.tensor(), Array)
 
@@ -91,7 +91,7 @@ def test_Tensor():
 def test_Tensor_simplify():
     x, y, z = symbols("x y z")
     test_list = [[[x, y], [y, sin(2 * z) - 2 * sin(z) * cos(z)]], [[z ** 2, x], [y, z]]]
-    obj = Tensor(test_list)
+    obj = Tensor(test_list, config="ull")
     # with set_self = False
     assert obj.simplify(set_self=False)[0, 1, 1] == 0
     assert not obj.tensor()[0, 1, 1] == 0
@@ -103,7 +103,7 @@ def test_Tensor_simplify():
 def test_Tensor_getitem():
     x, y, z = symbols("x y z")
     test_list = [[[x, y], [y, sin(2 * z) - 2 * sin(z) * cos(z)]], [[z ** 2, x], [y, z]]]
-    obj = Tensor(test_list)
+    obj = Tensor(test_list, config="ull")
     n = 2
     for i in range(n ** 3):
         p, q, r = i % n, int(i / n) % n, int(i / n ** 2) % n
@@ -113,7 +113,7 @@ def test_Tensor_getitem():
 def test_Tensor_str():
     x, y, z = symbols("x y z")
     test_list = [[[x, y], [y, x]], [[z, x], [y, z]]]
-    obj1 = Tensor(test_list, name="Test")
+    obj1 = Tensor(test_list, config="ull", name="Test")
     assert "object at 0x" not in str(obj1)
     assert "Test" in str(obj1)
 
@@ -121,7 +121,7 @@ def test_Tensor_str():
 def test_Tensor_repr():
     x, y, z = symbols("x y z")
     test_list = [[[x, y], [y, sin(2 * z) - 2 * sin(z) * cos(z)]], [[z ** 2, x], [y, z]]]
-    obj1 = Tensor(test_list)
+    obj1 = Tensor(test_list, config="ull")
     machine_representation = repr(obj1)
     assert not "object at 0x" in machine_representation
 
@@ -148,6 +148,14 @@ def test_TypeError3():
 
 @xfail(raises=ValueError, strict=True)
 def test_ValueError1():
+    x, y = symbols("x y")
+    test_list = [[x, y], [y, x]]
+    # pass array with shape (2,2) when (2,2,2) implied by argument syms
+    obj = Tensor(test_list, config="lll")
+
+
+@xfail(raises=ValueError, strict=True)
+def test_ValueError2():
     x, y, z = symbols("x y z")
     test_list = [[x, y], [y, x]]
     # pass 2x2 array when 3x3 implied by argument syms
@@ -214,7 +222,7 @@ def test_BaseRelativityTensor_automatic_calculation_of_free_variables():
 
 @pytest.mark.parametrize("scalar", [11.89, y * z + 5])
 def test_tensor_scalar(scalar):
-    scalar_tensor = Tensor(scalar)
+    scalar_tensor = Tensor(scalar, config="")
     assert scalar_tensor.tensor().rank() == 0
 
 
diff --git a/src/einsteinpy/tests/test_symbolic/test_weyl.py b/src/einsteinpy/tests/test_symbolic/test_weyl.py
index 9b7fc6d..53dd5a1 100644
--- a/src/einsteinpy/tests/test_symbolic/test_weyl.py
+++ b/src/einsteinpy/tests/test_symbolic/test_weyl.py
@@ -75,7 +75,7 @@ def test_weyl_dim3():
     syms = sympy.symbols(symbolstr)
     metric = MetricTensor(list_metric, syms)
     obj = WeylTensor.from_metric(metric).arr
-    assert obj == sympy.Array(np.zeros((3, 3), dtype=int))
+    assert obj == sympy.Array(np.zeros((3, 3, 3, 3), dtype=int))
 
 
 def test_weyl_conformal_rescaling():

pip install -e .[dev]
parse_log_pytest
numpy astropy matplotlib plotly scipy sympy numba
pytest
3.7
pytest --no-header -rA --tb=line --color=no -p no:cacheprovider -W ignore::DeprecationWarning
alabaster==0.7.13
astropy @ file:///tmp/build/80754af9/astropy_1629829214319/work
attrs==24.2.0
Babel==2.14.0
backcall==0.2.0
beautifulsoup4==4.13.3
black==23.3.0
bleach==6.0.0
cachetools==5.5.2
certifi @ file:///croot/certifi_1671487769961/work/certifi
chardet==5.2.0
charset-normalizer==3.4.1
click==8.1.8
colorama==0.4.6
comm==0.1.4
coverage==7.2.7
cycler @ file:///tmp/build/80754af9/cycler_1637851556182/work
debugpy==1.7.0
decorator==5.1.1
defusedxml==0.7.1
distlib==0.3.9
docutils==0.19
-e git+https://github.com/einsteinpy/einsteinpy.git@88a93a10d14ba0d75a86bf4072e75def34031501#egg=einsteinpy
entrypoints==0.4
exceptiongroup==1.2.2
execnet==2.0.2
fastjsonschema==2.21.1
filelock==3.12.2
flit_core @ file:///opt/conda/conda-bld/flit-core_1644941570762/work/source/flit_core
fonttools==4.25.0
gmpy2 @ file:///tmp/build/80754af9/gmpy2_1645455532931/work
idna==3.10
imagesize==1.4.1
importlib-metadata==6.7.0
importlib-resources==5.12.0
iniconfig==2.0.0
ipykernel==6.16.2
ipython==7.34.0
ipywidgets==8.1.5
isort==5.11.5
jedi==0.19.2
Jinja2==3.1.6
jsonschema==4.17.3
jupyter-sphinx==0.4.0
jupyter_client==7.4.9
jupyter_core==4.12.0
jupyterlab-pygments==0.2.2
jupyterlab_widgets==3.0.13
kiwisolver @ file:///croot/kiwisolver_1672387140495/work
llvmlite==0.39.1
MarkupSafe==2.1.5
matplotlib @ file:///croot/matplotlib-suite_1667356714455/work
matplotlib-inline==0.1.6
mistune==3.0.2
mpmath==1.2.1
munkres==1.1.4
mypy-extensions==1.0.0
nbclient==0.7.4
nbconvert==7.6.0
nbformat==5.8.0
nbsphinx==0.9.7
nest-asyncio==1.6.0
numba @ file:///croot/numba_1670258325998/work
numpy @ file:///opt/conda/conda-bld/numpy_and_numpy_base_1653915516269/work
packaging==24.0
pandocfilters==1.5.1
parso==0.8.4
pathspec==0.11.2
pexpect==4.9.0
pickleshare==0.7.5
Pillow==9.4.0
pkgutil_resolve_name==1.3.10
platformdirs==4.0.0
plotly @ file:///tmp/abs_7afcdfad-dbbb-49d2-adea-186abf525c45jbnd8p95/croots/recipe/plotly_1658160053621/work
pluggy==1.2.0
ply==3.11
prompt_toolkit==3.0.48
psutil==7.0.0
ptyprocess==0.7.0
pycodestyle==2.10.0
pyerfa @ file:///tmp/build/80754af9/pyerfa_1621560191196/work
Pygments==2.17.2
pyparsing @ file:///opt/conda/conda-bld/pyparsing_1661452539315/work
pyproject-api==1.5.3
PyQt5-sip==12.11.0
pyrsistent==0.19.3
pytest==7.4.4
pytest-cov==2.5.1
pytest-xdist==3.5.0
python-dateutil @ file:///tmp/build/80754af9/python-dateutil_1626374649649/work
pytz==2025.2
PyYAML @ file:///croot/pyyaml_1670514731622/work
pyzmq==26.2.1
requests==2.31.0
scipy @ file:///opt/conda/conda-bld/scipy_1661390393401/work
sip @ file:///tmp/abs_44cd77b_pu/croots/recipe/sip_1659012365470/work
six @ file:///tmp/build/80754af9/six_1644875935023/work
snowballstemmer==2.2.0
soupsieve==2.4.1
Sphinx==5.3.0
sphinxcontrib-applehelp==1.0.2
sphinxcontrib-devhelp==1.0.2
sphinxcontrib-htmlhelp==2.0.0
sphinxcontrib-jsmath==1.0.1
sphinxcontrib-qthelp==1.0.3
sphinxcontrib-serializinghtml==1.1.5
sympy @ file:///tmp/build/80754af9/sympy_1647835525989/work
tenacity @ file:///tmp/abs_9ca5cd06-f53b-4ea6-8eea-954e11157fddo5mhurpp/croots/recipe/tenacity_1657899103026/work
tinycss2==1.2.1
toml @ file:///tmp/build/80754af9/toml_1616166611790/work
tomli==2.0.1
tornado @ file:///opt/conda/conda-bld/tornado_1662061693373/work
tox==4.8.0
traitlets==5.9.0
typed-ast==1.5.5
typing_extensions==4.7.1
urllib3==2.0.7
virtualenv==20.26.6
wcwidth==0.2.13
webencodings==0.5.1
widgetsnbextension==4.0.13
zipp @ file:///croot/zipp_1672387121353/work

name: einsteinpy
channels:
  - defaults
  - https://repo.anaconda.com/pkgs/main
  - https://repo.anaconda.com/pkgs/r
  - conda-forge
dependencies:
  - _libgcc_mutex=0.1=main
  - _openmp_mutex=5.1=1_gnu
  - astropy=4.3.1=py37h09021b7_0
  - blas=1.0=openblas
  - brotli=1.0.9=h5eee18b_9
  - brotli-bin=1.0.9=h5eee18b_9
  - bzip2=1.0.8=h5eee18b_6
  - ca-certificates=2025.2.25=h06a4308_0
  - certifi=2022.12.7=py37h06a4308_0
  - cycler=0.11.0=pyhd3eb1b0_0
  - cyrus-sasl=2.1.28=h9c0eb46_1
  - dbus=1.13.18=hb2f20db_0
  - expat=2.6.4=h6a678d5_0
  - fftw=3.3.9=h5eee18b_2
  - flit-core=3.6.0=pyhd3eb1b0_0
  - fontconfig=2.14.1=h4c34cd2_2
  - fonttools=4.25.0=pyhd3eb1b0_0
  - freetype=2.12.1=h4a9f257_0
  - giflib=5.2.2=h5eee18b_0
  - glib=2.78.4=h6a678d5_0
  - glib-tools=2.78.4=h6a678d5_0
  - gmp=6.3.0=h6a678d5_0
  - gmpy2=2.1.2=py37heeb90bb_0
  - gst-plugins-base=1.14.1=h6a678d5_1
  - gstreamer=1.14.1=h5eee18b_1
  - icu=58.2=he6710b0_3
  - importlib_metadata=4.11.3=hd3eb1b0_0
  - jpeg=9e=h5eee18b_3
  - kiwisolver=1.4.4=py37h6a678d5_0
  - krb5=1.20.1=h568e23c_1
  - lcms2=2.16=hb9589c4_0
  - ld_impl_linux-64=2.40=h12ee557_0
  - lerc=4.0.0=h6a678d5_0
  - libbrotlicommon=1.0.9=h5eee18b_9
  - libbrotlidec=1.0.9=h5eee18b_9
  - libbrotlienc=1.0.9=h5eee18b_9
  - libclang=14.0.6=default_hc6dbbc7_2
  - libclang13=14.0.6=default_he11475f_2
  - libcups=2.4.2=ha637b67_0
  - libdeflate=1.22=h5eee18b_0
  - libedit=3.1.20230828=h5eee18b_0
  - libevent=2.1.12=h8f2d780_0
  - libffi=3.4.4=h6a678d5_1
  - libgcc-ng=11.2.0=h1234567_1
  - libgfortran-ng=11.2.0=h00389a5_1
  - libgfortran5=11.2.0=h1234567_1
  - libglib=2.78.4=hdc74915_0
  - libgomp=11.2.0=h1234567_1
  - libiconv=1.16=h5eee18b_3
  - libllvm11=11.1.0=h9e868ea_6
  - libllvm14=14.0.6=hecde1de_4
  - libopenblas=0.3.21=h043d6bf_0
  - libpng=1.6.39=h5eee18b_0
  - libpq=12.15=h37d81fd_1
  - libstdcxx-ng=11.2.0=h1234567_1
  - libtiff=4.5.1=hffd6297_1
  - libuuid=1.41.5=h5eee18b_0
  - libwebp=1.2.4=h11a3e52_1
  - libwebp-base=1.2.4=h5eee18b_1
  - libxcb=1.15=h7f8727e_0
  - libxkbcommon=1.0.1=h5eee18b_1
  - libxml2=2.10.4=hcbfbd50_0
  - libxslt=1.1.37=h2085143_0
  - llvmlite=0.39.1=py37he621ea3_0
  - lz4-c=1.9.4=h6a678d5_1
  - matplotlib=3.5.3=py37h06a4308_0
  - matplotlib-base=3.5.3=py37hf590b9c_0
  - mpc=1.3.1=h5eee18b_0
  - mpfr=4.2.1=h5eee18b_0
  - mpmath=1.2.1=py37h06a4308_0
  - munkres=1.1.4=py_0
  - mysql=5.7.24=he378463_2
  - ncurses=6.4=h6a678d5_0
  - nspr=4.35=h6a678d5_0
  - nss=3.89.1=h6a678d5_0
  - numba=0.56.4=py37h417a72b_0
  - numpy=1.21.5=py37hf838250_3
  - numpy-base=1.21.5=py37h1e6e340_3
  - openssl=1.1.1w=h7f8727e_0
  - pcre2=10.42=hebb0a14_1
  - pillow=9.4.0=py37h6a678d5_0
  - pip=22.3.1=py37h06a4308_0
  - plotly=5.9.0=py37h06a4308_0
  - ply=3.11=py37_0
  - pyerfa=2.0.0=py37h27cfd23_0
  - pyparsing=3.0.9=py37h06a4308_0
  - pyqt=5.15.7=py37h6a678d5_1
  - pyqt5-sip=12.11.0=py37h6a678d5_1
  - python=3.7.16=h7a1cb2a_0
  - python-dateutil=2.8.2=pyhd3eb1b0_0
  - pyyaml=6.0=py37h5eee18b_1
  - qt-main=5.15.2=h5b8104b_9
  - qt-webengine=5.15.9=h9ab4d14_7
  - qtwebkit=5.212=h3fafdc1_5
  - readline=8.2=h5eee18b_0
  - scipy=1.7.3=py37hf838250_2
  - setuptools=65.6.3=py37h06a4308_0
  - sip=6.6.2=py37h6a678d5_0
  - six=1.16.0=pyhd3eb1b0_1
  - sqlite=3.45.3=h5eee18b_0
  - sympy=1.10.1=py37h06a4308_0
  - tbb=2021.8.0=hdb19cb5_0
  - tenacity=8.0.1=py37h06a4308_1
  - tk=8.6.14=h39e8969_0
  - toml=0.10.2=pyhd3eb1b0_0
  - tornado=6.2=py37h5eee18b_0
  - wheel=0.38.4=py37h06a4308_0
  - xz=5.6.4=h5eee18b_1
  - yaml=0.2.5=h7b6447c_0
  - zipp=3.11.0=py37h06a4308_0
  - zlib=1.2.13=h5eee18b_1
  - zstd=1.5.6=hc292b87_0
  - pip:
      - alabaster==0.7.13
      - attrs==24.2.0
      - babel==2.14.0
      - backcall==0.2.0
      - beautifulsoup4==4.13.3
      - black==23.3.0
      - bleach==6.0.0
      - cachetools==5.5.2
      - chardet==5.2.0
      - charset-normalizer==3.4.1
      - click==8.1.8
      - colorama==0.4.6
      - comm==0.1.4
      - coverage==7.2.7
      - debugpy==1.7.0
      - decorator==5.1.1
      - defusedxml==0.7.1
      - distlib==0.3.9
      - docutils==0.19
      - einsteinpy==0.3.dev0
      - entrypoints==0.4
      - exceptiongroup==1.2.2
      - execnet==2.0.2
      - fastjsonschema==2.21.1
      - filelock==3.12.2
      - idna==3.10
      - imagesize==1.4.1
      - importlib-metadata==6.7.0
      - importlib-resources==5.12.0
      - iniconfig==2.0.0
      - ipykernel==6.16.2
      - ipython==7.34.0
      - ipywidgets==8.1.5
      - isort==5.11.5
      - jedi==0.19.2
      - jinja2==3.1.6
      - jsonschema==4.17.3
      - jupyter-client==7.4.9
      - jupyter-core==4.12.0
      - jupyter-sphinx==0.4.0
      - jupyterlab-pygments==0.2.2
      - jupyterlab-widgets==3.0.13
      - markupsafe==2.1.5
      - matplotlib-inline==0.1.6
      - mistune==3.0.2
      - mypy-extensions==1.0.0
      - nbclient==0.7.4
      - nbconvert==7.6.0
      - nbformat==5.8.0
      - nbsphinx==0.9.7
      - nest-asyncio==1.6.0
      - packaging==24.0
      - pandocfilters==1.5.1
      - parso==0.8.4
      - pathspec==0.11.2
      - pexpect==4.9.0
      - pickleshare==0.7.5
      - pkgutil-resolve-name==1.3.10
      - platformdirs==4.0.0
      - pluggy==1.2.0
      - prompt-toolkit==3.0.48
      - psutil==7.0.0
      - ptyprocess==0.7.0
      - pycodestyle==2.10.0
      - pygments==2.17.2
      - pyproject-api==1.5.3
      - pyrsistent==0.19.3
      - pytest==7.4.4
      - pytest-cov==2.5.1
      - pytest-xdist==3.5.0
      - pytz==2025.2
      - pyzmq==26.2.1
      - requests==2.31.0
      - snowballstemmer==2.2.0
      - soupsieve==2.4.1
      - sphinx==5.3.0
      - sphinxcontrib-applehelp==1.0.2
      - sphinxcontrib-devhelp==1.0.2
      - sphinxcontrib-htmlhelp==2.0.0
      - sphinxcontrib-jsmath==1.0.1
      - sphinxcontrib-qthelp==1.0.3
      - sphinxcontrib-serializinghtml==1.1.5
      - tinycss2==1.2.1
      - tomli==2.0.1
      - tox==4.8.0
      - traitlets==5.9.0
      - typed-ast==1.5.5
      - typing-extensions==4.7.1
      - urllib3==2.0.7
      - virtualenv==20.26.6
      - wcwidth==0.2.13
      - webencodings==0.5.1
      - widgetsnbextension==4.0.13
prefix: /opt/conda/envs/einsteinpy

src/einsteinpy/tests/test_symbolic/test_weyl.py::test_weyl_dim3
src/einsteinpy/tests/test_symbolic/test_tensor.py::test_lambdify_with_args
src/einsteinpy/tests/test_symbolic/test_tensor.py::test_simplify_sympy_array_works_for_all[target0] src/einsteinpy/tests/test_symbolic/test_tensor.py::test_simplify_sympy_array_works_for_all[target1] src/einsteinpy/tests/test_symbolic/test_tensor.py::test_simplify_sympy_array_works_for_all[target2] src/einsteinpy/tests/test_symbolic/test_tensor.py::test_Tensor src/einsteinpy/tests/test_symbolic/test_tensor.py::test_Tensor_simplify src/einsteinpy/tests/test_symbolic/test_tensor.py::test_Tensor_getitem src/einsteinpy/tests/test_symbolic/test_tensor.py::test_Tensor_str src/einsteinpy/tests/test_symbolic/test_tensor.py::test_Tensor_repr src/einsteinpy/tests/test_symbolic/test_tensor.py::test_subs_single src/einsteinpy/tests/test_symbolic/test_tensor.py::test_subs_multiple src/einsteinpy/tests/test_symbolic/test_tensor.py::test_check_properties src/einsteinpy/tests/test_symbolic/test_tensor.py::test_BaseRelativityTensor_automatic_calculation_of_free_variables src/einsteinpy/tests/test_symbolic/test_tensor.py::test_tensor_scalar[11.89] src/einsteinpy/tests/test_symbolic/test_tensor.py::test_tensor_scalar[scalar1] src/einsteinpy/tests/test_symbolic/test_tensor.py::test_lambdify_on_schwarzschild_metric_without_args src/einsteinpy/tests/test_symbolic/test_weyl.py::test_weyl_TypeError src/einsteinpy/tests/test_symbolic/test_weyl.py::test_weyl_ValueError_wrong_config_length src/einsteinpy/tests/test_symbolic/test_weyl.py::test_weyl_dim2 src/einsteinpy/tests/test_symbolic/test_weyl.py::test_weyl_conformal_rescaling src/einsteinpy/tests/test_symbolic/test_weyl.py::test_weyl_contraction_1st_3rd_indices_zero
src/einsteinpy/symbolic/tensor.py src/einsteinpy/symbolic/weyl.py
src/einsteinpy/symbolic/tensor.py src/einsteinpy/symbolic/weyl.py