+
    xȇiX                        R t ^ RIt^ RIHt ^ RIt^ RIHt ^ RIHt ^ RI	H
t
 ^ RIHt ]P                  P                  R4      t]P                  P#                  R4      t]P                  P#                  R4      t]'       d   R	tR
tMRtRt]P                  P-                  RRR/R] 23RRR]P.                  /R3R^/R] R23.4      ]R 4       4       t]P                  P-                  RR(R).4      ]R 4       4       tR t]P                  P-                  R. R*O4      R 4       t]]P                  P-                  R]P.                  ]P8                  .4      ]P                  P-                  RR	R.4      R 4       4       4       t]P                  P-                  R/ . R+O.3RRR]P.                  /. R+O.3RRR]P<                  /. R+O.3RRR]P8                  /. R,O.3RRR]P>                  /. R-O.3.4      ]R 4       4       t ]P                  P-                  RR^R ..3R!^R"..3.4      R# 4       t!]P                  P-                  RRR$.4      R% 4       t"]P                  P-                  R&RR!.4      R' 4       t#R# ).zt
Tests that quoting specifications are properly handled
during parsing for all of the parsers defined in parsers.py
N)StringIO)PY314)ParserError)	DataFramez=ignore:Passing a BlockManager to DataFrame:DeprecationWarningpyarrow_xfailpyarrow_skip z[\s\S]*za(n)? 1-character stringzstring( or None)?z
kwargs,msg	quotecharfooz"quotechar" must be quoting(quotechar must be set if quoting enabledz	, not intc                     R pT p\         P                  ! \        VR7      ;_uu_ 4        VP                  ! \	        V4      3/ VB  RRR4       R#   + '       g   i     R# ; i)1,2,3matchNpytestraises	TypeErrorread_csvr   )all_parserskwargsmsgdataparsers   &&&  s/Users/max/.openclaw/workspace/postharvest/venv/lib/python3.14/site-packages/pandas/tests/io/parser/test_quoting.pytest_bad_quote_charr   !   sC     DF	y	,	,1&1 
-	,	,	,   AA!	zquoting,msgc                     R pT p\         P                  ! \        VR7      ;_uu_ 4        VP                  \	        V4      VR7       RRR4       R#   + '       g   i     R# ; i)r   r   )r   Nr   )r   r   r   r   r   s   &&&  r   test_bad_quotingr   5   sB     DF	y	,	,8 
-	,	,	,r   c                     T pR p\        . RO.. ROR7      pVP                  \        V4      RR7      p\        P                  ! WC4       R# )a,b,c
1,2,"cat"columns"r	   N      catabcr   r   r   tmassert_frame_equal)r   r   r   expectedresults   &    r   test_quote_char_basicr3   E   s>    FD-/BH__Xd^s_;F&+    
quote_charc                     T p\        . RO.. ROR7      pRpVP                  RV4      pVP                  \        V4      VR7      p\        P
                  ! Wc4       R# )r'   r"   r!   r$   r%   Nr&   r*   )r   replacer   r   r/   r0   )r   r5   r   r1   r   new_datar2   s   &&     r   test_quote_char_variousr9   N   sO    F-/BHD||C,H__Xh/:_FF&+r4   c                    R VRV/pRpT pV\         P                  8w  d|   \        '       g   RpMRpV P                  R8X  d   VR8X  d   RV 2MRp\        P
                  ! \        VR	7      ;_uu_ 4        VP                  ! \        V4      3/ VB  R
R
R
4       R
# V P                  R8w  dG   \        . RO.. ROR7      pVP                  ! \        V4      3/ VB p\        P                  ! W4       R
# R
#   + '       g   i     R
# ; i)r	   r   za,b,c
1,2,3z1-character stringzunicode character or Nonepythonr   z"quotechar" must be a r   r   Nr"   r'   r(      r*   )csv
QUOTE_NONEr   enginer   r   r   r   r   r   r/   r0   )	r   r   r5   r   r   r   r   r1   r2   s	   &&&      r   test_null_quote_charrA   Z   s     :y':FDF#.. u&C-C !!X-*2B %SE*; 	 ]]9C00OOHTN5f5 10			x	'i[/B$:6:
f/	 
( 100s   4C44D	zkwargs,exp_datar$   c                     R pT p. ROpVP                   ! \        V4      3RV/VB p\        W%R7      p\        P                  ! Wg4       R# )z	1,2,"foo"namesr"   Nr*   )r   r   r   r/   r0   )r   r   exp_datar   r   r#   r2   r1   s   &&&     r   test_quoting_variousrE   w   sG    $ DFG__Xd^E7EfEF3H&+r4   zdoublequote,exp_dataTz4 " 5Fz4 " 5"c                 &   T pR pVP                   R8X  d:   V'       g2   \        P                  P                  RR7      pVP	                  V4       VP                  \        V4      RVR7      p\        VRR.R7      p\        P                  ! Wx4       R	# )
za,b
3,"4 "" 5"pyarrowMismatched resultreasonr$   )r	   doublequoter+   r,   r"   N)
r@   r   markxfailapplymarkerr   r   r   r/   r0   )	r   rK   rD   requestr   r   rL   r2   r1   s	   &&&&     r   test_double_quoterP      sx     FD}}	!+{{  (; <D!__Xd^s_TFC:6H&+r4   c                     R pT p\        R^./4      pVP                  \        V4      VR7      p\        P                  ! WT4       R# )za
1r+   r%   Nr.   )r   r	   r   r   r1   r2   s   &&    r   test_quotechar_unicoderS      sB     DF#s$H__Xd^y_AF&+r4   balancedc                 (   T pR pVP                   R8X  d:   V'       g2   \        P                  P                  RR7      pVP	                  V4       V'       dL   \        . RO.. ROR7      pVP                  \        VR,           4      4      p\        P                  ! Wv4       R
# VP                   R8X  d   RMRp\        P                  ! \        VR	7      ;_uu_ 4        VP                  \        V4      4       R
R
R
4       R
#   + '       g   i     R
# ; i)za,b,c
1,2,"3rG   rH   rI   r-   r"   r$   z#EOF inside string starting at row 1zunexpected end of datar   Nr<   r*   )r@   r   rL   rM   rN   r   r   r   r/   r0   r   r   )	r   rT   rO   r   r   rL   r1   r2   r   s	   &&&      r   test_unbalanced_quotingrV      s     FD}}	!({{  (; <D!i[/B$*!56
f/ }}# 2) 	 ]];c22OOHTN+ 3222s   D  D	)r
   z%"quoting" must be an integer|Argument)
   zbad "quoting" value)~*%$@P)r'   r(   r
   )r'   r(   z"foo")g      ?g       @r
   )$__doc__r>   ior   r   pandas.compatr   pandas.errorsr   pandasr   pandas._testing_testingr/   rL   filterwarnings
pytestmarkusefixturesxfail_pyarrowskip_pyarrowMSG1MSG2parametrizeQUOTE_MINIMALr   r   r3   r9   r?   rA   	QUOTE_ALLQUOTE_NONNUMERICrE   rP   rS   rV    r4   r   <module>rq      s  
     %  [[''C
 ''8{{&&~6 	DD%DD 
u	!5dV<=$	3+<+<=6	
 q	1$yAB
 2 
2 8# 9 9, 'EF, G, S%6%6$GHDz20 3 I 04 	m_
sIs'8'8	9M?K
sIs}}	5G sIs~~	68IJ sIs';';	<?P>QR  , !", da\N3eq(m_5MN
,
, sHo6, 7, dE]3, 4,r4   