[X] I searched open reports and couldn't find a duplicate
What happened?
Hello,
I am currently trying to execute conda pack on a specific environment.
It returns an error, I haven't been able to solve yet.
I already tried a full uninstall of Anaconda and doing a whole new installation...
But it seems an emoji "CHART WITH UPWARDS TREND" is present in a library and cannot be encoded because, conda pack is trying to encode it in cp1252, which is impossible.
`(base) C:\Users\G1111300\Anaconda3\envs>conda pack -n Prod_env -o Prod_env_packed.tar.gz
Collecting packages...
Packing environment at 'C:\Users\G1111300\Anaconda3\envs\Prod_env' to 'Prod_env_packed.tar.gz'
[########################################] | 100% Completed | 3min 16.0s
Traceback (most recent call last):
File "C:\Users\G1111300\Anaconda3\lib\site-packages\conda_pack\core.py", line 1108, in _write_text_file
fil.write(ftext)
File "C:\Users\G1111300\Anaconda3\lib\tempfile.py", line 478, in func_wrapper
return func(*args, **kwargs)
File "C:\Users\G1111300\Anaconda3\lib\encodings\cp1252.py", line 19, in encode
return codecs.charmap_encode(input,self.errors,encoding_table)[0]
UnicodeEncodeError: 'charmap' codec can't encode character '\U0001f4ca' in position 1209521: character maps to
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "C:\Users\G1111300\Anaconda3\lib\site-packages\conda_pack\cli.py", line 157, in main
pack(name=args.name,
File "C:\Users\G1111300\Anaconda3\lib\site-packages\conda_pack\core.py", line 542, in pack
return env.pack(output=output, format=format,
File "C:\Users\G1111300\Anaconda3\lib\site-packages\conda_pack\core.py", line 386, in pack
packer.finish()
File "C:\Users\G1111300\Anaconda3\lib\site-packages\conda_pack\core.py", line 1171, in finish
self._write_text_file(os.path.join(BIN_DIR, script_name), script, True)
File "C:\Users\G1111300\Anaconda3\lib\site-packages\conda_pack\core.py", line 1115, in _write_text_file
os.unlink(fil.name)
PermissionError: [WinError 32] The process cannot access the file because this file is used by another process: 'C:\Users\G1111300\AppData\Local\Temp\tmpxinf9sx2'`
Thank you for your help !
Conda Info
active environment : base
active env location : C:\Users\G1111300\Anaconda3
shell level : 1
user config file : C:\Users\G1111300\.condarc
populated config files : C:\Users\G1111300\.condarc
conda version : 4.13.0
conda-build version : 3.21.8
python version : 3.9.12.final.0
virtual packages : __win=0=0
__archspec=1=x86_64
base environment : C:\Users\G1111300\Anaconda3 (writable)
conda av data dir : C:\Users\G1111300\Anaconda3\etc\conda
conda av metadata url : None
channel URLs : https://repo.anaconda.com/pkgs/main/win-64
https://repo.anaconda.com/pkgs/main/noarch
https://repo.anaconda.com/pkgs/r/win-64
https://repo.anaconda.com/pkgs/r/noarch
https://repo.anaconda.com/pkgs/msys2/win-64
https://repo.anaconda.com/pkgs/msys2/noarch
package cache : C:\Users\G1111300\Anaconda3\pkgs
C:\Users\G1111300\.conda\pkgs
C:\Users\G1111300\AppData\Local\conda\conda\pkgs
envs directories : C:\Users\G1111300\Anaconda3\envs
C:\Users\G1111300\.conda\envs
C:\Users\G1111300\AppData\Local\conda\conda\envs
platform : win-64
user-agent : conda/4.13.0 requests/2.27.1 CPython/3.9.12 Windows/10 Windows/10.0.19042
administrator : False
netrc file : None
offline mode : False
Checklist
What happened?
Hello,
I am currently trying to execute conda pack on a specific environment. It returns an error, I haven't been able to solve yet.
I already tried a full uninstall of Anaconda and doing a whole new installation... But it seems an emoji "CHART WITH UPWARDS TREND" is present in a library and cannot be encoded because, conda pack is trying to encode it in cp1252, which is impossible.
`(base) C:\Users\G1111300\Anaconda3\envs>conda pack -n Prod_env -o Prod_env_packed.tar.gz Collecting packages... Packing environment at 'C:\Users\G1111300\Anaconda3\envs\Prod_env' to 'Prod_env_packed.tar.gz' [########################################] | 100% Completed | 3min 16.0s Traceback (most recent call last): File "C:\Users\G1111300\Anaconda3\lib\site-packages\conda_pack\core.py", line 1108, in _write_text_file fil.write(ftext) File "C:\Users\G1111300\Anaconda3\lib\tempfile.py", line 478, in func_wrapper return func(*args, **kwargs) File "C:\Users\G1111300\Anaconda3\lib\encodings\cp1252.py", line 19, in encode return codecs.charmap_encode(input,self.errors,encoding_table)[0] UnicodeEncodeError: 'charmap' codec can't encode character '\U0001f4ca' in position 1209521: character maps to
During handling of the above exception, another exception occurred:
Traceback (most recent call last): File "C:\Users\G1111300\Anaconda3\lib\site-packages\conda_pack\cli.py", line 157, in main pack(name=args.name, File "C:\Users\G1111300\Anaconda3\lib\site-packages\conda_pack\core.py", line 542, in pack return env.pack(output=output, format=format, File "C:\Users\G1111300\Anaconda3\lib\site-packages\conda_pack\core.py", line 386, in pack packer.finish() File "C:\Users\G1111300\Anaconda3\lib\site-packages\conda_pack\core.py", line 1171, in finish self._write_text_file(os.path.join(BIN_DIR, script_name), script, True) File "C:\Users\G1111300\Anaconda3\lib\site-packages\conda_pack\core.py", line 1115, in _write_text_file os.unlink(fil.name) PermissionError: [WinError 32] The process cannot access the file because this file is used by another process: 'C:\Users\G1111300\AppData\Local\Temp\tmpxinf9sx2'`
Thank you for your help !
Conda Info
Conda Config
Conda list
Additional Context
No response