Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add entry points #69

Merged
merged 8 commits into from
Jul 14, 2021
Merged

Add entry points #69

merged 8 commits into from
Jul 14, 2021

Conversation

chazuttu
Copy link
Collaborator

@chazuttu chazuttu commented Jul 9, 2021

Summary

This PR converts scripts into entry points as per issue-#11.

  • added entry points in setup.cfg
  • added main() methods in scripts so that they can be called from command line just by name

Checklist

  • Classes, Variables, function and methods logic ok
  • Comments written explaining what the code does
  • All python code is PEP8 compliant (run black .)
  • No lint issues (run flake8)
  • Test coverage with pytest implemented
  • Reviewers assigned (at least 1 mentor)

Manual evidence

$ wsaa

para soporte de WebClient debe instalar httplib2
Encodign in cp1252
Usando CRT=reingart.crt KEY=reingart.key URL=https://wsaahomo.afip.gov.ar/ws/services/LoginCms SERVICE=wsfe TTL=36000
WSAA Version 3.11c  False
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<loginTicketResponse version="1.0">
    <header>
        <source>CN=wsaahomo, O=AFIP, C=AR, SERIALNUMBER=CUIT 33693450239</source>
        <destination>SERIALNUMBER=CUIT 20267565393, CN=reingart2019pub</destination>
        <uniqueId>657428365</uniqueId>
        <generationTime>2021-07-09T13:51:57.149-03:00</generationTime>
        <expirationTime>2021-07-10T01:51:57.149-03:00</expirationTime>
    </header>
    <credentials>
        <token>P+Cg==</token>
        <sign>s4M0=</sign>
    </credentials>
</loginTicketResponse>

$ wsfev1 --prueba

para soporte de WebClient debe instalar httplib2
Leyendo TA de C:\Users\pyafipws\py3test\lib\site-packages\pyafipws-3.9.b_2514_-py3.9.egg\pyafipws\cache\TA-2b4277f5962bd2cb0265c0fac4b32304.xml...
b"FECAESolicitar(Auth=*{'Token': <class 'str'>, 'Sign': <class 'str'>, 'Cuit': <alias 'long' for '<class 'int'>'>}*, FeCAEReq=*{'FeCabReq': 
*{'CantReg': <class 'int'>, 'PtoVta': <class 'int'>, 'CbteTipo': <class 'int'>}*, 'FeDetReq': [*{'FECAEDetRequest': *{'Concepto': <class 'int'>, 'DocTipo': <class 'sg': <class 'str'>}*}*], 'Errors': [*{'Err': *{'Code': <class 'int'>, 'Msg': <class 'str'>}*}*]}*}**:\n\nSolicitud de C\xf3digo de Autorizaci\xf3n Electr\xf3nico (CAE)\nHeaders: None"
Nro. Cbte. desde-hasta 493 493
Resultado A
Reproceso
CAE 71283954824423
Vencimiento 20210719
Observaciones 10217: El credito fiscal discriminado en el presente comprobante solo podra ser computado a efectos del Procedimiento permanente de transicion al Regimen General.
71283954824423 == 71283954824423
3 != 2
10217 != 10017
El credito fiscal discriminado en el presente comprobante solo podra ser computado a efectos del Procedimiento permanente de transicion al Regimen General.

$ pyfepdf --prueba --mostrar

para soporte de WebClient debe instalar httplib2
Encodign in cp1252
Prueba!

chazuttu and others added 5 commits July 9, 2021 20:45
Signed-off-by: UTKARSH KUMAR <Utkarshdhsbgp@gmail.com>
Signed-off-by: UTKARSH KUMAR <Utkarshdhsbgp@gmail.com>
Signed-off-by: UTKARSH KUMAR <Utkarshdhsbgp@gmail.com>
@chazuttu chazuttu requested a review from reingart July 9, 2021 18:01
chazuttu and others added 3 commits July 10, 2021 00:27
Signed-off-by: UTKARSH KUMAR <Utkarshdhsbgp@gmail.com>
Signed-off-by: UTKARSH KUMAR <Utkarshdhsbgp@gmail.com>
Copy link
Member

@reingart reingart left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, there are some unneeded whitespace but we could address that in another PR

rece1.py Outdated Show resolved Hide resolved
@reingart reingart merged commit 7f556d5 into PyAr:main Jul 14, 2021
@chazuttu chazuttu deleted the add_entry_points branch July 26, 2021 06:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants