You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
There are some bugs in file "archinstall/lib/plugins.py" and "archinstall/init.py".
First problem
If I add --plugin https://raw.githubusercontent.com/phisch/archinstall-aur/master/archinstall-aur.py in archinstall command, this error appears:
Loading plugin from url ParseResult(scheme='https', netloc='raw.githubusercontent.com', path='/phisch/archinstall-aur/refs/heads/master/archinstall-aur.py', params='', query='', fragment='')
Traceback (most recent call last):
File "/home/archi/MyArchIso/install.py", line 3, in <module>
from my_global_menu import Menu
File "/home/archi/MyArchIso/my_global_menu.py", line 1, in <module>
from archinstall.lib.global_menu import GlobalMenu
File "/usr/lib/python3.12/site-packages/archinstall/__init__.py", line 282, in <module>
post_process_arguments(arguments)
File "/usr/lib/python3.12/site-packages/archinstall/__init__.py", line 275, in post_process_arguments
load_plugin(path)
File "/usr/lib/python3.12/site-packages/archinstall/lib/plugins.py", line 95, in load_plugin
localized = _localize_path(path)
^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3.12/site-packages/archinstall/lib/plugins.py", line 38, in _localize_path
converted_path = Path(f'/tmp/{path.stem}_{hashlib.md5(os.urandom(12)).hexdigest()}.py')
^^^^^^^^^
AttributeError: 'str' object has no attribute 'stem'
Seems that the problem is in function post_process_arguments in file archinstall/__init__.py. This function passes a string to the function load_plugin instead of a 'Path' object.
I changed line 276 to path = Path(args['plugin']) and the problem was solved.
#Second Problem #
At this point new problem came out:
Loading plugin from url ParseResult(scheme='https', netloc='', path='/raw.githubusercontent.com/phisch/archinstall-aur/refs/heads/master/archinstall-aur.py', params='', query='', fragment='')
Traceback (most recent call last):
File "/home/archi/MyArchIso/install.py", line 3, in <module>
from my_global_menu import Menu
File "/home/archi/MyArchIso/my_global_menu.py", line 1, in <module>
from archinstall.lib.global_menu import GlobalMenu
File "/usr/lib/python3.12/site-packages/archinstall/__init__.py", line 282, in <module>
post_process_arguments(arguments)
File "/usr/lib/python3.12/site-packages/archinstall/__init__.py", line 275, in post_process_arguments
load_plugin(path)
File "/usr/lib/python3.12/site-packages/archinstall/lib/plugins.py", line 95, in load_plugin
localized = _localize_path(path)
^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3.12/site-packages/archinstall/lib/plugins.py", line 41, in _localize_path
temp_file.write(urllib.request.urlopen(url.geturl()).read().decode('utf-8'))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3.12/urllib/request.py", line 215, in urlopen
return opener.open(url, data, timeout)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/lib/python3.12/urllib/request.py", line 512, in open
req = meth(req)
^^^^^^^^^
File "/usr/lib/python3.12/urllib/request.py", line 1268, in do_request_
raise URLError('no host given')
urllib.error.URLError: <urlopen error no host given>
The problem seems localized in funcion _localize_path in file archinstall/lib/plugins.py, where funcion url.geturl() return "https:///raw.githubusercontent.com/phisch/archinstall-aur/master/archinstall-aur.py" (there are 3 backslash after "https:").
The text was updated successfully, but these errors were encountered:
There are some bugs in file "archinstall/lib/plugins.py" and "archinstall/init.py".
First problem
If I add
--plugin https://raw.githubusercontent.com/phisch/archinstall-aur/master/archinstall-aur.py
in archinstall command, this error appears:Seems that the problem is in function
post_process_arguments
in filearchinstall/__init__.py
. This function passes a string to the functionload_plugin
instead of a 'Path' object.I changed line 276 to
path = Path(args['plugin'])
and the problem was solved.#Second Problem #
At this point new problem came out:
The problem seems localized in funcion
_localize_path
in filearchinstall/lib/plugins.py
, where funcion url.geturl() return "https:///raw.githubusercontent.com/phisch/archinstall-aur/master/archinstall-aur.py" (there are 3 backslash after "https:").The text was updated successfully, but these errors were encountered: