bcgov / entity

ServiceBC Registry Team working on Legal Entities
Apache License 2.0
23 stars 58 forks source link

Furnishings job - Updates required to SFTP XML to BC Laws #22499

Closed argush3 closed 1 week ago

argush3 commented 2 months ago

Implement logic required to XML file generated from stage 2 & 3 to BC Laws SFTP server.

Hongjing will have done a bunch of research as a part of the spike ticket. Talk to her before starting ticket.

PPR has sample SFTP code that can probably be leveraged:

TODOs

leodube-aot commented 2 weeks ago

Testing Notes

  1. Using an SFTP client (like FileZilla or Cyberduck), connect to the BCLaws SFTP staging server. Make sure you are able to view the folder we are uploading to.
  2. Ask someone with 1Password access to set disable-dissolution-sftp-bclaws=False.
  3. Run the furnishings job on some eligible batch_processings to generate an xml file (if curious you can check the batch_processings I used in local testing here, but it isn't necessary to have the same test data. We care more about the xml file upload rather than the xml payload for this ticket).
  4. Refresh the SFTP client. Verify the file is uploaded to the BCLaws SFTP server.

If there are any issues, make sure to save the job run logs to help with solving!

vishnup0422 commented 2 weeks ago

The file is being uploaded to the BC LAWS server

XML PAYLOAD from DATABASE

<?xml version="1.0" encoding="UTF-8"?>
<public_notice>
   <volume />
   <date />
   <filing_desc title="Intent to Dissolve (B.C.)" id="">
      <category>INTENT TO DISSOLVE</category>
      <subcategory>B.C.</subcategory>
      <corp_class>BC Company(s)</corp_class>
      <description>The Registrar of Companies hereby gives notice that the following companies may, at any time after the expiration of one month from the date of publication of this notice, unless cause is shown to the contrary, be dissolved under section 422 of the Business Corporations Act.</description>
      <filings>
         <filing_detail>
            <effective_date>September 20, 2024</effective_date>
            <corp_num>0814585</corp_num>
            <text>STRAIGHT UP ROOFING FIRM LTD. - IMPORT_TEST</text>
         </filing_detail>
         <filing_detail>
            <effective_date>September 20, 2024</effective_date>
            <corp_num>0006718</corp_num>
            <text>TIMBERSHORE HOMES INC. - IMPORT_TEST</text>
         </filing_detail>
      </filings>
   </filing_desc>
</public_notice>

FILE UPLOADED IN BCLAWS SERVER

<public_notice>
<volume/>
<date/>
<filing_desc title="Intent to Dissolve (B.C.)" id="">
<category>INTENT TO DISSOLVE</category>
<subcategory>B.C.</subcategory>
<corp_class>BC Company(s)</corp_class>
<description>The Registrar of Companies hereby gives notice that the following companies may, at any time after the expiration of one month from the date of publication of this notice, unless cause is shown to the contrary, be dissolved under section 422 of the Business Corporations Act.</description>
<filings>
<filing_detail>
<effective_date>September 20, 2024</effective_date>
<corp_num>0814585</corp_num>
<text> STRAIGHT UP ROOFING FIRM LTD. - IMPORT_TEST </text>
</filing_detail>
<filing_detail>
<effective_date>September 20, 2024</effective_date>
<corp_num>0006718</corp_num>
<text> TIMBERSHORE HOMES INC. - IMPORT_TEST </text>
</filing_detail>
</filings>
</filing_desc>
</public_notice>

The business in STAGE2 that are uploaded

image.png

The logs from the Furnishings job:

Screenshot 2024-09-20 at 1.45.32 PM.png

BCLAWS Server FILE:

Screenshot 2024-09-20 at 1.40.24 PM.png