Hello currently I was developing some a python script on Repl.it for sake for devices sharing.
But now considering I am moving towards Visual Studio (for the toolbox and other mattersà and I have copied over the code, I get an Invalid Argument code for me that does not make any sense.
Loaded '__main__'
Loaded 'runpy'
Traceback (most recent call last):
File "C:\Users\joeri\AppData\Local\Programs\Python\Python37\lib\runpy.py", line 193, in _run_module_as_main
"__main__", mod_spec)
File "C:\Users\joeri\AppData\Local\Programs\Python\Python37\lib\runpy.py", line 85, in _run_code
exec(code, run_globals)
File "c:\program files (x86)\microsoft visual studio\2019\enterprise\common7\ide\extensions\microsoft\python\core\debugpy\__main__.py", line 45, in <module>
cli.main()
File "c:\program files (x86)\microsoft visual studio\2019\enterprise\common7\ide\extensions\microsoft\python\core\debugpy/..\debugpy\server\cli.py", line 430, in main
run()
File "c:\program files (x86)\microsoft visual studio\2019\enterprise\common7\ide\extensions\microsoft\python\core\debugpy/..\debugpy\server\cli.py", line 267, in run_file
runpy.run_path(options.target, run_name=compat.force_str("__main__"))
File "C:\Users\joeri\AppData\Local\Programs\Python\Python37\lib\runpy.py", line 263, in run_path
pkg_name=pkg_name, script_name=fname)
File "C:\Users\joeri\AppData\Local\Programs\Python\Python37\lib\runpy.py", line 96, in _run_module_code
mod_name, mod_spec, pkg_name, script_name)
File "C:\Users\joeri\AppData\Local\Programs\Python\Python37\lib\runpy.py", line 85, in _run_code
exec(code, run_globals)
File "D:\Programmeer portfolio\Programma's\Python Scripts\PythonApplicationGIPODAPITest\PythonApplicationGIPODAPITest.py", line 167, in <module>
The thread 'MainThread' (0x1) has exited with code 0 (0x0).
fetch_points(api_response_url)
File "D:\Programmeer portfolio\Programma's\Python Scripts\PythonApplicationGIPODAPITest\PythonApplicationGIPODAPITest.py", line 107, in fetch_points
save_jsonfile(folder_path, "points", text)
File "D:\Programmeer portfolio\Programma's\Python Scripts\PythonApplicationGIPODAPITest\PythonApplicationGIPODAPITest.py", line 156, in save_jsonfile
file1 = open(completeName, "wt")
OSError: [Errno 22] Invalid argument: 'api_request_jsons\x0cetch_points\\points.json'
The program 'python.exe' has exited with code 1 (0x1).
If the code can work on repl.it and I have the same file and folder structure..then why does this not work in Visual Studio? Sure repl.it has python 3.8 and Visual Studio has python 3.7..But that could not be it right?
Edited: Code deleted for privacy reasons.