Is patient-portal branch compatible with v15 frappe?

i would like to test the patient portal branch and i have v15 frappe and erpnext installed. I also see that there is a v15-beta branch which i have tried and works except for the patient appointment feature. I really would like patient appointment feature thus was wondering if it is compatible with v15 or not. @akash_krishna

@m5ingh portal wont work in v15 frappe since there are some dependencies which was changed in 15. Will need to update the portal branch as well.

thanks @akash_krishna for the update, yes while building my custom image i got this message

#12 180.9 ▲ [WARNING] [plugin frappe-html] There was an error importing /home/frappe/frappe-bench/apps/healthcare/healthcare/public/js/healthcare_orders.html
#12 180.9 
#12 180.9     ../healthcare/healthcare/public/js/healthcare.bundle.js:4:7:
#12 180.9       4 │ import "./healthcare_orders.html";

although the build successfully completed. However when i run the image i got

AttributeError: module 'frappe.utils' has no attribute 'get_time_zone'

while creating patient appointment via desk. I would be happy to test new changes.

@akash_krishna sorry to bother you again, but can you please advise me what should i do to resolve the dependency issue. I am willing to put in work and time to get patient portal compatible with v15.

this method was available in version-14 but got deprecated in version-15

thanks @akash_krishna for pointing me in the right direction. I managed to resolve the get_time_zone error. I also added healthcare_orders.html file from develop branch to the healthcare/public/js , dont know if its relevant but the healthcare/public/js/healthcare.bundle.js file seems to reference it and build was trowing errors due to this. Please advise if healthcare_order.html file should be included or not. Here the the repo link.

After this the image built is working fine and i am able to book appointments via desk, but for patient-portal i am only able to go to the /departments link. clicking on any department or using practitioner slider gives error.

Traceback (most recent call last):
  File "apps/frappe/frappe/website/serve.py", line 18, in get_response
    response = renderer_instance.render()
               ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "apps/frappe/frappe/website/page_renderers/template_page.py", line 84, in render
    html = self.get_html()
           ^^^^^^^^^^^^^^^
  File "apps/frappe/frappe/website/utils.py", line 524, in cache_html_decorator
    html = func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^
  File "apps/frappe/frappe/website/page_renderers/template_page.py", line 95, in get_html
    self.update_context()
  File "apps/frappe/frappe/website/page_renderers/template_page.py", line 163, in update_context
    data = self.run_pymodule_method("get_context")
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "apps/frappe/frappe/website/page_renderers/template_page.py", line 225, in run_pymodule_method
    return method(self.context)
           ^^^^^^^^^^^^^^^^^^^^
  File "apps/healthcare/healthcare/www/practitioners.py", line 30, in get_context
    data = frappe.db.sql(query, as_dict=True)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "apps/frappe/frappe/database/database.py", line 235, in sql
    self._cursor.execute(query, values)
  File "env/lib/python3.11/site-packages/pymysql/cursors.py", line 153, in execute
    result = self._query(query)
             ^^^^^^^^^^^^^^^^^^
  File "env/lib/python3.11/site-packages/pymysql/cursors.py", line 322, in _query
    conn.query(q)
  File "env/lib/python3.11/site-packages/pymysql/connections.py", line 558, in query
    self._affected_rows = self._read_query_result(unbuffered=unbuffered)
                          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "env/lib/python3.11/site-packages/pymysql/connections.py", line 822, in _read_query_result
    result.read()
  File "env/lib/python3.11/site-packages/pymysql/connections.py", line 1200, in read
    first_packet = self.connection._read_packet()
                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "env/lib/python3.11/site-packages/pymysql/connections.py", line 772, in _read_packet
    packet.raise_for_error()
  File "env/lib/python3.11/site-packages/pymysql/protocol.py", line 221, in raise_for_error
    err.raise_mysql_exception(self._data)
  File "env/lib/python3.11/site-packages/pymysql/err.py", line 143, in raise_mysql_exception
    raise errorclass(errno, errval)
pymysql.err.OperationalError: (1054, "Unknown column 'h_pract.show_in_website' in 'where clause'")

I have enabled show in website for medical departments but am not able to find the same for healthcare practitioner. Any help or input will be greatly appreciated.

“show_in_website” column in the table is not created, IG you need to change the modified timestamp in healthcare practitioner json file and migrate.

@akash_krishna thanks a ton. I resolved the migration issue and now am able to view practitioners, but now i get a new error when i go to select the date.

Traceback (most recent call last):
  File "apps/frappe/frappe/app.py", line 106, in application
    frappe.handler.handle()
  File "apps/frappe/frappe/handler.py", line 49, in handle
    data = execute_cmd(cmd)
           ^^^^^^^^^^^^^^^^
  File "apps/frappe/frappe/handler.py", line 85, in execute_cmd
    return frappe.call(method, **frappe.form_dict)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "apps/frappe/frappe/__init__.py", line 1682, in call
    return fn(*args, **newargs)
           ^^^^^^^^^^^^^^^^^^^^
  File "apps/frappe/frappe/utils/typing_validations.py", line 31, in wrapper
    return func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^
TypeError: get_availability_data() missing 1 required positional argument: 'appointment'

I believe this error has happened before but i could not find how it was solved. can you please point me in the right direction.

@m5ingh in book_patient_appointment.js file there is a call “get_availability_data”, in the args you need to pass “appointment” as well as it is mandatory in the python method. The “appointment” arg needs practitioner, patient and appointment_date.